/* ===========================================================================
   Allora kit look for Feasi: the shadcn "nova" look in Allora colours, the same
   values as artemis / parcels / analytics. Loaded LAST (after brand.css and any
   page's own styles) and it only changes how things look: layout and behaviour
   stay in brand.css. Remove the <link> in base.html to get the old look back.

   Feasi is a public page, so this is the light version of the kit:
   - the allora.capital header and footer (ac- classes) are not touched;
   - the navy input panel and the teal result hero stay: they are Feasi's face;
   - chart colours stay (they live in charts.js and in the PDF);
   - no dark mode.
   brand.css names its tokens after colours (--noxen, --cymaris), so they are
   not remapped: the rules below restyle components. Only the two role tokens
   (--hairline, --muted) take kit values.
   =========================================================================== */

:root{
  --hairline:#DCE7EE;              /* kit border */
  --muted:#5A7486;                 /* kit grey text (was #6E8597: too light on the pale page) */
  --k-page:#F3FAFF;                /* page */
  --k-card:#FFFFFF;
  --k-fill:#E6EFF5;                /* grey fill: tracks, quiet tiles */
  --k-input:#D2DFE8;
  --k-primary:#0A2536; --k-primary-hover:#163A50; --k-primary-fg:#F3FAFF;
  --k-accent:#DAF6EF; --k-accent-fg:#1F6E6E;
  --k-ring:#2F8A8A;
  --k-ring-1:0 0 0 1px rgba(10,37,54,.09);
  --k-shadow-xs:0 1px 2px rgba(10,37,54,.05);
  --k-shadow-lg:0 4px 8px rgba(10,37,54,.06), 0 20px 50px rgba(10,37,54,.18);
  --shadow:var(--k-ring-1), var(--k-shadow-xs);     /* cards: a hairline ring, not a soft glow */
}

body{background:var(--k-page);}

/* ---- type: nothing heavier than 600, labels in sentence case ------------- */
main h1, main h2, main h3, main b, main strong,
#mini-hero b, .chart-tip b, .drill b{font-weight:600;}
.step-no, .pl-rows .tot, .doc summary, .donut-legend li.sel, .drill-rows > div.strong,
.mh-name, .stat-main .value, .stat-side b, .fact b, .chip b, .an-kpi b{font-weight:600;}
/* chart text gets its weight from an attribute set in charts.js; CSS wins over it */
.chart-holder svg text[font-weight="700"], #chart-donut svg text[font-weight="700"]{font-weight:600;}

/* the small labels were 10 px capitals with wide spacing */
.fld span, .fld-cap, .flow-strip > div > span, .fact > span, .stat-main .label, .stat-side span,
.chart-head span, .section-rule .label, .drill-sub, .mh-kpi em, .sens-corner, .eyebrow,
.vel-auto, .an-kpi span, .an-tbl th{
  text-transform:none; letter-spacing:0; font-weight:500; font-size:.74rem;
}
/* three of them are written in lower case in the page: start them with a capital */
.chart-head span::first-letter, .section-rule .label::first-letter{text-transform:uppercase;}
.drill-sub{display:inline-block;}
.drill-sub::first-letter{text-transform:uppercase;}
.stat-main .label, .stat-side span{opacity:.9;}
.stat-main .label{font-size:.8rem;}
.eyebrow{color:var(--muted); font-size:.8rem;}
.sens-corner{font-size:.7rem; max-width:72px;}
.mh-kpi em{font-size:.72rem;}
.fld span, .fld-cap{font-size:.78rem;}

/* links on the pale page: the brand teal is too faint for text there */
.hero a, .an-top p a{color:var(--k-accent-fg);}
.hero h1{letter-spacing:-.02em;}

/* ---- cards --------------------------------------------------------------- */
.pl-card, .chart-card, .docs-page .doc, .an-kpi{
  background:var(--k-card); border:0; border-radius:14px; box-shadow:var(--shadow);
}
.facts{border:0; box-shadow:var(--shadow); border-radius:14px;}
.fact{outline-color:var(--hairline);}
.flow-strip > div{background:var(--k-card); border:0; box-shadow:var(--shadow); border-radius:12px;}
.flow-strip > .arrow{background:none; box-shadow:none;}
.flow-strip > .hot, .an-kpi.hot{background:var(--k-accent); box-shadow:0 0 0 1px rgba(47,138,138,.45), var(--k-shadow-xs);}
.doc{background:var(--k-card); border:0; box-shadow:var(--shadow); border-radius:12px;}
.chip{border-color:var(--hairline);}
.pl-bar, .lever-bar, .an-bar{background:var(--k-fill);}
.panel{box-shadow:var(--k-shadow-xs), 0 8px 24px rgba(10,37,54,.10);}
.stat-hero{box-shadow:var(--k-shadow-xs), 0 8px 24px rgba(10,37,54,.08);}
.drill{border:0; border-left:3px solid var(--cymaris);
  box-shadow:var(--k-ring-1), 0 2px 4px rgba(10,37,54,.05), 0 8px 24px rgba(10,37,54,.10);}
.drill.inset{background:var(--k-page); box-shadow:var(--k-ring-1);}
#mini-hero{box-shadow:0 1px 0 var(--hairline), 0 8px 24px rgba(10,37,54,.10);}

/* ---- section headings ---------------------------------------------------- */
.section-rule{border-bottom:1px solid var(--hairline);}
.section-rule h2{letter-spacing:-.01em; font-weight:600;}
.docs-sect{text-transform:none; letter-spacing:-.005em; font-size:1.05rem; font-weight:600;
  color:var(--noxen); border-bottom:1px solid var(--hairline);}

/* ---- buttons: main = navy, second = outline ------------------------------ */
.btn{
  background:var(--k-primary); color:var(--k-primary-fg); border:1px solid var(--k-primary);
  border-radius:10px; font-weight:500; font-size:.9rem; padding:.55rem 1.1rem;
  box-shadow:var(--k-shadow-xs); transition:background-color .15s, border-color .15s, color .15s;
}
.btn:hover{background:var(--k-primary-hover); border-color:var(--k-primary-hover); box-shadow:var(--k-shadow-xs);}
.btn.ghost{background:var(--k-card); color:var(--noxen); border:1px solid var(--k-input);}
.btn.ghost:hover{background:var(--k-accent); color:var(--k-accent-fg); border-color:var(--k-input);}
.btn:disabled, .btn:disabled:hover{background:var(--k-primary); border-color:var(--k-primary); opacity:.6; box-shadow:none;}
.btn.ghost:disabled, .btn.ghost:disabled:hover{background:var(--k-card); color:var(--noxen); border-color:var(--k-input);}
.drill-close{border-color:var(--k-input); border-radius:8px; font-weight:500; background:var(--k-card);}
.drill-close:hover{background:var(--k-accent); color:var(--k-accent-fg); border-color:var(--k-input);}

/* ---- the navy panel: same panel, calmer controls ------------------------- */
.fld.dark span, .fld-cap{color:rgba(255,255,255,.72);}
.fld.dark input{border-radius:8px; border-color:rgba(255,255,255,.2);}
.fld.dark input:focus{border-color:var(--cymaris); box-shadow:0 0 0 3px rgba(94,168,168,.3);}
.seg span{border-radius:8px; font-weight:500;}
.seg input:checked + span{box-shadow:none; font-weight:600;}
.choice-body{border-radius:10px;}
.vel-auto{border-radius:8px; padding:.2rem .5rem; font-size:.7rem;}

/* ---- focus: one teal ring on the light page ------------------------------ */
main a:focus-visible, main button:focus-visible, main summary:focus-visible,
main [tabindex]:focus-visible{outline:2px solid var(--k-ring); outline-offset:2px; border-radius:6px;}
.panel a:focus-visible, .panel button:focus-visible{outline-color:var(--claria);}

/* ---- message (the Sonner look): a white card, not a navy pill ------------ */
#net-toast{
  background:var(--k-card); color:var(--noxen); font-weight:500; font-size:.86rem;
  border-radius:10px; padding:.7rem 1rem; box-shadow:var(--k-ring-1), var(--k-shadow-lg);
  max-width:min(92vw, 420px); text-align:left;
}
/* phones: the result bar is docked at the bottom, so the message sits above it */
@media (max-width:640px){ #net-toast{bottom:calc(72px + env(safe-area-inset-bottom));} }

/* ---- docs and questions -------------------------------------------------- */
.doc summary::after{color:var(--k-accent-fg);}
.faq-item summary{font-weight:500; color:var(--noxen);}

/* ---- usage analytics (team page; its own rules are in analytics.html) ---- */
.an-pills{background:var(--k-fill); border:0; border-radius:10px;}
.an-pills a{border-radius:8px; font-weight:500;}
.an-pills a[aria-current]{background:var(--k-card); color:var(--noxen); box-shadow:var(--k-ring-1), var(--k-shadow-xs);}
.an-toggle{border-color:var(--k-input); border-radius:10px; font-weight:500; background:var(--k-card);}
.an-toggle.on{background:var(--k-accent); color:var(--k-accent-fg); border-color:rgba(47,138,138,.45);}
.an-kpi span, .an-tbl th{color:var(--muted);}

/* ---- phones -------------------------------------------------------------- */
@media (max-width:640px){
  /* the two export buttons share the row evenly */
  .head-actions .btn{flex:1 1 0; padding-left:.6rem; padding-right:.6rem;}
}
@media (max-width:460px){
  .sens-corner{font-size:.7rem;}
  .sens-h{font-size:.7rem;}
  .sens-c{font-size:.7rem;}
}

/* ---- moving between pages ---------------------------------------------------
   Each page is a separate document. Where the browser supports it (Chrome, Edge,
   Safari 18.2+) the old page cross-fades into the new one instead of blanking,
   and the header, which is the same on every page, stays still. Other browsers
   simply load the page as before. */
@view-transition{ navigation:auto; }
.ac-header{ view-transition-name:site-header; }
::view-transition-old(root), ::view-transition-new(root){ animation-duration:.18s; }
::view-transition-group(site-header){ animation:none; }
::view-transition-old(site-header){ display:none; }
::view-transition-new(site-header){ animation:none; }
@media (prefers-reduced-motion:reduce){ @view-transition{ navigation:none; } }
