/* =========================================================================
   CineSfera Content Network — Design System
   Dark cinematic (RaiPlay-inspired) + broadcast "timecode" provenance motif
   ========================================================================= */

@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@500;600;700;800&family=Inter:wght@400;500;600;700&family=IBM+Plex+Mono:wght@400;500;600&display=swap');

:root {
  /* --- Color: tonal dark layering, not flat black --- */
  --bg-void: #0b0e14;
  --bg-surface: #121212;
  --bg-elevated: #171b23;
  --bg-elevated-2: #1d2230;

  --ink-primary: #f2f3f5;
  --ink-secondary: #9aa0ab;
  --ink-tertiary: #5c6270;

  --accent-blue: #0066ff;
  --accent-cyan: #00b4d8;
  --accent-gradient: linear-gradient(120deg, #0066ff 0%, #00b4d8 100%);

  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);

  --danger: #ff3b5c;
  --gold: #ffb020;
  --success: #00d68f;

  /* --- Type --- */
  --font-display: 'Montserrat', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'IBM Plex Mono', monospace;

  /* --- Scale / geometry --- */
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --shadow-elevated: 0 24px 60px rgba(0, 0, 0, 0.55);
  --shadow-glow: 0 0 0 1px rgba(0, 180, 216, 0.35), 0 8px 30px rgba(0, 102, 255, 0.25);
  --max-media-height: 76vh;
  --container-w: 1360px;
}

/* --- Reset --- */
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg-void);
  color: var(--ink-primary);
  font-family: var(--font-body);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }
table { border-collapse: collapse; width: 100%; }

:focus-visible {
  outline: 2px solid var(--accent-cyan);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

.container {
  max-width: var(--container-w);
  margin: 0 auto;
  padding: 0 32px;
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-cyan);
}

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

/* =========================================================================
   Header
   ========================================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px 32px;
  background: rgba(11, 14, 20, 0.78);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom: 1px solid var(--line);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.brand-mark {
  width: 30px; height: 30px;
  border-radius: 8px;
  background: var(--accent-gradient);
  display: flex; align-items: center; justify-content: center;
  color: #04101f;
  font-weight: 800;
  font-size: 14px;
  box-shadow: var(--shadow-glow);
}
.brand-name span { color: var(--accent-cyan); }

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.06em;
}
.main-nav a {
  padding: 9px 16px;
  border-radius: 999px;
  color: var(--ink-secondary);
  transition: color 0.2s ease, background 0.2s ease;
}
.main-nav a:hover,
.main-nav a.active {
  color: var(--ink-primary);
  background: var(--bg-elevated);
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  justify-content: flex-end;
}

.search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  max-width: 280px;
  padding: 9px 14px;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  color: var(--ink-secondary);
  transition: border-color 0.2s ease;
}
.search-box:focus-within { border-color: var(--accent-cyan); }
.search-box input {
  background: none;
  border: none;
  color: var(--ink-primary);
  font-size: 13px;
  width: 100%;
  outline: none;
}
.search-box svg { flex-shrink: 0; opacity: 0.7; }

.btn-admin {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--ink-primary);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.btn-admin:hover { border-color: var(--accent-cyan); background: var(--bg-elevated); }

/* =========================================================================
   Buttons (shared)
   ========================================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 14px;
  border: 1px solid transparent;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease, border-color .15s ease;
}
.btn:active { transform: translateY(1px); }
.btn-primary {
  background: var(--accent-gradient);
  color: #04101f;
  box-shadow: var(--shadow-glow);
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-secondary {
  background: var(--bg-elevated);
  color: var(--ink-primary);
  border-color: var(--line-strong);
}
.btn-secondary:hover { border-color: var(--accent-cyan); }
.btn-block { width: 100%; }
.btn-danger { background: var(--danger); color: #fff; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

/* =========================================================================
   Hero
   ========================================================================= */
.hero {
  position: relative;
  margin: 24px 32px 0;
  border-radius: var(--radius-lg);
  overflow: hidden;
  min-height: 62vh;
  display: flex;
  align-items: flex-end;
  background: var(--bg-surface);
  animation: hero-rise 0.7s ease both;
}
@keyframes hero-rise {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}
.hero-media { position: absolute; inset: 0; }
.hero-media img {
  width: 100%; height: 100%; object-fit: cover;
  filter: brightness(0.55);
}
.hero-scrim {
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(11,14,20,0.98) 0%, rgba(11,14,20,0.35) 55%, rgba(11,14,20,0.1) 100%);
}
.hero-content {
  position: relative;
  padding: 48px;
  max-width: 640px;
}
.hero-category {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}
.hero-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(32px, 4.2vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin: 0 0 14px;
}
.hero-desc {
  color: var(--ink-secondary);
  font-size: 15px;
  max-width: 52ch;
  margin: 0 0 26px;
}
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* =========================================================================
   Category sections + horizontal carousel
   ========================================================================= */
.section {
  padding: 56px 32px 0;
}
.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
  gap: 16px;
}
.section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.02em;
  display: flex;
  align-items: center;
  gap: 12px;
}
.section-title .count {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--ink-tertiary);
  font-weight: 400;
}
.carousel-controls { display: flex; gap: 8px; }
.carousel-btn {
  width: 38px; height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  color: var(--ink-primary);
  display: flex; align-items: center; justify-content: center;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.carousel-btn:hover { border-color: var(--accent-cyan); background: var(--bg-elevated-2); }
.carousel-btn:disabled { opacity: 0.35; cursor: default; }

.carousel-track {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  scroll-snap-type: x proximity;
  padding-bottom: 12px;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
}
.carousel-track::-webkit-scrollbar { height: 6px; }
.carousel-track::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 999px; }

.card {
  position: relative;
  flex: 0 0 auto;
  width: 300px;
  scroll-snap-align: start;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-surface);
  border: 1px solid var(--line);
  transition: transform 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}
.card:hover {
  transform: translateY(-4px);
  border-color: rgba(0, 180, 216, 0.4);
  box-shadow: var(--shadow-elevated);
}
.card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--bg-elevated);
  overflow: hidden;
}
.card-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.4s ease;
}
.card:hover .card-thumb img { transform: scale(1.06); }
.card-type-icon {
  position: absolute; top: 10px; left: 10px;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: rgba(11,14,20,0.65);
  backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center;
  color: var(--accent-cyan);
}
.card-new-badge {
  position: absolute; top: 10px; right: 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.08em;
  padding: 4px 8px;
  border-radius: 4px;
  background: var(--danger);
  color: #fff;
}
.card-play {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  transition: opacity 0.25s ease;
  background: rgba(11,14,20,0.25);
}
.card:hover .card-play { opacity: 1; }
.card-play svg { width: 48px; height: 48px; filter: drop-shadow(0 4px 12px rgba(0,0,0,0.5)); }

/* card-level timecode chip: signature motif echoed at small scale */
.card-timecode {
  position: absolute; bottom: 0; left: 0; right: 0;
  padding: 6px 10px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent-cyan);
  background: linear-gradient(0deg, rgba(0,0,0,0.85), transparent);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  display: flex;
  justify-content: space-between;
  letter-spacing: 0.02em;
}
.card:hover .card-timecode { opacity: 1; transform: translateY(0); }

.card-body { padding: 14px 16px 18px; }
.card-category {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
  margin-bottom: 6px;
  display: block;
}
.card-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  margin: 0 0 4px;
}
.card-meta {
  font-size: 12.5px;
  color: var(--ink-secondary);
}

/* =========================================================================
   Watermark + signature "provenance timecode" strip
   ========================================================================= */
.protected-media {
  position: relative;
  overflow: hidden;
  background: #000;
}
.watermark-overlay {
  position: absolute; inset: 0;
  pointer-events: none;
  display: flex;
  flex-wrap: wrap;
  align-content: space-around;
  justify-content: space-around;
  opacity: 0.28;
  z-index: 5;
}
.watermark-tile {
  transform: rotate(-24deg);
  font-family: var(--font-mono);
  font-size: 11px;
  color: #ffffff;
  white-space: nowrap;
  padding: 22px;
  text-shadow: 0 1px 3px rgba(0,0,0,0.6);
}
.watermark-badge {
  position: absolute;
  bottom: 14px;
  left: 14px;
  z-index: 6;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: var(--radius-sm);
  background: rgba(11, 14, 20, 0.55);
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255,255,255,0.14);
  font-family: var(--font-mono);
  font-size: 11px;
  pointer-events: none;
}
.watermark-badge strong { color: #fff; font-weight: 600; }
.watermark-badge span { color: var(--accent-cyan); }

/* Signature element: broadcast-style timecode strip under the media viewer */
.timecode-strip {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  background: #05070b;
  border-top: 1px solid rgba(0, 180, 216, 0.25);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--accent-cyan);
  letter-spacing: 0.03em;
}
.timecode-strip .tc-left { display: flex; align-items: center; gap: 10px; }
.timecode-strip .rec-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--danger);
  animation: rec-pulse 1.6s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes rec-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}
.timecode-strip .tc-perf {
  display: flex; gap: 4px;
  opacity: 0.5;
}
.timecode-strip .tc-perf span {
  width: 4px; height: 4px;
  border-radius: 50%;
  background: var(--accent-cyan);
}
.timecode-strip .tc-right { color: var(--ink-tertiary); }

/* =========================================================================
   Detail page: two-column layout
   ========================================================================= */
.detail-wrap {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 1fr);
  gap: 40px;
  padding: 32px 32px 80px;
  max-width: var(--container-w);
  margin: 0 auto;
  align-items: start;
}

.breadcrumb {
  grid-column: 1 / -1;
  font-size: 12.5px;
  color: var(--ink-tertiary);
  margin-bottom: 4px;
}
.breadcrumb a:hover { color: var(--accent-cyan); }

.media-column { position: sticky; top: 90px; }

.media-frame {
  position: relative;
  width: 100%;
  max-height: var(--max-media-height);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-elevated);
}
.media-viewport {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  max-height: calc(var(--max-media-height) - 40px);
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.media-viewport video,
.media-viewport img {
  width: 100%; height: 100%;
  object-fit: contain;
  background: #000;
  user-select: none;
  -webkit-user-drag: none;
}
.media-viewport[data-ratio="4:3"] { aspect-ratio: 4 / 3; }
.media-viewport[data-ratio="1:1"] { aspect-ratio: 1 / 1; }
.media-viewport[data-ratio="3:2"] { aspect-ratio: 3 / 2; }

.media-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: rgba(11,14,20,0.55);
  border: 1px solid rgba(255,255,255,0.18);
  backdrop-filter: blur(6px);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s ease, border-color 0.2s ease;
}
.media-nav-btn:hover { background: rgba(0,102,255,0.35); border-color: var(--accent-cyan); }
.media-nav-btn.prev { left: 14px; }
.media-nav-btn.next { right: 14px; }
.media-nav-btn:disabled { opacity: 0.3; }

.media-dots {
  position: absolute;
  bottom: 14px; left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex; gap: 6px;
}
.media-dots button {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.4);
  border: none;
  padding: 0;
}
.media-dots button.active { background: var(--accent-cyan); width: 18px; border-radius: 3px; }

.protection-note {
  margin-top: 12px;
  font-size: 12px;
  color: var(--ink-tertiary);
  display: flex;
  align-items: center;
  gap: 8px;
}

/* --- Purchase / info column --- */
.info-column { padding-top: 4px; }
.info-owner {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  font-size: 13px;
  color: var(--ink-secondary);
}
.info-owner strong { color: var(--ink-primary); }

.info-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(24px, 2.4vw, 32px);
  line-height: 1.15;
  margin: 0 0 12px;
}
.info-tags { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 22px; }
.tag {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 999px;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  color: var(--ink-secondary);
}

.purchase-panel {
  background: var(--bg-surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 22px;
  margin-bottom: 24px;
}
.panel-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
  margin-bottom: 12px;
  display: block;
}
.format-options {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}
.format-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.format-option:hover { border-color: rgba(0,180,216,0.5); }
.format-option input { accent-color: var(--accent-cyan); }
.format-option.selected {
  border-color: var(--accent-cyan);
  background: linear-gradient(180deg, rgba(0,180,216,0.1), rgba(0,102,255,0.05));
}
.format-option label {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  flex: 1;
}
.format-name { font-weight: 700; font-size: 14px; }
.format-res { font-size: 12px; color: var(--ink-tertiary); display: block; }
.format-price { font-family: var(--font-mono); font-weight: 600; font-size: 14px; color: var(--accent-cyan); }

.price-total {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-top: 16px;
  border-top: 1px dashed var(--line-strong);
}
.price-total .label { color: var(--ink-secondary); font-size: 13px; }
.price-total .value { font-family: var(--font-mono); font-size: 24px; font-weight: 600; }

.panel-actions { display: flex; flex-direction: column; gap: 10px; }

.specs-table {
  margin-bottom: 24px;
}
.specs-table table td {
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
}
.specs-table table td:first-child {
  color: var(--ink-tertiary);
  width: 42%;
  font-family: var(--font-mono);
  font-size: 12px;
}
.specs-table table tr:last-child td { border-bottom: none; }

.description-block { margin-bottom: 24px; }
.description-block p { color: var(--ink-secondary); font-size: 14px; line-height: 1.7; }

.legal-block {
  background: var(--bg-elevated);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 18px;
  font-size: 12px;
  color: var(--ink-tertiary);
  line-height: 1.7;
}
.legal-block strong { color: var(--ink-secondary); }
.legal-block a { color: var(--accent-cyan); }

/* =========================================================================
   Footer
   ========================================================================= */
.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 80px;
  padding: 40px 32px 32px;
}
.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 40px;
  flex-wrap: wrap;
  max-width: var(--container-w);
  margin: 0 auto 28px;
}
.footer-brand { max-width: 360px; }
.footer-brand p { color: var(--ink-tertiary); font-size: 13px; line-height: 1.7; }
.footer-cols { display: flex; gap: 56px; flex-wrap: wrap; }
.footer-col h4 {
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
  margin: 0 0 12px;
}
.footer-col a {
  display: block;
  font-size: 13px;
  color: var(--ink-secondary);
  margin-bottom: 8px;
}
.footer-col a:hover { color: var(--accent-cyan); }
.footer-legal {
  max-width: var(--container-w);
  margin: 0 auto;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 11.5px;
  color: var(--ink-tertiary);
  line-height: 1.8;
}
.footer-legal strong { color: var(--ink-secondary); }

/* =========================================================================
   Admin
   ========================================================================= */
.admin-shell { min-height: 100vh; }
.admin-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.admin-login-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow-elevated);
}
.admin-login-card h1 {
  font-family: var(--font-display);
  font-size: 20px;
  margin: 18px 0 6px;
}
.admin-login-card .sub { color: var(--ink-tertiary); font-size: 13px; margin-bottom: 24px; }
.field { margin-bottom: 16px; }
.field label {
  display: block;
  font-size: 12.5px;
  color: var(--ink-secondary);
  margin-bottom: 6px;
  font-weight: 600;
}
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  color: var(--ink-primary);
  font-size: 13.5px;
  outline: none;
  transition: border-color 0.2s ease;
}
.field input:focus,
.field select:focus,
.field textarea:focus { border-color: var(--accent-cyan); }
.field-hint { font-size: 11.5px; color: var(--ink-tertiary); margin-top: 5px; }
.form-error {
  background: rgba(255,59,92,0.12);
  border: 1px solid rgba(255,59,92,0.4);
  color: #ff8fa3;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  margin-bottom: 16px;
}
.demo-banner {
  background: linear-gradient(120deg, rgba(255,176,32,0.15), rgba(255,59,92,0.1));
  border: 1px solid rgba(255,176,32,0.4);
  color: #ffd58a;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  font-size: 12.5px;
  margin-bottom: 16px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 28px;
  border-bottom: 1px solid var(--line);
  background: var(--bg-surface);
  position: sticky; top: 0; z-index: 20;
}
.admin-tabs { display: flex; gap: 6px; }
.admin-tab {
  padding: 9px 16px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-secondary);
  background: transparent;
  border: 1px solid transparent;
}
.admin-tab.active { background: var(--bg-elevated); color: var(--ink-primary); border-color: var(--line-strong); }

.admin-body { padding: 28px; max-width: 1280px; margin: 0 auto; }
.admin-section-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  margin: 0 0 4px;
}
.admin-section-sub { color: var(--ink-tertiary); font-size: 13px; margin-bottom: 20px; }

.today-panel {
  background: linear-gradient(160deg, rgba(255,59,92,0.08), rgba(255,176,32,0.04));
  border: 1px solid rgba(255,59,92,0.35);
  border-radius: var(--radius-lg);
  padding: 20px;
  margin-bottom: 32px;
}
.today-panel-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.today-panel-head .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--danger);
  animation: rec-pulse 1.6s ease-in-out infinite;
}
.today-panel-head h3 { font-family: var(--font-display); font-size: 14px; margin: 0; letter-spacing: 0.04em; }
.today-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 12px;
}
.today-empty { color: var(--ink-tertiary); font-size: 13px; }
.today-card {
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  padding: 12px;
  display: flex; gap: 10px; align-items: center;
}
.today-card img { width: 46px; height: 46px; border-radius: 6px; object-fit: cover; flex-shrink: 0; }
.today-card .t-title { font-size: 12.5px; font-weight: 600; margin-bottom: 2px; }
.today-card .t-meta { font-size: 11px; color: var(--ink-tertiary); font-family: var(--font-mono); }

.data-table-wrap {
  background: var(--bg-surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.data-table { width: 100%; }
.data-table th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--ink-tertiary);
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-strong);
  background: var(--bg-elevated);
}
.data-table td {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 13px;
  vertical-align: middle;
}
.data-table tr:last-child td { border-bottom: none; }
.row-thumb { display: flex; align-items: center; gap: 10px; }
.row-thumb img { width: 40px; height: 40px; border-radius: 6px; object-fit: cover; }
.row-title { font-weight: 600; }
.row-slug { font-family: var(--font-mono); font-size: 11px; color: var(--ink-tertiary); }
.badge {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 4px;
  display: inline-block;
}
.badge-new { background: var(--danger); color: #fff; }
.badge-video { background: rgba(0,102,255,0.18); color: #6fa8ff; }
.badge-image { background: rgba(0,180,216,0.18); color: #5fd6ee; }
.date-edit {
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  color: var(--ink-primary);
  border-radius: 6px;
  padding: 6px 8px;
  font-size: 12px;
  font-family: var(--font-mono);
}
.row-actions { display: flex; gap: 6px; }
.icon-btn {
  width: 30px; height: 30px;
  border-radius: 6px;
  border: 1px solid var(--line-strong);
  background: var(--bg-elevated);
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-secondary);
}
.icon-btn:hover { border-color: var(--accent-cyan); color: var(--accent-cyan); }
.icon-btn.danger:hover { border-color: var(--danger); color: var(--danger); }

.upload-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: start;
}
.upload-card {
  background: var(--bg-surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.pricing-row { display: grid; grid-template-columns: 1fr 1fr 1fr auto; gap: 8px; margin-bottom: 8px; align-items: center; }
.dropzone {
  border: 1.5px dashed var(--line-strong);
  border-radius: var(--radius-md);
  padding: 28px;
  text-align: center;
  color: var(--ink-tertiary);
  font-size: 13px;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.dropzone.drag { border-color: var(--accent-cyan); background: rgba(0,180,216,0.06); }
.file-chip-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.file-chip {
  font-family: var(--font-mono);
  font-size: 11px;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  padding: 4px 8px;
  border-radius: 4px;
}

.toast {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 100;
  background: var(--bg-elevated);
  border: 1px solid var(--line-strong);
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-elevated);
  font-size: 13px;
  max-width: 320px;
  animation: toast-in 0.25s ease both;
}
.toast.success { border-color: rgba(0,214,143,0.5); }
.toast.error { border-color: rgba(255,59,92,0.5); }
@keyframes toast-in {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* =========================================================================
   Responsive
   ========================================================================= */
@media (max-width: 980px) {
  .detail-wrap { grid-template-columns: 1fr; }
  .media-column { position: static; }
  .upload-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .site-header { flex-wrap: wrap; padding: 14px 18px; }
  .main-nav { order: 3; width: 100%; justify-content: center; }
  .search-box { max-width: 160px; }
  .hero { margin: 16px 16px 0; min-height: 52vh; }
  .hero-content { padding: 28px 24px; }
  .section { padding: 40px 18px 0; }
  .detail-wrap { padding: 20px 18px 60px; gap: 24px; }
  .card { width: 240px; }
  .footer-grid { flex-direction: column; }
  .admin-body { padding: 18px; }
  .pricing-row { grid-template-columns: 1fr 1fr; }
}
