/* ============================================================
   TakeFrom — Premium Clean Theme
   ============================================================ */

/* ---------- Design tokens ---------- */
:root {
  --bg: #f5f8ff;
  --bg-hero: radial-gradient(circle at 16% 10%, #cfe6ff 0, transparent 34%),
             linear-gradient(135deg, #edf7ff 0%, #f1edff 52%, #edf3ff 100%);
  --navy: #17234a;
  --navy-2: #111b40;
  --ink: #101936;
  --ink-2: #26345c;
  --slate: #5e6a89;
  --muted: #8a94aa;
  --line: #dce3f4;
  --line-2: #dde4f5;
  --blue: #3858db;
  --blue-deep: #2d48c1;
  --blue-2: #3758db;
  --blue-soft: #e0eaff;
  --blue-text: #5265c8;
  --purple: #9b61cd;
  --green: #34ac87;
  --green-soft: #e9f8f2;
  --surface: rgba(255, 255, 255, 0.7);
  --surface-solid: #ffffff;
  --surface-2: #f8faff;
  --shadow-lg: 0 26px 70px -35px #5267bd;
  --shadow-md: 0 12px 35px -20px #5368cd;
  --shadow-sm: 0 4px 14px -8px rgba(83, 104, 205, 0.35);
  --radius-xl: 28px;
  --radius-lg: 20px;
  --radius-md: 16px;
  --radius-sm: 12px;
  --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --header-h: 64px;
  --grad-text: linear-gradient(90deg, #3858da, #5863dc, #9b61cd);
}

[data-theme="dark"] {
  --bg: #0b0f19;
  --bg-hero: radial-gradient(circle at 16% 10%, rgba(56, 88, 219, 0.15) 0, transparent 40%),
             linear-gradient(135deg, #0f172a 0%, #1e1b4b 52%, #0f172a 100%);
  --navy: #f1f5f9;
  --navy-2: #f8fafc;
  --ink: #f1f5f9;
  --ink-2: #e2e8f0;
  --slate: #94a3b8;
  --muted: #64748b;
  --line: rgba(255, 255, 255, 0.1);
  --line-2: rgba(255, 255, 255, 0.05);
  --blue: #3b82f6;
  --blue-deep: #2563eb;
  --blue-2: #3b82f6;
  --blue-soft: rgba(59, 130, 246, 0.1);
  --blue-text: #60a5fa;
  --purple: #a855f7;
  --green: #22c55e;
  --green-soft: rgba(34, 197, 94, 0.1);
  --surface: rgba(30, 41, 59, 0.7);
  --surface-solid: #1e293b;
  --surface-2: #0f172a;
  --shadow-lg: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
}

/* Loading Spinner */
.spinner {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
  vertical-align: middle;
  margin-right: 8px;
}

/* Skeleton Pulse Animation */
@keyframes pulse {
  0% { opacity: 1; }
  50% { opacity: 0.4; }
  100% { opacity: 1; }
}
.skeleton-card { animation: pulse 1.5s ease-in-out infinite; }

.stylish-title {
  font-family: 'Outfit', sans-serif;
  font-weight: 900;
  letter-spacing: -0.5px;
  background: linear-gradient(135deg, #3858db 0%, #9b61cd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  display: inline-block;
  text-transform: none; /* Let the capitalization be more natural */
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color .3s ease, color .3s ease;
}
p { text-align: justify; }
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 2px; border-radius: 8px; }
.container { max-width: 100%; margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }

/* ---------- Disclaimer bar ---------- */
.disclaimer-bar {
  background: var(--navy); color: #c9d4f5;
  font-size: 12px; line-height: 1.5; text-align: center;
  padding: 8px 16px;
}

/* ---------- Buttons ---------- */
.btn {
  border: none; font-weight: 800; font-size: 15px;
  padding: 14px 22px; border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  color: #fff; background: var(--blue);
  box-shadow: 0 13px 24px -12px var(--blue);
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, opacity .2s ease;
  min-height: 46px;
}
.btn:hover { background: var(--blue-deep); transform: translateY(-2px); box-shadow: 0 16px 28px -12px var(--blue); }
.btn:active { transform: translateY(0) scale(.99); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; box-shadow: none; }
.btn-big { font-size: 16px; padding: 15px 26px; width: 100%; }
.btn-small { width: auto; padding: 10px 16px; font-size: 14px; min-height: 40px; border-radius: 10px; }
.btn-outline {
  background: var(--surface-solid); color: var(--ink-2);
  border: 1px solid var(--line); box-shadow: none;
}
.btn-outline:hover { border-color: var(--blue-text); background: var(--blue-soft); color: var(--blue-deep); }

/* ---------- Header (glass) ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  height: var(--header-h);
  background: rgba(255,255,255,.55);
  backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(255,255,255,.5);
  transition: box-shadow .3s ease;
}
[data-theme="dark"] .site-header { background: rgba(13,19,48,.6); border-bottom-color: rgba(255,255,255,.07); }
.site-header.scrolled { box-shadow: 0 8px 30px -18px #5267bd; }
.header-inner { height: 100%; display: flex; align-items: center; gap: 16px; }
.brand { display: flex; align-items: center; gap: 10px; font-size: 19px; font-weight: 800; letter-spacing: -.04em; color: var(--navy-2); }
.brand-logo {
  height: 44px; width: auto; max-width: 160px;
  object-fit: contain;
}
.main-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.main-nav a {
  padding: 10px 16px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 700; color: var(--slate);
  transition: color .15s ease, background .15s ease;
}
.main-nav a:hover { color: var(--blue); background: rgba(56,88,219,.08); }

/* ---------- Language switcher ---------- */
.lang-wrap { position: relative; margin-right: 4px; }
.lang-toggle {
  display: flex; align-items: center; gap: 6px;
  height: 38px; padding: 0 12px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface-solid);
  color: var(--slate); font-size: 13px; font-weight: 700;
  transition: color .15s ease, border-color .15s ease;
  box-shadow: var(--shadow-sm);
}
.lang-toggle:hover { color: var(--blue); border-color: var(--blue-text); }
.lang-menu {
  position: absolute; top: calc(100% + 6px); right: 0; z-index: 60;
  min-width: 200px; list-style: none; padding: 6px; margin: 0;
  background: var(--surface-solid); border: 1px solid var(--line);
  border-radius: var(--radius-md); box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(-4px);
  transition: opacity .16s ease, transform .16s ease, visibility .16s;
}
.lang-menu.open { opacity: 1; visibility: visible; transform: none; }
.lang-menu li {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 9px 12px; border-radius: 10px;
  font-size: 13.5px; color: var(--ink); cursor: pointer;
  transition: background .12s ease;
}
.lang-menu li:hover { background: var(--blue-soft); }
.lang-menu li.active { color: var(--blue-deep); font-weight: 700; }
.lang-menu li.active svg { color: var(--blue); }
.lang-name { font-weight: 700; }

/* ---------- Theme toggle ---------- */
.theme-toggle {
  width: 38px; height: 38px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--surface-solid);
  color: var(--slate); display: grid; place-items: center;
  box-shadow: var(--shadow-sm);
  transition: color .15s ease, border-color .15s ease;
}
.theme-toggle:hover { color: var(--blue); border-color: var(--blue-text); }
[data-theme="dark"] .icon-sun { display: block; }
[data-theme="dark"] .icon-moon { display: none; }
.icon-sun { display: none; }
.icon-moon { display: block; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate;
  background: var(--bg-hero);
  padding: 64px 0 48px;
  overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; right: -120px; top: 20px; z-index: -1;
  width: 320px; height: 320px; border-radius: 50%;
  background: rgba(185,168,255,.3); filter: blur(60px);
}
.hero h1 {
  max-width: 100%;
  font-size: clamp(34px, 6vw, 56px);
  font-weight: 800; letter-spacing: -.06em; line-height: 1.02;
  color: var(--navy-2);
  text-align: center;
}
.hero .accent {
  background: var(--grad-text);
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-sub {
  margin-top: 18px; max-width: 800px;
  font-size: 17px; line-height: 1.7; color: var(--slate);
  text-align: center;
}

.highlight-counter {
  margin: 24px 0;
  font-size: 20px;
  font-weight: 800;
  color: var(--blue);
  background: var(--blue-soft);
  padding: 10px 24px;
  border-radius: 99px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(56, 88, 219, 0.2);
  text-align: center;
}

/* ---------- Downloader card (glass) ---------- */
.downloader-card {
  max-width: 800px; margin: 36px 0 0; text-align: left;
  background: var(--surface);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255,255,255,.7);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg);
  padding: 14px;
  width: 100%;
}
[data-theme="dark"] .downloader-card { border-color: rgba(255,255,255,.09); }

/* Tabs */
.dl-tabs {
  display: flex; gap: 8px; margin-bottom: 14px;
  background: rgba(248,250,255,.8); border: 1px solid var(--line);
  border-radius: var(--radius-md); padding: 5px;
}
.dl-tab {
  flex: 1; border: none; background: transparent; cursor: pointer;
  padding: 11px 14px; border-radius: 12px;
  font-size: 14px; font-weight: 800; color: var(--slate);
  transition: background .18s ease, color .18s ease, box-shadow .18s ease;
}
.dl-tab.active {
  background: var(--blue); color: #fff;
  box-shadow: 0 8px 20px -8px var(--blue);
}
.dl-panel { display: none; }
.dl-panel.active { display: block; animation: rise .25s ease both; }
@keyframes rise { from { opacity:0; transform: translateY(10px); } to { opacity:1; transform:none; } }

/* Input row */
.input-row {
  display: flex; align-items: center; gap: 10px;
  background: var(--surface-2); border: 1.5px solid var(--line);
  border-radius: var(--radius-md); padding: 6px 8px 6px 16px;
  margin-bottom: 12px; transition: border-color .2s ease, box-shadow .2s ease;
}
.input-row:focus-within { border-color: #7080df; box-shadow: 0 0 0 4px rgba(135,148,239,.12); }
.input-row .icon { color: var(--blue-text); display: grid; place-items: center; }
.ph { flex: 1; font-size: 15px; color: var(--muted); padding: 11px 0; min-width: 0; cursor: text; font-weight: 600; border: none; background: transparent; outline: none; font-family: inherit; }
.ph::placeholder { color: var(--muted); font-weight: 500; }
.ph.filled { color: var(--ink-2); }
.btn-clear {
  display: none; background: none; border: none; color: var(--muted);
  font-size: 15px; padding: 8px; border-radius: 10px;
}
.btn-clear:hover { color: var(--ink); }
.btn-clear.show { display: block; }

/* Consent + trust */
.consent-note { margin-top: 12px; font-size: 11.5px; color: var(--muted); text-align: center; }
.trust-note { margin-top: 12px; font-size: 13px; color: var(--muted); line-height: 1.7; }
.trust-note strong { color: var(--slate); font-weight: 700; }
.trust-note .sep { margin: 0 6px; color: var(--line-2); }

/* ---------- Status / skeleton ---------- */
#statusArea, #resultArea { max-width: 720px; margin: 18px 0 0; text-align: left; }
.skeleton-card {
  background: var(--surface); border: 1px solid rgba(255,255,255,.6);
  border-radius: var(--radius-lg); box-shadow: var(--shadow-md);
  padding: 20px; backdrop-filter: blur(12px);
}
.skeleton-thumb { height: 180px; border-radius: 14px; margin-bottom: 14px; background: linear-gradient(100deg, var(--surface-2) 40%, var(--line) 50%, var(--surface-2) 60%); background-size: 200% 100%; animation: shimmer 1.3s infinite; }
.skeleton-line { height: 13px; border-radius: 6px; margin-bottom: 10px; background: linear-gradient(100deg, var(--surface-2) 40%, var(--line) 50%, var(--surface-2) 60%); background-size: 200% 100%; animation: shimmer 1.3s infinite; }
.skeleton-line.short { width: 55%; }
.skeleton-line.btn { height: 46px; border-radius: var(--radius-sm); }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Result card ---------- */
.result-card { padding: 0; overflow: hidden; background: var(--surface-solid); border: 1px solid var(--line); border-radius: var(--radius-lg); box-shadow: var(--shadow-md); }
.thumb { height: 230px; position: relative; overflow: hidden; background: var(--surface-2); display: grid; place-items: center; }
.thumb img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.play-badge {
  width: 52px; height: 52px; border-radius: 50%;
  background: linear-gradient(135deg, var(--blue), var(--purple)); color: #fff;
  display: grid; place-items: center; font-size: 16px;
  box-shadow: var(--shadow-md); position: relative; z-index: 2;
}
.badge-tl, .badge-bl { position: absolute; z-index: 2; background: rgba(17,27,64,.7); color: #fff; font-size: 11px; font-weight: 700; padding: 5px 10px; border-radius: 10px; }
.badge-tl { top: 12px; left: 12px; }
.badge-bl { bottom: 12px; left: 12px; font-weight: 600; }
.result-body { padding: 20px; }
.author-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.author-av { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, var(--blue), var(--purple)); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; }
.author-name { font-size: 14px; font-weight: 800; color: var(--ink-2); }
.author-sub { font-size: 11px; color: var(--muted); }
.caption { font-size: 15px; font-weight: 700; margin: 2px 0 10px; color: var(--ink-2); }
.chips { display: flex; gap: 8px; margin-bottom: 10px; flex-wrap: wrap; }
.chip { font-size: 11px; font-weight: 700; padding: 4px 11px; border-radius: 999px; }
.chip-blue { background: var(--blue-soft); color: var(--blue-text); }
.chip-grey { background: var(--surface-2); color: var(--slate); border: 1px solid var(--line); }
.stats { font-size: 13px; color: var(--slate); font-weight: 600; margin-bottom: 14px; }
.dl-label { font-size: 11px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.dl-row { display: flex; gap: 8px; margin-top: 10px; }
.dl-row .btn { flex: 1; font-size: 13px; padding: 12px 8px; }
.btn-outline-blue { background: var(--surface-solid); color: var(--blue-deep); border: 1px solid var(--line); box-shadow: none; }
.btn-outline-blue:hover { border-color: var(--blue); background: var(--blue-soft); }

/* ---------- Sections ---------- */
.how-section, .who-section { padding: 64px 0; }
.features-section { padding: 64px 0; }
.bulk-section { background: var(--surface); border-block: 1px solid var(--line-2); padding: 56px 0; }
.faq-section { padding: 64px 0; }
section h2 { font-size: clamp(24px, 3.4vw, 36px); font-weight: 800; letter-spacing: -.05em; color: var(--navy-2); }
.how-section h2, .how-section .section-sub { text-align: left; }
.section-sub { color: var(--slate); font-size: 15px; margin: 10px 0 32px; max-width: 100%; }

/* Steps */
.steps { list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding: 0; }
.step-card {
  position: relative; background: var(--surface-solid); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 26px 22px;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease;
}
.step-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.step-num {
  display: inline-grid; place-items: center;
  width: 30px; height: 30px; border-radius: 10px;
  background: var(--blue-soft); color: var(--blue-text);
  font-size: 13px; font-weight: 800; margin-bottom: 12px;
}
.step-card h3 { font-size: 16px; font-weight: 800; color: var(--ink-2); margin-bottom: 6px; }
.step-card p { font-size: 13.5px; color: var(--slate); }
.pro-tip {
  margin-top: 18px; font-size: 13.5px; color: var(--blue-text);
  background: var(--blue-soft); border: 1px solid rgba(84,101,200,.25);
  border-radius: var(--radius-md); padding: 13px 16px;
}

/* Who grid (2 cols) */
.who-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.who-card {
  background: var(--surface-solid); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 26px 22px;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease;
}
.who-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.who-emoji {
  width: 52px; height: 52px; border-radius: 16px;
  background: var(--blue-soft); display: grid; place-items: center;
  font-size: 26px; margin-bottom: 14px;
}
.who-card h3 { font-size: 15.5px; font-weight: 800; color: var(--ink-2); margin-bottom: 6px; }
.who-card p { font-size: 13.5px; color: var(--slate); }

/* Features grid */
.features-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature-card {
  background: var(--surface-solid); border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 24px 20px;
  box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease;
}
.feature-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.feature-emoji {
  width: 48px; height: 48px; border-radius: 14px;
  background: var(--blue-soft); display: grid; place-items: center;
  font-size: 24px; margin-bottom: 14px;
}
.feature-card:nth-child(2) .feature-emoji { background: #fff3d6; }
.feature-card:nth-child(3) .feature-emoji { background: #e3f7ec; }
.feature-card:nth-child(4) .feature-emoji { background: #fde8f1; }
.feature-card:nth-child(5) .feature-emoji { background: #e8ebff; }
.feature-card:nth-child(6) .feature-emoji { background: #e0f5fd; }
.feature-card h3 { font-size: 15.5px; font-weight: 800; color: var(--ink-2); margin-bottom: 6px; }
.feature-card p { font-size: 13.5px; color: var(--slate); }

/* Long-form content */
.content-section { padding: 60px 0; }
.content-section:nth-of-type(even) { background: var(--surface); border-block: 1px solid var(--line-2); }
.content-section h2 { margin-bottom: 16px; }
.content-section p { max-width: 100%; color: var(--slate); margin-bottom: 14px; line-height: 1.75; }
.use-list { list-style: none; padding: 0; max-width: 100%; }
.use-list li { position: relative; padding: 9px 0 9px 26px; color: var(--slate); font-size: 14px; line-height: 1.7; }
.use-list li::before { content: ''; position: absolute; left: 4px; top: 17px; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }

/* ---------- History ---------- */
.history-section { margin: 0; border-radius: 0; border-left: 0; border-right: 0; background: var(--surface); }
.history-section .container { padding-top: 8px; padding-bottom: 8px; }
.card-title-row { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.card-title-row h3 { font-size: 15px; font-weight: 800; color: var(--ink-2); }
.link-btn { background: none; border: none; color: var(--muted); font-size: 12px; font-weight: 700; padding: 6px; border-radius: 8px; }
.link-btn:hover { color: var(--blue); }
.h-item { display: flex; align-items: center; gap: 10px; padding: 10px 6px; border-bottom: 1px solid var(--line-2); cursor: pointer; border-radius: 10px; transition: background .15s ease; }
.h-item:hover { background: var(--surface-2); }
.h-item:last-child { border-bottom: none; }
.h-ic { width: 32px; height: 32px; border-radius: 10px; flex-shrink: 0; background: var(--blue-soft); display: grid; place-items: center; font-size: 13px; }
.h-t { flex: 1; min-width: 0; }
.h-t b { font-size: 13px; font-weight: 700; color: var(--ink-2); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.h-t small { font-size: 11px; color: var(--muted); }
.h-a { color: var(--muted); font-size: 16px; }

/* ---------- FAQ ---------- */
.faq-list { max-width: 100%; margin: 0; }
.faq-list { border: 1px solid var(--line); border-radius: var(--radius-lg); background: rgba(255,255,255,.6); box-shadow: var(--shadow-md); overflow: hidden; }
[data-theme="dark"] .faq-list { background: rgba(23,35,74,.5); }
.faq-item { border-bottom: 1px solid var(--line-2); }
.faq-item:last-child { border-bottom: none; }
.faq-item summary {
  cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px; font-weight: 800; font-size: 14.5px; color: var(--ink-2);
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after {
  content: ''; width: 10px; height: 10px; flex-shrink: 0;
  border-right: 2px solid var(--blue-text); border-bottom: 2px solid var(--blue-text);
  transform: rotate(45deg); transition: transform .2s ease; margin-right: 6px;
}
.faq-item[open] summary::after { transform: rotate(225deg); }
.faq-item p { padding: 0 20px 18px; font-size: 14px; color: var(--slate); line-height: 1.75; max-width: 100%; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line-2); background: #edf2fb; padding: 36px 0 28px; }
[data-theme="dark"] .site-footer { background: #101737; }
.site-footer .container { display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.footer-brand { display: flex; align-items: center; gap: 8px; font-size: 16px; font-weight: 800; letter-spacing: -.03em; color: var(--navy-2); }
.footer-logo { height: 33px; width: auto; max-width: 120px; object-fit: contain; }
.footer-tag { font-size: 13px; color: var(--muted); font-weight: 400; }
.footer-nav { display: flex; gap: 20px; }
.footer-nav a { font-size: 13px; color: var(--slate); font-weight: 700; }
.footer-nav a:hover { color: var(--blue); }
.footer-copy { font-size: 12px; color: var(--muted); }

/* ---------- Toast ---------- */
#toast {
  position: fixed; left: 50%; bottom: 26px; transform: translateX(-50%) translateY(90px);
  background: var(--navy); color: #fff;
  font-size: 14px; font-weight: 600; padding: 13px 22px; border-radius: 14px;
  opacity: 0; transition: transform .3s cubic-bezier(.2,.9,.3,1.1), opacity .3s ease;
  z-index: 99; pointer-events: none; max-width: 90vw; text-align: center;
  box-shadow: var(--shadow-lg);
}
#toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Empty / error ---------- */
.empty-state { text-align: left; padding: 20px 4px; }
.empty-state svg { color: var(--muted); margin-bottom: 10px; }
.empty-state p { color: var(--muted); font-size: 14px; }
.error-card { background: #fdf1f4; border: 1px solid rgba(198,79,107,.3); border-radius: var(--radius-md); padding: 16px; display: flex; gap: 12px; align-items: flex-start; }
.error-card svg { color: #c64f6b; flex-shrink: 0; margin-top: 2px; }
.error-card h4 { font-size: 15px; font-weight: 800; color: #a63d58; margin-bottom: 4px; }
.error-card p { font-size: 13px; color: #8f3b50; line-height: 1.55; }
.error-card .er { font-size: 11px; color: #b04a63; margin-top: 4px; }

/* ---------- Batch items ---------- */
.b-item { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 13px 15px; margin-bottom: 8px; }
.b-head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.b-num { width: 24px; height: 24px; border-radius: 9px; flex-shrink: 0; background: var(--blue); color: #fff; font-size: 11px; font-weight: 800; display: grid; place-items: center; box-shadow: 0 6px 14px -6px var(--blue); }
.b-title { flex: 1; min-width: 0; }
.b-title b { font-size: 13px; font-weight: 700; color: var(--ink-2); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.b-title small { font-size: 11px; color: var(--muted); display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.b-status { display: flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; white-space: nowrap; color: var(--blue-text); }
.b-status .spin-mini { width: 13px; height: 13px; border-radius: 50%; border: 2px solid rgba(84,101,200,.2); border-top-color: var(--blue); animation: spin .7s linear infinite; }
.b-bar { height: 7px; border-radius: 4px; background: var(--line); overflow: hidden; }
.b-bar-fill { height: 100%; width: 0%; background: linear-gradient(90deg, var(--blue), var(--purple)); border-radius: 4px; transition: width .3s ease; }
.b-item.done { border-color: rgba(52,172,135,.4); background: var(--green-soft); }
.b-item.done .b-bar-fill { background: var(--green); }
.b-item.done .b-status { color: var(--green); }
.b-item.failed { border-color: rgba(198,79,107,.4); background: rgba(253,241,244,.7); }
.b-item.failed .b-bar-fill { background: #c64f6b; }
.b-item.failed .b-status { color: #c64f6b; }

/* ---------- Textarea ---------- */
textarea {
  width: 100%; min-height: 100px; resize: vertical;
  background: var(--surface-2); border: 1.5px solid var(--line); border-radius: var(--radius-md);
  padding: 13px; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px;
  color: var(--ink-2); margin-bottom: 12px; transition: border-color .2s ease, box-shadow .2s ease;
}
textarea:focus { outline: none; border-color: #7080df; box-shadow: 0 0 0 4px rgba(135,148,239,.12); }
.btn-row { display: flex; gap: 8px; margin-bottom: 12px; }
.btn-row .btn { flex: 1; }
.note { font-size: 12px; color: var(--muted); margin-top: 10px; }

/* ---------- Entrance ---------- */
@keyframes fadeUp { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.how-section .step-card, .features-section .feature-card, .who-section .who-card, .faq-item { animation: fadeUp .5s ease both; }
.step-card:nth-child(2), .feature-card:nth-child(2), .feature-card:nth-child(5), .who-card:nth-child(2) { animation-delay: .08s; }
.step-card:nth-child(3), .feature-card:nth-child(3), .feature-card:nth-child(6), .who-card:nth-child(4) { animation-delay: .16s; }

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

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .who-grid { grid-template-columns: 1fr; }
}

/* ---------- Bulk Download Items ---------- */
.batch-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  margin-top: 8px;
  background: var(--surface-2);
  font-size: 13px;
}
.bi-url { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--slate); }
.bi-status { font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 999px; white-space: nowrap; }
.bi-status.queued   { background: var(--line); color: var(--muted); }
.bi-status.fetching { background: #e0eaff; color: var(--blue); }
.bi-status.done     { background: var(--green-soft); color: var(--green); }
.bi-status.failed   { background: #fff0f0; color: #d94f4f; }
[data-theme="dark"] .bi-status.done   { background: rgba(34,197,94,0.15); color: #4ade80; }
[data-theme="dark"] .bi-status.failed { background: rgba(239,68,68,0.15); color: #f87171; }
[data-theme="dark"] .bi-status.fetching { background: rgba(59,130,246,0.15); color: var(--blue); }
.bi-bar-wrap { width: 100%; height: 4px; background: var(--line); border-radius: 2px; overflow: hidden; }
.bi-bar { height: 100%; background: var(--blue); border-radius: 2px; transition: width 0.4s ease; }

/* ---------- Ads (Hidden by Default) ---------- */
.ad-slot, .ad-sticky-bottom {
  display: none !important; /* Hide until ad code is added */
}

.ad-slot {
  width: 100%;
  min-height: 90px;
  background: var(--surface-2);
  border: 1px dashed var(--line);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 20px 0;
  border-radius: var(--radius-md);
  position: relative;
  overflow: hidden;
}
.ad-slot::before {
  content: 'Advertisement';
  font-size: 11px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}

.ad-sticky-bottom {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  min-height: 100px;
  background: var(--surface-solid);
  border-top: 1px solid var(--line);
  z-index: 1000;
  box-shadow: 0 -4px 15px rgba(0,0,0,0.1);
  align-items: center;
  justify-content: center;
}

@media (max-width: 768px) {
  .ad-slot { min-height: 250px; }
  .ad-sticky-bottom { min-height: 50px; }
}

@media (max-width: 560px) {
  .brand-img { height: 40px !important; }
  .brand-text { font-size: 20px !important; }
  .features-grid { grid-template-columns: 1fr; }
  .main-nav { display: none; }
  .hero { padding: 44px 0 32px; }
  .dl-row { flex-wrap: wrap; }
  .dl-row .btn { min-width: 120px; }
  .lang-toggle span#langCurrent { display: none; }
}

/* ---------- Result Modal ---------- */
/* Pops up centered over the page the instant a fetch finishes, so the
   result is impossible to miss no matter how far down #resultArea would
   otherwise sit on the page. */
.result-modal {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  visibility: hidden; opacity: 0;
  transition: opacity .22s ease, visibility .22s ease;
}
.result-modal.open { visibility: visible; opacity: 1; }
.result-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(15, 23, 42, .55);
  backdrop-filter: blur(2px);
}
.result-modal-panel {
  position: relative;
  background: var(--surface-solid, #fff);
  border-radius: var(--radius-md, 18px);
  max-width: 480px; width: 100%;
  max-height: 88vh; overflow-y: auto;
  box-shadow: var(--shadow-lg, 0 24px 60px -20px rgba(20,30,70,.35));
  transform: translateY(14px) scale(.97);
  transition: transform .25s cubic-bezier(.2,.9,.3,1.1);
}
.result-modal.open .result-modal-panel { transform: translateY(0) scale(1); }
.result-modal-close {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  width: 34px; height: 34px; border-radius: 50%;
  border: 1px solid var(--line); background: var(--surface-solid, #fff);
  color: var(--slate); font-size: 15px; cursor: pointer;
  display: grid; place-items: center;
}
.result-modal-close:hover { color: var(--blue); border-color: var(--blue-text); }
.result-modal-panel .result-card { border: none; box-shadow: none; margin: 0; }
.result-modal-panel .ad-slot { display: none; } /* no ad clutter inside the modal */
body.modal-open { overflow: hidden; }

@media (max-width: 560px) {
  .result-modal-panel { max-height: 92vh; border-radius: 16px; }
}
