/* ================================================================
   SLING POST — DESIGN SYSTEM
   Brand: Deep navy base, electric blue accent (#2563EB → #3B82F6),
   warm off-white text, subtle slate surfaces.
   Type: 'Plus Jakarta Sans' display + 'Inter' body
   Signature: The slingshot arc path used in the logo,
   echoed as a decorative motion line in the hero.
================================================================ */

/* ── GOOGLE FONTS ── */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Inter:wght@300;400;500;600&display=swap');

/* ── TOKENS ── */
:root {
  /* Palette — pulled from Sling Post brand (navy + electric blue) */
  --ink:        #0E1117;
  --ink-2:      #161B25;
  --ink-3:      #1E2535;
  --blue:       #2563EB;
  --blue-h:     #3B82F6;
  --blue-soft:  #60A5FA;
  --blue-glow:  rgba(37,99,235,0.28);
  --teal:       #0D9488;   /* secondary accent for imagery/video tabs */
  --cream:      #F0F2F8;
  --cream-2:    #BCC4D8;
  --cream-3:    #6B7A99;
  --surface:    #19202E;
  --surface-2:  #212B3C;
  --border:     rgba(96,165,250,0.14);
  --border-h:   rgba(96,165,250,0.32);
  --white:      #FFFFFF;

  /* Type */
  --font-d: 'Plus Jakarta Sans', sans-serif;
  --font-b: 'Inter', sans-serif;

  /* Radius */
  --r-xs: 6px;
  --r-sm: 10px;
  --r-md: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --r-full: 999px;

  /* Transitions */
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t-fast: 0.15s var(--ease);
  --t-med:  0.28s var(--ease);
  --t-slow: 0.5s var(--ease);
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }
body {
  background: var(--ink);
  color: var(--cream);
  font-family: var(--font-b);
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}
[dir="rtl"] { font-family: var(--font-b), 'Segoe UI', Arial, sans-serif; }
img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; }

/* ── SUBTLE TEXTURE ── */
body::after {
  content: '';
  position: fixed; inset: 0; pointer-events: none; z-index: 9000;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.025'/%3E%3C/svg%3E");
  opacity: 0.6;
}

/* ── LAYOUT ── */
.wrap      { max-width: 1140px; margin: 0 auto; padding: 0 24px; }
.wrap-md   { max-width: 900px;  margin: 0 auto; padding: 0 24px; }
.wrap-sm   { max-width: 640px;  margin: 0 auto; padding: 0 24px; }
.section   { padding: 96px 0; }
.section-sm{ padding: 64px 0; }

/* ── TYPOGRAPHY ── */
h1,h2,h3,h4,h5 { font-family: var(--font-d); line-height: 1.1; font-weight: 700; }
.t-xl  { font-size: clamp(2.6rem, 5.5vw, 4.2rem); letter-spacing: -0.035em; }
.t-lg  { font-size: clamp(1.9rem, 3.5vw, 3rem);   letter-spacing: -0.025em; }
.t-md  { font-size: clamp(1.3rem, 2.2vw, 1.85rem); letter-spacing: -0.018em; }
.t-sm  { font-size: 1.125rem; }
.t-xs  { font-size: 0.875rem; }
.t-xxs { font-size: 0.75rem;  }
.label {
  font-size: 0.7rem; font-weight: 700; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--blue-soft);
}
.muted  { color: var(--cream-3); }
.muted2 { color: var(--cream-2); }

/* ── GRADIENT TEXT ── */
.grad {
  background: linear-gradient(120deg, var(--blue-h), var(--blue-soft));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 12px 24px; border-radius: var(--r-md);
  font-family: var(--font-d); font-size: 0.9rem; font-weight: 600;
  border: none; transition: var(--t-fast); white-space: nowrap;
  position: relative; overflow: hidden;
}
.btn::after {
  content: '';
  position: absolute; inset: 0;
  background: rgba(255,255,255,0.08);
  opacity: 0; transition: opacity var(--t-fast);
}
.btn:hover::after { opacity: 1; }
.btn:active { transform: scale(0.98); }

.btn-primary {
  background: var(--blue); color: #fff;
  box-shadow: 0 2px 20px var(--blue-glow);
}
.btn-primary:hover {
  background: var(--blue-h);
  box-shadow: 0 4px 36px rgba(37,99,235,0.45);
  transform: translateY(-1px);
}
.btn-outline {
  background: transparent; color: var(--cream-2);
  border: 1px solid var(--border-h);
}
.btn-outline:hover { border-color: var(--blue-h); color: var(--cream); background: rgba(37,99,235,0.08); }
.btn-ghost {
  background: var(--surface-2); color: var(--cream-2);
  border: 1px solid var(--border);
}
.btn-ghost:hover { background: var(--surface); color: var(--cream); }
.btn-danger { background: #DC2626; color: #fff; }
.btn-danger:hover { background: #EF4444; }
.btn-lg { padding: 15px 30px; font-size: 1rem; border-radius: var(--r-lg); }
.btn-sm { padding: 8px 16px; font-size: 0.8rem; }
.btn-xs { padding: 5px 12px; font-size: 0.75rem; border-radius: var(--r-sm); }

/* ── BADGE ── */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 11px; border-radius: var(--r-full);
  font-size: 0.72rem; font-weight: 600;
  background: rgba(37,99,235,0.15); color: var(--blue-soft);
  border: 1px solid rgba(37,99,235,0.25);
}
.badge-teal { background: rgba(13,148,136,0.15); color: #5EEAD4; border-color: rgba(13,148,136,0.25); }
.badge-amber { background: rgba(245,158,11,0.12); color: #FCD34D; border-color: rgba(245,158,11,0.22); }
.badge .live { width: 6px; height: 6px; border-radius: 50%; background: #22C55E; animation: blink 2s infinite; }

/* ── CARD ── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: 24px;
  transition: border-color var(--t-med), box-shadow var(--t-med), transform var(--t-med);
}
.card:hover {
  border-color: var(--border-h);
  box-shadow: 0 8px 40px rgba(0,0,0,0.3);
  transform: translateY(-2px);
}
.card-flat { box-shadow: none !important; transform: none !important; }

/* ── NAV ── */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 500;
  background: rgba(14,17,23,0.88);
  backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid var(--border);
  transition: background var(--t-med);
}
.nav.scrolled { background: rgba(14,17,23,0.97); }
.nav-inner {
  max-width: 1140px; margin: 0 auto; padding: 0 24px;
  height: 60px;
  display: flex; align-items: center; gap: 20px;
}
.nav-logo {
  display: flex; align-items: center; gap: 9px;
  flex-shrink: 0;
}
.nav-logo img { height: 28px; width: auto; }
.nav-logo-text {
  font-family: var(--font-d); font-weight: 800; font-size: 1.05rem;
  color: var(--white); letter-spacing: -0.01em;
}
.nav-logo-text em { font-style: italic; color: var(--blue-soft); }

.nav-links {
  display: flex; align-items: center; gap: 2px;
  flex: 1; margin-left: 8px;
}
[dir="rtl"] .nav-links { margin-left: 0; margin-right: 8px; }
.nav-link {
  padding: 7px 13px; border-radius: var(--r-sm);
  font-size: 0.855rem; font-weight: 500; color: var(--cream-3);
  transition: var(--t-fast);
}
.nav-link:hover { color: var(--cream); background: rgba(255,255,255,0.05); }
.nav-link.active { color: var(--blue-soft); }

.nav-right {
  display: flex; align-items: center; gap: 10px; flex-shrink: 0; margin-inline-start: auto;
}

/* ── APP SIDEBAR ── */
.app-sidebar {
  position: fixed; top: 60px; left: 0; bottom: 0;
  width: 60px; z-index: 400;
  background: var(--ink-2);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  padding: 12px 0; overflow: hidden;
  transition: width 0.2s cubic-bezier(0.4,0,0.2,1);
}
[dir="rtl"] .app-sidebar { left: auto; right: 0; border-right: none; border-left: 1px solid var(--border); }
.app-sidebar.expanded { width: 200px; }

.sb-toggle {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; margin: 0 12px 8px;
  background: none; border: none; border-radius: var(--r-sm);
  color: var(--cream-3); cursor: pointer; transition: var(--t-fast); flex-shrink: 0;
}
.sb-toggle:hover { color: var(--cream); background: var(--surface-2); }
.sb-toggle svg { width: 18px; height: 18px; transition: transform 0.2s; }
.app-sidebar.expanded .sb-toggle svg { transform: rotate(180deg); }
[dir="rtl"] .sb-toggle svg { transform: scaleX(-1); }
[dir="rtl"] .app-sidebar.expanded .sb-toggle svg { transform: scaleX(-1) rotate(180deg); }

.sb-nav { display: flex; flex-direction: column; gap: 2px; padding: 0 8px; flex: 1; }
.sb-item {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 12px; border-radius: var(--r-sm);
  color: var(--cream-3); font-size: 0.82rem; font-weight: 500;
  text-decoration: none; white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}
.sb-item:hover { color: var(--cream); background: var(--surface-2); }
.sb-item.active { color: var(--blue-soft); background: var(--blue-glow); }
.sb-item svg { width: 20px; height: 20px; flex-shrink: 0; }
.sb-label { opacity: 0; width: 0; overflow: hidden; transition: opacity 0.15s, width 0.15s; }
.app-sidebar.expanded .sb-label { opacity: 1; width: auto; }

.sb-footer { padding: 8px; margin-top: auto; }
.sb-upgrade {
  display: flex; align-items: center; justify-content: center; gap: 8px;
  width: 100%; padding: 10px 12px; border-radius: var(--r-sm);
  background: linear-gradient(135deg, var(--blue), var(--blue-h));
  color: #fff; font-size: 0.78rem; font-weight: 600;
  border: none; cursor: pointer; white-space: nowrap;
  transition: filter 0.15s;
}
.sb-upgrade:hover { filter: brightness(1.1); }
.sb-upgrade svg { width: 16px; height: 16px; flex-shrink: 0; }
.sb-upgrade-label { opacity: 0; width: 0; overflow: hidden; transition: opacity 0.15s, width 0.15s; }
.app-sidebar.expanded .sb-upgrade-label { opacity: 1; width: auto; }

.has-sidebar { padding-left: 60px; }
[dir="rtl"] .has-sidebar { padding-left: 0; padding-right: 60px; }
.has-sidebar.sb-wide { padding-left: 200px; }
[dir="rtl"] .has-sidebar.sb-wide { padding-left: 0; padding-right: 200px; }
.has-sidebar .nav-inner { max-width: none; }

@media (max-width: 820px) {
  .app-sidebar {
    transform: translateX(-100%);
    width: 240px; z-index: 600;
    box-shadow: 4px 0 24px rgba(0,0,0,0.3);
  }
  [dir="rtl"] .app-sidebar { transform: translateX(100%); }
  .app-sidebar.mobile-open { transform: translateX(0); }
  .app-sidebar.mobile-open .sb-label { opacity: 1; width: auto; }
  .app-sidebar.mobile-open .sb-upgrade-label { opacity: 1; width: auto; }
  .has-sidebar { padding-left: 0 !important; padding-right: 0 !important; }
  .sb-overlay {
    position: fixed; inset: 0; z-index: 599;
    background: rgba(0,0,0,0.4); display: none;
  }
  .sb-overlay.visible { display: block; }
}

/* ── PROFILE DROPDOWN (shared) ── */
.sp-profile-wrap { position: relative; }
.sp-avatar-toggle { background: none; border: none; cursor: pointer; padding: 2px; border-radius: 50%; transition: box-shadow 0.15s; }
.sp-avatar-toggle:hover { box-shadow: 0 0 0 2px var(--blue); }
.sp-avatar { display: flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; overflow: hidden; background: var(--blue); color: #fff; font-weight: 600; font-size: 0.85rem; }
.sp-avatar--lg { width: 40px; height: 40px; font-size: 1rem; }
.sp-avatar-img { width: 100%; height: 100%; object-fit: cover; }
.sp-avatar-letter { line-height: 1; }
.sp-profile-dropdown {
  position: absolute; top: calc(100% + 8px); right: 0;
  background: var(--ink-2); border: 1px solid var(--border);
  border-radius: var(--r-lg); box-shadow: 0 8px 24px rgba(0,0,0,0.35);
  min-width: 240px; z-index: 999; overflow: hidden;
}
[dir="rtl"] .sp-profile-dropdown { right: auto; left: 0; }
.sp-profile-header { display: flex; align-items: center; gap: 0.75rem; padding: 1rem; border-bottom: 1px solid var(--border); }
.sp-profile-details { display: flex; flex-direction: column; gap: 0.15rem; overflow: hidden; }
.sp-profile-name { font-size: 0.85rem; font-weight: 600; color: var(--cream); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-profile-email { font-size: 0.72rem; color: var(--cream-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sp-profile-actions { padding: 0.5rem; }
.sp-profile-action-btn {
  display: flex; align-items: center; gap: 0.5rem; width: 100%;
  padding: 0.5rem 0.65rem; background: none; border: none;
  border-radius: var(--r-sm); color: var(--cream-3); font-size: 0.78rem;
  cursor: pointer; transition: background 0.15s;
}
.sp-profile-action-btn:hover { background: var(--surface-2); }
.sp-signout-btn { color: #FCA5A5; }
.sling-google-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 16px; background: var(--surface); border: 1px solid var(--border-h);
  border-radius: var(--r-sm); font-size: 0.82rem; font-weight: 600;
  color: var(--cream); cursor: pointer; transition: border-color 0.15s;
}
.sling-google-btn:hover { border-color: var(--blue-soft); }
.nav-credits {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 13px; border-radius: var(--r-full);
  background: var(--surface-2); border: 1px solid var(--border);
  font-size: 0.78rem; font-weight: 600; color: var(--cream-2);
}
.nav-credits .c-num { color: #FBBF24; }
.lang-btn {
  padding: 6px 12px; border-radius: var(--r-sm);
  background: var(--surface-2); border: 1px solid var(--border);
  font-size: 0.78rem; color: var(--cream-3); transition: var(--t-fast);
}
.lang-btn:hover { color: var(--cream); border-color: var(--border-h); }
.nav-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--blue-soft));
  display: flex; align-items: center; justify-content: center;
  font-size: 0.8rem; font-weight: 700; color: #fff; flex-shrink: 0;
  cursor: pointer;
}
.theme-btn {
  width: 34px; height: 34px; border-radius: var(--r-sm);
  background: var(--surface-2); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.95rem; color: var(--cream-3); transition: var(--t-fast);
}
.theme-btn:hover { color: var(--cream); border-color: var(--border-h); }

.nav-brand {
  display: flex; align-items: center; gap: 9px;
  flex-shrink: 0; text-decoration: none;
  font-family: var(--font-d); font-weight: 800; font-size: 1.05rem;
  color: var(--white); letter-spacing: -0.01em;
}
.nav-brand img { height: 28px; width: auto; }
.footer-inner { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

/* ── MOBILE NAV TOGGLE ── */
.nav-hamburger {
  display: none;
  flex-direction: column; gap: 5px;
  width: 34px; height: 34px;
  background: var(--surface-2); border: 1px solid var(--border);
  border-radius: var(--r-sm);
  align-items: center; justify-content: center;
}
.nav-hamburger span {
  width: 16px; height: 1.5px;
  background: var(--cream-2); border-radius: 2px;
  transition: var(--t-fast);
}

/* ── TABS ── */
.tabs {
  display: flex; border-bottom: 1px solid var(--border);
  overflow-x: auto; gap: 0;
}
.tab-btn {
  display: flex; align-items: center; gap: 7px;
  padding: 14px 20px; border-bottom: 2px solid transparent;
  font-size: 0.875rem; font-weight: 500; color: var(--cream-3);
  background: none; border-left: none; border-right: none; border-top: none;
  cursor: pointer; white-space: nowrap; transition: var(--t-fast);
}
.tab-btn:hover { color: var(--cream-2); }
.tab-btn.active { color: var(--blue-soft); border-bottom-color: var(--blue); }
.tab-new {
  font-size: 0.62rem; padding: 2px 7px; border-radius: 4px;
  background: #0D9488; color: #fff; font-weight: 700;
}

/* ── INPUT ── */
.input-box {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.input-box:focus-within {
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37,99,235,0.14);
}
.input-box textarea, .input-box input {
  width: 100%; background: none; border: none; outline: none;
  color: var(--cream); font-family: var(--font-b); font-size: 0.93rem;
  line-height: 1.65; padding: 16px 18px;
}
.input-box textarea::placeholder,
.input-box input::placeholder { color: var(--cream-3); }
.input-box textarea { resize: none; }
.input-foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: 9px 14px; border-top: 1px solid var(--border);
  background: rgba(14,17,23,0.4); border-radius: 0 0 var(--r-md) var(--r-md);
}

/* ── SELECT ── */
select.sp-select {
  background: var(--surface-2); border: 1px solid var(--border);
  color: var(--cream-2); padding: 9px 14px; border-radius: var(--r-sm);
  font-family: var(--font-b); font-size: 0.85rem; cursor: pointer;
  transition: border-color var(--t-fast);
}
select.sp-select:focus { border-color: var(--blue); outline: none; }

/* ── PLATFORM CHIPS ── */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 15px; border-radius: var(--r-full);
  font-size: 0.82rem; font-weight: 500; color: var(--cream-3);
  background: var(--surface-2); border: 1px solid var(--border);
  cursor: pointer; transition: var(--t-fast); user-select: none;
}
.chip:hover { border-color: var(--border-h); color: var(--cream-2); }
.chip.on {
  background: rgba(37,99,235,0.15); border-color: var(--blue);
  color: var(--blue-soft);
}

/* ── GENERATE BUTTON ── */
.gen-btn {
  width: 100%; padding: 17px;
  background: var(--blue); color: #fff;
  border: none; border-radius: var(--r-md);
  font-family: var(--font-d); font-size: 1.05rem; font-weight: 700;
  letter-spacing: 0.01em; cursor: pointer;
  transition: var(--t-fast);
  display: flex; align-items: center; justify-content: center; gap: 10px;
  box-shadow: 0 4px 28px rgba(37,99,235,0.38);
  position: relative; overflow: hidden;
}
.gen-btn::before {
  content: '';
  position: absolute; top: -50%; left: -75%;
  width: 60%; height: 200%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.12), transparent);
  transform: skewX(-15deg);
  transition: left 0.6s var(--ease);
}
.gen-btn:hover { background: var(--blue-h); box-shadow: 0 6px 42px rgba(37,99,235,0.5); transform: translateY(-1px); }
.gen-btn:hover::before { left: 120%; }
.gen-btn:active { transform: scale(0.99); }

/* ── ANIMATIONS ── */
@keyframes blink { 0%,100%{opacity:1} 50%{opacity:0.4} }
@keyframes fadeUp { from{opacity:0;transform:translateY(20px)} to{opacity:1;transform:translateY(0)} }
@keyframes fadeIn { from{opacity:0} to{opacity:1} }
@keyframes slideRight { from{opacity:0;transform:translateX(-20px)} to{opacity:1;transform:translateX(0)} }
@keyframes pulse-ring {
  0%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(37,99,235,0.45)}
  70%{transform:scale(1);box-shadow:0 0 0 10px rgba(37,99,235,0)}
  100%{transform:scale(0.95);box-shadow:0 0 0 0 rgba(37,99,235,0)}
}
@keyframes shimmer {
  0%{background-position:-200% 0}
  100%{background-position:200% 0}
}
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes float { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-8px)} }

/* ── REVEAL ON SCROLL ── */
.reveal {
  opacity: 0; transform: translateY(22px);
  transition: opacity 0.55s var(--ease), transform 0.55s var(--ease);
}
.reveal.in, .reveal.in-view { opacity: 1; transform: none; }
.reveal-d1 { transition-delay: 0.08s; }
.reveal-d2 { transition-delay: 0.16s; }
.reveal-d3 { transition-delay: 0.24s; }
.reveal-d4 { transition-delay: 0.32s; }

/* ── LOADING SKELETON ── */
.skeleton {
  background: linear-gradient(90deg, var(--surface) 25%, var(--surface-2) 50%, var(--surface) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.4s infinite; border-radius: var(--r-sm);
}

/* ── SPINNER ── */
.spinner {
  width: 20px; height: 20px; border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.25);
  border-top-color: #fff;
  animation: spin 0.7s linear infinite;
}

/* ── FOOTER ── */
.footer {
  background: var(--ink-2);
  border-top: 1px solid var(--border);
  padding: 52px 0 28px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1fr;
  gap: 40px; margin-bottom: 40px;
}
[dir="rtl"] .footer-grid { direction: rtl; }
.footer-brand p { font-size: 0.875rem; color: var(--cream-3); margin-top: 12px; line-height: 1.7; max-width: 260px; }
.footer-col h4 {
  font-family: var(--font-d); font-size: 0.75rem; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase; color: var(--cream-3);
  margin-bottom: 14px;
}
.footer-col a {
  display: block; margin-bottom: 9px;
  font-size: 0.875rem; color: var(--cream-3);
  transition: color var(--t-fast);
}
.footer-col a:hover { color: var(--cream); }
.footer-bottom {
  border-top: 1px solid var(--border); padding-top: 22px;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 10px;
}
.footer-copy { font-size: 0.8rem; color: var(--cream-3); }
.footer-links { display: flex; gap: 18px; }
.footer-links a { font-size: 0.8rem; color: var(--cream-3); }
.footer-links a:hover { color: var(--cream); }

/* ── DIVIDER ── */
.divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border), transparent);
}

/* ── MODAL ── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 800;
  background: rgba(10,13,20,0.75); backdrop-filter: blur(8px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px; opacity: 0; pointer-events: none;
  transition: opacity var(--t-med);
}
.modal-overlay.open { opacity: 1; pointer-events: all; }
.modal {
  background: var(--ink-2); border: 1px solid var(--border-h);
  border-radius: var(--r-xl); padding: 36px;
  width: 100%; max-width: 500px;
  transform: translateY(20px) scale(0.97);
  transition: transform var(--t-med);
}
.modal-overlay.open .modal { transform: none; }
.modal-close {
  float: right; background: none; border: none;
  font-size: 1.3rem; color: var(--cream-3); cursor: pointer;
  transition: color var(--t-fast);
}
.modal-close:hover { color: var(--cream); }
[dir="rtl"] .modal-close { float: left; }

/* ── TOAST ── */
.toast-container {
  position: fixed; bottom: 24px; right: 24px; z-index: 9100;
  display: flex; flex-direction: column; gap: 8px;
}
[dir="rtl"] .toast-container { right: auto; left: 24px; }
.toast {
  padding: 12px 18px; border-radius: var(--r-md);
  background: var(--surface); border: 1px solid var(--border-h);
  font-size: 0.875rem; color: var(--cream);
  box-shadow: 0 8px 30px rgba(0,0,0,0.4);
  animation: fadeUp 0.3s var(--ease) both;
}
.toast.success { border-color: #22C55E; }
.toast.error   { border-color: #EF4444; }

/* ── RESPONSIVE ── */
@media (max-width: 820px) {
  .section { padding: 64px 0; }
  .nav-links { display: none; }
  .nav-hamburger { display: flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px) {
  .footer-grid { grid-template-columns: 1fr; }
  .modal { padding: 24px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ══════════════════════════════════════════════════════════════
   LIGHT THEME — Auto-applied 06:00-19:00, or user-toggled
   ══════════════════════════════════════════════════════════════ */
[data-theme="light"] {
  --ink:        #FFFFFF;
  --ink-2:      #F8F9FC;
  --ink-3:      #EFF1F7;
  --blue-h:     #1D4ED8;
  --blue-soft:  #3B82F6;
  --blue-glow:  rgba(37,99,235,0.10);
  --cream:      #1E293B;
  --cream-2:    #475569;
  --cream-3:    #94A3B8;
  --surface:    #FFFFFF;
  --surface-2:  #F1F5F9;
  --border:     rgba(15,23,42,0.08);
  --border-h:   rgba(15,23,42,0.15);
}

[data-theme="light"] body::after { opacity: 0.08; }

[data-theme="light"] .nav {
  background: rgba(255,255,255,0.82);
  border-bottom-color: rgba(15,23,42,0.06);
}
[data-theme="light"] .nav.scrolled { background: rgba(255,255,255,0.96); }

[data-theme="light"] .nav-logo-text,
[data-theme="light"] .nav-brand { color: #1E293B; }

[data-theme="light"] .app-sidebar { background: #F8F9FC; border-color: rgba(15,23,42,0.06); }
[data-theme="light"] .sb-item:hover { background: rgba(15,23,42,0.04); }
[data-theme="light"] .sb-item.active { background: rgba(37,99,235,0.08); }
[data-theme="light"] .sp-profile-dropdown { background: #fff; box-shadow: 0 8px 24px rgba(0,0,0,0.08); }
[data-theme="light"] .sp-profile-action-btn:hover { background: #F1F5F9; }

[data-theme="light"] .grad {
  background: linear-gradient(120deg, var(--blue), #1D4ED8);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text;
}

[data-theme="light"] .btn-primary { color: #fff; }
[data-theme="light"] .btn::after { background: rgba(0,0,0,0.04); }
[data-theme="light"] .gen-btn { color: #fff; }
[data-theme="light"] .gen-btn::before {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
}
[data-theme="light"] .nav-avatar { color: #fff; }
[data-theme="light"] .badge { background: rgba(37,99,235,0.08); border-color: rgba(37,99,235,0.15); }

[data-theme="light"] .modal-overlay { background: rgba(0,0,0,0.18); }

[data-theme="light"] .input-foot { background: rgba(241,245,249,0.6); }

[data-theme="light"] .spinner { border-color: rgba(0,0,0,0.10); border-top-color: var(--blue); }

[data-theme="light"] .card:hover { box-shadow: 0 8px 30px rgba(0,0,0,0.06); }
[data-theme="light"] .toast { box-shadow: 0 4px 16px rgba(0,0,0,0.08); }
[data-theme="light"] .skeleton {
  background: linear-gradient(90deg, #EFF1F7 25%, #F8F9FC 50%, #EFF1F7 75%);
  background-size: 200% 100%;
}

/* Inline SVG icon — used inside badges, chips, etc. */
.sp-i { display:inline-block; width:1em; height:1em; vertical-align:-.125em; flex-shrink:0; }

/* Theme toggle button */
.theme-toggle {
  width: 34px; height: 34px; border-radius: var(--r-sm);
  background: var(--surface-2); border: 1px solid var(--border);
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--cream-3); cursor: pointer; transition: var(--t-fast);
  flex-shrink: 0; padding: 0;
}
.theme-toggle:hover { color: var(--cream); border-color: var(--border-h); }
.theme-toggle svg { width: 16px; height: 16px; }
