/* Better Bake styles. Colors and lettering come from the VIVAA Cookie badge. */
/* Fonts are self-hosted (SIL Open Font License, see fonts/). */
/* Fonts are self-hosted (SIL Open Font License, see fonts/). */
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: italic; font-weight: 500; font-display: swap; src: url("fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-style: normal; font-weight: 700; font-display: swap; src: url("fonts/cormorant-garamond-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 400; font-display: swap; src: url("fonts/figtree-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 500; font-display: swap; src: url("fonts/figtree-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Figtree"; font-style: normal; font-weight: 600; font-display: swap; src: url("fonts/figtree-latin-600-normal.woff2") format("woff2"); }

:root {
  --cream: #FBF4E6;
  --paper: #FFFBF4;
  --teal: #7DC7C7;        /* the VIVAA Cookie teal: seals, bands, fills */
  --teal-soft: #DDF0EE;   /* tinted surfaces */
  --teal-mist: #EEF7F5;
  --teal-ink: #1B5958;    /* text-safe teal for links and buttons */
  --ink: #2A211B;         /* espresso text */
  --ink-2: #5C4E44;
  --rule: #E4D8C4;
  --crumb: #B98A57;       /* cookie-brown, used sparingly */

  --display: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;

  --s1: .25rem; --s2: .5rem; --s3: .75rem; --s4: 1rem; --s5: 1.5rem; --s6: 2rem; --s7: 3rem; --s8: 4.5rem;
  --radius: 10px;
  --wrap: 74rem;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html { font-variant-numeric: lining-nums; }
body { margin: 0; background: var(--cream); color: var(--ink); font: 400 1.0625rem/1.6 var(--body); overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: var(--teal-ink); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--teal-ink); outline-offset: 3px; border-radius: 4px; }
p { margin: 0 0 var(--s4); }
h1, h2, h3, h4 { font-family: var(--display); font-weight: 600; line-height: 1.08; margin: 0 0 var(--s4); color: var(--ink); }
h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: 1.6rem; }
h4 { font-size: 1.25rem; }
h1:focus, h2:focus, h3:focus { outline: none; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap { width: min(100% - 2.5rem, var(--wrap)); margin-inline: auto; }
.measure { max-width: 42rem; }
.lede { font-size: 1.15rem; color: var(--ink-2); max-width: 40rem; }
.muted { color: var(--ink-2); }
.small { font-size: .925rem; }
.center { text-align: center; }
.skip { position: absolute; left: -999px; top: 0; background: var(--ink); color: var(--paper); padding: var(--s3) var(--s4); z-index: 10; }
.skip:focus { left: var(--s4); top: var(--s4); }

/* ---------- Icons and seals (the Vivaa badge, small) ---------- */
.ico { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; flex: none; vertical-align: -0.2em; }
.ico .fill { fill: currentColor; stroke: none; }
.seal { --d: 3rem; display: inline-grid; place-items: center; flex: none; width: var(--d); height: var(--d); border-radius: 50%; background: var(--teal); color: var(--cream);
  box-shadow: inset 0 0 0 calc(var(--d) * .06) var(--teal), inset 0 0 0 calc(var(--d) * .06 + 1.5px) var(--cream); }
.seal .ico { width: 56%; height: 56%; stroke-width: 2.3; }
.seal-sm { --d: 2.6rem; }
.seal-md { --d: 3.5rem; }
.seal-lg { --d: 4.5rem; }
.seal-xl { --d: 6.5rem; }

/* ---------- Header ---------- */
.site-header { border-bottom: 1px solid var(--rule); background: var(--cream); position: sticky; top: 0; z-index: 5; }
.header-row { display: flex; align-items: center; justify-content: space-between; min-height: 4.25rem; gap: var(--s4); }
.brand { display: inline-flex; align-items: center; gap: .65rem; text-decoration: none; color: var(--ink); }
.brand-mark { width: 1.85rem; height: 1.85rem; border-radius: 50%; background: var(--teal); box-shadow: inset 0 0 0 3px var(--teal), inset 0 0 0 4.5px var(--cream); flex: none; }
.brand-word { font-family: var(--display); font-weight: 600; font-size: 1.45rem; letter-spacing: .14em; text-transform: uppercase; line-height: 1; padding-top: .1em; }
.site-nav ul { list-style: none; display: flex; gap: var(--s5); margin: 0; padding: 0; }
.site-nav a { color: var(--ink); text-decoration: none; font-weight: 500; padding: var(--s2) 0; border-bottom: 2px solid transparent; }
.site-nav a:hover { border-color: var(--rule); }
.site-nav a[aria-current="page"] { border-color: var(--teal); }
.menu-btn { display: none; font: 500 1rem var(--body); background: none; border: 1px solid var(--rule); border-radius: 999px; padding: .5rem 1rem; color: var(--ink); min-height: 44px; }
@media (max-width: 720px) {
  .menu-btn { display: inline-block; }
  .site-nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--cream); border-bottom: 1px solid var(--rule); }
  .site-nav.open { display: block; }
  .site-nav ul { flex-direction: column; gap: 0; padding: var(--s2) 1.25rem var(--s4); }
  .site-nav a { display: block; padding: var(--s3) 0; border-bottom: 1px solid var(--rule); }
  .site-nav a[aria-current="page"] { border-color: var(--rule); color: var(--teal-ink); font-weight: 600; }
}

/* ---------- Buttons ---------- */
.btn-row { display: flex; flex-wrap: wrap; gap: var(--s3); margin-top: var(--s5); }
.center-row { justify-content: center; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 48px; padding: .7rem 1.35rem; border-radius: 999px; font: 600 1rem var(--body); text-decoration: none; border: 1.5px solid var(--teal-ink); cursor: pointer; transition: background-color .15s, transform .1s; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--teal-ink); color: var(--paper); }
.btn-primary:hover { background: #134443; }
.btn-ghost { background: transparent; color: var(--teal-ink); }
.btn-ghost:hover { background: var(--teal-soft); }
.btn-quiet { background: transparent; color: var(--ink-2); border-color: transparent; text-decoration: underline; text-underline-offset: .18em; }
.btn-sm { min-height: 44px; padding: .5rem 1.1rem; font-size: .95rem; }

/* ---------- Sections ---------- */
.section { padding-block: var(--s8); }
.section.tight { padding-top: var(--s6); }
.band { background: var(--teal-soft); }
.soft { background: var(--paper); border-block: 1px solid var(--rule); }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: var(--s4); margin-bottom: var(--s6); }
.section-head h2 { margin: 0; }
.section-head p { margin: 0; max-width: 32rem; color: var(--ink-2); }
.page-hero { padding-block: var(--s8) var(--s6); }
.divider { display: flex; align-items: center; justify-content: center; gap: var(--s3); color: var(--teal); margin-bottom: var(--s5); }
.divider span { width: 3rem; height: 2px; background: var(--teal); border-radius: 2px; }
.divider .ico { width: 2rem; height: 2rem; }

/* ---------- Hero ---------- */
.hero { padding-block: var(--s7) var(--s8); }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: var(--s7); align-items: center; }
.hero h1 { max-width: 14ch; }
.tagline { font-family: var(--display); font-style: italic; font-size: 1.45rem; color: var(--teal-ink); margin-bottom: var(--s3); }
.hero-fig { margin: 0; }
.badge-stage { position: relative; width: min(100%, 30rem); margin-inline: auto; padding: 1.6rem; }
.badge { position: relative; width: 100%; aspect-ratio: 1; border-radius: 50%; background: var(--teal); padding: 7%; }
.badge::before, .badge::after { content: ""; position: absolute; top: 50%; width: 3.2%; aspect-ratio: 1; border-radius: 50%; background: var(--cream); transform: translateY(-50%); }
.badge::before { left: 2%; }
.badge::after { right: 2%; }
.badge-inner { width: 100%; height: 100%; border-radius: 50%; padding: 2.2%; border: 2px solid var(--cream); }
.badge img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; }
.orbit { position: absolute; display: flex; flex-direction: column; align-items: center; gap: .25rem; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .85rem; }
.orbit .seal { --d: 4rem; box-shadow: inset 0 0 0 4px var(--teal), inset 0 0 0 5.5px var(--cream), 0 0 0 4px var(--cream); transition: transform .2s ease; }
.orbit:hover .seal, .orbit:focus-visible .seal { transform: rotate(-8deg) scale(1.08); }
.orbit-label { background: var(--cream); padding: 0 .4rem; border-radius: 4px; }
.orbit-0 { top: 0; left: 0; }
.orbit-1 { top: 0; right: 0; }
.orbit-2 { bottom: 0; left: 0; }
.orbit-3 { bottom: 0; right: 0; }
.badge-caption { text-align: center; margin-top: var(--s3); font-size: .9rem; color: var(--ink-2); }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: var(--s5); }
  .hero { padding-block: var(--s6) var(--s7); }
  .hero h1 { max-width: 16ch; }
  .badge-stage { width: min(100%, 24rem); }
  .orbit .seal { --d: 3.2rem; }
}

/* ---------- Swap Finder ---------- */
.finder-card { background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; padding: clamp(1.25rem, 4vw, 2.5rem); min-height: 20rem; }
.finder-progress { font-size: .9rem; font-weight: 600; color: var(--teal-ink); margin-bottom: var(--s2); }
.finder-q { font-size: clamp(1.7rem, 3.4vw, 2.3rem); margin-bottom: var(--s5); }
.choice-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: var(--s3); }
.choice-grid.four { grid-template-columns: repeat(4, 1fr); }
.choice { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s3); min-height: 9.5rem; padding: var(--s5) var(--s4); background: var(--cream); border: 1.5px solid var(--rule); border-radius: 14px; font: inherit; color: var(--ink); cursor: pointer; text-align: center; transition: border-color .15s, background-color .15s, transform .15s; }
.choice:hover { border-color: var(--teal-ink); background: var(--teal-mist); transform: translateY(-2px); }
.choice-title { font-family: var(--display); font-size: 1.5rem; font-weight: 600; line-height: 1.15; }
.choice-wide { align-items: flex-start; text-align: left; min-height: 7rem; }
.choice-wide .choice-title { font-size: 1.35rem; }
.choice-hint { font-size: .925rem; color: var(--ink-2); }
.back-btn { background: none; border: 0; padding: var(--s2) 0; margin-bottom: var(--s2); font: 600 .95rem var(--body); color: var(--teal-ink); cursor: pointer; min-height: 44px; }
.back-btn::before { content: "‹ "; }
.result-head { display: flex; gap: var(--s4); align-items: center; margin-bottom: var(--s5); }
.result-head h3 { margin-bottom: var(--s1); }
.result-head p { margin: 0; }
.result-kicker { font-weight: 600; color: var(--teal-ink); font-size: .95rem; margin-bottom: 0 !important; }
.result-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); align-items: start; }
@media (max-width: 860px) { .choice-grid.four { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .result-grid { grid-template-columns: 1fr; gap: var(--s5); } }
@media (max-width: 400px) { .choice { min-height: 8rem; } }

/* ---------- Calculator ---------- */
.calc { background: var(--teal-soft); border-radius: 14px; padding: var(--s5); }
.stepper-wrap { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2) var(--s4); margin-bottom: var(--s4); }
.stepper-label { font-weight: 600; font-size: .95rem; width: 100%; }
.stepper { display: inline-flex; align-items: center; background: var(--paper); border: 1.5px solid var(--teal-ink); border-radius: 999px; }
.step-btn { width: 48px; height: 48px; border: 0; background: none; font: 600 1.5rem/1 var(--body); color: var(--teal-ink); cursor: pointer; border-radius: 50%; }
.step-btn:hover:not([disabled]) { background: var(--teal-soft); }
.step-btn[disabled] { color: #B8B0A4; cursor: not-allowed; }
.step-val { min-width: 6.5rem; text-align: center; font-size: 1.15rem; font-weight: 600; }
.stepper-hint { font-size: .9rem; color: var(--ink-2); }
.calc-head { font-size: .875rem; font-weight: 600; color: var(--teal-ink); margin-bottom: var(--s2); }
.calc-list { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--s2); }
.calc-list li { background: var(--paper); border-radius: 8px; padding: var(--s3) var(--s4); line-height: 1.35; }
.calc-list strong { font-size: 1.1rem; font-weight: 600; margin-right: .2rem; color: var(--teal-ink); }
.calc-list .g { color: var(--ink-2); white-space: nowrap; }
.calc-list .adjust { background: transparent; border: 1.5px dashed var(--teal); }
.calc-note { font-size: .9rem; color: var(--ink-2); margin: var(--s3) 0 0; }
.calc-ratio { margin: 0; }

/* ---------- Tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--s4); list-style: none; margin: 0; padding: 0; }
.tile { display: flex; flex-direction: column; height: 100%; text-decoration: none; color: var(--ink); background: var(--paper); border: 1px solid var(--rule); border-radius: 14px; padding: var(--s5); transition: border-color .15s, transform .15s; }
.tile:hover { border-color: var(--teal-ink); transform: translateY(-3px); }
.tile:hover .seal { transform: rotate(-8deg); }
.tile .seal { margin-bottom: var(--s4); transition: transform .2s ease; }
.tile h2, .tile h3 { font-size: 2.1rem; margin-bottom: var(--s2); }
.tile .tile-sub { font-family: var(--display); font-style: italic; font-size: 1.15rem; color: var(--teal-ink); margin-bottom: var(--s3); }
.tile p { color: var(--ink-2); font-size: .975rem; }
.tile .tile-count { margin-top: auto; padding-top: var(--s4); border-top: 1px solid var(--rule); font-size: .925rem; font-weight: 600; color: var(--teal-ink) !important; margin-bottom: 0; }
@media (max-width: 980px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .tiles { grid-template-columns: 1fr; } .tile { flex-direction: row; flex-wrap: wrap; gap: 0 var(--s4); } .tile .seal { margin-bottom: 0; } .tile h2, .tile h3 { align-self: center; margin: 0; } .tile-sub, .tile p { width: 100%; } .tile-sub { margin-top: var(--s3); } }

/* ---------- Steps ---------- */
.steps { list-style: none; counter-reset: step; display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s6); padding: 0; margin: 0 0 var(--s6); }
.steps li { counter-increment: step; }
.steps li::before { content: counter(step); display: grid; place-items: center; width: 3rem; height: 3rem; border-radius: 50%; background: var(--teal); color: var(--cream); font-size: 1.25rem; font-weight: 600; margin-bottom: var(--s3); box-shadow: inset 0 0 0 3px var(--teal), inset 0 0 0 4.5px var(--cream); }
.steps h3 { font-size: 1.5rem; margin-bottom: var(--s2); }
.steps p { color: var(--ink-2); margin: 0; }
.example { display: flex; gap: var(--s4); align-items: flex-start; max-width: 46rem; background: var(--teal-mist); border-radius: 12px; padding: var(--s4) var(--s5); }
.example .ico { width: 2rem; height: 2rem; color: var(--teal-ink); margin-top: .1rem; }
@media (max-width: 780px) { .steps { grid-template-columns: 1fr; gap: var(--s5); } }

.risk { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s5); margin-top: var(--s7); }
.risk-card { background: var(--cream); border: 1px solid var(--rule); border-radius: 14px; padding: var(--s5); }
.risk-card h3 { font-size: 1.5rem; display: flex; align-items: center; gap: .5rem; }
.risk-card h3 .ico { color: var(--teal-ink); width: 1.6rem; height: 1.6rem; }
.risk-card.tricky { background: #FCF0E2; border-color: #EBD6BC; }
.risk-card.tricky h3 .ico { color: var(--crumb); }
.risk ul { margin: 0; padding-left: 1.1rem; }
.risk li { margin-bottom: var(--s2); }
.risk-note { grid-column: 1 / -1; color: var(--ink-2); margin: 0; }
.page-hero + .section .risk, .section .tiles + .risk { margin-top: var(--s7); }
@media (max-width: 700px) { .risk { grid-template-columns: 1fr; } }

/* ---------- Comparison preview ---------- */
.preview { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; border: 1px solid var(--rule); border-radius: 14px; background: var(--paper); }
.preview-col { padding: var(--s5) var(--s6); }
.preview-col .seal { margin-bottom: var(--s3); }
.preview-vs { display: grid; place-items: center; font-family: var(--display); font-style: italic; font-size: 1.6rem; color: var(--teal-ink); border-inline: 1px solid var(--rule); padding: 0 var(--s4); }
.preview h3 { font-size: 1.9rem; margin-bottom: var(--s2); }
.preview dt { font-size: .875rem; font-weight: 600; color: var(--ink-2); margin-top: var(--s4); }
.preview dd { margin: var(--s1) 0 0; }
@media (max-width: 640px) { .preview { grid-template-columns: 1fr; } .preview-vs { border-inline: 0; border-block: 1px solid var(--rule); padding: var(--s2); } }

.story-teaser { display: grid; grid-template-columns: 9rem 1fr; gap: var(--s6); align-items: center; max-width: 50rem; }
.story-teaser img { width: 9rem; height: 9rem; border-radius: 50%; }
.story-teaser h2 { font-size: 2.2rem; }
@media (max-width: 560px) { .story-teaser { grid-template-columns: 1fr; text-align: center; } .story-teaser img { margin-inline: auto; } .story-teaser .btn { margin-inline: auto; } }

/* ---------- Tags ---------- */
.tags { display: flex; flex-wrap: wrap; gap: var(--s2); list-style: none; padding: 0; margin: 0; }
.tag { display: inline-block; padding: .2rem .75rem; border-radius: 999px; background: var(--teal-soft); color: var(--teal-ink); font-size: .875rem; font-weight: 600; }
.tag-miss { background: transparent; color: var(--ink-2); border: 1px dashed #BFAF98; font-weight: 500; }

/* ---------- Guide page ---------- */
.guide-hero { padding-block: var(--s7); border-bottom: 1px solid var(--rule); }
.guide-hero-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: var(--s7); align-items: start; }
.crumbs { font-size: .925rem; margin-bottom: var(--s4); color: var(--ink-2); }
.guide-title { display: flex; align-items: center; gap: var(--s5); margin-bottom: var(--s5); }
.guide-title h1 { font-size: clamp(3.2rem, 8vw, 5.6rem); margin: 0; }
.guide-title .sub { font-family: var(--display); font-style: italic; font-size: 1.5rem; color: var(--teal-ink); margin: 0; }
.why-line { border-left: 3px solid var(--teal); padding-left: var(--s4); font-size: 1.05rem; font-style: italic; color: var(--ink); }
.guide-photo { border-radius: 14px; margin-top: var(--s5); }
@media (max-width: 900px) { .guide-hero-grid { grid-template-columns: 1fr; gap: var(--s6); } }
@media (max-width: 520px) { .guide-title { gap: var(--s4); } .guide-title .seal-xl { --d: 4.5rem; } }

.quiz { background: var(--teal-ink); color: var(--paper); border-radius: 18px; padding: var(--s5) var(--s5) var(--s4); position: sticky; top: 5.5rem; }
.quiz-kicker { display: flex; align-items: center; gap: .5rem; font-weight: 600; color: #BFE7E4; font-size: .95rem; }
.quiz-q { color: var(--paper); font-size: 1.6rem; line-height: 1.2; }
.quiz-opts { display: grid; gap: var(--s2); }
.quiz-opt { min-height: 48px; text-align: left; padding: .7rem 1rem; border-radius: 10px; border: 1.5px solid rgba(255,251,244,.4); background: transparent; color: var(--paper); font: 500 1rem var(--body); cursor: pointer; }
.quiz-opt:hover { background: rgba(255,251,244,.1); }
.quiz-opt.is-right { background: var(--paper); color: var(--teal-ink); border-color: var(--paper); font-weight: 600; }
.quiz-opt.is-right::after { content: "  ✓"; }
.quiz-opt.is-wrong { border-style: dashed; opacity: .75; }
.quiz-result p { margin: var(--s4) 0 0; font-size: .975rem; }
.quiz-result .cite a { color: #CFF0EE; }
.quiz :focus-visible { outline-color: var(--paper); }
@media (max-width: 900px) { .quiz { position: static; } }

.functions { display: grid; grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); gap: var(--s4); }
.fn { background: var(--paper); border: 1px solid var(--rule); border-top: 4px solid var(--teal); border-radius: 12px; padding: var(--s5); }
.fn h3 { font-size: 1.5rem; margin-bottom: var(--s2); }
.fn p { color: var(--ink-2); font-size: 1rem; margin: 0; }

.chips { display: flex; flex-wrap: wrap; gap: var(--s2); margin-bottom: var(--s3); }
.chip { min-height: 44px; padding: .45rem 1rem; border-radius: 999px; border: 1.5px solid var(--teal-ink); background: var(--paper); color: var(--teal-ink); font: 600 .95rem var(--body); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--teal-ink); color: var(--paper); }
.filter-status { min-height: 1.6em; font-weight: 500; color: var(--ink); }
.dir { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: var(--s4); }
.dir.is-empty { display: none; }
.dir-card { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto auto; column-gap: var(--s4); align-items: center; height: 100%; padding: var(--s4) var(--s5); background: var(--paper); border: 1.5px solid var(--rule); border-radius: 14px; color: var(--ink); text-decoration: none; transition: border-color .15s, transform .15s; }
.dir-card:hover { border-color: var(--teal-ink); transform: translateY(-2px); }
.dir-card .seal { grid-row: 1 / 4; align-self: start; }
.dir-name { font-family: var(--display); font-weight: 600; font-size: 1.4rem; line-height: 1.1; }
.dir-what { color: var(--ink-2); font-size: .95rem; margin-top: var(--s1); }
.dir-jobs { color: var(--teal-ink); font-size: .85rem; font-weight: 600; margin-top: var(--s2); }

.science-grid { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s5); }
.note-box { background: var(--paper); border: 1px solid var(--rule); border-left: 4px solid var(--teal); border-radius: 12px; padding: var(--s5); }
.note-box h3, .box-h { font-size: 1.5rem; margin-bottom: var(--s2); }
.note-box p:last-child { margin-bottom: 0; }
.note-box.key { background: var(--teal); border-color: var(--teal); color: var(--ink); }
.note-box.key a { color: var(--ink); }
@media (max-width: 760px) { .science-grid { grid-template-columns: 1fr; } }

.profile { background: var(--cream); border: 1px solid var(--rule); border-radius: 18px; padding: var(--s6); margin-bottom: var(--s5); scroll-margin-top: 5.5rem; }
.profile:target, .profile:focus { border-color: var(--teal-ink); box-shadow: 0 0 0 3px var(--teal); outline: none; }
.profile-head { display: flex; align-items: center; gap: var(--s4); border-bottom: 1px solid var(--rule); padding-bottom: var(--s4); margin-bottom: var(--s5); }
.profile-title { flex: 1; }
.profile-title h3 { font-size: clamp(1.9rem, 4vw, 2.5rem); margin-bottom: var(--s1); }
.profile-title p { margin: 0; color: var(--ink-2); font-size: 1.05rem; }
.profile-body { display: grid; grid-template-columns: 1.15fr 1fr; gap: var(--s6); align-items: start; }
.field { margin-bottom: var(--s4); }
.field:last-child { margin-bottom: 0; }
.field h4 { font-family: var(--body); font-size: .9rem; font-weight: 600; color: var(--teal-ink); margin-bottom: var(--s1); }
.field p { margin: 0; }
.my-note { margin-top: var(--s5); background: #FCF0E2; border-radius: 12px; padding: var(--s4) var(--s5); }
.my-note h4 { font-family: var(--body); font-size: .9rem; color: #7A4F22; margin-bottom: var(--s1); }
.my-note p { margin: 0; }
details.more { margin-top: var(--s5); border-top: 1px solid var(--rule); }
details.more summary { cursor: pointer; padding: var(--s4) 0; font-weight: 600; color: var(--teal-ink); min-height: 44px; }
.more-body { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s4) var(--s6); padding-bottom: var(--s3); }
.evidence { font-size: .9rem; color: var(--ink-2); border-top: 1px solid var(--rule); margin: var(--s3) 0 0; padding-top: var(--s3); }
.cite { font-size: .78rem; vertical-align: super; line-height: 0; margin-left: .1em; }
.cite a { text-decoration: none; font-weight: 600; }
@media (max-width: 760px) {
  .profile { padding: var(--s5); }
  .profile-head { flex-wrap: wrap; }
  .profile-head .seal-lg { --d: 3.5rem; }
  .profile-title { flex: 1 1 10rem; }
  .profile-head .btn { order: 3; flex-basis: 100%; }
  .profile-body > .calc { order: -1; }
  .profile-body, .more-body { grid-template-columns: 1fr; gap: var(--s5); }
}

.verdict { font-family: var(--display); font-size: clamp(1.5rem, 3vw, 2.1rem); line-height: 1.3; font-weight: 500; max-width: 46rem; margin-inline: auto; text-align: center; }
.source-list { padding-left: 1.6rem; margin: 0; }
.source-list li { margin-bottom: var(--s3); padding-left: var(--s2); }
.source-list .kind { color: var(--ink-2); font-size: .9rem; }
.flag { display: inline-block; font-size: .85rem; background: #FBE7C9; color: #6B4413; border-radius: 4px; padding: 0 .4rem; margin-left: .3rem; }

/* ---------- Compare ---------- */
.compare-controls { background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; padding: var(--s5); margin-bottom: var(--s6); }
.seg { display: flex; flex-wrap: wrap; gap: var(--s2); border: 0; padding: 0; margin: 0 0 var(--s5); }
.seg legend { font-weight: 600; margin-bottom: var(--s3); padding: 0; }
.seg label { position: relative; }
.seg input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.seg span { display: inline-flex; align-items: center; gap: .45rem; min-height: 48px; padding: .5rem 1.15rem; border: 1.5px solid var(--rule); border-radius: 999px; background: var(--cream); font-weight: 600; cursor: pointer; }
.seg span .ico { color: var(--teal-ink); }
.seg input:checked + span { background: var(--teal-ink); border-color: var(--teal-ink); color: var(--paper); }
.seg input:checked + span .ico { color: var(--paper); }
.seg input:focus-visible + span { outline: 3px solid var(--teal-ink); outline-offset: 3px; }
.pickers { display: grid; grid-template-columns: 1fr auto 1fr; gap: var(--s4); align-items: end; margin-bottom: var(--s5); }
.picker label { display: block; font-weight: 600; margin-bottom: var(--s2); }
.picker select { width: 100%; min-height: 52px; font: 500 1.05rem var(--body); color: var(--ink); background: var(--cream); border: 1.5px solid var(--rule); border-radius: 12px; padding: .55rem 2.25rem .55rem .9rem; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%231B5958' stroke-width='2'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .9rem center; }
.swap-btn { width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid var(--teal-ink); background: var(--paper); color: var(--teal-ink); font-size: 1.3rem; cursor: pointer; }
.swap-btn:hover { background: var(--teal-soft); }
.compare-status { margin: var(--s3) 0 0; font-size: .95rem; color: var(--ink-2); min-height: 1.4em; }
@media (max-width: 640px) { .pickers { grid-template-columns: 1fr; } .swap-btn { justify-self: center; transform: rotate(90deg); } }

.ctable { width: 100%; border-collapse: separate; border-spacing: 0; table-layout: fixed; background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; overflow: hidden; }
.ctable th, .ctable td { text-align: left; vertical-align: top; padding: var(--s4) var(--s5); border-bottom: 1px solid var(--rule); }
.ctable tbody tr:last-child th, .ctable tbody tr:last-child td { border-bottom: 0; }
.ctable thead th { padding-block: var(--s5); background: var(--teal-mist); border-bottom: 2px solid var(--teal); }
.ctable thead th:first-child { width: 11rem; }
.ctable thead .seal { margin-bottom: var(--s3); }
.ctable .col-name { font-family: var(--display); font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 600; line-height: 1.05; display: block; }
.ctable .col-what { display: block; font-weight: 400; color: var(--ink-2); margin-top: var(--s2); font-size: 1rem; }
.ctable tbody th { font-size: .925rem; font-weight: 600; color: var(--teal-ink); }
.ctable td + td { border-left: 1px solid var(--rule); }
.ctable td p { margin: 0; }
.ctable .na { color: var(--ink-2); font-style: italic; }
.ctable .profile-link { font-weight: 600; }
.coverage { list-style: none; padding: 0; margin: 0; display: grid; gap: .35rem; }
.coverage li { display: flex; align-items: center; gap: .55rem; font-size: .95rem; }
.coverage .mark { display: grid; place-items: center; width: 1.5rem; height: 1.5rem; border-radius: 50%; font-size: .85rem; font-weight: 700; flex: none; }
.coverage .on .mark { background: var(--teal-ink); color: var(--paper); }
.coverage .on { font-weight: 600; }
.coverage .off { color: #8C7F73; }
.coverage .off .mark { border: 1.5px dashed #BFAF98; color: #8C7F73; }
@media (max-width: 720px) {
  .ctable, .ctable tbody, .ctable tr, .ctable th, .ctable td { display: block; width: 100%; }
  .ctable thead { display: grid; grid-template-columns: 1fr 1fr; }
  .ctable thead tr { display: contents; }
  .ctable thead th:first-child { display: none; }
  .ctable thead th { padding: var(--s4); }
  .ctable thead th + th { border-left: 1px solid var(--rule); }
  .ctable .col-name { font-size: 1.45rem; }
  .ctable .col-what { font-size: .9rem; }
  .ctable thead .seal { --d: 2.8rem; }
  .ctable tbody tr { border-bottom: 1px solid var(--rule); padding: var(--s4); }
  .ctable tbody th { padding: 0 0 var(--s2); border: 0; }
  .ctable tbody td { border: 0; padding: var(--s2) 0; }
  .ctable td + td { border-left: 0; border-top: 1px dashed var(--rule); }
  .ctable td::before { content: attr(data-name); display: block; font-family: var(--display); font-weight: 600; font-size: 1.15rem; margin-bottom: var(--s1); }
}
details.why { margin-top: var(--s6); background: var(--paper); border: 1px solid var(--rule); border-radius: 18px; }
details.why summary { cursor: pointer; padding: var(--s5); font-family: var(--display); font-size: 1.6rem; font-weight: 600; min-height: 44px; }
details.why[open] summary { border-bottom: 1px solid var(--rule); }
.why-body { padding: var(--s5); }
.why-cols { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s6); margin-bottom: var(--s5); }
.why-cols h3 { font-size: 1.4rem; margin-bottom: var(--s2); }
@media (max-width: 640px) { .why-cols { grid-template-columns: 1fr; gap: var(--s4); } }
.empty { background: var(--paper); border: 1px dashed #BFAF98; border-radius: 14px; padding: var(--s6); text-align: center; }

/* ---------- About ---------- */
.about-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: var(--s8); align-items: start; }
.about-text p { font-size: 1.125rem; line-height: 1.7; }
.signature { font-family: var(--display); font-style: italic; font-size: 1.8rem !important; color: var(--teal-ink); }
.viva { display: grid; grid-template-columns: 11rem 1fr; gap: var(--s6); align-items: center; }
.viva img { width: 11rem; height: 11rem; border-radius: 50%; }
.viva h2 { font-size: 2.2rem; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; gap: var(--s6); } }
@media (max-width: 560px) { .viva { grid-template-columns: 1fr; text-align: center; } .viva img { margin-inline: auto; width: 9rem; height: 9rem; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #EDE3D3; padding-block: var(--s7); }
.site-footer a { color: #EDE3D3; }
.footer-grid { display: grid; grid-template-columns: 1fr 1fr 1.6fr; gap: var(--s6); }
.footer-brand { font-family: var(--display); font-size: 1.5rem; letter-spacing: .14em; text-transform: uppercase; font-weight: 600; margin-bottom: var(--s2); }
.footer-links { list-style: none; padding: 0; margin: 0; columns: 2; }
.footer-links li { margin-bottom: var(--s2); }
.footer-note p { font-size: .925rem; color: #CFC3B1; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } .choice:hover, .tile:hover, .dir-card:hover { transform: none; } }

/* ---------- Photos of my bakes ---------- */
.gallery { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--s4); grid-auto-flow: dense; }
.gallery.three { grid-template-columns: repeat(3, 1fr); margin-top: var(--s6); }
.photo { margin: 0; }
.photo.wide { grid-column: span 2; grid-row: span 2; }
.photo-btn { display: block; width: 100%; padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 14px; overflow: hidden; }
.photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; border-radius: 14px; transition: transform .3s ease; }
.photo.wide img { aspect-ratio: auto; height: 100%; min-height: 100%; }
.photo.wide .photo-btn { height: calc(100% - 3.2rem); }
.photo-btn:hover img { transform: scale(1.03); }
.photo figcaption { font-size: .9rem; color: var(--ink-2); margin-top: var(--s2); line-height: 1.4; }
.photo.small img { aspect-ratio: 1; }
@media (max-width: 860px) { .gallery { grid-template-columns: repeat(2, 1fr); } .photo.wide { grid-row: auto; } .photo.wide img { aspect-ratio: 4 / 3; height: auto; } .photo.wide .photo-btn { height: auto; } }
@media (max-width: 520px) { .gallery.three { grid-template-columns: 1fr 1fr; } .gallery.three .photo:first-child { grid-column: span 2; } }

.lightbox { border: 0; padding: var(--s4); border-radius: 18px; background: var(--paper); max-width: min(92vw, 52rem); max-height: 92vh; }
.lightbox::backdrop { background: rgba(42, 33, 27, .7); }
.lightbox img { max-height: 76vh; width: auto; max-width: 100%; margin: 0 auto; border-radius: 12px; }
.lb-cap { text-align: center; margin: var(--s3) 0 0; color: var(--ink-2); }
.lightbox form { display: flex; justify-content: flex-end; margin: 0 0 var(--s2); }
.lb-close { width: 44px; height: 44px; border-radius: 50%; border: 1.5px solid var(--teal-ink); background: var(--paper); color: var(--teal-ink); font-size: 1.5rem; line-height: 1; cursor: pointer; }

.guide-photo { margin: var(--s5) 0 0; }
.guide-photo img { border-radius: 14px; max-height: 34rem; width: auto; max-width: 100%; }
.guide-photo figcaption { display: flex; align-items: center; gap: .5rem; font-size: .95rem; color: var(--ink-2); margin-top: var(--s2); }
.guide-photo figcaption .ico, .kitchen-strip h4 .ico { color: var(--teal-ink); width: 1.4rem; height: 1.4rem; }
.kitchen-strip { margin-top: var(--s5); background: var(--paper); border: 1px solid var(--rule); border-radius: 14px; padding: var(--s4) var(--s5); }
.kitchen-strip h4 { display: flex; align-items: center; gap: .4rem; font-family: var(--body); font-size: .95rem; color: var(--teal-ink); margin-bottom: var(--s3); }
.kitchen-photos { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 13rem)); gap: var(--s4); }

.about-hero h1 { max-width: 20ch; }
.about-side { display: grid; gap: var(--s5); }
.about-side .photo img { aspect-ratio: 1; }
.about-text .closing, .closing { font-family: var(--display); font-size: clamp(1.8rem, 4vw, 2.6rem); line-height: 1.2; text-align: center; font-weight: 600; color: var(--teal-ink); }
.divider .ico { stroke-width: 1.8; }

/* ---------- Single tools pasted into Google Sites pages ---------- */
body.embed { background: transparent; }
body.embed main { padding: 6px 4px 24px; }
body.embed .finder-card { min-height: 0; }
body.embed .tool-h { font-size: 2rem; margin-bottom: var(--s2); }
body.embed .tool-swaps .dir { margin-bottom: var(--s6); }
body.embed .quiz { position: static; margin-bottom: var(--s6); }
body.embed .compare-controls { margin-bottom: var(--s5); }
body.embed .section.tight { padding: 0; }
body.embed .section .wrap { width: 100%; }
.embed-viva { grid-template-columns: 7rem 1fr; gap: var(--s4); margin-bottom: var(--s4); }
.embed-viva img { width: 7rem; height: 7rem; }
.embed-viva p { margin: 0; }
