/*
Theme Name: Erome Premium Portrait Video Theme
Theme URI: https://wordpress.org/themes/erome-portrait/
Author: AI Studio WordPress Customizations
Author URI: https://ai.studio/build
Description: A slick, feature-rich WordPress theme modeled after Erome, specialized for vertical and portrait-oriented media, short clips, reels, and mobile vloggers. Includes fully responsive column configurations and lightweight custom video elements.
Version: 1.0.0
License: GNU GPLv2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Tags: custom-colors, custom-header, vertical-video, grid-layout, dark, photography, portfolio, mobile-first
Text Domain: erome-portrait
*/

:root {
  --primary-color: #3b82f6;
  --background-color: #0d0d0d;
  --card-bg: #1e1e1e;
  --text-primary: #ffffff;
  --text-secondary: #9e9e9e;
  --border-color: #2a2a2a;
}

body {
  background-color: var(--background-color);
  color: var(--text-primary);
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
  margin: 0;
  padding: 0;
  overflow-x: hidden;
}

/* Base customizer column values: 4 columns */
.erome-video-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  padding: 24px;
}

.erome-video-card {
  background: var(--card-bg);
  border-radius: 16px;
  overflow: hidden;
  position: relative;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  aspect-ratio: 9/16;
  border: 1px solid rgba(255,225,255,0.06);
}

.erome-video-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
}

/* Ensure post card thumbnails and video posters cover full frame regardless of size */
article video,
article img,
.erome-video-card video,
.erome-video-card img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center !important;
}

.video-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9), transparent);
  padding: 16px;
  color: #fff;
}

.accent-badge {
  background: var(--primary-color);
  color: #000;
  font-weight: bold;
}

/* ─── Mobile Responsive Viewport ─────────────────────────────── */

/* Prevent any element from causing horizontal scroll */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  overflow-x: hidden;
  -webkit-text-size-adjust: 100%; /* Prevent font scaling on orientation change */
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden;
  -webkit-tap-highlight-color: transparent; /* Remove tap flash on mobile */
  touch-action: pan-y;                      /* Allow vertical scroll, prevent accidental zoom */
}

/* Safe area padding for notched phones (iPhone X+) */
.site-main,
.container {
  padding-left:  max(1rem, env(safe-area-inset-left));
  padding-right: max(1rem, env(safe-area-inset-right));
  padding-bottom: env(safe-area-inset-bottom);
}

/* Minimum tap target size for all links & buttons (44×44px) */
a,
button {
  min-height: 44px;
  min-width:  44px;
  display: inline-flex;
  align-items: center;
}

/* Pill / tag links – keep them inline-flex but allow smaller height override */
.flex a,
section a {
  min-height: unset;
  min-width:  unset;
  display: inline-flex;
}

/* Responsive grid fallback for very small screens (<360px) */
@media (max-width: 359px) {
  .grid-cols-2 {
    grid-template-columns: repeat(1, minmax(0, 1fr)) !important;
  }
}

/* Fine-tune card grid gap on small screens */
@media (max-width: 480px) {
  .gap-6 {
    gap: 0.75rem !important;
  }
  .px-4 {
    padding-left:  0.75rem !important;
    padding-right: 0.75rem !important;
  }
}

/* Smooth image/video rendering on mobile */
img,
video {
  max-width: 100%;
  height: auto;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
