/* ============================================================
   holdway - institutional digital-asset custody
   Visual direction locked to Refero "Slab" style reference.
   Primary traits preserved: berry-ink hero, Sentinel-serif display
   (Merriweather) w/ negative tracking, Whitney-sans body (Inter) w/
   positive tracking, Slab-red CTA-only, 6px radius, flat depth.
   ============================================================ */

/* ---- Tokens ---- */
:root {
  /* Color - roles preserved from Slab reference */
  --berry-ink: #42022e;        /* hero / dark sections ONLY */
  --berry-hi:  #5a0a3f;        /* berry gradient highlight */
  --berry-lo:  #2c011d;        /* berry gradient shadow */
  --slab-red:  #ff4143;        /* primary CTA ONLY */
  --slab-red-press: #e7383a;
  --slab-blue: #4285f4;        /* OAuth / integration button ONLY */

  --white:     #ffffff;
  --near-black:#000000;
  --slate:     #455360;        /* secondary text */
  --ash:       #939598;        /* tertiary text */
  --border:    #e0e0e0;
  --off-white: #f1f1f1;

  /* Decorative illustration accents (muted, decorative role ONLY) */
  --acc-cyan:  #00d5a0;
  --acc-blue:  #0061ff;
  --acc-sky:   #50c5dc;
  --acc-violet:#253858;

  /* Type */
  --font-display: "Merriweather", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Shape */
  --radius: 6px;
  --maxw: 1120px;
  --gutter: clamp(20px, 5vw, 40px);
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.5;
  letter-spacing: 0.27px;
  color: var(--near-black);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }

/* ---- Typography ---- */
.display, .display-sm, h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 400;
  color: var(--near-black);
  text-wrap: balance;
}
.display {
  font-size: clamp(38px, 6vw, 53px);
  line-height: 1.02;
  letter-spacing: -1px;
}
.display-sm, h2 {
  font-size: clamp(30px, 4.4vw, 42px);
  line-height: 1.14;
  letter-spacing: -0.8px;
  font-weight: 300;
}
h3 {
  font-size: 24px;
  line-height: 1.2;
  letter-spacing: -0.4px;
}
.eyebrow {
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ash);
}
.lead { font-size: 18px; line-height: 1.6; letter-spacing: 0.3px; color: var(--slate); }
.muted { color: var(--slate); }
p { text-wrap: pretty; }

/* ---- Layout ---- */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: clamp(56px, 9vw, 96px); }
.section--tight { padding-block: clamp(40px, 6vw, 64px); }
.berry { background: var(--berry-ink); color: var(--white); }
/* Text treatment for the purple/berry background - applies to both solid
   berry sections and the gradient hero, including all subpage heroes. */
.berry .eyebrow, .hero-bg .eyebrow { color: rgba(255,255,255,0.6); }
.berry .muted, .berry .lead,
.hero-bg .muted, .hero-bg .lead { color: rgba(255,255,255,0.85); } /* slightly softer white */
.berry .display, .berry .display-sm, .berry h1, .berry h2, .berry h3,
.hero-bg .display, .hero-bg .display-sm, .hero-bg h1, .hero-bg h2, .hero-bg h3 { color: var(--white); } /* bright white */

/* ---- Buttons (6px radius, flat) ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  border-radius: var(--radius);
  padding: 14px 22px;
  font-size: 15px; font-weight: 600; letter-spacing: 0.2px;
  border: 1px solid transparent;
  transition: background-color .16s ease, color .16s ease, border-color .16s ease, transform .16s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--slab-red); color: var(--white); }       /* CTA-only red */
.btn--primary:hover { background: var(--slab-red-press); }
.btn--ghost { background: transparent; color: var(--slate); border-color: var(--slate); }
.btn--ghost:hover { border-color: var(--near-black); color: var(--near-black); }
.berry .btn--ghost { color: var(--white); border-color: rgba(255,255,255,0.45); }
.berry .btn--ghost:hover { border-color: var(--white); background: rgba(255,255,255,0.06); }
.btn--google { background: var(--slab-blue); color: var(--white); border-radius: 2px; }
.btn--google:hover { filter: brightness(0.96); }
.btn--block { width: 100%; }
.btn--lg { padding: 16px 26px; font-size: 16px; }

.link {
  color: var(--slate); font-weight: 500;
  border-bottom: 1px solid transparent; padding-bottom: 1px;
  transition: border-color .15s ease, color .15s ease;
}
.link:hover { color: var(--near-black); border-color: var(--near-black); }
.link--red { color: var(--slab-red); }
.link--red:hover { color: var(--slab-red-press); border-color: var(--slab-red); }

/* focus visibility */
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--slab-red); outline-offset: 2px; border-radius: var(--radius);
}

/* ---- Header / nav ---- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(140%) blur(10px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; gap: 28px; height: 68px; }
.brand {
  font-family: var(--font-display); font-weight: 700; font-size: 22px;
  letter-spacing: -0.6px; color: var(--near-black); display: inline-flex; align-items: center; gap: 2px;
}
.brand .dot { color: var(--slab-red); }
.nav__links { display: flex; gap: 26px; margin-left: 8px; }
.nav__links a {
  font-size: 15px; font-weight: 500; color: var(--slate);
  transition: color .15s ease;
}
.nav__links a:hover { color: var(--near-black); }
.nav__spacer { flex: 1; }
.nav__actions { display: flex; align-items: center; gap: 16px; }
.nav__actions .link { font-size: 15px; }
.nav__toggle { display: none; background: none; border: 0; padding: 8px; }
.nav__toggle span { display: block; width: 22px; height: 2px; background: var(--near-black); margin: 4px 0; transition: .2s; }

/* ---- Hero ---- */
.hero { position: relative; overflow: clip; }
.hero-bg {
  background:
    radial-gradient(900px 480px at 80% -10%, rgba(0,213,160,0.10), transparent 60%),
    radial-gradient(700px 460px at 5% 110%, rgba(0,97,255,0.12), transparent 55%),
    linear-gradient(125deg, var(--berry-hi) 0%, var(--berry-ink) 52%, var(--berry-lo) 100%);
}
.hero__inner { padding-block: clamp(64px, 11vw, 128px); text-align: center; position: relative; z-index: 2; }
.hero__inner .display { max-width: 16ch; margin-inline: auto; }
.hero__inner .lead { max-width: 56ch; margin: 22px auto 0; }
.hero__eyebrow { margin-bottom: 20px; }

/* email capture pill */
.signup {
  margin: 34px auto 0; max-width: 520px;
  display: flex; gap: 10px; background: var(--white);
  border-radius: var(--radius); padding: 8px; box-shadow: 0 1px 0 rgba(0,0,0,.04);
}
.signup input {
  flex: 1; border: 0; background: transparent; padding: 10px 12px;
  font: inherit; color: var(--near-black); letter-spacing: 0.27px;
}
.signup input::placeholder { color: var(--ash); }
.signup .btn { flex: none; }
.hero__sub { margin-top: 16px; font-size: 13.5px; color: rgba(255,255,255,0.66); letter-spacing: 0.3px; }
.hero__sub b { color: rgba(255,255,255,0.92); font-weight: 600; }

/* floating decorative shapes (decorative role only) */
.hero__shape { position: absolute; z-index: 1; border-radius: 30% 70% 70% 30% / 30% 30% 70% 70%; filter: blur(2px); opacity: .5; }
.hero__shape--1 { width: 220px; height: 220px; left: -60px; top: 40px; background: radial-gradient(circle at 30% 30%, var(--acc-sky), transparent 70%); }
.hero__shape--2 { width: 280px; height: 280px; right: -80px; bottom: -40px; background: radial-gradient(circle at 60% 40%, var(--acc-violet), transparent 72%); }

/* ---- Trust wall ---- */
.trust { border-bottom: 1px solid var(--border); }
.trust__label { text-align: center; color: var(--ash); font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; }
.logos { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: clamp(28px, 6vw, 64px); margin-top: 26px; }
.logos span {
  font-family: var(--font-display); font-weight: 700; font-size: 19px; letter-spacing: -0.4px;
  color: var(--ash); opacity: .85;
}

/* ---- Feature rows (alternating two-column) ---- */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.feature + .feature { margin-top: clamp(56px, 9vw, 104px); }
.feature--flip .feature__media { order: -1; }
.feature__body h2 { margin-bottom: 16px; }
.feature__body .lead { margin-bottom: 22px; }
.feature__list { list-style: none; padding: 0; display: grid; gap: 12px; margin-bottom: 26px; }
.feature__list li { display: flex; gap: 12px; align-items: flex-start; color: var(--slate); }
.feature__list .tick {
  flex: none; width: 22px; height: 22px; border-radius: var(--radius);
  background: var(--off-white); color: var(--slab-red); display: grid; place-items: center;
  font-size: 13px; font-weight: 700; margin-top: 1px;
}

/* framed product-UI placeholder (honest schematic, not a fake screenshot) */
.frame {
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--white);
  overflow: hidden; box-shadow: 0 8px 30px rgba(66,2,46,0.06);
}
.frame__bar { display: flex; align-items: center; gap: 6px; padding: 12px 14px; border-bottom: 1px solid var(--border); background: var(--off-white); }
.frame__bar i { width: 9px; height: 9px; border-radius: 50%; background: var(--border); display: block; }
.frame__bar small { margin-left: 8px; color: var(--ash); font-size: 12px; letter-spacing: .3px; }
.frame__body { padding: 20px; }
.kvrow { display: flex; justify-content: space-between; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--border); }
.kvrow:last-child { border-bottom: 0; }
.kvrow .asset { display: flex; align-items: center; gap: 12px; }
.kvrow .chip { width: 30px; height: 30px; border-radius: var(--radius); display: grid; place-items: center; color: #fff; font-size: 12px; font-weight: 700; font-family: var(--font-body); }
.kvrow .name { font-weight: 600; font-size: 14px; }
.kvrow .sub { font-size: 12px; color: var(--ash); }
.kvrow .bal { font-variant-numeric: tabular-nums; font-weight: 600; font-size: 14px; }
.kvrow .pill { font-size: 11px; font-weight: 600; color: var(--acc-cyan); background: rgba(0,213,160,0.10); padding: 3px 8px; border-radius: 20px; }

/* abstract illustration block (CSS-native, matches Slab flat geometric imagery) */
.illus { position: relative; aspect-ratio: 4 / 3; border-radius: var(--radius); background: var(--off-white); overflow: hidden; border: 1px solid var(--border); }
.illus span { position: absolute; display: block; }
.illus .s1 { width: 46%; height: 46%; left: 12%; top: 14%; background: var(--acc-violet); border-radius: 20px; opacity: .9; }
.illus .s2 { width: 38%; height: 38%; right: 10%; top: 26%; background: var(--acc-cyan); border-radius: 50%; mix-blend-mode: multiply; }
.illus .s3 { width: 30%; height: 30%; left: 30%; bottom: 10%; background: var(--acc-sky); border-radius: 8px 40px 8px 40px; }
.illus .s4 { width: 14%; height: 14%; right: 24%; bottom: 18%; background: var(--slab-red); border-radius: 50%; }

/* ---- Stats ---- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(20px, 4vw, 40px); }
.stat .num { font-family: var(--font-display); font-weight: 300; font-size: clamp(34px, 4.5vw, 46px); letter-spacing: -1px; }
.stat .lab { color: rgba(255,255,255,0.66); font-size: 14px; margin-top: 6px; }
.stats--3 { grid-template-columns: repeat(3, 1fr); }

/* ---- Testimonial ---- */
.quote { max-width: 22ch; }
.quote blockquote { font-family: var(--font-display); font-weight: 300; font-size: clamp(26px, 3.6vw, 38px); line-height: 1.24; letter-spacing: -0.6px; }
.quote .cite { margin-top: 24px; color: var(--slate); font-size: 15px; }
.quote .cite b { color: var(--near-black); font-weight: 600; }

/* ---- CTA band ---- */
.cta-band { text-align: center; }
.cta-band .display-sm { max-width: 18ch; margin: 0 auto 24px; }
.cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---- Footer ---- */
.footer { background: var(--berry-ink); color: rgba(255,255,255,0.72); }
.footer__grid { display: grid; grid-template-columns: 1.6fr repeat(3, 1fr); gap: 40px; padding-block: 64px; }
.footer .brand { color: #fff; }
.footer__tag { margin-top: 14px; max-width: 30ch; font-size: 14px; color: rgba(255,255,255,0.6); }
.footer__col h4 { font-family: var(--font-body); font-size: 13px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: rgba(255,255,255,0.5); margin-bottom: 14px; }
.footer__col a { display: block; padding: 6px 0; font-size: 14px; color: rgba(255,255,255,0.78); }
.footer__col a:hover { color: #fff; }
.footer__bottom { border-top: 1px solid rgba(255,255,255,0.12); padding-block: 22px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 13px; color: rgba(255,255,255,0.5); }

/* ---- Auth card (login stub) - Slab sign-up form block ---- */
.authwrap { min-height: calc(100vh - 68px); display: grid; place-items: center; padding-block: 64px; }
.auth { width: 100%; max-width: 420px; }
.auth__card { background: #fff; border: 1px solid var(--border); border-radius: var(--radius); padding: clamp(28px, 5vw, 40px); box-shadow: 0 10px 40px rgba(66,2,46,0.08); }
.auth h1 { font-size: 28px; letter-spacing: -0.6px; margin-bottom: 6px; }
.auth .lead { font-size: 15px; margin-bottom: 26px; }
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; color: var(--slate); margin-bottom: 7px; }
.field input {
  width: 100%; padding: 12px; font: inherit; letter-spacing: 0.27px;
  border: 1px solid var(--near-black); border-radius: var(--radius); background: #fff; color: var(--near-black);
}
.field input::placeholder { color: var(--ash); }
.auth__divider { display: flex; align-items: center; gap: 14px; color: var(--ash); font-size: 13px; margin: 22px 0; }
.auth__divider::before, .auth__divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.auth__foot { text-align: center; margin-top: 22px; font-size: 14px; color: var(--slate); }

/* ---- Generic stub page hero ---- */
.page-hero { text-align: center; }
.page-hero .display-sm { margin-bottom: 16px; }
.page-hero .lead { max-width: 56ch; margin-inline: auto; }
.badge-soon { display: inline-block; margin-bottom: 18px; padding: 6px 12px; border: 1px solid rgba(255,255,255,0.3); border-radius: 20px; font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,0.8); }

/* ---- Responsive ---- */
@media (max-width: 860px) {
  .nav__links, .nav__actions .link { display: none; }
  .nav__toggle { display: block; }
  .nav[data-open="true"] .nav__links {
    display: flex; flex-direction: column; gap: 4px;
    position: absolute; left: 0; right: 0; top: 68px;
    background: #fff; border-bottom: 1px solid var(--border); padding: 12px var(--gutter) 18px;
  }
  .nav[data-open="true"] .nav__links a { padding: 10px 0; font-size: 16px; }
  .feature { grid-template-columns: 1fr; }
  .feature--flip .feature__media { order: 0; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .quote { max-width: none; }
}
@media (max-width: 520px) {
  .signup { flex-direction: column; }
  .signup .btn { width: 100%; }
  .stats { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; transition: none !important; }
}
