:root {
  --cream: #fbf6ee;
  --cream-2: #f6ecdd;
  --paper: #ffffff;
  --ink: #2a211a;
  --ink-soft: #5b4d40;
  --muted: #8a7a69;
  --line: #eee2d1;
  --line-strong: #e2d2ba;
  --accent: #c2410c;
  --accent-2: #e8834a;
  --accent-dark: #9a3412;
  --accent-soft: #fdeee2;
  --sage: #5b7b2e;
  --sage-soft: #eef4e0;
  --shadow: 0 1px 2px rgba(42, 33, 26, .05), 0 18px 40px -20px rgba(42, 33, 26, .28);
  --shadow-sm: 0 1px 2px rgba(42, 33, 26, .06), 0 6px 16px -8px rgba(42, 33, 26, .16);
  --radius: 20px;
  --radius-sm: 12px;
  --serif: Georgia, "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--cream); color: var(--ink); font-family: var(--sans);
  font-size: 17px; line-height: 1.65; -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 700; line-height: 1.15; color: var(--ink); margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2.1rem, 1.3rem + 3.2vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.1rem); }
h3 { font-size: 1.25rem; }
p { margin: 0 0 1em; color: var(--ink-soft); }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }
.wrap { max-width: 1060px; margin: 0 auto; padding: 0 20px; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(251, 246, 238, .85); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: 66px; }
.logo { display: flex; align-items: center; gap: 10px; font-family: var(--serif); font-weight: 700; font-size: 1.22rem; color: var(--ink); }
.logo:hover { text-decoration: none; color: var(--ink); }
.logo-mark { width: 30px; height: 30px; border-radius: 9px; flex: none; background: linear-gradient(135deg, var(--accent), var(--accent-2)); display: grid; place-items: center; color: #fff; font-size: 15px; box-shadow: inset 0 -2px 4px rgba(0,0,0,.2); }
.nav { display: flex; gap: 22px; align-items: center; }
.nav a { color: var(--ink-soft); font-size: .95rem; font-weight: 500; }
.nav a:hover { color: var(--accent); text-decoration: none; }
@media (max-width: 760px) { .nav { display: none; } }

/* Hero */
.hero { position: relative; padding: 54px 0 10px; overflow: hidden; }
.hero-bg { position: absolute; inset: 0; z-index: -1; background:
  radial-gradient(600px 320px at 12% 0%, #fbe3cf 0%, rgba(251,227,207,0) 70%),
  radial-gradient(700px 380px at 92% 8%, #f4efe0 0%, rgba(244,239,224,0) 72%),
  linear-gradient(180deg, #fff8ef 0%, var(--cream) 78%); }
.hero-grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 44px; align-items: center; padding: 20px 0 6px; }
.hero-copy, .hero-visual { min-width: 0; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: 1fr; gap: 30px; text-align: center; } }
.eyebrow { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); background: var(--accent-soft); padding: 7px 15px; border-radius: 999px; margin-bottom: 20px; }
.hero h1 { margin-bottom: 18px; }
.hero .lead { font-size: 1.16rem; max-width: 30ch; margin: 0 0 24px; }
@media (max-width: 860px) { .hero .lead { margin-inline: auto; } }
.badges { display: flex; gap: 10px; flex-wrap: wrap; }
@media (max-width: 860px) { .badges { justify-content: center; } }
.badge { display: inline-flex; align-items: center; gap: 7px; font-size: .86rem; font-weight: 600; color: var(--ink-soft); background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; box-shadow: var(--shadow-sm); }
.badge i { width: 8px; height: 8px; border-radius: 50%; background: var(--sage); display: inline-block; }

/* Hero visual (scaled recipe mock) */
.hero-visual { position: relative; }
.hv-card { background: var(--paper); border: 1px solid var(--line); border-radius: 22px; box-shadow: var(--shadow); overflow: hidden; transform: rotate(-1.4deg); }
@media (max-width: 860px) { .hv-card { transform: none; max-width: 440px; margin: 0 auto; } }
.hv-strip { height: 92px; background: linear-gradient(120deg, #f6c9a4, #e8834a 55%, #c2410c); position: relative; }
.hv-strip::after { content: ""; position: absolute; inset: 0; background: radial-gradient(180px 90px at 78% 20%, rgba(255,255,255,.5), rgba(255,255,255,0) 70%); }
.hv-body { padding: 20px 22px 24px; }
.hv-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 4px; }
.hv-tag { font-size: .74rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.hv-x { font-family: var(--serif); font-weight: 700; color: var(--accent); font-size: 1.15rem; background: var(--accent-soft); padding: 4px 12px; border-radius: 999px; }
.hv-serv { font-family: var(--serif); font-size: 1.2rem; color: var(--ink); margin-bottom: 14px; }
.hv-serv span { color: var(--accent); }
.hv-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.hv-list li { display: flex; justify-content: space-between; align-items: center; padding: 11px 0; border-top: 1px dashed var(--line); font-size: .96rem; }
.hv-list li:first-child { border-top: 0; }
.hv-list .nm { color: var(--ink-soft); }
.hv-list .num { font-variant-numeric: tabular-nums; color: var(--muted); }
.hv-list .num b { color: var(--sage); font-weight: 700; }
.hv-float { position: absolute; left: -20px; top: 26px; background: #fff; border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); padding: 10px 14px; font-size: .85rem; font-weight: 600; color: var(--ink); display: flex; align-items: center; gap: 8px; transform: rotate(-1.4deg); }
.hv-float .dot { width: 22px; height: 22px; border-radius: 7px; background: var(--sage-soft); color: var(--sage); display: grid; place-items: center; font-size: 13px; }
@media (max-width: 860px) { .hv-float { left: 0; top: 14px; } }

/* Tool card */
.tool { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; margin: 34px 0 8px; }
.tabs { display: flex; border-bottom: 1px solid var(--line); background: var(--cream-2); }
.tab { flex: 1; padding: 16px; border: 0; background: transparent; cursor: pointer; font-family: var(--sans); font-size: 1rem; font-weight: 600; color: var(--muted); position: relative; }
.tab:hover { color: var(--ink); }
.tab.active { color: var(--accent); background: var(--paper); }
.tab.active::after { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 3px; background: var(--accent); }
.panel { padding: 26px; display: none; }
.panel.active { display: block; }
.grid { display: grid; gap: 16px; }
.grid.cols-2 { grid-template-columns: 1fr 1fr; }
.grid.cols-3 { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 620px) { .grid.cols-2, .grid.cols-3 { grid-template-columns: 1fr; } }
label.fld { display: block; font-size: .78rem; font-weight: 700; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .05em; }
input, select { width: 100%; padding: 12px 14px; font-size: 1rem; font-family: var(--sans); color: var(--ink); background: var(--cream); border: 1px solid var(--line-strong); border-radius: var(--radius-sm); outline: none; transition: border-color .15s, box-shadow .15s; }
input:focus, select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
select { 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 fill='%238a7a69' d='M6 8L0 0h12z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }
.result { margin-top: 18px; padding: 20px; border-radius: var(--radius-sm); background: var(--sage-soft); border: 1px solid #d8e6ba; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.result .big { font-family: var(--serif); font-size: 1.9rem; font-weight: 700; color: var(--sage); }
.result .sub { color: var(--ink-soft); font-size: .95rem; }
.result-foot { font-size: .85rem; color: var(--muted); margin-top: 10px; }
.multiplier { display: flex; align-items: center; gap: 12px; background: var(--accent-soft); border-radius: var(--radius-sm); padding: 14px 18px; margin: 4px 0 18px; }
.multiplier .x { font-family: var(--serif); font-size: 1.6rem; font-weight: 700; color: var(--accent); }
.multiplier .t { color: var(--ink-soft); font-size: .95rem; }
.rows { display: grid; gap: 10px; }
.row { display: grid; grid-template-columns: 92px 130px 1fr 92px 36px; gap: 8px; align-items: center; }
@media (max-width: 620px) {
  .rows { gap: 12px; }
  .row { grid-template-columns: 1fr 1fr 34px; grid-template-areas: "amt unit del" "name name name" "out out out"; gap: 8px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
  .row > input[type=number] { grid-area: amt; }
  .row > select { grid-area: unit; }
  .row > .in-name { grid-area: name; }
  .row > .out { grid-area: out; text-align: left; }
  .row > .del { grid-area: del; justify-self: end; }
}
.row input { padding: 10px 12px; }
.row .out { font-weight: 700; color: var(--accent); text-align: right; font-variant-numeric: tabular-nums; }
.row .del { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 1.2rem; line-height: 1; padding: 6px; border-radius: 8px; }
.row .del:hover { background: var(--accent-soft); color: var(--accent); }
.btn { display: inline-block; border: 0; cursor: pointer; font-family: var(--sans); font-weight: 600; font-size: .95rem; padding: 12px 22px; border-radius: 999px; background: var(--accent); color: #fff; transition: background .15s, transform .06s; box-shadow: 0 6px 16px -8px var(--accent); }
.btn:hover { background: var(--accent-dark); color: #fff; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn.ghost { background: transparent; color: var(--accent); border: 1px solid var(--line-strong); box-shadow: none; }
.btn.ghost:hover { background: var(--accent-soft); }

/* Sections */
.section { padding: 52px 0; }
.section.alt { background: var(--paper); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.section-head { max-width: 640px; }
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin-top: 26px; }
@media (max-width: 760px) { .cards { grid-template-columns: 1fr; } }
.card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm); }
.card h3 { margin-bottom: .3em; }
.card p:last-child { margin-bottom: 0; }
.card .ico { width: 42px; height: 42px; border-radius: 12px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; font-size: 20px; margin-bottom: 14px; }

/* Steps */
.steps { counter-reset: s; display: grid; gap: 18px; margin-top: 26px; }
.step { counter-increment: s; display: grid; grid-template-columns: 46px 1fr; gap: 16px; align-items: start; }
.step::before { content: counter(s); font-family: var(--serif); font-weight: 700; font-size: 1.25rem; color: #fff; width: 42px; height: 42px; border-radius: 13px; background: linear-gradient(135deg, var(--accent), var(--accent-2)); display: grid; place-items: center; box-shadow: var(--shadow-sm); }
.step h3 { margin-bottom: .2em; }
.step p { margin-bottom: 0; }

/* Table */
.tbl { width: 100%; border-collapse: separate; border-spacing: 0; margin: 20px 0; font-variant-numeric: tabular-nums; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.tbl th, .tbl td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); }
.tbl thead th { background: var(--cream-2); font-size: .78rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); }
.tbl tbody tr:nth-child(even) { background: #fcf8f1; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl td:not(:first-child), .tbl th:not(:first-child) { text-align: right; }

/* Article */
.article { max-width: 780px; margin: 0 auto; padding: 40px 0 20px; }
.article h2 { margin-top: 1.7em; }
.article h3 { margin-top: 1.3em; }
.article ul, .article ol { padding-left: 1.3em; color: var(--ink-soft); }
.article li { margin-bottom: .4em; }
.article .lead { font-size: 1.14rem; }
.crumbs { font-size: .84rem; color: var(--muted); margin-bottom: 10px; }
.crumbs a { color: var(--muted); }
.toc { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 22px; margin: 26px 0; box-shadow: var(--shadow-sm); }
.toc h4 { font-family: var(--sans); font-size: .74rem; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); margin-bottom: 10px; }
.toc ol { margin: 0; padding-left: 1.2em; }
.toc li { margin-bottom: 4px; }
.byline { display: flex; align-items: center; gap: 12px; margin: 22px 0 6px; padding: 14px 18px; background: var(--cream-2); border-radius: var(--radius-sm); font-size: .9rem; color: var(--ink-soft); }
.byline .av { width: 38px; height: 38px; border-radius: 50%; background: linear-gradient(135deg, var(--accent), var(--accent-2)); color: #fff; display: grid; place-items: center; font-family: var(--serif); font-weight: 700; flex: none; }
.sourcebox { border-top: 1px solid var(--line); margin-top: 30px; padding-top: 18px; font-size: .88rem; color: var(--muted); }
.sourcebox h4 { font-family: var(--sans); font-size: .74rem; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); }

/* FAQ */
.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { cursor: pointer; font-weight: 600; font-family: var(--serif); font-size: 1.1rem; padding: 16px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--accent); font-size: 1.5rem; line-height: 1; }
.faq details[open] summary::after { content: "\2013"; }
.faq details p { padding-bottom: 12px; }

/* Footer */
.site-footer { background: #2a211a; color: #d9cec1; padding: 46px 0 30px; margin-top: 20px; }
.site-footer a { color: #f2c9a6; }
.site-footer a:hover { color: #fff; }
.site-footer .cols { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 26px; }
@media (max-width: 700px) { .site-footer .cols { grid-template-columns: 1fr 1fr; } }
.site-footer h4 { color: #fff; font-family: var(--sans); font-size: .8rem; text-transform: uppercase; letter-spacing: .09em; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; font-size: .93rem; }
.site-footer .fine { border-top: 1px solid #463a2d; margin-top: 28px; padding-top: 18px; font-size: .82rem; color: #a2937f; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; }

/* Ad slot */
.ad-slot { max-width: 1060px; margin: 26px auto; padding: 0 20px; text-align: center; }
.ad-slot .ad-in { display: grid; place-items: center; }
.ad-slot .ad-in[data-ad="leaderboard"] { min-height: 90px; }
.ad-slot .ad-in[data-ad="square"] { min-height: 250px; }
.ad-slot .ad-in[data-ad="native"] { min-height: 220px; }
@media (max-width: 767px) { .ad-slot .ad-in[data-ad="leaderboard"] { min-height: 50px; } }
.ad-slot .ad-label { font-size: .68rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.note { background: var(--cream-2); border-left: 4px solid var(--accent); padding: 14px 18px; border-radius: 0 10px 10px 0; color: var(--ink-soft); font-size: .96rem; }
.center { text-align: center; }
