/* ═══════════════════════════════════════════════════════════════════════
   StreamVox — Design System Premium
   Inspirado na fluidez do ChatGPT com identidade própria e visual forte
   ═══════════════════════════════════════════════════════════════════════ */

/* ── Google Fonts já importadas no head ── */

/* ── Tokens de Design ─────────────────────────────────────────────────── */
:root {
  --accent:       #10a37f;
  --accent-light: #1ab594;
  --accent-dark:  #0d8a6a;
  --accent-glow:  rgba(16,163,127,.25);

  --bg:           #0a0a0a;
  --bg-2:         #111111;
  --bg-3:         #181818;
  --bg-4:         #222222;
  --bg-5:         #2a2a2a;

  --border:       rgba(255,255,255,.07);
  --border-focus: rgba(16,163,127,.5);

  --text:         #ececec;
  --text-muted:   #888;
  --text-dim:     #555;

  --sidebar-w:    260px;
  --topbar-h:     56px;

  --radius-sm:    6px;
  --radius:       10px;
  --radius-lg:    16px;
  --radius-xl:    24px;

  --shadow:       0 4px 24px rgba(0,0,0,.45);
  --shadow-lg:    0 12px 48px rgba(0,0,0,.6);

  --font-display: 'Syne', sans-serif;
  --font-body:    'DM Sans', sans-serif;

  --transition:   .2s cubic-bezier(.4,0,.2,1);
  --transition-slow: .4s cubic-bezier(.4,0,.2,1);

  /* Live badge */
  --live-color: #ff3b30;
}

/* Light theme */
[data-theme="light"] {
  --bg:     #f5f5f5;
  --bg-2:   #ffffff;
  --bg-3:   #f0f0f0;
  --bg-4:   #e8e8e8;
  --bg-5:   #dedede;
  --border: rgba(0,0,0,.08);
  --text:   #111;
  --text-muted: #666;
  --text-dim:   #aaa;
  --shadow: 0 4px 24px rgba(0,0,0,.1);
  --shadow-lg: 0 12px 48px rgba(0,0,0,.15);
}

/* ── Reset & Base ──────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  min-height: 100dvh;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-light); }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
input, textarea, select { font-family: inherit; }
svg { flex-shrink: 0; }

/* ── App Layout ────────────────────────────────────────────────────────── */
.app-container {
  display: flex;
  min-height: 100dvh;
  position: relative;
}

/* ── Sidebar ───────────────────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  height: 100dvh;
  position: fixed;
  top: 0; left: 0;
  background: var(--bg-2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 200;
  transition: transform var(--transition-slow);
  will-change: transform;
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-width: thin;
  scrollbar-color: var(--bg-5) transparent;
}

.sidebar-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 16px 16px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -.02em;
}

.sidebar-logo .logo-img { height: 32px; width: auto; object-fit: contain; }

.logo-text {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.25rem;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.sidebar-toggle {
  width: 32px; height: 32px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition);
}
.sidebar-toggle:hover { background: var(--bg-4); color: var(--text); }
.sidebar-toggle svg { width: 18px; height: 18px; }

.sidebar-nav { flex: 1; padding: 12px 8px; }

.nav-list { list-style: none; display: flex; flex-direction: column; gap: 2px; }

.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 10px;
  border-radius: var(--radius);
  color: var(--text-muted);
  font-size: .9rem;
  font-weight: 450;
  transition: background var(--transition), color var(--transition);
  position: relative;
  user-select: none;
}

.nav-link:hover { background: var(--bg-4); color: var(--text); }
.nav-link.active {
  background: color-mix(in srgb, var(--accent) 12%, transparent);
  color: var(--accent);
}

.nav-icon { width: 18px; height: 18px; flex-shrink: 0; }

.badge-live {
  margin-left: auto;
  background: var(--live-color);
  color: #fff;
  font-size: .6rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 20px;
  letter-spacing: .05em;
  animation: pulse-live 2s ease-in-out infinite;
}

@keyframes pulse-live {
  0%,100% { opacity: 1; }
  50% { opacity: .6; }
}

.sidebar-footer {
  padding: 12px 12px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.social-link {
  width: 32px; height: 32px;
  background: var(--bg-4);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition);
}
.social-link:hover { background: var(--accent); color: #fff; }
.social-link svg { width: 16px; height: 16px; }

.sidebar-actions { display: flex; gap: 8px; align-items: center; }

.theme-toggle {
  width: 36px; height: 36px;
  background: var(--bg-4);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition);
}
.theme-toggle:hover { background: var(--bg-5); color: var(--text); }
.theme-toggle svg { width: 16px; height: 16px; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="light"] .icon-sun { display: none; }

.pwa-install-btn {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px;
  background: color-mix(in srgb, var(--accent) 15%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: var(--radius);
  color: var(--accent);
  font-size: .82rem;
  font-weight: 500;
  flex: 1;
  transition: background var(--transition);
}
.pwa-install-btn:hover { background: color-mix(in srgb, var(--accent) 25%, transparent); }
.pwa-install-btn svg { width: 15px; height: 15px; }

/* Overlay sidebar mobile */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(4px);
  z-index: 199;
}

/* ── Main Content ──────────────────────────────────────────────────────── */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-w);
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  transition: margin var(--transition-slow);
}

/* ── Topbar ────────────────────────────────────────────────────────────── */
.topbar {
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  background: var(--bg-2);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  backdrop-filter: blur(12px);
}

.menu-toggle {
  width: 36px; height: 36px;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border-radius: var(--radius-sm);
  color: var(--text);
  transition: background var(--transition);
}
.menu-toggle:hover { background: var(--bg-4); }
.menu-toggle span {
  display: block;
  width: 20px; height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform var(--transition);
}

.topbar-center .topbar-logo {
  display: none;
  color: var(--text);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
}
.topbar-logo img { height: 28px; }

.topbar-search-btn {
  width: 36px; height: 36px;
  background: var(--bg-4);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition), color var(--transition);
}
.topbar-search-btn:hover { background: var(--bg-5); color: var(--text); }
.topbar-search-btn svg { width: 18px; height: 18px; }

/* ── View Container ────────────────────────────────────────────────────── */
.view-container {
  flex: 1;
  padding: 0;
  animation: fadeIn .3s ease forwards;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Loader ────────────────────────────────────────────────────────────── */
.app-loader {
  position: fixed;
  inset: 0;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 24px;
  z-index: 9999;
  transition: opacity .4s ease, visibility .4s ease;
}

.app-loader.hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loader-logo {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2rem;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.loader-logo img { height: 48px; }

.loader-bar {
  width: 200px;
  height: 3px;
  background: var(--bg-4);
  border-radius: 3px;
  overflow: hidden;
}

.loader-progress {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-light));
  border-radius: 3px;
  animation: loading-bar 1.2s cubic-bezier(.4,0,.2,1) infinite;
}

@keyframes loading-bar {
  0% { width: 0%; margin-left: 0; }
  50% { width: 80%; margin-left: 10%; }
  100% { width: 0%; margin-left: 100%; }
}

/* ── Hero Section ──────────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 520px;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  background: var(--bg-3);
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  transition: transform 8s ease;
}

.hero:hover .hero-bg { transform: scale(1.04); }

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(10,10,10,.98) 0%,
    rgba(10,10,10,.6) 50%,
    rgba(10,10,10,.2) 100%
  );
}

[data-theme="light"] .hero-overlay {
  background: linear-gradient(
    to top,
    rgba(245,245,245,.98) 0%,
    rgba(245,245,245,.5) 50%,
    rgba(245,245,245,.1) 100%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  padding: 40px;
  max-width: 720px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: color-mix(in srgb, var(--accent) 15%, transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 30%, transparent);
  color: var(--accent);
  font-size: .78rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  margin-bottom: 14px;
  text-transform: uppercase;
  letter-spacing: .08em;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -.03em;
  margin-bottom: 14px;
}

.hero-desc {
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 24px;
  max-width: 500px;
  line-height: 1.7;
}

.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ── Buttons ───────────────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border-radius: var(--radius);
  font-size: .9rem;
  font-weight: 500;
  font-family: var(--font-body);
  transition: all var(--transition);
  user-select: none;
  white-space: nowrap;
  cursor: pointer;
}

.btn svg { width: 16px; height: 16px; }

.btn-primary {
  background: var(--accent);
  color: #fff;
  border: 1px solid var(--accent);
}
.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 20px var(--accent-glow);
}

.btn-secondary {
  background: var(--bg-4);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { background: var(--bg-5); transform: translateY(-1px); }

.btn-ghost {
  background: transparent;
  color: var(--text-muted);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--bg-4); color: var(--text); }

.btn-danger {
  background: #ff3b30;
  color: #fff;
  border: 1px solid #ff3b30;
}
.btn-danger:hover { background: #d32f2f; }

.btn-sm { padding: 7px 14px; font-size: .82rem; }
.btn-lg { padding: 14px 28px; font-size: 1rem; }
.btn-full { width: 100%; }

/* ── Cards ─────────────────────────────────────────────────────────────── */
.cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.card {
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  cursor: pointer;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: color-mix(in srgb, var(--accent) 30%, transparent);
}

.card-thumb {
  position: relative;
  aspect-ratio: 16/9;
  background: var(--bg-4);
  overflow: hidden;
}

.card-thumb img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}
.card:hover .card-thumb img { transform: scale(1.05); }

.card-play-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.4);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition);
}
.card:hover .card-play-overlay { opacity: 1; }

.card-play-btn {
  width: 52px; height: 52px;
  background: rgba(255,255,255,.9);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: transform var(--transition);
}
.card:hover .card-play-btn { transform: scale(1.1); }
.card-play-btn svg { width: 20px; height: 20px; color: var(--bg); margin-left: 3px; }

.card-type-badge {
  position: absolute;
  top: 10px; right: 10px;
  padding: 3px 8px;
  background: rgba(0,0,0,.7);
  backdrop-filter: blur(4px);
  border-radius: 20px;
  font-size: .72rem;
  font-weight: 600;
  color: #fff;
  text-transform: uppercase;
  letter-spacing: .06em;
}

.card-body { padding: 16px; }

.card-title {
  font-family: var(--font-display);
  font-size: .95rem;
  font-weight: 600;
  margin-bottom: 6px;
  line-height: 1.3;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.card-meta {
  font-size: .8rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-meta svg { width: 13px; height: 13px; }

/* ── Section Layout ────────────────────────────────────────────────────── */
.section {
  padding: 40px;
}

.section-sm { padding: 24px 40px; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: -.02em;
  display: flex;
  align-items: center;
  gap: 10px;
}

.section-title::before {
  content: '';
  display: block;
  width: 4px; height: 20px;
  background: var(--accent);
  border-radius: 2px;
}

/* ── Video Player ──────────────────────────────────────────────────────── */
.player-wrap {
  position: relative;
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
  aspect-ratio: 16/9;
  box-shadow: var(--shadow-lg);
}

.player-wrap iframe,
.player-wrap video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
}

.player-wrap .player-html {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

/* ── Gallery ───────────────────────────────────────────────────────────── */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.gallery-item {
  aspect-ratio: 4/3;
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  position: relative;
  background: var(--bg-4);
}

.gallery-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}
.gallery-item:hover img { transform: scale(1.08); }

.gallery-item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.4);
  opacity: 0;
  transition: opacity var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
.gallery-item:hover .gallery-item-overlay { opacity: 1; }

/* ── Lightbox ──────────────────────────────────────────────────────────── */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.92);
  backdrop-filter: blur(12px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: fadeIn .2s ease;
}

.lightbox img {
  max-width: 100%;
  max-height: 90dvh;
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
}

.lightbox-close {
  position: absolute;
  top: 20px; right: 20px;
  width: 40px; height: 40px;
  background: var(--bg-3);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text);
  transition: background var(--transition);
}
.lightbox-close:hover { background: var(--bg-5); }
.lightbox-close svg { width: 20px; height: 20px; }

/* ── Search Modal ──────────────────────────────────────────────────────── */
.search-modal {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.7);
  backdrop-filter: blur(8px);
  z-index: 500;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 24px 24px;
  opacity: 0;
  visibility: hidden;
  transition: opacity var(--transition), visibility var(--transition);
}

.search-modal.open {
  opacity: 1;
  visibility: visible;
}

.search-modal-inner {
  width: 100%;
  max-width: 640px;
  background: var(--bg-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  transform: translateY(-16px);
  transition: transform var(--transition);
}

.search-modal.open .search-modal-inner { transform: translateY(0); }

.search-input-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
}

.search-input-wrap svg { width: 20px; height: 20px; color: var(--text-muted); flex-shrink: 0; }

#searchInput {
  flex: 1;
  background: none;
  border: none;
  color: var(--text);
  font-size: 1rem;
  outline: none;
  placeholder-color: var(--text-dim);
}

#searchClose {
  background: var(--bg-4);
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  padding: 4px 8px;
  font-size: .75rem;
  font-weight: 600;
}

.search-results { max-height: 400px; overflow-y: auto; padding: 8px; }

.search-result-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 12px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition);
}
.search-result-item:hover { background: var(--bg-4); }

.search-result-thumb {
  width: 60px; height: 38px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--bg-4);
  flex-shrink: 0;
}

.search-result-info { flex: 1; min-width: 0; }
.search-result-title {
  font-size: .88rem;
  font-weight: 500;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.search-result-type { font-size: .75rem; color: var(--text-muted); }

/* ── Toast ─────────────────────────────────────────────────────────────── */
.toast-container {
  position: fixed;
  bottom: 24px; right: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 9000;
  max-width: 360px;
}

.toast {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  animation: toast-in .3s cubic-bezier(.34,1.56,.64,1) forwards;
  border-left: 3px solid var(--accent);
}

.toast.error { border-left-color: #ff3b30; }
.toast.warning { border-left-color: #ff9f0a; }
.toast.success { border-left-color: #30d158; }

@keyframes toast-in {
  from { opacity: 0; transform: translateX(100%); }
  to   { opacity: 1; transform: translateX(0); }
}

.toast-out {
  animation: toast-out .25s ease forwards !important;
}
@keyframes toast-out {
  to { opacity: 0; transform: translateX(110%); }
}

.toast-body { flex: 1; min-width: 0; }
.toast-title { font-size: .88rem; font-weight: 600; margin-bottom: 2px; }
.toast-msg { font-size: .82rem; color: var(--text-muted); }

/* ── Floating Player ───────────────────────────────────────────────────── */
.floating-player {
  position: fixed;
  bottom: 24px; right: 24px;
  width: 320px;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  z-index: 800;
  animation: slideUp .3s cubic-bezier(.34,1.56,.64,1);
}

@keyframes slideUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}

.fp-video-wrap { aspect-ratio: 16/9; background: #000; position: relative; }
.fp-video-wrap iframe,
.fp-video-wrap video { width: 100%; height: 100%; border: none; }

.fp-controls {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
}

.fp-title { font-size: .82rem; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 180px; }

.fp-actions { display: flex; gap: 8px; }
.fp-actions button {
  width: 28px; height: 28px;
  border-radius: var(--radius-sm);
  background: var(--bg-5);
  display: flex; align-items: center; justify-content: center;
  color: var(--text-muted);
  transition: background var(--transition);
}
.fp-actions button:hover { background: var(--bg-4); color: var(--text); }
.fp-actions button svg { width: 14px; height: 14px; }

/* ── Banner Slider ─────────────────────────────────────────────────────── */
.banner-slider {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--bg-3);
}

.banner-slider .slide {
  display: none;
  position: relative;
}
.banner-slider .slide.active { display: block; }

.banner-slider img {
  width: 100%;
  aspect-ratio: 21/9;
  object-fit: cover;
}

.banner-dots {
  position: absolute;
  bottom: 16px;
  left: 50%; transform: translateX(-50%);
  display: flex; gap: 8px;
}

.banner-dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.4);
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}
.banner-dot.active { background: #fff; transform: scale(1.3); }

/* ── Forms ─────────────────────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }

.form-label {
  display: block;
  font-size: .85rem;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.form-control {
  width: 100%;
  background: var(--bg-3);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  color: var(--text);
  font-size: .92rem;
  font-family: var(--font-body);
  transition: border-color var(--transition), box-shadow var(--transition);
  outline: none;
}

.form-control:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-control::placeholder { color: var(--text-dim); }

textarea.form-control { resize: vertical; min-height: 100px; }

/* ── Scrollbar ─────────────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--bg-5); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

/* ── Utilities ─────────────────────────────────────────────────────────── */
.container { max-width: 1280px; margin: 0 auto; padding: 0 24px; }
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-accent { color: var(--accent); }
.font-display { font-family: var(--font-display); }
.d-flex { display: flex; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.gap-3 { gap: 24px; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.badge-success { background: rgba(48,209,88,.15); color: #30d158; }
.badge-danger  { background: rgba(255,59,48,.15);  color: #ff3b30; }
.badge-warning { background: rgba(255,159,10,.15); color: #ff9f0a; }
.badge-info    { background: rgba(10,132,255,.15);  color: #0a84ff; }
.badge-accent  { background: var(--accent-glow); color: var(--accent); }

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .section { padding: 24px; }
  .section-sm { padding: 16px 24px; }
  .hero-content { padding: 28px 24px; }
}

@media (max-width: 768px) {
  :root { --sidebar-w: 0px; }

  .sidebar {
    width: 260px;
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
    box-shadow: var(--shadow-lg);
  }

  .sidebar-overlay.show { display: block; }

  .main-content { margin-left: 0; }

  .menu-toggle { display: flex; }
  .topbar-center .topbar-logo { display: flex; }

  .hero { min-height: 360px; }
  .hero-title { font-size: 1.6rem; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; justify-content: center; }

  .section { padding: 20px 16px; }
  .cards-grid { grid-template-columns: 1fr 1fr; gap: 14px; }

  .floating-player { width: 100%; right: 0; bottom: 0; border-radius: var(--radius-lg) var(--radius-lg) 0 0; }

  .toast-container { right: 12px; bottom: 12px; max-width: calc(100vw - 24px); }

  .section-header { flex-direction: column; align-items: flex-start; gap: 10px; }
}

@media (max-width: 480px) {
  .cards-grid { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: 1fr 1fr; }
}

/* ── Smart TV (>= 1920px) ──────────────────────────────────────────────── */
@media (min-width: 1920px) {
  :root { --sidebar-w: 300px; }
  .section { padding: 48px 56px; }
  .hero-content { padding: 56px; }
  .hero { min-height: 640px; }
  .cards-grid { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
  body { font-size: 1.05rem; }
}

/* ── Print ─────────────────────────────────────────────────────────────── */
@media print {
  .sidebar, .topbar, .floating-player, .toast-container { display: none !important; }
  .main-content { margin: 0; }
}

/* ── Animations ────────────────────────────────────────────────────────── */
.animate-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity .5s ease, transform .5s ease;
}
.animate-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── No JS fallback ────────────────────────────────────────────────────── */
.no-js .app-loader { display: none; }
.no-js #app { opacity: 1 !important; }
