/* ============================================
   superhtml.de — Bookify-Inspired Design System
   Editorial Warmth · Deep Purple · Cream Canvas
   ============================================ */

/* ── Local Fonts ─────────────────────────── */
/* Outfit — latin-ext */
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Outfit — latin */
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/outfit-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Outfit';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('/fonts/outfit-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Young Serif — latin-ext */
@font-face {
  font-family: 'Young Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/young-serif-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Young Serif — latin */
@font-face {
  font-family: 'Young Serif';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('/fonts/young-serif-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ── Tokens ───────────────────────────────── */
:root {
  --purple-900: #1E0A3C;
  --purple-800: #2D1065;
  --purple-700: #3B0A8C;
  --purple-600: #5B21B6;
  --purple-500: #7C3AED;
  --purple-400: #A78BFA;
  --purple-100: #EDE9FE;
  --purple-50:  #F5F3FF;

  --cream:      #EDE5D4;
  --cream-light:#F5EFE3;
  --cream-dark: #E0D5C1;
  --cream-card: #F9F6F0;
  --white:      #FFFFFF;

  --text-primary:   #1E0A3C;
  --text-secondary:  #5A4D6E;
  --text-muted:     #8B7F9E;
  --text-on-purple: #F5F3FF;

  --ff-display: 'Young Serif', Georgia, serif;
  --ff-body:    'Outfit', system-ui, sans-serif;

  --fs-hero:    clamp(2.75rem, 2rem + 4vw, 5rem);
  --fs-2xl:     clamp(2rem, 1.5rem + 2.5vw, 3.25rem);
  --fs-xl:      clamp(1.4rem, 1.1rem + 1.5vw, 1.85rem);
  --fs-lg:      1.1875rem;
  --fs-body:    1.0625rem;
  --fs-sm:      0.9375rem;
  --fs-xs:      0.8125rem;
  --fs-xxs:     0.75rem;

  --lh-body:    1.7;
  --lh-tight:   1.12;

  --space-2xs:  0.375rem;
  --space-xs:   0.5rem;
  --space-sm:   0.75rem;
  --space-md:   1.25rem;
  --space-lg:   2rem;
  --space-xl:   clamp(3rem, 2.5rem + 2.5vw, 5rem);
  --space-2xl:  clamp(5rem, 4rem + 4vw, 9rem);

  --max-w:      1200px;
  --radius-sm:  10px;
  --radius-md:  16px;
  --radius-lg:  24px;
  --radius-pill: 999px;

  --shadow-card:
    0 1px 3px rgba(30, 10, 60, .03),
    0 6px 24px rgba(30, 10, 60, .05);
  --shadow-card-hover:
    0 4px 12px rgba(30, 10, 60, .06),
    0 20px 48px rgba(30, 10, 60, .1);

  --ease-out:    cubic-bezier(.22, 1, .36, 1);
  --ease-spring: cubic-bezier(.34, 1.56, .64, 1);
  --dur:         .3s;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--ff-body);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  color: var(--text-primary);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
em { font-style: normal; }

a {
  color: var(--purple-600);
  text-decoration: none;
  transition: color var(--dur) var(--ease-out);
}
a:hover {
  color: var(--purple-500);
}

::selection {
  background: var(--purple-100);
  color: var(--purple-900);
}

/* ── Typography ──────────────────────────── */
h1, h2, h3, h4 {
  font-family: var(--ff-display);
  font-weight: 400;
  line-height: var(--lh-tight);
  color: var(--text-primary);
  text-wrap: balance;
}

h1 { font-size: var(--fs-hero); }
h2 { font-size: var(--fs-2xl); }
h3 { font-size: var(--fs-xl); }

/* ── Utilities ───────────────────────────── */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding-inline: var(--space-lg);
}

.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;
}

/* Scroll-reveal (only when JS is active) */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .65s var(--ease-out), transform .65s var(--ease-out);
}
.js .reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .js .reveal { opacity: 1; transform: none; transition: none; }
}

/* Pill button */
.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: .625rem;
  padding: .875rem 2rem;
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--white);
  background: var(--purple-600);
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  text-decoration: none;
  transition:
    background var(--dur) var(--ease-out),
    transform var(--dur) var(--ease-out),
    box-shadow var(--dur) var(--ease-out);
}
.btn-pill:hover {
  background: var(--purple-500);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(91, 33, 182, .25);
}
.btn-pill svg {
  width: 18px;
  height: 18px;
  transition: transform var(--dur) var(--ease-spring);
}
.btn-pill:hover svg {
  transform: translateX(3px);
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--cream);
  transition: background var(--dur), box-shadow var(--dur);
}

.site-header.is-scrolled {
  background: rgba(237, 229, 212, .92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 1px 0 rgba(30, 10, 60, .06), 0 4px 16px rgba(30, 10, 60, .03);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  transition: height var(--dur) var(--ease-out);
}

.is-scrolled .header-inner { height: 60px; }

/* Brand */
.site-brand {
  text-decoration: none;
  color: var(--text-primary);
  display: flex;
  align-items: baseline;
  gap: var(--space-sm);
  flex-shrink: 0;
}
.site-brand:hover { color: var(--text-primary); }

.site-brand__name {
  font-family: var(--ff-display);
  font-size: 1.5rem;
  line-height: 1;
}
.site-brand__name em {
  color: var(--purple-600);
}
.site-brand__name em::before {
  content: '<';
  color: var(--purple-400);
}
.site-brand__name em::after {
  content: '/>';
  color: var(--purple-400);
}

.site-brand__tagline {
  font-size: var(--fs-xs);
  color: var(--text-muted);
  font-weight: 500;
  letter-spacing: .02em;
  display: none;
}

/* Desktop nav */
.nav-main { display: none; }

.nav-main__list {
  list-style: none;
  display: flex;
  gap: var(--space-2xs);
}

.nav-main__link {
  display: block;
  padding: var(--space-xs) var(--space-sm);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: var(--fs-sm);
  font-weight: 500;
  border-radius: var(--radius-pill);
  transition: color var(--dur), background var(--dur);
  white-space: nowrap;
}

.nav-main__link:hover {
  color: var(--purple-600);
  background: var(--purple-50);
}

.nav-main__link--active {
  color: var(--purple-600);
  background: var(--purple-100);
  font-weight: 600;
}

/* Hamburger */
.nav-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: none;
  border: none;
  cursor: pointer;
  border-radius: var(--radius-sm);
  transition: background var(--dur);
}
.nav-toggle:hover { background: var(--purple-50); }

.nav-toggle__bar {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  position: relative;
  transition: background var(--dur);
}
.nav-toggle__bar::before,
.nav-toggle__bar::after {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--dur) var(--ease-out);
}
.nav-toggle__bar::before { transform: translateY(-6px); }
.nav-toggle__bar::after  { transform: translateY(6px); }

.nav-toggle[aria-expanded="true"] .nav-toggle__bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::before { transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::after  { transform: rotate(-45deg); }

/* Mobile nav */
.nav-mobile {
  display: none;
  background: var(--cream-light);
  border-top: 1px solid var(--cream-dark);
}

.nav-mobile.is-open {
  display: block;
  animation: mobileNavIn .35s var(--ease-out);
}

@keyframes mobileNavIn {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}

.nav-mobile__list {
  list-style: none;
  padding: var(--space-sm) 0;
}

.nav-mobile__link {
  display: block;
  padding: var(--space-sm) var(--space-lg);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: var(--fs-body);
  font-weight: 500;
  transition: color var(--dur), background var(--dur);
}
.nav-mobile__link:hover {
  color: var(--purple-600);
  background: var(--purple-50);
}
.nav-mobile__link--active {
  color: var(--purple-600);
  font-weight: 600;
}

/* ============================================
   HERO (Homepage)
   ============================================ */
.hero {
  padding: var(--space-xl) 0 var(--space-2xl);
  position: relative;
  overflow: hidden;
}

.hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-xl);
  align-items: center;
}

.hero__content {
  max-width: 600px;
}

.hero__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--purple-600);
  margin-bottom: var(--space-md);
}

.hero__label::before {
  content: '';
  display: block;
  width: 8px;
  height: 8px;
  background: var(--purple-500);
  border-radius: 50%;
}

.hero__title {
  margin-bottom: var(--space-lg);
  color: var(--purple-900);
}

.hero__title em {
  color: var(--purple-600);
}

.hero__lead {
  font-size: var(--fs-lg);
  color: var(--text-secondary);
  max-width: 520px;
  font-weight: 400;
  line-height: 1.75;
  margin-bottom: var(--space-lg);
}

/* Code window visual */
.hero__visual {
  display: none;
}

.code-window {
  background: var(--purple-900);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow:
    0 4px 16px rgba(30, 10, 60, .12),
    0 24px 64px rgba(30, 10, 60, .15);
  transform: rotate(1.5deg);
  transition: transform .5s var(--ease-out);
  max-width: 420px;
  margin-left: auto;
}

.code-window:hover {
  transform: rotate(0deg) translateY(-4px);
}

.code-window__bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: .875rem 1.125rem;
  background: rgba(255, 255, 255, .06);
  border-bottom: 1px solid rgba(255, 255, 255, .06);
}

.code-window__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .15);
}
.code-window__dot:nth-child(1) { background: #FF5F57; }
.code-window__dot:nth-child(2) { background: #FFBD2E; }
.code-window__dot:nth-child(3) { background: #28CA42; }

.code-window__title {
  margin-left: .5rem;
  font-family: var(--ff-body);
  font-size: var(--fs-xxs);
  color: rgba(255, 255, 255, .4);
  font-weight: 500;
}

.code-window__code {
  padding: 1.25rem 1.5rem;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: .8125rem;
  line-height: 1.85;
  color: rgba(255, 255, 255, .65);
  overflow-x: auto;
  white-space: pre;
}

.code-tag { color: #C792EA; }
.code-attr { color: #FFCB6B; }
.code-val { color: #C3E88D; }
.code-text { color: rgba(255, 255, 255, .85); }

/* ============================================
   BENTO GRID
   ============================================ */
.bento {
  padding: 0 0 var(--space-2xl);
}

.bento__label {
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--text-muted);
  margin-bottom: var(--space-lg);
}

.bento__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}

/* Card base */
.bento-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-lg) var(--space-lg) var(--space-lg);
  border-radius: var(--radius-lg);
  text-decoration: none;
  color: var(--text-primary);
  overflow: hidden;
  min-height: 220px;
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .05);
  box-shadow: var(--shadow-card);
  transition:
    transform var(--dur) var(--ease-out),
    box-shadow var(--dur) var(--ease-out);
}

.bento-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-card-hover);
  color: var(--text-primary);
}

.bento-card__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--purple-50);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--space-md);
  color: var(--purple-600);
  transition: background var(--dur), transform var(--dur) var(--ease-spring);
}

.bento-card:hover .bento-card__icon {
  background: var(--purple-100);
  transform: scale(1.05);
}

.bento-card__tag {
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--purple-600);
  margin-bottom: var(--space-xs);
}

.bento-card__title {
  font-family: var(--ff-display);
  font-size: var(--fs-xl);
  line-height: var(--lh-tight);
  margin-bottom: var(--space-xs);
  color: var(--text-primary);
}

.bento-card__desc {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: var(--space-md);
}

.bento-card__cta {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--purple-600);
  margin-top: auto;
  transition: gap var(--dur) var(--ease-out);
}

.bento-card:hover .bento-card__cta {
  gap: .75rem;
}

.bento-card__cta svg {
  width: 16px;
  height: 16px;
  transition: transform var(--dur) var(--ease-spring);
}

.bento-card:hover .bento-card__cta svg {
  transform: translateX(3px);
}

/* Featured card */
.bento-card--featured {
  background: var(--purple-900);
  color: var(--cream-light);
  border: none;
}

.bento-card--featured .bento-card__icon {
  background: rgba(255, 255, 255, .08);
  color: var(--purple-400);
}
.bento-card--featured:hover .bento-card__icon {
  background: rgba(255, 255, 255, .12);
}

.bento-card--featured .bento-card__tag { color: var(--purple-400); }
.bento-card--featured .bento-card__title { color: var(--white); }
.bento-card--featured .bento-card__desc { color: rgba(255, 255, 255, .6); }
.bento-card--featured .bento-card__cta { color: var(--white); }
.bento-card--featured:hover { color: var(--cream-light); }

/* Stagger animation */
.bento-card.reveal:nth-child(1) { transition-delay: 0s; }
.bento-card.reveal:nth-child(2) { transition-delay: .08s; }
.bento-card.reveal:nth-child(3) { transition-delay: .16s; }
.bento-card.reveal:nth-child(4) { transition-delay: .24s; }

/* ============================================
   TOP 3 EDITORS
   ============================================ */
.top3 {
  padding: var(--space-xl) 0 var(--space-2xl);
  background: var(--cream-light);
}

.top3__header {
  margin-bottom: var(--space-xl);
}

.top3__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--purple-600);
  margin-bottom: var(--space-sm);
}

.top3__label::before {
  content: '';
  display: block;
  width: 8px;
  height: 8px;
  background: var(--purple-500);
  border-radius: 50%;
}

.top3__title {
  margin-bottom: var(--space-xs);
}

.top3__subtitle {
  font-size: var(--fs-lg);
  color: var(--text-secondary);
  font-weight: 400;
}

.top3__grid {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  margin-bottom: var(--space-xl);
}

/* Editor card */
.editor-card {
  display: flex;
  gap: var(--space-lg);
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  border: 1px solid rgba(30, 10, 60, .05);
  box-shadow: var(--shadow-card);
  transition:
    transform var(--dur) var(--ease-out),
    box-shadow var(--dur) var(--ease-out);
}

.editor-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-card-hover);
}

.editor-card__rank {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--ff-display);
  font-size: 1.5rem;
  color: var(--purple-600);
  background: var(--purple-50);
  border-radius: var(--radius-md);
  transition: background var(--dur), color var(--dur);
}

.editor-card:hover .editor-card__rank {
  background: var(--purple-600);
  color: var(--white);
}

.editor-card__body {
  flex: 1;
  min-width: 0;
}

.editor-card__head {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  margin-bottom: var(--space-xs);
  flex-wrap: wrap;
}

.editor-card__name {
  font-size: var(--fs-xl);
  line-height: 1.2;
}

.editor-card__badge {
  display: inline-block;
  padding: .25rem .75rem;
  font-size: var(--fs-xxs);
  font-weight: 600;
  letter-spacing: .03em;
  border-radius: var(--radius-pill);
  background: var(--cream-dark);
  color: var(--text-secondary);
  white-space: nowrap;
}

.editor-card__badge--free {
  background: var(--purple-100);
  color: var(--purple-600);
}

.editor-card__desc {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: var(--space-md);
}

.editor-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-md) var(--space-xl);
}

.editor-card__meta-label {
  display: block;
  font-size: var(--fs-xxs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
  margin-bottom: var(--space-2xs);
}

.editor-card__tags {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  list-style: none;
}

.editor-card__tags li {
  padding: .2rem .625rem;
  font-size: var(--fs-xxs);
  font-weight: 500;
  color: var(--text-muted);
  background: var(--cream);
  border-radius: var(--radius-pill);
}

.top3__action {
  text-align: center;
}

/* Stagger */
.editor-card.reveal:nth-child(1) { transition-delay: 0s; }
.editor-card.reveal:nth-child(2) { transition-delay: .1s; }
.editor-card.reveal:nth-child(3) { transition-delay: .2s; }

@media (min-width: 640px) {
  .editor-card__rank {
    width: 56px;
    height: 56px;
    font-size: 1.75rem;
  }
}

/* ============================================
   SUBPAGE — Page Header
   ============================================ */
.page-hero {
  padding: var(--space-2xl) 0 var(--space-xl);
}

.page-hero__label {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--purple-600);
  margin-bottom: var(--space-md);
}

.page-hero__label::before {
  content: '';
  display: block;
  width: 8px;
  height: 8px;
  background: var(--purple-500);
  border-radius: 50%;
}

.page-hero__title {
  margin-bottom: var(--space-md);
  color: var(--purple-900);
}

.page-hero__title em {
  color: var(--purple-600);
}

.page-hero__subtitle {
  font-size: var(--fs-lg);
  color: var(--text-secondary);
  font-weight: 400;
  max-width: 600px;
  line-height: 1.75;
}

/* Content area */
.content-area {
  max-width: 720px;
  padding-bottom: var(--space-2xl);
}

.placeholder-notice {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .06);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  color: var(--text-secondary);
  font-size: var(--fs-body);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.placeholder-notice::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--purple-500), var(--purple-400));
  border-radius: 4px 0 0 4px;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--purple-900);
  color: rgba(255, 255, 255, .6);
  padding: var(--space-xl) 0;
  position: relative;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.footer-top {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
}

.footer-brand {
  font-family: var(--ff-display);
  font-size: 1.25rem;
  color: var(--white);
}
.footer-brand em {
  color: var(--purple-400);
}
.footer-brand em::before {
  content: '<';
  color: var(--purple-300);
}
.footer-brand em::after {
  content: '/>';
  color: var(--purple-300);
}

.footer-tagline {
  font-size: var(--fs-sm);
  color: rgba(255, 255, 255, .4);
  font-weight: 400;
}

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
  font-size: var(--fs-sm);
}

.footer-bottom a {
  color: rgba(255, 255, 255, .5);
  text-decoration: none;
  transition: color var(--dur);
}
.footer-bottom a:hover { color: var(--white); }

.footer-copy {
  color: rgba(255, 255, 255, .25);
  font-size: var(--fs-xs);
}

/* ============================================
   RESPONSIVE
   ============================================ */

/* ≥ 640px — Tablet */
@media (min-width: 640px) {
  .site-brand__tagline { display: block; }

  .bento__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .bento-card--featured {
    grid-column: 1 / -1;
    min-height: 280px;
  }

  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
  }

  .footer-bottom {
    align-items: flex-end;
    text-align: right;
  }
}

/* ≥ 960px — Desktop */
@media (min-width: 960px) {
  .nav-main { display: block; }
  .nav-toggle { display: none; }
  .nav-mobile { display: none !important; }

  .hero__inner {
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
  }

  .hero__visual {
    display: block;
  }

  .bento__grid {
    grid-template-columns: 1.2fr .8fr .8fr;
    grid-template-rows: auto auto;
  }

  .bento-card--featured {
    grid-column: 1 / 2;
    grid-row: 1 / 3;
    min-height: 420px;
  }

  .bento-card { min-height: 200px; }
}

/* ============================================
   TUTORIAL PAGE
   ============================================ */

/* Article wrapper */
.tutorial {
  max-width: 780px;
  padding-bottom: var(--space-2xl);
}

/* Table of Contents */
.toc {
  background: var(--white);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin-bottom: var(--space-xl);
  border: 1px solid rgba(30, 10, 60, .05);
  box-shadow: var(--shadow-card);
}

.toc__label {
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--purple-600);
  margin-bottom: var(--space-md);
}

.toc__list {
  list-style: none;
  counter-reset: toc;
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
}

.toc__list li {
  counter-increment: toc;
}

.toc__link {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--dur), background var(--dur);
}

.toc__link::before {
  content: counter(toc, decimal-leading-zero);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 28px;
  font-size: var(--fs-xxs);
  font-weight: 600;
  color: var(--purple-600);
  background: var(--purple-50);
  border-radius: 8px;
  flex-shrink: 0;
  transition: background var(--dur), color var(--dur);
}

.toc__link:hover {
  color: var(--purple-600);
  background: var(--purple-50);
}

.toc__link:hover::before {
  background: var(--purple-600);
  color: var(--white);
}

/* Tutorial sections */
.tutorial__section {
  padding-top: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--cream-dark);
}

.tutorial__section:last-child {
  border-bottom: none;
}

.tutorial__step-badge {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--purple-600);
  background: var(--purple-50);
  padding: .3rem .875rem;
  border-radius: var(--radius-pill);
  margin-bottom: var(--space-md);
}

.tutorial__heading {
  font-size: var(--fs-2xl);
  margin-bottom: var(--space-lg);
}

.tutorial__subheading {
  font-size: var(--fs-xl);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.tutorial__section p {
  margin-bottom: var(--space-md);
  line-height: var(--lh-body);
}

.tutorial__section p:last-child {
  margin-bottom: 0;
}

.tutorial__section code {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: .875em;
  background: var(--purple-50);
  color: var(--purple-700);
  padding: .15em .4em;
  border-radius: 6px;
}

/* Tutorial lists */
.tutorial__list,
.tutorial__checklist {
  margin-bottom: var(--space-md);
  padding-left: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.tutorial__list li,
.tutorial__checklist li {
  line-height: var(--lh-body);
}

.tutorial__checklist {
  list-style: none;
  padding-left: 0;
  counter-reset: checklist;
}

.tutorial__checklist li {
  counter-increment: checklist;
  padding-left: 3rem;
  position: relative;
}

.tutorial__checklist li::before {
  content: counter(checklist);
  position: absolute;
  left: 0;
  top: .15em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--purple-600);
  background: var(--purple-50);
  border-radius: 10px;
}

/* Tip box */
.tutorial__tip {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .06);
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-lg);
  margin-top: var(--space-md);
  margin-bottom: var(--space-md);
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.tutorial__tip::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--purple-500), var(--purple-400));
  border-radius: 4px 0 0 4px;
}

.tutorial__tip strong {
  color: var(--text-primary);
}

.tutorial__tip a {
  font-weight: 500;
}

/* Comparison table */
.tutorial__comparison {
  margin: var(--space-md) 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.tutorial__table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  font-size: var(--fs-sm);
}

.tutorial__table th,
.tutorial__table td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--cream-dark);
}

.tutorial__table thead th {
  background: var(--purple-900);
  color: var(--white);
  font-weight: 600;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: .04em;
}

.tutorial__table thead th:first-child {
  background: var(--purple-900);
}

.tutorial__table tbody tr:last-child td {
  border-bottom: none;
}

.tutorial__table-label {
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
}

.tutorial__table td {
  color: var(--text-secondary);
}

/* Inline code windows (no rotation, full width) */
.code-window--inline {
  transform: none;
  max-width: 100%;
  margin: var(--space-md) 0;
  border-radius: var(--radius-md);
}

.code-window--inline:hover {
  transform: none;
}

/* Code comment color */
.code-comment {
  color: rgba(255, 255, 255, .35);
}

/* FAQ Accordion */
.faq {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.faq__item {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .06);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  transition: box-shadow var(--dur) var(--ease-out);
}

.faq__item[open] {
  box-shadow: var(--shadow-card-hover);
}

.faq__question {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-lg);
  font-size: var(--fs-body);
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
  transition: color var(--dur);
}

.faq__question::-webkit-details-marker {
  display: none;
}

.faq__question::after {
  content: '';
  display: block;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--purple-600);
  border-bottom: 2px solid var(--purple-600);
  transform: rotate(45deg);
  margin-left: auto;
  flex-shrink: 0;
  transition: transform var(--dur) var(--ease-out);
}

.faq__item[open] .faq__question::after {
  transform: rotate(-135deg);
}

.faq__question:hover {
  color: var(--purple-600);
}

.faq__answer {
  padding: 0 var(--space-lg) var(--space-lg);
  color: var(--text-secondary);
  font-size: var(--fs-sm);
  line-height: var(--lh-body);
}

.faq__answer p {
  margin: 0;
}

/* Tutorial section without top border for FAQ */
.tutorial__section--faq {
  padding-top: var(--space-xl);
}

/* ── Tutorial Responsive ──────────────────── */
@media (min-width: 640px) {
  .toc__list {
    columns: 2;
    gap: var(--space-2xs);
  }

  .toc__list li {
    break-inside: avoid;
  }

  .tutorial__table th,
  .tutorial__table td {
    padding: var(--space-sm) var(--space-lg);
  }
}

/* ============================================
   COMPARISON PAGE
   ============================================ */

/* Article wrapper (reused for comparison & resource pages) */
.article {
  max-width: 780px;
  padding-bottom: var(--space-2xl);
}

.article__section {
  padding-top: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--cream-dark);
}

.article__section:last-child {
  border-bottom: none;
}

.article__section p {
  margin-bottom: var(--space-md);
  line-height: var(--lh-body);
}

.article__section p:last-child {
  margin-bottom: 0;
}

.article__badge {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--purple-600);
  background: var(--purple-50);
  padding: .3rem .875rem;
  border-radius: var(--radius-pill);
  margin-bottom: var(--space-md);
}

.article__heading {
  font-size: var(--fs-2xl);
  margin-bottom: var(--space-lg);
}

.article__subheading {
  font-size: var(--fs-xl);
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.article__section code {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: .875em;
  background: var(--purple-50);
  color: var(--purple-700);
  padding: .15em .4em;
  border-radius: 6px;
}

/* Quick-overview comparison table */
.compare-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  font-size: var(--fs-sm);
  margin: var(--space-md) 0;
}

.compare-table th,
.compare-table td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--cream-dark);
}

.compare-table thead th {
  background: var(--purple-900);
  color: var(--white);
  font-weight: 600;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: .04em;
  white-space: nowrap;
}

.compare-table tbody tr:last-child td {
  border-bottom: none;
}

.compare-table tbody tr {
  transition: background var(--dur);
}

.compare-table tbody tr:hover {
  background: var(--purple-50);
}

.compare-table__name {
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
}

.compare-table__highlight {
  background: var(--purple-50);
}

/* Overflow wrapper for tables */
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: var(--space-md) 0;
  border-radius: var(--radius-lg);
}

/* Rating dots */
.rating {
  display: inline-flex;
  gap: 3px;
}

.rating__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--cream-dark);
}

.rating__dot--filled {
  background: var(--purple-500);
}

/* Price badge */
.badge {
  display: inline-block;
  padding: .2rem .625rem;
  font-size: var(--fs-xxs);
  font-weight: 600;
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

.badge--free {
  background: var(--purple-100);
  color: var(--purple-600);
}

.badge--paid {
  background: var(--cream-dark);
  color: var(--text-secondary);
}

.badge--freemium {
  background: #FEF3C7;
  color: #92400E;
}

/* OS badge */
.os-badges {
  display: flex;
  gap: var(--space-2xs);
  flex-wrap: wrap;
}

.os-badge {
  display: inline-block;
  padding: .15rem .5rem;
  font-size: var(--fs-xxs);
  font-weight: 500;
  color: var(--text-muted);
  background: var(--cream);
  border-radius: var(--radius-pill);
  white-space: nowrap;
}

/* Editor detail card (extended) */
.editor-detail {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .05);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-card);
  margin-bottom: var(--space-md);
  transition: box-shadow var(--dur) var(--ease-out);
}

.editor-detail:hover {
  box-shadow: var(--shadow-card-hover);
}

.editor-detail__header {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
}

.editor-detail__rank {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--ff-display);
  font-size: 1.5rem;
  color: var(--purple-600);
  background: var(--purple-50);
  border-radius: var(--radius-md);
}

.editor-detail__title-group {
  flex: 1;
  min-width: 0;
}

.editor-detail__name {
  font-size: var(--fs-xl);
  line-height: 1.2;
  margin-bottom: var(--space-2xs);
}

.editor-detail__subtitle {
  font-size: var(--fs-sm);
  color: var(--text-muted);
}

.editor-detail__badges {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
  align-self: center;
}

.editor-detail__desc {
  font-size: var(--fs-body);
  color: var(--text-secondary);
  line-height: var(--lh-body);
  margin-bottom: var(--space-md);
}

/* Pro/Contra lists */
.pro-contra {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
  margin: var(--space-md) 0;
}

.pro-contra__col h4 {
  font-family: var(--ff-body);
  font-size: var(--fs-xs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  margin-bottom: var(--space-sm);
}

.pro-contra__col--pro h4 { color: #16A34A; }
.pro-contra__col--contra h4 { color: #DC2626; }

.pro-contra__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.pro-contra__list li {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  padding-left: 1.5rem;
  position: relative;
  line-height: 1.6;
}

.pro-contra__col--pro .pro-contra__list li::before {
  content: '+';
  position: absolute;
  left: 0;
  font-weight: 700;
  color: #16A34A;
}

.pro-contra__col--contra .pro-contra__list li::before {
  content: '\2212';
  position: absolute;
  left: 0;
  font-weight: 700;
  color: #DC2626;
}

/* Specs/meta row */
.editor-specs {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-xl);
  padding-top: var(--space-md);
  border-top: 1px solid var(--cream-dark);
}

.editor-specs__item {
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
}

.editor-specs__label {
  font-size: var(--fs-xxs);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--text-muted);
}

.editor-specs__value {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--text-primary);
}

/* Tip box (reusable outside tutorial) */
.tip-box {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .06);
  border-radius: var(--radius-md);
  padding: var(--space-md) var(--space-lg);
  margin: var(--space-md) 0;
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  box-shadow: var(--shadow-card);
  position: relative;
  overflow: hidden;
}

.tip-box::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(to bottom, var(--purple-500), var(--purple-400));
  border-radius: 4px 0 0 4px;
}

.tip-box strong {
  color: var(--text-primary);
}

.tip-box a {
  font-weight: 500;
}

/* Decision box */
.decision-box {
  background: var(--purple-50);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  margin: var(--space-md) 0;
}

.decision-box__title {
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--purple-600);
  margin-bottom: var(--space-xs);
}

.decision-box__text {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  line-height: 1.65;
}

.decision-box__text strong {
  color: var(--text-primary);
}

/* ============================================
   DOWNLOAD PAGE
   ============================================ */

.download-card {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .05);
  border-radius: var(--radius-lg);
  padding: var(--space-lg);
  box-shadow: var(--shadow-card);
  margin-bottom: var(--space-md);
  transition: box-shadow var(--dur) var(--ease-out), transform var(--dur) var(--ease-out);
}

.download-card:hover {
  box-shadow: var(--shadow-card-hover);
  transform: translateY(-2px);
}

.download-card__header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-md);
  flex-wrap: wrap;
}

.download-card__icon {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--purple-50);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-600);
  flex-shrink: 0;
  font-family: var(--ff-display);
  font-size: 1.25rem;
}

.download-card__title-group {
  flex: 1;
  min-width: 0;
}

.download-card__name {
  font-size: var(--fs-xl);
  line-height: 1.2;
  margin-bottom: var(--space-2xs);
}

.download-card__meta {
  display: flex;
  gap: var(--space-xs);
  flex-wrap: wrap;
  align-items: center;
  font-size: var(--fs-xxs);
  color: var(--text-muted);
}

.download-card__desc {
  font-size: var(--fs-sm);
  color: var(--text-secondary);
  line-height: 1.65;
  margin-bottom: var(--space-md);
}

.download-card__features {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
}

.download-card__features li {
  padding: .2rem .625rem;
  font-size: var(--fs-xxs);
  font-weight: 500;
  color: var(--text-muted);
  background: var(--cream);
  border-radius: var(--radius-pill);
}

.download-card__actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.download-card__btn {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .625rem 1.25rem;
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  border-radius: var(--radius-pill);
  text-decoration: none;
  transition: background var(--dur), transform var(--dur), box-shadow var(--dur);
}

.download-card__btn--primary {
  background: var(--purple-600);
  color: var(--white);
}

.download-card__btn--primary:hover {
  background: var(--purple-500);
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(91, 33, 182, .2);
}

.download-card__btn--secondary {
  background: var(--cream);
  color: var(--text-secondary);
}

.download-card__btn--secondary:hover {
  background: var(--cream-dark);
  color: var(--text-primary);
}

.download-card__btn svg {
  width: 16px;
  height: 16px;
}

/* ============================================
   RESOURCE PAGE
   ============================================ */

/* Reference table */
.ref-table {
  width: 100%;
  border-collapse: collapse;
  background: var(--white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  font-size: var(--fs-sm);
  margin: var(--space-md) 0;
}

.ref-table th,
.ref-table td {
  padding: var(--space-sm) var(--space-md);
  text-align: left;
  border-bottom: 1px solid var(--cream-dark);
}

.ref-table thead th {
  background: var(--purple-900);
  color: var(--white);
  font-weight: 600;
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: .04em;
}

.ref-table tbody tr:last-child td {
  border-bottom: none;
}

.ref-table tbody tr:hover {
  background: var(--purple-50);
}

.ref-table code {
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', monospace;
  font-size: .875em;
  background: var(--purple-50);
  color: var(--purple-700);
  padding: .15em .4em;
  border-radius: 6px;
}

/* Resource link cards */
.resource-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-sm);
  margin: var(--space-md) 0;
}

.resource-link {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-md) var(--space-lg);
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .05);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--text-primary);
  box-shadow: var(--shadow-card);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out);
}

.resource-link:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card-hover);
  color: var(--text-primary);
}

.resource-link__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--purple-50);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--purple-600);
  flex-shrink: 0;
}

.resource-link__icon svg {
  width: 20px;
  height: 20px;
}

.resource-link__text {
  flex: 1;
  min-width: 0;
}

.resource-link__name {
  font-weight: 600;
  font-size: var(--fs-sm);
  margin-bottom: 2px;
}

.resource-link__desc {
  font-size: var(--fs-xs);
  color: var(--text-muted);
}

.resource-link__arrow {
  color: var(--purple-400);
  flex-shrink: 0;
  transition: transform var(--dur) var(--ease-spring);
}

.resource-link__arrow svg {
  width: 16px;
  height: 16px;
}

.resource-link:hover .resource-link__arrow {
  transform: translateX(3px);
  color: var(--purple-600);
}

/* Color swatch */
.color-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: var(--space-sm);
  margin: var(--space-md) 0;
}

.color-swatch {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-card);
}

.color-swatch__preview {
  height: 48px;
}

.color-swatch__info {
  padding: var(--space-xs) var(--space-sm);
}

.color-swatch__name {
  font-size: var(--fs-xs);
  font-weight: 600;
  color: var(--text-primary);
}

.color-swatch__hex {
  font-family: 'SF Mono', 'Fira Code', monospace;
  font-size: var(--fs-xxs);
  color: var(--text-muted);
}

/* ── Comparison/Download/Resource Responsive ── */
@media (min-width: 640px) {
  .pro-contra {
    grid-template-columns: 1fr 1fr;
  }

  .resource-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .compare-table th,
  .compare-table td {
    padding: var(--space-sm) var(--space-lg);
  }

  .editor-detail__header {
    flex-wrap: nowrap;
  }
}

@media (min-width: 960px) {
  .resource-grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ============================================
   IMPRINT PAGE
   ============================================ */
.imprint__section {
  background: var(--white);
  border: 1px solid rgba(30, 10, 60, .05);
  border-radius: var(--radius-md);
  padding: var(--space-lg);
  margin-bottom: var(--space-md);
  box-shadow: var(--shadow-card);
}

.imprint__heading {
  font-size: var(--fs-lg);
  margin-bottom: var(--space-sm);
  color: var(--purple-900);
}

.imprint__section p {
  line-height: var(--lh-body);
  color: var(--text-secondary);
  margin-bottom: var(--space-sm);
}

.imprint__section p:last-child {
  margin-bottom: 0;
}

.imprint__section a {
  font-weight: 500;
  word-break: break-all;
}

.imprint__source {
  font-size: var(--fs-xs);
  color: var(--text-muted);
  margin-top: var(--space-sm);
}

.imprint__section h3 {
  font-family: var(--ff-body);
  font-size: var(--fs-body);
  font-weight: 600;
  color: var(--text-primary);
  margin-top: var(--space-md);
  margin-bottom: var(--space-xs);
}

.imprint__section h3:first-child {
  margin-top: 0;
}

.imprint__section ul {
  list-style: none;
  padding-left: 0;
  margin-bottom: var(--space-sm);
  display: flex;
  flex-direction: column;
  gap: var(--space-2xs);
}

.imprint__section ul li {
  padding-left: 1.25rem;
  position: relative;
  color: var(--text-secondary);
  line-height: var(--lh-body);
}

.imprint__section ul li::before {
  content: '';
  position: absolute;
  left: 0;
  top: .65em;
  width: 6px;
  height: 6px;
  background: var(--purple-400);
  border-radius: 50%;
}

/* Footer links */
.footer-links {
  display: flex;
  gap: var(--space-md);
}

/* ============================================
   COOKIE CONSENT
   ============================================ */
.cookie-consent {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  background: var(--purple-900);
  color: rgba(255, 255, 255, .8);
  padding: var(--space-md) 0;
  transform: translateY(100%);
  transition: transform .4s var(--ease-out);
  box-shadow: 0 -4px 24px rgba(30, 10, 60, .2);
}

.cookie-consent.is-visible {
  transform: translateY(0);
}

.cookie-consent__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding-inline: var(--space-lg);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.cookie-consent__text {
  font-size: var(--fs-sm);
  line-height: 1.6;
}

.cookie-consent__text a {
  color: var(--purple-400);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-consent__text a:hover {
  color: var(--white);
}

.cookie-consent__actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.cookie-consent__btn {
  display: inline-flex;
  align-items: center;
  padding: .625rem 1.5rem;
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  border: none;
  border-radius: var(--radius-pill);
  cursor: pointer;
  transition: background var(--dur), transform var(--dur), box-shadow var(--dur);
  white-space: nowrap;
}

.cookie-consent__btn--accept {
  background: var(--purple-500);
  color: var(--white);
}

.cookie-consent__btn--accept:hover {
  background: var(--purple-400);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(124, 58, 237, .3);
}

@media (min-width: 640px) {
  .cookie-consent__inner {
    flex-direction: row;
    align-items: center;
  }

  .cookie-consent__text {
    flex: 1;
  }

  .cookie-consent__actions {
    flex-shrink: 0;
  }
}
