*,*::before,*::after{box-sizing:border-box;margin:0;padding:0}
:root{--bg:#F4F1E8;--bg2:#EAE6D8;--surface:#FFFFFF;--surface2:#F9F7F1;
  --green:#2D6A35;--green-h:#1E4F26;--green-tint:rgba(45,106,53,.09);--green-ring:rgba(45,106,53,.22);
  --green2:#3D8247;--green2-tint:rgba(61,130,71,.1);
  --moss:#5A7A3A;--moss-tint:rgba(90,122,58,.1);
  --amber:#7A5C1E;--amber-tint:rgba(122,92,30,.1);
  --rust:#8B3A2A;--rust-tint:rgba(139,58,42,.08);
  --text:#12190F;--text2:#1E2E1A;--text3:#4A5E42;--text4:#5E7156;--text4-dark:#8A9E82;
  --line:#D4CFC0;--line2:#BFB9A8;
  --ok:#166534;--ok-bg:rgba(22,101,52,.08);
  --err:#B91C1C;--err-bg:rgba(185,28,28,.08);
  --font-d:"Fraunces",serif;--font-b:"DM Sans",sans-serif;
  --font-m:"Fira Mono",monospace;--font-s:"Fraunces",serif;
  --e1:0 1px 3px rgba(0,0,0,.07),0 1px 2px rgba(0,0,0,.04);
  --e2:0 4px 14px rgba(0,0,0,.09),0 2px 4px rgba(0,0,0,.05);
  --e3:0 12px 36px rgba(0,0,0,.12),0 4px 8px rgba(0,0,0,.06);
  --ease:cubic-bezier(.22,1,.36,1);
  
  --border:var(--line);--border2:var(--line2);
  --shadow-sm:var(--e1);
  --red:#B91C1C;--red-bg:rgba(185,28,28,.08);
  --green-bg:rgba(45,106,53,.08);
  --orange:var(--green);--orange-h:var(--green-h);
  --orange-tint:var(--green-tint);--orange-ring:var(--green-ring);
  --orange-light:rgba(45,106,53,.06);
  --amber-tint:rgba(122,92,30,.1);}
html{font-size:16px;scroll-behavior:smooth}
*,*::before,*::after{box-sizing:border-box}
body{font-family:var(--font-b);background:var(--bg);color:var(--text2);line-height:1.65;overflow-x:hidden;-webkit-font-smoothing:antialiased;max-width:100vw}
::-webkit-scrollbar{width:5px}
::-webkit-scrollbar-track{background:var(--bg2)}
::-webkit-scrollbar-thumb{background:var(--line2);border-radius:3px}
a{text-decoration:none;color:inherit}
img{max-width:100%;display:block}
input,textarea,select,button{font-family:var(--font-b)}
.mnav{position:sticky;top:0;z-index:200;background:rgba(255,255,255,.96);backdrop-filter:blur(14px);border-bottom:1px solid var(--line);box-shadow:var(--e1)}
.mnav-inner{display:flex;align-items:center;gap:8px;padding:0 32px;height:62px;width:100%}
.mlogo{display:flex;align-items:center;gap:10px;flex-shrink:0}
.logo-word{font-family:var(--font-d);font-size:19px;font-weight:900;color:var(--text);letter-spacing:-.4px}
.logo-word em{font-style:italic;color:var(--green)}
.mnav-links{display:flex;gap:0;flex:1;justify-content:center;overflow:visible}
.nl{font-size:13px;color:var(--text3);padding:6px 10px;border-radius:7px;transition:.15s;font-family:var(--font-b);font-weight:500}
.nl:hover{color:var(--text);background:var(--bg2)}
.nl.active{color:var(--green);background:var(--green-tint);font-weight:600}
.mnav-right{display:flex;align-items:center;gap:8px;flex-shrink:0;margin-left:auto;justify-content:flex-end}
.nav-user{position:relative}
.nu-avatar{width:30px;height:30px;border-radius:50%;display:flex;align-items:center;justify-content:center;font-family:var(--font-d);font-size:11px;font-weight:700;flex-shrink:0;overflow:hidden;color:#fff}
.nu-name{font-size:12px;color:var(--text);padding:4px 8px 4px 5px;border-radius:8px;background:var(--surface2);border:1.5px solid var(--line);display:flex;align-items:center;gap:5px;cursor:pointer;user-select:none;transition:.15s;font-weight:500}
.nu-name:focus-visible{outline:2px solid var(--green);outline-offset:2px}
.nu-name:hover{background:var(--bg2);border-color:var(--line2)}
.nu-caret{font-size:8px;color:var(--text4);margin-left:1px}
.nu-drop{display:none;position:absolute;right:0;top:calc(100% + 8px);background:var(--surface);border:1.5px solid var(--line);border-radius:12px;padding:6px;min-width:190px;z-index:400;box-shadow:var(--e3)}
.nu-drop.open{display:flex;flex-direction:column}
.nu-sep{height:1px;background:var(--line);margin:4px 6px}
.nu-drop a,.nu-drop button{display:flex;align-items:center;gap:9px;width:100%;padding:9px 12px;font-size:13px;color:var(--text2);border-radius:7px;background:none;border:none;cursor:pointer;text-align:left;transition:.12s;text-decoration:none}
.nu-drop a:hover,.nu-drop button:hover{background:var(--bg2);color:var(--text)}
.btn-ghost-nav{font-size:13px;color:var(--text2);padding:6px 12px;border-radius:7px;border:1.5px solid var(--line);transition:.15s;font-weight:500}
.btn-ghost-nav:hover{border-color:var(--line2);color:var(--text)}
.btn-green-nav{background:var(--green);color:#fff;font-size:13px;padding:6px 12px;border-radius:7px;font-weight:600;transition:.15s}
.btn-green-nav:hover{background:var(--green-h)}
.nav-burger{display:none;background:none;border:none;color:var(--text);font-size:18px;cursor:pointer;padding:6px}
.btn{display:inline-flex;align-items:center;gap:6px;padding:11px 22px;border-radius:9px;font-family:var(--font-b);font-size:13.5px;font-weight:600;cursor:pointer;border:none;transition:.15s;letter-spacing:-.1px;text-decoration:none}
.btn-primary{background:var(--green);color:#fff;box-shadow:0 1px 4px rgba(45,106,53,.35)}
.btn-primary:hover{background:var(--green-h);box-shadow:0 4px 14px rgba(45,106,53,.4)}
.btn-outline{background:transparent;color:var(--text);border:1.5px solid var(--line2)}
.btn-outline:hover{border-color:var(--green);color:var(--green)}
.btn-ghost{background:transparent;color:var(--text2);border:1.5px solid var(--line)}
.btn-ghost:hover{background:var(--bg2);border-color:var(--line2)}
.btn-sm{padding:7px 14px;font-size:12.5px;border-radius:7px}
.btn-full{width:100%;justify-content:center}
.hidden{display:none!important}
.award-row .fg{margin:0}
.rs-seg-btn.on{background:var(--green);color:#fff;box-shadow:var(--e1)}
#track{max-width:100%}
.q-dot.on{background:var(--green);width:20px;border-radius:4px}
.bd-awb.more{cursor:pointer;color:var(--green);border-color:var(--green);background:var(--green-tint)}
.bd-hero .btn-outline,.page-hero .btn-outline,
.hero-section .btn-outline,.profile-hero .btn-outline,.reading-goal-hero .btn-outline{color:#fff;border-color:rgba(255,255,255,.38);background:rgba(255,255,255,.07);}
.bd-hero .btn-outline:hover,.page-hero .btn-outline:hover,
.hero-section .btn-outline:hover,.profile-hero .btn-outline:hover,.reading-goal-hero .btn-outline:hover{border-color:#fff;background:rgba(255,255,255,.15);color:#fff;}
.bd-hero .btn-ghost,.page-hero .btn-ghost,
.hero-section .btn-ghost,.profile-hero .btn-ghost,.reading-goal-hero .btn-ghost{color:rgba(255,255,255,.82);border-color:rgba(255,255,255,.24);background:rgba(255,255,255,.06);}
.bd-hero .btn-ghost:hover,.page-hero .btn-ghost:hover,
.hero-section .btn-ghost:hover,.profile-hero .btn-ghost:hover,.reading-goal-hero .btn-ghost:hover{background:rgba(255,255,255,.14);border-color:rgba(255,255,255,.44);color:#fff;}
.flash{padding:13px 20px;border-radius:9px;margin:14px 40px;font-size:13.5px;display:flex;align-items:center;gap:10px}
.flash-success{background:var(--ok-bg);color:var(--ok);border:1px solid rgba(22,101,52,.22)}
.flash-error{background:var(--err-bg);color:var(--err);border:1px solid rgba(185,28,28,.22)}
.wrap{max-width:1200px;margin:0 auto;padding:0 40px}
.section{padding:80px 0;background:var(--bg)}
.label{font-family:var(--font-m);font-size:10px;letter-spacing:2.5px;text-transform:uppercase;color:var(--green)}
.h1{font-family:var(--font-d);font-size:clamp(34px,5.5vw,66px);font-weight:900;line-height:1.05;letter-spacing:-.5px;color:var(--text)}
.h2{font-family:var(--font-d);font-size:clamp(22px,3.5vw,40px);font-weight:700;line-height:1.15;color:var(--text)}
.h3{font-family:var(--font-d);font-size:clamp(17px,2.5vw,24px);font-weight:700;line-height:1.25;color:var(--text)}
.ob-author-form-grid .fg{display:flex;flex-direction:column;gap:5px}
@keyframes ticker{0%{transform:translateX(0)}100%{transform:translateX(-50%)}}
.state-pill.active{background:var(--green);color:#fff;border-color:var(--green)}
.cat-pill.active{background:var(--green);color:#fff;border-color:var(--green)}
.bs-item.active{color:var(--green);font-weight:600}
@keyframes bdLbIn{from{transform:scale(.92);opacity:0}to{transform:scale(1);opacity:1}}
.pill{display:inline-block;font-family:var(--font-m);font-size:10px;font-weight:600;padding:4px 11px;border-radius:20px;letter-spacing:.5px}
.fg{margin-bottom:14px}
.fg label{display:block;font-size:12px;font-weight:600;color:var(--text2);margin-bottom:5px;letter-spacing:.1px}
.fg input,.fg textarea,.fg select{width:100%;border:1.5px solid var(--line2);border-radius:8px;padding:10px 13px;font-size:13.5px;color:var(--text);background:#fff;outline:none;transition:.2s}
.fg input::placeholder,.fg textarea::placeholder{color:var(--text4)}
.fg select option{background:var(--surface);color:var(--text)}
.fg input:focus,.fg textarea:focus,.fg select:focus{border-color:var(--green);background:var(--surface);box-shadow:0 0 0 3px var(--green-tint)}
.fg textarea{resize:vertical;min-height:96px}
.fg input[type=file]{padding:8px 10px;font-size:12px;color:var(--text3);cursor:pointer}
.form-row{display:grid;grid-template-columns:1fr 1fr;gap:14px}
.pf-mod-stamp.on{background:rgba(45,106,53,.14);border-color:rgba(45,106,53,.35);filter:none;opacity:1}
.tc{background:var(--surface);border:1.5px solid var(--line);border-radius:12px;padding:16px;margin-bottom:12px;display:grid;grid-template-columns:52px 1fr auto;gap:12px;align-items:center;box-shadow:var(--e1)}
.space-link.active{background:var(--green-tint)}
.admin-layout{display:grid;grid-template-columns:210px 1fr;min-height:calc(100vh - 62px)}
.admin-sb{background:var(--surface);padding:20px 14px;border-right:1.5px solid var(--line)}
.admin-ni{display:block;padding:9px 13px;border-radius:8px;font-size:13px;color:var(--text3);margin-bottom:3px;transition:.15s;text-decoration:none;font-weight:500}
.admin-ni:hover,.admin-ni.active{background:var(--green-tint);color:var(--green)}
.admin-alert{display:flex;align-items:center;gap:10px;margin-bottom:20px;padding:12px 16px;
  border-radius:10px;background:var(--red-bg);border:1.5px solid rgba(185,28,28,.25);
  color:var(--red);font-size:13px;text-decoration:none}
.admin-alert strong{font-family:var(--font-m)}
.admin-alert:hover{background:rgba(185,28,28,.12)}
.admin-content{padding:30px 36px;background:var(--bg);min-width:0;overflow-x:auto}
.admin-title{font-family:var(--font-d);font-size:24px;font-weight:900;color:var(--text);margin-bottom:22px}
.atbl{width:100%;border-collapse:collapse;font-size:13px;background:var(--surface);border-radius:12px;overflow:hidden;border:1.5px solid var(--line);box-shadow:var(--e1)}
.atbl th{padding:11px 14px;background:var(--bg2);border-bottom:1.5px solid var(--line);font-weight:600;color:var(--text3);font-family:var(--font-m);font-size:10px;letter-spacing:1px;text-transform:uppercase;text-align:left}
.atbl td{padding:11px 14px;border-bottom:1px solid var(--line);color:var(--text2);vertical-align:middle}
.atbl tr:hover td{background:var(--surface2)}
.atbl tr:last-child td{border-bottom:none}
.nl-group{position:relative;display:inline-flex;align-items:center}
.nl-group-btn{display:inline-flex;align-items:center;gap:4px;font-size:13.5px;color:var(--text2);padding:6px 10px;border-radius:7px;cursor:pointer;transition:.15s;font-family:var(--font-b);font-weight:500;border:none;background:none;white-space:nowrap}
.nl-group-btn:hover,.nl-group-btn.open{color:var(--green);background:var(--green-tint)}
.nl-group-btn .nl-caret{font-size:8px;opacity:.5;transition:.2s;display:inline-block}
.nl-group-btn.open .nl-caret{transform:rotate(180deg);opacity:.8}
.nl-group-drop{position:absolute;top:calc(100% + 6px);left:0;min-width:170px;background:var(--surface);border:1.5px solid var(--line);border-radius:10px;box-shadow:var(--e2);padding:6px;z-index:400;display:none;flex-direction:column;gap:2px}
.nl-group-drop.open{display:flex}
.nl-group-drop a{display:block;padding:8px 12px;border-radius:7px;font-size:13px;color:var(--text2);text-decoration:none;transition:.15s;font-weight:500;white-space:nowrap}
.nl-group-drop a:hover{background:var(--green-tint);color:var(--green)}
.nl-group-drop a.active{color:var(--green);font-weight:600}
.menu-row{display:flex;align-items:stretch;gap:0;border-radius:12px;border:1.5px solid var(--line);background:var(--surface);overflow:hidden;transition:.15s;cursor:default}
.menu-row:hover{border-color:var(--line2);box-shadow:var(--e1)}
.menu-row.drag-over{border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint);background:var(--surface2)}
.menu-row.dragging{opacity:.45;border-style:dashed}
.menu-drag-handle{display:flex;align-items:center;justify-content:center;width:36px;flex-shrink:0;background:var(--surface2);border-right:1.5px solid var(--line);cursor:grab;color:var(--text4);font-size:16px;transition:.15s;user-select:none}
.menu-drag-handle:active{cursor:grabbing;background:var(--green-tint);color:var(--green)}
.menu-row-body{flex:1;padding:14px 16px;display:flex;flex-direction:column;gap:10px}
.menu-row-fields{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.menu-row-meta{display:flex;align-items:center;justify-content:space-between;gap:12px}
.menu-toggle{position:relative;display:inline-flex;align-items:center;gap:8px;cursor:pointer;user-select:none}
.menu-toggle input{position:absolute;opacity:0;width:0;height:0}
.menu-toggle-track{width:36px;height:20px;border-radius:999px;background:var(--line2);transition:.2s;flex-shrink:0;position:relative}
.menu-toggle input:checked~.menu-toggle-track{background:var(--green)}
.menu-toggle-thumb{position:absolute;top:3px;left:3px;width:14px;height:14px;border-radius:50%;background:#fff;box-shadow:0 1px 3px rgba(0,0,0,.2);transition:.2s}
.menu-toggle input:checked~.menu-toggle-track .menu-toggle-thumb{transform:translateX(16px)}
.menu-toggle-label{font-size:12.5px;font-weight:600;color:var(--text3)}
.menu-row.inactive-row{opacity:.65}
.menu-preview{background:var(--text);border-radius:10px;padding:10px 16px;display:flex;align-items:center;gap:6px;flex-wrap:wrap;min-height:42px}
.menu-preview-item{font-size:12px;color:rgba(255,255,255,.6);padding:4px 10px;border-radius:6px;transition:.15s;font-family:var(--font-b);font-weight:500;white-space:nowrap}
.menu-preview-item.active{color:#fff;background:rgba(255,255,255,.12)}
.menu-preview-logo{font-family:var(--font-d);font-size:13px;font-weight:700;color:#fff;margin-right:8px;padding-right:12px;border-right:1px solid rgba(255,255,255,.15);white-space:nowrap}
.menu-add-btn{display:inline-flex;align-items:center;gap:7px;padding:9px 16px;border-radius:9px;border:1.5px dashed var(--line2);background:transparent;color:var(--text3);font-size:13px;font-weight:600;cursor:pointer;transition:.15s;font-family:var(--font-b)}
.menu-add-btn:hover{border-color:var(--green);color:var(--green);background:var(--green-tint)}
a:focus-visible,button:focus-visible,input:focus-visible,select:focus-visible,textarea:focus-visible,label:focus-visible{outline:2px solid var(--green);outline-offset:2px;border-radius:4px}
@media (prefers-reduced-motion: reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important;scroll-behavior:auto!important}}
.site-footer{background:#0A1A0C;padding:52px 40px 26px}
.footer-inner{display:grid;grid-template-columns:2fr 3fr;gap:52px;margin-bottom:44px}
.footer-cols-row{display:grid;grid-template-columns:1fr 1fr 1fr;gap:32px}
.fb-logo{display:flex;align-items:center;gap:10px;font-family:var(--font-d);font-size:18px;font-weight:900;color:#fff;margin-bottom:12px}
.footer-brand p{font-size:13px;color:rgba(255,255,255,.3);line-height:1.75}
.fc h4{font-family:var(--font-m);font-size:9.5px;font-weight:700;letter-spacing:2.5px;text-transform:uppercase;color:rgba(255,255,255,.22);margin-bottom:14px}
.fc a{display:block;font-size:13px;color:rgba(255,255,255,.35);margin-bottom:9px;transition:.15s}
.fc a:hover{color:var(--green2)}
.footer-bottom{display:flex;align-items:center;justify-content:space-between;padding-top:20px;border-top:1px solid rgba(255,255,255,.08);font-family:var(--font-m);font-size:11px;color:rgba(255,255,255,.2);letter-spacing:.3px}
@media(max-width:1200px){.nl{font-size:12.5px;padding:6px 8px}}
@media(max-width:1380px){.nu-name .nu-label{display:none}}
@media(max-width:900px){.mnav-inner{padding:0 16px;justify-content:space-between}
.mnav-links{display:none;position:absolute;top:62px;left:0;right:0;background:var(--surface);flex-direction:column;padding:8px 16px 16px;border-bottom:1.5px solid var(--line);z-index:300;box-shadow:var(--e2)}
.mnav-links.open{display:flex}
.nl-group{width:100%}
.nl-group-btn{width:100%;justify-content:space-between;padding:8px 4px}
.nl-group-drop{position:static;border:none;box-shadow:none;background:var(--bg2);border-radius:8px;padding:4px 8px;margin-top:2px}
.nl-group-drop.open{display:flex}
.mnav-right{gap:6px}
.nav-burger{display:block}
.footer-inner{grid-template-columns:1fr;gap:0}
.footer-brand{padding-bottom:28px;margin-bottom:28px;border-bottom:1px solid rgba(255,255,255,.08)}
.footer-cols-row{grid-template-columns:1fr 1fr 1fr;gap:20px}
.admin-layout{grid-template-columns:1fr}
.admin-sb{display:flex;gap:4px;flex-wrap:wrap;padding:10px;border-right:none;border-bottom:1.5px solid var(--line)}
.admin-content{padding:20px 12px}
.form-row{grid-template-columns:1fr}
.wrap{padding:0 16px}
.site-footer{padding:40px 20px 20px}
.flash{margin:10px 16px}}
@media(max-width:760px){.wrap,.bd-body,.books-layout,.community-layout,.tracker-layout,.profile-hero{max-width:100%;overflow-x:hidden}
.section{padding:32px 0;width:100%;overflow-x:hidden}
.nr-qa-compose-actions .btn{width:100%;justify-content:center}
.pill{font-size:9.5px;padding:3px 9px}
.bd-actions .btn{padding:10px 16px;font-size:13px;flex:1;min-width:130px;text-align:center;justify-content:center}
.bd-actions .btn-primary{flex:1 0 100%}
.bd-share .btn{flex:1;min-width:0}
.wrap{padding:0 16px}
.mnav-inner{padding:0 14px}
.mnav-right{gap:4px}
.nu-name .nu-pts{display:none}
.nu-name .nu-caret{display:none}
.nu-name .nu-label{display:none}
.nu-name{padding:3px;gap:0;background:none;border-color:transparent;border-radius:50%;min-width:40px;min-height:40px;justify-content:center}
.nu-name:hover{background:none;border-color:var(--line)}
.nu-avatar{width:34px;height:34px;font-size:12px}
.btn-ghost-nav{padding:5px 8px;font-size:12px;border-color:transparent}
.btn-green-nav{padding:5px 10px;font-size:12px}
.flash{margin:8px 14px;font-size:13px}
.footer-inner{grid-template-columns:1fr;gap:0}
.footer-brand{padding-bottom:24px;margin-bottom:24px;border-bottom:1px solid rgba(255,255,255,.08)}
.footer-cols-row{display:grid!important;grid-template-columns:1fr 1fr 1fr;gap:16px}}
@media(max-width:480px){.footer-inner{grid-template-columns:1fr}
.footer-cols-row{grid-template-columns:1fr 1fr!important}
.footer-bottom{flex-direction:column;gap:8px;text-align:center}}
@keyframes hpTrendingPulse{0%{box-shadow:0 0 0 0 rgba(22,163,74,.6)}70%{box-shadow:0 0 0 10px rgba(22,163,74,0)}100%{box-shadow:0 0 0 0 rgba(22,163,74,0)}}
.hp-trending-slide.active{opacity:1;transform:translateY(0);pointer-events:auto;position:relative}
.hp-trending-dot-btn.active{background:var(--green);transform:scale(1.4)}
@keyframes hpPulse{0%,100%{opacity:1;transform:scale(1)}50%{opacity:.5;transform:scale(.7)}}
.hp-qr-slide.active{display:block}
@keyframes hpQrIn{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:translateY(0)}}
.hp-qr-dot-btn.on{background:var(--green2);width:18px;border-radius:3px}
.pp-toast.show{transform:translateX(-50%) translateY(0);opacity:1}
.mr-tab.on{color:var(--green);border-bottom-color:var(--green);font-weight:700}
.mr-tab.on .mr-tab-count{background:var(--green);color:#fff}
.mr-qa-input.focus{border-color:var(--green);background:var(--surface)}
.mr-yr.on{background:var(--green);color:#fff;border-color:var(--green)}
.mr-bar-n.on{color:var(--green);font-weight:800;font-size:12px}
.mr-bar.filled{background:linear-gradient(180deg,var(--green2),var(--green));opacity:1;box-shadow:inset 0 1px 0 rgba(255,255,255,.2)}
.mr-bar.current{outline:2px solid var(--green-ring);outline-offset:2px;box-shadow:0 0 0 4px rgba(45,106,53,.1),inset 0 1px 0 rgba(255,255,255,.3)}
.mr-bar-m.on{color:var(--green);font-weight:700}
.cv2-space-pill.on{background:var(--green);color:#fff;border-color:var(--green);font-weight:700}
.cv2-space-pill.on .cv2-sp-dot{display:none}
.cv2-compose:focus-within,.cv2-compose.editing{border-color:var(--green);box-shadow:0 0 0 4px var(--green-tint),var(--e1)}
.cv2-compose.editing .cv2-compose-toolbar{border-top:none;padding:10px 20px 4px}
.cv2-compose.editing .cv2-compose-footer{padding-top:14px}
.cv2-fp.on{background:var(--text);color:#fff;border-color:var(--text)}
.cv2-more-menu.open{display:block}
.cv2-act.on{color:var(--green);background:var(--green-tint)}
.cv2-act.on.bookmark{color:var(--amber);background:var(--amber-tint)}
.cv2-reply-like.on{color:var(--green)}
.cv2-pg.on{background:var(--green);color:#fff;border-color:var(--green)}
.cv2-reply-accept.on{background:var(--green);color:#fff;border-color:var(--green)}
.bd-sticky.on{transform:translateY(0)}
.bd-sheet-backdrop.on{opacity:1;pointer-events:auto}
.bd-sheet.on{transform:translateY(0)}
.bd-sheet-item.on{background:var(--green);border-color:var(--green);color:#fff}
.bd-sheet-item.on .bd-sheet-lbl{color:#fff}
.bd-celebrate-backdrop.on{opacity:1;pointer-events:auto}
.bd-celebrate.on{opacity:1;pointer-events:auto;transform:translate(-50%,-50%) scale(1)}
.bd-celebrate.on .bd-celebrate-confetti span{opacity:1}
@keyframes bd-fall{
  0%{transform:translateY(0) rotate(0);opacity:0}
  10%{opacity:1}
  100%{transform:translateY(420px) rotate(360deg);opacity:0}
}
.bd-celebrate-actions .btn{flex:1;min-width:140px}
@media(max-width:480px){.bd-celebrate-actions .btn{width:100%}}
@keyframes obFadeIn{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
@media(max-width:900px){:root{--nr-tabh:60px}
.nr-tab.on{color:var(--green);font-weight:700}
.nr-tab.on svg{stroke-width:2}
body{padding-bottom:calc(var(--nr-tabh) + 4px + env(safe-area-inset-bottom,0px))}
@media(display-mode:standalone){.mnav{padding-top:env(safe-area-inset-top,0px)}}}
[hidden]{display:none!important}
.nr-install{border-top:1px solid rgba(255,255,255,.08);margin-top:8px;
  padding:16px 0 4px;text-align:center}
.nr-install-btn{display:inline-flex;align-items:center;gap:8px;
  font-family:var(--font-b);font-size:13px;font-weight:600;color:#0A1A0C;
  background:var(--green2);border:0;border-radius:8px;padding:9px 18px;
  cursor:pointer;transition:filter .15s}
.nr-install-btn:hover{filter:brightness(1.08)}
.nr-install-btn:focus-visible{outline:2px solid var(--green2);outline-offset:3px}
.nr-install-help{font-size:12.5px;color:rgba(255,255,255,.45);
  max-width:52ch;margin:0 auto;line-height:1.7}
.nr-install-help b{display:block;color:rgba(255,255,255,.7);
  font-family:var(--font-d);font-size:14px;font-weight:600;margin-bottom:5px}
.nr-install-help p b{display:inline;font-family:var(--font-b);font-size:inherit;
  color:rgba(255,255,255,.8)}
/* 1.12: beta label and feedback strip, footer disclaimer */
.beta-tag{font-family:var(--font-m);font-size:9.5px;font-weight:600;letter-spacing:.6px;text-transform:uppercase;color:var(--green);background:var(--green-tint);border:1px solid var(--green-ring);border-radius:999px;padding:2px 7px;line-height:1.3;align-self:center}
.beta-strip{display:flex;align-items:center;justify-content:center;gap:10px;padding:7px 44px 7px 16px;position:relative;background:var(--green);color:#fff;font-size:12.5px;line-height:1.45;text-align:center}
.beta-strip a{color:#fff;font-weight:700;text-decoration:underline;text-underline-offset:2px}
.beta-strip button{position:absolute;right:8px;top:50%;transform:translateY(-50%);width:30px;height:30px;border:0;border-radius:6px;background:transparent;color:#fff;font-size:18px;line-height:1;cursor:pointer}
.beta-strip button:hover,.beta-strip button:focus-visible{background:rgba(255,255,255,.16)}
.footer-disc{max-width:620px;text-align:right;line-height:1.6;font-family:var(--font-b);font-size:11.5px;letter-spacing:0}
@media(max-width:480px){.footer-disc{text-align:center}}
/* 1.14: newsletter archive */
.nl-cta{margin:var(--s5) 0;padding:14px 16px;border:1px solid var(--line);border-radius:var(--rad);background:var(--surface);font-size:14px;display:flex;gap:12px;align-items:center;flex-wrap:wrap}
.nl-cta .hm-btn{margin-left:auto}
.nl-list{list-style:none;margin:var(--s5) 0 0;padding:0}
.nl-list li{padding:14px 0;border-bottom:1px solid var(--line);display:flex;flex-direction:column;gap:2px}
.nl-list a{color:var(--text);font-size:17px}
.nl-list small{color:var(--text3);font-size:12.5px}
.nl-list span{color:var(--text2);font-size:14px}

/* 1.14.2: maintenance page */
.mt-page{min-height:100vh;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:22px;padding:40px 16px;background:radial-gradient(ellipse at 50% 0%,var(--green-tint),transparent 60%),var(--bg)}
.mt-preview{max-width:560px;width:100%;font-size:13px;padding:10px 14px;border-radius:10px;background:var(--amber-tint);color:var(--text2)}
.mt-brand img{height:40px;max-width:200px;object-fit:contain;display:block}
.mt-brand .logo-word{font-size:24px}
.mt-card{max-width:560px;width:100%;text-align:center;background:var(--surface);border:1px solid var(--line);border-radius:18px;padding:36px 32px 30px;box-shadow:0 18px 50px -24px rgba(18,25,15,.25)}
.mt-art{width:170px;height:auto;display:block;margin:0 auto 18px}
.mt-sea{fill:var(--green-tint)}
.mt-hull{fill:var(--green)}
.mt-box{stroke:var(--surface);stroke-width:1.5}
.mt-b1{fill:var(--green2,var(--green))}.mt-b2{fill:var(--amber)}.mt-b3{fill:var(--rust)}
.mt-b3{animation:mt-lift 3.2s ease-in-out infinite;transform-origin:center}
.mt-crane,.mt-hook{fill:none;stroke:var(--text3);stroke-width:2.5;stroke-linecap:round;stroke-linejoin:round}
.mt-gear circle{fill:none;stroke:var(--green);stroke-width:4;stroke-dasharray:4 3}
.mt-gear .mt-gear-hole{stroke-width:2;stroke-dasharray:none}
.mt-gear{transform-origin:138px 34px;animation:mt-spin 6s linear infinite}
.mt-eyebrow{font-size:11px;font-weight:600;letter-spacing:2px;text-transform:uppercase;color:var(--green);margin-bottom:6px}
.mt-card .v4-h1{margin:0 0 12px}
.mt-msg{font-size:16px;line-height:1.6;color:var(--text3);max-width:44ch;margin:0 auto}
.mt-when{display:inline-flex;align-items:center;gap:8px;margin-top:18px;padding:9px 14px;border-radius:999px;background:var(--green-tint);color:var(--text2);font-size:14px}
.mt-when svg{width:18px;height:18px;fill:none;stroke:var(--green);stroke-width:2;stroke-linecap:round;flex-shrink:0}
.mt-bar{height:4px;border-radius:999px;background:var(--bg2);overflow:hidden;margin:24px auto 14px;max-width:280px}
.mt-bar span{display:block;height:100%;width:35%;border-radius:999px;background:var(--green);animation:mt-slide 1.8s ease-in-out infinite}
.mt-small{font-size:13px;color:var(--text4);max-width:46ch;margin:0 auto}
.mt-foot{font-size:12.5px;color:var(--text4)}
.mt-foot a{color:var(--text3);text-decoration:underline}
@keyframes mt-spin{to{transform:rotate(360deg)}}
@keyframes mt-lift{0%,100%{transform:translateY(0)}50%{transform:translateY(-6px)}}
@keyframes mt-slide{0%{transform:translateX(-110%)}100%{transform:translateX(320%)}}
@media (prefers-reduced-motion:reduce){.mt-gear,.mt-b3,.mt-bar span{animation:none}.mt-bar span{width:100%;opacity:.35}}
@media (max-width:520px){.mt-card{padding:28px 20px 24px}.mt-art{width:140px}}


/* ══════════════════════════════════════════════════════════════════════════
   V4 TOKENS
   Colour tokens are inherited from the v3 :root block, which is already
   well-disciplined (1758 var() uses against 195 raw hexes). Nothing here
   redefines a colour. What was missing was type, space, and rhythm.
   ══════════════════════════════════════════════════════════════════════════ */
:root{
  /* Type scale. 1.25 ratio, rounded to whole pixels. */
  /* v4.1.0 — five steps that are actually distinguishable, not nine that are
     not. The old --t-sm 13 against --t-xs 12 meant a card title and its author
     line were the same thing to a reader; the gap between adjacent steps is now
     at least 2px below 20 and proportional above it. */
  --t-2xs:10px;   /* tag caps only, never body text       */
  --t-xs:12px;    /* meta, timestamps, tags               */
  --t-sm:14px;    /* secondary body, captions             */
  --t-base:16px;  /* body                                 */
  --t-md:16px;    /* MINIMUM for any input. See note below */
  --t-lg:18px;    /* the thought / quote voice            */
  --t-xl:22px;    /* panel headings                       */
  --t-2xl:27px;   /* page title, mobile                   */
  --t-3xl:34px;   /* page title, desktop                  */
  --t-4xl:42px;   /* hero only, used sparingly            */

  /* v4.1.0 — two weights, used deliberately. Almost everything was 500, which
     reads as neither bold nor regular. A name or a title is 600; everything
     else is 400 and gets its emphasis from size and colour instead. */
  --w-name:600;
  --w-body:400;
  /* v4.1.2 — display type needs LESS weight than UI type to read as equally
     emphatic. That is optical sizing: at 34px a stroke that reads as confident
     is heavy at 14px, and the reverse. 4.1.1 put page titles on --w-name (600)
     to fix them reading thin at 400, and overshot — on a phone the hero came
     out as a slab. Headings get their own token; card titles and reader names
     keep 600, because small text does need it. */
  --w-display:300;
  /* v4.6.4 — the weight for the NAME of something: a book title, an author.
     --w-display stays light because the only other thing wearing .v4-h1 is
     the homepage hero, which is a sentence rather than a name. Both live
     inside the loaded 300-900 range, so both render as asked. */
  --w-title:600;

  /* Line heights, paired to the scale rather than set ad hoc. */
  --lh-tight:1.2;
  --lh-snug:1.45;
  --lh-body:1.6;

  /* Space scale. Every margin, padding and gap picks from these eight. */
  --s1:4px; --s2:8px; --s3:12px; --s4:16px;
  --s5:24px; --s6:32px; --s7:48px; --s8:64px;

  /* Radius */
  --rad-sm:6px; --rad:10px; --rad-lg:14px; --rad-full:999px;

  /* Measure. Prose never runs wider than this. */
  --measure:62ch;

  /* Avatar sizes, so face stacks line up across pages. */
  --face-sm:26px; --face:31px; --face-lg:44px; --face-xl:96px;

  /* v4.0.0-beta.4 — stars. --amber (#7A5C1E) is a dark olive-brown that reads
     as mud at star size. It is consumed by v3 award chips and .btn-amber, so it
     is left alone; this token is used only by .v4 .v4-star-on. */
  --star:#D9A32B;
  --star-off:rgba(217,163,43,.18);
}

/* v4.6.0 — the CSS half of the colour-scheme declaration. The meta tag tells
   the browser before the stylesheet arrives; this tells form controls,
   scrollbars and the rest of the UA chrome to stay light too. */
:root{color-scheme:light}

/* iOS Safari magnifies the viewport when a focused input is under 16px and
   never restores it. That shipped as v3.38.1. It is now structural: any v4
   control inherits the floor and cannot opt out by accident. */
.v4 input,.v4 textarea,.v4 select{font-size:var(--t-md)}

/* ══════════════════════════════════════════════════════════════════════════
   V4 SCOPE + LAYOUT PRIMITIVES
   Everything is namespaced under .v4 so a v4 page and a v3 page can coexist
   on the same site during the migration.
   ══════════════════════════════════════════════════════════════════════════ */
.v4{font-family:var(--font-b);font-size:var(--t-base);line-height:var(--lh-body);color:var(--text)}
/* v4.0.0-beta.6 — 1080, matching body.v4skin .wrap.
   900 was chosen for reading and it is still right for reading, but it was
   never the constraint on prose: .v4-prose caps text at --measure (62ch, about
   465px) independently, so text lines do not get longer here. What 900 was
   actually capping was everything that is not prose — the browse grid at six
   covers, the author directory at two columns, book details at two.
   The other half of the reason is the seam. v4 pages were 900 and the 22 v3
   pages under the skin were 1080, so clicking from the Commons to the Quote
   Wall stepped the content 180px wider. One number for the whole site.
   Not v3's 1200: five cards across a main column reads as a directory, and
   narrowing that was one of the deliberate v4 changes. */
.v4 .v4-wrap{max-width:1080px;margin:0 auto;padding:0 var(--s5)}
.v4 .v4-prose{max-width:var(--measure)}

/* The two-column shell. minmax(0,...) on both tracks is not optional: grid
   items default to min-width:auto, which is what blew the main column out in
   v3.38.2 when a carousel wider than its track refused to shrink. */
.v4 .v4-cols{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:var(--s6);margin-top:var(--s5)}
.v4 .v4-stack>*+*{margin-top:var(--s5)}
.v4 .v4-stack-tight>*+*{margin-top:var(--s3)}

/* Any flex row that contains text. min-width:0 on the growing child is the
   other half of the same bug class. Baked in so call sites cannot forget. */
.v4 .v4-row{display:flex;gap:var(--s3);align-items:flex-start;padding:var(--s3) 0;border-bottom:1px solid var(--line)}
.v4 .v4-row:last-child{border-bottom:none}
.v4 .v4-row>.v4-grow{flex:1;min-width:0}

/* ── type ─────────────────────────────────────────────────────────────────── */
/* v4.1.1 — back to weight. 4.1.0 dropped these to 400 on the theory that a
   display face at 34px does not also need weight. It does: Fraunces is
   fine-stroked and at 400 a book title read thin rather than confident. */
.v4 .v4-h1{font-family:var(--font-d);font-weight:var(--w-display);font-size:var(--t-3xl);line-height:var(--lh-tight);letter-spacing:-.015em;margin:0 0 var(--s1)}
/* v4.6.4 — .is-name marks a heading that names a thing rather than saying
   something. Book pages and author pages carry it; the homepage hero does
   not. */
.v4 .v4-h1.is-name{font-weight:var(--w-title);letter-spacing:-.02em}
.v4 .v4-h2{font-family:var(--font-d);font-weight:var(--w-display);font-size:var(--t-xl);line-height:var(--lh-snug);letter-spacing:-.01em;margin:0 0 var(--s3)}
/* v4.1.0 — an eyebrow is a label, not content. It was --t-xs at weight 700,
   the same size as the meta text under it and heavier than most titles, so it
   competed with the section it was introducing. Smaller, lighter, wider. */
/* v4.1.1 — 600, not 500. Dropping an eyebrow from 700 to 500 took it one step
   too far: ABOUT THE BOOK and BOOK DETAILS receded until they stopped working
   as section markers. The smaller size and wider tracking were right; the
   weight was not. */
.v4 .v4-eyebrow{font-family:var(--font-m);font-weight:600;font-size:var(--t-2xs);
  letter-spacing:.14em;text-transform:uppercase;color:var(--text3);margin:0 0 var(--s4)}
/* v4.1.0 — a panel's own label sits below a page section's. Every heading on
   the page carried identical weight, so the giveaway and "Nobody can find a
   copy" felt equally urgent. */
.v4 .v4-panel > .v4-eyebrow:first-child{margin-bottom:var(--s3);color:var(--text4)}

/* v4.1.0 — the reading voice. A thought is somebody speaking and should sound
   like it: larger than the meta around it, with room to breathe. */
/* Italic now survives only on the presence lede, which is always one sentence. */
.v4 .v4-thought q{line-height:var(--lh-body)}
.v4 .v4-meta{font-family:var(--font-m);font-size:var(--t-xs);color:var(--text4);letter-spacing:.02em}
.v4 .v4-sub{color:var(--text3);font-size:var(--t-sm);line-height:var(--lh-snug)}

/* ── buttons ──────────────────────────────────────────────────────────────── */
.v4 .v4-btn{display:inline-block;background:var(--green);color:#fff;font-family:var(--font-b);font-size:var(--t-base);font-weight:500;padding:var(--s3) var(--s4);border-radius:var(--rad);border:none;cursor:pointer;text-align:center;line-height:1.3}
.v4 .v4-btn:hover{background:var(--green-h)}
/* beta.8 — a secondary action. The status pills are what a reader is doing
   with the book; a follow is about the author, and at equal weight it read as
   the loudest control on the page. */
.v4 .v4-btn.is-sm{font-size:var(--t-sm);padding:var(--s2) var(--s3)}
.v4 .v4-btn.is-ghost{background:transparent;color:var(--green-h);border:1.5px solid var(--line2)}
.v4 .v4-btn.is-ghost:hover{border-color:var(--green);background:var(--green-tint)}
.v4 .v4-btn.is-wide{display:block;width:100%}

.v4 .v4-tag{display:inline-block;font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.05em;text-transform:uppercase;padding:var(--s1) var(--s2);border-radius:var(--rad-sm);background:var(--bg2);color:var(--text3)}
.v4 .v4-tag.is-now{background:var(--green-tint);color:var(--green-h)}
.v4 .v4-tag.is-ask{background:var(--rust-tint);color:var(--rust)}

/* ── surfaces ─────────────────────────────────────────────────────────────── */
.v4 .v4-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s4)}
.v4 .v4-panel{background:var(--surface2);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s4)}
/* v4.10.2 — the signed-out compose prompt. Shaped like .v4-compose so the
   page does not rearrange when somebody signs in: the ghost is replaced by the
   real box in the same place at about the same height.

   It is an <a>, not a form, and the "Sign in" pill inside it is a <span> —
   nesting a real button inside a link gives assistive tech two controls where
   there is one. The whole row is the link; the pill is how it looks. */
.v4 .v4-compose-ghost{display:flex;align-items:center;gap:var(--s3);
  text-decoration:none;background:var(--surface);border:1px solid var(--line);
  border-radius:var(--rad-lg);padding:var(--s3);margin:0 0 var(--s4)}
.v4 .v4-compose-ghost:hover{border-color:var(--green-ring)}
.v4 .v4-compose-ghost:focus-visible{outline:2px solid var(--green);outline-offset:2px}
.v4 .v4-compose-ghost-av{width:38px;height:38px;border-radius:50%;flex:none;
  background:var(--bg2)}
.v4 .v4-compose-ghost-t{flex:1;min-width:0;font-family:var(--font-b);
  font-size:var(--t-base);color:var(--text4);overflow:hidden;
  text-overflow:ellipsis;white-space:nowrap}
/* v4.10.3 — the book page needs a rating alongside the line, so its ghost
   carries five off stars.

   A GRID, not the base rule's flex row. On a 342px phone row the placeholder,
   the stars and the pill do not all fit, and flex resolved that by shrinking
   the placeholder to "One line about th..." -- the one string that carries the
   message. Here the avatar and the pill each span both rows and the stars sit
   on their own row directly under the placeholder they qualify, so nothing is
   truncated and the height is the same 64px the Commons ghost has.

   Wrapping the stars and pill into a flex group was tried first: on a phone it
   pushed them to a second line hard right, under nothing, and the two halves
   read as separate objects. */
.v4 .v4-compose-ghost.is-rate{display:grid;grid-template-columns:auto 1fr auto;
  align-items:center;column-gap:var(--s3);row-gap:5px}
.v4 .v4-compose-ghost.is-rate .v4-compose-ghost-av{grid-column:1;grid-row:1/3}
.v4 .v4-compose-ghost.is-rate .v4-compose-ghost-t{grid-column:2;grid-row:1}
.v4 .v4-compose-ghost.is-rate .v4-ghoststars{grid-column:2;grid-row:2}
.v4 .v4-compose-ghost.is-rate .v4-btn{grid-column:3;grid-row:1/3}
.v4 .v4-ghoststars{display:block;width:66px;height:13px;fill:var(--line2)}

/* v4.10.4 — the website link on a public profile. v3 rendered one; the v4 port
   dropped it, so the field was collected and never read back for four releases.
   Mono because it is a machine address, not prose. */
.v4 .v4-weblink{display:inline-block;margin-top:var(--s2);font-family:var(--font-m);
  font-size:var(--t-xs);color:var(--green);text-decoration:none;
  border-bottom:1px solid var(--green-ring);padding-bottom:1px}
.v4 .v4-weblink:hover{border-bottom-color:var(--green)}
/* v4.10.4 — the reading-from question on onboarding step 1. */
.v4 .v4ob-place{margin:var(--s5) 0 0;max-width:340px}
.v4 .v4ob-place select{width:100%;margin-top:var(--s2)}

.v4 .v4-empty{border:1px dashed var(--line2);border-radius:var(--rad-lg);padding:var(--s5);text-align:center}
/* v4.1.0 — italic is reserved for a person's own words (a thought) and the
   editorial lede (the presence line). An empty state is the site talking to
   you about nothing being there; in italic it read as wistful. */
.v4 .v4-empty p{margin:0 0 var(--s3);font-family:var(--font-d);font-size:var(--t-lg);color:var(--text3)}

/* ══════════════════════════════════════════════════════════════════════════
   THE PRESENCE LINE — the signature element of v4
   Named people, not counts. At 121 members a count of 18 reads as small;
   three named people reading right now reads as a room with people in it.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-presence{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap;padding:var(--s3) 0;border-top:1px solid var(--line);border-bottom:1px solid var(--line);margin:var(--s4) 0}
.v4 .v4-presence p{margin:0;font-family:var(--font-d);font-size:var(--t-lg);line-height:var(--lh-snug);color:var(--text2);flex:1;min-width:220px}
.v4 .v4-presence p em{font-style:italic}

.v4 .v4-faces{display:flex;flex-shrink:0}
.v4 .v4-face{width:var(--face);height:var(--face);border-radius:var(--rad-full);background:var(--bg2);border:2px solid var(--bg);margin-left:-9px;display:flex;align-items:center;justify-content:center;font-family:var(--font-b);font-size:var(--t-xs);font-weight:700;color:var(--text3);flex-shrink:0;overflow:hidden}
.v4 .v4-face:first-child{margin-left:0}
.v4 .v4-face.is-live{background:var(--green-tint);color:var(--green-h);border-color:var(--green)}
.v4 .v4-face.is-sm{width:var(--face-sm);height:var(--face-sm);font-size:var(--t-2xs)}
.v4 .v4-face.is-lg{width:var(--face-lg);height:var(--face-lg);font-size:var(--t-sm)}
.v4 .v4-face.is-xl{width:var(--face-xl);height:var(--face-xl);font-family:var(--font-d);font-size:var(--t-2xl);font-weight:400;margin-left:0}

/* ══════════════════════════════════════════════════════════════════════════
   THE THOUGHT — the atomic unit of the community
   One reader, one line, in the display face. Everything else on a book page
   is arrangement around these.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-thought{padding:var(--s4) 0;border-bottom:1px solid var(--line)}
/* 4.5.2 — in the Commons stream a post is three siblings: the thought, its
   replies, and the reply control. The rule above draws the separator under the
   FIRST of them, so Reply appeared below the line and read as the opening of
   the next post. The line belongs to the whole post, so it moves to a wrapper
   and comes off the thought inside one. */
.v4 .v4-post{border-bottom:1px solid var(--line);padding-bottom:var(--s3)}
.v4 .v4-post>.v4-thought{border-bottom:none}
/* 4.5.3 — a reply belongs to the post above it, so it should sit closer to it
   than to the next post. Three paddings were stacking to about 36px: the
   thought's own bottom padding, the reply block's top margin, and the first
   nested thought's top padding. Pulled in only INSIDE a post — the thought
   keeps its normal rhythm everywhere else. */
.v4 .v4-post>.v4-thought{padding-bottom:var(--s1)}
.v4 .v4-post>.v4-replies>.v4-thought:first-child{padding-top:var(--s1)}
/* 4.5.4 — the reply BOX, which 4.5.3 missed. .v4-replies is the nested comment
   column and only exists once somebody has answered; <details class="v4-reply">
   is the Reply control itself and is on every post. Tightening only the first
   left the common case — a post nobody has replied to yet — carrying the box's
   own --s2 margin on top of the thought's padding. The margin BELOW it stays:
   the control should sit against the post it belongs to and away from the rule
   that closes it. */
/* 4.5.12 — the rules above were written when a post was three siblings and
   the Reply control was the last of them. It now sits inside .v4-acts, so
   .v4-post>.v4-reply matches nothing and the margin-bottom it carried is
   replaced by padding on .v4-post itself. The replies column now follows the
   acts row rather than the thought, so it needs the wider gap back: pulling it
   to --s1 was right when it sat under a sentence and wrong under a row of
   controls. */
.v4 .v4-post>.v4-replies{margin-top:var(--s3)}
.v4 .v4-thought:last-child{border-bottom:none}
.v4 .v4-thought-who{display:flex;align-items:center;gap:var(--s2);margin-bottom:var(--s2);flex-wrap:wrap}
/* v4.1.0 — the name carries. On a site whose premise is who else here has read
   this, the reader was quieter than their own sentence. */
.v4 .v4-thought-who b{font-size:var(--t-sm);font-weight:var(--w-name);letter-spacing:-.005em}
/* v4.3.0 — the poll. It sits directly under the dark week bar and belongs to
   it, so it takes the same width and a matching top edge. */
.v4 .v4-poll{background:var(--surface);border:1px solid var(--line);
  border-top:0;border-radius:0 0 var(--rad-lg) var(--rad-lg);
  padding:var(--s4);margin-top:calc(var(--rad-lg) * -1);padding-top:var(--s5)}
.v4 .v4-poll-res{position:relative;padding:var(--s3);margin-bottom:var(--s2);
  border-radius:var(--rad-sm);overflow:hidden;background:var(--bg)}
.v4 .v4-poll-res.is-mine{box-shadow:inset 0 0 0 1.5px var(--green)}
/* The bar is behind the text, not beside it: a row that is both the label and
   the measurement reads faster than a label with a chart next to it. */
.v4 .v4-poll-bar{position:absolute;inset:0 auto 0 0;background:var(--green-tint);
  transition:width .3s ease}
.v4 .v4-poll-row{position:relative;display:flex;align-items:baseline;
  justify-content:space-between;gap:var(--s3)}
.v4 .v4-poll-label{font-size:var(--t-sm);font-weight:var(--w-name);color:var(--text)}
.v4 .v4-poll-n{font-family:var(--font-m);font-size:var(--t-sm);color:var(--green);
  font-weight:600;flex-shrink:0}
.v4 .v4-poll-who{position:relative;display:flex;align-items:center;gap:var(--s1);
  margin-top:var(--s2)}
.v4 .v4-poll-who .v4-face{margin-left:0;border:2px solid var(--bg)}
.v4 .v4-poll-who .v4-face+.v4-face{margin-left:-8px}
.v4 .v4-poll-form{margin-top:var(--s3)}
.v4 .v4-poll-opt{display:flex;align-items:center;gap:var(--s3);padding:var(--s3);
  margin-bottom:var(--s2);border:1.5px solid var(--line2);border-radius:var(--rad-sm);
  cursor:pointer;font-size:var(--t-sm);background:var(--bg)}
.v4 .v4-poll-opt:hover{border-color:var(--green)}
.v4 .v4-poll-opt.is-mine{border-color:var(--green);background:var(--green-tint)}
.v4 .v4-poll-opt input{flex-shrink:0;accent-color:var(--green);width:18px;height:18px}
.v4 .v4-poll-form textarea{width:100%;box-sizing:border-box;margin-top:var(--s2);
  border:1px solid var(--line2);border-radius:var(--rad-sm);background:var(--bg);
  padding:var(--s2) var(--s3);font-family:var(--font-b);font-size:var(--t-md);
  color:var(--text);resize:vertical;line-height:var(--lh-snug)}
.v4 .v4-poll-form textarea:focus{outline:none;border-color:var(--green);
  box-shadow:0 0 0 3px var(--green-tint)}
.v4 .v4-poll-form button{margin-top:var(--s2)}

/* v4.2.0 — replies under a thought. Indented and quieter than the thought
   itself: a reply is a response to something, and should read as subordinate to
   the line it answers rather than as another verdict. */
.v4 .v4-replies{margin-top:var(--s3);padding-left:var(--s4);
  border-left:2px solid var(--line)}
/* 4.5.1 — scoped to div. .v4-reply names TWO different elements: the comment
   row here, and the <details> that ui_reply_box wraps its form in. Unscoped,
   display:flex turned that <details> into a flex container and stood the
   summary beside the form, squeezing the box to content width — the reason the
   Commons reply area and the book-page thread boxes have never been full width.
   The <details> rules further down already target it on their own. */
.v4 div.v4-reply{display:flex;gap:var(--s3);align-items:flex-start;padding:var(--s3) 0}
.v4 div.v4-reply+div.v4-reply{border-top:1px solid var(--line)}
.v4 div.v4-reply .v4-face{margin-left:0;border:none;flex-shrink:0}
.v4 .v4-reply-who{font-size:var(--t-sm);font-weight:var(--w-name);color:var(--text)}
.v4 div.v4-reply p{margin:var(--s1) 0 0;font-size:var(--t-sm);line-height:var(--lh-snug);
  color:var(--text2);overflow-wrap:anywhere}
.v4 .v4-reply-cue{display:inline-block;margin-top:var(--s2);font-family:var(--font-m);
  font-size:var(--t-2xs);letter-spacing:.08em;text-transform:uppercase;
  color:var(--green);text-decoration:none;cursor:pointer}
.v4 .v4-reply-cue:hover{text-decoration:underline}
.v4 .v4-replyform>summary{list-style:none;display:block}
.v4 .v4-replyform>summary::-webkit-details-marker{display:none}
.v4 .v4-replyform[open]>summary{display:none}
.v4 .v4-replyform textarea{width:100%;box-sizing:border-box;margin-top:var(--s2);
  border:1px solid var(--line2);border-radius:var(--rad-sm);background:var(--bg);
  padding:var(--s2) var(--s3);font-family:var(--font-b);font-size:var(--t-md);
  color:var(--text);resize:vertical;line-height:var(--lh-snug)}
.v4 .v4-replyform textarea:focus{outline:none;border-color:var(--green);
  box-shadow:0 0 0 3px var(--green-tint)}
.v4 .v4-replyform button{margin-top:var(--s2)}

/* v4.1.1 — plain, not italic. 4.1.0 made italic mean "a person's own words",
   which is right for one line and wrong for six: a full review set in italic at
   18px is tiring, and reviews here run long. The voice is carried by the
   display face, the size and the colour instead. */
/* v4.6.3 — stated rather than inherited. This text had been rendering at 300
   because Fraunces 400 upright was never loaded; once it was, every review
   and every Commons post got heavier overnight. 300 is the weight the page
   was designed against, so 300 is what it asks for now. */
.v4 .v4-thought q{font-weight:var(--w-display);display:block;quotes:none;font-family:var(--font-d);font-style:normal;font-size:var(--t-lg);line-height:var(--lh-snug);color:var(--text);overflow-wrap:anywhere}
.v4 .v4-thought.is-plain q{font-family:var(--font-b);font-style:normal;font-size:var(--t-base);line-height:var(--lh-body)}
.v4 .v4-thought.is-plain q em{font-style:normal;font-weight:var(--w-name);color:var(--text)}
.v4 .v4-thought.is-author{background:var(--green-tint);border-radius:var(--rad);border-bottom:none;padding:var(--s4)}
.v4 .v4-thought-act{margin-top:var(--s2);display:flex;gap:var(--s4);flex-wrap:wrap;font-size:var(--t-sm);color:var(--text3)}

/* ══════════════════════════════════════════════════════════════════════════
   BOOK CARD — one component, three variants.
   v3 calls book_card() once per page and then renders covers inline 29 more
   times across eight files. Every v4 cover goes through here.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-cover{display:block;width:100%;aspect-ratio:2/3;border-radius:var(--rad-sm);background:linear-gradient(160deg,var(--green),var(--green-h));box-shadow:var(--e1);overflow:hidden;position:relative}
.v4 .v4-cover img{width:100%;height:100%;object-fit:cover;display:block}
.v4 .v4-cover-fallback{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;text-align:center;padding:var(--s3);color:var(--bg2);font-family:var(--font-d);font-size:var(--t-sm);line-height:var(--lh-tight)}

/* The card wrapper itself. Carried no rule at all until alpha.19 — the grid gap
   positioned the cards and nothing needed it, but a class with no rule is a
   class nobody can safely change. min-width:0 is the load-bearing part: without
   it a long unbroken title makes the card refuse to shrink below its content
   and pushes the whole grid track wide. */
.v4 .v4-bc{min-width:0}
/* beta.9 — the guest hero. Text left, three covers right. The covers are the
   first thing that proves the claim beside them, so they get real size; below
   900 they drop away entirely rather than shrinking to stamps, because on a
   phone the search bar should be reachable without scrolling past decoration. */
.v4 .v4-hero{display:grid;grid-template-columns:minmax(0,1fr) auto;
  gap:var(--s6);align-items:center}
.v4 .v4-hero-say{min-width:0}
/* At 42px even 500 reads heavy; the hero carries its emphasis by size alone. */
.v4 .v4-hero-say .v4-h1{font-weight:450}
.v4 .v4-hero-fan{display:flex;align-items:flex-start;flex-shrink:0;
  padding-right:var(--s4)}
.v4 .v4-hero-fan-i{display:block;width:112px;flex-shrink:0;text-decoration:none;
  transition:transform .18s ease}
.v4 .v4-hero-fan-i:nth-child(1){transform:rotate(-6deg)}
.v4 .v4-hero-fan-i:nth-child(2){margin-left:-22px;z-index:2;transform:translateY(-10px)}
.v4 .v4-hero-fan-i:nth-child(3){margin-left:-22px;transform:rotate(6deg)}
.v4 .v4-hero-fan-i:hover{transform:translateY(-14px) rotate(0)}
.v4 .v4-hero-fan .v4-cover{box-shadow:var(--e2,0 8px 24px rgba(0,0,0,.16))}

/* beta.9 — who someone follows, as a face and a name. Not a face alone: at this
   scale several members share a first name and some have no photo, so a bare
   avatar row is a guessing game. */
/* v4.0.5 — the author spotlight portrait. A round 44px face is how you show
   somebody in a list; this panel introduces a writer at length and was showing
   them smaller than the covers below it. */
.v4 .v4-spot{display:grid;grid-template-columns:132px minmax(0,1fr);gap:var(--s5);
  align-items:start}
.v4 .v4-spot-face{display:block;aspect-ratio:3/4;overflow:hidden;
  border-radius:var(--rad-sm);background:var(--surface2)}
.v4 .v4-spot-face img{width:100%;height:100%;object-fit:cover;display:block}
.v4 .v4-spot-initials{display:flex;width:100%;height:100%;align-items:center;
  justify-content:center;font-family:var(--font-m);font-size:var(--t-2xl);
  color:var(--text4)}

/* v4.0.5 — the featured strip. Scroll-snap, not a carousel: v4 has shipped
   almost no JavaScript and this is the last place worth starting. Swipes on a
   phone, scrolls with a trackpad, and degrades to a plain row where scroll-snap
   is unsupported. */
.v4 .v4-bstrip{display:grid;grid-auto-flow:column;grid-auto-columns:132px;
  gap:var(--s4);overflow-x:auto;scroll-snap-type:x mandatory;
  padding-bottom:var(--s3);scrollbar-width:thin;overscroll-behavior-x:contain}
.v4 .v4-bstrip > *{scroll-snap-align:start}
.v4 .v4-bstrip::-webkit-scrollbar{height:6px}
.v4 .v4-bstrip::-webkit-scrollbar-thumb{background:var(--line2);border-radius:3px}

/* v4.0.6 — the strip says it scrolls. A peeking half-card was the only cue and
   a mouse user has no gesture that would discover it.
   The fade is decorative and pointer-events:none so it never eats a click on
   the card beneath it. */
.v4 .v4-striproll{position:relative}
.v4 .v4-striproll::after{content:'';position:absolute;top:0;right:0;bottom:var(--s3);
  width:56px;pointer-events:none;opacity:.9;
  background:linear-gradient(90deg,transparent,var(--bg))}
.v4 .v4-striproll.is-end::after{opacity:0}
.v4 .v4-strip-nav{display:flex;gap:var(--s2);margin-left:auto}
.v4 .v4-strip-head{display:flex;align-items:center;gap:var(--s3)}
.v4 .v4-strip-btn{width:30px;height:30px;flex-shrink:0;display:none;
  align-items:center;justify-content:center;padding:0;border-radius:var(--rad-full);
  border:1.5px solid var(--line2);background:var(--bg);color:var(--text2);
  font-size:var(--t-sm);line-height:1;cursor:pointer}
.v4 .v4-strip-btn:hover:not(:disabled){border-color:var(--green);color:var(--green)}
.v4 .v4-strip-btn:disabled{opacity:.3;cursor:default}
/* Shown only where a pointer exists. On a phone the gesture IS the affordance
   and two buttons would be clutter. */
@media (hover:hover) and (pointer:fine){
  .v4 .v4-strip-btn{display:inline-flex}
}

/* The two grid rows show 8; a phone shows 6. Done in CSS rather than by
   querying twice, so the server never has to guess a viewport it cannot see. */
.v4 .v4-brow{grid-template-columns:repeat(4,minmax(0,1fr))}

/* Collections: four across, and a way through to the rest. */
.v4 .v4-colls{grid-template-columns:repeat(4,minmax(0,1fr))}

/* v4.6.9 — the giveaway index, two across.
   .v4-give was drawn for the home page's 385px rail. Stacked full-width on
   /giveaway each card ran the whole measure, which left a full-width button
   under two short lines and a mostly empty row. Two columns give the card
   about the width it was designed for. Two rather than three or four: the
   prize is a real sentence, and there are rarely more than a few running.
   align-items:start so a card with a longer prize line does not stretch the
   one beside it into matching whitespace. */
.v4 .v4-gives{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));
  gap:var(--s5);align-items:start}

.v4 .v4-morelink{font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.08em;
  text-transform:uppercase;color:var(--green);text-decoration:none}
.v4 .v4-morelink:hover{text-decoration:underline}

/* v4.0.4 — the author bio disclosure. The summary carries the opening while
   closed and is replaced by the full text when open, so no state of this
   element can ever render as an empty "Show more". */
.v4 .v4-bio{display:block}
.v4 .v4-bio>summary{cursor:pointer;list-style:none;display:block}
.v4 .v4-bio>summary::-webkit-details-marker{display:none}
.v4 .v4-bio[open]>summary{display:none}
.v4 .v4-bio-cue{display:inline-block;margin-top:var(--s2);font-size:var(--t-sm);
  color:var(--green-h)}
.v4 .v4-bio>summary:hover .v4-bio-cue{text-decoration:underline}

/* Where else a writer is. */
.v4 .v4-alinks{display:flex;flex-wrap:wrap;gap:var(--s2) var(--s4);margin-top:var(--s3)}
.v4 .v4-alinks a{font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.06em;
  text-transform:uppercase;color:var(--text3);text-decoration:none;
  border-bottom:1px solid var(--line2)}
.v4 .v4-alinks a:hover{color:var(--green);border-bottom-color:var(--green)}

/* Titles and bylines are links now; they inherit rather than turning green so a
   grid of cards does not read as a wall of hyperlinks. */
.v4 .v4-bc-title a,.v4 .v4-bc-author a{color:inherit;text-decoration:none}
.v4 .v4-bc-title a:hover{color:var(--green)}
.v4 .v4-bc-author a:hover{color:var(--green);text-decoration:underline}

/* The pick of the month, with its cover. */
.v4 .v4-pick{display:grid;grid-template-columns:82px minmax(0,1fr);gap:var(--s4);
  align-items:start}
.v4 .v4-pick-cover{display:block}
.v4 .v4-pick-say{min-width:0}
.v4 .v4-pick-say .v4-h2 a{color:inherit;text-decoration:none}
.v4 .v4-pick-say .v4-h2 a:hover{color:var(--green)}

/* Curated collections: four covers fanned, a name, a count. */
/* v4.0.6 — the column count moved to the single rule above. This one used to
   repeat grid-template-columns and, being LATER in the file at equal
   specificity, silently won: minmax(210px) in a 615px main column resolves to
   two columns, which is what the laptop was showing. Layout properties only
   from here on. */
.v4 .v4-colls{display:grid;gap:var(--s5)}
.v4 .v4-coll{display:block;text-decoration:none;color:inherit}
.v4 .v4-coll-fan{display:flex;margin-bottom:var(--s3)}
/* v4.0.6 — sized to the track. Four columns of a 615px main column give 136px
   each; the old fan measured 52 + 38x3 = 166px and would have overflowed even
   once the column count was fixed. 44 - 16 x3 = 128px fits with room. */
.v4 .v4-coll-fan .v4-cover{width:44px;flex-shrink:0;box-shadow:0 2px 8px rgba(0,0,0,.12)}
.v4 .v4-coll-fan .v4-cover+.v4-cover{margin-left:-16px}
.v4 .v4-coll-name{display:block;font-family:var(--font-d);font-size:var(--t-lg);
  font-weight:400;line-height:var(--lh-tight);margin-bottom:2px}
.v4 .v4-coll:hover .v4-coll-name{color:var(--green)}

/* v4.8.1 — the same collection card, laid out for the 385px rail: a row
   instead of a stack. Scoped under .v4-coll-rail on purpose. /lists renders
   .v4-coll three times over and must not move, so every declaration here is
   one level deeper than the base rule (0,3,0 against 0,2,0) and cannot reach
   it. Four covers at 34 with a 13 overlap measure 34 + 21x3 = 97px, which
   leaves the name a comfortable ~230px of the rail. */
.v4 .v4-coll-rail{display:flex;flex-direction:column;gap:var(--s4)}
.v4 .v4-coll-rail .v4-coll{display:grid;grid-template-columns:auto minmax(0,1fr);
  gap:var(--s3);align-items:center}
.v4 .v4-coll-rail .v4-coll-fan{margin-bottom:0}
.v4 .v4-coll-rail .v4-coll-fan .v4-cover{width:34px}
.v4 .v4-coll-rail .v4-coll-fan .v4-cover+.v4-cover{margin-left:-13px}
.v4 .v4-coll-rail .v4-coll-say{min-width:0}
.v4 .v4-coll-rail .v4-coll-name{font-size:var(--t-base);margin-bottom:1px}

/* v4.0.3 — the giveaway card. The image leads: a giveaway is the one panel on
   the home page whose job is to be looked at rather than read. Full-bleed to
   the panel edge, which is why the panel's own padding is cancelled here. */
.v4 .v4-give{margin:calc(var(--s4) * -1)}
.v4 .v4-give-img{display:block;overflow:hidden;background:var(--surface2)}
.v4 .v4-give-img img{width:100%;height:100%;object-fit:cover;display:block;
  transition:transform .4s ease}
.v4 .v4-give-img:hover img{transform:scale(1.03)}
.v4 .v4-give-say{padding:var(--s4)}

/* v4.0.5 — two shapes, because two different kinds of picture end up here.
   is-cover: the prize book's own cover, left, matching Reading together.
   is-plain (4.1.1): no picture at all. A promotional banner has no workable
   size in a 385px rail, so the decorated header announces the giveaway and the
   poster stays on /giveaway where it has the width for it. */
/* v4.1.1 — the banner is gone entirely. There is no size at which a 16:9
   poster works in a 385px rail: cropped it lost its headline, uncropped it took
   a third of the column. A decorated header does the announcing instead, and
   the poster still does its job on /giveaway where it has the width for it.
   A prize BOOK cover is different and stays: it is portrait, and it is the
   thing being won. */
.v4 .v4-give-head{display:flex;align-items:center;gap:var(--s2);
  padding:var(--s3) var(--s4);margin:calc(var(--s4) * -1) calc(var(--s4) * -1) var(--s4);
  border-radius:var(--rad-lg) var(--rad-lg) 0 0;
  background:var(--green);color:var(--bg2);
  font-family:var(--font-m);font-size:var(--t-2xs);font-weight:600;
  letter-spacing:.14em;text-transform:uppercase}
.v4 .v4-give-head::before{content:'\25C6';letter-spacing:0;opacity:.7}
/* 4.5.2 — TWO negative margins were stacking. .v4-give already cancels the
   panel's padding for the plain shape, and the header then cancelled it a
   SECOND time, pushing itself a full --s4 past the panel edge on both sides.
   is-cover is unaffected: it resets .v4-give's margin to 0 and pads itself, so
   its header still needs the pull. Radius kept, or the corners square off. */
.v4 .v4-give:not(.is-cover) .v4-give-head{margin:0 0 var(--s4)}
.v4 .v4-give.is-cover .v4-give-head{margin:calc(var(--s4) * -1) calc(var(--s4) * -1) var(--s4);
  grid-column:1 / -1}
.v4 .v4-give.is-cover{display:grid;grid-template-columns:82px minmax(0,1fr);
  gap:var(--s4);padding:var(--s4);margin:0;align-items:start}
.v4 .v4-give.is-cover .v4-give-img{border-radius:var(--rad-sm);aspect-ratio:2/3}
.v4 .v4-give.is-cover .v4-give-say{padding:0;min-width:0}
.v4 .v4-give-say .v4-h2{line-height:var(--lh-tight)}

/* ── v4.7.0 — the Quote Wall ───────────────────────────────────────────────
   A wall, not a feed: columns rather than rows, because quotes are different
   lengths and a single column of ragged cards reads as a list of interruptions.
   Multi-column layout rather than grid, so a short quote does not leave a
   tall gap beside a long one — the browser packs them.
   (Careful: this file is a nowdoc. A line starting with optional whitespace
   then the terminator word ends the block early, so no comment line here may
   begin with it. That is a silent, confusing parse error.)

   break-inside:avoid is what keeps a card from being sawn in half across a
   column boundary; without it the wall looks broken at exactly the moment a
   quote runs long, which is the moment it is most worth reading. */
.v4 .v4-quotes{columns:2;column-gap:var(--s5)}
.v4 .v4-quote{break-inside:avoid;-webkit-column-break-inside:avoid;page-break-inside:avoid;
  display:block;margin:0 0 var(--s5);padding:var(--s5);background:var(--surface);
  border:1px solid var(--line);border-radius:var(--rad-lg)}
.v4 .v4-quote.is-verified{border-color:var(--green-ring)}
.v4 .v4-quote-badge{display:inline-block;font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.08em;text-transform:uppercase;color:var(--green);margin-bottom:var(--s3)}

/* The line itself carries the page. Fraunces, stated weight rather than
   inherited — see the 4.6.3 note on .v4-thought q: an unset weight walks to
   whatever the variable font has loaded and the quote comes out thin. */
.v4 .v4-quote-t{margin:0 0 var(--s3);font-family:var(--font-d);font-weight:var(--w-display);
  font-size:var(--t-lg);line-height:var(--lh-snug);color:var(--text);cursor:pointer}
.v4 .v4-quote-t:hover{color:var(--green-h)}
.v4 .v4-quote-t:focus-visible{outline:2px solid var(--green);outline-offset:4px;border-radius:2px}

.v4 .v4-quote-book{display:flex;gap:var(--s3);align-items:center;text-decoration:none;
  color:inherit;padding-top:var(--s3);border-top:1px solid var(--line)}
.v4 .v4-quote-book .v4-cover{width:34px;flex:none}
.v4 .v4-quote-bt{display:block;min-width:0}
.v4 .v4-quote-bt b{display:block;font-size:var(--t-sm);font-weight:var(--w-title)}
.v4 .v4-quote-book:hover .v4-quote-bt b{color:var(--green-h)}

.v4 .v4-quote-acts{display:flex;gap:var(--s3);align-items:center;flex-wrap:wrap;
  margin-top:var(--s3)}
.v4 .v4-quote-acts > .v4-meta:first-child{margin-right:auto}

/* One shape that fills in when saved, so the state change is the same object
   changing rather than two unrelated pictures (v3.29.0). */
.v4 .v4-quote-save{display:inline-flex;align-items:center;gap:var(--s1);background:none;
  border:0;padding:var(--s1);cursor:pointer;color:var(--text4);font-family:var(--font-m);
  font-size:var(--t-2xs);line-height:1}
.v4 .v4-quote-save svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.6}
.v4 .v4-quote-save:hover{color:var(--green-h)}
.v4 .v4-quote-save.saved{color:var(--green)}
.v4 .v4-quote-save.saved svg{fill:currentColor;stroke:currentColor}
.v4 .v4-quote-n[hidden]{display:none}

.v4 .v4-quote-tool{background:none;border:0;padding:var(--s1);cursor:pointer;
  color:var(--text4);font-family:var(--font-m);font-size:var(--t-2xs);line-height:1}
.v4 .v4-quote-tool:hover{color:var(--green-h)}

/* Reach without redrawing: the 4.6.3 lesson. min-height would fatten these
   controls; an invisible band under them only grows what a thumb can hit. */
.v4 .v4-quote-save,.v4 .v4-quote-tool{position:relative}
.v4 .v4-quote-save::before,.v4 .v4-quote-tool::before{content:'';position:absolute;
  left:50%;top:50%;transform:translate(-50%,-50%);width:44px;height:44px}

/* ── v4.7.1 — the eight states ─────────────────────────────────────────────
   Four across, like the collections grid it sits closest to in kind: a small
   set of fixed, named things you pick one of. Each card carries its own line
   of writing, so these are taller than a collection card and the covers sit
   at the foot rather than leading. */
.v4 .v4-states{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--s4)}
.v4 .v4-state{display:block;text-decoration:none;color:inherit;padding:var(--s4);
  background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg)}
.v4 .v4-state:hover{border-color:var(--green)}
.v4 .v4-state-n{display:block;font-family:var(--font-d);font-size:var(--t-lg);
  line-height:var(--lh-tight);margin-bottom:2px}
.v4 .v4-state:hover .v4-state-n{color:var(--green-h)}
.v4 .v4-state-d{display:block;margin-top:var(--s2);font-size:var(--t-sm);
  color:var(--text3);line-height:var(--lh-body)}
.v4 .v4-state-fan{display:flex;margin-top:var(--s3)}
.v4 .v4-state-fan .v4-cover{width:30px;flex-shrink:0;box-shadow:0 2px 8px rgba(0,0,0,.12)}
.v4 .v4-state-fan .v4-cover+.v4-cover{margin-left:-10px}

/* ── v4.7.2 — bookshops ────────────────────────────────────────────────────
   Three across: a shop card is a logo, a name, a place and a line, which needs
   more width than a book cover and less than a collection. The mark is the
   stand-in when a shop has no logo — two letters on a hue derived from the
   name, so a shop keeps its colour between the list and its own page. */
.v4 .v4-shops{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--s4)}
.v4 .v4-shop{display:flex;gap:var(--s3);align-items:flex-start;text-decoration:none;color:inherit;
  padding:var(--s4);background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg)}
.v4 .v4-shop:hover{border-color:var(--green)}
.v4 .v4-shop-b{display:block;min-width:0}
.v4 .v4-shop-b b{display:block;font-size:var(--t-md);line-height:var(--lh-tight)}
.v4 .v4-shop:hover .v4-shop-b b{color:var(--green-h)}
.v4 .v4-shop-bio{display:block;margin:var(--s2) 0;font-size:var(--t-sm);color:var(--text3);
  line-height:var(--lh-body)}
.v4 .v4-shop-logo{width:48px;height:48px;flex:none;object-fit:contain;border-radius:var(--rad-sm);
  background:var(--surface2)}
.v4 .v4-shop-mark{width:48px;height:48px;flex:none;border-radius:var(--rad-sm);color:#fff;
  display:flex;align-items:center;justify-content:center;font-family:var(--font-d);
  font-size:var(--t-md);font-weight:var(--w-title);letter-spacing:.02em}
.v4 .v4-shop-hero{display:flex;gap:var(--s4);align-items:center;margin-top:var(--s4)}
.v4 .v4-shop-logo.is-big,.v4 .v4-shop-mark.is-big{width:76px;height:76px;font-size:var(--t-xl)}

/* ── v4.7.4 — blog ─────────────────────────────────────────────────────────
   A post in the list is a card with an optional lead image beside it. Two
   columns when there is an image, one when there is not, so a post without a
   cover does not sit in a column with a hole in it. */
.v4 .v4-post{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);
  padding:var(--s4)}
.v4 .v4-post.has-cover{display:grid;grid-template-columns:180px minmax(0,1fr);gap:var(--s4);
  align-items:start}
.v4 .v4-post-img{display:block;overflow:hidden;border-radius:var(--rad-sm);background:var(--surface2)}
.v4 .v4-post-img img{width:100%;height:100%;object-fit:cover;display:block;aspect-ratio:4/3}
.v4 .v4-post-b{min-width:0}

/* The article body is editor-written HTML, so it is styled by element rather
   than by class — there are no hooks to add to it. */
.v4 .v4-article{margin-top:var(--s5);max-width:var(--measure);font-size:var(--t-md);
  line-height:var(--lh-body);color:var(--text2)}
.v4 .v4-article > *{margin:0 0 var(--s4)}
.v4 .v4-article h2,.v4 .v4-article h3{font-family:var(--font-d);color:var(--text);
  line-height:var(--lh-snug);margin:var(--s6) 0 var(--s3)}
.v4 .v4-article h2{font-size:var(--t-xl)}
.v4 .v4-article h3{font-size:var(--t-lg)}
.v4 .v4-article img{max-width:100%;height:auto;border-radius:var(--rad-sm);display:block}
.v4 .v4-article blockquote{margin:var(--s5) 0;padding-left:var(--s4);
  border-left:2px solid var(--green);font-family:var(--font-d);font-size:var(--t-lg);
  line-height:var(--lh-snug);color:var(--text)}
.v4 .v4-article ul,.v4 .v4-article ol{padding-left:var(--s5)}
.v4 .v4-article li{margin-bottom:var(--s2)}
.v4 .v4-article a{color:var(--green-h)}
.v4 .v4-article code{font-family:var(--font-m);font-size:.92em;background:var(--surface2);
  padding:2px 5px;border-radius:var(--rad-sm)}
.v4 .v4-article pre{background:var(--surface2);padding:var(--s4);border-radius:var(--rad-sm);
  overflow-x:auto}
.v4 .v4-article hr{border:0;border-top:1px solid var(--line);margin:var(--s6) 0}

/* ── v4.7.6 — a page for reading ───────────────────────────────────────────
   The article page was a reading measure inside a full-width wrap, so the
   column sat hard against the left edge with half the screen empty. This
   centres the whole page — heading, body, attachments and comments — on one
   measure, which is what a page whose job is reading needs. */
.v4 .v4-read{max-width:var(--measure);margin-left:auto;margin-right:auto;
  padding-top:var(--s5);padding-bottom:var(--s8)}
.v4 .v4-read-lead{width:100%;height:auto;border-radius:var(--rad-lg);
  margin:var(--s5) 0 0;display:block}
.v4 .v4-read .v4-article{max-width:none}

/* What the piece is about: the book, the writer, or both. This used to sit in
   a sidebar BELOW the comments, which is the last place anybody looks. It
   belongs under the body and before the comments, and it shows the cover and
   the face rather than a bare name. */
.v4 .v4-attach{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--s4);
  margin-top:var(--s6)}
.v4 .v4-attach:has(> :only-child){grid-template-columns:minmax(0,1fr)}
.v4 .v4-attach-i{display:flex;gap:var(--s4);align-items:center;text-decoration:none;color:inherit;
  padding:var(--s4);background:var(--surface);border:1px solid var(--line);
  border-radius:var(--rad-lg)}
.v4 .v4-attach-i:hover{border-color:var(--green)}
.v4 .v4-attach-i .v4-cover{width:56px;flex:none}
.v4 .v4-attach-face{width:56px;height:56px;flex:none;border-radius:var(--rad-full);
  object-fit:cover;display:block}
.v4 .v4-attach-t{display:block;min-width:0}
.v4 .v4-attach-t b{display:block;font-size:var(--t-md);line-height:var(--lh-tight);
  margin:2px 0}
.v4 .v4-attach-i:hover .v4-attach-t b{color:var(--green-h)}

/* v4.7.7 — save a post. Sits beside the like in the same row, and reads as a
   different kind of thing on purpose: the heart is public approval, this is a
   private "come back to it". Same bookmark shape as the Quote Wall's save, so
   one glyph means one thing across the site. */
.v4 .v4-bm-f{display:inline;margin:0}
.v4 .v4-bm{display:inline-flex;align-items:center;gap:var(--s1);background:none;border:0;
  padding:var(--s1);cursor:pointer;color:var(--text4);font-family:var(--font-m);
  font-size:var(--t-2xs);letter-spacing:.08em;text-transform:uppercase;line-height:1;
  position:relative}
.v4 .v4-bm svg{width:15px;height:15px;fill:none;stroke:currentColor;stroke-width:1.6}
.v4 .v4-bm:hover{color:var(--green-h)}
.v4 .v4-bm.is-on{color:var(--green)}
.v4 .v4-bm.is-on svg{fill:currentColor}
/* Reach, not size — 4.6.3. */
.v4 .v4-bm::before{content:'';position:absolute;left:50%;top:50%;
  transform:translate(-50%,-50%);width:44px;height:44px}

/* v4.0.1 — the owner's tools on their own author page. */
.v4 .v4-owner-acts{display:flex;flex-direction:column;gap:var(--s2)}
.v4 .v4-field{display:block;margin-top:var(--s3)}
.v4 .v4-field > span{display:block;font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.08em;text-transform:uppercase;color:var(--text3);margin-bottom:var(--s1)}
/* v4.6.1 — these values used to differ from the .v4-field input rule ~700
   lines below: cream not white, --rad-sm not --rad, --s2 padding not --s3.
   Because [type=text] adds specificity, this block won for text inputs and
   lost for every other type, so one form showed two kinds of field. They are
   now identical, which means the cascade no longer decides anything. The
   selector list stays because select and input[type=file] are sized nowhere
   else. */
.v4 .v4-field input[type=text],.v4 .v4-field textarea,.v4 .v4-field select,
.v4 .v4-field input[type=file]{width:100%;box-sizing:border-box;
  border:1px solid var(--line2);border-radius:var(--rad);background:var(--surface);
  padding:var(--s3);font-family:var(--font-b);font-size:var(--t-md);color:var(--text)}
.v4 .v4-field textarea{resize:vertical;line-height:var(--lh-snug)}
.v4 .v4-field input:focus,.v4 .v4-field textarea:focus,.v4 .v4-field select:focus{
  outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}

/* The follower figures row on /author-dashboard/followers. */
.v4 .v4-figs{display:flex;gap:var(--s6);flex-wrap:wrap}
.v4 .v4-figs > div{display:flex;flex-direction:column;gap:2px}
.v4 .v4-figs span{font-family:var(--font-d);font-size:var(--t-2xl);color:var(--green);line-height:1}
.v4 .v4-figs em{font-style:normal;font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.1em;color:var(--text4)}

.v4 .v4-follow-list{display:flex;flex-wrap:wrap;gap:var(--s2) var(--s3);margin:0}
.v4 .v4-follow-i{display:inline-flex;align-items:center;gap:var(--s2);
  text-decoration:none;color:var(--text2);font-size:var(--t-sm);min-width:0}
.v4 .v4-follow-i .v4-face{margin-left:0;border:none}
.v4 .v4-follow-i:hover{color:var(--green)}
.v4 .v4-follow-i:hover .v4-face{box-shadow:0 0 0 2px var(--green)}

.v4 .v4-bc-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(120px,1fr));gap:var(--s4)}
/* beta.9 — 74px packed 7 covers across the wrap and none of them was legible.
   At 92px it fits 6 and the cover art starts doing its job. */
.v4 .v4-bc-grid.is-mini{grid-template-columns:repeat(auto-fill,minmax(92px,1fr));gap:var(--s3)}
/* v4.1.0 — the title leads. It was 13px/500 against an author at 12px/400:
   one pixel and one weight step apart, so a grid of cards read as an
   undifferentiated block of text. */
/* v4.1.1 — clamped. "Whispers from the Mist of Tripura Hills: True Hauntings
   and Supernatural Tales from Tripura" ran five lines next to "Arachnid" at
   one, so a row of cards sat at five different heights and read as a mess.
   Two lines for a title, one for an author, ellipsis after. The information
   stays; the raggedness does not. */
.v4 .v4-bc-title{font-size:var(--t-sm);font-weight:var(--w-name);line-height:var(--lh-snug);
  margin:var(--s2) 0 0;color:var(--text);overflow-wrap:anywhere;letter-spacing:-.005em;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.v4 .v4-bc-author{font-size:var(--t-xs);font-weight:var(--w-body);color:var(--text3);margin:3px 0 0;
  display:-webkit-box;-webkit-line-clamp:1;-webkit-box-orient:vertical;overflow:hidden}
/* The verified mark. Sized to the byline rather than the body so it reads as
   part of the name, and given a little optical lift because a check glyph sits
   low in most faces. */
/* 4.5.7 — renamed from .v4-verified to .v4-vmark. This rule and the pill rule
   further down both claimed .v4-verified, and the later one won for both, so
   the bare mark was inheriting a flex box and a gap it had no use for. */
.v4 .v4-vmark{display:inline-flex;align-items:center;margin-left:4px;
  vertical-align:-1px;line-height:0}
.v4 .v4-vmark .v4-vdisc{width:11px;height:11px}
/* The rating row on a card. Only rendered where the sample size earns it, so
   most cards have nothing here and the row costs nothing when absent. */
.v4 .v4-bc-rating{display:flex;align-items:center;gap:var(--s2);margin-top:4px}
/* beta.9 — 44px was narrower than the text beside it was tall, so the row read
   as a list with a stamp rather than as a book. 64px is still a row, not a card. */
.v4 .v4-bc-row-cover{width:64px;flex-shrink:0}

/* ══════════════════════════════════════════════════════════════════════════
   THE WEEK BAR — the host prompt that opens the Commons
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-week{background:var(--text);color:var(--bg2);border-radius:var(--rad-lg);padding:var(--s5)}
/* v4.6.2 — the dark panel keeps the original value. --text4 was darkened for
   the cream ground where it failed at 2.55:1; on this near-black panel that
   same original value is already 6.23:1, and darkening it here would take it
   to 3.39:1 and break the one place it worked. */
.v4 .v4-week .v4-meta{color:var(--text4-dark)}
.v4 .v4-week h2{font-family:var(--font-d);font-weight:var(--w-display);font-size:var(--t-2xl);line-height:var(--lh-tight);color:var(--bg);margin:var(--s2) 0 var(--s3)}
.v4 .v4-week p{margin:0 0 var(--s4);color:#C8CFC2;font-size:var(--t-base);max-width:56ch}
/* beta.7 — .v4-btn-face is gone with the face it held: the author's photo moved
   to the byline, so nothing renders that class any more and leaving the rules
   behind would be dead CSS shadowing nothing.
   is-on outlived it and is still on the book page's Following link, so it is
   promoted here rather than dropped with its old parent. */
.v4 .v4-btn.is-on{border-color:var(--green);color:var(--green)}

/* beta.7 — online sellers, inside the Where to find it panel and under the
   indie shops. A top border only when there are stockists above to divide from,
   which is what :not(:first-child) is doing. */
.v4 .v4-sellers{margin-top:var(--s4)}
.v4 .v4-sellers:not(:first-child){border-top:1px solid var(--line);padding-top:var(--s4)}
.v4 .v4-sellers .v4-btn{margin-top:var(--s2)}

/* beta.7 — a checkbox row that also carries a link somewhere. The anchor is a
   sibling of the label, never a child: a link inside a label that toggles a
   checkbox is one click doing two things. */
.v4 .v4-check-wrap{display:flex;flex-direction:column;gap:var(--s2)}
.v4 .v4-check-link{align-self:flex-start;font-family:var(--font-m);
  font-size:var(--t-2xs);letter-spacing:.06em;text-transform:uppercase;
  color:var(--green);text-decoration:none;padding-left:calc(var(--s5) + var(--s2))}
.v4 .v4-check-link:hover{text-decoration:underline}

.v4 .v4-week-acts{display:flex;gap:var(--s2);flex-wrap:wrap;align-items:center}
/* "No answers yet" is a plain line, not a button — it sits on the dark week bar
   so it needs the light text the rest of that block uses. */
.v4 .v4-week-acts .v4-meta{color:var(--text4-dark)}
.v4 .v4-week .v4-btn{background:var(--bg2);color:var(--text)}
.v4 .v4-week .v4-btn.is-ghost{background:transparent;color:var(--bg2);border-color:var(--text3)}

/* ══════════════════════════════════════════════════════════════════════════
   THE DIGEST — not a stream.
   Follow bursts collapse to one line and quiet days are absorbed. A raw
   chronological feed at this volume renders eight near-identical follow rows
   and reads like a bot log.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-digest{border-left:2px solid var(--line);padding-left:var(--s5);margin-left:var(--s1)}
.v4 .v4-digest-item{position:relative;padding:var(--s3) 0}
.v4 .v4-digest-item::before{content:"";position:absolute;left:calc(-1 * var(--s5) - 5px);top:22px;width:9px;height:9px;border-radius:var(--rad-full);background:var(--line2)}
.v4 .v4-digest-item.is-hot::before{background:var(--rust)}
.v4 .v4-digest-item p{margin:var(--s1) 0 0;font-size:var(--t-base);color:var(--text2)}
.v4 .v4-digest-item p b{font-weight:500;color:var(--text)}
/* A notification inside the digest. The whole message is the link, and the
   timestamp sits under it rather than beside it so a long message does not
   squeeze the time into a column of its own. */
.v4 .v4-notif-link{color:var(--text2);text-decoration:none}
.v4 .v4-notif-link:hover{color:var(--green);text-decoration:underline}
.v4 .v4-notif-when{display:block;margin-top:2px;font-family:var(--font-m);
  font-size:var(--t-2xs);letter-spacing:.06em;text-transform:uppercase;color:var(--text3)}

/* ==========================================================================
   LIVE SEARCH
   A real form around a real input: with the script blocked it submits to
   /search and still works. The dropdown is the only enhancement.
   ========================================================================== */
.v4 .v4-search{position:relative;display:flex;gap:var(--s2);margin-top:var(--s5)}
.v4 .v4-search input[type=search]{flex:1;min-width:0;padding:var(--s3) var(--s4);
  border:1px solid var(--line2);border-radius:var(--rad);background:var(--surface);
  font-family:var(--font-b);font-size:var(--t-md);color:var(--text)}
.v4 .v4-search input[type=search]:focus{outline:none;border-color:var(--green);
  box-shadow:0 0 0 3px var(--green-tint)}
.v4 .v4-search-results{display:none;position:absolute;left:0;right:0;top:calc(100% + 6px);z-index:40;
  background:var(--surface);border:1px solid var(--line2);border-radius:var(--rad);
  box-shadow:0 8px 28px rgba(0,0,0,.12);overflow:hidden;max-height:60vh;overflow-y:auto}
.v4 .v4-search-results.is-open{display:block}
/* beta.7 — a thumbnail beside each hit. The row becomes a two-column flex
   (thumb, text stack) rather than a single text column. A 2:3 cover and a round
   face both occupy the same 30px box, so mixed lists stay aligned. */
.v4 .v4-search-img{width:30px;height:45px;flex-shrink:0;object-fit:cover;
  border-radius:var(--rad-sm,4px);background:var(--surface2)}
.v4 .v4-search-img.is-round{height:30px;border-radius:var(--rad-full);
  margin-top:7px;margin-bottom:8px}
.v4 .v4-search-img.is-empty{display:flex;align-items:center;justify-content:center;
  font-family:var(--font-m);font-size:var(--t-2xs);font-weight:700;color:var(--text4)}
.v4 .v4-search-txt{display:flex;flex-direction:column;gap:2px;min-width:0}
.v4 .v4-search-txt .v4-search-t,.v4 .v4-search-txt .v4-search-a{
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.v4 .v4-search-hit{display:flex;align-items:center;gap:var(--s3);padding:var(--s3) var(--s4);
  text-decoration:none;border-bottom:1px solid var(--line)}
.v4 .v4-search-hit:last-child{border-bottom:none}
.v4 .v4-search-hit:hover{background:var(--surface2)}
.v4 .v4-search-t{font-size:var(--t-sm);font-weight:500;color:var(--text)}
.v4 .v4-search-a{font-size:var(--t-xs);color:var(--text3)}
.v4 .v4-search-empty{padding:var(--s3) var(--s4);font-size:var(--t-sm);color:var(--text4)}

/* ==========================================================================
   BOOK HERO, DETAILS, LIGHTBOX
   ========================================================================== */
/* Four areas rather than a cover beside one tall column. Desktop keeps the
   arrangement it has always had — everything to the right of the cover — but
   expressing it as areas is what lets the phone reflow without touching the
   markup. align-content:start stops the three right-hand rows stretching to the
   height of the cover. */
.v4 .v4-book-hero{display:grid;grid-template-columns:168px minmax(0,1fr);
  grid-template-areas:"cover head" "cover acts";
  grid-template-rows:auto 1fr;
  gap:var(--s3) var(--s5);align-items:start;align-content:start}
.v4 .v4-bh-cover{grid-area:cover}
.v4 .v4-bh-head{grid-area:head;min-width:0}
/* beta.8 — .v4-bh-meta is gone: the award moved in beside the rating and the
   grid area it held would only ever have been empty.
   flex-wrap lets the sample line and the award chip drop under the stars in a
   narrow column rather than being squeezed onto one line. */
.v4 .v4-bh-rating{display:flex;align-items:center;gap:var(--s2) var(--s3);
  flex-wrap:wrap;margin-top:var(--s3)}
.v4 .v4-bh-acts{grid-area:acts;display:flex;gap:var(--s3);flex-wrap:wrap;
  align-items:center;margin-top:var(--s2)}
.v4 .v4-cover-link{display:block;text-decoration:none}
.v4 .v4-cover-link:hover .v4-cover{box-shadow:0 4px 18px rgba(0,0,0,.18)}

/* Show more, without script. The hidden tail is inside the paragraph so the
   text reflows as one block when opened, rather than appearing as a second
   detached paragraph. The summary sits after the content so it reads as a
   control beneath the text. */
.v4 .v4-more{display:block}
.v4 .v4-more .v4-more-rest{display:none}
.v4 .v4-more[open] .v4-more-rest{display:inline}
.v4 .v4-more>summary{cursor:pointer;list-style:none;margin-top:var(--s2);
  font-size:var(--t-sm);color:var(--green-h)}
.v4 .v4-more>summary::-webkit-details-marker{display:none}
.v4 .v4-more>summary:hover{text-decoration:underline}
.v4 .v4-more[open]>summary{visibility:hidden;height:0;margin:0}

.v4 .v4-detailwrap{border-top:1px solid var(--line);border-bottom:1px solid var(--line);padding:var(--s2) 0}
.v4 .v4-detailwrap>summary{cursor:pointer;list-style:none;display:flex;gap:var(--s3);align-items:baseline;
  flex-wrap:wrap;padding:var(--s2) 0}
.v4 .v4-detailwrap>summary::-webkit-details-marker{display:none}
.v4 .v4-detailwrap>summary::after{content:"+";margin-left:auto;color:var(--text4);font-family:var(--font-m)}
.v4 .v4-detailwrap[open]>summary::after{content:"\2212"}
.v4 .v4-detail-teaser{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1}
.v4 .v4-details{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));
  gap:0 var(--s5);margin-top:var(--s2)}
.v4 .v4-detail{display:flex;gap:var(--s3);padding:var(--s2) 0;border-bottom:1px solid var(--line);min-width:0}
.v4 .v4-detail dt{margin:0;flex:0 0 88px;font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.05em;text-transform:uppercase;color:var(--text4);padding-top:2px}
.v4 .v4-detail dd{margin:0;flex:1;min-width:0;font-size:var(--t-sm);color:var(--text2);overflow-wrap:anywhere}

/* Lightbox with no script. :target opens it, the whole overlay is the close
   link. Only rendered when there is a real image — a generated cover has
   nothing to enlarge. */
/* v4.9.1 — 400, was 200. The tab bar is 350, so an enlarged cover was a
   full-screen dark overlay with five lit tabs sitting on top of it, and the
   overlay is itself the close link, so the strip they occupied could not be
   tapped to dismiss it. Above the bar, the picture is the whole screen. */
.v4 .v4-lightbox{position:fixed;inset:0;display:none;align-items:center;justify-content:center;
  background:rgba(18,25,15,.88);z-index:400;padding:var(--s5)}
.v4 .v4-lightbox:target{display:flex}
.v4 .v4-lightbox img{max-width:min(92vw,520px);max-height:90vh;border-radius:var(--rad);
  box-shadow:0 10px 50px rgba(0,0,0,.5)}

/* ==========================================================================
   FIGURES — the only numbers on a profile
   Points, streaks and rank are deliberately absent. These three are counts of
   things a person did, not a score they earned.
   ========================================================================== */
.v4 .v4-figures{display:flex;gap:var(--s5);flex-wrap:wrap}
.v4 .v4-figures div{min-width:0}
.v4 .v4-figures span{display:block;font-family:var(--font-d);font-size:var(--t-2xl);line-height:1.1;color:var(--text)}
.v4 .v4-figures em{font-style:normal;font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.06em;color:var(--text4)}

/* ==========================================================================
   RATINGS AND AWARDS
   Stars are a bookstore idiom, so they are small, muted, and never appear
   without a name attached. Awards are editorial signal and carry more weight
   here than any score does — a win is amber, everything else is quiet.
   ========================================================================== */
/* Two layers: grey stars beneath, amber clipped to a percentage above. This is
   what makes a half star possible — reviews.rating is 1-10, so 7 is three and a
   half, and rounding it to whole stars loses the thing the scale exists for. */
/* Stars are inline SVG, sized in px and filled by class. They were text glyphs
   clipped by percentage until alpha.16; the geometry now comes from the path,
   so a half star is exactly half regardless of what font is available.
   An svg with no width and no fill expands to its container and paints black,
   which is what happened when the markup changed and these rules did not. */
.v4 .v4-stars{display:inline-block;vertical-align:-2px;width:66px;height:13px;flex-shrink:0}
/* beta.4 — the book hero passes 'lg'. 130px is a visible step up from 110 at
   the top of a page without competing with the h1 beside it. */
.v4 .v4-stars.is-lg{width:130px;height:26px;vertical-align:-5px}
.v4 .v4-star-off{fill:var(--star-off)}
.v4 .v4-star-on{fill:var(--star)}

/* The picker. Ten invisible half-width labels laid over one SVG star strip.
   The previous version clipped a text glyph to .5em per half, which assumes a
   star character is exactly one em wide. It is not, and it varies by fallback
   font — that is what produced ragged halves and an apparent sixth star.
   Geometry now comes from the SVG, and fill is driven by which radio is checked
   through sibling selectors, so there is still no script. */
.v4 .v4-rate{position:relative;display:inline-block;line-height:0}
.v4 .v4-rate input{position:absolute;opacity:0;width:0;height:0}
.v4 .v4-rate-stars{position:relative;display:inline-block;height:22px}
.v4 .v4-rate-stars .v4-stars{width:110px;height:22px;display:block}
.v4 .v4-rate-stars .v4-star-off{fill:var(--line2)}
.v4 .v4-rate-stars .v4-star-on{fill:var(--star);opacity:0}
.v4 .v4-rate-half{position:absolute;top:0;height:100%;width:11px;cursor:pointer;z-index:2}
.v4 .v4-rate-half:nth-of-type(1){left:0px}
.v4 .v4-rate-half:nth-of-type(2){left:11px}
.v4 .v4-rate-half:nth-of-type(3){left:22px}
.v4 .v4-rate-half:nth-of-type(4){left:33px}
.v4 .v4-rate-half:nth-of-type(5){left:44px}
.v4 .v4-rate-half:nth-of-type(6){left:55px}
.v4 .v4-rate-half:nth-of-type(7){left:66px}
.v4 .v4-rate-half:nth-of-type(8){left:77px}
.v4 .v4-rate-half:nth-of-type(9){left:88px}
.v4 .v4-rate-half:nth-of-type(10){left:99px}
.v4 .v4-sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.v4 .v4-rate input#v4r1:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 90% 0 0)}
.v4 .v4-rate input#v4r2:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 80% 0 0)}
.v4 .v4-rate input#v4r3:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 70% 0 0)}
.v4 .v4-rate input#v4r4:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 60% 0 0)}
.v4 .v4-rate input#v4r5:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 50% 0 0)}
.v4 .v4-rate input#v4r6:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 40% 0 0)}
.v4 .v4-rate input#v4r7:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 30% 0 0)}
.v4 .v4-rate input#v4r8:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 20% 0 0)}
.v4 .v4-rate input#v4r9:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 10% 0 0)}
.v4 .v4-rate input#v4r10:checked ~ .v4-rate-stars .v4-star-on{opacity:1;clip-path:inset(0 0% 0 0)}
.v4 .v4-rate input:focus-visible ~ .v4-rate-stars{outline:2px solid var(--green);outline-offset:3px}

.v4 .v4-award{display:flex;gap:var(--s2);align-items:baseline;padding:var(--s2) 0;border-bottom:1px solid var(--line)}
.v4 .v4-award:last-child{border-bottom:none}
.v4 .v4-award-res{font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.06em;
  color:var(--text4);white-space:nowrap;flex-shrink:0;min-width:74px}
.v4 .v4-award.is-win .v4-award-res{color:var(--amber);font-weight:500}
.v4 .v4-award-name{font-size:var(--t-sm);color:var(--text2);line-height:var(--lh-snug);min-width:0}
.v4 .v4-award-name i{font-style:normal;color:var(--text4)}
.v4 .v4-award-strip{display:inline-flex;align-items:center;gap:var(--s2);padding:var(--s1) var(--s3);
  border-radius:var(--rad-full);background:rgba(122,92,30,.10);color:var(--amber);
  font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.06em}

/* ══════════════════════════════════════════════════════════════════════════
   COMPOSE — saying something in a room, not filling in a form

   Collapsed it is one line that sits in the same rhythm as a thought: avatar,
   then text. It opens on focus-within, which is pure CSS and needs no script.
   Native selects are the least designed element available, so the options are
   radio pills that reuse the tag shape already on the page.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-compose{border:1px solid var(--line);border-radius:var(--rad-lg);background:var(--surface);
  padding:var(--s3) var(--s4);transition:border-color .18s ease,box-shadow .18s ease}
.v4 .v4-compose:focus-within{border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.v4 .v4-compose-head{display:flex;gap:var(--s3);align-items:flex-start}
/* 4.5.1 — width:100% added. flex:1 sizes this only inside .v4-compose-head;
   as a direct child of .v4-compose it was inert and the textarea fell back to
   its default cols. Harmless in the flex case, where flex-basis:0% wins. */
.v4 .v4-compose textarea{flex:1;min-width:0;width:100%;box-sizing:border-box;
  border:none;background:transparent;resize:none;
  padding:var(--s2) 0;font-family:var(--font-b);font-size:var(--t-md);line-height:var(--lh-snug);
  color:var(--text);height:40px;transition:height .18s ease}
.v4 .v4-compose textarea::placeholder{color:var(--text4)}
.v4 .v4-compose textarea:focus{outline:none}
.v4 .v4-compose:focus-within textarea{height:104px}

/* The controls stay out of the way until there is something to control. */
.v4 .v4-compose-foot{max-height:0;opacity:0;overflow:hidden;margin-top:0;
  transition:max-height .2s ease,opacity .2s ease,margin-top .2s ease}
.v4 .v4-compose:focus-within .v4-compose-foot{max-height:260px;opacity:1;margin-top:var(--s3)}
.v4 .v4-compose-bar{display:flex;gap:var(--s2);align-items:center;flex-wrap:wrap}
.v4 .v4-compose-bar .v4-btn{margin-left:auto}

.v4 .v4-pills{display:flex;gap:var(--s2);flex-wrap:wrap;align-items:center}
/* An author row. A writer is a person, so the row leads with a face rather than
   a cover, and the whole row is the link. */
.v4 .v4-arow{display:grid;grid-template-columns:auto minmax(0,1fr);gap:var(--s4);
  align-items:center;padding:var(--s4) 0;text-decoration:none;color:inherit;
  border-top:1px solid var(--line)}
.v4 .v4-arow:hover .v4-bc-title{color:var(--green)}
.v4 .v4-arow-now{display:block;margin-top:4px;font-size:var(--t-xs);color:var(--text2)}
.v4 .v4-arow-now em{font-style:normal}
/* Columns, because production has 128 writers and one column of them is a very
   long page. auto-fill against a 300px minimum gives three columns on a wide
   desktop, two on a laptop or landscape tablet, one on a phone — without a
   media query, and without a fixed count that would strand a single card in a
   row of three. The border-top on every row rather than on siblings is what
   makes the columns line up: a sibling selector would skip whichever row
   happens to start each column. */
.v4 .v4-arow-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));
  column-gap:var(--s6)}
/* A filter row: label at the side, controls beside it. Three stacked
   eyebrow-over-chips groups read as six rows of equal weight with nothing
   saying which label owns which chips; pulling the label out makes the
   grouping structural. Collapses to stacked below 760. */
/* v4.10.0 — the poll compose box and the in-post poll.

   .v4-pollbox is a <details>: opening it IS choosing to make a poll, so there
   is no radio to keep in sync with a reveal and nothing to fail if script or
   :has() is unavailable. The server reads the same fact — two or more filled
   answers — so the control and the payload cannot disagree.

   .v4-poll.is-inpost drops the card chrome: inside a post it is part of the
   post, not a second panel sitting on one. */
.v4 .v4-pollbox{margin-top:var(--s3)}
.v4 .v4-pollbox>summary{list-style:none;display:inline-block;cursor:pointer}
.v4 .v4-pollbox>summary::-webkit-details-marker{display:none}
.v4 .v4-polloptions{display:grid;gap:var(--s2);margin-bottom:var(--s2)}
/* v4.11.0 — .v4-reportbox. Same disclosure shape as .v4-pollbox above and for
   the same reason: the reason select has to live somewhere, and a <details>
   needs no script and no query parameter. Sits in the .v4-acts row beside Like
   and Reply, so it borrows their rhythm rather than announcing itself — a
   report control that catches the eye invites reports nobody meant to file. */
.v4 .v4-reportbox{display:inline-block}
.v4 .v4-reportbox>summary{list-style:none;display:inline-block;cursor:pointer}
.v4 .v4-reportbox>summary::-webkit-details-marker{display:none}
.v4 .v4-reportbox[open]{display:block;width:100%;margin-top:var(--s2)}
.v4 .v4-reportbox form{display:grid;gap:var(--s2);margin-top:var(--s2);max-width:320px}
/* v4.10.1 — the collapsed change-your-answer control, and the read-only
   option rows a signed-out reader sees. .is-static borrows the option row's
   shape but has no input: it shows WHAT is on offer without pretending to be
   something you can pick. */
.v4 .v4-poll-change{margin-top:var(--s3)}
.v4 .v4-poll-change>summary{list-style:none;display:inline-block;cursor:pointer}
.v4 .v4-poll-change>summary::-webkit-details-marker{display:none}
.v4 .v4-poll-opt.is-static{cursor:default;opacity:.85}
.v4 .v4-poll-dot{width:14px;height:14px;border-radius:50%;border:1.5px solid var(--line2);
  flex:none;display:inline-block}
.v4 .v4-poll.is-inpost{background:none;border:0;border-left:2px solid var(--line);
  border-radius:0;padding:var(--s1) 0 var(--s1) var(--s3);margin:var(--s3) 0 0}

/* v4.9.6 — facets that share a line. The label sits beside its own chips
   rather than above them, and the groups wrap as units, so "Show" never ends
   up on one line with "Sort"'s chips underneath it. */
.v4 .v4-facetrow{display:flex;flex-wrap:wrap;gap:var(--s3) var(--s6);
  align-items:center;padding:var(--s3) 0}
.v4 .v4-facetgrp{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap}
.v4 .v4-facetgrp .v4-facet-label{padding-top:0}
.v4 .v4-facet{display:grid;grid-template-columns:64px minmax(0,1fr);gap:var(--s3);
  align-items:start;padding:var(--s3) 0}
/* v4.10.5 — the filter block on /books. Not a .v4-panel: a border, a fill and a
   radius all announce a separate object, and this is a row of controls attached
   to the list under it. */
.v4 .v4-filters{margin-top:var(--s4)}
.v4 .v4-morefilters>summary{list-style:none;display:block;cursor:pointer;padding:var(--s2) 0}
.v4 .v4-morefilters>summary::-webkit-details-marker{display:none}
.v4 .v4-morefilters[open]>summary{padding-bottom:0}
.v4 .v4-facet + .v4-facet{border-top:1px solid var(--line)}
.v4 .v4-facet-label{font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.08em;
  text-transform:uppercase;color:var(--text3);padding-top:7px}
/* The bar between the filters and the grid: count on the left, order on the
   right. Separating narrowing from arranging, and giving the grid room to
   start — it previously butted straight up against the last chip row. */
.v4 .v4-listbar{display:flex;align-items:center;justify-content:space-between;
  gap:var(--s3);flex-wrap:wrap;margin:var(--s5) 0 var(--s5)}

/* A chip is a pill that submits. Same shape as the radio pills so the shelf
   control and the compose options read as one family. */
/* v4.10.5 — 13px, and tighter. The chips are a filter, not body copy, and on a
   phone eight state names at 14px pushed the first book cover 823px down the
   page. The control itself shrinks; the reach does not -- the ::before band
   below stays 44px, which is exactly what the 4.6.3 pattern is for. */
.v4 .v4-chip{font-family:var(--font-b);font-size:13px;padding:3px 10px;
  border-radius:var(--rad-full);border:1px solid var(--line2);color:var(--text3);
  background:transparent;cursor:pointer;white-space:nowrap;transition:all .14s}
/* v4.10.5 — the count beside a chip label. It was inline opacity:.6 in five
   places, which on cream resolves to 2.40:1 -- under the 4.5 AA floor, and it
   had been that way at full size too. NO opacity below 1 passes against this
   text colour, so the hierarchy is carried by SIZE instead, and the colour is
   inherited so the selected chip's white count stays white. Same lesson as
   --text4 in 4.10.2: de-emphasise by size, never by transparency. */
.v4 .v4-chip-n{font-size:11px;color:inherit;opacity:1;margin-left:1px}
.v4 .v4-chip:hover{border-color:var(--green);color:var(--green-h)}
.v4 .v4-chip.is-on{background:var(--green);border-color:var(--green);color:#fff;font-weight:500}
.v4 .v4-pill{position:relative;display:inline-flex}
.v4 .v4-pill input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.v4 .v4-pill span{display:inline-block;font-family:var(--font-b);font-size:var(--t-sm);
  padding:var(--s1) var(--s3);border-radius:var(--rad-full);border:1px solid var(--line2);
  color:var(--text3);background:transparent;white-space:nowrap}
.v4 .v4-pill input:checked + span{background:var(--green-tint);border-color:var(--green);
  color:var(--green-h);font-weight:500}
.v4 .v4-pill input:focus-visible + span{outline:2px solid var(--green);outline-offset:2px}

/* Only surfaces when the host actually switches to asking a question.
   :has() is unsupported on very old browsers, where the hint simply stays
   hidden — the control still works. */
.v4 .v4-reply{margin-top:var(--s2)}
.v4 .v4-reply>summary{cursor:pointer;font-size:var(--t-sm);color:var(--green-h);list-style:none;
  display:inline-block;padding:var(--s1) 0}
.v4 .v4-reply>summary::-webkit-details-marker{display:none}
.v4 .v4-reply>summary:hover{text-decoration:underline}
.v4 .v4-reply[open]>summary{color:var(--text4)}
.v4 .v4-replies{margin:var(--s3) 0 0 var(--s4);padding-left:var(--s4);border-left:2px solid var(--line)}
.v4 .v4-replies .v4-thought{padding:var(--s2) 0}

/* v4.4.0 — the acts row under a thought: like, comment, and edit when it is
   yours. Sits outside .v4-replies, so it is flush with the thought rather than
   inside the indented comment column. Wraps rather than overflowing on a narrow
   phone, and an open form is forced onto a full line of its own so it never
   shares one with the heart. */
/* 4.5.2 — EQUAL HEIGHTS, not centred guesses. Signed out, the like and the cue
   are both direct children of this row and line up; signed in, the like is a
   <button> in a <form> and the cue is a <span> in a <summary> in a <details>,
   so the two flex items are boxes of different heights built from different
   line-heights and padding. align-items:center then centres two unequal boxes,
   which is close but never exact. Giving every item and every wrapper the SAME
   fixed height removes the variance instead of compensating for it. */
.v4 .v4-acts{display:flex;flex-wrap:wrap;align-items:center;gap:var(--s4);
  margin-top:var(--s2);--act-h:20px}
.v4 .v4-acts>form{margin:0;display:flex;align-items:center;height:var(--act-h)}
.v4 .v4-acts>details>summary{display:flex;align-items:center;height:var(--act-h)}
.v4 .v4-acts>details[open]>summary{height:auto}
/* 4.5.1 — the cue gets the SAME box as the like button. align-items:center
   centres boxes, not text, so two items with different line-heights and
   padding sit on different baselines however they are aligned. */
.v4 .v4-acts .v4-reply-cue{margin-top:0;display:inline-flex;align-items:center;
  height:var(--act-h);line-height:var(--act-h);padding:0}
.v4 .v4-acts>details[open]{flex:1 1 100%}
/* 4.5.12 — the Commons reply control joins this row. .v4-reply carries its own
   margin-top and its summary its own font-size and padding, all set for when it
   stood alone under a post. Inside the row those are exactly the unequal boxes
   that align-items:center cannot fix, so they are removed rather than
   compensated for. The label inside is a .v4-reply-cue, which the rule above
   has already given the shared height. */
/* 4.5.13 — the tools <details> too, which 4.5.12 missed. .v4-tools carries
   margin-top:--s2 for when it hangs under a thought on its own, and in a row
   aligned on centre an 8px top margin lowers the item by four. That is the
   whole of the misalignment: EDIT was on the line, just not on the same one.
   BOTH classes have to be named. .v4-tools is declared 450 lines below this
   block, so .v4-acts>* at equal specificity would lose on source order — the
   reason this is written as two explicit selectors rather than one tidy one. */
.v4 .v4-acts>.v4-reply,
.v4 .v4-acts>.v4-tools{margin-top:0}
.v4 .v4-acts>.v4-reply>summary{padding:0;font-size:var(--t-2xs)}
.v4 .v4-acts>.v4-reply[open]>summary{height:var(--act-h)}
/* 4.5.12 — the folded answer box. Same idiom as .v4-tools: a cue that gets out
   of the way once the box it opens is open. */
.v4 .v4-answer{margin-top:var(--s2)}
.v4 .v4-answer>summary{list-style:none;display:block;cursor:pointer}
.v4 .v4-answer>summary::-webkit-details-marker{display:none}
.v4 .v4-answer[open]>summary{display:none}
.v4 .v4-like{display:inline-flex;align-items:center;gap:5px;background:none;border:none;
  padding:0;height:var(--act-h,20px);cursor:pointer;font-family:var(--font-m);
  font-size:var(--t-xs);letter-spacing:.04em;color:var(--text3);line-height:var(--act-h,20px)}
.v4 .v4-like:hover{color:var(--rust)}
.v4 .v4-like.is-on{color:var(--rust)}
.v4 .v4-like.is-static{cursor:default}
.v4 .v4-like svg{display:block;flex-shrink:0}
/* 4.5.0 — the word, matching .v4-reply-cue exactly so LIKE and 1 COMMENT read
   as one row of controls rather than an icon next to some text. */
.v4 .v4-like-t{font-size:var(--t-2xs);letter-spacing:.08em;text-transform:uppercase}

/* 4.5.1 — a quote that links to itself. Inherits the quote's own type rather
   than turning the line green: it is still the line, not a link with a line in
   it. The affordance is the underline on hover. */
/* 4.5.2 — the cover beside a book-scoped post, and the face beside a digest
   line. .v4-face carries margin-left:-9px and a ring because it is built for
   overlapping stacks; both are reset wherever it stands alone. */
.v4 .v4-postbook{display:inline-flex;align-items:center;gap:var(--s2)}
.v4 .v4-postbook img{width:20px;height:29px;object-fit:cover;border-radius:2px;
  display:block;flex-shrink:0}
/* 4.5.4 — the face and the sentence are a flex row, centred on each other.
   .v4-face carries margin-left:-9px and a 2px ring because it is built for
   overlapping stacks; both are reset here, where it stands alone. */
.v4 .v4-digest-line{display:flex;align-items:center;gap:var(--s2);margin-top:var(--s1)}
.v4 .v4-digest-line>p{margin:0}
.v4 .v4-digest-line .v4-face{margin-left:0;border:none}
/* BOOK 3 — a stockist is a shop, so it gets a shop's mark. At one or two rows
   this is a face on a name, not a grid of logos. The initials fall back tinted,
   the same pattern the partner directory already uses at 54px. */
.v4 .v4-shopmark{width:28px;height:28px;border-radius:6px;flex-shrink:0;
  overflow:hidden;border:1px solid var(--line);background:var(--bg);
  display:inline-flex;align-items:center;justify-content:center;
  font-family:var(--font-m);font-size:var(--t-2xs);font-weight:600;color:#fff}
.v4 .v4-shopmark img{width:100%;height:100%;object-fit:cover;display:block}
.v4 .v4-shoprow{display:flex;align-items:center;gap:var(--s3)}
.v4 .v4-quote-link{color:inherit;text-decoration:none}
.v4 .v4-quote-link:hover{text-decoration:underline;text-underline-offset:3px}
.v4 .v4-editform>summary{list-style:none;display:block;cursor:pointer}
.v4 .v4-editform>summary::-webkit-details-marker{display:none}
.v4 .v4-editform[open]>summary{display:none}

/* 4.5.0 — the control that starts a conversation about a book. */
.v4 .v4-discuss{margin-top:var(--s3);padding-top:var(--s3);border-top:1px solid var(--line)}
/* v4.10.3 — first thing in the card, so there is nothing for the rule above to
   separate it from. A divider with nothing on one side of it reads as a broken
   component, which is what an empty book page has looked like since 4.5.0. */
.v4 .v4-discuss.is-first{margin-top:0;padding-top:0;border-top:0}
.v4 .v4-ask{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap}
.v4 .v4-ask-t{flex:1 1 180px;font-family:var(--font-b);font-size:var(--t-sm);
  color:var(--text3);line-height:1.45}
.v4 .v4-discuss>summary{list-style:none;display:block;cursor:pointer}
.v4 .v4-discuss>summary::-webkit-details-marker{display:none}
.v4 .v4-discuss[open]>summary{display:none}
.v4 .v4-discuss-foot{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap;
  margin-top:var(--s2)}
.v4 .v4-hint{font-size:var(--t-xs);color:var(--text3)}

/* 4.5.0 — Share. Sits with the other things a reader does, and keeps the
   quieter weight: it is an offer, not the primary action on the page. */
.v4 .v4-share{display:inline-flex;align-items:center;gap:var(--s2);cursor:pointer;
  background:none;border:1px solid var(--line);border-radius:999px;
  padding:var(--s2) var(--s3);font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.08em;text-transform:uppercase;color:var(--text2);line-height:1}
.v4 .v4-share:hover{border-color:var(--green);color:var(--green-h)}
.v4 .v4-share.is-done{border-color:var(--green);color:var(--green-h)}
.v4 .v4-share svg{flex-shrink:0}

/* 4.5.0 — the sticky bar. Phone only: on a laptop the hero controls have never
   left the screen, so there is nothing to bring back. */
.v4 .v4-bookbar{display:none}
.v4 .v4-bookbar-space{display:none}
/* v4.9.1 — the section strip. Links that look like tabs; see ui_segments().
   Scrollable sideways rather than wrapping, so a third item never drops to a
   second line and shifts the page under a thumb.

   v4.9.4 — and it is PHONE ONLY, hidden by default and revealed below 900px.
   This strip is the tab bar's second level: it exists because Discover and
   Commons are single tabs that stand for three pages and two. Above 900px
   there is no tab bar, and the top navigation already lists Books, Authors,
   Lists, Community and the Quote Wall as siblings of each other — so on a
   laptop the strip was a second, smaller copy of a row already on screen.

   900px is not a number chosen for this rule. It is the tab bar's breakpoint,
   in CSS.php, and the two must stay equal: a strip that appeared at a width
   where the bar did not would be a sub-navigation for a navigation that is
   not there. They live in different files, so a guard checks they match —
   the same drift that put the giveaway swap at 1000px while the columns
   stacked at 760. */
.v4 .v4-segs{display:none;gap:var(--s5);align-items:flex-end;
  border-bottom:1px solid var(--line);margin:0 0 var(--s5);
  overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch}
@media (max-width:900px){
  .v4 .v4-segs{display:flex}
}
.v4 .v4-segs::-webkit-scrollbar{display:none}
.v4 .v4-seg{display:block;flex:none;padding:0 0 var(--s2);
  font-family:var(--font-b);font-size:var(--t-base);font-weight:500;
  color:var(--text3);text-decoration:none;white-space:nowrap;
  border-bottom:2px solid transparent;margin-bottom:-1px;transition:color .15s}
.v4 .v4-seg:hover{color:var(--text)}
.v4 .v4-seg.is-on{color:var(--text);font-weight:600;border-bottom-color:var(--green)}
.v4 .v4-seg:focus-visible{outline:2px solid var(--green);outline-offset:3px;border-radius:3px}

/* v4.9.2 — the giveaway, in the main column on a phone and in the rail on a
   desktop. One render in HomeV4.php, echoed into two slots; these two rules
   are the whole mechanism that keeps exactly one of them on screen.

   This replaces 4.9.0's .is-lead-rail, which hoisted the entire <aside> — all
   seven panels — above the main column, and did it at 1000px when the columns
   themselves do not stack until 760px, so it also collapsed the tablet
   layout. Both rules are gone; do not reintroduce an order: -1 on the rail.

   The swap width is the same 760px the grid collapses at, deliberately: above
   it there is a rail for the panel to sit in, below it there is not. */
.v4 .v4-give-m{display:none}
@media (max-width:760px){
  .v4 .v4-give-m{display:block}
  .v4 .v4-give-d{display:none}
}
/* v4.10.6 — Browse by state, same swap and the same 760px, for the same reason.
   The rail is the right home for it on a desktop; below 760px the rail stacks
   AFTER the main column, so a straight move would push the section further from
   the reader on the screen most of them use. One render, two slots, one visible. */
.v4 .v4-states-m{display:none}
@media (max-width:760px){
  .v4 .v4-states-m{display:block}
  .v4 .v4-states-d{display:none}
}

/* v4.9.5 — the pager. Was inline styles inside books_v4_pager(); it is a
   class now because a second page uses it. space-between with an empty
   <span> holding each end means "Next" stays on the right when there is no
   "Previous" to balance it, rather than sliding to the middle. */
.v4 .v4-pager{margin-top:var(--s6);display:flex;gap:var(--s3);align-items:center;
  justify-content:space-between;flex-wrap:wrap}

/* v4.9.5 — your questions. Composed from what already exists — .v4-panel,
   .v4-chip, .v4-tag, .v4-prose — so these five rules are only the parts that
   have no component: the card head, the reply block, and the foot. */
.v4 .v4-qhead{display:flex;align-items:center;gap:var(--s3);flex-wrap:wrap}
.v4 .v4-ansbox{background:var(--green-tint);border:1px solid var(--green-ring);
  border-radius:var(--rad);padding:var(--s3);margin:0 0 var(--s3)}
.v4 .v4-qfoot{display:flex;align-items:center;justify-content:space-between;
  gap:var(--s3);flex-wrap:wrap;margin-top:var(--s3);
  border-top:1px solid var(--line);padding-top:var(--s3)}
.v4 .v4-qedit>summary{list-style:none;display:inline-block;cursor:pointer}
.v4 .v4-qedit>summary::-webkit-details-marker{display:none}
/* A destructive action that is a link, not a button: it must not look like
   the one beside it that only navigates. */
.v4 .v4-linkbtn{background:none;border:0;padding:0;cursor:pointer;
  font-family:var(--font-b);font-size:var(--t-sm);color:var(--text4);
  text-decoration:underline;text-underline-offset:2px}
.v4 .v4-linkbtn:hover{color:var(--err,#9C3F2A)}

@media (max-width:760px){
  /* v4.9.1 — ABOVE the tab bar, not under it. Both were fixed at bottom:0
     and the tab bar's z-index of 350 beat this one's 60, so from 4.9.0 until
     now "Track this book" was painted over completely — the control existed,
     was focusable, and could not be seen. The offset reads --nr-tabh, set
     alongside the bar itself in the stylesheet that draws it, so the two
     cannot drift — they already did once, by 4px, inside one release.
     (And no line of this comment may begin with the nowdoc terminator: an
     earlier one started with the word C-S-S and silently closed the block.) */
  .v4 .v4-bookbar{display:flex;align-items:center;gap:var(--s3);
    position:fixed;left:0;right:0;z-index:60;
    bottom:calc(var(--nr-tabh,60px) + env(safe-area-inset-bottom,0px));
    /* Out of the way while the hero's own status pills are still on screen —
       see book_v4_bookbar_js(). Transform rather than display, so the spacer
       below never changes height and the page cannot jump. */
    transition:transform .18s ease;
    padding:var(--s2) var(--s3);background:var(--bg);
    border-top:1px solid var(--line);box-shadow:0 -2px 14px rgba(0,0,0,.07)}
  .v4 .v4-bookbar-book{display:flex;align-items:center;gap:var(--s2);
    min-width:0;flex:1 1 auto}
  .v4 .v4-bookbar-cover{width:28px;height:40px;object-fit:cover;border-radius:2px;
    flex-shrink:0}
  .v4 .v4-bookbar-title{font-size:var(--t-sm);font-weight:var(--w-name);color:var(--text);
    overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
  .v4 .v4-bookbar-menu{flex-shrink:0}
  .v4 .v4-bookbar-menu>summary{list-style:none;display:block;cursor:pointer}
  .v4 .v4-bookbar-menu>summary::-webkit-details-marker{display:none}
  .v4 .v4-bookbar-btn{display:inline-block;background:var(--green);color:#fff;
    border-radius:999px;padding:var(--s2) var(--s3);font-size:var(--t-sm);
    font-weight:var(--w-name);white-space:nowrap}
  /* The panel opens UPWARD, because there is nothing below it to open into. */
  .v4 .v4-bookbar-panel{position:absolute;left:var(--s3);right:var(--s3);
    bottom:calc(100% + var(--s2));background:var(--bg);border:1px solid var(--line);
    border-radius:12px;padding:var(--s3);box-shadow:0 6px 24px rgba(0,0,0,.14)}
  .v4 .v4-bookbar-menu[open]>summary .v4-bookbar-btn{background:var(--green-h)}
  /* Clearance. NOT padding on the wrapper: .v4-wrap carries an inline
     padding-bottom, which no stylesheet rule can beat. A spacer element is
     the only thing that reliably keeps the footer out from under the bar. */
  .v4 .v4-bookbar-space{display:block;height:76px}
  /* Slides down behind the tab bar. 200% clears its own height and the bar
     beneath it whatever the inset turns out to be. */
  .v4 .v4-bookbar.is-away{transform:translateY(200%);pointer-events:none}
  @media (prefers-reduced-motion:reduce){
    .v4 .v4-bookbar{transition:none}
  }
}

.v4 .v4-compose-hint{display:none;margin:var(--s3) 0 0;font-size:var(--t-xs);color:var(--text3)}
.v4 .v4-compose:has(input[value="prompt"]:checked) .v4-compose-hint{display:block}

/* ══════════════════════════════════════════════════════════════════════════
   ONBOARDING (alpha.26)

   Classes are v4ob-* rather than ob-*, because v3 declares .ob-* globally in
   the v3 stylesheet and those rules would otherwise bleed in. Element ids are
   shared with v3 deliberately — only one of the two pages renders per request,
   so they cannot collide, and keeping them is what let the behaviour layer be
   ported without edits.
   ══════════════════════════════════════════════════════════════════════════ */

/* Only the active step is in the document flow. The script toggles v4ob-active. */
.v4 .v4ob-step{display:none}
.v4 .v4ob-step.v4ob-active{display:block}

.v4 .v4ob-topbar{display:flex;align-items:center;justify-content:space-between;
  gap:var(--s4);margin-bottom:var(--s6)}
.v4 .v4ob-progress{display:flex;gap:var(--s2);align-items:center}
.v4 .v4ob-pdot{width:24px;height:3px;border-radius:2px;background:var(--line2);
  transition:background .2s}
.v4 .v4ob-pdot.v4ob-pdot-on{background:var(--green)}
.v4 .v4ob-skip,.v4 .v4ob-textbtn{background:none;border:none;padding:0;cursor:pointer;
  font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3);text-decoration:underline}
.v4 .v4ob-skip:hover,.v4 .v4ob-textbtn:hover{color:var(--green)}

/* Every step ends in the same place, so the primary action never moves. */
.v4 .v4ob-foot{display:flex;align-items:center;justify-content:space-between;
  gap:var(--s3);flex-wrap:wrap;margin-top:var(--s6)}

/* A pickable card. The tick is hidden until the script adds v4ob-picked, so the
   selected state is a single class change and cannot get out of sync. */
.v4 .v4ob-card{position:relative;display:flex;flex-direction:column;gap:var(--s1);
  padding:var(--s2);background:none;border:1.5px solid transparent;border-radius:var(--rad);
  cursor:pointer;text-align:left;font:inherit;color:inherit;transition:border-color .15s}
.v4 .v4ob-card:hover{border-color:var(--line2)}
.v4 .v4ob-card.v4ob-picked{border-color:var(--green);background:var(--green-tint)}
.v4 .v4ob-card-t{font-family:var(--font-d);font-size:var(--t-sm);color:var(--text);
  line-height:1.3;margin-top:var(--s1)}
.v4 .v4ob-card-a{font-size:var(--t-xs);color:var(--text3)}
.v4 .v4ob-tick{position:absolute;top:var(--s2);right:var(--s2);width:22px;height:22px;
  border-radius:var(--rad-full);background:var(--green);color:#fff;display:none;
  align-items:center;justify-content:center;font-size:12px;font-weight:700}
.v4 .v4ob-card.v4ob-picked .v4ob-tick{display:flex}

.v4 .v4ob-bookgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(120px,1fr));
  gap:var(--s3);margin-top:var(--s3)}
.v4 .v4ob-authorgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));
  gap:var(--s3);margin-top:var(--s3)}
.v4 .v4ob-acard{align-items:center;text-align:center}

/* Inputs inherit the 16px floor from the base rules; nothing here may lower it. */
.v4 .v4ob-input{width:100%;padding:var(--s3);border:1px solid var(--line2);
  border-radius:var(--rad);background:var(--surface);color:var(--text);
  font-family:var(--font-b);font-size:var(--t-md)}
.v4 .v4ob-searchwrap{position:relative}
.v4 .v4ob-drop{position:absolute;top:calc(100% + 4px);left:0;right:0;max-height:320px;
  overflow:auto;background:var(--surface);border:1px solid var(--line2);
  border-radius:var(--rad);box-shadow:var(--e2);z-index:20}
.v4 .v4ob-drop button{display:flex;gap:var(--s3);align-items:center;width:100%;
  padding:var(--s2) var(--s3);background:none;border:none;border-bottom:1px solid var(--line);
  text-align:left;cursor:pointer;color:var(--text);font:inherit}
.v4 .v4ob-drop button:hover{background:var(--surface2)}
.v4 .v4ob-author-drop-row{padding:var(--s2) var(--s3);cursor:pointer;
  border-bottom:1px solid var(--line);display:flex;justify-content:space-between;gap:var(--s3)}
.v4 .v4ob-author-drop-row:hover{background:var(--surface2)}
.v4 .v4ob-author-drop-name{font-family:var(--font-d);font-size:var(--t-sm);color:var(--text)}
.v4 .v4ob-author-drop-state{font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3)}

.v4 .v4ob-author-feedback{margin-top:var(--s3);padding:var(--s3);border-radius:var(--rad);
  font-size:var(--t-sm);border:1px solid var(--line2);background:var(--surface2);color:var(--text2)}
.v4 .v4ob-author-feedback-ok{border-color:var(--green);color:var(--green)}
.v4 .v4ob-author-feedback-err{border-color:var(--rust);color:var(--rust)}

.v4 .v4ob-formgrid{display:grid;gap:var(--s3)}
.v4 .v4ob-field{display:block}
.v4 .v4ob-field span{display:block;margin-bottom:var(--s1);
  font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3)}
.v4 .v4ob-submitown{margin-top:var(--s6);padding-top:var(--s4);border-top:1px solid var(--line)}
.v4 .v4ob-recap{list-style:none;padding:0;margin:var(--s4) 0;max-width:520px}
.v4 .v4ob-recap-row{padding:var(--s3) 0;border-bottom:1px solid var(--line);
  font-size:var(--t-base);color:var(--text2)}

/* ══════════════════════════════════════════════════════════════════════════
   THE SKIN LAYER (alpha.27)

   Twenty-two pages that have no v4 counterpart yet — quotes, lists, giveaway,
   partners, blog, states, circles, refer, stats and the rest — share one header
   pattern: a dark gradient banner with .ph-label / .ph-h1 / .ph-sub. That
   banner is the loudest v3 signal on the site, and with v4 as the default a
   reader crosses it constantly: light paper page, dark green slab, light paper
   page.

   Restyling it here reaches all twenty-two at once with no PHP change and no
   per-page risk. It does NOT make those pages v4 — their bodies are still v3
   layout — but it removes the jarring seam at the top of each, which is the
   part a reader notices first.

   Scoped to body.v4skin, which layout.php adds only when use_v4() is true. With
   the toggle off, every one of these rules is inert and v3 renders exactly as
   it always has.
   ══════════════════════════════════════════════════════════════════════════ */

/* The banner becomes a page opening rather than a slab.

   4.5.5 — AND IT IS CONTAINED. In v3 this was a full-bleed dark slab, so its
   40px padding was baked in and it never needed a wrapper; the skin removed the
   background and left it running to the viewport edge, while everything beneath
   it sat centred in a 1080px column. On a wide screen the title stood alone out
   at the left margin. Same max-width and same horizontal padding as
   `body.v4skin .wrap` and `.v4 .v4-wrap`, so a skinned page now lines up with a
   ported one to the pixel — box-sizing is border-box globally, so the padding
   is inside the max-width in all three.

   The rule under it is contained too, matching the hairline under the v4 shelf
   header rather than spanning the window.

   Roughly twenty pages ride on this component: Lists and its list pages, States
   and its state pages, Blog, Giveaway and its giveaway pages, the Partners
   directory, Contact, and a dozen more. */
body.v4skin .page-hero{background:none;max-width:1080px;margin:0 auto;
  padding:var(--s6) var(--s5) var(--s5);border-bottom:1px solid var(--line)}

/* The phone case is a SECOND misalignment, and a quieter one. v3 sets
   `.page-hero{padding:40px 16px 28px!important}` below 760, while
   `body.v4skin .wrap` overrides the wrap to 24px at every width — its
   specificity beats the media query's. So on a phone the header sat 8px inside
   the content it heads. !important is required to answer !important; between
   two important declarations the more specific selector wins, and this one is. */
@media (max-width:760px){
  body.v4skin .page-hero{padding:var(--s6) var(--s5) var(--s5)!important}
}
body.v4skin .page-hero::after{display:none}
body.v4skin .ph-label{font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.12em;text-transform:uppercase;color:var(--text3);margin-bottom:var(--s2)}
body.v4skin .ph-h1{font-family:var(--font-d);font-weight:400;
  font-size:var(--t-3xl);line-height:1.1;color:var(--text);margin-bottom:var(--s2)}
body.v4skin .ph-h1 em{font-style:italic;color:var(--text)}
body.v4skin .ph-sub{font-family:var(--font-b);font-size:var(--t-base);
  color:var(--text2);max-width:60ch}

/* The hero used to sit on a dark field, so buttons inside it were inverted.
   On paper they need the normal treatment back. */
body.v4skin .page-hero .btn-outline,
body.v4skin .page-hero .btn-ghost{color:var(--text2);border-color:var(--line2)}
body.v4skin .page-hero .btn-outline:hover,
body.v4skin .page-hero .btn-ghost:hover{color:var(--green);border-color:var(--green)}

/* v3 sections are 80px top and bottom, which reads as cavernous next to the v4
   rhythm. Bring them onto the same scale. */
body.v4skin .section{padding:var(--s7) 0}

/* The reading goal panel. One number against a target — no projection, no pace
   warning, no ranking. A goal is a commitment, not a score. */
.v4 .v4-goal-n{display:flex;align-items:baseline;gap:var(--s2)}
.v4 .v4-goal-n b{font-family:var(--font-d);font-size:var(--t-3xl);font-weight:400;
  line-height:1;color:var(--text)}
.v4 .v4-goal-n span{font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3)}
.v4 .v4-goal-bar{margin-top:var(--s3);height:4px;border-radius:2px;background:var(--line2);overflow:hidden}
.v4 .v4-goal-bar span{display:block;height:100%;background:var(--green);border-radius:2px}
.v4 .v4-goal-form{display:flex;gap:var(--s2);align-items:center}
.v4 .v4-goal-form input[type="number"]{width:80px;padding:var(--s2);border:1px solid var(--line2);
  border-radius:var(--rad);background:var(--surface);color:var(--text);font-size:var(--t-md)}

/* An author's note on their own book. Display face, because it is the author
   speaking rather than metadata about them. */
.v4 .v4-note + .v4-note{margin-top:var(--s4);padding-top:var(--s4);border-top:1px solid var(--line)}
.v4 .v4-note-t{display:block;margin-top:2px;font-family:var(--font-d);
  font-size:var(--t-lg);font-weight:400;color:var(--text)}

/* The profile edit panel. Fields inherit the 16px floor from the skin rules. */
.v4 .v4-edit summary{cursor:pointer;list-style:none;display:flex;gap:var(--s3);
  align-items:baseline;flex-wrap:wrap}
.v4 .v4-edit summary::-webkit-details-marker{display:none}
.v4 .v4-formgrid{display:grid;gap:var(--s4)}
.v4 .v4-field{display:block}
.v4 .v4-field > span:first-child{display:block;margin-bottom:var(--s1);
  font-family:var(--font-m);font-size:var(--t-xs);letter-spacing:.04em;
  text-transform:uppercase;color:var(--text3)}
.v4 .v4-field input,.v4 .v4-field textarea{width:100%;padding:var(--s3);
  border:1px solid var(--line2);border-radius:var(--rad);background:var(--surface);
  color:var(--text);font-family:var(--font-b);font-size:var(--t-md)}
/* v4.6.1 — an explicit floor rather than one inferred from padding and
   line-height. Applies to every v4 form, not only the two auth pages. */
.v4 .v4-field input{min-height:44px}
.v4 .v4-field .v4-meta{display:block;margin-top:var(--s1)}
.v4 .v4-edit-checks{display:grid;gap:var(--s3);margin-top:var(--s5);
  padding-top:var(--s4);border-top:1px solid var(--line)}
.v4 .v4-check{display:flex;gap:var(--s3);align-items:flex-start;cursor:pointer}
.v4 .v4-check input{margin-top:3px;width:18px;height:18px;accent-color:var(--green);flex:none}
.v4 .v4-check b{display:block;font-weight:500;font-size:var(--t-sm);color:var(--text)}
.v4 .v4-check .v4-meta{display:block;margin-top:2px;text-transform:none;letter-spacing:0}

/* Answer tools: two quiet links on one row, opening into the box only when
   asked. The closed state is what an author scrolling their own page sees. */
.v4 .v4-ans-tools{display:flex;gap:var(--s4);align-items:baseline;
  margin:var(--s2) 0 var(--s4) var(--s6);flex-wrap:wrap}
.v4 .v4-ans summary{cursor:pointer;list-style:none;font-family:var(--font-m);
  font-size:var(--t-xs);color:var(--green-h);padding:2px 0}
.v4 .v4-ans summary::-webkit-details-marker{display:none}
.v4 .v4-ans summary:hover{text-decoration:underline}
.v4 .v4-ans[open]{flex:1 1 100%}
.v4 .v4-ans[open] summary{margin-bottom:var(--s2)}
.v4 .v4-ans-del button{background:none;border:none;padding:0;cursor:pointer;
  font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3)}
.v4 .v4-ans-del button:hover{color:var(--err,#b3261e);text-decoration:underline}

/* The author answering. Indented and quieter than the ask form below it, so
   the page reads as: question, answer box, question, answer box — rather than
   a row of identical compose boxes. */
.v4 .v4-compose.is-answer{margin:0;border-color:var(--line)}
.v4 .v4-compose.is-answer textarea{font-size:var(--t-md)}

/* A clickable face and name. The hover state has to be visible without a
   colour change on the avatar itself, since many are photographs. */
.v4 .v4-face.is-link{cursor:pointer;text-decoration:none;transition:box-shadow .15s}
.v4 .v4-face.is-link:hover{box-shadow:0 0 0 2px var(--green)}
.v4 .v4-who-link{color:inherit;text-decoration:none}
.v4 .v4-who-link:hover{color:var(--green);text-decoration:underline}

/* ── shared primitives ────────────────────────────────────────────────────
   The five pages that matter most here — lists, quotes, giveaway, partners,
   blog — each carry their own bespoke class prefix, but they all sit on the
   same handful of shared primitives. Restyling those reaches every one of the
   twenty-two, not just the five.

   These are token swaps, not redesigns. Radius, weight, spacing and type come
   from the v4 scale; colour is untouched because the v3 palette was already
   disciplined and v4 inherited it wholesale. The page bodies keep their own
   layout — the brief was consistency, not a rewrite. */

body.v4skin .btn{border-radius:var(--rad);font-family:var(--font-b);
  font-size:var(--t-sm);font-weight:500;letter-spacing:0;padding:10px 18px}
body.v4skin .btn-sm{padding:6px 12px;font-size:var(--t-xs);border-radius:var(--rad-sm,6px)}
/* v3 primaries carry a coloured drop shadow, which is the single most dated
   thing on those pages next to a v4 button that has none. */
body.v4skin .btn-primary{box-shadow:none}
body.v4skin .btn-primary:hover{box-shadow:none;background:var(--green-h)}
body.v4skin .btn-outline,body.v4skin .btn-ghost{border-width:1px}

/* Form fields: same 16px floor as v4, same border weight, same radius. */
body.v4skin .fg label{font-family:var(--font-m);font-size:var(--t-xs);
  font-weight:400;color:var(--text3);letter-spacing:.04em;text-transform:uppercase}
body.v4skin .fg input,body.v4skin .fg textarea,body.v4skin .fg select{
  border-width:1px;border-radius:var(--rad);padding:var(--s3);
  font-size:var(--t-md);background:var(--surface)}

/* Content width. v3 wraps at 1200px, which throws prose lines twice as long as
   the v4 pages beside them. */
/* 1080 rather than v4-wrap's 900: these pages carry grids and tables that 900
   would crush, and the goal is a family resemblance, not an identical column. */
body.v4skin .wrap{max-width:1080px;padding-left:var(--s5);padding-right:var(--s5)}

/* The input floor is the one v4 rule that is a bug fix rather than a style, so
   it applies everywhere once the skin is on. Anything under 16px makes iOS
   Safari zoom the viewport and never restore it. */
body.v4skin input[type="text"],body.v4skin input[type="search"],
body.v4skin input[type="email"],body.v4skin input[type="password"],
body.v4skin input[type="number"],body.v4skin input[type="url"],
body.v4skin textarea,body.v4skin select{font-size:var(--t-md)}

/* ══════════════════════════════════════════════════════════════════════════
   BREAKPOINT 760 — the only structural one. Two columns become one.
   ══════════════════════════════════════════════════════════════════════════ */
@media (max-width:760px){
  .v4 .v4-cols{grid-template-columns:minmax(0,1fr);gap:var(--s5)}
  .v4 .v4-facet{grid-template-columns:minmax(0,1fr);gap:var(--s2)}
  .v4 .v4-facet-label{padding-top:0}
  /* The screenshot fix. The cover ran out after ~180px and left an empty
     gutter beside a 500px stack, while three status pills wrapped to three rows
     in a column too narrow for two. The cover now keeps only the title and
     byline company; the rating and the actions take the full width. */
  /* beta.9 — the fan goes rather than shrinks. On a phone the search bar
     should be reachable without scrolling past decoration. */
  /* v4.0.5 — six books on a phone, not eight: the last two are hidden rather
     than the row being queried twice server-side. */
  .v4 .v4-brow{grid-template-columns:repeat(3,minmax(0,1fr))}
  .v4 .v4-brow > *:nth-child(n+7){display:none}
  .v4 .v4-bstrip{grid-auto-columns:112px}
  .v4 .v4-spot{grid-template-columns:104px minmax(0,1fr);gap:var(--s4)}
  .v4 .v4-colls{grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--s4)}
  /* v4.6.9 — one giveaway across on a phone. Two would put the prize sentence
     in a column too narrow to read it in. */
  .v4 .v4-gives{grid-template-columns:minmax(0,1fr);gap:var(--s4)}
  /* v4.7.0 — the wall goes to one column on a phone. A quote set in two
     narrow columns breaks mid-clause on nearly every line. */
  .v4 .v4-quotes{columns:1}
  .v4 .v4-quote{padding:var(--s4);margin-bottom:var(--s4)}
  /* v4.7.1 — two states across on a phone, not four. */
  .v4 .v4-states{grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--s3)}
  .v4 .v4-state{padding:var(--s3)}
  /* v4.7.6 — one attachment across on a phone. */
  .v4 .v4-attach{grid-template-columns:minmax(0,1fr);gap:var(--s3)}
  /* v4.7.4 — a blog card stacks on a phone; 180px of image beside text is
     not a layout, it is two slivers. */
  .v4 .v4-post.has-cover{grid-template-columns:minmax(0,1fr);gap:var(--s3)}
  /* v4.7.2 — one shop across on a phone; the bio needs the width. */
  .v4 .v4-shops{grid-template-columns:minmax(0,1fr);gap:var(--s3)}
  .v4 .v4-shop-hero{gap:var(--s3)}
  .v4 .v4-shop-logo.is-big,.v4 .v4-shop-mark.is-big{width:56px;height:56px;font-size:var(--t-lg)}
  .v4 .v4-pick{grid-template-columns:64px minmax(0,1fr);gap:var(--s3)}
  .v4 .v4-hero{grid-template-columns:minmax(0,1fr);gap:0}
  .v4 .v4-hero-fan{display:none}

  .v4 .v4-book-hero{grid-template-columns:118px minmax(0,1fr);
    grid-template-areas:"cover head" "acts acts";
    grid-template-rows:auto auto;
    gap:var(--s3) var(--s4);align-content:start}
  /* A pill row that fits is worth more than a pill row that is centred. */
  .v4 .v4-bh-acts{gap:var(--s2)}
  .v4 .v4-bh-acts .v4-btn{flex:0 1 auto}
  .v4 .v4-h1{font-size:var(--t-2xl)}
  .v4 .v4-presence p{font-size:var(--t-base)}
  .v4 .v4-week{padding:var(--s4)}
  .v4 .v4-week h2{font-size:var(--t-xl)}
}

/* ══════════════════════════════════════════════════════════════════════════
   BREAKPOINT 480 — small phones. Density only, never structure.
   ══════════════════════════════════════════════════════════════════════════ */
@media (max-width:480px){
  .v4 .v4-book-hero{grid-template-columns:96px minmax(0,1fr)}
  .v4 .v4-stars.is-lg{width:112px;height:22px}
}
@media (max-width:480px){
  .v4 .v4-wrap{padding:0 var(--s3)}
  .v4 .v4-bc-grid{grid-template-columns:repeat(auto-fill,minmax(94px,1fr));gap:var(--s3)}
  .v4 .v4-thought q{font-size:var(--t-base)}
  .v4 .v4-digest{padding-left:var(--s4)}
  .v4 .v4-digest-item::before{left:calc(-1 * var(--s4) - 5px)}
}
/* ══════════════════════════════════════════════════════════════════════════
   V4.0.0-BETA.4
   ══════════════════════════════════════════════════════════════════════════ */

/* The verified mark. One treatment for both the author hero (standalone chip)
   and the book byline (is-inline, sitting beside a name in running text).
   Green rather than gold: gold is now load-bearing for ratings, and a claim is
   not a score. */
.v4 .v4-verified{display:inline-flex;align-items:center;gap:4px;
  padding:2px var(--s2);border-radius:var(--rad-full);
  background:var(--green-tint,rgba(74,140,80,.12));color:var(--green);
  font-family:var(--font-m);font-size:var(--t-2xs);font-weight:700;
  letter-spacing:.06em;text-transform:uppercase;white-space:nowrap;
  vertical-align:middle}
.v4 .v4-verified .v4-vdisc{width:12px;height:12px;flex-shrink:0}
/* The disc, everywhere it appears. Green fill, tick knocked out in white —
   NOT currentColor, because inside the pill currentColor is green and the tick
   would vanish into the circle. */
.v4 .v4-vdisc circle{fill:var(--green)}
.v4 .v4-vdisc path{stroke:#FFFFFF}
.v4 .v4-verified.is-inline{margin-left:var(--s2)}

/* 4.5.7 — the claim, as a line inside the Ask panel. Quiet on purpose: it is
   addressed to one person who is almost never the one reading the page. */
/* 4.5.9 — Edit / Delete on something you wrote. Quiet: it belongs to one person
   and everyone else on the page should not have to read past it. */
/* 4.5.10 — the same control on the dark question panel. Only the colours
   change; the markup is identical, so there is one control to maintain. */
.v4 .v4-week-tools{margin-top:var(--s4);padding-top:var(--s3);
  border-top:1px solid rgba(255,255,255,.16)}
.v4 .v4-week-tools .v4-reply-cue{color:#C8CFC2}
.v4 .v4-week-tools .v4-danger{border-top-color:rgba(255,255,255,.16)}
.v4 .v4-week-tools .v4-danger>summary .v4-reply-cue{color:#E8A08C}
.v4 .v4-week-tools .v4-sub{color:#C8CFC2}
.v4 .v4-week-tools .v4-compose{background:rgba(255,255,255,.07);
  border-color:rgba(255,255,255,.20)}
.v4 .v4-week-tools .v4-compose textarea{color:var(--bg)}

.v4 .v4-tools{margin-top:var(--s2)}
.v4 .v4-tools>summary,.v4 .v4-danger>summary{list-style:none;display:block;cursor:pointer}
.v4 .v4-tools>summary::-webkit-details-marker,
.v4 .v4-danger>summary::-webkit-details-marker{display:none}
.v4 .v4-tools[open]>summary{display:none}
.v4 .v4-danger{margin-top:var(--s3);padding-top:var(--s3);border-top:1px solid var(--line)}
.v4 .v4-danger>summary .v4-reply-cue{color:var(--rust)}
.v4 .v4-btn.is-danger{background:var(--rust)}
.v4 .v4-btn.is-danger:hover{background:#71301F}

.v4 .v4-claimline{margin:var(--s3) 0 0;padding-top:var(--s3);
  border-top:1px solid var(--line);font-size:var(--t-sm);color:var(--text3)}
.v4 .v4-claimform{display:inline}
.v4 .v4-claimform button{background:none;border:none;padding:0;cursor:pointer;
  font-family:inherit;font-size:inherit;color:var(--green-h);font-weight:500;
  text-decoration:underline;text-underline-offset:2px}
.v4 .v4-claimform button:hover{color:var(--green)}

/* The follow control in the hero. Capped, so a full-width button does not run
   the whole measure of a laptop; unconstrained on a phone, where it should. */
.v4 .v4-follow-hero{margin-top:var(--s4);max-width:420px}
/* 4.5.8 — the button was carried over from the sidebar still wearing is-wide,
   which was right in a narrow panel and wrong here: "Follow Chetan" is a short
   label and it was being stretched to a 320px slab beside it. Sized to its text
   on a laptop. On a phone it goes back to full width, where a tap target that
   spans the column is the correct shape. */
.v4 .v4-follow-hero .v4-btn.is-wide{display:inline-flex;align-items:center;
  justify-content:center;width:auto;min-width:180px;
  /* 4.5.9 — and shorter. --s3 top and bottom put it at about 45px, which is a
     primary-action height; a follow is an offer, not the point of the page. */
  padding-top:var(--s2);padding-bottom:var(--s2)}
@media (max-width:760px){
  .v4 .v4-follow-hero{max-width:none}
  .v4 .v4-follow-hero .v4-btn.is-wide{display:flex;width:100%}
}

/* The book byline. The author name is a link now, so it needs the same
   underline-on-hover the rest of the page uses rather than turning green. */
/* beta.7 — the byline holds a face, the name and the verified chip. inline-flex
   keeps them on a baseline together and lets the chip wrap as a unit rather
   than stranding the tick on its own line. */
/* v4.6.4 — the byline is the author's NAME, so it takes the name weight in
   the body face. It sat at the inherited 400 and read lighter than the
   title above it, which put the person second to the object. */
.v4 .v4-byline{display:flex;align-items:center;gap:var(--s2);flex-wrap:wrap;
  font-weight:var(--w-name);color:var(--text2)}
/* beta.8 — .v4-face carries margin-left:-9px and a 2px ring because it was
   built for overlapping face stacks, where the pull and the ring are what
   separate one face from the next. A byline has nothing to overlap, so on the
   phone both showed as a misplaced avatar with an arc around it. */
.v4 .v4-byline .v4-face{flex-shrink:0;margin-left:0;border:none}
/* beta.8 — the permanent border-bottom made a large name on a pale surface read
   as a text input. The link is legible from its position; the underline is only
   needed to confirm it on hover. */
.v4 .v4-byline a{color:inherit;text-decoration:none;border-bottom:1px solid transparent}
.v4 .v4-byline a:hover{border-bottom-color:var(--green);color:var(--green)}

/* The profile edit disclosure. The summary marker is suppressed above, which
   left the panel with no affordance at all and reading as a heading. */
.v4 .v4-caret{margin-left:auto;width:9px;height:9px;flex-shrink:0;
  border-right:1.5px solid var(--text3);border-bottom:1.5px solid var(--text3);
  transform:rotate(45deg);transition:transform .15s ease}
.v4 details[open] > summary .v4-caret{transform:rotate(-135deg)}

/* Author activity rows. Single column of text, unlike .v4-arow which is a
   two-column grid built for a cover beside a title. */
.v4 .v4-lrow{display:block;text-decoration:none;color:inherit}
.v4 .v4-lrow:last-child{border-bottom:0;padding-bottom:0}
.v4 .v4-lrow:first-child{padding-top:0}
.v4 .v4-lrow:hover .v4-meta{color:var(--green)}

/* ── v3 PAGE HEADERS, UNDER THE V4 SKIN ───────────────────────────────────
   4.0.0. Quotes, Lists, Giveaway, Blog and States each open with a full-bleed
   dark gradient band. Under v4 that band is louder than anything v4 itself
   does, so arriving from the Commons feels like leaving the site.

   The band is full-bleed and sits OUTSIDE the .wrap that constrains the page
   below it, which is why beta.9's version left the heading hard against the
   viewport edge: removing the horizontal padding did not pull the text into
   the wrap, it pushed it out to nothing. So the band keeps its full width —
   it carries the rule beneath it, which should span the page — and its CONTENT
   is given the wrap's own geometry: 1080px, centred, same gutter. The h1 now
   sits directly above the first card.

   Only the band is restyled. No markup on those pages is touched, every class
   name is theirs, and with the toggle off not one of these rules applies.
   Deliberately NOT a port: the page below is still v3, and a v4 header over a
   v3 body would be a worse lie than an honest seam. */

/* The band: no gradient, no giant quote mark, a rule instead of an edge. */
body.v4skin .page-hero,
body.v4skin .qw-hero-wrap{background:none;background-color:transparent;
  padding:var(--s6) 0 var(--s5);border-bottom:1px solid var(--line);
  text-align:left;overflow:visible}
body.v4skin .page-hero::after,
body.v4skin .page-hero::before,
body.v4skin .qw-hero-wrap::before{display:none;content:none}

/* The content: exactly the wrap the page below uses. This is the alignment fix. */
body.v4skin .page-hero > *,
body.v4skin .qw-hero{max-width:1080px;margin-left:auto;margin-right:auto;
  padding-left:var(--s5);padding-right:var(--s5);text-align:left}
body.v4skin .qw-hero > *{max-width:none;padding-left:0;padding-right:0}

/* Type, in v4's voice rather than v3's. */
body.v4skin .ph-label,
body.v4skin .qw-hero .qw-eyebrow{font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.12em;text-transform:uppercase;color:var(--text3);margin-bottom:var(--s2)}
body.v4skin .ph-h1,
body.v4skin .qw-hero h1{font-family:var(--font-d);font-weight:400;
  font-size:clamp(1.9rem,4vw,2.6rem);line-height:1.12;letter-spacing:-.01em;
  color:var(--text);margin:0 0 var(--s2)}
body.v4skin .ph-h1 em,
body.v4skin .qw-hero h1 em{font-style:italic;color:var(--text)}
body.v4skin .ph-sub,
body.v4skin .qw-hero p{font-family:var(--font-b);font-size:var(--t-base);
  line-height:var(--lh-snug);color:var(--text3);margin:0;max-width:62ch}

/* The stat row reads as figures, not as a scoreboard. */
body.v4skin .qw-stats{justify-content:flex-start;gap:var(--s6);margin:var(--s5) 0 0;
  flex-wrap:wrap}
body.v4skin .qw-stat{text-align:left}
body.v4skin .qw-stat-n{font-family:var(--font-d);font-weight:400;color:var(--green);
  font-size:var(--t-2xl)}
body.v4skin .qw-stat-l{font-family:var(--font-m);font-size:var(--t-2xs);
  letter-spacing:.1em;text-transform:uppercase;color:var(--text4)}

/* Buttons inside the band were white-on-dark. */
body.v4skin .page-hero .btn-outline,
body.v4skin .page-hero .btn-ghost,
body.v4skin .qw-hero-wrap .btn-outline,
body.v4skin .qw-hero-wrap .btn-ghost{color:var(--text2);border-color:var(--line2)}

/* States and Blog write their breadcrumbs as inline styles sized for white text
   on a dark band. Once the band is pale those are invisible, so they are pulled
   back to readable colours here. Specificity has to beat an inline style, hence
   the !important — the alternative is editing two v3 pages, which this release
   deliberately does not do. */
body.v4skin .page-hero a[style],
body.v4skin .page-hero div[style],
body.v4skin .page-hero span[style]{color:var(--text3) !important}
body.v4skin .page-hero a[style]:hover{color:var(--green) !important}

/* ══════════════════════════════════════════════════════════════════════════
   V4.6.0 — SIGN IN AND JOIN
   Composed almost entirely from components that already exist: .v4-cols,
   .v4-panel, .v4-field, .v4-check, .v4-facet, .v4-week, .v4-btn. What is new
   here is the shell around them and the username availability affordance,
   which has no equivalent anywhere else on the site.
   ══════════════════════════════════════════════════════════════════════════ */
.v4 .v4-auth{padding-top:var(--s6);padding-bottom:var(--s8)}
/* Narrower than the 1080 browse shell. A form does not want six covers of
   width, and a login page that fills a desktop monitor reads as a dashboard. */
.v4 .v4-auth-cols{max-width:900px;margin-left:auto;margin-right:auto;
  grid-template-columns:minmax(0,1.1fr) minmax(0,1fr);gap:var(--s7);
  align-items:start;margin-top:var(--s5)}
.v4 .v4-auth-go{margin-top:var(--s5)}
.v4 .v4-auth-alt{margin-top:var(--s4);font-family:var(--font-m);
  font-size:var(--t-xs);color:var(--text3);letter-spacing:.02em}
.v4 .v4-auth-alt a{color:var(--green-h)}
.v4 .v4-auth-alt span{margin:0 var(--s2);color:var(--line2)}
.v4 .v4-auth-p{margin:0 0 var(--s3);font-size:var(--t-sm);color:var(--text3)}
.v4 .v4-auth-note{margin-top:var(--s4);padding:var(--s3);border-radius:var(--rad);
  background:var(--green-tint);border:1px solid var(--green-ring);
  font-size:var(--t-sm);color:var(--text2)}
/* The two consent rows. Separated from the fields above them by a rule, because
   they are a different kind of decision: everything above is required, these
   two are choices. */
.v4 .v4-auth-opts{margin-top:var(--s5);padding-top:var(--s4);
  border-top:1px solid var(--line);display:flex;flex-direction:column;gap:var(--s4)}
.v4 .v4-auth-ts{margin-top:var(--s5)}
.v4 .v4-panel.is-live{background:var(--green-tint);border-color:var(--green-ring)}
.v4 .v4-live-t{margin:0 0 var(--s1);font-family:var(--font-d);font-size:var(--t-lg);
  line-height:var(--lh-snug);color:var(--text)}

/* Username availability. The status sits inside the field, so the input needs
   room reserved for it; the hint below reserves its own height so the form does
   not jump every time the answer arrives. */
.v4 .v4-un{position:relative}
.v4 .v4-un input{padding-right:96px}
.v4 .v4-un-status{position:absolute;right:var(--s3);top:50%;transform:translateY(-50%);
  font-family:var(--font-m);font-size:var(--t-2xs);letter-spacing:.08em;
  text-transform:uppercase;color:var(--text3);pointer-events:none}
.v4 .v4-un-status.is-good{color:var(--green)}
.v4 .v4-un-status.is-bad{color:var(--rust)}
.v4 .v4-un-hint{display:block;min-height:18px;margin-top:var(--s1)}
.v4 .v4-un-sug{color:var(--green-h);font-weight:var(--w-name)}

/* Touch targets. The live checkboxes are 18px, which is a miss on a phone.
   Growing the box to 22px and giving the row a 44px floor makes the whole line
   tappable without making the control look oversized. */
.v4 .v4-auth-opts .v4-check{min-height:44px;padding:var(--s1) 0}
.v4 .v4-auth-opts .v4-check input{width:22px;height:22px;margin-top:2px}

/* v4.6.1 — a panel that is a link. Whole-panel targets rather than a link
   inside them: on a phone the panel is the affordance, and a 12px "View
   giveaway" line at the bottom would be the smallest target on the page. */
.v4 .v4-panel.is-link{display:block;text-decoration:none;color:inherit;
  transition:border-color .15s,box-shadow .15s}
.v4 .v4-panel.is-link:hover{border-color:var(--green);box-shadow:var(--e1)}
.v4 .v4-panel.is-link .v4-eyebrow,.v4 .v4-panel.is-link .v4-live-t,
.v4 .v4-panel.is-link .v4-meta{display:block}
.v4 .v4-pick-row{display:flex;gap:var(--s3);align-items:center;margin-top:var(--s3)}
.v4 .v4-pick-cover{width:56px;flex-shrink:0}
.v4 .v4-pick-txt{min-width:0}
.v4 .v4-pick-card .v4-live-t{margin-bottom:2px}

@media (max-width:760px){
  /* Form first. Nobody signing in on a phone should scroll past a panel about
     how nice the community is to reach the password field. */
  .v4 .v4-auth-cols{grid-template-columns:minmax(0,1fr);gap:var(--s5)}
  .v4 .v4-auth-aside{order:2}
  .v4 .v4-auth{padding-top:var(--s5);padding-bottom:var(--s7)}
}

/* ══════════════════════════════════════════════════════════════════════════
   V4.6.2 — TOUCH TARGETS, FOCUS, MOTION
   ══════════════════════════════════════════════════════════════════════════ */

/* A 28px chip and an 18px checkbox are misses on a phone, and this audience is
   phone-first. The visible size does not change: the box keeps its drawn
   dimensions and the ROW around it grows to 44px, so the whole line is
   pressable. Growing the visuals instead would have coarsened every one of
   these components. */
/* v4.6.3 — 4.6.2 used min-height here and grew the controls themselves, which
   is what min-height does: it sizes the border box, so background, border and
   radius all follow. The chips visibly fattened.

   This is the technique that grows the reach without touching the drawing. The
   control keeps its own dimensions; an invisible band, centred on it and 44px
   tall, catches the press. Chips sit in rows with a --s4 (16px) gap, so 8px of
   reach on each side leaves adjacent targets touching rather than overlapping,
   which is the line you do not want to cross. */
/* v4.6.4 — three components, three height formulas, one row. A shared floor
   plus centring is the only thing that makes them agree, and unlike 4.6.2's
   chips this IS a change to the drawing, which is what was wanted: the row is
   supposed to look like one row. 38px is the current tallest rounded up, so
   Following barely moves and the other two rise to meet it. */
.v4 .v4-bh-acts .v4-pill span,
.v4 .v4-bh-acts .v4-btn,
.v4 .v4-bh-acts .v4-share{min-height:38px;display:inline-flex;align-items:center;
  justify-content:center;box-sizing:border-box}

.v4 .v4-chip,.v4 .v4-pill span,.v4 .v4-reply>summary,.v4 .v4-ans summary,
.v4 .v4-btn.is-sm,.v4 .v4-bookbar-btn{position:relative}
.v4 .v4-chip::before,.v4 .v4-pill span::before,.v4 .v4-reply>summary::before,
.v4 .v4-ans summary::before,.v4 .v4-btn.is-sm::before,
.v4 .v4-bookbar-btn::before{content:"";position:absolute;left:0;right:0;
  top:50%;transform:translateY(-50%);height:44px;pointer-events:auto}
/* The acts row is excluded. Its children are levelled on --act-h (20px) and a
   44px band inside one of them would reintroduce exactly the misalignment
   4.5.13 spent a release removing. */
.v4 .v4-acts>.v4-reply>summary::before{display:none}
/* These two are rows of text that already clear 44px; the floor only matters
   when a row happens to be short, and it changes nothing visible when it does
   not. The input is the exception worth drawing bigger: 18px is too small to
   hit accurately, and 22px still reads as a checkbox. */
.v4 .v4-check,.v4 .v4-poll-opt{min-height:44px}
.v4 .v4-check input,.v4 .v4-poll-opt input{width:22px;height:22px}

/* v4.6.2 — every other outline:none in this sheet pairs with a box-shadow.
   This one did not, so tabbing into the main Commons compose box left a
   keyboard user with no idea where they were. */
.v4 .v4-compose textarea:focus{box-shadow:0 0 0 3px var(--green-tint);
  border-color:var(--green)}

/* v4.6.2 — 11 transitions in this sheet and nothing honouring the setting.
   Someone who has asked their device to stop moving things has usually asked
   for a reason. */
@media (prefers-reduced-motion:reduce){
  .v4 *,.v4 *::before,.v4 *::after{transition-duration:.01ms!important;
    animation-duration:.01ms!important;animation-iteration-count:1!important;
    scroll-behavior:auto!important}
}


/* ── single-column auth / account forms ─────────────────────────────── */
.v4-auth-single{max-width:440px;margin:0 auto}
.v4-auth-single form{margin-top:var(--s4)}

/* ── home page ──────────────────────────────────────────────────────── */
.plat-hero{max-width:720px}
.plat-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(260px,1fr));gap:var(--s4);margin-top:var(--s3)}
.plat-card{display:flex;flex-direction:column;gap:var(--s2);text-decoration:none;color:inherit}
.plat-card img{width:100%;aspect-ratio:16/9;object-fit:cover;border-radius:8px;margin-bottom:var(--s2)}
.plat-card-t{font-family:var(--font-d);font-size:1.1rem;line-height:1.3;color:var(--text)}

/* ── admin dashboard ────────────────────────────────────────────────── */
.plat-stats{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));gap:12px;margin:8px 0 20px}
.plat-stat{display:flex;flex-direction:column;gap:2px;padding:16px 18px;background:var(--surface);border:1px solid var(--line);border-radius:12px;text-decoration:none;color:var(--text);transition:border-color .15s}
.plat-stat:hover{border-color:var(--green)}
.plat-stat-n{font-family:var(--font-d);font-size:28px;font-weight:800;line-height:1.1}
.plat-stat-l{font-size:13px;font-weight:600}
.plat-stat-s{font-family:var(--font-m);font-size:11px;color:var(--text4)}
.plat-2col{display:grid;grid-template-columns:1fr 1fr;gap:16px}
@media(max-width:860px){.plat-2col{grid-template-columns:1fr}}
.plat-box{background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:18px 20px}
.plat-box h3{font-family:var(--font-d);font-size:15px;font-weight:700;margin:0 0 10px;color:var(--text)}
.plat-row{display:flex;justify-content:space-between;align-items:center;gap:12px;padding:7px 0;border-top:1px solid var(--line);font-size:13px}
.plat-row:first-of-type{border-top:0}
.plat-row a{color:var(--text);text-decoration:none}
.plat-row a:hover{color:var(--green)}
.plat-muted{color:var(--text4)}

/* ── admin settings cards ───────────────────────────────────────────── */
.plat-card-s{background:var(--surface);border:1px solid var(--line);border-radius:14px;padding:22px 24px;margin-bottom:16px}
.plat-card-s h3{font-family:var(--font-d);font-size:15px;font-weight:700;color:var(--text);margin:0 0 14px}
.plat-card-s h3 small{font-family:var(--font-b);font-weight:400;font-size:12px;color:var(--text3)}
.plat-card-s .fg label small{font-weight:400;color:var(--text3)}
.plat-check{display:flex;align-items:center;gap:9px;font-size:13.5px;padding:6px 0;cursor:pointer}
/* ── fixes over the inherited stylesheet ────────────────────────────── */
/* The footer was hard-coded the original engine green; it now follows the theme. */
.site-footer{background:var(--footer-bg,#0F1A2B)}
/* Footer text was 20-35% white on near-black, below WCAG contrast. */
.fc h4{color:rgba(255,255,255,.55)}
.fc a{color:rgba(255,255,255,.72)}
.fc a:hover{color:#fff}
.footer-brand p{color:rgba(255,255,255,.7)}
.footer-bottom{color:rgba(255,255,255,.55)}
/* ".v4 .v4-panel.is-link" sets display:block; match its specificity. */
.v4 .v4-panel.plat-card{display:flex;flex-direction:column;gap:var(--s2)}

/* ECGC country rating page (/ecgc-country-rating).
 * Ported from the standalone HTML page. Every rule is scoped under .ecgc so it
 * cannot touch the rest of the site; :root and body became .ecgc, and the
 * page now uses the site's fonts. The AI advisor styles were removed with the
 * advisor. */
.ecgc,.ecgc *,.ecgc ::before,.ecgc ::after{box-sizing:border-box;margin:0;padding:0}
.ecgc{--teal:#0C7B7B;--teal-l:#0A9696;
  --navy:#0B1F3A;--navy-l:#142d52;
  --ink:#0F172A;--ink2:#475569;--ink3:#94A3B8;--ink4:#CBD5E1;
  --bg:#FFFFFF;--bg2:#F8FAFC;--bg3:#F1F5F9;
  --bd:#E2E8F0;--bd2:#CBD5E1;
  --shadow:0 1px 4px rgba(0,0,0,.07);
  --shadow-md:0 4px 20px rgba(0,0,0,.10);
  --shadow-xl:0 12px 48px rgba(0,0,0,.18);
  --r:8px;--rl:14px;
  --font:var(--font-b);--mono:var(--font-m);}
.ecgc{font-family:var(--font);background:var(--bg2);color:var(--ink);font-size:14px;line-height:1.6;}

/* ── HERO ── */
.ecgc .hero{background:linear-gradient(135deg,#0B1F3A 0%,#0e2a47 50%,#0C5F72 100%);padding:1.75rem 1.5rem 1.5rem;color:#fff}
.ecgc .hero-inner{max-width:1080px;margin:0 auto}
.ecgc .hero-top{display:flex;align-items:flex-start;justify-content:space-between;flex-wrap:wrap;gap:.75rem;margin-bottom:.85rem}
.ecgc .hero-chip{font-size:10px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:rgba(255,255,255,.45)}
.ecgc .hero h1{font-size:1.75rem;font-weight:700;line-height:1.22;margin-bottom:5px;color:#fff!important}
.ecgc .hero h1 em{color:#5ECECE;font-style:normal}
.ecgc .hero p{font-size:13px;color:rgba(255,255,255,.6);max-width:520px;margin-bottom:1.1rem}

/* Effective date badge — prominent in hero */
.ecgc .eff-badge{display:inline-flex;align-items:center;gap:6px;background:rgba(255,255,255,.1);border:1px solid rgba(255,255,255,.2);border-radius:20px;padding:5px 13px;font-size:12px;color:rgba(255,255,255,.85);font-family:var(--mono);font-weight:500;white-space:nowrap}
.ecgc .eff-dot{width:7px;height:7px;border-radius:50%;background:#5ECECE;flex-shrink:0;animation:ecgc-pulse 3s ease-in-out infinite}
@keyframes ecgc-pulse{0%,100%{opacity:1}50%{opacity:.4}}
.ecgc .eff-lbl{font-size:9px;font-weight:700;text-transform:uppercase;letter-spacing:.1em;color:rgba(255,255,255,.45);margin-right:2px}
.ecgc .search-bar{display:flex;gap:8px;max-width:520px}
.ecgc .search-bar input{flex:1;padding:10px 14px;border-radius:var(--r);border:1.5px solid rgba(255,255,255,.18);background:rgba(255,255,255,.09);color:#fff;font-family:var(--font);font-size:14px;outline:none;transition:all .2s;backdrop-filter:blur(6px)}
.ecgc .search-bar input::placeholder{color:rgba(255,255,255,.4)}
.ecgc .search-bar input:focus{border-color:rgba(255,255,255,.4);background:rgba(255,255,255,.13)}
.ecgc .search-btn{padding:10px 20px;background:var(--teal);color:#fff;border:none;border-radius:var(--r);font-family:var(--font);font-size:13px;font-weight:600;cursor:pointer;transition:background .15s}
.ecgc .search-btn:hover{background:var(--teal-l)}

/* ── STATS ── */
.ecgc .stats-bar{background:#0a1a30;border-top:1px solid rgba(255,255,255,.06);padding:.75rem 1.5rem}
.ecgc .stats-inner{max-width:1080px;margin:0 auto;display:flex;align-items:center;gap:1.5rem;flex-wrap:wrap}
.ecgc .s-num{font-size:1.15rem;font-weight:700;color:#fff}
.ecgc .s-lbl{font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.07em;color:rgba(255,255,255,.4)}
.ecgc .s-sep{width:1px;height:28px;background:rgba(255,255,255,.08)}
.ecgc .dist-wrap{flex:1;min-width:240px}
.ecgc .dist-lbl{font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.07em;color:rgba(255,255,255,.4);margin-bottom:4px}
.ecgc .dist-track{height:6px;border-radius:3px;overflow:hidden;display:flex;gap:1px}
.ecgc .dist-seg{height:100%}
.ecgc .dist-leg{display:flex;flex-wrap:wrap;gap:9px;margin-top:5px}
.ecgc .dl-item{display:flex;align-items:center;gap:4px;font-size:10px;color:rgba(255,255,255,.55)}
.ecgc .dl-dot{width:6px;height:6px;border-radius:50%;flex-shrink:0}

/* Effective date strip below stats */
.ecgc .eff-strip{background:#061220;border-bottom:1px solid rgba(255,255,255,.06);padding:.45rem 1.5rem;display:flex;align-items:center;justify-content:center;gap:.75rem;flex-wrap:wrap}
.ecgc .eff-strip-inner{max-width:1080px;width:100%;display:flex;align-items:center;gap:.75rem;flex-wrap:wrap}
.ecgc .eff-strip-date{font-size:11px;color:rgba(255,255,255,.6);font-family:var(--mono)}
.ecgc .eff-strip-date strong{color:#5ECECE}
.ecgc .eff-strip-src{font-size:10px;color:rgba(255,255,255,.3)}

/* ── MAIN ── */

/* ── CONTROL BAR ── */
.ecgc .cbar{background:var(--bg);border:1px solid var(--bd);border-radius:var(--rl);padding:9px 12px;display:flex;align-items:center;flex-wrap:wrap;gap:7px;box-shadow:var(--shadow);margin-bottom:.9rem}
.ecgc .cbar label{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.07em;color:var(--ink3)}
.ecgc .fsel{padding:5px 9px;border:1px solid var(--bd2);border-radius:var(--r);font-family:var(--font);font-size:12px;color:var(--ink);background:var(--bg2);cursor:pointer;outline:none}
.ecgc .fsel:focus{border-color:var(--teal)}
.ecgc .fsep{width:1px;height:20px;background:var(--bd);margin:0 2px}
.ecgc .vtgl{display:flex;border:1px solid var(--bd2);border-radius:var(--r);overflow:hidden;margin-left:auto}
.ecgc .vbtn{padding:5px 11px;background:var(--bg2);border:none;cursor:pointer;color:var(--ink2);font-size:11px;font-weight:600;transition:all .15s;display:flex;align-items:center;gap:4px;font-family:var(--font);letter-spacing:.02em;text-transform:uppercase}
.ecgc .vbtn.on{background:var(--navy);color:#fff}
.ecgc .vbtn:not(:last-child){border-right:1px solid var(--bd2)}
.ecgc .rcnt{font-size:11px;color:var(--ink3);margin-bottom:.65rem}
.ecgc .rcnt strong{color:var(--ink);font-weight:600}

/* ── MAP VIEW ── */
.ecgc #map-view{background:var(--bg);border:1px solid var(--bd);border-radius:var(--rl);overflow:hidden;box-shadow:var(--shadow)}
.ecgc .map-wrap{position:relative;width:100%;background:linear-gradient(180deg,#dbeafe 0%,#eff6ff 50%,#dbeafe 100%)}
.ecgc .map-wrap svg{display:block;width:100%;cursor:grab}
.ecgc .map-wrap svg:active{cursor:grabbing}
.ecgc .map-footer{display:flex;align-items:center;justify-content:space-between;padding:.65rem 1rem;border-top:1px solid var(--bd);flex-wrap:wrap;gap:.5rem}
.ecgc .map-hint{font-size:11px;color:var(--ink3)}
.ecgc .map-hint span{margin-right:10px}
.ecgc .zoom-ctrls{display:flex;gap:4px}
.ecgc .zbtn{width:26px;height:26px;border:1px solid var(--bd2);border-radius:6px;background:var(--bg);cursor:pointer;display:flex;align-items:center;justify-content:center;font-size:14px;color:var(--ink2);transition:all .15s;font-weight:600}
.ecgc .zbtn:hover{background:var(--navy);color:#fff;border-color:var(--navy)}
.ecgc .map-legend{display:flex;align-items:center;gap:6px;flex-wrap:wrap}
.ecgc .leg-item{display:flex;align-items:center;gap:4px;font-size:10px;color:var(--ink2);font-weight:500}
.ecgc .leg-swatch{width:12px;height:12px;border-radius:3px;flex-shrink:0}

/* MAP TOOLTIP */
.ecgc .map-tip{position:fixed;background:var(--navy);color:#fff;border-radius:var(--r);padding:8px 11px;font-size:12px;pointer-events:none;z-index:400;opacity:0;transition:opacity .1s;box-shadow:var(--shadow-md);min-width:140px}
.ecgc .map-tip.on{opacity:1}
.ecgc .tip-flag{font-size:18px;margin-bottom:3px}
.ecgc .tip-name{font-size:13px;font-weight:700;margin-bottom:4px}
.ecgc .tip-row{display:flex;align-items:center;gap:6px;margin-bottom:2px}
.ecgc .tip-lbl{font-size:10px;color:rgba(255,255,255,.5);font-weight:600;text-transform:uppercase;letter-spacing:.06em}
.ecgc .tip-val{font-size:11px;font-weight:600}
.ecgc .tip-click{font-size:10px;color:rgba(255,255,255,.4);margin-top:5px;border-top:1px solid rgba(255,255,255,.1);padding-top:4px}

/* ── TABLE ── */
.ecgc .twrap{background:var(--bg);border:1px solid var(--bd);border-radius:var(--rl);overflow:hidden;box-shadow:var(--shadow)}
.ecgc table{width:100%;border-collapse:collapse}
.ecgc thead th{background:var(--bg2);padding:8px 12px;text-align:left;font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.07em;color:var(--ink2);border-bottom:1px solid var(--bd);white-space:nowrap;cursor:pointer;user-select:none;transition:color .15s}
.ecgc thead th:hover{color:var(--teal)}
.ecgc thead th.srt{color:var(--teal)}
.ecgc tbody tr{cursor:pointer;transition:background .1s}
.ecgc tbody tr:hover td{background:#f0fdfc}
.ecgc tbody td{padding:9px 12px;border-bottom:1px solid var(--bg3);vertical-align:middle}
.ecgc tbody tr:last-child td{border-bottom:none}
.ecgc .cn-cell{display:flex;align-items:center;gap:8px}
.ecgc .cflag{font-size:18px;width:24px;text-align:center;flex-shrink:0}
.ecgc .cname{font-weight:600;font-size:13px}
.ecgc .creg{font-size:11px;color:var(--ink3)}
.ecgc .rbadge{display:inline-flex;align-items:center;padding:3px 8px;border-radius:20px;font-family:var(--mono);font-size:12px;font-weight:500;border:1px solid;letter-spacing:.02em}
.ecgc .rbar-wrap{min-width:110px}
.ecgc .rbar-lbl{font-size:10px;color:var(--ink2);margin-bottom:3px}
.ecgc .rbar-track{height:4px;border-radius:3px;background:var(--bg3);overflow:hidden}
.ecgc .rbar-fill{height:100%;border-radius:3px}
.ecgc .cvrbadge{font-size:10px;font-weight:700;padding:3px 8px;border-radius:20px;white-space:nowrap;letter-spacing:.02em}
.ecgc .arr-ico{color:var(--ink4);font-size:12px}
.ecgc .empty{text-align:center;padding:3rem 2rem;color:var(--ink3)}
.ecgc .empty .e-ico{font-size:2.5rem;margin-bottom:.75rem;opacity:.5}
.ecgc .empty h3{font-size:16px;font-weight:600;color:var(--ink2);margin-bottom:.4rem}

/* ── CARD GRID ── */
.ecgc .cgrid{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));gap:10px}
.ecgc .ccard{background:var(--bg);border:1px solid var(--bd);border-radius:var(--rl);padding:1rem;cursor:pointer;transition:border-color .15s,box-shadow .15s,transform .15s;box-shadow:var(--shadow)}
.ecgc .ccard:hover{border-color:var(--teal);box-shadow:var(--shadow-md);transform:translateY(-2px)}
.ecgc .cc-top{display:flex;justify-content:space-between;align-items:flex-start;margin-bottom:8px}
.ecgc .cc-flag{font-size:28px}
.ecgc .cc-name{font-size:13px;font-weight:700;margin-bottom:2px}
.ecgc .cc-reg{font-size:11px;color:var(--ink3);margin-bottom:8px}
.ecgc .cc-rbar{height:3px;border-radius:2px;background:var(--bg3);overflow:hidden;margin-bottom:8px}
.ecgc .cc-foot{display:flex;justify-content:space-between;align-items:center}

/* ── PANEL ── */
.ecgc .overlay{display:none;position:fixed;inset:0;background:rgba(11,31,58,.5);z-index:600;backdrop-filter:blur(3px)}
.ecgc .overlay.on{display:block}
.ecgc .panel{position:fixed;top:0;right:0;width:min(560px,100vw);height:100vh;background:var(--bg);z-index:700;transform:translateX(105%);transition:transform .3s cubic-bezier(.4,0,.2,1);overflow-y:auto;box-shadow:var(--shadow-xl)}
.ecgc .panel.on{transform:translateX(0)}
.ecgc .phdr{display:flex;align-items:center;justify-content:space-between;padding:.9rem 1.3rem;border-bottom:1px solid var(--bd);background:var(--bg);position:sticky;top:0;z-index:10}
.ecgc .pback{display:flex;align-items:center;gap:5px;font-size:12px;color:var(--ink2);background:none;border:none;cursor:pointer;padding:4px 8px;border-radius:var(--r);transition:background .15s;font-family:var(--font);font-weight:500}
.ecgc .pback:hover{background:var(--bg3);color:var(--ink)}
.ecgc .pclose{width:28px;height:28px;border-radius:50%;border:1px solid var(--bd);background:none;cursor:pointer;display:flex;align-items:center;justify-content:center;color:var(--ink2);transition:all .15s}
.ecgc .pclose:hover{background:var(--bg3)}
.ecgc .phero{padding:1.3rem;background:var(--bg2);border-bottom:1px solid var(--bd)}
.ecgc .phero-row{display:flex;align-items:flex-start;gap:1rem;margin-bottom:1rem}
.ecgc .pflag{font-size:50px;line-height:1}
.ecgc .pcname{font-size:1.4rem;font-weight:700;margin-bottom:5px}
.ecgc .pchip{display:inline-flex;align-items:center;gap:5px;padding:2px 9px;background:var(--bg);border:1px solid var(--bd);border-radius:20px;font-size:11px;color:var(--ink2);font-weight:500;margin-right:4px;margin-bottom:3px}
/* Effective date chip in profile — teal tinted */
.ecgc .pchip-eff{background:#F0FDF4;border-color:#BBF7D0;color:#15803D}
.ecgc .gauge-wrap{display:flex;flex-direction:column;align-items:center;gap:3px}
.ecgc .gauge-rlabel{font-size:13px;font-weight:700;text-align:center}
.ecgc .gauge-desc{font-size:11px;color:var(--ink2);text-align:center}
.ecgc .pbody{padding:1.3rem}
.ecgc .psec{margin-bottom:1.3rem}
.ecgc .psec:last-child{margin-bottom:0}
.ecgc .stitle{font-size:10px;font-weight:800;text-transform:uppercase;letter-spacing:.09em;color:var(--ink3);padding-bottom:6px;border-bottom:1px solid var(--bd);margin-bottom:9px}
.ecgc .icard{background:var(--bg2);border:1px solid var(--bd);border-radius:var(--r);padding:.85rem;margin-bottom:7px}
.ecgc .icard p{font-size:13px;color:var(--ink2);line-height:1.65}
.ecgc .icard strong{color:var(--ink)}
.ecgc .irow{display:flex;justify-content:space-between;align-items:flex-start;padding:6px 0;border-bottom:1px solid var(--bd);gap:1rem}
.ecgc .irow:last-child{border-bottom:none}
.ecgc .ilbl{font-size:12px;color:var(--ink2);font-weight:500;flex-shrink:0}
.ecgc .ival{font-size:12px;color:var(--ink);text-align:right;font-weight:600}
.ecgc .ival-eff{color:var(--teal)!important;font-family:var(--mono)}
.ecgc .pay-box{border-radius:var(--r);padding:.85rem;border-left:4px solid;margin-bottom:7px}
.ecgc .pay-box p{font-size:13px;line-height:1.65;color:var(--ink2)}
.ecgc .pay-terms{font-size:13px;font-weight:700;margin-bottom:5px}
.ecgc .tag-row{display:flex;flex-wrap:wrap;gap:5px;margin-top:6px}
.ecgc .tag{padding:3px 10px;border-radius:20px;font-size:11px;font-weight:600;border:1px solid}
.ecgc .fin-note{font-size:11px;color:var(--ink3);text-align:center;margin-top:1.2rem;padding-top:.9rem;border-top:1px solid var(--bd)}
.ecgc .fin-note strong{color:var(--ink2)}

/* ── RISK COLORS ── */
.ecgc .A1{--rc:#16A34A;--rb:#F0FDF4;--rbc:#BBF7D0}
.ecgc .A2{--rc:#5A8F0B;--rb:#F7FEE7;--rbc:#C6EF6E}
.ecgc .B1{--rc:#B07A04;--rb:#FEFCE8;--rbc:#FDE870}
.ecgc .B2{--rc:#C97100;--rb:#FFFBEB;--rbc:#FCCD6A}
.ecgc .C1{--rc:#C2470A;--rb:#FFF7ED;--rbc:#FDCB9A}
.ecgc .C2{--rc:#B91C1C;--rb:#FEF2F2;--rbc:#FECACA}
.ecgc .D{--rc:#7F1D1D;--rb:#FEF2F2;--rbc:#FCA5A5}
.ecgc .rbadge.A1,.ecgc .rbadge.A2,.ecgc .rbadge.B1,.ecgc .rbadge.B2,.ecgc .rbadge.C1,.ecgc .rbadge.C2,.ecgc .rbadge.D{background:var(--rb);color:var(--rc);border-color:var(--rbc)}
.ecgc .rbar-fill.A1{background:#16A34A}
.ecgc .rbar-fill.A2{background:#65A30D}
.ecgc .rbar-fill.B1{background:#CA8A04}
.ecgc .rbar-fill.B2{background:#D97706}
.ecgc .rbar-fill.C1{background:#EA580C}
.ecgc .rbar-fill.C2{background:#DC2626}
.ecgc .rbar-fill.D{background:#991B1B}
.ecgc .cvr-OC{background:#F0FDF4;color:#15803D;border:1px solid #BBF7D0}
.ecgc .cvr-RC1{background:#FFFBEB;color:#92400E;border:1px solid #FDE68A}
.ecgc .cvr-RC2{background:#FFF7ED;color:#9A3412;border:1px solid #FED7AA}
.ecgc .cvr-OFF{background:#FEF2F2;color:#991B1B;border:1px solid #FECACA}
.ecgc .pay-A1,.ecgc .pay-A2{background:#F0FDF4;border-color:#16A34A}
.ecgc .pay-B1,.ecgc .pay-B2{background:#FFFBEB;border-color:#D97706}
.ecgc .pay-C1,.ecgc .pay-C2{background:#FFF7ED;border-color:#EA580C}
.ecgc .pay-D,.ecgc .pay-OFF{background:#FEF2F2;border-color:#DC2626}
.ecgc .tag.A1,.ecgc .tag.A2{background:#F0FDF4;color:#15803D;border-color:#BBF7D0}
.ecgc .tag.B1,.ecgc .tag.B2{background:#FFFBEB;color:#92400E;border-color:#FDE68A}
.ecgc .tag.C1,.ecgc .tag.C2{background:#FFF7ED;color:#9A3412;border-color:#FED7AA}
.ecgc .tag.D,.ecgc .tag.OFF{background:#FEF2F2;color:#991B1B;border-color:#FECACA}
@keyframes ecgc-spin{to{transform:rotate(360deg)}}
@media(max-width:640px){
.ecgc .hero h1{font-size:1.4rem}
.ecgc .hm{display:none}
.ecgc .cbar{flex-direction:column;align-items:stretch}
.ecgc .vtgl{align-self:flex-start}
.ecgc .stats-inner{gap:.5rem}
}

/* ── Added for the site version ─────────────────────────────────────────── */
.ecgc .hero h1{font-family:var(--font-d);letter-spacing:-.01em}
.ecgc .map-loading,.ecgc .map-off{display:flex;align-items:center;justify-content:center;height:420px;color:var(--ink3);font-size:13px;gap:8px}
.ecgc .map-off{flex-direction:column;height:380px}
.ecgc .p-loading{font-size:11px;color:var(--ink3);padding:6px 0;display:flex;align-items:center;gap:6px}
.ecgc .eg-spin-w{display:inline-block;width:11px;height:11px;border:2px solid var(--ink3);border-top-color:transparent;border-radius:50%;animation:ecgc-spin .65s linear infinite}
/* Recent rating changes */
.ecgc .recent{background:var(--bg);border:1px solid var(--bd);border-radius:var(--rl);padding:10px 12px;margin-bottom:.9rem;box-shadow:var(--shadow)}
.ecgc .rc-t{font-size:10px;font-weight:700;text-transform:uppercase;letter-spacing:.07em;color:var(--ink3);margin-bottom:6px}
.ecgc .rc-list{display:flex;gap:6px;overflow-x:auto;padding-bottom:2px}
.ecgc .rc-i{display:flex;align-items:center;gap:6px;flex-shrink:0;padding:6px 10px;border:1px solid var(--bd);border-radius:var(--r);background:var(--bg2);cursor:pointer;font:inherit;font-size:12px;color:var(--ink)}
.ecgc .rc-i:hover{border-color:var(--teal)}
.ecgc .rc-n{font-weight:600}
.ecgc .rc-m{font-family:var(--mono);font-size:11px;color:var(--ink2)}
.ecgc .rc-m.is-down,.ecgc .hist-down{color:#B91C1C!important}
.ecgc .rc-m.is-up,.ecgc .hist-up{color:#15803D!important}
.ecgc .rc-d{font-size:10px;color:var(--ink3)}
/* My markets */
.ecgc .mine-btn{padding:5px 11px;border:1px solid var(--bd2);border-radius:var(--r);background:var(--bg2);color:var(--ink2);font:inherit;font-size:11px;font-weight:600;cursor:pointer;text-transform:uppercase;letter-spacing:.02em}
.ecgc .mine-btn.on{background:var(--teal);border-color:var(--teal);color:#fff}
.ecgc .mine-dot{color:var(--teal);font-size:11px}
.ecgc .trk-wrap{margin-top:10px}
.ecgc .trk{display:inline-flex;align-items:center;gap:5px;padding:6px 12px;border-radius:var(--r);border:1.5px solid var(--teal);background:var(--bg);color:var(--teal);font:inherit;font-size:12px;font-weight:700;cursor:pointer;text-decoration:none}
.ecgc .trk:hover{background:#F0FDFA}
.ecgc .trk.on{background:var(--teal);color:#fff}
.ecgc .trk:disabled{opacity:.6;cursor:wait}
.ecgc .trk-note{font-size:11px;color:var(--ink3);margin-top:4px;max-width:300px}
.ecgc .trk-note a{color:var(--teal)}
/* Footer of the tool */
.ecgc .ecgc-foot{margin:1.2rem 0 .5rem;font-size:12px;color:var(--ink3)}
.ecgc .ecgc-foot p{max-width:720px}
.ecgc .ecgc-cta{display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap;background:linear-gradient(135deg,#0B1F3A,#0C5F72);color:rgba(255,255,255,.85);border-radius:var(--rl);padding:1rem 1.2rem;margin-bottom:1rem;font-size:13px}
.ecgc .ecgc-cta strong{color:#fff}
.ecgc .ecgc-cta div{flex:1;min-width:240px}
.ecgc .ecgc-cta .search-btn{text-decoration:none;white-space:nowrap}
.ecgc .panel{top:0}


/* ── Site look (1.9.2): the page wears the same clothes as the other tools ── */
.ecgc{--teal:var(--green);--teal-l:var(--green-h,var(--green));--navy:var(--text);--navy-l:var(--text2);
  --ink:var(--text);--ink2:var(--text2);--ink3:var(--text3);--ink4:var(--line2);
  --bg:var(--surface);--bg2:var(--surface2);--bg3:var(--bg2);--bd:var(--line);--bd2:var(--line2);
  --shadow:none;--shadow-md:0 10px 30px -18px rgba(20,40,30,.35);--rl:var(--rad-lg,14px);
  background:transparent;color:var(--text);font-size:var(--t-base)}
.v4 .v4-wrap.ec-head{padding-top:var(--s5)}
.ec-top{display:flex;justify-content:space-between;align-items:flex-start;gap:var(--s4);flex-wrap:wrap}
.ec-top .ta-hero{margin-bottom:var(--s4)}
.ec-top .ta-hero .v4-sub{margin-bottom:0}
.ec-eff{margin:var(--s3) 0 0;display:flex;flex-direction:column;align-items:flex-end;gap:2px;font-size:var(--t-sm);color:var(--text2);text-align:right}
.ec-eff b{font-family:var(--font-d);font-size:var(--t-lg);font-weight:600;color:var(--text)}
.ec-eff span{font-size:var(--t-xs);color:var(--text3)}
@media(max-width:700px){.ec-eff{flex-direction:row;flex-wrap:wrap;align-items:baseline;gap:4px 8px;text-align:left;margin:0 0 var(--s4)}.ec-eff b{font-size:var(--t-md)}}
.ec-search{position:relative;display:flex;gap:8px;max-width:560px;margin-bottom:var(--s5)}
.ec-search svg{position:absolute;left:14px;top:50%;transform:translateY(-50%);color:var(--text3);pointer-events:none}
.ec-search input{flex:1;min-width:0;height:48px;padding:0 14px 0 42px;border:1.5px solid var(--line2);border-radius:var(--rad);background:var(--surface);font:inherit;font-size:var(--t-md);color:var(--text)}
.ec-search input:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.ec-btn{display:inline-flex;align-items:center;justify-content:center;height:48px;padding:0 22px;border-radius:var(--rad);background:var(--green);color:#fff;border:1px solid var(--green);font:inherit;font-weight:600;cursor:pointer;text-decoration:none;white-space:nowrap}
.ec-btn:hover{background:var(--green-h,var(--green))}
.ec-btn.is-light{background:#fff;color:var(--green-h,var(--green));border-color:#fff;height:44px}
.ec-stats{display:grid;grid-template-columns:repeat(4,auto) minmax(220px,1fr);gap:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg,14px);margin-bottom:var(--s4);overflow:hidden}
.ec-stat{padding:14px 22px;border-right:1px solid var(--line);display:flex;flex-direction:column;gap:2px}
.ec-stat b{font-family:var(--font-d);font-size:26px;font-weight:600;line-height:1.1;color:var(--text)}
.ec-stat span{font-size:var(--t-xs);color:var(--text3)}
.ec-stat.is-oc b{color:#15803D}.ec-stat.is-rc b{color:#B45309}.ec-stat.is-off b{color:var(--err)}
.ec-dist{padding:14px 22px;display:flex;flex-direction:column;justify-content:center;gap:6px;min-width:0}
.ec-dist-l{font-size:var(--t-xs);color:var(--text3)}
.ecgc .dist-track{height:8px;border-radius:99px;overflow:hidden;display:flex;gap:2px}
.ecgc .dist-leg{display:flex;flex-wrap:wrap;gap:10px}
.ecgc .dl-item{display:flex;align-items:center;gap:4px;font-size:11px;color:var(--text2)}
.ecgc .dl-dot{width:8px;height:8px;border-radius:50%;flex-shrink:0;display:inline-block}
@media(max-width:900px){.ec-stats{grid-template-columns:repeat(4,1fr)}.ec-dist{grid-column:1/-1;border-top:1px solid var(--line)}.ec-stat:nth-child(4){border-right:0}}
@media(max-width:560px){.ec-stats{grid-template-columns:repeat(2,1fr)}.ec-stat:nth-child(2){border-right:0}.ec-stat:nth-child(-n+2){border-bottom:1px solid var(--line)}.ec-stat{padding:12px 16px}}
.v4 .v4-wrap.main{padding-top:0;padding-bottom:var(--s8)}
/* Recent changes, controls, views: site cards and controls */
.ecgc .recent,.ecgc .cbar,.ecgc #map-view,.ecgc .twrap,.ecgc .ccard{border-radius:var(--rad-lg,14px);box-shadow:none}
.ecgc .recent{padding:14px 16px}
.ecgc .rc-t,.ecgc .cbar label{font-size:12px;font-weight:600;letter-spacing:0;text-transform:none;color:var(--text2)}
.ecgc .rc-t{margin-bottom:8px;font-family:var(--font-d);font-size:var(--t-md);color:var(--text)}
.ecgc .rc-i{border-radius:10px;padding:8px 12px}
.ecgc .cbar{padding:10px 14px;gap:10px}
.ecgc .fsel{height:36px;padding:0 10px;border-radius:8px;font-size:13px;background:var(--surface)}
.ecgc .vbtn,.ecgc .mine-btn{text-transform:none;letter-spacing:0;font-size:12.5px;padding:0 12px;height:34px}
.ecgc .vbtn.on{background:var(--green);color:#fff}
.ecgc .vtgl{border-radius:8px}
.ecgc .map-wrap{background:var(--surface2)}
.ecgc .zbtn{width:30px;height:30px;border-radius:8px}
.ecgc .zbtn:hover{background:var(--green);border-color:var(--green)}
.ecgc thead th{font-size:11.5px;font-weight:600;letter-spacing:0;text-transform:none;color:var(--text3);background:var(--surface2)}
.ecgc tbody tr:hover td{background:var(--green-tint)}
.ecgc .ccard:hover{border-color:var(--green);transform:none}
.ecgc .map-tip{background:var(--text);border-radius:10px}
/* Profile panel */
.ecgc .overlay{background:rgba(15,25,20,.45)}
.ecgc .pcname{font-family:var(--font-d);font-weight:600;font-size:1.6rem}
.ecgc .stitle{font-size:12px;font-weight:600;letter-spacing:0;text-transform:none;color:var(--text2)}
.ecgc .icard,.ecgc .pay-box{border-radius:10px}
.ecgc .trk:hover{background:var(--green-tint)}
/* Footer of the tool: the site's green band instead of navy */
.ecgc .ecgc-cta{background:var(--green);color:rgba(255,255,255,.9);border-radius:var(--rad-lg,14px);padding:18px 22px;font-size:var(--t-sm)}
.ecgc .ecgc-foot p{color:var(--text3)}
@media(max-width:640px){
  .ecgc .cbar{display:grid;grid-template-columns:auto 1fr;align-items:center;gap:8px 12px}
  .ecgc .fsep{display:none}
  .ecgc .vtgl,.ecgc .mine-btn{grid-column:1/-1;justify-self:start;margin-left:0}
}
/* 1.13.1: long histories fold after five changes */
.ecgc .hist-more{display:none}
.ecgc .hist-open .hist-more{display:flex}
.ecgc .hist-all{margin-top:8px;border:0;background:none;padding:4px 0;font:inherit;font-size:12.5px;font-weight:600;color:var(--teal);cursor:pointer;text-decoration:underline;text-underline-offset:2px}

/* Exporter dashboard (/dashboard) and its setup page (/dashboard/setup).
 * Built on the v4 design tokens (colours follow Admin → Appearance). */

/* ── Rating and cover badges (shared with admin) ── */
.em-rb{display:inline-flex;align-items:center;justify-content:center;min-width:30px;padding:2px 7px;border-radius:999px;font-family:var(--font-m);font-size:12px;font-weight:600;border:1px solid;line-height:1.4}
.em-rb-A1{background:#F0FDF4;color:#15803D;border-color:#BBF7D0}
.em-rb-A2{background:#F7FEE7;color:#4D7C0F;border-color:#C6EF6E}
.em-rb-B1{background:#FEFCE8;color:#A16207;border-color:#FDE870}
.em-rb-B2{background:#FFFBEB;color:#B45309;border-color:#FCCD6A}
.em-rb-C1{background:#FFF7ED;color:#C2410C;border-color:#FDCB9A}
.em-rb-C2{background:#FEF2F2;color:#B91C1C;border-color:#FECACA}
.em-rb-D{background:#FEF2F2;color:#7F1D1D;border-color:#FCA5A5}
.em-cv{font-size:11px;font-weight:600;padding:2px 8px;border-radius:999px;white-space:nowrap}
.em-cv-OC{background:#F0FDF4;color:#15803D}
.em-cv-RC1{background:#FFFBEB;color:#92400E}
.em-cv-RC2{background:#FFF7ED;color:#9A3412}
.em-cv-OFF{background:#FEF2F2;color:#991B1B}

/* ── Page frame ── */
.v4 .v4-wrap.em{padding-top:var(--s6);padding-bottom:var(--s8)}
.em-head{display:flex;justify-content:space-between;align-items:flex-end;gap:var(--s4);flex-wrap:wrap;margin-bottom:var(--s5)}
.em-head .v4-sub{margin:0}
.em-head-acts{display:flex;gap:var(--s2);flex-wrap:wrap}
.em-muted{color:var(--text3)}
.em-small{font-size:var(--t-xs)}

/* ── Attention strip ── */
.em-attn{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:var(--s3);margin-bottom:var(--s5)}
.em-tile{display:flex;gap:var(--s3);align-items:flex-start;padding:var(--s4);border-radius:var(--rad-lg);border:1px solid var(--line);background:var(--surface);text-decoration:none;color:var(--text)}
a.em-tile:hover{border-color:var(--green)}
.em-tile-i{font-size:20px;line-height:1.2}
.em-tile-n{font-family:var(--font-d);font-size:var(--t-lg);font-weight:700;line-height:1.25}
.em-tile-s{font-size:var(--t-xs);color:var(--text3);margin-top:2px}
.em-tile.is-red{background:#FEF2F2;border-color:#FECACA}
.em-tile.is-amber{background:#FFFBEB;border-color:#FDE68A}
.em-tile.is-calm{background:var(--surface2)}

/* ── Two columns ── */
.em-grid{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(0,1fr);gap:var(--s5);align-items:start}
@media(max-width:900px){.em-grid{grid-template-columns:1fr}}
.em-col{display:flex;flex-direction:column;gap:var(--s5);min-width:0}
.em-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s4) var(--s5)}
@media(max-width:600px){.em-card{padding:var(--s4)}}
.em-card-h{display:flex;justify-content:space-between;align-items:baseline;gap:var(--s3);margin-bottom:var(--s3)}
.em-card-h h2{font-family:var(--font-d);font-size:var(--t-lg);font-weight:700;margin:0;color:var(--text)}
.em-card-h a,.em-card-h summary{font-size:var(--t-xs);color:var(--green-h,var(--green));text-decoration:none;font-weight:600;cursor:pointer}
.em-none{font-size:var(--t-sm);color:var(--text3);padding:var(--s2) 0}

/* ── Feed ── */
.em-feed{display:flex;flex-direction:column}
.em-item{display:flex;gap:var(--s3);padding:var(--s3) 0;border-top:1px solid var(--line);position:relative;scroll-margin-top:90px}
.em-item:first-child{border-top:0;padding-top:0}
.em-item-i{flex:0 0 36px;height:36px;border-radius:10px;background:var(--surface2);display:flex;align-items:center;justify-content:center;font-size:18px}
.em-item-i.is-down{background:#FEF2F2}
.em-item-i.is-up{background:#F0FDF4}
.em-item-b{flex:1;min-width:0}
.em-item-t{font-weight:600;font-size:var(--t-sm);line-height:1.4;color:var(--text)}
.em-item-t a{color:inherit}
.em-item-s{font-size:var(--t-sm);color:var(--text2);margin-top:2px;line-height:1.55}
.em-item-m{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin-top:6px;font-size:var(--t-xs);color:var(--text3)}
.em-item-m a{color:var(--green-h,var(--green))}
.em-new{display:inline-block;font-family:var(--font-m);font-size:10px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:#fff;background:var(--green);border-radius:4px;padding:1px 5px;margin-right:4px;vertical-align:1px}
.em-kind{font-family:var(--font-m);font-size:10px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;color:var(--text3)}
.em-why{display:inline-flex;align-items:center;gap:4px;padding:1px 8px;border-radius:999px;background:var(--surface2);border:1px solid var(--line);color:var(--text2);font-size:11px;white-space:nowrap;max-width:100%;overflow:hidden;text-overflow:ellipsis}
.em-act{display:inline-flex;align-items:center;gap:4px;padding:1px 8px;border-radius:999px;background:#FFFBEB;border:1px solid #FDE68A;color:#92400E;font-size:11px;font-weight:600}
.em-advice{margin-top:6px;padding:8px 10px;border-radius:8px;background:var(--surface2);font-size:var(--t-xs);color:var(--text2);line-height:1.55}
.em-item details{margin-top:6px}
.em-item details summary{cursor:pointer;font-size:var(--t-xs);color:var(--green-h,var(--green));font-weight:600}
.em-item details div{font-size:var(--t-sm);color:var(--text2);line-height:1.65;margin-top:6px;white-space:pre-line}

/* ── Due soon ── */
.em-due{display:flex;flex-direction:column}
.em-due-r{display:flex;align-items:center;gap:var(--s3);padding:9px 0;border-top:1px solid var(--line)}
.em-due-r:first-child{border-top:0;padding-top:0}
.em-due-d{flex:0 0 52px;text-align:center;border-radius:8px;background:var(--surface2);padding:4px 0;line-height:1.1}
.em-due-d b{display:block;font-family:var(--font-d);font-size:18px}
.em-due-d small{font-family:var(--font-m);font-size:10px;text-transform:uppercase;color:var(--text3)}
.em-due-r.is-red .em-due-d{background:#FEF2F2;color:#B91C1C}
.em-due-r.is-amber .em-due-d{background:#FFFBEB;color:#B45309}
.em-due-b{flex:1;min-width:0;font-size:var(--t-sm)}
.em-due-b a{color:var(--text)}
.em-due-b small{display:block;color:var(--text3);font-size:var(--t-xs)}
.em-x{border:0;background:none;color:var(--text4);cursor:pointer;font-size:16px;padding:2px 6px;border-radius:6px}
.em-x:hover{background:var(--surface2);color:var(--err,#B91C1C)}
.em-add{margin-top:var(--s3);border-top:1px dashed var(--line2);padding-top:var(--s3)}
.em-add summary{font-size:var(--t-xs);font-weight:600;color:var(--green-h,var(--green));cursor:pointer}
.em-add form{display:grid;grid-template-columns:1fr auto;gap:var(--s2);margin-top:var(--s2)}
.em-add input[type=text]{grid-column:1/-1}
.em-add input{font-size:var(--t-md);padding:8px 10px;border:1.5px solid var(--line2);border-radius:var(--rad-sm);background:var(--bg);color:var(--text);min-width:0}

/* ── Markets ── */
.em-mkts{display:flex;flex-direction:column}
.em-mkt{display:flex;align-items:center;gap:var(--s2);padding:8px 0;border-top:1px solid var(--line);font-size:var(--t-sm);text-decoration:none;color:var(--text)}
.em-mkt:first-child{border-top:0;padding-top:0}
.em-mkt:hover .em-mkt-n{color:var(--green-h,var(--green))}
.em-mkt-f{font-size:18px;width:24px;text-align:center}
.em-mkt-n{flex:1;min-width:0;font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.em-mkt-c{font-family:var(--font-m);font-size:11px}
.em-mkt-c.is-down{color:#B91C1C}
.em-mkt-c.is-up{color:#15803D}

/* ── Products ── */
.em-chips{display:flex;flex-wrap:wrap;gap:6px}
.em-chip{display:inline-flex;align-items:center;gap:6px;padding:4px 10px;border-radius:999px;border:1px solid var(--line2);background:var(--surface);font-size:var(--t-xs);color:var(--text2);max-width:100%}
.em-chip b{font-family:var(--font-m);color:var(--text);font-weight:600}
.em-chip span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}


/* ── Welcome (not set up yet) ── */
.em-welcome{background:linear-gradient(135deg,var(--green) 0%,var(--green-h,var(--green)) 100%);color:#fff;border-radius:var(--rad-lg);padding:var(--s5) var(--s6);margin-bottom:var(--s5)}
.em-welcome h2{font-family:var(--font-d);font-size:var(--t-xl);margin:0 0 var(--s2);color:#fff}
.em-welcome p{color:rgba(255,255,255,.85);margin:0 0 var(--s4);max-width:620px}
.em-welcome ol{margin:0 0 var(--s4);padding-left:1.2em;color:rgba(255,255,255,.9);font-size:var(--t-sm);line-height:1.8}
.em-welcome .v4-btn{background:#fff;color:var(--green);border-color:#fff}
@media(max-width:600px){.em-welcome{padding:var(--s4)}}

/* ── Setup page ── */
.em-setup{max-width:760px;margin:0 auto}
.em-step{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s5);margin-bottom:var(--s4)}
@media(max-width:600px){.em-step{padding:var(--s4)}}
.em-step-h{display:flex;gap:var(--s3);align-items:flex-start;margin-bottom:var(--s3)}
.em-step-n{flex:0 0 28px;height:28px;border-radius:50%;background:var(--green);color:#fff;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:13px}
.em-step-h h2{font-family:var(--font-d);font-size:var(--t-lg);margin:0;color:var(--text)}
.em-step-h p{margin:2px 0 0;font-size:var(--t-sm);color:var(--text3)}
.em-picker{position:relative}
.em-picker input[type=search]{width:100%;font-size:var(--t-md);padding:10px 12px;border:1.5px solid var(--line2);border-radius:var(--rad);background:var(--bg);color:var(--text)}
.em-picker input[type=search]:focus{outline:none;border-color:var(--green)}
.em-results{position:absolute;left:0;right:0;top:100%;margin-top:4px;background:var(--surface);border:1px solid var(--line2);border-radius:var(--rad);box-shadow:0 10px 30px rgba(15,23,42,.12);max-height:320px;overflow-y:auto;z-index:50;display:none}
.em-results.on{display:block}
.em-res{display:flex;gap:10px;width:100%;text-align:left;padding:9px 12px;border:0;border-bottom:1px solid var(--line);background:none;cursor:pointer;font:inherit;font-size:var(--t-sm);color:var(--text)}
.em-res:last-child{border-bottom:0}
.em-res:hover,.em-res.is-active{background:var(--surface2)}
.em-res b{font-family:var(--font-m);flex:0 0 auto}
.em-res small{display:block;color:var(--text3);font-size:11px}
.em-res-empty{padding:10px 12px;font-size:var(--t-sm);color:var(--text3)}
.em-selected{display:flex;flex-wrap:wrap;gap:6px;margin-top:var(--s3);min-height:4px}
.em-sel{display:inline-flex;align-items:center;gap:6px;padding:4px 4px 4px 10px;border-radius:999px;background:var(--green-tint,#EEF3FB);border:1px solid var(--green-ring,#C9D6EE);font-size:var(--t-xs);color:var(--text);max-width:100%}
.em-sel b{font-family:var(--font-m)}
.em-sel span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;max-width:260px}
.em-sel button{border:0;background:rgba(0,0,0,.06);border-radius:50%;width:20px;height:20px;cursor:pointer;font-size:12px;line-height:1;color:var(--text2);flex-shrink:0}
.em-quick{display:flex;flex-wrap:wrap;gap:6px;margin-top:var(--s3)}
.em-quick span{font-size:var(--t-xs);color:var(--text3);align-self:center;margin-right:2px}
.em-q{padding:4px 10px;border-radius:999px;border:1px dashed var(--line2);background:none;font:inherit;font-size:var(--t-xs);color:var(--text2);cursor:pointer}
.em-q:hover{border-color:var(--green);color:var(--green)}
.em-q[disabled]{opacity:.35;cursor:default}
.em-form2{display:grid;grid-template-columns:1fr 1fr;gap:var(--s3)}
@media(max-width:600px){.em-form2{grid-template-columns:1fr}}
.em-save{position:sticky;bottom:0;background:linear-gradient(to top,var(--bg) 70%,transparent);padding:var(--s4) 0;display:flex;justify-content:flex-end;gap:var(--s2);align-items:center}

/* The v4 field rule sizes text, select, textarea and file inputs only. */
.v4 .v4-field input[type=date],.v4 .v4-field input[type=url],.v4 .v4-field input[type=email],
.v4 .v4-field input[type=number]{width:100%;box-sizing:border-box;border:1px solid var(--line2);border-radius:var(--rad);
  background:var(--surface);padding:var(--s3);font-family:var(--font-b);font-size:var(--t-md);color:var(--text)}

/* Compact dashboard (1.9.2): tools strip, one "What you follow" card, buyer desk inside Due soon */
.em-tools{display:flex;flex-wrap:wrap;gap:8px;margin:0 0 var(--s4)}
.em-tools a{display:inline-flex;align-items:center;gap:7px;height:36px;padding:0 13px;border:1px solid var(--line);border-radius:999px;background:var(--surface);color:var(--text2);font-size:var(--t-xs);font-weight:600;text-decoration:none;white-space:nowrap}
.em-tools a svg{color:var(--green);flex:none}
.em-tools a:hover{border-color:var(--green);color:var(--text)}
.em-sub{font-size:var(--t-xs);font-weight:600;color:var(--text3);margin:var(--s3) 0 6px}
.em-card-h + .em-sub{margin-top:0}
.em-desk{display:flex;gap:12px;align-items:center;margin-top:var(--s3);padding:12px;border:1px solid var(--line);border-radius:12px;background:var(--surface2);color:var(--text);text-decoration:none}
.em-desk:hover{border-color:var(--green)}
.em-desk-i{flex:none;width:34px;height:34px;border-radius:9px;display:grid;place-items:center;background:var(--green-tint);color:var(--green)}
.em-desk b{display:block;font-size:var(--t-sm)}
.em-desk small{display:block;font-size:var(--t-xs);color:var(--text3)}
.em-desk em{font-style:normal;font-weight:600;color:var(--err)}

/* Onboarding (1.9.2) */
.em-save [hidden],.em-step[hidden],.em-prog[hidden]{display:none!important}
.em-prog{list-style:none;margin:var(--s5) 0 0;padding:0;display:grid;grid-template-columns:repeat(4,1fr);gap:6px;counter-reset:st}
.em-prog li{counter-increment:st;font-size:var(--t-xs);color:var(--text3);padding-top:10px;border-top:3px solid var(--line)}
.em-prog li::before{content:counter(st) ". "}
.em-prog li.is-on{color:var(--text);font-weight:600;border-top-color:var(--green)}
.em-prog li.is-done{color:var(--text2);border-top-color:var(--green-ring)}
@media(max-width:560px){.em-prog li{font-size:0}.em-prog li::before{font-size:11px}.em-prog li.is-on{font-size:11px}}
.em-types{border:0;margin:var(--s4) 0;padding:0}
.em-types legend{font-size:var(--t-sm);font-weight:600;color:var(--text);margin-bottom:8px;padding:0}
.em-types{display:flex;flex-wrap:wrap;gap:8px}
.em-type{position:relative;cursor:pointer}
.em-type input{position:absolute;opacity:0;pointer-events:none}
.em-type span{display:inline-flex;align-items:center;height:40px;padding:0 14px;border:1.5px solid var(--line2);border-radius:999px;background:var(--surface);font-size:var(--t-sm);color:var(--text2)}
.em-type input:checked + span{border-color:var(--green);background:var(--green-tint);color:var(--text);font-weight:600}
.em-type input:focus-visible + span{outline:2px solid var(--green);outline-offset:2px}
.em-back{height:44px;padding:0 18px;border:1px solid var(--line2);border-radius:var(--rad);background:var(--surface);font:inherit;font-weight:600;color:var(--text2);cursor:pointer;margin-right:auto}
.em-step h2:focus{outline:none}
.em-tools-more{display:none;height:36px;padding:0 13px;border:1.5px dashed var(--green);border-radius:999px;background:var(--surface);color:var(--green-h,var(--green));font:inherit;font-size:var(--t-xs);font-weight:700;cursor:pointer;white-space:nowrap}
.em-item-t a{color:inherit;text-decoration:none}
.em-item-t a:hover{text-decoration:underline;text-underline-offset:3px}
.em-desk + .em-desk{margin-top:8px}

@media(max-width:640px){.em-tools a.is-extra{display:none}.em-tools.is-open a.is-extra{display:inline-flex}.em-tools-more{display:inline-flex;align-items:center}}

/* Knowledge base (/docs, /docs-category/…, /docs/…) and app pages. */
.v4 .v4-wrap.kb{padding-top:var(--s5);padding-bottom:var(--s8)}
.kb-hero{max-width:760px;margin:var(--s4) auto var(--s6);text-align:center}
.kb-hero .v4-sub{margin-left:auto;margin-right:auto}
.kb-search{display:flex;gap:8px;margin:var(--s4) 0}
.kb-search input{flex:1;min-width:0;font-size:var(--t-md);padding:10px 14px;border:1.5px solid var(--line2);border-radius:var(--rad);background:var(--surface);color:var(--text)}
.kb-search input:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.kb-search button{padding:0 18px;border:0;border-radius:var(--rad);background:var(--green);color:#fff;font:inherit;font-weight:600;cursor:pointer}
.kb-search.is-large input{padding:14px 18px}
.kb-crumbs{font-size:var(--t-xs);color:var(--text3);margin-bottom:var(--s3);display:flex;flex-wrap:wrap;gap:4px;align-items:center}
.kb-crumbs a{color:var(--green-h,var(--green));text-decoration:none}
.kb-crumbs span:last-child{color:var(--text2)}
.kb-count{font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3);margin:var(--s2) 0 var(--s3)}
.kb-none{color:var(--text3);padding:var(--s4) 0}
.kb-draft{background:#FFFBEB;border:1px solid #FDE68A;color:#92400E;padding:6px 10px;border-radius:8px;font-size:var(--t-xs)}

/* Index: topic cards */
.kb-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(300px,1fr));gap:var(--s4)}
.kb-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s4) var(--s5);display:flex;flex-direction:column}
.kb-card h2,.kb-section h2{font-family:var(--font-d);font-size:var(--t-lg);margin:0 0 var(--s2);display:flex;justify-content:space-between;align-items:baseline;gap:8px}
.kb-card h2 a,.kb-section h2 a{color:var(--text);text-decoration:none}
.kb-card h2 a:hover,.kb-section h2 a:hover{color:var(--green)}
.kb-card h2 span,.kb-section h2 span{font-family:var(--font-m);font-size:11px;font-weight:600;color:var(--text3);background:var(--surface2);border-radius:999px;padding:1px 8px}
.kb-card ul{list-style:none;margin:0 0 var(--s2);padding:0}
.kb-card li{border-top:1px solid var(--line)}
.kb-card li:first-child{border-top:0}
.kb-card li a{display:block;padding:7px 0;color:var(--text2);text-decoration:none;font-size:var(--t-sm);line-height:1.4}
.kb-card li a:hover{color:var(--green)}
.kb-sub{display:flex;justify-content:space-between;gap:8px;padding:7px 10px;margin-top:6px;border-radius:8px;background:var(--surface2);color:var(--text);text-decoration:none;font-size:var(--t-sm);font-weight:600}
.kb-sub:hover{background:var(--green-tint)}
.kb-sub span:last-child{font-family:var(--font-m);font-size:11px;color:var(--text3)}
.kb-more{margin-top:auto;padding-top:var(--s2);font-size:var(--t-xs);font-weight:700;color:var(--green-h,var(--green));text-decoration:none}

/* Lists and results */
.kb-list,.kb-results{display:flex;flex-direction:column;gap:var(--s2)}
.kb-result{display:block;padding:12px 16px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad);text-decoration:none;color:var(--text)}
.kb-result:hover{border-color:var(--green)}
.kb-result b{display:block;font-size:var(--t-base);line-height:1.35}
.kb-result small{display:block;font-family:var(--font-m);font-size:11px;color:var(--text3);margin-top:2px}
.kb-result span{display:block;font-size:var(--t-sm);color:var(--text2);margin-top:4px;line-height:1.5}
.kb-section{margin-top:var(--s6)}

/* Article */
.kb-doc{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:var(--s6);align-items:start}
@media(max-width:920px){.kb-doc{grid-template-columns:1fr}}
.kb-main{min-width:0;max-width:760px}
.kb-meta{font-family:var(--font-m);font-size:var(--t-xs);color:var(--text3);margin:0 0 var(--s4)}
.kb-meta a{color:var(--green)}
.kb-body{font-size:var(--t-base);line-height:1.75}
.kb-body table{width:100%;border-collapse:collapse;margin:var(--s4) 0;font-size:var(--t-sm)}
@media(max-width:700px){.kb-body table{display:block;overflow-x:auto;-webkit-overflow-scrolling:touch;background:linear-gradient(to right,var(--bg) 30%,transparent) left center/40px 100% no-repeat local,linear-gradient(to left,var(--bg) 30%,transparent) right center/40px 100% no-repeat local,radial-gradient(farthest-side at 0 50%,rgba(0,0,0,.14),transparent) left center/12px 100% no-repeat scroll,radial-gradient(farthest-side at 100% 50%,rgba(0,0,0,.14),transparent) right center/12px 100% no-repeat scroll}.kb-body td,.kb-body th{min-width:96px}}
.kb-body th,.kb-body td{border:1px solid var(--line2);padding:8px 10px;text-align:left;vertical-align:top}
.kb-body th{background:var(--surface2);font-weight:700}
.kb-body img{max-width:100%;height:auto;border-radius:8px}
.kb-body iframe{max-width:100%}
.kb-foot{margin-top:var(--s6);padding:var(--s3) var(--s4);background:var(--surface2);border-radius:var(--rad);font-size:var(--t-sm);color:var(--text2)}
.kb-foot a{color:var(--green);font-weight:600}
.kb-related{margin-top:var(--s6)}
.kb-related h2{font-family:var(--font-d);font-size:var(--t-lg);margin:0 0 var(--s3)}
.kb-side{position:sticky;top:84px;display:flex;flex-direction:column;gap:var(--s4)}
@media(max-width:920px){.kb-side{position:static}}
.kb-side .kb-search{margin:0}
.kb-toc{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s3) var(--s4)}
.kb-toc h2{font-family:var(--font-m);font-size:11px;letter-spacing:.06em;text-transform:uppercase;margin:0 0 6px}
.kb-toc h2 a{color:var(--text3);text-decoration:none}
.kb-toc ul{list-style:none;margin:0;padding:0;max-height:60vh;overflow:auto}
.kb-toc li a{display:block;padding:6px 8px;border-radius:6px;color:var(--text2);text-decoration:none;font-size:var(--t-sm);line-height:1.4}
.kb-toc li a:hover{background:var(--surface2)}
.kb-toc li a.is-on{background:var(--green-tint);color:var(--green-h,var(--green));font-weight:600}
.kb-cta{display:block;padding:var(--s4);border-radius:var(--rad-lg);background:linear-gradient(135deg,#0B1F3A,#0C5F72);color:rgba(255,255,255,.85);text-decoration:none;font-size:var(--t-sm);line-height:1.5}
.kb-cta b{display:block;color:#fff;font-size:var(--t-base);margin-bottom:4px}

/* App pages: the frame fills the width and grows to the app's height. */
.app-page{background:var(--bg)}
.app-frame{display:block;width:100%;height:70vh;border:0;background:transparent}

/* ── Admin: category manager (Docs and Downloads) ─────────────────────── */
.cm-top{display:flex;justify-content:space-between;align-items:flex-start;gap:16px;flex-wrap:wrap;margin-bottom:16px}
.cm-top-acts{display:flex;gap:8px}
.cm-total{font-family:var(--font-m);font-size:12px;font-weight:600;color:var(--text3);background:var(--surface2);border-radius:999px;padding:2px 9px;vertical-align:middle}
.cm-intro{font-size:13px;color:var(--text3);margin:6px 0 0;max-width:640px}
.cm-list{background:var(--surface);border:1px solid var(--line);border-radius:14px;overflow:hidden}
.cm-empty{padding:28px;text-align:center;color:var(--text3);margin:0}
.cm-item{border-top:1px solid var(--line)}
.cm-list>.cm-item:first-child{border-top:0}
.cm-item .cm-item{border-top:1px solid var(--line)}
.cm-row{display:flex;align-items:center;gap:12px;padding:11px 16px 11px calc(16px + var(--depth,0) * 30px);min-height:58px}
.cm-row:hover{background:var(--surface2)}
.cm-grip{width:18px;text-align:center;color:var(--text4);font-size:14px;flex-shrink:0}
.cm-main{flex:1;min-width:0;display:flex;flex-direction:column;gap:1px}
.cm-main b{font-size:14px;color:var(--text);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cm-slug{font-family:var(--font-m);font-size:11px;color:var(--text4);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cm-count{font-family:var(--font-m);font-size:11px;font-weight:600;color:var(--green-h,var(--green));background:var(--green-tint);border-radius:999px;padding:3px 10px;white-space:nowrap;flex-shrink:0}
.cm-count.is-zero{color:var(--text4);background:var(--surface2)}
.cm-acts{display:flex;align-items:center;gap:6px;flex-shrink:0}
.cm-acts form{display:flex;gap:2px}
.cm-ico{width:30px;height:30px;border:1px solid var(--line);border-radius:8px;background:var(--surface);color:var(--text2);cursor:pointer;font-size:14px;line-height:1}
.cm-ico:hover:not([disabled]){border-color:var(--green);color:var(--green)}
.cm-ico[disabled]{opacity:.3;cursor:default}
.cm-btn{height:30px;padding:0 12px;border:1px solid var(--line2);border-radius:8px;background:var(--surface);color:var(--text);font:inherit;font-size:12px;font-weight:600;cursor:pointer}
.cm-btn:hover{border-color:var(--green);color:var(--green)}
.cm-edit{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:12px;padding:14px 16px 16px calc(46px + var(--depth,0) * 30px);background:var(--surface2);border-top:1px dashed var(--line2)}
.cm-edit[hidden]{display:none}
.cm-edit label{display:flex;flex-direction:column;gap:4px;min-width:0}
.cm-edit label>span{font-family:var(--font-m);font-size:10px;letter-spacing:.07em;text-transform:uppercase;color:var(--text3)}
.cm-edit label>span small{text-transform:none;letter-spacing:0}
.cm-edit input,.cm-edit select{width:100%;box-sizing:border-box;padding:8px 10px;border:1.5px solid var(--line2);border-radius:8px;background:var(--surface);color:var(--text);font:inherit;font-size:14px}
.cm-edit input:focus,.cm-edit select:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.cm-wide{grid-column:1/-1}
.cm-edit-acts{grid-column:1/-1;display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.cm-del{margin-left:auto;border:0;background:none;color:var(--err,#B91C1C);font:inherit;font-size:12px;font-weight:600;cursor:pointer;padding:6px 8px;border-radius:6px}
.cm-del:hover{background:rgba(185,28,28,.08)}
.cm-note{margin-left:auto;font-size:12px;color:var(--text4)}
.cm-new{border:1px solid var(--line);border-radius:14px;margin-bottom:14px;padding-left:16px}
@media(max-width:760px){.cm-edit{grid-template-columns:1fr;padding-left:16px}.cm-row{flex-wrap:wrap}.cm-main{flex-basis:60%}}

/* ── Downloads ─────────────────────────────────────────────────────────── */
.v4 .v4-wrap.dl{padding-top:var(--s5);padding-bottom:var(--s8)}
.dl-head{display:flex;justify-content:space-between;align-items:flex-end;gap:var(--s4);flex-wrap:wrap;margin-bottom:var(--s4)}
.dl-head .kb-search{margin:0;min-width:min(360px,100%)}
.dl-type{display:inline-flex;align-items:center;justify-content:center;min-width:44px;height:28px;padding:0 6px;border-radius:6px;font-family:var(--font-m);font-size:10px;font-weight:700;letter-spacing:.04em;flex-shrink:0;background:#EEF2F6;color:#475569}
.dl-type-pdf{background:#FEF2F2;color:#B91C1C}
.dl-type-xls{background:#F0FDF4;color:#15803D}
.dl-type-doc{background:#EFF6FF;color:#1D4ED8}
.dl-type-ppt{background:#FFF7ED;color:#C2410C}
.dl-btn{display:inline-flex;align-items:center;gap:6px;padding:8px 14px;border-radius:var(--rad);background:var(--green);color:#fff;text-decoration:none;font-weight:600;font-size:var(--t-sm);white-space:nowrap}
.dl-btn:hover{background:var(--green-h,var(--green))}
.dl-btn.is-locked{background:var(--surface);color:var(--green-h,var(--green));border:1.5px solid var(--green-ring,var(--line2))}
.dl-btn.is-large{padding:12px 20px;font-size:var(--t-base)}
.dl-link{color:var(--green-h,var(--green));font-weight:600;font-size:var(--t-sm);text-decoration:none}
.dl-gate{display:flex;justify-content:space-between;align-items:center;gap:var(--s4);flex-wrap:wrap;padding:var(--s4) var(--s5);border-radius:var(--rad-lg);background:linear-gradient(135deg,#0B1F3A,#0C5F72);color:rgba(255,255,255,.85);font-size:var(--t-sm);margin-bottom:var(--s4)}
.dl-gate b{color:#fff}
.dl-gate>div:first-child{flex:1;min-width:240px}
.dl-gate-acts{display:flex;align-items:center;gap:var(--s3)}
.dl-gate .dl-btn{background:#fff;color:#0B1F3A}
.dl-gate .dl-link{color:#fff}
.dl-cats{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:var(--s4)}
.dl-cats a{padding:6px 12px;border-radius:999px;border:1px solid var(--line2);background:var(--surface);color:var(--text2);text-decoration:none;font-size:var(--t-sm)}
.dl-cats a span{font-family:var(--font-m);font-size:11px;color:var(--text4);margin-left:2px}
.dl-cats a.is-on{background:var(--green);border-color:var(--green);color:#fff}
.dl-cats a.is-on span{color:rgba(255,255,255,.75)}
.dl-pin{display:flex;justify-content:space-between;align-items:center;gap:var(--s4);flex-wrap:wrap;padding:var(--s5);margin-bottom:var(--s4);border-radius:var(--rad-lg);border:1.5px solid var(--green-ring,var(--line2));background:var(--green-tint)}
.dl-pin-b{flex:1;min-width:240px}
.dl-pin-t{font-family:var(--font-m);font-size:11px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--green-h,var(--green));margin:0 0 4px}
.dl-pin h2{font-family:var(--font-d);font-size:var(--t-xl);margin:0 0 6px;line-height:1.25}
.dl-pin h2 a{color:var(--text);text-decoration:none}
.dl-pin p{margin:0 0 6px;color:var(--text2);font-size:var(--t-sm)}
.dl-list{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.dl-row{display:flex;align-items:center;gap:var(--s4);padding:14px 18px;border-top:1px solid var(--line)}
.dl-row:first-child{border-top:0}
.dl-row-b{flex:1;min-width:0}
.dl-row h2{font-size:var(--t-base);font-weight:600;margin:0;line-height:1.35}
.dl-row h2 a{color:var(--text);text-decoration:none}
.dl-row h2 a:hover{color:var(--green)}
.dl-row p{margin:3px 0 0;font-size:var(--t-sm);color:var(--text2)}
.dl-meta{font-size:var(--t-xs);color:var(--text3);margin-top:4px}
.dl-new{font-family:var(--font-m);font-size:10px;font-weight:700;color:#fff;background:var(--green);border-radius:4px;padding:1px 5px;vertical-align:2px}
@media(max-width:640px){.dl-row{flex-wrap:wrap;padding:14px}.dl-row-a{width:100%;padding-left:60px}.dl-row .dl-btn{padding:6px 12px}}
.dl-one{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:var(--s6);align-items:start}
@media(max-width:920px){.dl-one{grid-template-columns:1fr}}
.dl-one-head{display:flex;align-items:center;gap:var(--s3)}
.dl-one-head .v4-h1{margin:0}
.dl-desc{font-size:var(--t-base);line-height:1.7;color:var(--text2);margin-bottom:var(--s4);max-width:720px}
.dl-one-acts{display:flex;align-items:center;gap:var(--s4);flex-wrap:wrap}
.dl-preview{display:block;width:100%;height:75vh;min-height:420px;margin-top:var(--s5);border:1px solid var(--line);border-radius:var(--rad-lg);background:var(--surface2)}
.dl-side{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s4)}
.dl-side h2{font-family:var(--font-m);font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:var(--text3);margin:0 0 8px}
.dl-side-i{display:flex;gap:10px;align-items:center;padding:8px 0;border-top:1px solid var(--line);text-decoration:none;color:var(--text);font-size:var(--t-sm)}
.dl-side-i:first-of-type{border-top:0}
.dl-side-i small{display:block;color:var(--text4);font-size:11px}
/* admin */
.dl-drop{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:26px;border:2px dashed var(--line2);border-radius:12px;background:var(--surface2);text-align:center;cursor:pointer;font-size:13px;color:var(--text2)}
.dl-single{display:grid;grid-template-columns:1fr;gap:12px;margin-top:14px;padding:14px 16px;border:1px solid var(--line);border-radius:12px;background:var(--surface2)}
.dl-single[hidden]{display:none}
.dl-single .fg{margin:0}
.dl-single input,.dl-single textarea{width:100%}
.dl-drop.is-over{border-color:var(--green);background:var(--green-tint)}
.dl-admin-file{display:flex;gap:12px;align-items:center;padding:10px 12px;background:var(--surface2);border-radius:10px;margin-bottom:12px;font-size:13px}

/* Admin → Downloads → Review dates */
.dl-date-hint{background:#FEF9C3;border-color:#FDE047!important}
mark.dl-date-hint{padding:0 4px;border-radius:3px}
.dl-date-row td{background:#FFFDF0}

/* Downloads: range line and numbered pager */
.dl-range{font-size:var(--t-xs);color:var(--text3);margin:0 0 var(--s2)}
.dl-pager{display:flex;justify-content:space-between;align-items:center;gap:var(--s3);margin-top:var(--s5);flex-wrap:wrap}
.dl-pg-nums{display:flex;gap:4px;align-items:center;flex-wrap:wrap}
.dl-pg{display:inline-flex;align-items:center;justify-content:center;min-width:38px;height:38px;padding:0 10px;border-radius:var(--rad);border:1px solid var(--line2);background:var(--surface);color:var(--text);text-decoration:none;font-size:var(--t-sm);font-weight:600}
a.dl-pg:hover{border-color:var(--green);color:var(--green)}
.dl-pg.is-on{background:var(--green);border-color:var(--green);color:#fff}
.dl-pg.is-off{opacity:.4}
.dl-pg-gap{color:var(--text4);padding:0 2px}
@media(max-width:520px){.dl-pg-nav{flex:1}.dl-pg-nums{order:-1;width:100%;justify-content:center}}
.dl-dupe{font-family:var(--font-m);font-size:10px;font-weight:700;color:#9A3412;background:#FFF7ED;border:1px solid #FED7AA;border-radius:4px;padding:1px 6px;margin-left:4px}

/* Admin → Downloads list: status pills, tabs, bulk bar, danger zone */
.dl-pill{display:inline-block;font-family:var(--font-m);font-size:10px;font-weight:700;letter-spacing:.04em;text-transform:uppercase;border-radius:999px;padding:2px 9px;white-space:nowrap}
.dl-pill.is-live{background:#ECFDF5;color:#047857;border:1px solid #A7F3D0}
.dl-pill.is-draft{background:#F1F5F9;color:#475569;border:1px dashed #94A3B8}
.dl-pill.is-pin{background:var(--green-tint);color:var(--green-h,var(--green));border:1px solid var(--green-ring,var(--line2))}
#dl-table tr.is-draft td{background:repeating-linear-gradient(135deg,transparent 0 10px,rgba(148,163,184,.07) 10px 20px)}
#dl-table tr.is-draft td a{color:var(--text3)!important}
.dl-toolbar{display:flex;justify-content:space-between;align-items:center;gap:10px;flex-wrap:wrap;margin-bottom:10px}
.dl-toolbar input[type=search]{max-width:280px;padding:8px 12px;border:1.5px solid var(--line2);border-radius:8px;background:var(--surface);font:inherit;font-size:13px}
.dl-tabs{display:flex;gap:4px;flex-wrap:wrap}
.dl-tab{padding:6px 12px;border-radius:999px;border:1px solid var(--line2);background:var(--surface);font:inherit;font-size:12px;font-weight:600;color:var(--text2);cursor:pointer}
.dl-tab span{font-family:var(--font-m);font-size:11px;color:var(--text4);margin-left:3px}
.dl-tab.is-on{background:var(--text);border-color:var(--text);color:#fff}
.dl-tab.is-on span{color:rgba(255,255,255,.7)}
.dl-bulkbar{position:sticky;top:70px;z-index:20;display:flex;align-items:center;gap:8px;flex-wrap:wrap;padding:10px 14px;margin-bottom:10px;border-radius:10px;background:var(--text);color:#fff;box-shadow:0 8px 24px rgba(15,23,42,.18)}
.dl-bulkbar[hidden]{display:none}
.dl-bulkbar b{margin-right:6px;font-size:13px}
.dl-bulkbar .btn-ghost{background:rgba(255,255,255,.1);color:#fff;border-color:rgba(255,255,255,.25)}
.dl-bulkbar .dl-link{background:none;border:0;color:rgba(255,255,255,.75);cursor:pointer;margin-left:auto;font:inherit;font-size:12px}
.dl-del-btn{background:#B91C1C;color:#fff;border:1px solid #B91C1C}
.dl-del-btn:hover{background:#991B1B}
.dl-row-del{border:1px solid var(--line);background:var(--surface);border-radius:8px;width:30px;height:30px;cursor:pointer;vertical-align:middle;opacity:.7}
.dl-row-del:hover{opacity:1;border-color:#FCA5A5;background:#FEF2F2}
.dl-danger{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;margin-top:16px;padding:14px 18px;border:1.5px solid #FECACA;border-radius:12px;background:#FEF2F2;font-size:13px;color:#7F1D1D}
.dl-danger small{color:#991B1B;opacity:.8}
.kb-disc{margin-top:var(--s3);font-size:12px;line-height:1.55;color:var(--text3);max-width:680px}

/* Tools (/tools, tool cards everywhere), the HS Code Finder, app page headings
   and the home page. Colours come from the theme's tokens only, so they follow
   Admin → Appearance. Icons are line drawings in currentColor, no emoji. */

/* ── Tool cards ──────────────────────────────────────────────────────────── */
.v4 .v4-wrap.tl-page{padding-top:var(--s6);padding-bottom:var(--s8)}
.tl-page .v4-sub{max-width:60ch;margin-bottom:var(--s5)}
.tl-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(280px,1fr));gap:var(--s3)}
.tl-stack{display:flex;flex-direction:column;gap:var(--s2)}
.tl-card{position:relative;display:flex;align-items:flex-start;gap:14px;padding:18px 20px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);color:var(--text);text-decoration:none;transition:border-color .15s,box-shadow .15s,transform .15s}
a.tl-card:hover{border-color:var(--green);box-shadow:var(--e2)}
a.tl-card:focus-visible{outline:2px solid var(--green);outline-offset:2px}
.tl-ico{flex:none;display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;border-radius:10px;background:var(--green-tint);color:var(--green-h,var(--green))}
.tl-ico.is-xs{width:28px;height:28px;border-radius:7px}
.tl-b{flex:1;min-width:0;display:flex;flex-direction:column;gap:3px}
.tl-b b{font-size:var(--t-base);font-weight:600;line-height:1.3;display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.tl-b small{font-size:var(--t-sm);color:var(--text3);line-height:1.5}
.tl-go{flex:none;align-self:center;color:var(--text4);font-size:18px;transition:transform .15s,color .15s}
a.tl-card:hover .tl-go{color:var(--green);transform:translateX(3px)}
.tl-soon{font-family:var(--font-m);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--text3);background:var(--surface2);border:1px solid var(--line);border-radius:999px;padding:1px 7px}
.tl-card.is-soon{background:var(--surface2);border-style:dashed}
.tl-card.is-soon .tl-ico{background:transparent;border:1px dashed var(--line2);color:var(--text4)}
.tl-card.is-lg{padding:22px 22px 24px;flex-direction:column;gap:16px;min-height:180px}
.tl-card.is-lg .tl-b b{font-family:var(--font-d);font-size:var(--t-lg);font-weight:600}
.tl-card.is-lg .tl-go{position:absolute;right:20px;top:26px}
.tl-card.is-sm{padding:10px 12px;gap:10px;border-radius:var(--rad)}
.tl-card.is-sm .tl-ico{width:34px;height:34px;border-radius:8px}
.tl-card.is-sm .tl-ico svg{width:18px;height:18px}
.tl-card.is-sm .tl-b b{font-size:var(--t-sm)}
.tl-card.is-sm .tl-b small{font-size:var(--t-xs);display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
.tl-card.is-sm .tl-go{font-size:15px}

/* ── App page heading (optional, per app) ────────────────────────────────── */
.ap-head{background:var(--surface);border-bottom:1px solid var(--line)}
.ap-head-in{max-width:1080px;margin:0 auto;padding:var(--s5) var(--s5) var(--s5)}
.ap-head-row{display:flex;gap:16px;align-items:flex-start}
.ap-head .tl-ico{width:48px;height:48px;margin-top:4px}
.ap-head .v4-h1{font-size:var(--t-2xl);margin:0 0 4px}
.ap-head .v4-sub{margin:0;max-width:70ch;font-size:var(--t-base)}
@media(max-width:640px){.ap-head-in{padding:var(--s4) var(--s3)}.ap-head .tl-ico{display:none}}
.ap-opt{display:flex;gap:10px;align-items:flex-start;flex:1;min-width:260px;font-size:13px;cursor:pointer}
.ap-opt input{margin-top:3px;accent-color:var(--green)}
.ap-opt b{display:block;color:var(--text)}
.ap-opt small{display:block;color:var(--text3);line-height:1.45;margin-top:2px}

/* ── HS Code Finder ──────────────────────────────────────────────────────── */
.v4 .v4-wrap.hs{padding-top:var(--s5);padding-bottom:var(--s8)}
.hs-hero{max-width:760px;margin:var(--s2) 0 var(--s5)}
.hs-hero .v4-h1{margin-bottom:var(--s2)}
.hs-hero .v4-sub{font-size:var(--t-base);max-width:62ch}
.hs-code{display:inline-block;flex:none;min-width:3.6em;font-family:var(--font-m);font-size:13px;font-weight:500;letter-spacing:.02em;color:var(--green-h,var(--green));background:var(--green-tint);border-radius:5px;padding:2px 7px;text-align:center;font-variant-numeric:tabular-nums}
.hs-code.is-sub{background:transparent;border:1px solid var(--line);color:var(--text2);min-width:4.8em}
.hs-code.is-big{font-size:40px;font-weight:500;padding:0;background:none;border:0;min-width:0;color:var(--text);letter-spacing:.01em;line-height:1.1}
.hs-results{display:flex;flex-direction:column;gap:var(--s2);margin-bottom:var(--s5)}
.hs-group{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.hs-head{display:flex;gap:14px;align-items:baseline;padding:14px 18px;color:var(--text);text-decoration:none;font-weight:600;line-height:1.45}
.hs-head:hover{background:var(--surface2)}
.hs-head:hover span:last-child{color:var(--green-h,var(--green))}
.hs-subs{list-style:none;margin:0;padding:0 0 6px;border-top:1px solid var(--line)}
.hs-subs li a,.hs-list li a{display:flex;gap:14px;align-items:baseline;padding:8px 18px;color:var(--text2);text-decoration:none;font-size:var(--t-sm);line-height:1.5}
.hs-subs li a:hover,.hs-list li a:hover{background:var(--surface2);color:var(--text)}
.hs-subs li:first-child a{padding-top:10px}
.hs-more a{color:var(--green-h,var(--green))!important;font-weight:600;padding-left:calc(18px + 4.8em + 14px)!important}
.hs-note{margin:var(--s4) 0;padding:14px 18px;border-left:3px solid var(--amber);background:var(--amber-tint);border-radius:0 var(--rad) var(--rad) 0;font-size:var(--t-sm);line-height:1.6;color:var(--text2)}
.hs-note b{color:var(--text)}
.hs-browse{margin-top:var(--s6)}
.hs-browse h2,.hs-h2{font-family:var(--font-d);font-weight:600;font-size:var(--t-lg);margin:0 0 var(--s3);display:flex;align-items:baseline;gap:10px}
.hs-h2{margin-top:var(--s6)}
.hs-h2 span{font-family:var(--font-m);font-size:11px;font-weight:600;color:var(--text3);background:var(--surface2);border:1px solid var(--line);border-radius:999px;padding:1px 8px}
.hs-sec{border-top:1px solid var(--line)}
.hs-sec:last-of-type{border-bottom:1px solid var(--line)}
.hs-sec summary{display:grid;grid-template-columns:44px 1fr auto;gap:12px;align-items:baseline;padding:12px 4px;cursor:pointer;list-style:none;font-size:var(--t-base);color:var(--text);line-height:1.4}
.hs-sec summary::-webkit-details-marker{display:none}
.hs-sec summary:hover{color:var(--green-h,var(--green))}
.hs-sec summary small{font-family:var(--font-m);font-size:11px;color:var(--text3);white-space:nowrap}
.hs-sec summary small::after{content:"+";display:inline-block;width:16px;margin-left:10px;text-align:center;font-size:15px;color:var(--text3)}
.hs-sec[open] summary small::after{content:"−"}
.hs-roman{font-family:var(--font-m);font-size:12px;font-weight:600;color:var(--text3)}
.hs-sec ul{list-style:none;margin:0 0 var(--s3);padding:0 0 0 44px}
.hs-sec li a{display:flex;gap:14px;align-items:baseline;padding:6px 8px;border-radius:6px;color:var(--text2);text-decoration:none;font-size:var(--t-sm);line-height:1.45}
.hs-sec li a:hover{background:var(--surface);color:var(--text)}
@media(max-width:640px){.hs-sec ul{padding-left:0}.hs-sec summary{grid-template-columns:34px 1fr}.hs-sec summary small{display:none}}
.hs-src{margin-top:var(--s6);font-size:var(--t-xs);color:var(--text3)}

.hs-one{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:var(--s6);align-items:start;margin-top:var(--s3)}
@media(max-width:920px){.hs-one{grid-template-columns:1fr}}
.hs-one-main{min-width:0}
.hs-kicker{font-family:var(--font-m);font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--text3);margin:0 0 6px}
.hs-title{margin:0 0 var(--s2)}
.hs-desc{font-size:var(--t-lg);line-height:1.55;color:var(--text2);margin:0 0 var(--s4);max-width:65ch}
.hs-acts{display:flex;gap:10px;flex-wrap:wrap;align-items:center;margin-bottom:var(--s5)}
.hs-copy,.hs-add{display:inline-flex;align-items:center;gap:6px;height:38px;padding:0 16px;border-radius:var(--rad);font:inherit;font-size:var(--t-sm);font-weight:600;cursor:pointer;text-decoration:none;white-space:nowrap}
.hs-copy{background:var(--green);color:#fff;border:1px solid var(--green)}
.hs-copy:hover{background:var(--green-h,var(--green))}
.hs-add{background:var(--surface);color:var(--text);border:1px solid var(--line2)}
.hs-add:hover{border-color:var(--green);color:var(--green-h,var(--green))}
.hs-add.is-on{cursor:default;color:var(--ok);background:var(--ok-bg);border-color:transparent}
.hs-path{border:1px solid var(--line);border-radius:var(--rad-lg);background:var(--surface);padding:6px 0;margin-bottom:var(--s4)}
.hs-path div{display:flex;gap:12px;align-items:baseline;padding:8px 18px;font-size:var(--t-sm);color:var(--text2);line-height:1.5}
.hs-path .is-2{padding-left:38px}
.hs-path .is-3{padding-left:58px;color:var(--text)}
.hs-list{list-style:none;margin:0;padding:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.hs-list li+li{border-top:1px solid var(--line)}
.hs-list li a{padding:10px 18px}
.hs-side{position:sticky;top:84px;display:flex;flex-direction:column;gap:var(--s4)}
.hs-side .kb-search{margin:0}
@media(max-width:920px){.hs-side{position:static}}
@media(max-width:640px){.hs-code.is-big{font-size:32px}.hs-desc{font-size:var(--t-base)}.hs-path .is-2{padding-left:18px}.hs-path .is-3{padding-left:18px}.hs-path div,.hs-subs li a,.hs-list li a,.hs-head{flex-direction:column;gap:4px}.hs-more a{padding-left:18px!important}}

/* ── Home page ───────────────────────────────────────────────────────────── */
.hm-hero{background:var(--surface);border-bottom:1px solid var(--line)}
.hm-hero-in{display:grid;grid-template-columns:minmax(0,1.15fr) minmax(0,1fr);gap:var(--s7);align-items:center;padding-top:var(--s8)!important;padding-bottom:var(--s8)!important}
@media(max-width:900px){.hm-hero-in{grid-template-columns:1fr;gap:var(--s6);padding-top:var(--s6)!important;padding-bottom:var(--s6)!important}}
.hm-eyebrow,.hm-kicker{font-family:var(--font-m);font-size:11px;font-weight:600;letter-spacing:.1em;text-transform:uppercase;color:var(--green-h,var(--green));margin:0 0 var(--s3)}
.hm-kicker{margin:0 0 4px;color:var(--text3)}
.hm-h1{font-family:var(--font-d);font-weight:500;font-size:clamp(32px,4.4vw,48px);line-height:1.1;letter-spacing:-.02em;color:var(--text);margin:0 0 var(--s4);text-wrap:balance}
.hm-lede{font-size:var(--t-lg);line-height:1.6;color:var(--text3);margin:0 0 var(--s5);max-width:52ch}
.hm-ctas{display:flex;gap:var(--s3);flex-wrap:wrap}
.hm-btn{display:inline-flex;align-items:center;height:46px;padding:0 22px;border-radius:var(--rad);background:var(--green);color:#fff;font-weight:600;font-size:var(--t-base);text-decoration:none;border:1px solid var(--green);transition:background .15s}
.hm-btn:hover{background:var(--green-h,var(--green))}
.hm-btn.is-ghost{background:transparent;color:var(--text);border-color:var(--line2)}
.hm-btn.is-ghost:hover{border-color:var(--green);color:var(--green-h,var(--green))}
.hm-btn.is-light{background:#fff;color:var(--green-h,var(--green));border-color:#fff}
.hm-btn.is-light:hover{background:rgba(255,255,255,.9)}


.hm-stats{background:var(--green-h,var(--green));color:#fff}
.hm-stats-in{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr))}
.hm-stat{display:flex;flex-direction:column;gap:2px;padding:22px 20px;color:#fff;text-decoration:none;border-left:1px solid rgba(255,255,255,.14)}
.hm-stat:first-child{border-left:0;padding-left:0}
.hm-stat b{font-family:var(--font-d);font-weight:500;font-size:26px;line-height:1.15;font-variant-numeric:tabular-nums}
.hm-stat span{font-size:var(--t-xs);color:rgba(255,255,255,.72)}
.hm-stat:hover span{color:#fff}
@media(max-width:640px){.hm-stats-in{grid-template-columns:1fr 1fr}.hm-stat{padding:16px 12px;border-left:0;border-top:1px solid rgba(255,255,255,.14)}.hm-stat:first-child{padding-left:12px}}

.v4 .v4-wrap.hm-body{padding-top:var(--s7);padding-bottom:var(--s8)}
.hm-sec+.hm-sec{margin-top:var(--s8)}
.hm-sec-h{display:flex;justify-content:space-between;align-items:flex-end;gap:16px;margin-bottom:var(--s4)}
.hm-sec-h h2{font-family:var(--font-d);font-weight:500;font-size:var(--t-2xl);letter-spacing:-.01em;margin:0;color:var(--text)}
.hm-sec-h>a{flex:none;font-size:var(--t-sm);font-weight:600;color:var(--green-h,var(--green));text-decoration:none}
.hm-sec-h>a:hover{text-decoration:underline}

.hm-ecgc{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:var(--s4);align-items:stretch}
@media(max-width:900px){.hm-ecgc{grid-template-columns:1fr}}
.hm-moves{list-style:none;margin:0;padding:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.hm-moves li+li{border-top:1px solid var(--line)}
.hm-moves a{display:grid;grid-template-columns:minmax(0,1.3fr) auto minmax(0,1fr) auto;gap:14px;align-items:center;padding:13px 18px;color:var(--text);text-decoration:none;font-size:var(--t-sm)}
.hm-moves a:hover{background:var(--surface2)}
.hm-mv-n{font-weight:600;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hm-mv-r{display:inline-flex;align-items:center;gap:6px}
.hm-arrow{color:var(--text4)}
.hm-mv-d{color:var(--text3);font-size:var(--t-xs)}
.hm-mv-d.is-down{color:var(--err)}
.hm-mv-d.is-up{color:var(--ok)}
.hm-mv-w{font-family:var(--font-m);font-size:11px;color:var(--text3);white-space:nowrap}
@media(max-width:640px){.hm-moves a{grid-template-columns:1fr auto;row-gap:4px}.hm-mv-w{grid-column:2;text-align:right}}
.hm-circ{display:flex;flex-direction:column;gap:10px;padding:22px;border-radius:var(--rad-lg);background:var(--surface);border:1px solid var(--line);border-top:3px solid var(--green);color:var(--text);text-decoration:none}
.hm-circ:hover{border-color:var(--green)}
.hm-circ b{font-family:var(--font-d);font-weight:600;font-size:var(--t-lg);line-height:1.35}
.hm-circ-m{display:flex;align-items:center;gap:8px;font-size:var(--t-xs);color:var(--text3)}
.hm-circ-go{margin-top:auto;font-size:var(--t-sm);font-weight:600;color:var(--green-h,var(--green))}

.hm-topics{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:var(--s2)}
.hm-topic{display:flex;justify-content:space-between;align-items:baseline;gap:10px;padding:14px 16px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad);color:var(--text);text-decoration:none}
.hm-topic:hover{border-color:var(--green)}
.hm-topic b{font-weight:600;font-size:var(--t-sm);line-height:1.35}
.hm-topic span{flex:none;font-family:var(--font-m);font-size:11px;color:var(--text3)}

.hm-two{display:grid;grid-template-columns:1fr 1fr;gap:var(--s6)}
.hm-two.is-one{grid-template-columns:1fr}
@media(max-width:900px){.hm-two{grid-template-columns:1fr}}
.hm-sec.hm-two .hm-sec-h h2{font-size:var(--t-xl)}
.hm-rows{list-style:none;margin:0;padding:0;border-top:1px solid var(--line)}
.hm-rows li{border-bottom:1px solid var(--line)}
.hm-rows a{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:12px;align-items:center;padding:12px 2px;color:var(--text);text-decoration:none;font-size:var(--t-sm)}
.hm-rows a:hover .hm-row-t{color:var(--green-h,var(--green))}
.hm-row-t{font-weight:500;line-height:1.4;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.hm-rows time{font-family:var(--font-m);font-size:11px;color:var(--text3);white-space:nowrap}
.hm-rows.is-posts a{grid-template-columns:minmax(0,1fr) auto;row-gap:2px}
.hm-rows.is-posts .hm-row-t{white-space:normal;font-weight:600}
.hm-rows.is-posts small{grid-column:1;color:var(--text3);line-height:1.5}
.hm-rows.is-posts time{grid-column:2;grid-row:1}
.hm-note{font-size:var(--t-xs);color:var(--text3);margin:10px 0 0}
.hm-note a{color:var(--green-h,var(--green));font-weight:600}

.hm-join{background:var(--green-h,var(--green));color:#fff}
.hm-join-in{display:flex;justify-content:space-between;align-items:center;gap:var(--s6);padding-top:var(--s7)!important;padding-bottom:var(--s7)!important;flex-wrap:wrap}
.hm-join h2{font-family:var(--font-d);font-weight:500;font-size:var(--t-2xl);margin:0 0 var(--s3);color:#fff}
.hm-join ul{margin:0;padding:0;list-style:none;display:grid;grid-template-columns:1fr 1fr;gap:8px 28px}
.hm-join li{position:relative;padding-left:22px;font-size:var(--t-sm);color:rgba(255,255,255,.85);line-height:1.5}
.hm-join li::before{content:"";position:absolute;left:2px;top:6px;width:10px;height:6px;border-left:2px solid rgba(255,255,255,.8);border-bottom:2px solid rgba(255,255,255,.8);transform:rotate(-45deg)}
.hm-join-cta{display:flex;flex-direction:column;gap:10px;align-items:center}
.hm-join-cta>a:last-child{font-size:var(--t-sm);color:rgba(255,255,255,.8)}
@media(max-width:640px){.hm-join ul{grid-template-columns:1fr}.hm-join-cta{align-items:flex-start}}

/* ── Admin: Homepage & tools ─────────────────────────────────────────────── */
.hmadm{display:flex;flex-direction:column;gap:16px;max-width:900px}
.hmadm-card h3{font-size:15px;margin:0 0 12px}
.hmadm-card .ap-opt{padding:10px 0}
.hmadm-card .ap-opt+.ap-opt{border-top:1px solid var(--line)}
.hmadm-secs{display:grid;grid-template-columns:1fr 1fr;gap:8px 20px;font-size:13px;margin-top:6px}
.hmadm-secs input{accent-color:var(--green);margin-right:6px}
@media(max-width:700px){.hmadm-secs{grid-template-columns:1fr}}
.hmadm-tools td.is-c,.hmadm-tools th:nth-child(n+2):nth-child(-n+4){text-align:center}
.hmadm-tools input[type=checkbox]{accent-color:var(--green);width:16px;height:16px}
.hmadm-tool{display:flex;gap:10px;align-items:center}
.hmadm-tool small{display:block;font-size:11px;color:var(--text3);font-family:var(--font-m)}
.hmadm>.btn{align-self:flex-start}
.hmadm select,.hmadm input[type=number]{font:inherit;font-size:13px;padding:6px 10px;border:1.5px solid var(--line);border-radius:8px;background:var(--surface);color:var(--text)}
.hmadm select:focus,.hmadm input[type=number]:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.hmadm .ap-opt select{display:block;width:100%}

/* ── Trade Agreements Checker and Export Document Checklist ──────────────── */
.v4 .v4-wrap.ta,.v4 .v4-wrap.dc{padding-top:var(--s5);padding-bottom:var(--s8)}
.ta-hero{max-width:820px;margin:var(--s2) 0 var(--s5)}
.ta-hero .v4-sub{font-size:var(--t-base);max-width:64ch;margin-bottom:var(--s4)}
.ta-form{display:flex;gap:10px;align-items:flex-end;flex-wrap:wrap;margin-top:var(--s4)}
.ta-f{display:flex;flex-direction:column;gap:6px;min-width:0}
.ta-form .ta-f{flex:1 1 280px}
.ta-form .ta-f.is-hs{flex:0 1 170px}
.ta-f label{font-size:var(--t-sm);font-weight:600;color:var(--text)}
.ta-f label small{font-weight:400;color:var(--text3)}
.ta-f input,.ta-f select{width:100%;height:46px;padding:0 14px;border:1.5px solid var(--line2);border-radius:var(--rad);background:var(--surface);font:inherit;font-size:var(--t-md);color:var(--text)}
.ta-f select{padding-right:32px}
.ta-f input:focus,.ta-f select:focus{outline:none;border-color:var(--green);box-shadow:0 0 0 3px var(--green-tint)}
.ta-form button,.dc-go button{height:46px;padding:0 24px;border:0;border-radius:var(--rad);background:var(--green);color:#fff;font:inherit;font-weight:600;cursor:pointer}
.ta-form button:hover,.dc-go button:hover{background:var(--green-h,var(--green))}

.ta-verdict{display:flex;justify-content:space-between;gap:20px;align-items:flex-start;padding:20px 22px;border-radius:var(--rad-lg);border:1px solid var(--line);background:var(--surface);margin-bottom:var(--s5)}
.ta-verdict.is-yes{border-left:4px solid var(--ok)}
.ta-verdict.is-no{border-left:4px solid var(--line2)}
.ta-verdict-k{font-family:var(--font-m);font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase;margin:0 0 6px;color:var(--text3)}
.ta-verdict.is-yes .ta-verdict-k{color:var(--ok)}
.ta-verdict-t{margin:0;font-size:var(--t-lg);line-height:1.55;color:var(--text);max-width:68ch}
.ta-ecgc{flex:none;display:flex;flex-direction:column;align-items:center;gap:4px;padding:8px 12px;border:1px solid var(--line);border-radius:var(--rad);text-decoration:none}
.ta-ecgc span{font-family:var(--font-m);font-size:10px;letter-spacing:.08em;color:var(--text3)}
.ta-ecgc:hover{border-color:var(--green)}

.ta-hs{padding:18px 22px;border:1px solid var(--line);border-radius:var(--rad-lg);background:var(--surface2);margin-bottom:var(--s5)}
.ta-hs-h{display:flex;gap:12px;align-items:baseline;margin:0 0 8px;font-weight:600;color:var(--text);line-height:1.45}
.ta-hs-h a.hs-code{text-decoration:none}
.ta-hs-t{margin:0 0 8px;font-size:var(--t-sm);color:var(--text2)}
.ta-links{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:6px}
.ta-links a{font-weight:600;color:var(--green-h,var(--green));text-decoration:none;font-size:var(--t-sm)}
.ta-links a:hover{text-decoration:underline}
.ta-links small{color:var(--text3);font-size:var(--t-xs);margin-left:6px}

.ta-sec{margin-top:var(--s6)}
.ta-sec>h2,.ta-how h2{font-family:var(--font-d);font-weight:500;font-size:var(--t-xl);margin:0 0 var(--s3);display:flex;align-items:baseline;gap:10px;color:var(--text)}
.ta-n{font-family:var(--font-m);font-size:11px;font-weight:600;color:var(--text3);background:var(--surface2);border:1px solid var(--line);border-radius:999px;padding:1px 8px}
.ta-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:20px 22px;margin-bottom:var(--s3)}
.ta-card.is-brief{padding:16px 20px}
.ta-card-h{display:flex;justify-content:space-between;align-items:flex-start;gap:14px}
.ta-card h3{font-family:var(--font-d);font-weight:600;font-size:var(--t-lg);margin:0;line-height:1.3}
.ta-card h3 a{color:var(--text);text-decoration:none}
.ta-card h3 a:hover{color:var(--green-h,var(--green))}
.ta-meta{margin:4px 0 0;font-size:var(--t-xs);color:var(--text3);font-family:var(--font-m)}
.ta-sum{margin:12px 0 0;font-size:var(--t-base);line-height:1.6;color:var(--text2);max-width:78ch}
.ta-card.is-brief .ta-sum{font-size:var(--t-sm)}
.ta-hl{margin:12px 0 0;padding-left:20px;font-size:var(--t-sm);line-height:1.55;color:var(--text2)}
.ta-hl li{margin:3px 0}
.ta-hl.is-big{font-size:var(--t-base);line-height:1.65}
.ta-dl{margin:14px 0 0;display:grid;gap:10px;border-top:1px solid var(--line);padding-top:14px}
.ta-dl div{display:grid;grid-template-columns:140px 1fr;gap:12px;font-size:var(--t-sm);line-height:1.55}
.ta-dl dt{font-weight:600;color:var(--text)}
.ta-dl dd{margin:0;color:var(--text2)}
.ta-dl.is-big{margin-top:var(--s5)}
@media(max-width:640px){.ta-dl div{grid-template-columns:1fr;gap:2px}.ta-card-h{flex-direction:column-reverse;gap:8px}.ta-verdict{flex-direction:column}}
.ta-go{margin:12px 0 0;font-size:var(--t-sm)}
.ta-go a{font-weight:600;color:var(--green-h,var(--green));text-decoration:none}
.ta-src{margin:12px 0 0;font-size:var(--t-xs);color:var(--text3);line-height:1.6}
.ta-src span{font-weight:600}
.ta-src a{color:var(--text3)}
.ta-src a:hover{color:var(--green-h,var(--green))}
.ta-pill{flex:none;display:inline-block;font-family:var(--font-m);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;border-radius:999px;padding:3px 9px;white-space:nowrap;border:1px solid transparent}
.ta-pill.is-live{color:var(--ok);background:var(--ok-bg)}
.ta-pill.is-soon{color:var(--amber);background:var(--amber-tint)}
.ta-pill.is-talks{color:var(--text3);background:var(--surface2);border-color:var(--line)}
.ta-note{padding:16px 20px;border-left:3px solid var(--amber);background:var(--amber-tint);border-radius:0 var(--rad) var(--rad) 0;margin-bottom:var(--s3)}
.ta-note b{display:block;color:var(--text);margin-bottom:4px}
.ta-note p{margin:0;font-size:var(--t-sm);line-height:1.6;color:var(--text2)}
.ta-next{margin-top:var(--s6);max-width:560px}
.ta-foot{margin-top:var(--s6);font-size:var(--t-xs);color:var(--text3);max-width:80ch;line-height:1.6}
.ta-how{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:20px 24px;margin-bottom:var(--s4)}
.ta-how ol,.ta-how ul{margin:0;padding-left:20px;font-size:var(--t-sm);line-height:1.65;color:var(--text2)}
.ta-how li{margin:6px 0}
.ta-how b{color:var(--text)}
.ta-how a{color:var(--green-h,var(--green))}
.ta-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:var(--s2)}
.ta-tile{display:flex;flex-direction:column;gap:3px;padding:14px 16px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad);color:var(--text);text-decoration:none}
.ta-tile:hover{border-color:var(--green)}
.ta-tile b{font-weight:600;font-size:var(--t-sm)}
.ta-tile span{font-size:var(--t-xs);color:var(--text2);line-height:1.45}
.ta-tile small{font-family:var(--font-m);font-size:11px;color:var(--text3)}
.ta-one{display:grid;grid-template-columns:minmax(0,1fr) 300px;gap:var(--s6);align-items:start;margin-top:var(--s3)}
@media(max-width:920px){.ta-one{grid-template-columns:1fr}}
.ta-one .v4-h1{margin:6px 0 6px}
.ta-lede{font-size:var(--t-lg);line-height:1.6;color:var(--text2);margin:var(--s4) 0 0;max-width:70ch}
.ta-side{position:sticky;top:84px;display:flex;flex-direction:column;gap:var(--s4)}
@media(max-width:920px){.ta-side{position:static}}
.ta-partners{list-style:none;margin:0;padding:0;max-height:none}
.ta-partners a{display:block;padding:5px 8px;border-radius:6px;color:var(--text2);text-decoration:none;font-size:var(--t-sm)}
.ta-partners a:hover{background:var(--surface2);color:var(--green-h,var(--green))}

.dc-form{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:20px 22px;margin-bottom:var(--s5)}
.dc-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px 16px;align-items:end}
.dc-grid .ta-f:first-child{grid-column:span 2}
.dc-grid .ta-f:nth-child(7){grid-column:span 2}
.dc-go{justify-content:flex-end}
.dc-go button{width:100%}
@media(max-width:900px){.dc-grid{grid-template-columns:1fr 1fr}.dc-grid .ta-f:first-child,.dc-grid .ta-f:nth-child(7){grid-column:span 2}}
@media(max-width:560px){.dc-grid{grid-template-columns:1fr}.dc-grid .ta-f:first-child,.dc-grid .ta-f:nth-child(7){grid-column:auto}}
.dc-form.is-compact{padding:16px 18px;background:var(--surface2)}
.dc-form.is-compact .ta-f input,.dc-form.is-compact .ta-f select,.dc-form.is-compact .dc-go button{height:40px;font-size:var(--t-sm)}
.dc-sum{display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;margin-bottom:var(--s3)}
.dc-sum-t{margin:0;font-size:var(--t-base);color:var(--text2)}
.dc-sum-t b{color:var(--text)}
.dc-acts{display:flex;gap:8px;align-items:center}
.dc-prog{font-family:var(--font-m);font-size:12px;color:var(--text3);margin-right:6px}
.dc-prog b{color:var(--green-h,var(--green))}
.dc-btn{height:34px;padding:0 14px;border:1px solid var(--line2);border-radius:8px;background:var(--surface);font:inherit;font-size:var(--t-sm);font-weight:600;color:var(--text);cursor:pointer}
.dc-btn:hover{border-color:var(--green);color:var(--green-h,var(--green))}
.dc-flags{display:flex;flex-direction:column;gap:8px;margin-bottom:var(--s5)}
.dc-flag{padding:12px 16px;border-radius:var(--rad);background:var(--surface);border:1px solid var(--line);font-size:var(--t-sm);line-height:1.6;color:var(--text2)}
.dc-flag b{color:var(--text)}
.dc-flag a{color:var(--green-h,var(--green));font-weight:600}
.dc-flag.is-warn{background:var(--amber-tint);border-color:transparent;border-left:3px solid var(--amber)}
.dc-flag.is-good{background:var(--ok-bg);border-color:transparent;border-left:3px solid var(--ok)}
.dc-flag .em-rb{font-size:11px;padding:1px 6px;min-width:0}
.dc-sec{margin-top:var(--s5)}
.dc-sec h2{font-family:var(--font-d);font-weight:500;font-size:var(--t-xl);margin:0 0 4px;display:flex;align-items:baseline;gap:10px;color:var(--text)}
.dc-sec-sub{margin:0 0 var(--s2);font-size:var(--t-sm);color:var(--text3);max-width:80ch}
.dc-items{list-style:none;margin:var(--s2) 0 0;padding:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.dc-item{display:flex;gap:14px;padding:14px 18px;align-items:flex-start}
.dc-item+.dc-item{border-top:1px solid var(--line)}
.dc-item input{flex:none;width:20px;height:20px;margin-top:2px;accent-color:var(--green);cursor:pointer}
.dc-b{flex:1;min-width:0}
.dc-name{font-weight:600;color:var(--text);cursor:pointer;line-height:1.4}
.dc-item.is-done .dc-name{text-decoration:line-through;text-decoration-color:var(--text4);color:var(--text3)}
.dc-item.is-done .dc-what,.dc-item.is-done .dc-meta,.dc-item.is-done .dc-note{opacity:.6}
.dc-pill{display:inline-block;vertical-align:1px;margin-left:6px;font-family:var(--font-m);font-size:10px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;border-radius:999px;padding:1px 8px}
.dc-pill.is-req{color:var(--green-h,var(--green));background:var(--green-tint)}
.dc-pill.is-if{color:var(--text3);background:var(--surface2);border:1px solid var(--line)}
.dc-pill.is-rec{color:var(--amber);background:var(--amber-tint)}
.dc-what{margin:4px 0 0;font-size:var(--t-sm);line-height:1.6;color:var(--text2);max-width:80ch}
.dc-meta{margin:4px 0 0;font-size:var(--t-xs);color:var(--text3);line-height:1.5}
.dc-note{margin:4px 0 0;font-size:var(--t-xs);color:var(--text3);line-height:1.5;font-style:italic;max-width:80ch}
.dc-links{margin:6px 0 0;display:flex;flex-wrap:wrap;gap:4px 14px;font-size:var(--t-xs)}
.dc-links:empty{display:none}
.dc-links a{color:var(--green-h,var(--green));font-weight:600;text-decoration:none}
.dc-links a.is-src{color:var(--text3);font-weight:400}
.dc-links a:hover{text-decoration:underline}
@media print{
  nav,.site-nav,header.v4-nav,footer,.dc-form,.dc-acts,.kb-crumbs,.dc-links,.ta-hero .v4-sub{display:none!important}
  .dc-items{border:0}.dc-item{break-inside:avoid;padding:8px 0}.dc-flag{border:1px solid #ccc}
  body,.v4{background:#fff!important}
}
a.dl-tab{text-decoration:none;display:inline-block}

/* ── ECGC Premium Calculator ─────────────────────────────────────────────── */
.v4 .v4-wrap.pc{padding-top:var(--s5);padding-bottom:var(--s8)}
.pc-grid{display:grid;grid-template-columns:minmax(0,1.25fr) minmax(0,1fr);gap:var(--s5);align-items:start}
@media(max-width:900px){.pc-grid{grid-template-columns:1fr}}
.pc-form{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:22px 24px;display:flex;flex-direction:column;gap:18px}
.pc-f{border:0;margin:0;padding:0;min-width:0}
.pc-f legend{font-size:var(--t-sm);font-weight:600;color:var(--text);margin-bottom:8px;padding:0}
.pc-seg{display:flex;flex-wrap:wrap;gap:6px}
.pc-seg input{position:absolute;opacity:0;pointer-events:none}
.pc-seg label{display:inline-flex;align-items:center;height:40px;padding:0 16px;border:1.5px solid var(--line2);border-radius:var(--rad);background:var(--surface);font-size:var(--t-sm);font-weight:600;color:var(--text2);cursor:pointer;user-select:none;transition:border-color .12s,background .12s}
.pc-seg label:hover{border-color:var(--green)}
.pc-seg input:checked+label{background:var(--green);border-color:var(--green);color:#fff}
.pc-seg input:focus-visible+label{outline:2px solid var(--green);outline-offset:2px}
.pc-seg.is-terms{display:grid;grid-template-columns:repeat(auto-fit,minmax(88px,1fr))}
.pc-seg.is-terms label{justify-content:center;padding:0 8px}
.pc-row{display:grid;grid-template-columns:minmax(0,1fr) 150px;gap:14px}
.pc-row.pc-when-sbe{grid-template-columns:1fr 1fr}
@media(max-width:560px){.pc-row,.pc-row.pc-when-sbe{grid-template-columns:1fr}}
.pc-rating select:disabled{background:var(--surface2);color:var(--text);opacity:1;cursor:not-allowed}
.pc-hint{margin:-10px 0 0;font-size:var(--t-xs);color:var(--text3)}
.pc-amt{display:block;min-height:1.2em;margin-top:5px;font-family:var(--font-m);font-size:11.5px;color:var(--text3)}
.pc-form[data-policy="sbe"] .pc-when-giv,.pc-form:not([data-policy="sbe"]) .pc-when-sbe{display:none}
.pc-go button{height:46px;padding:0 26px;border:0;border-radius:var(--rad);background:var(--green);color:#fff;font:inherit;font-weight:600;cursor:pointer}
.pc-go.is-js{display:none}
.pc-res{position:sticky;top:84px;background:var(--surface);border:1px solid var(--line);border-top:3px solid var(--green);border-radius:var(--rad-lg);padding:22px 24px}
@media(max-width:900px){.pc-res{position:static}}
.pc-kicker{font-family:var(--font-m);font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase;color:var(--text3);margin:0}
.pc-big{font-family:var(--font-d);font-weight:500;font-size:clamp(34px,4vw,44px);line-height:1.1;color:var(--text);margin:6px 0 2px;font-variant-numeric:tabular-nums}
.pc-big.is-dim{color:var(--text4)}
.pc-big.is-off{color:var(--err);font-size:30px}
.pc-words{margin:0 0 14px;font-size:var(--t-sm);color:var(--text3)}
.pc-empty{margin:8px 0 0;font-size:var(--t-sm);color:var(--text3);line-height:1.6}
.pc-warn{margin:10px 0 0;font-size:var(--t-sm);line-height:1.6;color:var(--text2)}
.pc-warn a,.pc-note a{color:var(--green-h,var(--green));font-weight:600}
.pc-rows{margin:0;border-top:1px solid var(--line)}
.pc-rows div{display:flex;justify-content:space-between;gap:12px;padding:9px 0;border-bottom:1px dashed var(--line);font-size:var(--t-sm)}
.pc-rows dt{color:var(--text3)}
.pc-rows dd{margin:0;color:var(--text);font-weight:600;text-align:right;font-variant-numeric:tabular-nums}
.pc-note{margin:12px 0 0;padding:10px 12px;border-radius:var(--rad);background:var(--amber-tint);font-size:var(--t-xs);line-height:1.55;color:var(--text2)}
.pc-cmp{margin-top:18px}
.pc-cmp-h{margin:0 0 8px;font-size:var(--t-xs);font-weight:600;color:var(--text2)}
.pc-cmp ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:4px}
.pc-cmp li{display:grid;grid-template-columns:96px 1fr 86px;gap:10px;align-items:center;font-size:var(--t-xs);color:var(--text2);padding:3px 6px;border-radius:6px}
.pc-cmp li i{display:block;height:6px;border-radius:3px;background:var(--line);position:relative;overflow:hidden}
.pc-cmp li i::after{content:"";position:absolute;inset:0 auto 0 0;width:var(--w);background:var(--text4);border-radius:3px}
.pc-cmp li b{font-weight:600;color:var(--text);font-variant-numeric:tabular-nums;text-align:right}
.pc-cmp li.is-on{background:var(--green-tint)}
.pc-cmp li.is-on span,.pc-cmp li.is-on b{color:var(--green-h,var(--green))}
.pc-cmp li.is-on i::after{background:var(--green)}
.pc-cmp ul:has(li:nth-child(2):last-child) li{grid-template-columns:1fr 86px}
.pc-alt{margin:10px 0 0;font-size:var(--t-xs);color:var(--text3)}
.pc-alt b{color:var(--text)}
.pc-fine{margin:16px 0 0;padding-top:12px;border-top:1px solid var(--line);font-size:11.5px;line-height:1.55;color:var(--text3)}
.pc-more{display:grid;grid-template-columns:repeat(auto-fill,minmax(250px,1fr));gap:var(--s2);margin-top:var(--s6)}

/* ── Pre-Shipment Finance Calculator (shares the pc-* layout) ────────────── */
.pc-row.psf-order{grid-template-columns:minmax(0,1fr) 110px}
.pc-row.is-3{grid-template-columns:1fr 1fr 1.3fr}
@media(max-width:560px){.pc-row.is-3{grid-template-columns:1fr 1fr}.pc-row.is-3 .ta-f:last-child{grid-column:span 2}}
.pc-form[data-cur="INR"] .psf-fx,.pc-form[data-cur="INR"] .psf-pcfc{display:none}
.psf-box{border-top:1px solid var(--line);padding-top:16px;display:flex;flex-direction:column;gap:12px}
.psf-box .pc-hint{margin:-4px 0 0}
.psf-sub{padding:10px 12px;border:1px solid var(--line);border-radius:var(--rad);background:var(--surface2)}
.psf-used{display:none}
.psf-box:has(.psf-sub input:checked) .psf-used{display:flex}
.psf-opts{display:grid;gap:10px;margin-top:4px}
.psf-opt{border:1px solid var(--line);border-radius:var(--rad);padding:12px 14px}
.psf-opt.is-best{border-color:var(--green);background:var(--green-tint)}
.psf-opt-h{margin:0 0 4px;font-weight:600;font-size:var(--t-sm);color:var(--text);display:flex;justify-content:space-between;align-items:center}
.psf-opt-h span{font-family:var(--font-m);font-size:10px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:#fff;background:var(--green);border-radius:999px;padding:2px 8px}
.psf-opt .pc-rows{border-top:0}
.psf-opt .pc-rows div{padding:6px 0}
.psf-opt .pc-rows div:last-child{border-bottom:0}
.pc-rows div.is-total dt{color:var(--text);font-weight:600}
.pc-rows div.is-total dd{font-size:var(--t-base)}
.pc-rows dd.is-minus{color:var(--ok)}
.pc-rows dt small{font-family:var(--font-m);font-size:10px;color:var(--amber)}
.psf-verdict{margin:12px 0 0;font-size:var(--t-xs);line-height:1.6;color:var(--text2)}
.psf-verdict b{color:var(--text)}
.psf-meta{margin-top:12px}
.psf-how{margin-top:var(--s6)}
.psf-ecgc{display:none;flex-direction:column;gap:12px}
.psf-box:has(input[name=ecgc]:checked) .psf-ecgc{display:flex}
.pc-row.is-even{grid-template-columns:1fr 1fr}
@media(max-width:560px){.pc-row.is-even{grid-template-columns:1fr}}
.pc-f legend small{font-weight:400;color:var(--text3)}
.psf-opts.is-two{grid-template-columns:1fr}
.psf-print{margin:12px 0 0}
@media print{.pc-form,.psf-how,.pc-more,.psf-print,.kb-crumbs{display:none!important}.pc-grid{display:block}.pc-res{position:static;border:1px solid #ccc}}

/* Dashboard: renew the RCMC in place */
.em-renew{margin-top:6px}
.em-renew summary{cursor:pointer;font-size:12px;font-weight:600;color:var(--green-h,var(--green));list-style:none}
.em-renew summary::-webkit-details-marker{display:none}
.em-renew form{display:flex;flex-wrap:wrap;gap:8px;align-items:flex-end;margin-top:8px;padding:10px;border:1px solid var(--line);border-radius:var(--rad);background:var(--surface2)}
.em-renew label{display:flex;flex-direction:column;gap:4px;font-size:12px;color:var(--text2)}
.em-renew input[type=date]{height:36px;padding:0 10px;border:1.5px solid var(--line2);border-radius:8px;font:inherit;font-size:14px;background:var(--surface)}
.em-renew small{flex-basis:100%;font-size:11px;color:var(--text3)}

/* Footer "Install the app": readable on any footer colour */
.nr-install-btn{background:#fff;color:#0F172A}
.em-due-r:has(.em-renew[open]){align-items:flex-start}

/* Members-only tool: what it does, and how to get in */
.v4 .v4-wrap.tl-gate-wrap{padding-top:var(--s5);padding-bottom:var(--s8)}
.tl-gate{max-width:640px;margin:var(--s6) auto;text-align:center;background:var(--surface);border:1px solid var(--line);border-radius:18px;padding:var(--s7) var(--s6)}
.tl-gate .tl-ico{width:60px;height:60px;border-radius:14px;margin-bottom:var(--s3)}
.tl-gate .v4-sub{font-size:var(--t-base);margin:var(--s2) auto var(--s4);max-width:52ch}
.tl-gate-note{font-size:var(--t-sm);color:var(--text2);margin:0 0 var(--s5)}
.tl-gate .hm-ctas{justify-content:center}

/* Export Quote Builder */
.pc-row.is-4{grid-template-columns:repeat(4,minmax(0,1fr))}
@media(max-width:560px){.pc-row.is-4{grid-template-columns:1fr 1fr}}
.psf-box.is-first{border-top:0;padding-top:0}
.pc-form[data-cur="INR"] .qb-fx{display:none}
.qb-fin{display:none}
.psf-box:has(input[type=checkbox][name=fin]:checked) .qb-fin{display:grid}
.qb-per{font-family:var(--font-b);font-size:var(--t-sm);color:var(--text3);font-weight:400;letter-spacing:0}
.qb-ladder{width:100%;border-collapse:collapse;margin:6px 0 0;font-size:var(--t-sm);font-variant-numeric:tabular-nums}
.qb-ladder th{font-family:var(--font-m);font-size:10.5px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--text3);text-align:left;padding:6px 8px;border-bottom:1px solid var(--line)}
.qb-ladder td{padding:8px;border-bottom:1px dashed var(--line);color:var(--text)}
.qb-ladder th:not(:first-child),.qb-ladder td:not(:first-child){text-align:right}
.qb-ladder tr.is-on td{background:var(--green-tint);color:var(--green-h,var(--green));font-weight:600}
.qb-lines div.is-minus dt{color:var(--ok)}

/* RoDTEP table on HS code pages (1.9.0) */
.hs-rt{width:100%;border-collapse:collapse;font-size:13px;margin:6px 0 4px}
.hs-rt th{font-size:11px;font-weight:600;letter-spacing:.03em;text-transform:uppercase;color:var(--text3);padding:6px 8px;border-bottom:1px solid var(--line2)}
.hs-rt td{padding:8px;border-bottom:1px solid var(--line);vertical-align:top}
.hs-rt small{font-size:10px;color:var(--text3)}

/* Buyer risk desk (1.9.0) */
.by-policy{display:flex;flex-wrap:wrap;align-items:center;gap:8px 12px;margin:0 0 var(--s4);padding:12px 16px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad)}
.by-policy label{font-weight:600;font-size:var(--t-sm)}
.by-policy select{font:inherit;font-size:var(--t-sm);padding:7px 10px;border:1px solid var(--line2);border-radius:8px;background:var(--surface);color:var(--text);min-width:260px;max-width:100%}
.by-policy small{flex-basis:100%;font-size:var(--t-xs);color:var(--text3)}
.by-stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:0 0 var(--s4)}
.by-stat{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad);padding:12px 14px;display:flex;flex-direction:column;gap:2px}
.by-stat b{font-family:var(--font-d);font-size:22px;line-height:1.1;color:var(--text)}
.by-stat span{font-size:var(--t-xs);color:var(--text3)}
.by-stat.is-red{border-color:rgba(185,28,28,.35);background:rgba(185,28,28,.04)}
.by-stat.is-red b{color:var(--err)}
@media(max-width:640px){.by-stats{grid-template-columns:repeat(2,minmax(0,1fr))}}
.by-grid{display:grid;grid-template-columns:minmax(0,1.6fr) minmax(0,1fr);gap:var(--s5);align-items:start;margin-bottom:var(--s6)}
@media(max-width:900px){.by-grid{grid-template-columns:1fr}.by-grid.is-empty .by-side{order:-1}}
.by-main{display:flex;flex-direction:column;gap:var(--s4);min-width:0}
.by-main .v4-empty{margin:0}
.by-side{position:sticky;top:84px}
@media(max-width:900px){.by-side{position:static}}
.by-card{background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:18px 20px}
.by-card-h{display:flex;justify-content:space-between;align-items:flex-start;gap:12px}
.by-card-h h2{font-family:var(--font-d);font-size:20px;margin:0 0 2px}
.by-card-h .ta-meta{margin:0}
.by-cl{display:flex;flex-wrap:wrap;gap:10px 28px;margin:14px 0 6px}
.by-cl > div{display:flex;flex-direction:column;gap:2px;min-width:130px}
.by-cl span{font-size:11px;letter-spacing:.03em;text-transform:uppercase;color:var(--text3)}
.by-cl b{font-size:16px}
.by-cl small{font-size:var(--t-xs);color:var(--text3)}
.by-use{flex:1;min-width:180px!important}
.by-use i{display:block;height:8px;border-radius:99px;background:var(--surface2);position:relative;overflow:hidden;margin:6px 0 2px}
.by-use i::after{content:"";position:absolute;inset:0 auto 0 0;width:var(--w);background:var(--green);border-radius:99px}
.by-use i.is-high::after{background:var(--amber)}
.by-use i.is-full::after{background:var(--err)}
.by-flag{margin:8px 0 0;padding:8px 12px;border-radius:8px;font-size:var(--t-sm);line-height:1.45}
.by-flag.is-amber{background:rgba(180,83,9,.08);color:#7c3a06;border-left:3px solid var(--amber)}
.by-flag.is-red{background:rgba(185,28,28,.06);color:#7f1d1d;border-left:3px solid var(--err)}
.by-inv{width:100%;border-collapse:collapse;margin-top:14px;font-size:var(--t-sm)}
.by-inv th{font-size:11px;font-weight:600;letter-spacing:.03em;text-transform:uppercase;color:var(--text3);text-align:left;padding:6px 8px;border-bottom:1px solid var(--line2)}
.by-inv td{padding:9px 8px;border-bottom:1px solid var(--line);vertical-align:top}
.by-inv td small{display:block;font-size:11px;color:var(--text3)}
.by-inv tr.is-ok td{color:var(--text3)}
.by-st{display:inline-block;font-size:11.5px;font-weight:600;padding:2px 9px;border-radius:99px;background:var(--surface2);color:var(--text2);white-space:nowrap}
.by-inv tr.is-ok .by-st{background:var(--green-tint);color:var(--green)}
.by-inv tr.is-amber .by-st{background:rgba(180,83,9,.12);color:var(--amber)}
.by-inv tr.is-red .by-st{background:rgba(185,28,28,.1);color:var(--err)}
.by-acts{display:flex;gap:6px;justify-content:flex-end}
.by-acts form{margin:0}
.by-x{color:var(--err)!important}
.by-inv tr:has(+ .by-do) td{border-bottom:0}
.by-do td{background:var(--surface2);border-radius:0 0 8px 8px;padding:10px 12px;font-size:13px;line-height:1.5}
.by-do p{margin:0 0 6px}
.by-dates{display:flex;flex-wrap:wrap;gap:6px 18px;color:var(--text3);font-size:12px}
.by-dates b{color:var(--text)}
.by-mini{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:4px 0 0}
.by-mini label{display:flex;align-items:center;gap:8px;font-size:12px}
.by-mini input[type=date]{font:inherit;font-size:12px;padding:5px 8px;border:1px solid var(--line2);border-radius:6px}
.by-add{margin-top:14px}
.by-add .by-inv-form{display:grid;grid-template-columns:repeat(auto-fill,minmax(150px,1fr));gap:10px;align-items:end}
.by-inv-form label{display:flex;flex-direction:column;gap:4px;font-size:12px;font-weight:600;color:var(--text2)}
.by-inv-form input,.by-inv-form select{font:inherit;font-size:13px;font-weight:400;padding:7px 9px;border:1px solid var(--line2);border-radius:8px;background:var(--surface);color:var(--text)}
.by-rules{margin-top:0}
@media(max-width:640px){.by-inv thead{display:none}.by-inv tr:not(.by-do){display:grid;grid-template-columns:1fr 1fr;gap:4px}.by-inv td{border:0;padding:4px 6px}.by-inv tr:not(.by-do){border-bottom:1px solid var(--line);padding:6px 0}.by-acts{justify-content:flex-start}}

/* Home hero: what a member gets, and a preview of the dashboard (1.9.1) */
.hm-gets{list-style:none;margin:var(--s5) 0 0;padding:0;display:grid;gap:10px;max-width:52ch}
.hm-gets li{display:flex;gap:10px;align-items:flex-start;font-size:var(--t-sm);line-height:1.5;color:var(--text2)}
.hm-gets svg{flex:none;color:var(--green);margin-top:1px}
.hm-peek{margin:0;position:relative;padding:0 0 0 14px}
.hm-peek::before{content:"";position:absolute;inset:18px -10px -12px 0;border-radius:20px;background:var(--green-tint);border:1px solid var(--green-ring)}
.hm-peek-card{position:relative;background:var(--surface);border:1px solid var(--line);border-radius:18px;box-shadow:0 18px 40px -24px rgba(20,40,30,.35);overflow:hidden}
.hm-peek-bar{display:flex;justify-content:space-between;align-items:baseline;gap:10px;padding:14px 18px;border-bottom:1px solid var(--line);background:var(--surface2)}
.hm-peek-bar b{font-family:var(--font-d);font-size:var(--t-md);font-weight:600;color:var(--text)}
.hm-peek-bar span{font-size:var(--t-xs);color:var(--text3)}
.hm-peek-list{list-style:none;margin:0;padding:6px 18px 10px}
.hm-pk{display:flex;gap:14px;align-items:flex-start;padding:13px 0;border-bottom:1px solid var(--line)}
.hm-pk:last-child{border-bottom:0}
.hm-pk-i{flex:none;width:38px;height:38px;border-radius:10px;display:grid;place-items:center;background:var(--green-tint);color:var(--green)}
.hm-pk-i.is-down{background:var(--err-bg);color:var(--err)}
.hm-pk-d{flex:none;width:38px;min-height:38px;border-radius:10px;display:flex;flex-direction:column;align-items:center;justify-content:center;background:var(--err-bg);color:var(--err);font-size:9.5px;font-weight:600;text-transform:uppercase;letter-spacing:.04em;line-height:1.1}
.hm-pk-d b{font-family:var(--font-d);font-size:17px;letter-spacing:0;text-transform:none}
.hm-pk-d.is-calm{background:var(--amber-tint);color:var(--amber)}
.hm-pk-b{min-width:0;display:flex;flex-direction:column;gap:2px}
.hm-pk-b > b{font-size:var(--t-sm);font-weight:600;color:var(--text);line-height:1.4}
.hm-pk-b small{font-size:var(--t-xs);color:var(--text3)}
.hm-pk-r{display:inline-flex;align-items:center;gap:4px;margin-left:4px;vertical-align:1px}
.hm-pk-r .em-rb{font-size:11px;min-width:26px;padding:1px 6px}
.hm-peek figcaption{position:relative;margin:22px 0 0;font-size:var(--t-xs);color:var(--text3);line-height:1.5}
@media(max-width:900px){.hm-peek{padding-left:8px}.hm-peek::before{inset:14px -6px -10px 0}}
/* One moment on load: the dashboard items arrive in turn. */
@media(prefers-reduced-motion:no-preference){
  .hm-pk{animation:hm-arrive .5s cubic-bezier(.2,.7,.2,1) both}
  .hm-pk:nth-child(2){animation-delay:.12s}.hm-pk:nth-child(3){animation-delay:.24s}.hm-pk:nth-child(4){animation-delay:.36s}
  @keyframes hm-arrive{from{opacity:0;transform:translateY(8px)}to{opacity:1;transform:none}}
}

/* Home: what's new (1.9.2) */
.hm-ecgc.is-one{grid-template-columns:minmax(0,1fr)}
.hm-ecgc.is-one .hm-circ{max-width:560px}
.hm-news .hm-nw{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:14px;align-items:center;padding:13px 18px;color:var(--text);text-decoration:none}
.hm-news a.hm-nw:hover{background:var(--surface2)}
.hm-nw-i{width:36px;height:36px;border-radius:10px;display:grid;place-items:center;background:var(--green-tint);color:var(--green)}
.hm-nw-i.is-down{background:var(--err-bg);color:var(--err)}
.hm-nw-b{min-width:0;display:flex;flex-direction:column;gap:2px}
.hm-nw-b > b{font-size:var(--t-sm);font-weight:600;line-height:1.4}
.hm-nw-b small{font-size:var(--t-xs);color:var(--text3)}
.hm-nw-b .hm-mv-r{margin-left:6px;vertical-align:1px}
.hm-nw-b .em-rb{font-size:11px;min-width:26px;padding:1px 6px}
@media(max-width:640px){.hm-news .hm-nw{grid-template-columns:auto minmax(0,1fr)}.hm-news .hm-mv-w{grid-column:2}}

/* 1.10: What's new rows carry their date in the meta line; headings wrap cleanly on phones */
.hm-news .hm-nw{grid-template-columns:auto minmax(0,1fr)}
@media(max-width:640px){
  .hm-sec-h{flex-wrap:wrap;align-items:baseline;gap:4px 16px}
  .hm-sec-h > div{flex:1 1 100%}
  .hm-news .hm-nw{padding:12px 14px;gap:12px}
}
/* Alerts pages */
.v4 .v4-wrap.al{padding-top:var(--s5);padding-bottom:var(--s8)}
.al-list{list-style:none;margin:0;padding:0;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);overflow:hidden}
.al-list li+li{border-top:1px solid var(--line)}
.al-list a{display:flex;flex-direction:column;gap:3px;padding:14px 18px;color:var(--text);text-decoration:none}
.al-list a:hover{background:var(--surface2)}
.al-list b{font-size:var(--t-md);font-weight:600;line-height:1.4}
.al-meta{font-size:var(--t-xs);color:var(--text3);margin:0}
.al-sum{font-size:var(--t-sm);color:var(--text2);line-height:1.5}
.al-pager{display:flex;gap:16px;align-items:center;justify-content:center;margin-top:var(--s4);font-size:var(--t-sm)}
.al-one{max-width:760px;background:var(--surface);border:1px solid var(--line);border-radius:var(--rad-lg);padding:var(--s6)}
@media(max-width:640px){.al-one{padding:var(--s4)}}
.al-one .v4-h1{margin:6px 0 var(--s3)}
.al-lede{font-size:var(--t-lg);line-height:1.6;color:var(--text2);margin:0 0 var(--s4)}
.al-act{display:inline-block;margin:0 0 var(--s4);padding:6px 12px;border-radius:8px;background:var(--amber-tint);color:var(--amber);font-size:var(--t-sm)}
.al-body{font-size:var(--t-base);line-height:1.7;color:var(--text);margin:0 0 var(--s4)}
.al-facts{margin:0;border-top:1px solid var(--line)}
.al-facts div{display:grid;grid-template-columns:110px 1fr;gap:12px;padding:10px 0;border-bottom:1px solid var(--line);font-size:var(--t-sm)}
.al-facts dt{color:var(--text3)}.al-facts dd{margin:0;color:var(--text)}
.al-lock{margin-top:var(--s3);padding:var(--s5);border-radius:var(--rad-lg);background:var(--green-tint);border:1px solid var(--green-ring)}
.al-lock b{font-family:var(--font-d);font-size:var(--t-lg);color:var(--text)}
.al-lock p{margin:6px 0 var(--s4);color:var(--text2);font-size:var(--t-sm);line-height:1.6;max-width:60ch}
.al-more{max-width:760px;margin-top:var(--s6)}
.al-more h2{font-family:var(--font-d);font-size:var(--t-xl);font-weight:500;margin:0 0 var(--s3)}
.al-more p{margin:var(--s3) 0 0;font-size:var(--t-sm)}
.al-more p a{color:var(--green-h,var(--green));font-weight:600;text-decoration:none}
/* Policies and licences */
.pl-presets{display:flex;flex-wrap:wrap;gap:10px;align-items:center;margin:0 0 var(--s4);padding:14px 16px;background:var(--surface);border:1px dashed var(--line2);border-radius:var(--rad-lg)}
.pl-presets p{margin:0;flex:1 1 100%;font-size:var(--t-sm);color:var(--text2)}
.pl-presets form{margin:0}
.pl-preset{display:flex;flex-direction:column;align-items:flex-start;gap:1px;padding:9px 14px;border:1.5px solid var(--green);border-radius:12px;background:var(--surface);font:inherit;color:var(--text);cursor:pointer;text-align:left}
.pl-preset:hover{background:var(--green-tint)}
.pl-preset b{font-size:var(--t-sm);color:var(--green-h,var(--green))}
.pl-preset small{font-size:11px;color:var(--text3)}
.pl-h{font-family:var(--font-d);font-size:var(--t-lg);font-weight:600;margin:0 0 6px}
.pl-row{display:grid;grid-template-columns:minmax(0,1fr) auto auto;gap:14px;align-items:start;padding:12px 0;border-top:1px solid var(--line)}
.pl-h + .pl-row{border-top:0}
.pl-main{display:flex;flex-direction:column;gap:2px;min-width:0}
.pl-main b{font-size:var(--t-sm)}
.pl-main small{font-size:var(--t-xs);color:var(--text3)}
.pl-note{font-style:italic}
.pl-date{text-align:right;display:flex;flex-direction:column}
.pl-date b{font-size:var(--t-sm)}
.pl-date small{font-size:var(--t-xs);color:var(--text3)}
.pl-row.is-amber .pl-date small{color:var(--amber);font-weight:600}
.pl-row.is-red .pl-date small{color:var(--err);font-weight:600}
.pl-acts{display:flex;gap:6px;align-items:flex-start}
.pl-acts .em-renew{font-size:var(--t-xs)}
@media(max-width:640px){.pl-row{grid-template-columns:1fr auto}.pl-acts{grid-column:1/-1}}

