:root {
  color-scheme: light;
  --paper: #f7f4eb;
  --panel: #fffdf7;
  --ink: #202d25;
  --muted: #526055;
  --pine: #234c39;
  --pine-dark: #193c2b;
  --edge: #ded9cb;
  --control: #858876;
  --soft: #edf2e8;
  --accent: #a54b30;
  --warm: #fff1df;
  --warning: #733d23;
  --focus: #2b664b;
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  color: var(--ink);
  background: radial-gradient(ellipse at 84% 4%, #efeadb 0%, transparent 47%), var(--paper);
  font: 16px/1.5 var(--sans);
}
a { color: var(--pine); text-underline-offset: .22em; overflow-wrap: anywhere; }
button, input, select, textarea { font: inherit; }
button, summary { cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.frame { width: min(1272px, calc(100% - 72px)); margin-inline: auto; }
.masthead { border-bottom: 1px solid var(--edge); }
.masthead-inner { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.wordmark { color: var(--ink); font: bold 23px/1 var(--serif); display: inline-flex; gap: 11px; align-items: center; text-decoration: none; }
.mark { display: inline-block; position: relative; width: 30px; height: 30px; border-radius: 50%; background: var(--pine); flex: none; }
.mark::before { content: ""; position: absolute; width: 15px; height: 7px; top: 12px; left: 7px; border: 1.5px solid #fffdf7; border-radius: 2px 2px 8px 8px; }
.mark::after { content: ""; position: absolute; height: 8px; width: 1.5px; top: 6px; left: 17px; background: #fffdf7; rotate: 35deg; }
.header-link { display: inline-flex; align-items: center; font-size: .84rem; color: var(--muted); font-weight: 650; text-decoration: none; }
.wordmark, .header-link { min-height: 44px; }
.header-link:hover { text-decoration: underline; }
.header-link span { margin-left: .25em; color: var(--accent); }
.site-nav { display: flex; align-items: center; justify-content: end; flex-wrap: wrap; gap: 0 16px; }
.nav-link { display: inline-flex; align-items: center; min-height: 44px; font-size: .84rem; font-weight: 650; }
.skip { position: fixed; top: 8px; left: 12px; z-index: 3; transform: translateY(-180%); background: var(--panel); padding: 8px 12px; }
.skip:focus { transform: none; }
.intro { padding: clamp(42px, 6vw, 83px) 0 clamp(34px, 4.4vw, 60px); display: flex; align-items: end; gap: clamp(24px, 5vw, 75px); }
h1, h2, h3, p { margin: 0; }
h1 { font: 500 clamp(3.1rem, 6.3vw, 6.15rem)/.91 var(--serif); letter-spacing: -.072em; }
h1 em { color: var(--pine); font-weight: 400; }
.intro p { max-width: 340px; font-size: clamp(1rem, 1.53vw, 1.2rem); line-height: 1.6; color: var(--muted); padding-bottom: 3px; }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 22px; align-items: start; }
.panel { min-width: 0; background: var(--panel); border: 1px solid var(--edge); border-radius: 15px; box-shadow: 0 4px 15px #2e362008; }
.panel-head { display: flex; align-items: center; gap: 12px; justify-content: space-between; padding: 21px 23px 17px; border-bottom: 1px solid var(--edge); }
h2 { font: 500 clamp(1.55rem, 2.6vw, 2.03rem)/1.05 var(--serif); letter-spacing: -.04em; }
.panel-head p { font-size: .84rem; color: var(--muted); margin-top: 6px; }
.panel-body { padding: 19px 23px 12px; }
label { display: block; font-weight: 670; font-size: .89rem; margin-bottom: 5px; }
input:not([type="checkbox"]), select, textarea {
  display: block; min-width: 0; width: 100%; padding: 9px 11px;
  background: #fffefa; border: 1px solid var(--control); border-radius: 7px;
  color: var(--ink); min-height: 44px;
}
input::placeholder, textarea::placeholder { color: #667066; opacity: 1; }
textarea { resize: vertical; min-height: 94px; }
#ingredient-text { min-height: 153px; background-color: #fbf9f1; line-height: 1.65; }
.input-caption { color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 4px 10px; margin-top: 5px; font-size: .79rem; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.serving-fields { margin-top: 17px; }
.units-fields { margin-top: 13px; }
.hint { color: var(--muted); font-size: .8rem; line-height: 1.45; }
#measure-note, #output-note, .serving-hint { margin-top: 6px; }
#target-measures { margin-top: 12px; }
.options { margin-top: 12px; border-top: 1px solid var(--edge); }
.options summary { padding: 11px 0; color: var(--pine-dark); font-weight: 650; font-size: .86rem; min-height: 44px; }
.options summary .hint { margin-left: 6px; font-weight: 400; }
.options-body { padding: 0 0 8px; }
.extra-fields { display: grid; gap: 11px; }
.check { display: flex; gap: 9px; align-items: center; min-height: 44px; margin: 0; }
.check input { width: 18px; height: 18px; accent-color: var(--pine); flex: none; margin: 0; }
#custom-fields { padding: 5px 0 8px; }
#custom-fields .link-button { margin: 3px 0 4px; }
.panel-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; padding: 13px 23px; border-top: 1px solid var(--edge); }
.button { min-width: 44px; min-height: 44px; display: inline-flex; gap: 9px; justify-content: center; align-items: center; border: 1px solid transparent; border-radius: 7px; padding: 7px 13px; font-size: .84rem; line-height: 1.22; font-weight: 700; text-align: center; }
.button:disabled { cursor: default; opacity: .58; }
.primary { color: #fffef7; background: var(--pine); }
.primary:not(:disabled):hover { background: var(--pine-dark); }
.secondary { color: var(--pine-dark); background: #f2f3e9; border-color: #c3cbb9; }
.secondary:not(:disabled):hover { background: #e7ecdf; }
.quiet, .link-button { color: var(--pine-dark); background: transparent; }
.quiet:not(:disabled):hover, .link-button:hover { background: var(--soft); }
.button:not(:disabled):active, .link-button:active { box-shadow: inset 0 0 0 2px currentColor; }
.link-button { border: 0; border-radius: 5px; padding: 4px 7px; min-width: 44px; min-height: 44px; font-size: .77rem; font-weight: 670; text-align: left; text-decoration: underline; text-underline-offset: .25em; }
.result-head { background: #eef1e7; border-radius: 14px 14px 0 0; }
.result-body { padding: 0 23px; }
.empty { text-align: center; padding: clamp(54px, 9vw, 108px) 13px; color: var(--muted); }
.empty h3 { font: 500 1.65rem/1.2 var(--serif); margin-bottom: 8px; color: var(--ink); letter-spacing: -.025em; }
.empty p { margin-inline: auto; max-width: 300px; font-size: .88rem; }
.paper-icon { width: 45px; border: 1px solid #aebaab; background: #f1f3e9; border-radius: 6px; padding: 10px 8px; margin: 0 auto 20px; display: grid; gap: 5px; rotate: -6deg; }
.paper-icon i { height: 2px; width: 100%; background: #718778; border-radius: 3px; }
.paper-icon i:last-child { width: 70%; }
.recipe-summary { font-size: .88rem; margin: 11px 0; overflow-wrap: anywhere; }
.recipe-summary h3 { font: 500 1.4rem/1.2 var(--serif); }
.recipe-summary a { display: inline-block; padding: 8px 0; }
.column-labels, .result-row { display: grid; grid-template-columns: minmax(0, .87fr) minmax(0, 1.13fr); gap: 13px; }
.column-labels { color: var(--muted); font-size: .73rem; font-weight: 750; letter-spacing: .035em; border-bottom: 1px solid var(--edge); padding: 11px 0 8px; }
.results { list-style: none; padding: 0; margin: 0; }
.result-row { border-bottom: 1px solid var(--edge); padding: 12px 0 5px; overflow-wrap: anywhere; }
.original-line { color: var(--muted); font-size: .86rem; margin-top: 2px; white-space: pre-wrap; }
.row-outcome { min-width: 0; }
.outcome-title { color: var(--ink); font-size: .98rem; font-weight: 700; }
.row-status { color: var(--pine-dark); font-size: .75rem; margin-top: 3px; line-height: 1.4; }
.row-warnings { display: grid; gap: 3px; margin: 5px 0 0; color: var(--warning); font-size: .79rem; }
.row-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 0 8px; margin-left: -5px; }
.row-swap-title { color: var(--pine-dark); }
.swap-list { margin: 5px 0; padding-left: 1.18em; font-size: .88rem; }
.swap-list li + li { margin-top: 3px; }
.swap-method { margin: 6px 0; font-size: .83rem; }
.notice { background: var(--warm); color: var(--warning); border: 1px solid #eacbae; border-radius: 8px; padding: 9px 11px; margin-top: 11px; font-size: .82rem; overflow-wrap: anywhere; }
.notice a { color: inherit; }
.notice ul { padding-left: 20px; margin: 4px 0 0; }
.error { color: #8a2e19; font-size: .81rem; margin-top: 5px; }
[aria-invalid="true"] { border-color: #a23a25 !important; }
.action-status { padding: 8px 0 0; color: var(--pine-dark); font-size: .82rem; }
.kitchen-tip { padding: 15px 0; }
.original-steps { white-space: pre-wrap; overflow-wrap: anywhere; margin-top: 8px; font-size: .88rem; }
.footer { padding: 17px 0 32px; color: var(--muted); font-size: .79rem; }
.footer .options { margin-top: 9px; }
.source-list { margin: 7px 0; padding-left: 20px; font-size: .84rem; }
.source-list li { margin: 6px 0; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
dialog { width: min(550px, calc(100% - 24px)); max-height: 90dvh; background: var(--panel); color: var(--ink); border: 1px solid var(--edge); border-radius: 13px; padding: 0; box-shadow: 0 10px 50px #16251d50; overflow: auto; }
dialog::backdrop { background: #172a226b; }
.dialog-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 14px 18px; background: var(--soft); }
.dialog-body { padding: 14px 18px 17px; display: grid; gap: 9px; font-size: .9rem; overflow-wrap: anywhere; }
.dialog-body label { margin-bottom: 3px; }
.dialog-actions { padding: 9px 18px 14px; display: flex; gap: 8px; justify-content: end; flex-wrap: wrap; }
.dialog-body .dialog-actions { padding: 6px 0 0; }
.dialog-original { color: var(--muted); white-space: pre-wrap; }
.dialog-preview { padding: 10px; border: 1px solid #cbd5c5; background: var(--soft); border-radius: 7px; }
.manual-copy { min-height: 160px; }
.guide-section { margin-top: 38px; }
.guide-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px; margin-block: 14px 12px; }
.guide-grid a { display: grid; align-content: start; gap: 4px; padding: 14px; background: var(--panel); border: 1px solid var(--edge); border-radius: 10px; }
.guide-grid a:hover { background: var(--soft); }
.guide-grid span { color: var(--muted); text-decoration: none; }
.guide-page { max-width: 740px; padding: clamp(30px, 6vw, 72px) 0; }
.guide-page h1 { font-size: clamp(2.55rem, 7vw, 4.6rem); line-height: 1.02; letter-spacing: -.058em; overflow-wrap: anywhere; }
.guide-page h2 { margin-top: 1.25em; }
.guide-page p, .guide-page ol, .guide-page ul { margin-block: .8em; }
.guide-page ol, .guide-page ul { padding-inline-start: 1.5em; }
.guide-page li + li { margin-top: .35em; }
.guide-page .answer { font-size: 1.125rem; color: var(--muted); }
.guide-page .guide-tool { text-decoration: none; margin-block: .5em; }
.guide-page table { width: 100%; border-collapse: collapse; margin-block: 1em; }
.guide-page th, .guide-page td { text-align: left; padding: 7px 5px; border-bottom: 1px solid var(--edge); overflow-wrap: anywhere; }
.guide-page caption { text-align: left; font-weight: 650; }
.guide-page pre { white-space: pre-wrap; overflow-wrap: anywhere; padding: 12px; background: var(--panel); border: 1px solid var(--edge); border-radius: 8px; }
@media (max-width: 1040px) {
  .frame { width: calc(100% - 52px); }
  .panel-head, .panel-body, .panel-foot { padding-inline: 16px; }
  .result-body { padding-inline: 16px; }
}
@media (max-width: 850px) {
  .workspace { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .intro { align-items: start; flex-direction: column; gap: 17px; }
  .title-break { display: none; }
  .intro p { max-width: 490px; }
}
@media (max-width: 520px) {
  .frame { width: calc(100% - 24px); }
  .masthead-inner { min-height: 56px; }
  .wordmark { font-size: 19px; gap: 7px; }
  .mark { scale: .83; }
  .header-link { font-size: .73rem; text-align: right; }
  .site-nav { gap: 0 9px; }
  .nav-link { font-size: .78rem; }
  .intro { padding: 31px 2px 24px; }
  h1 { font-size: clamp(2.78rem, 11.5vw, 4.3rem); }
  .panel-head, .panel-body, .panel-foot { padding-inline: 12px; }
  .panel-head { padding-top: 14px; align-items: start; }
  .result-body { padding-inline: 12px; }
  .column-labels { display: none; }
  .result-row { grid-template-columns: minmax(0, 1fr); gap: 5px; }
  .original-line::before { content: "Original · "; color: var(--muted); font-size: .73rem; font-weight: 700; }
  .form-grid { gap: 8px; }
}
