@import url("/assets/fonts/fonts.css");

:root {
  /* warm literary palette — ink on aged paper, terracotta + a deep pine accent */
  --ink: #1c1813;
  --ink-soft: #59514733;
  --ink-70: #5b5348;
  --paper: #efe9dd;
  --paper-2: #e7dfcf;
  --paper-3: #ded4c0;
  --card: #f6f1e7;
  --line: #cdc2ab;
  --line-soft: #d9cfbb;
  --terra: #b0472a;
  --terra-deep: #8f3820;
  --pine: #2f4739;
  --gold: #c98a3a;
  --white: #fbf8f1;

  --maxw: 1180px;
  --display: "Fraunces", "Georgia", serif;
  --body: "Hanken Grotesk", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--body);
  color: var(--ink);
  background-color: var(--paper);
  line-height: 1.6;
  font-size: 18px;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  position: relative;
  overflow-x: hidden;
}

/* paper grain overlay — subtle, tactile, fixed */
body::before {
  content: "";
  position: fixed; inset: 0; z-index: 1; pointer-events: none;
  opacity: 0.5; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.28'/%3E%3C/svg%3E");
}
/* warm vignette glow top-left for depth */
body::after {
  content: "";
  position: fixed; inset: 0; z-index: 0; pointer-events: none;
  background:
    radial-gradient(120% 80% at 8% -10%, rgba(201,138,58,0.14), transparent 55%),
    radial-gradient(100% 90% at 100% 0%, rgba(47,71,57,0.08), transparent 50%);
}
main, .site-header, .masthead, .site-footer { position: relative; z-index: 2; }

img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration: none; }
::selection { background: var(--terra); color: var(--white); }

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

/* ---------- Masthead ---------- */
.masthead {
  font-family: var(--mono); font-size: 11.5px; letter-spacing: 0.05em;
  color: var(--ink-70); background: var(--ink); color: #d8cdb8;
  border-bottom: 1px solid var(--terra);
}
.masthead .wrap { display: flex; justify-content: space-between; gap: 18px; padding: 9px 32px; text-transform: uppercase; }
.masthead span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.masthead .m-right { color: var(--gold); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(150%) blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 74px; }
.brand { display: flex; align-items: center; gap: 13px; font-family: var(--display); font-weight: 500; font-size: 20px; letter-spacing: -0.01em; font-variation-settings: "opsz" 40; }
.brand .mark {
  position: relative; width: 26px; height: 26px; background: var(--ink);
  display: inline-block; flex: none; transform: rotate(0deg); transition: transform .5s var(--ease);
}
.brand .mark::after { content: ""; position: absolute; right: 5px; bottom: 5px; width: 9px; height: 9px; background: var(--paper); }
.brand:hover .mark { transform: rotate(90deg); }
.nav-links { display: flex; gap: 34px; align-items: center; list-style: none; }
.nav-links a { font-size: 15px; color: var(--ink-70); transition: color .18s; position: relative; }
.nav-links a:not(.nav-cta):hover { color: var(--ink); }
.nav-links a:not(.nav-cta)::after { content: ""; position: absolute; left: 0; bottom: -5px; width: 0; height: 1.5px; background: var(--terra); transition: width .26s var(--ease); }
.nav-links a:not(.nav-cta):hover::after { width: 100%; }
.nav-cta { background: var(--ink); color: var(--white) !important; padding: 10px 20px; font-size: 15px !important; transition: background .2s; }
.nav-cta:hover { background: var(--terra); }
.nav-toggle { display: none; background: none; border: 0; font-size: 24px; cursor: pointer; color: var(--ink); line-height: 1; }

/* ---------- Labels ---------- */
.label, .eyebrow {
  font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.16em;
  font-size: 11.5px; color: var(--terra-deep); font-weight: 500; margin-bottom: 22px;
  display: inline-flex; align-items: center; gap: 11px;
}
.label::before, .eyebrow::before { content: ""; width: 8px; height: 8px; background: var(--terra); display: inline-block; }

/* ---------- Reveal on load ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
.reveal { opacity: 0; animation: rise 0.9s var(--ease) forwards; }
.d1{animation-delay:.05s}.d2{animation-delay:.16s}.d3{animation-delay:.27s}.d4{animation-delay:.38s}.d5{animation-delay:.5s}
@media (prefers-reduced-motion: reduce){ .reveal{animation:none;opacity:1} }

/* ---------- Hero ---------- */
.hero { padding: 116px 0 92px; border-bottom: 1px solid var(--line); position: relative; }
/* faint oversized ghost square, decorative */
.hero::after {
  content: ""; position: absolute; right: -60px; top: 40px; width: 340px; height: 340px;
  border: 1px solid var(--line); z-index: -1; transform: rotate(-8deg);
  background: linear-gradient(135deg, rgba(176,71,42,0.05), transparent 60%);
}
.hero .wrap { display: grid; grid-template-columns: 1.5fr 1fr; gap: 68px; align-items: end; }
.hero h1 {
  font-family: var(--display); font-weight: 400;
  font-size: clamp(2.7rem, 6.4vw, 5.1rem); line-height: 0.98;
  letter-spacing: -0.028em; max-width: 15ch;
  font-variation-settings: "opsz" 144, "wght" 380;
  text-wrap: balance;
}
.hero h1 em { font-style: italic; color: var(--terra-deep); font-variation-settings: "opsz" 144, "wght" 400; }
.hero-aside { padding-bottom: 10px; }
.hero-aside p { color: var(--ink-70); font-size: 1.06rem; max-width: 42ch; }
.hero-aside p strong { color: var(--ink); font-weight: 600; }
.hero-aside p + p { margin-top: 16px; }
.hero-aside .btn-row { margin-top: 34px; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 12px;
  background: var(--ink); color: var(--white);
  padding: 16px 28px; font-size: 15.5px; font-weight: 500; letter-spacing: 0.01em;
  transition: background .22s var(--ease), transform .18s var(--ease), box-shadow .22s;
  border: 0; cursor: pointer; box-shadow: 0 1px 0 rgba(0,0,0,0.04);
}
.btn:hover { background: var(--terra); transform: translateY(-2px); box-shadow: 0 12px 26px -12px rgba(176,71,42,0.6); }
.btn .tick { font-family: var(--mono); transition: transform .22s var(--ease); }
.btn:hover .tick { transform: translateX(4px); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { background: var(--ink); color: var(--white); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }

/* ---------- Sections ---------- */
section { padding: 96px 0; }
.section-sm { padding: 56px 0; }
h2 { font-family: var(--display); font-weight: 400; font-size: clamp(1.95rem, 4vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; max-width: 22ch; font-variation-settings: "opsz" 80, "wght" 400; text-wrap: balance; }
h2 em { font-style: italic; color: var(--terra-deep); }
h3 { font-size: 1.2rem; font-weight: 600; margin-bottom: 10px; }
p + p { margin-top: 16px; }
.muted { color: var(--ink-70); }
.prose { max-width: 60ch; }
.prose p { margin-bottom: 20px; color: var(--ink-70); font-size: 1.08rem; }
.prose p strong { color: var(--ink); font-weight: 600; }
/* drop cap on first prose paragraph */
.prose.dropcap > p:first-of-type::first-letter {
  font-family: var(--display); float: left; font-size: 4.4rem; line-height: 0.72;
  padding: 6px 12px 0 0; color: var(--terra-deep); font-variation-settings: "opsz" 144, "wght" 420;
}

/* ---------- Editorial index ---------- */
.index .index-head { margin-bottom: 50px; max-width: 40ch; }
.index-list { list-style: none; counter-reset: idx; border-top: 1.5px solid var(--ink); }
.index-list li { border-bottom: 1px solid var(--line); }
.index-list a {
  display: grid; grid-template-columns: 72px 1fr auto; gap: 30px; align-items: baseline;
  padding: 34px 10px 34px 6px; transition: padding .32s var(--ease), background .32s;
  position: relative;
}
.index-list a::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 0;
  background: linear-gradient(90deg, rgba(176,71,42,0.09), transparent); transition: width .32s var(--ease);
}
.index-list a:hover { padding-left: 26px; }
.index-list a:hover::before { width: 100%; }
.idx-num { counter-increment: idx; font-family: var(--mono); font-size: 13px; color: var(--terra); padding-top: 8px; }
.idx-num::before { content: counter(idx, decimal-leading-zero); }
.idx-body { max-width: 52ch; }
.idx-body h3 { font-family: var(--display); font-weight: 400; font-size: clamp(1.5rem, 2.9vw, 2.15rem); margin-bottom: 8px; letter-spacing: -0.017em; font-variation-settings: "opsz" 72, "wght" 400; transition: color .3s; }
.idx-body p { color: var(--ink-70); font-size: 16px; }
.idx-cat { font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.11em; color: var(--ink-70); white-space: nowrap; padding-top: 9px; }
.index-list a:hover .idx-body h3 { color: var(--terra-deep); }
.index-list a:hover .idx-num { color: var(--terra-deep); }

/* ---------- Recognise ---------- */
.recognise { background: var(--paper-2); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); position: relative; }
.recognise .grid2 { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 60px; align-items: start; }
.recognise ul { list-style: none; display: grid; gap: 0; }
.recognise li { padding: 22px 0 22px 40px; color: var(--ink-70); border-bottom: 1px solid var(--line); position: relative; font-size: 1.05rem; }
.recognise li:first-child { border-top: 1px solid var(--line); }
.recognise li > span { position: absolute; left: 0; top: 22px; color: var(--terra); font-family: var(--display); font-size: 1.3rem; line-height: 1; font-style: italic; }
.recognise li > span::before { content: "→"; font-family: var(--mono); font-style: normal; }

/* ---------- Pull quote ---------- */
.quote { padding: 118px 0; border-bottom: 1px solid var(--line); background:
  linear-gradient(180deg, transparent, rgba(47,71,57,0.03)); }
.quote .wrap { display: grid; grid-template-columns: 90px 1fr; gap: 28px; }
.quote .qmark { font-family: var(--display); font-size: 7rem; line-height: 0.62; color: var(--terra); font-variation-settings: "opsz" 144, "wght" 400; font-style: italic; }
.quote blockquote { font-family: var(--display); font-weight: 400; font-style: italic; font-size: clamp(1.7rem, 4vw, 2.9rem); line-height: 1.18; max-width: 20ch; letter-spacing: -0.015em; font-variation-settings: "opsz" 144, "wght" 380; }
.quote cite { display: block; margin-top: 26px; font-family: var(--mono); font-style: normal; font-size: 12px; letter-spacing: 0.09em; color: var(--ink-70); text-transform: uppercase; }

/* ---------- Facts ---------- */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1.5px solid var(--ink); margin-top: 44px; }
.facts div { padding: 26px 24px 26px 0; border-bottom: 1px solid var(--line); }
.facts .label { margin-bottom: 12px; }
.facts .value { font-family: var(--display); font-size: 1.7rem; letter-spacing: -0.015em; font-variation-settings: "opsz" 60, "wght" 420; }

/* ---------- Testimonials ---------- */
.testimonials { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border-top: 1.5px solid var(--ink); margin-top: 44px; }
.testimonials figure { padding: 34px 28px 34px 0; border-bottom: 1px solid var(--line); }
.testimonials figure:not(:last-child) { border-right: 1px solid var(--line); padding-right: 28px; }
.testimonials figure::before { content: "\201D"; font-family: var(--display); font-size: 2.6rem; color: var(--terra); line-height: 0; display: block; height: 20px; font-style: italic; }
.testimonials blockquote { font-family: var(--display); font-weight: 400; font-size: 1.12rem; line-height: 1.42; color: var(--ink); font-variation-settings: "opsz" 40, "wght" 380; }

/* ---------- CTA band ---------- */
.cta-band { background: var(--pine); color: var(--white); position: relative; overflow: hidden; }
.cta-band::after { content: ""; position: absolute; right: -80px; top: -80px; width: 300px; height: 300px; border: 1px solid rgba(255,255,255,0.12); transform: rotate(12deg); }
.cta-band .wrap { display: grid; grid-template-columns: 1fr auto; gap: 44px; align-items: center; padding: 84px 32px; position: relative; }
.cta-band .label { color: var(--gold); }
.cta-band .label::before { background: var(--gold); }
.cta-band h2 { color: var(--white); font-variation-settings: "opsz" 90, "wght" 400; }
.cta-band p { color: rgba(251,248,241,0.72); max-width: 40ch; margin-top: 18px; font-size: 1.05rem; }
.cta-band .btn { background: var(--white); color: var(--ink); }
.cta-band .btn:hover { background: var(--terra); color: #fff; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--ink); padding: 72px 0 38px; background: var(--paper-3); }
.footer-grid { display: flex; justify-content: space-between; gap: 44px; flex-wrap: wrap; }
.footer-grid .brand { font-size: 22px; }
.footer-grid p { color: var(--ink-70); font-size: 15px; max-width: 32ch; }
.footer-links { list-style: none; display: grid; gap: 13px; }
.footer-links a { font-size: 15px; color: var(--ink-70); transition: color .18s; }
.footer-links a:hover { color: var(--terra-deep); }
.footer-meta { margin-top: 52px; padding-top: 24px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 12px; letter-spacing: 0.03em; color: var(--ink-70); display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; text-transform: uppercase; }
.footer-meta a { color: var(--ink-70); }
.footer-meta a:hover { color: var(--terra-deep); }

/* ---------- Page hero ---------- */
.page-hero { padding: 104px 0 64px; border-bottom: 1px solid var(--line); position: relative; }
.page-hero h1 { font-family: var(--display); font-weight: 400; font-size: clamp(2.3rem, 5.4vw, 4rem); line-height: 1.02; max-width: 19ch; letter-spacing: -0.026em; font-variation-settings: "opsz" 144, "wght" 390; text-wrap: balance; }
.page-hero h1 em { font-style: italic; color: var(--terra-deep); }
.page-hero .lead { color: var(--ink-70); font-size: 1.24rem; margin-top: 26px; max-width: 50ch; }

/* ---------- Steps ---------- */
.steps { counter-reset: step; display: grid; gap: 0; margin-top: 44px; max-width: 62ch; border-top: 1.5px solid var(--ink); }
.step { padding: 30px 0 30px 68px; position: relative; border-bottom: 1px solid var(--line); }
.step::before { counter-increment: step; content: counter(step, decimal-leading-zero); position: absolute; left: 0; top: 30px; font-family: var(--mono); font-size: 13px; color: var(--terra); }
.step h3 { font-family: var(--display); font-weight: 400; font-size: 1.45rem; font-variation-settings: "opsz" 40, "wght" 400; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero .wrap { grid-template-columns: 1fr; gap: 38px; align-items: start; }
  .hero::after { display: none; }
  .recognise .grid2 { grid-template-columns: 1fr; gap: 30px; }
  .cta-band .wrap { grid-template-columns: 1fr; gap: 28px; }
  .facts { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 820px) {
  .masthead .m-mid { display: none; }
  .nav-links { position: fixed; inset: 74px 0 auto 0; background: var(--paper); flex-direction: column; padding: 26px 32px; gap: 22px; border-bottom: 1px solid var(--line); transform: translateY(-135%); transition: transform .3s var(--ease); }
  .nav-links.open { transform: translateY(0); }
  .nav-toggle { display: block; }
  .index-list a { grid-template-columns: 44px 1fr; gap: 18px; }
  .idx-cat { display: none; }
  .testimonials { grid-template-columns: 1fr; }
  .testimonials figure:not(:last-child) { border-right: 0; padding-right: 0; }
  section { padding: 66px 0; }
  .hero { padding: 74px 0 58px; }
  .quote { padding: 76px 0; }
  .quote .wrap { grid-template-columns: 1fr; gap: 10px; }
  .prose.dropcap > p:first-of-type::first-letter { font-size: 3.4rem; }
}
