/* =============================================================================
 * EduLMS Mario Bros Theme — Custom CSS
 * Built from Stitch design system
 * ============================================================================= */

/* ---------- Design Tokens (CSS variables) ---------- */
:root {
  /* Primary Mario Red */
  --mario-red: #be000c;
  --mario-red-bright: #e52521;
  --mario-red-light: #ffb4aa;
  --mario-red-dark: #930007;

  /* Pipe Green */
  --pipe-green: #006d33;
  --pipe-green-bright: #75f999;
  --pipe-green-dark: #005225;

  /* Coin Gold */
  --coin-gold: #ebc300;
  --coin-gold-bright: #ffe179;

  /* Sky Blue (info) */
  --sky-blue: #5C94FC;

  /* Goomba Brown (text/secondary) */
  --goomba-brown: #5d3f3b;

  /* Brick Tan (surface) */
  --brick-tan: #fff8f7;
  --brick-tan-dim: #f4d3ce;
  --brick-tan-bright: #fddbd6;

  /* Castle Stone (dark surface) */
  --castle-stone: #291715;
  --castle-stone-light: #402b29;

  /* Neutrals */
  --surface: #fff8f7;
  --on-surface: #291715;
  --on-surface-variant: #5d3f3b;
  --outline: #926f6a;
  --outline-variant: #e7bdb7;

  /* Status */
  --error: #ba1a1a;
  --error-container: #ffdad6;

  /* Spacing */
  --unit: 4px;
  --gutter: 24px;
  --margin-mobile: 16px;
  --margin-desktop: 48px;
  --container-max: 1280px;

  /* Borders */
  --border-thin: 2px;
  --border-thick: 3px;
  --border-chunky: 4px;
}

/* ---------- Font imports (loaded by layouts, fallback here) ---------- */
.font-pixel  { font-family: 'Press Start 2P', cursive, monospace; }
.font-body   { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }
.font-mono   { font-family: 'JetBrains Mono', 'Menlo', 'Consolas', monospace; }

/* ---------- Headlines (pixel font for H1/H2) ---------- */
.h1 {
  font-family: 'Press Start 2P', cursive;
  font-size: 32px;
  font-weight: 400;
  line-height: 1.2;
  letter-spacing: -2%;
  color: var(--on-surface);
}
.h2 {
  font-family: 'Press Start 2P', cursive;
  font-size: 24px;
  font-weight: 400;
  line-height: 1.2;
  color: var(--on-surface);
}
.h3 {
  font-family: 'Press Start 2P', cursive;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
  color: var(--on-surface);
}

/* ---------- Body text ---------- */
.body-lg { font-family: 'Inter', sans-serif; font-size: 18px; line-height: 1.6; color: var(--on-surface); }
.body-md { font-family: 'Inter', sans-serif; font-size: 16px; line-height: 1.5; color: var(--on-surface); }
.body-sm { font-family: 'Inter', sans-serif; font-size: 14px; line-height: 1.5; color: var(--on-surface); }

/* ---------- Numeric ---------- */
.numeric-display {
  font-family: 'JetBrains Mono', monospace;
  font-size: 20px;
  font-weight: 700;
  line-height: 1;
  color: var(--on-surface);
}
.label-caps {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* =============================================================================
 * Page Backgrounds
 * ============================================================================= */

/* Sky Blue with cloud polka dots (default public bg) */
.bg-sky {
  background-color: var(--sky-blue);
  background-image: radial-gradient(circle, rgba(255,255,255,0.6) 4px, transparent 5px);
  background-size: 32px 32px;
}

/* Brick pattern (auth + admin pages) */
.bg-bricks {
  background-color: var(--brick-tan);
  background-image:
    repeating-linear-gradient(0deg, transparent 0 24px, rgba(139,69,19,0.12) 24px 25px),
    repeating-linear-gradient(90deg, transparent 0 48px, rgba(139,69,19,0.12) 48px 49px);
}

/* Castle dark (admin) */
.bg-castle {
  background-color: var(--castle-stone);
  background-image:
    radial-gradient(circle, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 24px 24px;
  color: #fff8f7;
}

/* Grass strip (public pages footer) */
.grass-strip {
  background: linear-gradient(180deg, var(--pipe-green) 0%, #008f3d 100%);
  position: relative;
  height: 28px;
}
.grass-strip::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 0;
  right: 0;
  height: 10px;
  background-image: linear-gradient(135deg, transparent 33%, var(--pipe-green) 33%, var(--pipe-green) 66%, transparent 66%),
                    linear-gradient(225deg, transparent 33%, var(--pipe-green) 33%, var(--pipe-green) 66%, transparent 66%);
  background-size: 24px 12px;
  background-repeat: repeat-x;
  background-position: top;
}

/* Coin row separator */
.coin-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 24px 0;
}
.coin-row::before,
.coin-row::after {
  content: '';
  flex: 1;
  height: 2px;
  background: var(--outline-variant);
}
.coin-row-coins {
  font-size: 18px;
  letter-spacing: 4px;
}

/* =============================================================================
 * Buttons — Chunky 3D retro
 * ============================================================================= */

/* Primary button — Mario Red */
.btn-primary {
  background: var(--mario-red);
  color: white;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 14px;
  padding: 12px 24px;
  border: 3px solid var(--mario-red-dark);
  border-radius: 4px;
  box-shadow: 0 4px 0 var(--mario-red-dark);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: transform 80ms ease-out, box-shadow 80ms ease-out;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.btn-primary:hover {
  background: var(--mario-red-bright);
}
.btn-primary:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 var(--mario-red-dark);
}
.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  background: #999;
  border-color: #666;
  box-shadow: 0 4px 0 #666;
}

/* Pixel-art primary (uses Press Start 2P font) — for big CTAs */
.btn-pixel {
  font-family: 'Press Start 2P', cursive;
  font-size: 12px;
  padding: 16px 32px;
  letter-spacing: 0;
}

/* Secondary — Pipe Green */
.btn-secondary {
  background: var(--pipe-green);
  color: white;
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  padding: 10px 20px;
  border: 3px solid var(--pipe-green-dark);
  border-radius: 4px;
  box-shadow: 0 4px 0 var(--pipe-green-dark);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: transform 80ms, box-shadow 80ms;
}
.btn-secondary:hover { background: var(--pipe-green-bright); }
.btn-secondary:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 var(--pipe-green-dark);
}

/* Outline / ghost */
.btn-outline {
  background: transparent;
  color: var(--mario-red);
  border: 2px solid var(--mario-red);
  font-weight: 700;
  padding: 8px 16px;
  border-radius: 4px;
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: background 100ms;
}
.btn-outline:hover {
  background: var(--mario-red);
  color: white;
}

/* Ghost (text only) */
.btn-ghost {
  background: transparent;
  color: var(--mario-red);
  font-weight: 700;
  padding: 8px 12px;
  border: none;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* Buy button (green, like Stitch) */
.btn-buy {
  background: var(--pipe-green);
  color: white;
  font-family: 'Press Start 2P', cursive;
  font-size: 11px;
  padding: 12px 24px;
  border: 3px solid var(--pipe-green-dark);
  border-radius: 4px;
  box-shadow: 0 4px 0 var(--pipe-green-dark);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0;
  transition: transform 80ms, box-shadow 80ms;
}
.btn-buy:active {
  transform: translateY(4px);
  box-shadow: 0 0 0 var(--pipe-green-dark);
}

/* =============================================================================
 * Inputs & Forms
 * ============================================================================= */

.input-field {
  width: 100%;
  padding: 12px 14px 12px 44px;
  border: 2px solid var(--goomba-brown);
  border-radius: 4px;
  background: white;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--on-surface);
  position: relative;
}
.input-field:focus {
  outline: none;
  border-color: var(--sky-blue);
  box-shadow: 0 0 0 3px rgba(92, 148, 252, 0.3);
}
.input-field::placeholder { color: #999; }

.input-wrap {
  position: relative;
  margin-bottom: 16px;
}
.input-wrap .input-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--goomba-brown);
  pointer-events: none;
  font-size: 18px;
}
.input-wrap .input-icon-right {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--goomba-brown);
  cursor: pointer;
  font-size: 18px;
}
.input-label {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  font-weight: 600;
  color: var(--on-surface);
  margin-bottom: 6px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.input-required::after {
  content: ' ⚡';
  color: var(--coin-gold);
}

.field-error {
  color: var(--error);
  font-size: 12px;
  margin-top: 4px;
  font-family: 'Inter', sans-serif;
}

/* =============================================================================
 * Cards
 * ============================================================================= */

.card {
  background: white;
  border: 2px solid var(--goomba-brown);
  border-radius: 12px;
  box-shadow: 4px 4px 0 rgba(45, 23, 21, 0.15);
  overflow: hidden;
  transition: transform 100ms, box-shadow 100ms;
}
.card:hover {
  transform: translateY(-2px);
  box-shadow: 6px 6px 0 rgba(45, 23, 21, 0.15);
}

/* Course/module card with cover */
.module-card {
  background: white;
  border: 2px solid var(--goomba-brown);
  border-radius: 12px;
  box-shadow: 4px 4px 0 rgba(45, 23, 21, 0.15);
  overflow: hidden;
  position: relative;
  transition: transform 100ms;
}
.module-card:hover { transform: translateY(-2px); }
.module-card-cover {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: var(--brick-tan-dim);
  overflow: hidden;
}
.module-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.module-card-cover-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 48px;
  background: linear-gradient(135deg, var(--brick-tan-dim), var(--brick-tan-bright));
}
.module-card-owned {
  position: absolute;
  top: 12px;
  right: 12px;
  background: var(--pipe-green);
  color: white;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 4px;
  text-transform: uppercase;
  box-shadow: 0 2px 0 var(--pipe-green-dark);
  transform: rotate(8deg);
}
.module-card-body {
  padding: 16px;
}
.module-card-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 16px;
  color: var(--on-surface);
  margin-bottom: 8px;
  line-height: 1.3;
}
.module-card-price {
  font-family: 'JetBrains Mono', monospace;
  font-size: 18px;
  font-weight: 700;
  color: var(--coin-gold);
  display: flex;
  align-items: center;
  gap: 6px;
}
.module-card-sections {
  font-size: 12px;
  color: var(--on-surface-variant);
  margin: 6px 0 12px;
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Owned card variant */
.module-card.owned { border-color: var(--pipe-green); }
.module-card.owned .module-card-owned-overlay {
  position: absolute;
  top: 12px;
  right: -32px;
  background: var(--pipe-green);
  color: white;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 40px;
  transform: rotate(35deg);
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 2px 0 var(--pipe-green-dark);
}

/* =============================================================================
 * KPI Cards (Admin Dashboard)
 * ============================================================================= */

.kpi-card {
  background: white;
  border: 2px solid var(--goomba-brown);
  border-radius: 12px;
  padding: 20px;
  position: relative;
  overflow: hidden;
  box-shadow: 4px 4px 0 rgba(45, 23, 21, 0.15);
}
.kpi-card-label {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  color: var(--on-surface-variant);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}
.kpi-card-value {
  font-family: 'JetBrains Mono', monospace;
  font-size: 32px;
  font-weight: 700;
  color: var(--on-surface);
  line-height: 1;
}
.kpi-card-icon {
  position: absolute;
  top: 12px;
  right: 12px;
  font-size: 28px;
  opacity: 0.3;
}

/* =============================================================================
 * Status Badges (pill shape)
 * ============================================================================= */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 12px;
  border-radius: 999px;
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 2px solid;
}
.badge-pending  { background: #fff7e0; color: #b45309; border-color: #fde68a; }
.badge-approved { background: var(--pipe-green-bright); color: var(--pipe-green-dark); border-color: var(--pipe-green-dark); }
.badge-rejected { background: #fee2e2; color: var(--error); border-color: #fca5a5; }
.badge-expired  { background: #f3f4f6; color: #4b5563; border-color: #d1d5db; }
.badge-draft    { background: #f3f4f6; color: #6b7280; border-color: #d1d5db; }
.badge-published{ background: var(--pipe-green-bright); color: var(--pipe-green-dark); border-color: var(--pipe-green-dark); }

/* =============================================================================
 * Filter Chips (Admin Orders, Katalog)
 * ============================================================================= */

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  border: 2px solid var(--goomba-brown);
  border-radius: 999px;
  background: white;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 13px;
  color: var(--on-surface);
  cursor: pointer;
  transition: background 100ms, color 100ms;
}
.filter-chip:hover { background: var(--brick-tan); }
.filter-chip.active {
  background: var(--mario-red);
  color: white;
  border-color: var(--mario-red-dark);
  box-shadow: 0 2px 0 var(--mario-red-dark);
}

/* =============================================================================
 * Navigation
 * ============================================================================= */

.nav-top {
  background: white;
  border-top: 4px solid var(--mario-red);
  border-bottom: 2px solid var(--brick-tan-bright);
  padding: 12px 0;
  position: sticky;
  top: 0;
  z-index: 50;
}
.nav-top-logo {
  font-family: 'Press Start 2P', cursive;
  font-size: 20px;
  color: var(--mario-red);
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
}
.nav-link {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 14px;
  color: var(--on-surface);
  padding: 8px 16px;
  border-radius: 8px;
  text-decoration: none;
  transition: background 100ms;
}
.nav-link:hover { background: var(--brick-tan); }
.nav-link.active {
  background: var(--mario-red);
  color: white;
}

/* Mobile bottom nav */
.nav-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--castle-stone);
  display: flex;
  justify-content: space-around;
  padding: 8px 0 12px;
  z-index: 50;
  border-top: 3px solid var(--mario-red);
}
.nav-bottom-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  color: var(--brick-tan);
  text-decoration: none;
  font-size: 10px;
  font-family: 'Inter', sans-serif;
  gap: 4px;
  padding: 4px 8px;
  border-radius: 8px;
  flex: 1;
}
.nav-bottom-item.active {
  background: var(--mario-red);
  color: white;
}
.nav-bottom-item span.material-symbols-outlined {
  font-size: 24px;
}

/* =============================================================================
 * Admin Sidebar (Dark)
 * ============================================================================= */

.admin-sidebar {
  background: var(--castle-stone);
  background-image:
    radial-gradient(circle, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 16px 16px;
  width: 260px;
  min-height: 100vh;
  border-right: 4px solid var(--mario-red);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
}
.admin-sidebar-logo {
  font-family: 'Press Start 2P', cursive;
  font-size: 16px;
  color: var(--mario-red);
  padding: 20px;
  text-align: center;
  border-bottom: 2px solid var(--castle-stone-light);
}
.admin-sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.admin-sidebar-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 16px;
  border-radius: 8px;
  color: var(--brick-tan);
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  font-size: 14px;
  transition: background 100ms;
}
.admin-sidebar-link:hover {
  background: var(--castle-stone-light);
}
.admin-sidebar-link.active {
  background: var(--mario-red);
  color: white;
}
.admin-sidebar-link span.material-symbols-outlined { font-size: 20px; }

.admin-sidebar-footer {
  border-top: 1px solid var(--castle-stone-light);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

/* =============================================================================
 * Hero
 * ============================================================================= */

.hero {
  background: linear-gradient(135deg, #5c94fc 0%, #4a8afc 100%);
  background-image:
    radial-gradient(circle, rgba(255,255,255,0.4) 3px, transparent 4px),
    linear-gradient(135deg, #5c94fc 0%, #4a8afc 100%);
  background-size: 32px 32px, 100% 100%;
  color: white;
  padding: 80px 24px;
  border-radius: 0 0 24px 24px;
  position: relative;
  text-align: center;
  overflow: hidden;
  border-bottom: 4px solid var(--mario-red);
}
.hero-title {
  font-family: 'Press Start 2P', cursive;
  font-size: 32px;
  line-height: 1.3;
  color: white;
  margin-bottom: 24px;
  text-shadow: 4px 4px 0 var(--mario-red-dark);
}
.hero-subtitle {
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  color: white;
  margin-bottom: 32px;
  opacity: 0.95;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* =============================================================================
 * Tables (Admin)
 * ============================================================================= */

.table {
  width: 100%;
  background: white;
  border: 2px solid var(--goomba-brown);
  border-radius: 12px;
  overflow: hidden;
  border-collapse: collapse;
}
.table thead {
  background: var(--castle-stone);
  color: white;
}
.table th {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 14px 16px;
  text-align: left;
}
.table td {
  padding: 14px 16px;
  border-top: 1px solid var(--outline-variant);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--on-surface);
}
.table tbody tr:hover {
  background: var(--brick-tan);
}

/* =============================================================================
 * Form Containers (Login, Settings)
 * ============================================================================= */

.input-help {
  font-family: 'JetBrains Mono', monospace;
  font-size: 11px;
  color: var(--goomba-brown);
  margin-top: 4px;
  display: flex;
  align-items: center;
  gap: 4px;
}
.input-help::before {
  content: '💡';
  font-size: 12px;
  font-family: inherit;
}

.form-error-summary {
  background: #fee2e2;
  border: 2px solid #fca5a5;
  border-left: 6px solid var(--mario-red);
  border-radius: 8px;
  padding: 16px 20px;
  margin-bottom: 20px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  box-shadow: 4px 4px 0 var(--mario-red-dark);
  animation: shake 0.4s ease-out;
}
.form-error-summary-icon {
  font-size: 32px;
  flex-shrink: 0;
}
.form-error-summary-title {
  font-family: 'Press Start 2P', cursive;
  font-size: 12px;
  color: var(--mario-red);
  margin-bottom: 8px;
  letter-spacing: 1px;
}
.form-error-summary-body {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: #991b1b;
  line-height: 1.5;
}
.form-error-summary-list {
  margin: 8px 0 0 0;
  padding-left: 20px;
  list-style: '🎯 ';
}
.form-error-summary-list li {
  margin: 2px 0;
}
.form-error-summary-list strong {
  color: var(--mario-red);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}

@keyframes flash-error {
  0% { box-shadow: 0 0 0 4px rgba(229, 37, 33, 0.6); }
  100% { box-shadow: 0 0 0 4px rgba(229, 37, 33, 0); }
}
.input-error, .input-field.input-error {
  animation: flash-error 1s ease-out;
}

.auth-card {
  background: white;
  border: 3px solid var(--mario-red);
  border-radius: 4px;
  box-shadow: 8px 8px 0 rgba(0,0,0,0.15);
  overflow: hidden;
  max-width: 460px;
  margin: 0 auto;
  padding: 0;
}
.auth-card-top-stripe {
  height: 12px;
  background: var(--mario-red);
}
.auth-card-body {
  padding: 40px 32px 32px;
  position: relative;
}
.auth-card-logo {
  text-align: center;
  margin-bottom: 24px;
  font-family: 'Press Start 2P', cursive;
  font-size: 28px;
  color: var(--mario-red);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.auth-card-title {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  font-size: 22px;
  text-align: center;
  margin-bottom: 24px;
  color: var(--on-surface);
}
.auth-divider {
  border-top: 2px dashed var(--outline-variant);
  margin: 24px 0;
}
.auth-footer {
  text-align: center;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--on-surface-variant);
}
.auth-footer a { color: var(--mario-red); font-weight: 600; }

/* =============================================================================
 * Toast / Flash
 * ============================================================================= */

.toast {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 12px;
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  border: 2px solid;
  display: flex;
  align-items: center;
  gap: 8px;
}
.toast-success { background: var(--pipe-green-bright); color: var(--pipe-green-dark); border-color: var(--pipe-green); }
.toast-error   { background: #fee2e2; color: var(--error); border-color: #fca5a5; }
.toast-info    { background: #dbeafe; color: #1e3a8a; border-color: #93c5fd; }

/* =============================================================================
 * Responsive Helpers
 * ============================================================================= */

@media (max-width: 768px) {
  .h1 { font-size: 20px; }
  .h2 { font-size: 16px; }
  .hero { padding: 40px 16px; }
  .hero-title { font-size: 18px; }
  .hero-subtitle { font-size: 14px; }
  .admin-sidebar {
    position: fixed;
    left: -260px;
    transition: left 200ms;
    z-index: 60;
  }
  .admin-sidebar.open { left: 0; }
  .kpi-card { padding: 12px; }
  .kpi-card-value { font-size: 20px; }
  .nav-bottom { display: flex; }
  body.has-bottom-nav { padding-bottom: 80px; }
  .desktop-only { display: none; }
}

@media (min-width: 769px) {
  .mobile-only { display: none; }
  .nav-bottom { display: none; }
}

/* ==========================================================================
   YouTube embed — NATIVE SIZE, breaks out of .card padding to fill container
   ========================================================================== */
.youtube-embed {
  position: relative;
  width: calc(100% + 48px);          /* break out of .card p-6 padding (24px x 2) */
  max-width: min(1400px, 100vw);     /* up to 1400px, but never overflow viewport */
  margin-left: -24px;                /* offset the +48px width to stay centered */
  margin-right: -24px;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 0.75rem;
  background: #000;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.22);
}
.youtube-embed iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}
@supports not (aspect-ratio: 16 / 9) {
  .youtube-embed { height: 0; padding-bottom: 56.25%; }
}
@media (max-width: 640px) {
  .youtube-embed {
    width: calc(100% + 32px);
    margin-left: -16px;
    margin-right: -16px;
    border-radius: 0.5rem;
  }
}