/* =========================================================
   Quantum — B2B platform for PE portfolio administration,
   risk & reporting. Design system.
   ========================================================= */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600&family=IBM+Plex+Sans:wght@400;500;600&display=swap');

:root{
  --ink:        #101820;
  --ink-soft:   #4B5763;
  --ink-faint:  #8B93A0;
  --paper:      #F6F4EE;
  --paper-2:    #ECE8DD;
  --paper-3:    #FBFAF7;
  --line:       #DAD4C4;
  --brass:      #AD8036;
  --brass-dark: #8C6626;
  --teal:       #2B5148;
  --teal-soft:  #E4E9E6;
  --white:      #ffffff;

  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'IBM Plex Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --maxw: 1180px;
  --radius: 3px;
}

*,*::before,*::after{ box-sizing: border-box; }
html{ scroll-behavior: smooth; }
body{
  margin:0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img,svg{ max-width:100%; display:block; }
a{ color: inherit; text-decoration:none; }
ul{ margin:0; padding:0; list-style:none; }
h1,h2,h3,h4{ font-family: var(--serif); font-weight:500; margin:0; color: var(--ink); letter-spacing: -0.01em; }
p{ margin:0; }
button{ font-family: inherit; cursor:pointer; }

:focus-visible{
  outline: 2px solid var(--brass);
  outline-offset: 3px;
}

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

@media (max-width: 720px){
  .wrap{ padding: 0 20px; }
}

/* ---------- Header ---------- */
.site-header{
  position: sticky; top:0; z-index: 40;
  background: rgba(246,244,238,0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap{
  display:flex; align-items:center; justify-content:space-between;
  height: 76px;
}
.brand{ display:flex; align-items:center; gap:10px; }
.brand svg{ height: 28px; width:auto; }
.brand-name{ font-family: var(--serif); font-size: 20px; font-weight:600; letter-spacing:-0.01em; }
.brand-tag{
  font-size: 11px; color: var(--ink-faint); border-left:1px solid var(--line);
  padding-left:10px; margin-left:2px; font-family: var(--sans);
}

.main-nav{ display:flex; align-items:center; gap: 36px; }
.main-nav a{
  font-size: 14.5px; color: var(--ink-soft); transition: color .15s ease;
  padding: 4px 0; border-bottom: 1px solid transparent;
}
.main-nav a:hover{ color: var(--ink); border-color: var(--brass); }
.main-nav a.active{ color: var(--ink); border-color: var(--brass); }

.header-cta{ display:flex; align-items:center; gap:18px; }

.nav-toggle{ display:none; background:none; border:0; padding:8px; }
.nav-toggle span{ display:block; width:22px; height:1.5px; background:var(--ink); margin:5px 0; }

@media (max-width: 920px){
  .main-nav{
    position: fixed; inset: 76px 0 0 0; background: var(--paper-3);
    flex-direction:column; align-items:flex-start; gap:0; padding: 8px 20px 24px;
    transform: translateY(-8px); opacity:0; pointer-events:none; transition: all .18s ease;
    border-top: 1px solid var(--line);
  }
  .main-nav.open{ transform: translateY(0); opacity:1; pointer-events:auto; }
  .main-nav a{ width:100%; padding: 14px 0; border-bottom:1px solid var(--line); }
  .nav-toggle{ display:block; }
  .header-cta .btn-ghost{ display:none; }
}

/* ---------- Buttons ---------- */
.btn{
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  font-size: 14.5px; font-weight: 500; font-family: var(--sans);
  padding: 12px 22px; border-radius: var(--radius); border: 1px solid transparent;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.btn-primary{ background: var(--ink); color: var(--paper-3); }
.btn-primary:hover{ background: var(--brass-dark); }
.btn-ghost{ color: var(--ink); border-color: var(--ink); }
.btn-ghost:hover{ background: var(--ink); color: var(--paper-3); }
.btn-on-dark{ background: var(--brass); color: var(--ink); }
.btn-on-dark:hover{ background: var(--paper-3); }
.btn-line-dark{ color: var(--paper-3); border-color: rgba(255,255,255,0.4); }
.btn-line-dark:hover{ border-color: var(--paper-3); background: rgba(255,255,255,0.08); }

/* ---------- Hero ---------- */
.hero{
  background: var(--ink); color: var(--paper-3);
  padding: 108px 0 96px;
  position: relative; overflow:hidden;
}
.hero .wrap{ position:relative; z-index:2; display:grid; grid-template-columns: 1.15fr 0.85fr; gap: 64px; align-items:end; }
.hero-eyebrow{ color: var(--brass); font-size: 14px; margin-bottom: 22px; }
.hero h1{
  color: var(--paper-3); font-size: clamp(34px, 4.6vw, 58px); line-height: 1.06;
  max-width: 12.5ch;
}
.hero-lede{ margin-top: 26px; max-width: 46ch; color: #C7CCD3; font-size: 17.5px; line-height:1.65; }
.hero-actions{ margin-top: 38px; display:flex; gap:14px; flex-wrap:wrap; }
.hero-figure{ position:relative; }
.hero-stats{ margin-top: 40px; display:grid; grid-template-columns: repeat(3,1fr); gap:22px; border-top:1px solid rgba(255,255,255,0.14); padding-top:22px; }
.hero-stat b{ display:block; font-family: var(--serif); font-size: 26px; color:var(--paper-3); font-weight:500; }
.hero-stat span{ font-size: 12.5px; color:#9AA2AC; }

@media (max-width: 920px){
  .hero .wrap{ grid-template-columns: 1fr; }
  .hero{ padding: 72px 0 56px; }
  .hero-stats{ grid-template-columns: repeat(3,1fr); gap:14px; }
}

/* ---------- Logo strip ---------- */
.logo-strip{ padding: 40px 0; border-bottom:1px solid var(--line); }
.logo-strip .wrap{ display:flex; align-items:center; gap:44px; flex-wrap:wrap; justify-content:space-between; }
.logo-strip-label{ font-size: 12.5px; color: var(--ink-faint); white-space:nowrap; }
.logo-row{ display:flex; align-items:center; gap:38px; flex-wrap:wrap; opacity:0.75; }
.logo-row svg{ height:20px; width:auto; }

/* ---------- Section basics ---------- */
.section{ padding: 96px 0; }
.section-tight{ padding: 72px 0; }
.section-head{ max-width: 640px; margin-bottom: 52px; }
.section-head.center{ margin-left:auto; margin-right:auto; text-align:center; }
.section-kicker{ color: var(--brass-dark); font-size: 13.5px; margin-bottom: 14px; }
.section-head h2{ font-size: clamp(28px, 3.2vw, 40px); line-height:1.14; }
.section-head p{ margin-top:16px; color: var(--ink-soft); font-size: 16.5px; }
.on-dark .section-head p{ color:#C7CCD3; }
.on-dark{ background: var(--ink); color: var(--paper-3); }
.on-dark h2, .on-dark h3{ color: var(--paper-3); }
.on-paper2{ background: var(--paper-2); }

/* ---------- Feature grid ---------- */
.grid-3{ display:grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--line); border:1px solid var(--line); }
.grid-2{ display:grid; grid-template-columns: repeat(2, 1fr); gap: 1px; background: var(--line); border:1px solid var(--line); }
.feature-card{ background: var(--paper-3); padding: 34px 30px; }
.feature-card .ic{ width:34px; height:34px; margin-bottom:22px; color: var(--teal); }
.feature-card h3{ font-size: 19px; margin-bottom:10px; }
.feature-card p{ color: var(--ink-soft); font-size: 15px; line-height:1.6; }

@media (max-width: 860px){
  .grid-3{ grid-template-columns: 1fr; }
  .grid-2{ grid-template-columns: 1fr; }
}

/* ---------- Workflow (legit sequence) ---------- */
.workflow{ counter-reset: step; }
.workflow-row{
  display:grid; grid-template-columns: 90px 1fr 1.1fr; gap: 28px; align-items:start;
  padding: 30px 0; border-top: 1px solid var(--line);
}
.workflow-row:last-child{ border-bottom: 1px solid var(--line); }
.workflow-num{ counter-increment: step; font-family: var(--serif); font-size: 34px; color: var(--brass); }
.workflow-num::before{ content: counter(step, decimal-leading-zero); }
.workflow-row h3{ font-size: 19px; margin-bottom: 8px; }
.workflow-row p{ color: var(--ink-soft); font-size: 15px; }

@media (max-width: 720px){
  .workflow-row{ grid-template-columns: 50px 1fr; }
  .workflow-row p{ grid-column: 2 / 3; }
}

/* ---------- Split panel ---------- */
.split{ display:grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items:center; }
.split.reverse .split-media{ order:2; }
.split-eyebrow{ color: var(--brass-dark); font-size: 13.5px; margin-bottom:14px; }
.split h2{ font-size: clamp(26px,3vw,34px); margin-bottom: 18px; }
.split p{ color: var(--ink-soft); font-size: 16px; margin-bottom: 22px; }
.check-list li{ display:flex; gap:12px; padding: 10px 0; border-top:1px solid var(--line); font-size:15px; }
.check-list li:first-child{ border-top:none; }
.check-list svg{ flex:none; width:16px; height:16px; margin-top:4px; color: var(--teal); }

@media (max-width: 860px){
  .split, .split.reverse{ grid-template-columns: 1fr; gap: 36px; }
  .split.reverse .split-media{ order:0; }
}

/* ---------- Panel / mock UI ---------- */
.panel{
  background: var(--paper-3); border:1px solid var(--line); border-radius: 6px;
  padding: 22px; box-shadow: 0 24px 60px -30px rgba(16,24,32,0.35);
}
.panel-bar{ display:flex; gap:6px; margin-bottom:16px; }
.panel-bar span{ width:8px; height:8px; border-radius:50%; background: var(--line); }

/* ---------- Testimonial ---------- */
.quote{ max-width: 760px; margin: 0 auto; text-align:center; }
.quote blockquote{ font-family: var(--serif); font-size: clamp(22px,2.6vw,30px); line-height:1.42; font-weight:500; color: var(--paper-3); }
.quote cite{ display:block; font-style:normal; margin-top:26px; color:#B9BFC7; font-size:14px; }

/* ---------- Pricing ---------- */
.pricing-grid{ display:grid; grid-template-columns: repeat(3,1fr); gap: 20px; align-items:stretch; }
.price-card{
  background: var(--paper-3); border:1px solid var(--line); border-radius: 8px; padding: 36px 30px;
  display:flex; flex-direction:column;
}
.price-card.featured{ border-color: var(--ink); box-shadow: 0 28px 60px -34px rgba(16,24,32,0.4); position:relative; }
.price-badge{
  position:absolute; top:-13px; left:30px; background: var(--brass); color: var(--ink);
  font-size:11.5px; padding: 5px 12px; border-radius: 20px; font-weight:600;
}
.price-name{ font-size: 13px; color: var(--ink-faint); margin-bottom: 10px; }
.price-amount{ font-family: var(--serif); font-size: 40px; margin-bottom:4px; }
.price-amount small{ font-family: var(--sans); font-size:14px; color: var(--ink-soft); font-weight:400; }
.price-desc{ color: var(--ink-soft); font-size: 14.5px; margin-bottom: 26px; }
.price-list{ margin: 26px 0 30px; flex:1; }
.price-list li{ display:flex; gap:10px; font-size: 14.5px; padding: 9px 0; border-top: 1px solid var(--line); }
.price-list li:first-child{ border-top:none; }
.price-list svg{ flex:none; width:15px; height:15px; margin-top:3px; color: var(--teal); }

@media (max-width: 920px){
  .pricing-grid{ grid-template-columns:1fr; }
}

.pricing-table-wrap{ overflow-x:auto; margin-top: 90px; }
table.compare{ width:100%; border-collapse: collapse; min-width: 640px; }
table.compare th, table.compare td{ text-align:left; padding: 14px 18px; border-bottom:1px solid var(--line); font-size:14.5px; }
table.compare th{ font-family: var(--serif); font-weight:500; font-size:15px; color:var(--ink-faint); }
table.compare td.center, table.compare th.center{ text-align:center; }

/* ---------- FAQ ---------- */
.faq-item{ border-top:1px solid var(--line); }
.faq-item:last-child{ border-bottom:1px solid var(--line); }
.faq-q{
  display:flex; justify-content:space-between; align-items:center; gap:20px;
  width:100%; background:none; border:0; text-align:left; padding: 22px 0; font-size:16.5px; font-family: var(--serif); color: var(--ink);
}
.faq-q .plus{ flex:none; font-size:20px; color: var(--brass-dark); transition: transform .15s ease; }
.faq-item[open] .faq-q .plus{ transform: rotate(45deg); }
.faq-a{ padding: 0 0 24px; color: var(--ink-soft); font-size:15px; max-width: 66ch; line-height:1.65; }

/* ---------- CTA band ---------- */
.cta-band{ background: var(--teal); color: var(--paper-3); padding: 74px 0; }
.cta-band .wrap{ display:flex; align-items:center; justify-content:space-between; gap:30px; flex-wrap:wrap; }
.cta-band h2{ color: var(--paper-3); font-size: clamp(24px,3vw,32px); max-width: 20ch; }
.cta-band p{ color: #CFE0DA; margin-top:10px; }

/* ---------- Footer ---------- */
.site-footer{ background: var(--ink); color: #C7CCD3; padding-top: 72px; }
.footer-top{ display:grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 32px; padding-bottom: 56px; border-bottom:1px solid rgba(255,255,255,0.12); }
.footer-brand .brand-name{ color: var(--paper-3); }
.footer-brand p{ margin-top:16px; font-size:14px; color:#9AA2AC; max-width:32ch; line-height:1.6; }
.footer-col h4{ color: var(--paper-3); font-size:13px; font-weight:500; margin-bottom:18px; font-family: var(--sans); }
.footer-col li{ margin-bottom: 11px; }
.footer-col a{ font-size:14px; color:#AEB4BC; transition: color .15s ease; }
.footer-col a:hover{ color: var(--paper-3); }
.footer-locations{ font-size:13.5px; color:#9AA2AC; line-height:1.6; }
.footer-locations b{ display:block; color:#C7CCD3; font-weight:500; margin-top:14px; }
.footer-locations b:first-child{ margin-top:0; }

.footer-bottom{ padding: 26px 0 34px; display:flex; align-items:center; justify-content:space-between; gap:20px; flex-wrap:wrap; font-size:13px; color:#8B93A0; }
.footer-bottom-links{ display:flex; gap:22px; flex-wrap:wrap; }
.footer-bottom-links a{ color:#8B93A0; }
.footer-bottom-links a:hover{ color: var(--paper-3); }

@media (max-width: 920px){
  .footer-top{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 560px){
  .footer-top{ grid-template-columns: 1fr; }
}

/* ---------- Legal / content pages ---------- */
.legal-hero{ background: var(--ink); color: var(--paper-3); padding: 68px 0 52px; }
.legal-hero .section-kicker{ color: var(--brass); }
.legal-hero h1{ color: var(--paper-3); font-size: clamp(30px,4vw,44px); }
.legal-updated{ margin-top:14px; font-size:13.5px; color:#9AA2AC; }

.legal-body{ padding: 64px 0 100px; }
.legal-layout{ display:grid; grid-template-columns: 260px 1fr; gap: 64px; }
.legal-toc{ position:sticky; top: 100px; align-self:start; }
.legal-toc a{ display:block; padding:8px 0; font-size:14px; color: var(--ink-soft); border-left:2px solid var(--line); padding-left:14px; }
.legal-toc a:hover{ color: var(--ink); border-color: var(--brass); }
.legal-content{ max-width: 720px; }
.legal-content h2{ font-size: 22px; margin-top:44px; margin-bottom:14px; }
.legal-content h2:first-child{ margin-top:0; }
.legal-content h3{ font-size:17px; margin-top:26px; margin-bottom:10px; font-family: var(--sans); font-weight:600; }
.legal-content p{ color: var(--ink-soft); font-size:15px; line-height:1.75; margin-bottom:14px; }
.legal-content ul{ margin: 0 0 16px; padding-left:0; }
.legal-content li{ color: var(--ink-soft); font-size:15px; line-height:1.7; padding-left:20px; position:relative; margin-bottom:8px; }
.legal-content li::before{ content:"–"; position:absolute; left:0; color: var(--brass-dark); }
.legal-content a.inline{ color: var(--teal); border-bottom:1px solid var(--teal); }
.legal-content table{ width:100%; border-collapse:collapse; margin: 18px 0 24px; font-size:14px; }
.legal-content th, .legal-content td{ text-align:left; padding:10px 12px; border:1px solid var(--line); color: var(--ink-soft); }
.legal-content th{ background: var(--paper-2); color: var(--ink); font-weight:600; }
.legal-note{ background: var(--paper-2); border-left:3px solid var(--brass); padding: 16px 20px; font-size:14px; color: var(--ink-soft); margin: 20px 0; }

@media (max-width: 860px){
  .legal-layout{ grid-template-columns: 1fr; }
  .legal-toc{ position:static; display:flex; flex-wrap:wrap; gap: 4px 18px; margin-bottom: 20px; }
  .legal-toc a{ border-left:none; padding-left:0; padding-bottom:8px; border-bottom:2px solid var(--line); }
}

/* ---------- Cookie consent banner ---------- */
#cookie-banner{
  position: fixed; left:20px; right:20px; bottom:20px; z-index: 200;
  max-width: 620px; margin: 0 auto;
  background: var(--paper-3); border:1px solid var(--line); border-radius: 8px;
  padding: 22px 24px; box-shadow: 0 30px 70px -20px rgba(16,24,32,0.45);
  transform: translateY(140%); transition: transform .35s ease;
}
#cookie-banner.show{ transform: translateY(0); }
#cookie-banner h3{ font-size:16px; margin-bottom:8px; }
#cookie-banner p{ font-size:13.5px; color: var(--ink-soft); line-height:1.6; }
#cookie-banner p a{ color: var(--teal); border-bottom:1px solid var(--teal); }
.cookie-actions{ display:flex; gap:10px; margin-top:16px; flex-wrap:wrap; }
.cookie-actions .btn{ padding: 10px 16px; font-size:13.5px; }
.cookie-actions .btn-text{ background:none; border:0; color: var(--ink-soft); text-decoration:underline; padding:10px 4px; }

#cookie-modal{
  position: fixed; inset:0; z-index: 210; background: rgba(16,24,32,0.55);
  display:none; align-items:center; justify-content:center; padding:20px;
}
#cookie-modal.show{ display:flex; }
.cookie-modal-panel{
  background: var(--paper-3); border-radius:10px; max-width:560px; width:100%;
  max-height: 84vh; overflow:auto; padding: 30px 30px 26px;
}
.cookie-modal-panel h3{ font-size:20px; margin-bottom:6px; }
.cookie-modal-panel > p{ font-size:14px; color:var(--ink-soft); margin-bottom:20px; }
.cookie-row{ display:flex; justify-content:space-between; align-items:flex-start; gap:16px; padding: 16px 0; border-top:1px solid var(--line); }
.cookie-row:first-of-type{ border-top:1px solid var(--line); }
.cookie-row-title{ font-size:14.5px; font-weight:600; margin-bottom:4px; }
.cookie-row-desc{ font-size:13px; color: var(--ink-soft); line-height:1.55; }
.switch{ position:relative; width:40px; height:22px; flex:none; }
.switch input{ opacity:0; width:0; height:0; }
.switch .track{ position:absolute; inset:0; background: var(--line); border-radius:20px; transition: background .15s ease; }
.switch .track::before{ content:""; position:absolute; width:16px; height:16px; left:3px; top:3px; background:#fff; border-radius:50%; transition: transform .15s ease; }
.switch input:checked + .track{ background: var(--teal); }
.switch input:checked + .track::before{ transform: translateX(18px); }
.switch input:disabled + .track{ opacity:0.5; }
.cookie-modal-actions{ display:flex; gap:10px; margin-top:22px; flex-wrap:wrap; }

/* ---------- Misc ---------- */
.small-print{ font-size:12.5px; color: var(--ink-faint); }
.skip-link{
  position:absolute; left:-999px; top:auto; background:var(--ink); color:#fff; padding:10px 16px; z-index:999;
}
.skip-link:focus{ left:20px; top:20px; }

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