/* ═══════════════════════════════════════════════════════════
   INKBOUND — Author Studio · brand system v1.0
   Warm literary studio: paper canvas, warm ink, gold-leaf accent
   used sparingly. Fraunces (display) · Albert Sans (UI) ·
   Spectral (reading) · Caveat (handwritten notes).
   A Five Line Studio app — only the Five Line mark persists.
   ═══════════════════════════════════════════════════════════ */

:root {
  /* Gold ramp */
  --gold-50: #FAF1DC; --gold-100: #F1DFAE; --gold-200: #E5C77E;
  --gold-300: #D8B25C; --gold: #CFA34A; --gold-500: #A8842F; --gold-600: #6E541F;
  /* Ink (warm neutral) */
  --ink-300: #A9A08B; --ink-400: #837A66; --ink-500: #6E6757;
  --ink-600: #423A2A; --ink-700: #2C2619; --ink-800: #211C14; --ink-900: #15120C;
  /* Paper */
  --paper-white: #FFFFFF; --paper-50: #FAF7F0; --paper-100: #F5F0E6;
  --paper-200: #EDE6D8; --paper-300: #E2D9C7; --paper-400: #D4C9B3; --paper-500: #BFB39A;
  /* Bindery accents */
  --forest: #21382B; --espresso: #2A2318; --oxblood: #5E2F2A; --slate: #2E3A44;
  /* Semantic */
  --success: #3E7D55; --warning: #C98A2E; --error: #9E4439; --info: #3F6178;

  /* Roles */
  --bg: var(--paper-100);
  --surface: var(--paper-50);
  --surface-2: #FFFFFF;
  --text: var(--ink-900);
  --text-soft: var(--ink-600);
  --muted: var(--ink-500);
  --faint: var(--ink-400);
  --line: #E2D9C7;
  --line-strong: #D4C9B3;

  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --ui: "Albert Sans", -apple-system, "Segoe UI", system-ui, sans-serif;
  --reading: "Spectral", Georgia, serif;
  --hand: "Caveat", cursive;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --max: 1180px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
[id] { scroll-margin-top: 92px; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--ui);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
button { font: inherit; cursor: pointer; }
::selection { background: var(--gold-200); color: var(--ink-900); }
:focus-visible { outline: 2px solid var(--gold-500); outline-offset: 3px; border-radius: 3px; }

.skip-link {
  position: absolute; left: 16px; top: -60px; z-index: 200;
  background: var(--ink-900); color: var(--paper-50);
  font-size: 13px; padding: 12px 18px; border-radius: 8px; transition: top 0.2s;
}
.skip-link:focus { top: 16px; }

.wrap { max-width: var(--max); margin: 0 auto; padding: 0 32px; }

/* ── Type ── */
.overline {
  font-family: var(--ui); font-size: 12px; font-weight: 600;
  letter-spacing: 0.22em; text-transform: uppercase; color: var(--gold-500);
}
.overline.muted { color: var(--faint); }
.display { font-family: var(--display); font-weight: 600; line-height: 1.04; letter-spacing: -0.02em; color: var(--ink-900); }
h1.display { font-weight: 600; font-size: clamp(44px, 6.4vw, 74px); letter-spacing: -0.025em; }
h2.display { font-size: clamp(30px, 4vw, 46px); }
h3.display { font-size: clamp(22px, 2.6vw, 30px); }
.lede { font-size: clamp(18px, 1.7vw, 21px); line-height: 1.6; color: var(--text-soft); max-width: 600px; }
.reading { font-family: var(--reading); }

/* ── Buttons ── */
.btn {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--ui); font-size: 15px; font-weight: 600; letter-spacing: 0.01em;
  padding: 14px 24px; border-radius: 12px; border: 1.5px solid transparent;
  transition: transform 0.2s var(--ease), box-shadow 0.2s, background 0.2s, border-color 0.2s, color 0.2s;
}
.btn .arr { transition: transform 0.2s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn:hover .arr { transform: translateX(4px); }
.btn:active { transform: translateY(0) scale(0.985); }
.btn-gold { background: var(--gold); color: var(--ink-900); border-color: var(--gold); }
.btn-gold:hover { background: var(--gold-300); box-shadow: 0 12px 30px rgba(207, 163, 74, 0.32); }
.btn-ink { background: var(--ink-900); color: var(--paper-50); border-color: var(--ink-900); }
.btn-ink:hover { background: var(--ink-700); box-shadow: 0 12px 30px rgba(21, 18, 12, 0.22); }
.btn-ghost { border-color: var(--line-strong); color: var(--ink-900); background: transparent; }
.btn-ghost:hover { border-color: var(--ink-900); }

/* ── Header ── */
.ib-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(245, 240, 230, 0.82);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.ib-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 18px; height: 76px; }
.ib-logo { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.ib-logo .mark { width: 36px; height: 36px; flex-shrink: 0; }
.ib-logo .mark svg { width: 100%; height: 100%; border-radius: 9px; box-shadow: 0 2px 8px rgba(110, 84, 31, 0.22); }
.ib-logo .word { font-family: var(--display); font-weight: 600; font-size: 22px; letter-spacing: -0.01em; color: var(--ink-900); line-height: 1; }
.ib-logo .sub { font-family: var(--ui); font-size: 9px; font-weight: 600; letter-spacing: 0.24em; text-transform: uppercase; color: var(--faint); margin-top: 3px; }
.ib-nav { display: flex; align-items: center; gap: 28px; font-family: var(--ui); font-size: 15px; font-weight: 500; }
.ib-nav a:not(.cta) { color: var(--muted); transition: color 0.2s; position: relative; padding: 6px 0; }
.ib-nav a:not(.cta)::after { content: ""; position: absolute; left: 0; bottom: 0; height: 2px; width: 100%; background: var(--gold); transform: scaleX(0); transform-origin: right; transition: transform 0.25s var(--ease); }
.ib-nav a:not(.cta):hover, .ib-nav a.active { color: var(--ink-900); }
.ib-nav a:not(.cta):hover::after, .ib-nav a.active::after { transform: scaleX(1); transform-origin: left; }
.ib-nav a.cta { background: var(--gold); color: var(--ink-900); padding: 10px 18px; border-radius: 10px; font-weight: 600; transition: transform 0.2s, box-shadow 0.2s, background 0.2s; }
.ib-nav a.cta:hover { transform: translateY(-1px); background: var(--gold-300); box-shadow: 0 8px 20px rgba(207,163,74,0.3); }

/* Persistent Five Line badge */
.fl-badge { display: inline-flex; align-items: center; gap: 8px; color: var(--faint); transition: color 0.2s; }
.fl-badge:hover { color: var(--ink-900); }
.fl-badge svg { display: block; color: var(--ink-900); }
.fl-badge .by { font-family: var(--ui); font-size: 9px; font-weight: 600; letter-spacing: 0.16em; text-transform: uppercase; line-height: 1.3; }

/* Hamburger */
.ib-burger { display: none; align-items: center; justify-content: center; width: 40px; height: 40px; border: 1px solid var(--line-strong); border-radius: 9px; background: transparent; flex-shrink: 0; }
.ib-burger .bars { position: relative; width: 18px; height: 12px; }
.ib-burger .bars span { position: absolute; left: 0; width: 18px; height: 2px; border-radius: 2px; background: var(--ink-900); transition: transform 0.28s var(--ease), opacity 0.2s; }
.ib-burger .bars span:nth-child(1) { top: 0; }
.ib-burger .bars span:nth-child(2) { top: 5px; }
.ib-burger .bars span:nth-child(3) { top: 10px; }
.ib-burger[aria-expanded="true"] .bars span:nth-child(1) { transform: translateY(5px) rotate(45deg); }
.ib-burger[aria-expanded="true"] .bars span:nth-child(2) { opacity: 0; }
.ib-burger[aria-expanded="true"] .bars span:nth-child(3) { transform: translateY(-5px) rotate(-45deg); }
.ib-menu { position: fixed; inset: 0; z-index: 45; background: var(--paper-50); display: flex; flex-direction: column; padding: 100px 32px 40px; transform: translateY(-12px); opacity: 0; visibility: hidden; transition: transform 0.35s var(--ease), opacity 0.3s, visibility 0.35s; overflow-y: auto; }
.ib-menu.is-open { transform: translateY(0); opacity: 1; visibility: visible; }
.ib-menu a.ml { font-family: var(--display); font-weight: 600; font-size: clamp(28px, 8vw, 40px); color: var(--ink-900); padding: 18px 0; border-bottom: 1px solid var(--line); }
.ib-menu a.ml:hover { color: var(--gold-500); }
.ib-menu .ml-back { margin-top: auto; padding-top: 32px; }
body.menu-open { overflow: hidden; }

/* ── Sections ── */
section { padding: 96px 0; }
.section-head { margin-bottom: 52px; max-width: 720px; }
.section-head .overline { display: block; margin-bottom: 16px; }
.section-head p { color: var(--text-soft); margin-top: 14px; }
.reveal { opacity: 0; transform: translateY(24px); transition: opacity 0.8s var(--ease), transform 0.8s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.08s; } .reveal.d2 { transition-delay: 0.16s; } .reveal.d3 { transition-delay: 0.24s; }

/* ── Hero ── */
.hero { position: relative; padding: 92px 0 64px; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: radial-gradient(900px 500px at 78% -10%, rgba(207,163,74,0.14), transparent 60%); pointer-events: none; }
.hero-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 56px; align-items: center; }
.hero .overline { display: block; margin-bottom: 22px; }
.hero h1 { margin-bottom: 22px; }
.hero h1 em { font-style: italic; color: var(--gold-500); }
.hero .lede { margin-bottom: 34px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-meta { margin-top: 28px; display: flex; gap: 22px; flex-wrap: wrap; font-family: var(--ui); font-size: 13px; color: var(--muted); }
.hero-meta .mi { display: inline-flex; align-items: center; gap: 8px; }
.hero-meta .mi svg { width: 18px; height: 18px; color: var(--gold-500); }

/* App window mockup */
.app-window { background: var(--surface-2); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; box-shadow: 0 30px 70px rgba(33, 28, 20, 0.16); }
.aw-bar { height: 38px; display: flex; align-items: center; gap: 7px; padding: 0 14px; background: var(--paper-100); border-bottom: 1px solid var(--line); }
.aw-bar i { width: 11px; height: 11px; border-radius: 50%; display: block; }
.aw-bar i:nth-child(1) { background: #E0C089; } .aw-bar i:nth-child(2) { background: #D4C9B3; } .aw-bar i:nth-child(3) { background: #C7B79A; }
.aw-bar .aw-title { flex: 1; text-align: center; font-size: 11px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--faint); }
.aw-body { display: grid; grid-template-columns: 116px 1fr; min-height: 320px; }
.aw-side { background: var(--ink-900); padding: 18px 14px; display: flex; flex-direction: column; gap: 4px; }
.aw-side .s-logo { display: flex; align-items: center; gap: 8px; margin-bottom: 16px; }
.aw-side .s-logo .m { width: 22px; height: 22px; } .aw-side .s-logo .m svg { border-radius: 6px; }
.aw-side .s-logo span { font-family: var(--display); font-weight: 600; font-size: 14px; color: var(--paper-50); }
.aw-side .s-item { font-size: 12.5px; color: var(--ink-300); padding: 8px 10px; border-radius: 8px; display: flex; align-items: center; gap: 8px; }
.aw-side .s-item svg { width: 15px; height: 15px; }
.aw-side .s-item.active { background: rgba(207,163,74,0.16); color: var(--gold); }
.aw-main { padding: 22px 24px; }
.aw-main .am-title { font-family: var(--display); font-weight: 600; font-size: 19px; color: var(--ink-900); margin-bottom: 4px; }
.aw-main .am-sub { font-size: 12px; color: var(--muted); margin-bottom: 16px; }
.aw-line { height: 9px; border-radius: 5px; background: var(--paper-200); margin-bottom: 10px; }
.aw-read { font-family: var(--reading); font-size: 13.5px; line-height: 1.7; color: var(--ink-600); }
.aw-read .dropcap { float: left; font-family: var(--display); font-weight: 600; font-size: 46px; line-height: 0.8; color: var(--gold-500); padding: 4px 8px 0 0; }
.aw-float { position: absolute; right: -14px; bottom: -16px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; box-shadow: 0 16px 40px rgba(33,28,20,0.16); display: flex; align-items: center; gap: 10px; max-width: 240px; }
.aw-float .ai-dot { width: 26px; height: 26px; border-radius: 8px; background: rgba(207,163,74,0.18); color: var(--gold-500); display: grid; place-items: center; flex-shrink: 0; }
.aw-float .ai-dot svg { width: 16px; height: 16px; }
.aw-float .ai-t { font-size: 12px; color: var(--text-soft); line-height: 1.4; }
.aw-float .ai-t b { font-family: var(--ui); font-weight: 600; color: var(--ink-900); }
.hero-stage { position: relative; }

/* ── Workflow rail (Library → Publish) ── */
.flow { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.flow-step { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 22px 18px; transition: transform 0.25s var(--ease), border-color 0.25s, box-shadow 0.25s; }
.flow-step:hover { transform: translateY(-4px); border-color: var(--line-strong); box-shadow: 0 14px 34px rgba(33,28,20,0.08); }
.flow-step .fs-ico { width: 30px; height: 30px; color: var(--gold-500); margin-bottom: 14px; }
.flow-step .fs-n { font-family: var(--ui); font-size: 11px; font-weight: 600; letter-spacing: 0.16em; color: var(--faint); }
.flow-step h3 { font-family: var(--display); font-weight: 600; font-size: 19px; margin: 4px 0 6px; }
.flow-step p { font-size: 13.5px; color: var(--muted); line-height: 1.5; }

/* ── Feature blocks ── */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.feature + .feature { margin-top: 88px; }
.feature.flip .feat-text { order: 2; }
.feat-text .overline { display: block; margin-bottom: 16px; }
.feat-text h2 { margin-bottom: 16px; }
.feat-text p { color: var(--text-soft); margin-bottom: 18px; }
.feat-list { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.feat-list li { display: flex; gap: 12px; font-size: 15.5px; color: var(--text-soft); }
.feat-list li svg { width: 20px; height: 20px; color: var(--gold-500); flex-shrink: 0; margin-top: 2px; }
.feat-visual { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 30px; min-height: 320px; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }

/* AI staff cards */
.staff-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 18px; }
.staff { background: var(--surface-2); border: 1px solid var(--line); border-radius: 14px; padding: 24px; transition: transform 0.25s var(--ease), box-shadow 0.25s; }
.staff:hover { transform: translateY(-4px); box-shadow: 0 16px 38px rgba(33,28,20,0.1); }
.staff .st-ico { width: 32px; height: 32px; color: var(--gold-500); margin-bottom: 16px; }
.staff h3 { font-family: var(--display); font-weight: 600; font-size: 19px; margin-bottom: 8px; }
.staff p { font-size: 14px; color: var(--muted); line-height: 1.55; }

/* Cover lab visual */
.cover-stack { position: relative; width: 100%; height: 300px; display: flex; align-items: center; justify-content: center; }
.book-cover { position: absolute; width: 150px; height: 226px; border-radius: 4px 8px 8px 4px; box-shadow: 0 20px 44px rgba(33,28,20,0.32); display: flex; flex-direction: column; justify-content: space-between; padding: 18px 16px; }
.book-cover .bc-kicker { font-family: var(--ui); font-size: 8px; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.75; }
.book-cover .bc-title { font-family: var(--display); font-weight: 600; font-size: 22px; line-height: 1.05; }
.book-cover .bc-author { font-family: var(--ui); font-size: 9px; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.85; }
.book-cover.b1 { transform: rotate(-9deg) translateX(-58px); background: var(--forest); color: #E7E0CE; }
.book-cover.b2 { transform: rotate(3deg); z-index: 2; background: var(--oxblood); color: #F0E2D2; }
.book-cover.b3 { transform: rotate(12deg) translateX(58px); background: var(--slate); color: #DDE5EC; }
.book-cover.float { animation: bob 6s ease-in-out infinite; }
.book-cover.b2.float { animation-delay: .8s; } .book-cover.b3.float { animation-delay: 1.5s; }
@keyframes bob { 0%,100% { translate: 0 0; } 50% { translate: 0 -10px; } }

/* ── Pull quote (reading surface) ── */
.pullquote { background: var(--ink-900); color: var(--paper-100); border-radius: 18px; padding: 64px 56px; position: relative; overflow: hidden; }
.pullquote .overline { color: var(--gold); display: block; margin-bottom: 20px; }
.pullquote blockquote { font-family: var(--reading); font-size: clamp(22px, 3vw, 32px); line-height: 1.4; color: var(--paper-50); max-width: 760px; }
.pullquote .note { font-family: var(--hand); font-size: 24px; color: var(--gold-200); margin-top: 24px; transform: rotate(-2deg); }

/* ── Platforms / specs strip ── */
.specs { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.spec { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 24px; }
.spec .sp-n { font-family: var(--display); font-weight: 600; font-size: 28px; color: var(--ink-900); }
.spec .sp-l { font-size: 13px; color: var(--muted); margin-top: 6px; }

/* ── CTA band ── */
.cta-band { background: linear-gradient(180deg, var(--ink-800), var(--ink-900)); color: var(--paper-100); border-radius: 20px; padding: 64px 56px; display: flex; align-items: center; justify-content: space-between; gap: 36px; flex-wrap: wrap; position: relative; overflow: hidden; }
.cta-band::before { content: ""; position: absolute; right: -40px; top: -40px; width: 260px; height: 260px; background: radial-gradient(circle, rgba(207,163,74,0.2), transparent 70%); pointer-events: none; }
.cta-band h2 { color: var(--paper-50); margin-bottom: 10px; }
.cta-band p { color: var(--paper-300); max-width: 440px; }
.cta-actions { display: flex; flex-direction: column; gap: 12px; }
.cta-actions .btn { justify-content: center; }
.cta-fine { font-size: 12px; color: var(--ink-300); text-align: center; }

/* ── Footer ── */
.ib-footer { border-top: 1px solid var(--line); padding: 56px 0 40px; }
.ib-footer .f-grid { display: flex; justify-content: space-between; gap: 40px; flex-wrap: wrap; align-items: flex-start; margin-bottom: 44px; }
.ib-footer .f-links { display: flex; gap: 52px; flex-wrap: wrap; }
.ib-footer .f-col { display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.ib-footer .f-col .h { font-family: var(--ui); font-size: 10px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--faint); margin-bottom: 6px; }
.ib-footer .f-col a { color: var(--muted); transition: color 0.2s; }
.ib-footer .f-col a:hover { color: var(--gold-500); }
.ib-footer .f-base { display: flex; justify-content: space-between; gap: 18px; flex-wrap: wrap; border-top: 1px solid var(--line); padding-top: 22px; font-size: 12px; letter-spacing: 0.04em; color: var(--faint); }

/* ── Responsive ── */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .flow { grid-template-columns: repeat(3, 1fr); }
  .feature, .feature.flip .feat-text { grid-template-columns: 1fr; order: 0; }
  .feature { gap: 32px; }
  .specs { grid-template-columns: repeat(2, 1fr); }
  .cta-band { flex-direction: column; align-items: flex-start; padding: 44px 36px; }
}
@media (max-width: 920px) {
  .ib-nav a:not(.cta), .ib-nav a.cta { display: none; }
  .ib-burger { display: inline-flex; }
}
@media (max-width: 620px) {
  .wrap { padding: 0 20px; }
  section { padding: 68px 0; }
  .flow { grid-template-columns: 1fr 1fr; }
  .pullquote, .cta-band { padding: 36px 28px; }
}
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition-duration: 0.01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
