/* Citable platform UI. Tokens: mineral paper, graphite ink, prussian blue for action, marker yellow for citations only. */
:root{
  --bg:#E8EBE5; --paper:#F8F9F6; --panel:#FFFFFF; --ink:#16202A; --ink-2:#34414C; --muted:#5B6757; --rule:#CBD1C6; --rule-2:#DDE1D8;
  --blue:#1D3F66; --blue-2:#2A5588; --blue-soft:#DCE4EC; --marker:#F2D44A; --marker-soft:#FAEFB5;
  --ok:#2E6B4A; --ok-soft:#DCEBE1; --err:#A3321C; --err-soft:#F5E0DA; --warn:#8A5A00; --warn-soft:#F7ECCF;
  --f-display:"Bricolage Grotesque", "Instrument Sans", system-ui, sans-serif;
  --f-ui:"Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --r-s:6px; --r-m:10px; --r-l:16px;
}
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;scroll-padding-top:calc(76px + env(safe-area-inset-top,0px))}
body{margin:0;background:var(--bg);color:var(--ink);font-family:var(--f-ui);font-size:16px;line-height:1.55;-webkit-font-smoothing:antialiased}
img,svg{max-width:100%}
a{color:var(--blue);text-underline-offset:.18em;text-decoration-thickness:1px}
a:hover{color:var(--blue-2)}
:focus-visible{outline:2px solid var(--blue);outline-offset:2px;border-radius:3px}
h1,h2,h3,h4{margin:0;line-height:1.15;font-weight:600}
p{margin:0 0 1em}
.muted{color:var(--muted)}
.small{font-size:.875rem}
.skip{position:absolute;left:-999px;top:0;background:var(--ink);color:#fff;padding:.6rem 1rem;z-index:100}
.skip:focus{left:1rem;top:1rem}
.i{flex:none;vertical-align:middle}
.nowrap{white-space:nowrap}
code,.mono{font-family:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace;font-size:.88em}
code{background:var(--rule-2);padding:.1em .35em;border-radius:4px}
hr{border:0;border-top:1px solid var(--rule);margin:2rem 0}

/* Logo: wordmark followed by a citation index in a marker square */
.logo{display:inline-flex;align-items:flex-start;gap:3px;text-decoration:none;color:var(--ink)}
.logo-word{font-family:var(--f-display);font-weight:700;font-size:1.35rem;letter-spacing:-.02em;line-height:1}
.logo-cite{background:var(--marker);color:var(--ink);font:700 .62rem/1 var(--f-ui);padding:2px 4px;border-radius:3px;margin-top:-4px}

/* Buttons */
.btn{display:inline-flex;align-items:center;justify-content:center;gap:.5rem;min-height:42px;padding:.6rem 1.1rem;border-radius:var(--r-s);
  border:1px solid var(--ink);background:var(--ink);color:#fff;font:600 .95rem/1.2 var(--f-ui);text-decoration:none;cursor:pointer;transition:background .15s,border-color .15s}
.btn:hover{background:var(--blue);border-color:var(--blue);color:#fff}
.btn:disabled,.btn[aria-disabled=true]{opacity:.5;cursor:not-allowed}
.btn-lg{min-height:52px;padding:.8rem 1.5rem;font-size:1.02rem}
.btn-sm{min-height:34px;padding:.35rem .8rem;font-size:.875rem}
.btn-quiet,.btn-ghost{background:transparent;color:var(--ink);border-color:var(--rule)}
.btn-quiet:hover,.btn-ghost:hover{background:var(--paper);color:var(--ink);border-color:var(--ink-2)}
.btn-blue{background:var(--blue);border-color:var(--blue)}
.btn-danger{background:transparent;color:var(--err);border-color:#DDB6AC}
.btn-danger:hover{background:var(--err);border-color:var(--err);color:#fff}
.btn-marker{background:var(--marker);border-color:var(--marker);color:var(--ink)}
.btn-marker:hover{background:#fff;border-color:#fff;color:var(--ink)}
.btn .i{margin-left:-2px}
.btn.is-loading{position:relative;color:transparent!important;pointer-events:none}
.btn.is-loading::after{content:"";position:absolute;width:18px;height:18px;border:2px solid #fff;border-right-color:transparent;border-radius:50%;animation:spin .7s linear infinite}
.btn-quiet.is-loading::after,.btn-ghost.is-loading::after{border-color:var(--ink);border-right-color:transparent}
@keyframes spin{to{transform:rotate(360deg)}}
.link-quiet{color:var(--ink);text-decoration:none;font-weight:500}
.link-quiet:hover{text-decoration:underline}
.linkbtn{background:none;border:0;padding:0;font:inherit;color:var(--blue);cursor:pointer;text-decoration:underline;text-underline-offset:.18em}
.icon-btn{display:inline-grid;place-items:center;width:40px;height:40px;border-radius:var(--r-s);border:0;background:transparent;color:var(--ink);cursor:pointer}
.icon-btn:hover{background:var(--rule-2)}

/* Forms */
.field{display:grid;gap:.35rem;margin-bottom:1.1rem}
.field>label,.label{font-weight:600;font-size:.92rem}
.field .help{font-size:.85rem;color:var(--muted);margin:0}
.input,.field input:not([type=checkbox]):not([type=radio]):not([type=file]):not([type=color]),.field select,.field textarea{
  width:100%;font:inherit;color:var(--ink);background:var(--panel);border:1px solid var(--rule);border-radius:var(--r-s);padding:.62rem .75rem;min-height:44px}
.field textarea{min-height:auto;line-height:1.55;resize:vertical}
.field input:focus,.field select:focus,.field textarea:focus,.input:focus{outline:2px solid var(--blue);outline-offset:-1px;border-color:var(--blue)}
.field .err,.field-err{color:var(--err);font-size:.86rem;margin:0}
.grid2{display:grid;gap:0 1.25rem}
@media (min-width:720px){.grid2{grid-template-columns:1fr 1fr}.grid3{display:grid;gap:0 1.25rem;grid-template-columns:repeat(3,1fr)}}
.check{display:flex;gap:.7rem;align-items:flex-start;padding:.2rem 0;cursor:pointer}
.check input{width:18px;height:18px;margin:.15rem 0 0;accent-color:var(--blue);flex:none}
.check span b{display:block;font-weight:600}
.check span small{color:var(--muted);font-size:.86rem;display:block}
.form-actions{display:flex;flex-wrap:wrap;gap:.75rem;align-items:center;margin-top:1.5rem}
.input-affix{display:flex;align-items:stretch}
.input-affix input{border-top-right-radius:0!important;border-bottom-right-radius:0!important}
.input-affix span{display:flex;align-items:center;padding:0 .75rem;background:var(--rule-2);border:1px solid var(--rule);border-left:0;border-radius:0 var(--r-s) var(--r-s) 0;color:var(--muted);white-space:nowrap;font-size:.92rem}

/* Toggle switch */
.switch{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.9rem 0;border-bottom:1px solid var(--rule-2);cursor:pointer}
.switch:last-child{border-bottom:0}
.switch input{appearance:none;-webkit-appearance:none;width:44px;height:26px;border-radius:13px;background:var(--rule);position:relative;flex:none;cursor:pointer;transition:background .15s;margin:0}
.switch input::after{content:"";position:absolute;top:3px;left:3px;width:20px;height:20px;border-radius:50%;background:#fff;box-shadow:0 1px 2px rgba(22,32,42,.3);transition:transform .15s}
.switch input:checked{background:var(--blue)}
.switch input:checked::after{transform:translateX(18px)}
.switch span b{display:block;font-weight:600}
.switch span small{display:block;color:var(--muted);font-size:.86rem}

/* Flash + notices */
.flash{position:relative;padding:.8rem 2.5rem .8rem 1rem;border-radius:var(--r-s);margin:0 0 1.25rem;border-left:3px solid;font-weight:500}
.flash-ok{background:var(--ok-soft);border-color:var(--ok)}
.flash-err{background:var(--err-soft);border-color:var(--err)}
.flash-info{background:var(--blue-soft);border-color:var(--blue)}
.flash-x{position:absolute;right:.5rem;top:.45rem;border:0;background:none;font-size:1.3rem;cursor:pointer;color:inherit;line-height:1}
.note{padding:1rem 1.15rem;border-radius:var(--r-m);background:var(--paper);border:1px solid var(--rule-2)}
.note-warn{background:var(--warn-soft);border-color:#E8D5A3}
.note-marker{background:var(--marker-soft);border-color:#EAD98A}

/* Tags */
.tag{display:inline-flex;align-items:center;gap:.35rem;padding:.12rem .55rem;border-radius:999px;font-size:.78rem;font-weight:600;background:var(--rule-2);color:var(--ink-2);white-space:nowrap}
.tag-ok{background:var(--ok-soft);color:var(--ok)}
.tag-err{background:var(--err-soft);color:var(--err)}
.tag-warn{background:var(--warn-soft);color:var(--warn)}
.tag-blue{background:var(--blue-soft);color:var(--blue)}
.dot{width:8px;height:8px;border-radius:50%;display:inline-block;flex:none}
.dot-on{background:#3C9A65;box-shadow:0 0 0 3px #CFE6D8}
.dot-off{background:#A7AFA3}

/* =================== Marketing =================== */
.mk{background:var(--bg)}
.mk-wrap{width:min(1180px,100% - 2.5rem);margin-inline:auto}
.mk-nav{position:sticky;top:0;z-index:30;background:rgba(232,235,229,.9);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);border-bottom:1px solid transparent;padding-top:env(safe-area-inset-top,0px)}
.mk-nav-in{display:flex;align-items:center;gap:2rem;min-height:68px}
.mk-links{display:flex;gap:1.6rem;margin-right:auto}
.mk-links a{color:var(--ink-2);text-decoration:none;font-weight:500;font-size:.95rem}
.mk-links a:hover{color:var(--ink)}
.mk-nav-actions{display:flex;align-items:center;gap:1.1rem}
@media (max-width:880px){.mk-links{display:none}.mk-nav-actions{margin-left:auto}}

.mk-hero{padding:4.5rem 0 5rem}
.mk-hero-in{display:grid;gap:3.5rem;align-items:center}
@media (min-width:1000px){.mk-hero-in{grid-template-columns:minmax(0,1.08fr) minmax(0,1fr);gap:4.5rem}}
.mk-h1{font-family:var(--f-display);font-weight:600;font-size:clamp(2.5rem,5.4vw,4.35rem);line-height:1.02;letter-spacing:-.035em;font-variation-settings:"opsz" 96;max-width:14ch}
.mk-lede{font-size:clamp(1.08rem,1.6vw,1.22rem);color:var(--ink-2);max-width:48ch;margin:1.5rem 0 0;line-height:1.55}
.mk-cta-row{display:flex;flex-wrap:wrap;gap:.75rem;margin-top:2.25rem}
.mk-fine{color:var(--muted);font-size:.92rem;margin:1.1rem 0 0}

/* Hero specimen: an AI answer that cites the professional */
.answer{margin:0;background:var(--panel);border-radius:var(--r-l);border:1px solid var(--rule);box-shadow:0 30px 60px -30px rgba(22,32,42,.35),0 2px 0 rgba(22,32,42,.04);overflow:hidden}
.answer-q{display:flex;gap:.7rem;align-items:center;padding:1.05rem 1.3rem;border-bottom:1px solid var(--rule-2);font-weight:600;color:var(--ink)}
.answer-q svg{color:var(--muted)}
.answer-body{padding:1.3rem 1.3rem .4rem;font-size:1rem;line-height:1.65;color:var(--ink-2)}
.answer-body strong{color:var(--ink)}
.cite{display:inline-grid;place-items:center;min-width:1.25rem;height:1.25rem;padding:0 .3rem;margin-left:.2rem;border-radius:4px;background:var(--rule-2);color:var(--ink-2);font:700 .7rem/1 var(--f-ui);text-decoration:none;vertical-align:.2em;transition:background .4s}
.cite[data-cite="1"].lit{background:var(--marker);color:var(--ink)}
.answer-sources{list-style:none;margin:0;padding:.6rem .8rem 1rem;display:grid;gap:.35rem}
.answer-sources li{display:flex;gap:.7rem;align-items:center;padding:.6rem .6rem;border-radius:var(--r-s);font-size:.9rem;color:var(--muted);transition:background .5s}
.answer-sources li b{color:var(--ink);font-weight:600;margin-right:.4rem}
.answer-sources .n{display:grid;place-items:center;width:1.4rem;height:1.4rem;border-radius:4px;background:var(--rule-2);font-weight:700;font-size:.72rem;color:var(--ink-2);flex:none}
.answer-sources li.lit{background:var(--marker-soft)}
.answer-sources li.lit .n{background:var(--marker);color:var(--ink)}
.answer figcaption{font-size:.78rem;color:var(--muted);padding:.7rem 1.3rem;border-top:1px solid var(--rule-2);background:var(--paper)}
.answer [data-typeset] p{margin:0 0 .9rem}
.answer .w{opacity:0;transition:opacity .25s}
.answer .w.on{opacity:1}
@media (prefers-reduced-motion:reduce){.answer .w{opacity:1;transition:none}}

.mk-section{padding:6rem 0;border-top:1px solid var(--rule)}
.mk-h2{font-family:var(--f-display);font-weight:600;font-size:clamp(1.9rem,3.4vw,2.8rem);line-height:1.08;letter-spacing:-.025em;max-width:22ch}
.mk-narrow{max-width:30ch}
.mk-lede.mk-narrow{max-width:56ch}
.mk-split{display:grid;gap:2rem}
@media (min-width:960px){.mk-split{grid-template-columns:minmax(0,1fr) minmax(0,1.25fr);gap:5rem}}
.mk-prose{font-size:1.1rem;color:var(--ink-2);max-width:60ch}
.mk-prose p:last-child{margin:0;color:var(--ink);font-weight:500}

.compare{margin-top:4rem;border-top:2px solid var(--ink)}
.compare-row{display:grid;grid-template-columns:1fr;gap:.2rem 2rem;padding:1.1rem 0;border-bottom:1px solid var(--rule)}
.compare-row>span:first-child{font-weight:600}
.compare-row>span:nth-child(2){color:var(--muted)}
.compare-row>span:nth-child(3){color:var(--ink)}
.compare-head{display:none}
@media (min-width:760px){
  .compare-row{grid-template-columns:1fr 1.3fr 1.3fr}
  .compare-head{display:grid;font-size:.9rem;color:var(--muted);padding:.8rem 0}
  .compare-head>span:nth-child(3){color:var(--ink);font-weight:600}
  .compare-row>span:nth-child(3){position:relative;padding-left:1.1rem}
  .compare-row:not(.compare-head)>span:nth-child(3)::before{content:"";position:absolute;left:0;top:.55em;width:6px;height:6px;background:var(--marker);outline:2px solid var(--ink);outline-offset:0}
}
@media (max-width:759px){.compare-row>span:nth-child(2)::before{content:"Applying: "}.compare-row>span:nth-child(3)::before{content:"Found by name: ";font-weight:600}}

/* Annotated specimen */
.specimen-grid{display:grid;gap:3rem;margin-top:3.5rem;align-items:start}
@media (min-width:1000px){.specimen-grid{grid-template-columns:minmax(0,1.2fr) minmax(0,1fr);gap:4rem}}
.specimen{position:relative;background:#F5F4F0;border:1px solid var(--rule);border-radius:var(--r-l);padding:1.2rem 1.5rem 2.5rem;font-family:Georgia,serif;color:#1C2230;box-shadow:0 30px 60px -35px rgba(22,32,42,.35)}
.sp-top{display:flex;justify-content:space-between;font:600 .8rem var(--f-ui);padding-bottom:.9rem;border-bottom:1px solid #D9DAD6}
.sp-nav{display:flex;gap:1rem;color:#5D6573;font-weight:500}
.sp-hero{display:grid;grid-template-columns:1.4fr 1fr;gap:1.5rem;padding:2rem 0 1.5rem}
.sp-name{font-size:clamp(1.5rem,3vw,2.1rem);font-weight:700;letter-spacing:-.01em}
.sp-head{font-style:italic;color:#5D6573;margin:.5rem 0 1.2rem;font-size:.95rem;line-height:1.45}
.sp-btn{display:inline-block;background:#7A2E2E;color:#fff;font:600 .78rem var(--f-ui);padding:.5rem .8rem;border-radius:2px}
.sp-facts{background:#fff;border:1px solid #D9DAD6;padding:.6rem .8rem;font:.74rem var(--f-ui)}
.sp-facts div{display:flex;justify-content:space-between;gap:.5rem;padding:.4rem 0;border-bottom:1px solid #ECECE8}
.sp-facts div:last-child{border:0}
.sp-facts span{color:#5D6573}
.sp-lines i{display:block;height:8px;background:#E4E3DE;border-radius:2px;margin:.6rem 0}
.pin{position:absolute;display:grid;place-items:center;width:1.7rem;height:1.7rem;border-radius:5px;background:var(--marker);color:var(--ink);font:700 .78rem var(--f-ui);box-shadow:0 0 0 3px rgba(242,212,74,.35),0 2px 6px rgba(0,0,0,.15)}
@media (max-width:560px){.sp-hero{grid-template-columns:1fr}.pin{display:none}}
.notes{list-style:none;counter-reset:n;margin:0;padding:0;display:grid;gap:1.4rem}
.notes li{counter-increment:n;position:relative;padding-left:2.6rem;color:var(--ink-2)}
.notes li::before{content:counter(n);position:absolute;left:0;top:.05rem;width:1.7rem;height:1.7rem;display:grid;place-items:center;border-radius:5px;background:var(--marker);color:var(--ink);font-weight:700;font-size:.78rem}
.notes b{color:var(--ink)}

.mk-steps-section{background:var(--ink);color:#DDE3E8;border-top:0}
.mk-steps-section .mk-h2{color:#fff}
.steps{list-style:none;counter-reset:s;margin:3rem 0 0;padding:0;display:grid;gap:2.5rem}
@media (min-width:880px){.steps{grid-template-columns:repeat(3,1fr);gap:3rem}}
.steps li{counter-increment:s;border-top:1px solid #3A4854;padding-top:1.5rem}
.steps li::before{content:"Step " counter(s);display:block;color:var(--marker);font-weight:600;font-size:.9rem;margin-bottom:.8rem}
.steps h3{font-family:var(--f-display);font-size:1.5rem;color:#fff;margin-bottom:.7rem;letter-spacing:-.015em}
.steps p{color:#B8C2CB;margin:0}
.mk-aside{margin:3.5rem 0 0;max-width:62ch;font-size:1.1rem;color:#fff;padding-left:1.1rem;border-left:3px solid var(--marker)}

.layouts{display:grid;gap:1.5rem;margin-top:3rem;grid-template-columns:repeat(auto-fit,minmax(230px,1fr))}
.layout-card{margin:0}
.layout-card h3{font-family:var(--f-display);font-size:1.25rem;margin:1rem 0 .25rem}
.layout-card p{color:var(--muted);margin:0;font-size:.95rem}
.thumb{aspect-ratio:4/3;border-radius:var(--r-m);background:var(--tb);border:1px solid var(--rule);position:relative;overflow:hidden}
.thumb i{position:absolute;display:block;border-radius:2px}
.thumb-ledger .t1{left:9%;top:14%;width:45%;height:9%;background:var(--ti)}
.thumb-ledger .t2{left:9%;top:28%;width:38%;height:4%;background:var(--tl)}
.thumb-ledger .t3{right:8%;top:14%;width:30%;height:44%;background:var(--ts);border:1px solid var(--tl)}
.thumb-ledger .t4{left:9%;top:40%;width:16%;height:7%;background:var(--ta)}
.thumb-ledger .t5{left:9%;right:8%;top:70%;height:3%;background:var(--tl);box-shadow:0 12px 0 var(--tl)}
.thumb-studio .t1{left:8%;top:16%;width:78%;height:20%;background:var(--ti)}
.thumb-studio .t2{left:8%;top:42%;width:46%;height:5%;background:var(--tl)}
.thumb-studio .t3{left:8%;top:60%;width:40%;height:32%;background:var(--ta);border-radius:6px}
.thumb-studio .t4{left:52%;top:60%;width:40%;height:32%;background:var(--ts);border-radius:6px}
.thumb-studio .t5{display:none}
.thumb-stack .t1{left:8%;top:14%;width:40%;height:8%;background:var(--ti)}
.thumb-stack .t2{left:8%;top:28%;width:60%;height:4%;background:var(--tl)}
.thumb-stack .t3{left:8%;top:40%;width:84%;height:7%;background:repeating-linear-gradient(90deg,var(--ts) 0 16%,transparent 16% 18%);border-radius:3px}
.thumb-stack .t4{left:8%;top:58%;width:3px;height:32%;background:var(--ta)}
.thumb-stack .t5{left:14%;top:60%;width:60%;height:3%;background:var(--tl);box-shadow:0 14px 0 var(--tl),0 28px 0 var(--tl)}
.thumb-practice .t1{left:0;right:0;top:0;height:52%;background:var(--ts);border-radius:0}
.thumb-practice .t2{left:8%;top:16%;width:50%;height:9%;background:var(--ti)}
.thumb-practice .t3{right:10%;top:10%;width:24%;aspect-ratio:1;background:var(--tl);border-radius:50%}
.thumb-practice .t4{left:8%;top:62%;width:26%;height:28%;background:#fff;border-top:3px solid var(--ta)}
.thumb-practice .t5{left:38%;top:62%;width:26%;height:28%;background:#fff;border-top:3px solid var(--ta);box-shadow:calc(100% + 12px) 0 0 #fff}

.features{display:grid;gap:1.5rem 2.5rem;margin:0}
@media (min-width:640px){.features{grid-template-columns:1fr 1fr}}
.features div{border-top:1px solid var(--rule);padding-top:1rem}
.features dt{font-weight:600;margin-bottom:.3rem}
.features dd{margin:0;color:var(--muted)}

.price{display:grid;gap:3rem;align-items:start}
@media (min-width:960px){.price{grid-template-columns:minmax(0,1fr) minmax(0,1.2fr);gap:5rem}}
.price-figures{background:var(--panel);border:1px solid var(--rule);border-radius:var(--r-l);padding:2.5rem}
.price-big{font-family:var(--f-display);font-size:clamp(4rem,9vw,6.5rem);font-weight:600;letter-spacing:-.05em;line-height:.9;margin:0}
.price-big span,.price-small span{display:block;font:500 1rem var(--f-ui);letter-spacing:0;color:var(--muted);margin-top:.6rem}
.price-small{font-family:var(--f-display);font-size:2.4rem;font-weight:600;letter-spacing:-.03em;margin:2rem 0 0;padding-top:2rem;border-top:1px solid var(--rule-2);line-height:1}
.ticks{list-style:none;padding:0;margin:2rem 0 2.25rem;display:grid;gap:.8rem}
.ticks li{position:relative;padding-left:1.8rem;color:var(--ink-2)}
.ticks li::before{content:"";position:absolute;left:0;top:.35em;width:.95rem;height:.55rem;border-left:2px solid var(--blue);border-bottom:2px solid var(--blue);transform:rotate(-45deg)}

.mk-faq details{border-bottom:1px solid var(--rule);padding:1.2rem 0}
.mk-faq details:first-child{padding-top:0}
.mk-faq summary{cursor:pointer;font-weight:600;font-size:1.08rem;list-style:none;display:flex;justify-content:space-between;gap:1rem}
.mk-faq summary::-webkit-details-marker{display:none}
.mk-faq summary::after{content:"+";font-weight:400;font-size:1.4rem;line-height:1;color:var(--blue)}
.mk-faq details[open] summary::after{content:"–"}
.mk-faq p{margin:.8rem 0 0;color:var(--ink-2);max-width:60ch}

.mk-final{background:var(--blue);color:#fff;padding:5rem 0}
.mk-final .mk-wrap{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:2rem}
.mk-final-line{font-family:var(--f-display);font-size:clamp(1.8rem,3.6vw,2.9rem);font-weight:600;letter-spacing:-.03em;line-height:1.1;max-width:22ch;margin:0}
.mk-foot{padding:3rem 0 calc(3rem + env(safe-area-inset-bottom,0px));font-size:.92rem}
.mk-foot-in{display:grid;gap:1.5rem;align-items:start}
@media (min-width:760px){.mk-foot-in{grid-template-columns:2fr 2fr 1fr}}
.mk-foot nav{display:flex;flex-wrap:wrap;gap:1.25rem}
.mk-foot nav a{color:var(--ink-2)}
.mk-foot .muted{margin:.6rem 0 0}
.legal{max-width:68ch;padding:4rem 0}
.legal h1{font-family:var(--f-display);font-size:2.4rem;letter-spacing:-.03em;margin-bottom:1.5rem}
.legal h2{font-size:1.2rem;margin:2rem 0 .6rem}

/* =================== Auth / onboarding =================== */
.auth{min-height:100vh;background:var(--bg)}
.auth-top{padding:calc(1.4rem + env(safe-area-inset-top,0px)) 1.5rem 1rem;display:flex;justify-content:space-between;align-items:center;max-width:1180px;margin:0 auto}
.auth-main{width:min(460px,100% - 2.5rem);margin:2rem auto 4rem}
.auth-main.wide,.auth-wide .auth-main{width:min(760px,100% - 2.5rem)}
.auth-card{background:var(--panel);border:1px solid var(--rule);border-radius:var(--r-l);padding:clamp(1.5rem,4vw,2.25rem)}
.auth-title{font-family:var(--f-display);font-size:1.9rem;letter-spacing:-.025em;margin-bottom:.5rem}
.auth-sub{color:var(--muted);margin-bottom:1.75rem}
.auth-alt{text-align:center;margin-top:1.5rem;color:var(--muted)}
.progress{display:flex;gap:.4rem;margin:0 0 1.75rem;padding:0;list-style:none;font-size:.82rem;color:var(--muted)}
.progress li{flex:1;border-top:3px solid var(--rule);padding-top:.5rem}
.progress li.done{border-color:var(--blue);color:var(--ink)}
.progress li.now{border-color:var(--ink);color:var(--ink);font-weight:600}
.domain-results{display:grid;gap:.5rem;margin:.75rem 0 0}
.domain-opt{display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.7rem .9rem;border:1px solid var(--rule);border-radius:var(--r-s);background:var(--paper);cursor:pointer}
.domain-opt:has(input:checked){border-color:var(--blue);background:var(--blue-soft)}
.domain-opt input{accent-color:var(--blue)}
.domain-opt.off{opacity:.55;cursor:default}
.choice-grid{display:grid;gap:.9rem;grid-template-columns:repeat(auto-fit,minmax(200px,1fr))}
.choice{position:relative;display:block;border:1px solid var(--rule);border-radius:var(--r-m);padding:1rem;background:var(--paper);cursor:pointer}
.choice:has(input:checked){border-color:var(--blue);box-shadow:0 0 0 2px var(--blue)}
.choice input{position:absolute;opacity:0;pointer-events:none}
.choice .thumb{margin-bottom:.8rem}
.choice b{display:block}
.choice small{display:block;color:var(--muted);line-height:1.4;margin-top:.2rem}
.choice .rec{position:absolute;top:.6rem;right:.6rem}
.or{display:flex;align-items:center;gap:1rem;color:var(--muted);margin:1.75rem 0;font-size:.9rem}
.or::before,.or::after{content:"";flex:1;border-top:1px solid var(--rule)}
.drop{display:grid;place-items:center;text-align:center;gap:.4rem;border:1.5px dashed #A9B3A3;border-radius:var(--r-m);padding:2rem 1rem;background:var(--paper);cursor:pointer}
.drop:hover,.drop.is-over{border-color:var(--blue);background:var(--blue-soft)}
.drop input{position:absolute;opacity:0;width:1px;height:1px}
.drop .i{color:var(--blue)}
.drop b{font-weight:600}
.drop-name{font-weight:600;color:var(--blue)}
.busy{display:none;align-items:center;gap:.8rem;padding:1rem;border-radius:var(--r-m);background:var(--marker-soft);margin-top:1rem}
.busy.on{display:flex}
.busy::before{content:"";width:18px;height:18px;border:2px solid var(--ink);border-right-color:transparent;border-radius:50%;animation:spin .7s linear infinite;flex:none}

/* =================== App shell (dashboard + admin) =================== */
.shell{background:var(--bg)}
.shell-grid{display:grid;min-height:100vh}
@media (min-width:1024px){.shell-grid{grid-template-columns:268px minmax(0,1fr)}}
.side{background:var(--paper);border-right:1px solid var(--rule);display:flex;flex-direction:column;padding:1.1rem .8rem calc(1rem + env(safe-area-inset-bottom,0px));position:sticky;top:0;height:100vh;overflow-y:auto}
.side-head{display:flex;align-items:center;justify-content:space-between;padding:.2rem .5rem 1rem;gap:.5rem}
.side-close{display:none}
.admin-tag{font-size:.72rem;font-weight:700;background:var(--ink);color:#fff;padding:.15rem .45rem;border-radius:4px;margin-right:auto;margin-left:.4rem}
.side-site{display:flex;align-items:center;gap:.6rem;margin:0 .2rem 1rem;padding:.65rem .75rem;border:1px solid var(--rule);border-radius:var(--r-s);background:var(--panel);text-decoration:none;color:var(--ink);font-size:.86rem;font-weight:500}
.side-site-url{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1}
.side-group{font-size:.78rem;font-weight:600;color:var(--muted);margin:1.1rem .75rem .35rem}
.side-nav{display:grid;gap:2px}
.side-nav a,.side-logout{display:flex;align-items:center;gap:.75rem;padding:.6rem .75rem;border-radius:var(--r-s);color:var(--ink-2);text-decoration:none;font-weight:500;font-size:.94rem;border:0;background:none;width:100%;cursor:pointer;font-family:inherit}
.side-nav a:hover,.side-logout:hover{background:var(--rule-2);color:var(--ink)}
.side-nav a.is-active{background:var(--ink);color:#fff}
.side-nav .count{margin-left:auto;font-style:normal;background:var(--marker);color:var(--ink);font-size:.72rem;font-weight:700;padding:.08rem .45rem;border-radius:999px}
.side-foot{margin-top:auto;padding-top:1rem;border-top:1px solid var(--rule-2)}
.side-who{display:block;padding:.4rem .75rem;font-size:.86rem;font-weight:600}
.side-who small{color:var(--muted);font-weight:500}
.main-col{min-width:0;display:flex;flex-direction:column}
.mbar{display:none}
.main{width:min(980px,100% - 2.5rem);margin:0 auto;padding:2.5rem 0 5rem}
.main-wide{width:min(1280px,100% - 2.5rem)}
.side-scrim{display:none}
.tabbar{display:none}
.imp-bar{background:var(--marker);padding:.55rem 1rem;text-align:center;font-weight:600;font-size:.9rem;position:sticky;top:0;z-index:60}
.imp-bar button{margin-left:.6rem;font:inherit;font-weight:700;background:var(--ink);color:#fff;border:0;border-radius:4px;padding:.2rem .6rem;cursor:pointer}

@media (max-width:1023px){
  .side{position:fixed;inset:0 auto 0 0;width:min(300px,86vw);z-index:80;transform:translateX(-102%);transition:transform .22s ease;box-shadow:0 0 40px rgba(0,0,0,.2);padding-top:calc(1.1rem + env(safe-area-inset-top,0px))}
  .nav-open .side{transform:none}
  .side-close{display:inline-grid}
  .nav-open .side-scrim{display:block;position:fixed;inset:0;background:rgba(22,32,42,.35);z-index:70}
  .mbar{display:flex;align-items:center;justify-content:space-between;gap:.5rem;position:sticky;top:0;z-index:40;background:rgba(248,249,246,.95);backdrop-filter:blur(8px);-webkit-backdrop-filter:blur(8px);border-bottom:1px solid var(--rule);padding:calc(.4rem + env(safe-area-inset-top,0px)) .6rem .4rem}
  .mbar-title{font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .main{padding:1.5rem 0 calc(6rem + env(safe-area-inset-bottom,0px))}
  .shell:not(.shell-admin) .tabbar{display:grid;grid-template-columns:repeat(5,1fr);position:fixed;left:0;right:0;bottom:0;z-index:50;background:var(--paper);border-top:1px solid var(--rule);padding:.3rem .3rem calc(.3rem + env(safe-area-inset-bottom,0px))}
  .tabbar a,.tabbar button{position:relative;display:grid;justify-items:center;gap:2px;padding:.35rem 0;font:500 .7rem var(--f-ui);color:var(--muted);text-decoration:none;background:none;border:0;border-radius:var(--r-s);cursor:pointer}
  .tabbar .is-active{color:var(--ink)}
  .tabbar .is-active .i{color:var(--blue)}
  .tabbar .count{position:absolute;top:0;left:55%;font-style:normal;background:var(--marker);color:var(--ink);font-size:.62rem;font-weight:700;padding:0 .35rem;border-radius:999px}
}
@media (prefers-reduced-motion:reduce){.side{transition:none}}

/* Page header */
.ph{display:flex;flex-wrap:wrap;align-items:flex-end;justify-content:space-between;gap:1rem;margin-bottom:1.75rem}
.ph h1{font-family:var(--f-display);font-size:clamp(1.6rem,3vw,2.1rem);letter-spacing:-.025em}
.ph p{color:var(--muted);margin:.4rem 0 0;max-width:60ch}
.ph-actions{display:flex;flex-wrap:wrap;gap:.6rem}
.crumb{font-size:.88rem;margin-bottom:.4rem;display:inline-block;color:var(--muted);text-decoration:none}
.crumb:hover{color:var(--ink)}
.h-page{font-family:var(--f-display);font-size:2rem;letter-spacing:-.025em;margin-bottom:.6rem}

/* Panels */
.panel{background:var(--panel);border:1px solid var(--rule);border-radius:var(--r-m);padding:1.4rem;margin-bottom:1.25rem}
.panel-flush{padding:0;overflow:hidden}
.panel-h{display:flex;align-items:center;justify-content:space-between;gap:1rem;margin-bottom:1rem}
.panel-h h2{font-size:1.08rem}
.panel-h p{margin:.2rem 0 0;color:var(--muted);font-size:.9rem}
.panel h2{font-size:1.08rem}
.cols{display:grid;gap:1.25rem}
@media (min-width:900px){.cols{grid-template-columns:minmax(0,1.6fr) minmax(0,1fr)}.cols-even{grid-template-columns:1fr 1fr}}
.cols>.panel{margin-bottom:0}
.stack>*+*{margin-top:1.25rem}

/* Stats */
.stats{display:grid;gap:1px;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));background:var(--rule);border:1px solid var(--rule);border-radius:var(--r-m);overflow:hidden;margin-bottom:1.25rem}
.stat{background:var(--panel);padding:1.1rem 1.2rem}
.stat b{display:block;font-family:var(--f-display);font-size:1.9rem;font-weight:600;letter-spacing:-.03em;line-height:1.1}
.stat span{font-size:.86rem;color:var(--muted)}
.bars{display:flex;align-items:flex-end;gap:3px;height:120px;padding-top:.5rem}
.bars div{flex:1;display:flex;flex-direction:column-reverse;gap:1px;min-width:0;height:100%}
.bars i{display:block;border-radius:2px 2px 0 0;min-height:0}
.bars .v{background:var(--blue)}
.bars .a{background:var(--marker)}
.bars .s{background:#9FB0C2}
.legend{display:flex;flex-wrap:wrap;gap:1rem;font-size:.84rem;color:var(--muted);margin-top:.75rem}
.legend span::before{content:"";display:inline-block;width:10px;height:10px;border-radius:2px;margin-right:.4rem;vertical-align:-1px;background:var(--c)}

/* Checklist */
.checklist{list-style:none;margin:0;padding:0}
.checklist li{border-bottom:1px solid var(--rule-2)}
.checklist li:last-child{border:0}
.checklist a{display:flex;align-items:center;gap:.75rem;padding:.7rem 0;color:var(--ink);text-decoration:none}
.checklist a:hover span{text-decoration:underline}
.checklist .box{width:20px;height:20px;border-radius:5px;border:1.5px solid var(--rule);display:grid;place-items:center;flex:none}
.checklist .done .box{background:var(--ok);border-color:var(--ok);color:#fff}
.checklist .done span{color:var(--muted);text-decoration:line-through}
.meter{height:8px;background:var(--rule-2);border-radius:99px;overflow:hidden;margin:.5rem 0 1rem}
.meter i{display:block;height:100%;background:var(--blue);border-radius:99px}

/* Lists / tables */
.list{list-style:none;margin:0;padding:0}
.list>li{display:flex;align-items:center;gap:1rem;padding:.95rem 1.2rem;border-bottom:1px solid var(--rule-2)}
.list>li:last-child{border-bottom:0}
.list .grow{flex:1;min-width:0}
.list .title{font-weight:600;display:block;color:var(--ink);text-decoration:none}
.list a.title:hover{text-decoration:underline}
.list .meta{font-size:.86rem;color:var(--muted);overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.list .unread .title::before{content:"";display:inline-block;width:8px;height:8px;border-radius:50%;background:var(--blue);margin-right:.5rem;vertical-align:1px}
.table-wrap{overflow-x:auto;-webkit-overflow-scrolling:touch}
table.t{width:100%;border-collapse:collapse;font-size:.92rem}
.t th{text-align:left;font-weight:600;color:var(--muted);font-size:.8rem;padding:.7rem 1rem;border-bottom:1px solid var(--rule);background:var(--paper);white-space:nowrap}
.t td{padding:.75rem 1rem;border-bottom:1px solid var(--rule-2);vertical-align:top}
.t tr:last-child td{border-bottom:0}
.t tr:hover td{background:#FBFCFA}
.t .num{text-align:right;font-variant-numeric:tabular-nums}
.t a{font-weight:600;text-decoration:none}
.t a:hover{text-decoration:underline}
.empty{text-align:center;padding:3rem 1.5rem;color:var(--muted)}
.empty b{display:block;color:var(--ink);font-size:1.05rem;margin-bottom:.35rem}
.filters{display:flex;flex-wrap:wrap;gap:.6rem;margin-bottom:1rem}
.filters .input{width:auto;min-width:220px;flex:1;max-width:360px;min-height:40px}
.filters select.input{flex:0 1 auto;min-width:0}
.pager{display:flex;gap:.5rem;justify-content:flex-end;margin-top:1rem}

/* Section editor */
.sec-list{list-style:none;margin:0;padding:0}
.sec-list li{display:flex;align-items:center;gap:.75rem;padding:.8rem 1rem;border-bottom:1px solid var(--rule-2);background:var(--panel)}
.sec-list li:last-child{border-bottom:0}
.sec-list .grow{flex:1;min-width:0}
.sec-list .grow a{font-weight:600;color:var(--ink);text-decoration:none}
.sec-list .grow a:hover{text-decoration:underline}
.sec-list .grow small{display:block;color:var(--muted)}
.sec-list .move{display:flex;flex-direction:column}
.sec-list .move button{border:0;background:none;padding:0 .2rem;cursor:pointer;color:var(--muted);line-height:0}
.sec-list .move button:hover{color:var(--ink)}
.sec-list .move button:disabled{opacity:.25;cursor:default}
.repeater{display:grid;gap:1rem}
.rep-item{border:1px solid var(--rule);border-radius:var(--r-m);background:var(--panel)}
.rep-head{display:flex;align-items:center;gap:.5rem;padding:.6rem .6rem .6rem 1rem;border-bottom:1px solid var(--rule-2);background:var(--paper);border-radius:var(--r-m) var(--r-m) 0 0}
.rep-head b{flex:1;font-weight:600;font-size:.94rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.rep-head .icon-btn{width:34px;height:34px}
.rep-body{padding:1rem 1rem .1rem}
.rep-item.collapsed .rep-body{display:none}
.rep-item.collapsed .rep-head{border-bottom:0;border-radius:var(--r-m)}
.sticky-actions{position:sticky;bottom:0;z-index:5;background:linear-gradient(rgba(232,235,229,0),var(--bg) 35%);padding:1.5rem 0 1rem;display:flex;gap:.75rem;flex-wrap:wrap;align-items:center}
@media (max-width:1023px){.sticky-actions{bottom:calc(58px + env(safe-area-inset-bottom,0px))}}
.photo-row{display:flex;align-items:center;gap:1rem;flex-wrap:wrap}
.photo-row img,.photo-ph{width:84px;height:84px;border-radius:50%;object-fit:cover;background:var(--rule-2);display:grid;place-items:center;color:var(--muted);font-weight:700;font-size:1.4rem}

/* AI suggestions dialog */
dialog.modal{border:0;border-radius:var(--r-l);padding:0;width:min(640px,100% - 1.5rem);max-height:86vh;box-shadow:0 30px 80px rgba(22,32,42,.35);color:var(--ink)}
dialog.modal::backdrop{background:rgba(22,32,42,.45)}
.modal-h{display:flex;justify-content:space-between;align-items:center;padding:1rem 1.25rem;border-bottom:1px solid var(--rule-2);position:sticky;top:0;background:#fff}
.modal-h h2{font-size:1.1rem}
.modal-b{padding:1.25rem;overflow-y:auto}
.sugg{border-top:1px solid var(--rule-2);padding:1rem 0}
.sugg:first-of-type{border-top:0;padding-top:0}
.sugg h3{font-size:1rem;margin-bottom:.3rem}
.sugg p{color:var(--ink-2);margin:0 0 .5rem}
.sugg .ex{background:var(--paper);border:1px solid var(--rule-2);border-radius:var(--r-s);padding:.75rem;white-space:pre-wrap;font-size:.93rem;position:relative}
.sugg .ex button{position:absolute;top:.4rem;right:.4rem}
.verdict{padding:.8rem 1rem;background:var(--marker-soft);border-radius:var(--r-s);margin-bottom:1.25rem}
.ai-btn .i{color:var(--blue)}

/* Diff review */
.diff-group{margin-bottom:1.5rem}
.diff-group h2{font-size:1rem;margin:0 0 .6rem}
.diff{display:flex;gap:.9rem;align-items:flex-start;padding:1rem;border:1px solid var(--rule);border-radius:var(--r-m);background:var(--panel);margin-bottom:.6rem;cursor:pointer}
.diff:has(input:checked){border-color:var(--blue);background:#F6F9FC}
.diff input{width:20px;height:20px;accent-color:var(--blue);margin:.1rem 0 0;flex:none}
.diff .grow{flex:1;min-width:0}
.diff-title{display:flex;flex-wrap:wrap;gap:.5rem;align-items:center;font-weight:600;margin-bottom:.5rem}
.diff-cols{display:grid;gap:.6rem;font-size:.9rem}
@media (min-width:760px){.diff-cols{grid-template-columns:1fr 1fr}}
.diff-old,.diff-new{padding:.6rem .75rem;border-radius:var(--r-s);white-space:pre-wrap;word-break:break-word}
.diff-old{background:#F7EFEC;color:#6B4336}
.diff-new{background:#EAF3EC;color:#244F37}
.diff-old small,.diff-new small{display:block;font-weight:700;font-size:.72rem;margin-bottom:.25rem;opacity:.8}
.diff dl{margin:0;display:grid;grid-template-columns:auto 1fr;gap:.15rem .75rem}
.diff dt{font-weight:600;opacity:.75}
.diff dd{margin:0}

/* Design */
.swatches{display:grid;grid-template-columns:repeat(auto-fill,minmax(130px,1fr));gap:.75rem}
.swatch{display:grid;gap:.35rem;font-size:.85rem;font-weight:600}
.swatch input[type=color]{width:100%;height:44px;border:1px solid var(--rule);border-radius:var(--r-s);padding:2px;background:#fff;cursor:pointer}
.theme-preview{border-radius:var(--r-m);overflow:hidden;border:1px solid var(--rule)}
.theme-preview iframe{display:block;width:100%;height:520px;border:0;background:#fff}

/* Admin specifics */
.kv{display:grid;grid-template-columns:minmax(120px,auto) 1fr;gap:.5rem 1.5rem;margin:0}
.kv dt{color:var(--muted);font-size:.9rem}
.kv dd{margin:0;word-break:break-word}
.inline-form{display:inline}
.secret-state{font-size:.85rem;color:var(--ok);font-weight:600}
.btn-row{display:flex;flex-wrap:wrap;gap:.5rem}
.tpl-vars code{margin:0 .25rem .25rem 0;display:inline-block}
.code-area{font-family:ui-monospace,Menlo,Consolas,monospace!important;font-size:.85rem!important}
