/* ============================================================
   Fatura Tasarruf — Premium Design System v2
   Senior-level, accessible, fast. Light/Dark themes.
   ============================================================ */

:root {
  --bg: #f7f8fc;
  --bg-alt: #eef0f7;
  --bg-gradient: linear-gradient(135deg, #f7f8fc 0%, #e8ecf7 100%);
  --card: #ffffff;
  --card-hover: #f4f7ff;
  --glass: rgba(255,255,255,.7);
  --glass-border: rgba(255,255,255,.4);
  --text: #111827;
  --text-secondary: #4b5563;
  --muted: #6b7280;
  --border: #e5e7eb;
  --accent: #2563eb;
  --accent-light: #eff6ff;
  --accent-dark: #1d4ed8;
  --accent-gradient: linear-gradient(135deg, #2563eb 0%, #7c3aed 100%);
  --accent2: #059669;
  --accent2-light: #ecfdf5;
  --accent2-dark: #047857;
  --accent2-gradient: linear-gradient(135deg, #059669 0%, #0d9488 100%);
  --danger: #dc2626;
  --danger-light: #fef2f2;
  --warning: #d97706;
  --warning-light: #fffbeb;
  --success: #059669;
  --success-light: #ecfdf5;
  --info: #2563eb;
  --info-light: #eff6ff;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --shadow-xs: 0 1px 2px rgba(0,0,0,.05);
  --shadow: 0 1px 3px rgba(0,0,0,.06), 0 2px 8px rgba(0,0,0,.04);
  --shadow-md: 0 4px 16px rgba(0,0,0,.08), 0 2px 4px rgba(0,0,0,.04);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.1), 0 4px 12px rgba(0,0,0,.05);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.12);
  --shadow-accent: 0 4px 20px rgba(37,99,235,.25);
  --transition: 200ms cubic-bezier(.4,0,.2,1);
  --transition-slow: 400ms cubic-bezier(.4,0,.2,1);
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', 'Fira Code', monospace;
  --max-w: 1200px;
  --nav-h: 68px;
}

[data-theme="dark"] {
  --bg: #0b0f1a;
  --bg-alt: #111827;
  --bg-gradient: linear-gradient(135deg, #0b0f1a 0%, #111827 100%);
  --card: #1f2937;
  --card-hover: #283548;
  --glass: rgba(31,41,55,.7);
  --glass-border: rgba(55,65,81,.5);
  --text: #f3f4f6;
  --text-secondary: #9ca3af;
  --muted: #6b7280;
  --border: #374151;
  --accent: #60a5fa;
  --accent-light: #1e293b;
  --accent-dark: #93c5fd;
  --accent-gradient: linear-gradient(135deg, #60a5fa 0%, #a78bfa 100%);
  --accent2: #34d399;
  --accent2-light: #1a2e2a;
  --accent2-dark: #6ee7b7;
  --accent2-gradient: linear-gradient(135deg, #34d399 0%, #2dd4bf 100%);
  --danger: #f87171;
  --danger-light: #1f1515;
  --warning: #fbbf24;
  --warning-light: #1f1a0f;
  --success: #34d399;
  --success-light: #1a2e2a;
  --info: #60a5fa;
  --info-light: #1e293b;
  --shadow-xs: 0 1px 2px rgba(0,0,0,.2);
  --shadow: 0 1px 3px rgba(0,0,0,.2), 0 2px 8px rgba(0,0,0,.15);
  --shadow-md: 0 4px 16px rgba(0,0,0,.25);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.3);
  --shadow-xl: 0 20px 60px rgba(0,0,0,.4);
  --shadow-accent: 0 4px 20px rgba(96,165,250,.2);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  scroll-padding-top: calc(var(--nav-h) + 1rem);
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  min-height: 100vh;
  transition: background var(--transition), color var(--transition);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

::selection { background: var(--accent); color: #fff; }

a { color: var(--accent); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--accent-dark); }
img { max-width: 100%; height: auto; display: block; }
h1, h2, h3, h4, h5, h6 { line-height: 1.3; color: var(--text); font-weight: 700; letter-spacing: -.01em; }
h1 { font-size: 2.25rem; margin-bottom: 1rem; font-weight: 800; }
h2 { font-size: 1.625rem; margin-bottom: .75rem; font-weight: 700; }
h3 { font-size: 1.25rem; margin-bottom: .5rem; font-weight: 600; }
p { margin-bottom: 1rem; }
ul, ol { margin-bottom: 1rem; padding-left: 1.5rem; }
li { margin-bottom: .25rem; }
.hidden { display: none !important; }

.container { max-width: var(--max-w); margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 4rem 0; }
.section--sm { padding: 3rem 0; }
.section-alt { background: var(--bg-alt); }

/* ---- HEADER / NAV ---- */
.site-header {
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);
  border-bottom: 1px solid var(--glass-border);
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  transition: background var(--transition), border var(--transition);
}
.nav { display: flex; align-items: center; height: var(--nav-h); gap: 1rem; }
.nav__logo {
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--accent);
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: .5rem;
  letter-spacing: -.02em;
}
.nav__logo:hover { color: var(--accent-dark); text-decoration: none; }
.nav__logo svg { width: 28px; height: 28px; flex-shrink: 0; }
.nav__links { display: flex; gap: .25rem; margin-left: auto; align-items: center; flex-wrap: nowrap; }
.nav__link {
  padding: .5rem .875rem;
  border-radius: var(--radius-sm);
  font-size: .875rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition);
  white-space: nowrap;
}
.nav__link:hover, .nav__link--active {
  color: var(--accent);
  background: var(--accent-light);
  text-decoration: none;
}
.nav__toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: .5rem;
  color: var(--text);
}
.nav__toggle svg { width: 24px; height: 24px; }

.theme-toggle {
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
}
.theme-toggle:hover { background: var(--accent-light); border-color: var(--accent); transform: rotate(15deg); }
.theme-toggle svg { width: 18px; height: 18px; color: var(--text); }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }

@media (max-width: 768px) {
  .nav__links {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--glass);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 1rem;
    gap: .25rem;
    box-shadow: var(--shadow-lg);
  }
  .nav__links.open { display: flex; }
  .nav__toggle { display: flex; margin-left: auto; }
  .theme-toggle { order: -1; }
}

/* ---- HERO ---- */
.hero {
  padding: 4rem 0 3rem;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -20%;
  width: 140%;
  height: 200%;
  background: radial-gradient(ellipse at 30% 20%, rgba(37,99,235,.08) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(124,58,237,.06) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}
[data-theme="dark"] .hero::before {
  background: radial-gradient(ellipse at 30% 20%, rgba(96,165,250,.06) 0%, transparent 50%),
              radial-gradient(ellipse at 70% 80%, rgba(167,139,250,.04) 0%, transparent 50%);
}
.hero > * { position: relative; z-index: 1; }
.hero__badge {
  display: inline-flex;
  align-items: center;
  gap: .375rem;
  padding: .375rem 1rem;
  background: var(--accent-light);
  border: 1px solid var(--accent);
  border-radius: 100px;
  font-size: .8rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 1.5rem;
  animation: fadeIn .6s ease both;
}
.hero__badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pulse 2s infinite; }
.hero__title {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 800;
  margin-bottom: 1rem;
  letter-spacing: -.03em;
  line-height: 1.15;
  animation: fadeIn .6s .1s ease both;
}
.hero__title-gradient {
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.hero__sub {
  font-size: 1.15rem;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 2rem;
  line-height: 1.7;
  animation: fadeIn .6s .2s ease both;
}
.hero__actions {
  display: flex;
  gap: .75rem;
  justify-content: center;
  flex-wrap: wrap;
  animation: fadeIn .6s .3s ease both;
}
.hero__stats {
  display: flex;
  gap: 2rem;
  justify-content: center;
  margin-top: 3rem;
  animation: fadeIn .6s .4s ease both;
}
.hero__stat { text-align: center; }
.hero__stat-value { font-size: 1.75rem; font-weight: 800; color: var(--accent); }
.hero__stat-label { font-size: .8rem; color: var(--muted); font-weight: 500; }

/* ---- CARDS ---- */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: all var(--transition);
  box-shadow: var(--shadow);
  position: relative;
}
.card:hover { box-shadow: var(--shadow-md); }
.card--link { cursor: pointer; text-decoration: none; color: var(--text); display: block; }
.card--link:hover { border-color: var(--accent); transform: translateY(-2px); text-decoration: none; color: var(--text); }
.card--flat { box-shadow: none; border: none; }
.card--glass {
  background: var(--glass);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-color: var(--glass-border);
}
.card--accent { border-left: 4px solid var(--accent); }
.card--success { border-left: 4px solid var(--accent2); }
.card--warning { border-left: 4px solid var(--warning); background: var(--warning-light); }
.card--danger { border-left: 4px solid var(--danger); background: var(--danger-light); }
.card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
  font-size: 1.5rem;
}
.card__icon--blue { background: var(--accent-light); color: var(--accent); }
.card__icon--green { background: var(--accent2-light); color: var(--accent2); }
.card__icon--purple { background: #f5f3ff; color: #7c3aed; }
[data-theme="dark"] .card__icon--purple { background: #1e1533; }
.card__icon--orange { background: var(--warning-light); color: var(--warning); }
.card__title { font-size: 1.05rem; font-weight: 700; margin-bottom: .375rem; }
.card__text { color: var(--text-secondary); font-size: .9rem; line-height: 1.6; margin: 0; }
.card__arrow {
  position: absolute;
  right: 1.25rem;
  top: 50%;
  transform: translateY(-50%);
  color: var(--muted);
  transition: all var(--transition);
  opacity: 0;
}
.card--link:hover .card__arrow { opacity: 1; transform: translateY(-50%) translateX(4px); color: var(--accent); }

/* ---- GRID ---- */
.grid { display: grid; gap: 1.25rem; }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }

/* ---- TABS ---- */
.tabs {
  display: flex;
  gap: .25rem;
  background: var(--bg-alt);
  padding: .3rem;
  border-radius: var(--radius);
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border: 1px solid var(--border);
}
.tab-btn {
  padding: .625rem 1.25rem;
  border: none;
  background: transparent;
  border-radius: calc(var(--radius) - 4px);
  font-size: .875rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  white-space: nowrap;
  transition: all var(--transition);
  font-family: var(--font);
  position: relative;
}
.tab-btn:hover { color: var(--text); }
.tab-btn.active {
  background: var(--card);
  color: var(--accent);
  box-shadow: var(--shadow);
}
.tab-panel { display: none; padding-top: 1.5rem; }
.tab-panel.active { display: block; animation: fadeIn .3s ease; }

/* ---- FORMS ---- */
.form-group { margin-bottom: 1.25rem; }
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1rem; }
.form-label {
  display: block;
  font-size: .85rem;
  font-weight: 600;
  margin-bottom: .375rem;
  color: var(--text-secondary);
}
.form-input, .form-select {
  width: 100%;
  padding: .7rem .875rem;
  border: 1.5px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .95rem;
  font-family: var(--font);
  background: var(--card);
  color: var(--text);
  transition: all var(--transition);
  outline: none;
}
.form-input:focus, .form-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 4px var(--accent-light);
}
.form-input::placeholder { color: var(--muted); }
.form-input.error { border-color: var(--danger); box-shadow: 0 0 0 4px var(--danger-light); }
.form-hint { font-size: .78rem; color: var(--muted); margin-top: .25rem; }
.form-error { font-size: .78rem; color: var(--danger); margin-top: .25rem; display: none; }
.form-error.show { display: block; }
.form-suffix { display: flex; align-items: center; }
.form-suffix .form-input { border-top-right-radius: 0; border-bottom-right-radius: 0; border-right: none; }
.form-suffix__label {
  background: var(--bg-alt);
  border: 1.5px solid var(--border);
  border-left: none;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: .7rem .875rem;
  font-size: .85rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
}

/* ---- BUTTONS ---- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.5rem;
  border: none;
  border-radius: var(--radius-sm);
  font-size: .9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font);
  text-decoration: none;
  white-space: nowrap;
  position: relative;
  overflow: hidden;
}
.btn:hover { text-decoration: none; }
.btn svg { width: 16px; height: 16px; flex-shrink: 0; }
.btn--primary {
  background: var(--accent-gradient);
  color: #fff;
  box-shadow: var(--shadow-accent);
}
.btn--primary:hover { transform: translateY(-1px); box-shadow: 0 6px 24px rgba(37,99,235,.3); color: #fff; }
.btn--success {
  background: var(--accent2-gradient);
  color: #fff;
}
.btn--success:hover { transform: translateY(-1px); color: #fff; }
.btn--outline {
  background: transparent;
  border: 1.5px solid var(--border);
  color: var(--text-secondary);
}
.btn--outline:hover {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-light);
}
.btn--ghost { background: transparent; color: var(--text-secondary); }
.btn--ghost:hover { background: var(--bg-alt); color: var(--text); }
.btn--sm { padding: .4rem 1rem; font-size: .8rem; }
.btn--lg { padding: .875rem 2.25rem; font-size: 1rem; border-radius: var(--radius); }
.btn--block { width: 100%; justify-content: center; }
.btn-group { display: flex; gap: .5rem; flex-wrap: wrap; }

/* ---- SEGMENTED CONTROL ---- */
.segmented {
  display: inline-flex;
  background: var(--bg-alt);
  border-radius: var(--radius-sm);
  padding: .25rem;
  gap: .2rem;
  border: 1px solid var(--border);
}
.segmented__btn {
  padding: .5rem 1rem;
  border: none;
  background: transparent;
  border-radius: calc(var(--radius-sm) - 3px);
  font-size: .85rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all var(--transition);
  font-family: var(--font);
}
.segmented__btn:hover { color: var(--text); }
.segmented__btn.active {
  background: var(--card);
  color: var(--accent);
  box-shadow: var(--shadow-xs);
}

/* ---- BADGE ---- */
.badge {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: .3rem .875rem;
  border-radius: 100px;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .02em;
}
.badge--success { background: var(--success-light); color: var(--accent2); }
.badge--warning { background: var(--warning-light); color: var(--warning); }
.badge--danger { background: var(--danger-light); color: var(--danger); }
.badge--info { background: var(--accent-light); color: var(--accent); }

/* ---- TABLE ---- */
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); background: var(--card); }
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: .9rem;
}
.table th, .table td {
  padding: .875rem 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.table th {
  background: var(--bg-alt);
  font-weight: 700;
  font-size: .78rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted);
}
.table tr:last-child td { border-bottom: none; }
.table tr:hover td { background: var(--card-hover); }
.table--highlight tr.best td { background: var(--accent-light); font-weight: 600; }

/* ---- STATS ---- */
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 1rem; }
.stat {
  text-align: center;
  padding: 1.5rem 1rem;
  background: var(--card);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  transition: all var(--transition);
}
.stat:hover { border-color: var(--accent); box-shadow: var(--shadow-md); }
.stat__value {
  font-size: 1.875rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.1;
  letter-spacing: -.02em;
}
.stat__label {
  font-size: .78rem;
  color: var(--muted);
  margin-top: .375rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .03em;
}
.stat--success .stat__value { color: var(--accent2); }
.stat--danger .stat__value { color: var(--danger); }
.stat--warning .stat__value { color: var(--warning); }

/* ---- RESULT BAR ---- */
.result-bar {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem 1rem;
  background: var(--bg-alt);
  border-radius: var(--radius-sm);
  margin-bottom: .5rem;
  transition: all var(--transition);
}
.result-bar:hover { background: var(--card-hover); }
.result-bar__label { font-size: .85rem; font-weight: 600; min-width: 100px; }
.result-bar__track {
  flex: 1;
  height: 8px;
  background: var(--border);
  border-radius: 100px;
  overflow: hidden;
}
.result-bar__fill {
  height: 100%;
  border-radius: 100px;
  transition: width .6s cubic-bezier(.4,0,.2,1);
  background: var(--accent-gradient);
}
.result-bar__fill--success { background: var(--accent2-gradient); }
.result-bar__fill--warning { background: linear-gradient(90deg, var(--warning), #f59e0b); }
.result-bar__fill--danger { background: linear-gradient(90deg, var(--danger), #ef4444); }
.result-bar__value { font-size: .85rem; font-weight: 700; min-width: 80px; text-align: right; }

/* ---- ACCORDION (FAQ) ---- */
.accordion { border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; background: var(--card); }
.accordion__item { border-bottom: 1px solid var(--border); }
.accordion__item:last-child { border-bottom: none; }
.accordion__header {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.125rem 1.5rem;
  background: transparent;
  border: none;
  cursor: pointer;
  font-size: .95rem;
  font-weight: 600;
  color: var(--text);
  text-align: left;
  transition: all var(--transition);
  font-family: var(--font);
  gap: 1rem;
}
.accordion__header:hover { background: var(--card-hover); }
.accordion__icon {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  transition: transform .3s cubic-bezier(.4,0,.2,1);
  color: var(--muted);
}
.accordion__item.open .accordion__icon { transform: rotate(180deg); color: var(--accent); }
.accordion__body {
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s cubic-bezier(.4,0,.2,1);
}
.accordion__content {
  padding: 0 1.5rem 1.5rem;
  color: var(--text-secondary);
  font-size: .9rem;
  line-height: 1.8;
}

/* ---- DISCLAIMER ---- */
.disclaimer {
  background: var(--warning-light);
  border: 1px solid rgba(217,119,6,.2);
  border-radius: var(--radius-sm);
  padding: 1rem 1.25rem;
  font-size: .85rem;
  color: var(--text-secondary);
  line-height: 1.7;
}
.disclaimer strong { color: var(--text); }

/* ---- BREADCRUMB ---- */
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: .25rem;
  font-size: .8rem;
  color: var(--muted);
  padding: 1rem 0 0;
  list-style: none;
}
.breadcrumb li::after { content: "/"; margin-left: .5rem; color: var(--border); }
.breadcrumb li:last-child::after { content: ""; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--accent); }

/* ---- TAG / CHIP ---- */
.tag {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  padding: .3rem .75rem;
  background: var(--bg-alt);
  border: 1px solid var(--border);
  border-radius: 100px;
  font-size: .75rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition);
}
.tag:hover, .tag.active {
  background: var(--accent-light);
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
}

/* ---- SEARCH ---- */
.search-box { position: relative; max-width: 600px; margin: 0 auto; }
.search-box__input {
  width: 100%;
  padding: 1rem 1.125rem 1rem 3.25rem;
  font-size: 1rem;
  border: 2px solid var(--border);
  border-radius: var(--radius);
  background: var(--card);
  color: var(--text);
  transition: all var(--transition);
  font-family: var(--font);
  outline: none;
}
.search-box__input:focus { border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-light); }
.search-box__icon {
  position: absolute;
  left: 1.125rem;
  top: 50%;
  transform: translateY(-50%);
  width: 20px;
  height: 20px;
  color: var(--muted);
}
.search-results { margin-top: 1.5rem; }
.search-result {
  display: block;
  padding: 1.125rem 1.25rem;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: .75rem;
  transition: all var(--transition);
  text-decoration: none;
  color: var(--text);
}
.search-result:hover { border-color: var(--accent); background: var(--card-hover); text-decoration: none; transform: translateY(-1px); }
.search-result__title { font-weight: 700; margin-bottom: .25rem; }
.search-result__snippet { font-size: .85rem; color: var(--text-secondary); }
.search-result mark { background: var(--warning-light); color: var(--text); padding: .1rem .25rem; border-radius: 3px; }

/* ---- INTERNAL LINKS ---- */
.related {
  margin-top: 3rem;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
}
.related__title { font-size: 1.125rem; margin-bottom: 1.25rem; }
.related__links { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: .75rem; }
.related__link {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .875rem 1.125rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .875rem;
  font-weight: 500;
  color: var(--text);
  transition: all var(--transition);
}
.related__link:hover {
  border-color: var(--accent);
  color: var(--accent);
  text-decoration: none;
  background: var(--accent-light);
  transform: translateX(4px);
}
.related__link svg { width: 16px; height: 16px; flex-shrink: 0; color: var(--accent); }

/* ---- PRESET GRID ---- */
.preset-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: .875rem; }
.preset-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 1.5rem 1rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all var(--transition);
  text-decoration: none;
  color: var(--text);
  position: relative;
  overflow: hidden;
}
.preset-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  transform: scaleX(0);
  transition: transform var(--transition);
}
.preset-card:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  text-decoration: none;
}
.preset-card:hover::before { transform: scaleX(1); }
.preset-card__value { font-size: 1.625rem; font-weight: 800; color: var(--accent); }
.preset-card__label { font-size: .78rem; color: var(--muted); margin-top: .375rem; text-align: center; font-weight: 500; }

/* ---- FEATURE SECTION ---- */
.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; }
.feature {
  padding: 2rem 1.5rem;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: all var(--transition);
  text-align: center;
}
.feature:hover { border-color: var(--accent); box-shadow: var(--shadow-md); transform: translateY(-2px); }
.feature__icon {
  width: 56px;
  height: 56px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 1.5rem;
}
.feature__title { font-size: 1rem; font-weight: 700; margin-bottom: .375rem; }
.feature__text { font-size: .875rem; color: var(--text-secondary); margin: 0; line-height: 1.6; }

/* ---- HOW IT WORKS ---- */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.5rem; counter-reset: step; }
.step {
  text-align: center;
  padding: 1.5rem;
  position: relative;
}
.step__number {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-gradient);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.1rem;
  margin: 0 auto 1rem;
  box-shadow: var(--shadow-accent);
}
.step__title { font-size: .95rem; font-weight: 700; margin-bottom: .375rem; }
.step__text { font-size: .85rem; color: var(--text-secondary); margin: 0; }

/* ---- RANGE SLIDER ---- */
.range-group { margin-bottom: 1rem; }
.range-group__header { display: flex; justify-content: space-between; margin-bottom: .5rem; }
.range-group__label { font-size: .85rem; font-weight: 600; color: var(--text-secondary); }
.range-group__value { font-size: .85rem; font-weight: 700; color: var(--accent); }
input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 6px;
  background: var(--border);
  border-radius: 100px;
  outline: none;
  cursor: pointer;
}
input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--card);
  box-shadow: var(--shadow), 0 0 0 1px var(--accent);
  cursor: pointer;
  transition: all var(--transition);
}
input[type="range"]::-webkit-slider-thumb:hover { transform: scale(1.15); }

/* ---- FOOTER ---- */
.site-footer {
  background: var(--card);
  border-top: 1px solid var(--border);
  padding: 3.5rem 0 2rem;
  margin-top: 4rem;
}
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 2rem; margin-bottom: 2rem; }
.footer__heading { font-size: .78rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin-bottom: .875rem; }
.footer__link {
  display: block;
  font-size: .875rem;
  color: var(--text-secondary);
  padding: .3rem 0;
  transition: all var(--transition);
}
.footer__link:hover { color: var(--accent); text-decoration: none; transform: translateX(3px); }
.footer__bottom {
  border-top: 1px solid var(--border);
  padding-top: 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  font-size: .8rem;
  color: var(--muted);
}

/* ---- ADSENSE ---- */
.ad-slot {
  text-align: center;
  margin: 2rem 0;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.ad-slot ins { display: block; width: 100%; }

/* ---- TOAST ---- */
.toast {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  padding: .875rem 1.5rem;
  background: var(--text);
  color: var(--bg);
  border-radius: var(--radius-sm);
  font-size: .875rem;
  font-weight: 600;
  box-shadow: var(--shadow-xl);
  transform: translateY(120px);
  opacity: 0;
  transition: all .35s cubic-bezier(.4,0,.2,1);
  z-index: 1000;
}
.toast.show { transform: translateY(0); opacity: 1; }

/* ---- ARTICLE ---- */
.article { max-width: 720px; margin: 0 auto; }
.article h2 { margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.article h3 { margin-top: 1.5rem; }
.article p { font-size: .95rem; color: var(--text-secondary); }
.article ul, .article ol { color: var(--text-secondary); font-size: .95rem; }
.article blockquote {
  border-left: 4px solid var(--accent);
  padding: 1rem 1.25rem;
  background: var(--accent-light);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin: 1.5rem 0;
  font-style: italic;
  color: var(--text-secondary);
}

/* ---- GUIDE CTA ---- */
.guide-cta {
  background: var(--accent-gradient);
  color: #fff;
  padding: 2.5rem 2rem;
  border-radius: var(--radius);
  text-align: center;
  margin: 2.5rem 0;
  box-shadow: var(--shadow-accent);
  position: relative;
  overflow: hidden;
}
.guide-cta::before {
  content: "";
  position: absolute;
  top: -50%;
  right: -30%;
  width: 60%;
  height: 200%;
  background: rgba(255,255,255,.06);
  border-radius: 50%;
  pointer-events: none;
}
.guide-cta h3 { color: #fff; margin-bottom: .5rem; position: relative; }
.guide-cta p { color: rgba(255,255,255,.85); margin-bottom: 1.25rem; position: relative; }
.guide-cta .btn { background: #fff; color: var(--accent); position: relative; box-shadow: var(--shadow-md); }
.guide-cta .btn:hover { background: rgba(255,255,255,.9); transform: translateY(-1px); }

/* ---- COOKIE BANNER ---- */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-top: 1px solid var(--border);
  padding: 1rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  z-index: 999;
  box-shadow: 0 -4px 30px rgba(0,0,0,.1);
  font-size: .85rem;
}
.cookie-banner.hidden { display: none; }

/* ---- SKIP LINK ---- */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--accent);
  color: #fff;
  padding: .5rem 1rem;
  border-radius: var(--radius-sm);
  z-index: 1000;
  font-weight: 600;
}
.skip-link:focus { top: .5rem; }

/* ---- TOGGLE ---- */
.toggle { display: inline-flex; align-items: center; gap: .5rem; cursor: pointer; font-size: .875rem; }
.toggle__input { display: none; }
.toggle__slider {
  width: 44px;
  height: 24px;
  background: var(--border);
  border-radius: 100px;
  position: relative;
  transition: background var(--transition);
}
.toggle__slider::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  transition: transform var(--transition);
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.toggle__input:checked + .toggle__slider { background: var(--accent); }
.toggle__input:checked + .toggle__slider::after { transform: translateX(20px); }

/* ---- PROGRESS ---- */
.progress { width: 100%; height: 8px; background: var(--border); border-radius: 100px; overflow: hidden; }
.progress__bar { height: 100%; border-radius: 100px; background: var(--accent-gradient); transition: width .4s ease; }
.progress__bar--success { background: var(--accent2-gradient); }
.progress__bar--warning { background: linear-gradient(90deg, var(--warning), #f59e0b); }
.progress__bar--danger { background: linear-gradient(90deg, var(--danger), #ef4444); }

/* ---- TRUST BANNER ---- */
.trust { display: flex; gap: 2rem; justify-content: center; flex-wrap: wrap; padding: 1.5rem 0; color: var(--muted); font-size: .85rem; font-weight: 500; }
.trust__item { display: flex; align-items: center; gap: .5rem; }
.trust__item svg { width: 18px; height: 18px; color: var(--accent2); }

/* ---- ANIMATIONS ---- */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }
@keyframes slideUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-in { animation: slideUp .5s ease both; }
.animate-in:nth-child(2) { animation-delay: .1s; }
.animate-in:nth-child(3) { animation-delay: .2s; }
.animate-in:nth-child(4) { animation-delay: .3s; }

/* ---- FOCUS ---- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- PRINT ---- */
@media print {
  .site-header, .site-footer, .ad-slot, .nav, .theme-toggle,
  .btn-group, .tabs, .no-print, .related, .guide-cta,
  .toast, .cookie-banner, .hero__badge { display: none !important; }
  body { background: #fff; color: #000; font-size: 12pt; }
  .card { box-shadow: none; border: 1px solid #ccc; break-inside: avoid; }
  .container { max-width: 100%; }
  .stat__value { color: #000; }
  .hero::before { display: none; }
  .print-only { display: block !important; }
}
.print-only { display: none; }

/* ---- ANCHOR AD ---- */
.ad-anchor { box-shadow: 0 -2px 8px rgba(0,0,0,.08); }
body { padding-bottom: 98px; }
@media print { .ad-anchor { display: none !important; } body { padding-bottom: 0; } }

/* ---- RESPONSIVE ---- */
@media (max-width: 640px) {
  h1 { font-size: 1.75rem; }
  h2 { font-size: 1.375rem; }
  .section { padding: 2.5rem 0; }
  .hero { padding: 2.5rem 0 2rem; }
  .hero__stats { gap: 1.25rem; }
  .hero__stat-value { font-size: 1.25rem; }
  .form-row { grid-template-columns: 1fr; }
  .stat-grid { grid-template-columns: repeat(2, 1fr); }
  .stat__value { font-size: 1.375rem; }
  .btn--lg { padding: .75rem 1.5rem; font-size: .9rem; }
  .preset-grid { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .trust { gap: 1rem; }
}
