@import url('https://fonts.googleapis.com/css2?family=Instrument+Serif:ital@0;1&display=swap');
/* ============================================================
   WARM THEME — phase 1 (John approved W7 in #proposals, 2026-10-12:
   "Move the whole site to the new warm high-end look (like /custom-work/),
   replacing the blue blueprint grid ... footer first, then headers/hero, then shop").
   Phase 1 = page ground, text/link/card colours and the footer. The header/nav
   (sitenav.js #f3dNav) and hero typography are deliberately untouched.

   SOURCE: ~/bin/warm_theme.css. Loaded LAST in <head> on every public page by ~/bin/warm_theme_pass.py
   (run by pages_deploy_clean.sh on the upload mirror once live), so it overrides each page
   family's own tokens without editing ~10 separate generators:
     A  shop/home family   --bg --panel --panel2 --line --txt --dim   (light + dark)
     B  styles.css family  --bg --bg-card --text --text-muted --accent --border (guides, /3d-printing-melbourne/ ...)
     C  one-offs           --card --fg --mut (ai, shop/add) · --paper --ink --muted --navy --chip (lab)
   Tokens mirror ~/bin/build_custom_work_page.py (#f6f4f0 ground, #1b1a18 ink, #1c1a17 footer).
   ============================================================ */

/* ---- warm palette: light is the default, html[data-theme=dark] = warm dark ---- */
html:root{
  --w-bg:#f6f4f0; --w-bg2:#efebe4; --w-panel:#fffdfa; --w-tile:#ebe7e0;
  --w-ink:#1b1a18; --w-muted:#5f5a52; --w-line:#e2ddd4; --w-hair:rgba(27,26,24,.14);
  --w-link:#00718f; --w-btn:#1b1a18; --w-btn-ink:#ffffff; --w-sel:#1b1a18; --w-sel-ink:#f6f4f0;
  --w-foot:#1c1a17; --w-foot-ink:#efe9e1; --w-foot-muted:#b3aa9e; --w-foot-line:#3a352f; --w-foot-link:#e9e3da; --w-brass:#c9a46b;
}
html[data-theme=dark]:root{
  --w-bg:#151311; --w-bg2:#1b1916; --w-panel:#1f1c19; --w-tile:#2a2622;
  --w-ink:#efe9e1; --w-muted:#aaa298; --w-line:#332e28; --w-hair:rgba(239,233,225,.14);
  --w-link:#4fc3dc; --w-btn:#efe9e1; --w-btn-ink:#1b1a18; --w-sel:#efe9e1; --w-sel-ink:#151311;
  --w-foot:#0f0e0c; --w-foot-line:#2a2622;
}

/* ---- family tokens → warm (specificity 0,2,1 beats a page's :root / html[data-theme=..]) ---- */
html:root:not(#w0){
  /* A */ --bg:var(--w-bg); --panel:var(--w-panel); --panel2:var(--w-bg2); --pane:var(--w-panel); --line:var(--w-line); --txt:var(--w-ink); --dim:var(--w-muted);
  /* B */ --bg-alt:var(--w-bg2); --bg-card:var(--w-panel); --bg-card-hover:var(--w-tile); --text:var(--w-ink); --text-muted:var(--w-muted); --text-dim:var(--w-muted);
          --accent:var(--w-ink); --accent-glow:rgba(168,131,79,.14); --border:var(--w-hair);
  /* C */ --card:var(--w-panel); --fg:var(--w-ink); --mut:var(--w-muted); --code:var(--w-bg2);
          /* lab */ --paper:var(--w-bg); --ink:var(--w-ink); --muted:var(--w-muted); --navy:var(--w-ink); --chip:var(--w-tile);
}
/* light only: accent text to AA on the warm ground. #0090ad/#00b4d8 text was 2.2-3.7:1;
   #00718f (the header "Get a Quote" teal) is 5.1:1. Buttons filled with --cyan flip to white text (5.6:1). */
html:root:not([data-theme=dark]):not(#w0){
  --cyan:#00718f; --cyan2:#005c74; --cyanTxt:#005c74;
  /* quote engine (qe.css) */ --bg2:var(--w-bg2); --line2:#cfc7ba; --mute:var(--w-muted); --acc:#00718f; --acc2:#00718f; --acc-soft:rgba(0,113,143,.09); --ok:#0f6e3d;
}
html:not([data-theme=dark]) :is(button.add,button.add:hover,.toast,.fbtadd,.btn.primary,.jb-btn,.cfg .go,#pmAdd,#fbtcart button,#checkout,#cartBtn .n,#slbar .go,.mini.o,.soonflag,.dtbadge,.dl a,.submit,.stickybuy button,.pstrip a,#dsgAdd,.gt-btn,button.go){color:#fff!important}
html:not([data-theme=dark]) .eco{color:#2f7a4a}
html:not([data-theme=dark]) #f3dpop button.go{background:#00718f!important;color:#fff!important}
html:not([data-theme=dark]) header.hd .sub{color:var(--w-muted)}
html:not([data-theme=dark]) label[for=privacy-check]{color:var(--w-muted)!important}
html:not([data-theme=dark]) label[for=privacy-check] a{color:#00718f!important}
html:not([data-theme=dark]) .fitflag{color:#7fdcf0}
html[data-theme=dark] :is(#f3dpop button.go,.jb-btn,button.go){color:#04222b!important}

/* ---- page ground: warm off-white, no blueprint grid ---- */
html body{background-color:var(--w-bg)!important;background-image:none!important;color:var(--w-ink)}
html body::before{background:none!important}           /* the faint cyan 44px grid on shop/home pages */
video.bgvid{display:none!important}                     /* fixed full-page blueprint-drawing video behind home (navy at .6 in dark mode) */
::selection{background:var(--w-sel);color:var(--w-sel-ink)}

/* ---- B: styles.css blueprint leftovers (hard-coded pale-ink / white-alpha values) ---- */
.btn-primary{background:var(--w-btn)!important;color:var(--w-btn-ink)!important;border-color:var(--w-btn)!important}
.btn-primary:hover{background:#3a352f!important}
html[data-theme=dark] .btn-primary:hover{background:#fff!important}
.btn-secondary,.btn-outline{color:var(--w-ink)!important;border-color:var(--w-hair)!important}
.prod-card-img .img-hover{background:var(--w-tile)}
.guide-table td{border-bottom-color:var(--w-hair)}
.guide-table th{border-bottom-color:var(--w-ink)}
.guide-faq details,.guide-video video,.guide-stats{border-color:var(--w-hair)}
.guide-more{border-top-color:var(--w-hair)}
.guide-stats{background:var(--w-hair)}
.guide-pick{background:var(--w-panel);border-color:var(--w-line)}
.guide-pick strong,.guide-stats b{color:var(--w-ink)}
.guide-crumbs a{color:var(--w-muted)}
.guide-body a:not(.btn):not(.gt-btn),.container p a:not(.btn){text-decoration:underline;text-decoration-color:var(--w-hair);text-underline-offset:3px}
.fsub{border-color:var(--w-line)!important;background:var(--w-panel)!important}
.fsub-form input{background:var(--w-bg)!important;border-color:var(--w-hair)!important;color:var(--w-ink)!important}
.fsub-done{color:var(--w-link)}
[style*="border:1px solid rgba(255,255,255"]{border-color:var(--w-hair)!important}
.contact-form input,.contact-form select,.contact-form textarea{background:var(--w-panel);color:var(--w-ink);border-color:var(--w-hair)}
.contact-form select option{background:var(--w-panel)}
.card,.bg-card,[class*="card"]{border-color:var(--w-line)}
/* old styles.css fixed nav (only shown where sitenav.js is absent) */
.nav{background:rgba(246,244,240,.92)!important;border-bottom-color:var(--w-line)!important}
html[data-theme=dark] .nav{background:rgba(21,19,17,.92)!important}
.nav .nav-links a:not(.btn){color:var(--w-ink)}

/* ---- footer: warm charcoal, no grid (all families; not the cart drawer's <footer>) ---- */
footer:not(aside footer):not(dialog footer):not([role=dialog] footer):not(#drawer footer){
  --txt:var(--w-foot-ink); --dim:var(--w-foot-muted); --line:var(--w-foot-line); --cyan:var(--w-foot-link);
  --text:var(--w-foot-ink); --text-muted:var(--w-foot-muted); --accent:var(--w-foot-link); --border:var(--w-foot-line);
  --fg:var(--w-foot-ink); --mut:var(--w-foot-muted); --ink:var(--w-foot-ink); --muted:var(--w-foot-muted);
  background:var(--w-foot)!important; background-image:none!important; color:var(--w-foot-muted)!important;
  border-top:0!important; position:relative; z-index:2;
}
footer:not(aside footer):not(dialog footer):not(#drawer footer) a{color:var(--w-foot-link)!important;opacity:1}
footer:not(aside footer):not(dialog footer):not(#drawer footer) a:hover{color:var(--w-brass)!important}
footer:not(aside footer):not(dialog footer):not(#drawer footer) :is(p,span,small,li,div,label,.legal){color:var(--w-foot-muted)!important}
footer:not(aside footer):not(dialog footer):not(#drawer footer) :is(h1,h2,h3,h4,h5,h6,strong,b){color:var(--w-foot-ink)!important}
footer:not(aside footer):not(dialog footer):not(#drawer footer) a :is(span,b,strong,small){color:inherit!important}
footer:not(aside footer):not(dialog footer):not(#drawer footer) .footer-legal a{opacity:1}
footer:not(aside footer):not(dialog footer):not(#drawer footer) input{background:#26231f;color:var(--w-foot-ink);border-color:var(--w-foot-line)}
/* the logo wordmark images/svg inside dark footers keep their light variant */
footer:not(aside footer):not(#drawer footer) .logo-svg{color:var(--w-foot-ink)}

/* ============================================================
   WARM THEME — phase 2 (John approved W8 in #proposals, 2026-10-12: "and live ok do that all").
   1 cyan headlines/accents -> Instrument Serif headlines, bronze (light) / sand-gold (dark) accents;
     teal #00718f stays for links + buttons (as on /custom-work/).
   2 blueprint-drawing heroes -> paint-racks hero = real photo (rainbow Vallejo load); navy blueprint
     drawings become warm "drafting paper" drawings (CSS filter, light + dark); STL pages lead with the real print.
   3 pale-cyan "10% off" sign-up boxes -> warm sand.
   4 nav "Formada" wordmark #00B4D8 (2.4:1) -> teal #00718f (5.1:1); warm nav ground. Logo image untouched.
   5 product pages showed two nav bars: sitenav.js hides the FIRST <nav>, which on /shop/p/* is the breadcrumb,
     not the page's old <header> (brand + back link). Hide that header, bring the breadcrumb back.
   ============================================================ */
html:root{--w-acc:#7a5c33; --w-sand:#d9c29b; --w-espresso:#2e2a25; --w-serif:'Instrument Serif',Georgia,'Times New Roman',serif}
html[data-theme=dark]:root{--w-acc:#d9c29b}

/* ---- 1. headlines: serif, no cyan, no glow ---- */
html body :is(h1.rv, header.hero h1, section.hero h1, .guide-hero h1, #f3dpop h2){
  font-family:var(--w-serif)!important; font-weight:400!important; letter-spacing:-.005em; text-shadow:none!important}
html body :is(h1.rv, header.hero h1){font-size:clamp(40px,5.4vw,70px); line-height:1.02}
html body :is(.guide-hero h1, section.hero h1){font-size:clamp(34px,4.4vw,56px); line-height:1.06}
@media (max-width:600px){html body :is(h1.rv, header.hero h1){font-size:clamp(32px,9.6vw,40px); line-height:1.04}
  html body :is(.guide-hero h1, section.hero h1){font-size:clamp(30px,8.6vw,38px)}}
html body :is(h1,h2,h3) em{text-shadow:none!important}
html body :is(h1.rv, header.hero h1, section.hero h1, .guide-hero h1) em{font-family:var(--w-serif)!important; font-style:italic; color:var(--w-acc)!important}
/* small accent text that was cyan: eyebrows, counts, step numbers, card meta */
html body :is(.kicker, section.hero .eyebrow, .bizk, .aik, .tbody .meta, .body .cap, .pstep .n, .stats .v span, .v > span, .aig b, .guide-meta, span.tag, p.suits){color:var(--w-acc)!important; text-shadow:none!important}
html body :is(.fb .pr, .b .p, .buy #price, .buy #price span){color:var(--w-ink)!important}
/* badges (NEW / DESIGN TOOL / COMING SOON flags) -> sand pill, ink text */
html:not(#w0):root body :is(.soonflag, .dtbadge, a.imgbox .flag){background:var(--w-sand)!important; color:#1b1a18!important; box-shadow:none!important}
html body .fitflag{background:rgba(27,26,24,.82)!important; border-color:rgba(217,194,155,.55)!important; color:#efe2c8!important}
/* chips, outlines and selected states that were cyan -> warm ink / hairline */
html body .chip{background:var(--w-bg2)!important; border-color:var(--w-line)!important; color:var(--w-ink)!important}
html body :is(ul.aiq li, .aie code, .toolgrid a.tile.tool){border-color:var(--w-line)!important}
html body ul.aiq li{background:var(--w-panel)!important}
html body span.cardcta a.add{background:var(--w-bg2)!important; border-color:var(--w-line)!important; color:var(--w-ink)!important}
html body span.cardcta a.add:hover{border-color:var(--w-ink)!important}
html body :is(#pills .pill.on, #fit.fitq button){border-color:var(--w-ink)!important; color:var(--w-ink)!important}
html body #pills .pill.on{background:var(--w-ink)!important; color:var(--w-bg)!important}
html body :is(#thumbs img.on, .sw button.on){border-color:var(--w-ink)!important}
html body .sizes button.on{border-color:var(--w-ink)!important; color:var(--w-ink)!important; background:var(--w-tile)!important}
html body .btn-ghost{color:var(--w-ink)!important; border-color:var(--w-hair)!important}
html body .hero .shade{background:linear-gradient(105deg,rgba(246,244,240,.96) 30%,rgba(246,244,240,.62) 62%,rgba(246,244,240,.4)),linear-gradient(rgba(246,244,240,.25),rgba(246,244,240,.4) 70%,var(--w-bg))!important}
html[data-theme=dark] body .hero .shade{background:linear-gradient(105deg,rgba(21,19,17,.96) 30%,rgba(21,19,17,.6) 62%,rgba(21,19,17,.35)),linear-gradient(rgba(21,19,17,.2),rgba(21,19,17,.35) 70%,var(--w-bg))!important}
html body .hero p.sub{color:var(--w-muted)!important}
/* Ask Formada floating button: espresso pill (light) / sand pill (dark) */
html body #f3dAskBtn{background:var(--w-espresso)!important; color:#f6f1e8!important; box-shadow:0 8px 24px rgba(27,26,24,.28)!important}
html[data-theme=dark] body #f3dAskBtn{background:var(--w-sand)!important; color:#1b1a18!important; box-shadow:0 8px 24px rgba(0,0,0,.45)!important}

/* ---- 2. blueprint drawings -> warm drafting paper (the colour-palette sheets keep true colours) ---- */
html body img:is([src*="blueprint" i],[src*="/bp_"],[src*="_bp_"],[src*="-bp."]):not([src*="palette" i]):not([src*="03-blueprint-iso"]):not([src*="08-blueprint-top"]){
  filter:invert(1) grayscale(1) sepia(.22) brightness(1.07) contrast(.92)}
html[data-theme=dark] body img:is([src*="blueprint" i],[src*="/bp_"],[src*="_bp_"],[src*="-bp."]):not([src*="palette" i]):not([src*="03-blueprint-iso"]):not([src*="08-blueprint-top"]){
  filter:grayscale(1) sepia(.3) brightness(.92)}
html body section.bp figure{background:var(--w-panel)!important; border-color:var(--w-line)!important}
html body section.bp figcaption{background:var(--w-bg2)!important; color:var(--w-muted)!important}
html body section.bp{border-color:var(--w-line)!important}
/* /stl/* pages: the real print leads, the drawing follows */
html body .stl-hero-grid img:not([src*="-bp."]){order:-1}
html body .stl-hero-grid img{border-color:var(--w-line)!important}
/* /shop/paint-racks hero: the cyan-lit render loop -> a real photo of a loaded rack */
html body header.hero:has(> #heroVid source[src^="hero-loop"]) #heroVid{display:none!important}
html body header.hero:has(> #heroVid source[src^="hero-loop"]){background:var(--w-bg)}
/* below 1100px the text spans the hero, so the hero is plain warm (no washed-out photo behind text) */
html body header.hero:has(> #heroVid source[src^="hero-loop"]) .shade{background:none!important}
@media (min-width:1100px){   /* text column left, the photo fills the right half */
  html body header.hero:has(> #heroVid source[src^="hero-loop"]) .wrap{margin-left:max(24px,calc(50% - 590px))}
  html body header.hero:has(> #heroVid source[src^="hero-loop"])::before{content:""; position:absolute; top:0; bottom:0; right:0; left:calc(50% + 40px);
    background:url(/pimg/9f0c172819_ainbow-vallejo-load-formada3d_0456a54f-85dc-455d-9f45-5cb289644f7c.jpg) center 30%/cover no-repeat; mix-blend-mode:multiply;
    -webkit-mask-image:linear-gradient(90deg,transparent 0,#000 22%); mask-image:linear-gradient(90deg,transparent 0,#000 22%)}
  html body header.hero:has(> #heroVid source[src^="hero-loop"]) .shade{background:linear-gradient(rgba(246,244,240,0) 82%,var(--w-bg))!important}
  html[data-theme=dark] body header.hero:has(> #heroVid source[src^="hero-loop"])::before{mix-blend-mode:normal; opacity:.9}
  html[data-theme=dark] body header.hero:has(> #heroVid source[src^="hero-loop"]) .shade{background:linear-gradient(rgba(21,19,17,0) 82%,var(--w-bg))!important}
}
/* homepage / shop hub: the blueprint video is hidden (phase 1), so its cool white veil goes too */
html body div.bgshade{display:none!important}
html body .btn-primary{box-shadow:0 8px 24px rgba(27,26,24,.16)!important}
html:not([data-theme=dark]) body > nav#nav{background:rgba(250,248,244,.92)!important; border-bottom-color:var(--w-line)!important}
html[data-theme=dark] body > nav#nav{background:rgba(21,19,17,.9)!important}
html body .soonveil{background:rgba(27,26,24,.55)!important}
html body .soonveil b{background:rgba(27,26,24,.35)!important}
html:not([data-theme=dark]) body div#toast:not(.toast){background:var(--w-panel)!important; color:var(--w-ink)!important; border-color:var(--w-ink)!important}

/* ---- 3. "10% off" sign-up boxes: pale cyan -> warm sand ---- */
html body .joinbar{background:linear-gradient(135deg,rgba(217,194,155,.30),rgba(217,194,155,.10))!important; border-color:rgba(168,131,79,.35)!important}
html body .joinbar .jb-form input{background:var(--w-panel)!important; border-color:var(--w-line)!important}
html[data-theme=dark] body .joinbar{background:linear-gradient(135deg,rgba(217,194,155,.14),rgba(217,194,155,.04))!important; border-color:rgba(217,194,155,.28)!important}
html[data-theme=dark] body .joinbar .jb-form input{background:var(--w-bg)!important}
html body .wrap > div[style*="border:1px solid var(--line)"]:has(> form[onsubmit*="formada-subscribe"]){background:linear-gradient(135deg,rgba(217,194,155,.30),rgba(217,194,155,.10)); border-color:rgba(168,131,79,.35)!important}
html[data-theme=dark] body .wrap > div[style*="border:1px solid var(--line)"]:has(> form[onsubmit*="formada-subscribe"]){background:linear-gradient(135deg,rgba(217,194,155,.14),rgba(217,194,155,.04)); border-color:rgba(217,194,155,.28)!important}
html body #f3dpop .box{background:var(--w-panel)!important; color:var(--w-ink)!important; border-color:var(--w-line)!important}
html body #f3dpop input{background:var(--w-bg)!important; border-color:var(--w-line)!important; color:var(--w-ink)!important}
html[data-theme=dark] body #f3dpop .box{background:#1f1c19!important}
/* the sitenav.js "10% off your first order" sheet (#f3dsw/#f3dsb) */
html body #f3dsw{background:rgba(27,26,24,.55)!important}
html body #f3dsb{border-color:var(--w-line)!important}
html body #f3dsb h4{font-family:var(--w-serif)!important; font-weight:400!important; font-size:26px!important}
html:not([data-theme=dark]) body :is(#f3dsb button.go, #f3dpop button.go, form[onsubmit*="formada-subscribe"] > button[type=submit]){background:#00718f!important; color:#fff!important}
html[data-theme=dark] body form[onsubmit*="formada-subscribe"] > button[type=submit]{background:#4fc3dc!important; color:#04222b!important}

/* ---- 4. shared nav (sitenav.js #f3dNav) + homepage native nav ---- */
html:not([data-theme=dark]) body #f3dNav{background:rgba(250,248,244,.94)!important; border-bottom-color:var(--w-line)!important; box-shadow:0 4px 24px rgba(27,26,24,.06)!important}
html[data-theme=dark] body #f3dNav{background:rgba(21,19,17,.92)!important; border-bottom-color:#2a2622!important; box-shadow:0 4px 30px rgba(0,0,0,.4)!important}
html:not([data-theme=dark]) body #f3dNav .fnbrand{color:var(--w-ink)}
html:not([data-theme=dark]) body #f3dNav .fnbrand b, html:not([data-theme=dark]) body a.brand > b{color:#00718f!important}
html:not([data-theme=dark]) body #f3dNav a.fnl{color:#3a352f}
html body #f3dNav a.fnl:hover{color:#00718f}
html:not([data-theme=dark]) body #f3dNav :is(.fnsel,#fnTheme,#fnCart){border-color:#d8d1c6!important; background:transparent}
html:not([data-theme=dark]) body #f3dNav .fnlinks.open, html:not([data-theme=dark]) body #f3dMM{background:#fbf9f5!important; border-bottom-color:var(--w-line)!important}
html[data-theme=dark] body #f3dNav .fnlinks.open, html[data-theme=dark] body #f3dMM{background:#1b1916!important; border-bottom-color:#2a2622!important}
html:not([data-theme=dark]) body #f3dMM .mmall, html:not([data-theme=dark]) body .mm a.hl{color:#00718f!important}
html:not([data-theme=dark]) body #f3dMM .mmh{border-bottom-color:var(--w-line)}
html body #f3dNav #fnCartN.on{background:var(--w-sand)!important; color:#1b1a18!important}

/* ---- 5. product pages: one nav bar, breadcrumb back ---- */
html body #f3dNav ~ header:has(> .wrap > a.brand[href="/"]){display:none!important}
html body #f3dNav ~ .wrap > nav.crumb{display:block!important; background:none!important; border:0!important; box-shadow:none!important; position:static!important; -webkit-backdrop-filter:none!important; backdrop-filter:none!important}
