/* Campo claro: contraste, leitura e controles para uso em campo. */
@font-face {
  font-family: 'Source Sans 3'; font-style: normal; font-weight: 400;
  font-display: swap; src: url('./fonts/SourceSans3-Regular.woff') format('woff');
}
@font-face {
  font-family: 'Source Sans 3'; font-style: normal; font-weight: 600;
  font-display: swap; src: url('./fonts/SourceSans3-Semibold.woff') format('woff');
}
@font-face {
  font-family: 'Source Sans 3'; font-style: normal; font-weight: 700;
  font-display: swap; src: url('./fonts/SourceSans3-Bold.woff') format('woff');
}
:root {
  --paper: #F5F5EE; --ink: #203024; --muted: #4B5D43;
  --green: #355B3D; --panel: #263F31; --lime: #DBEBB1;
  --line: #ADBBA1; --error: #993D28; --white: #FFFFFF;
  font-family: 'Source Sans 3', 'Segoe UI', Arial, sans-serif;
  font-size: 18px; line-height: 1.55; color: var(--ink);
  background: var(--paper); color-scheme: light;
}
body { font-size: 18px; line-height: 1.55; }
button, input, select, textarea { font-family: inherit; }
button, a, summary { touch-action: manipulation; }
button:disabled { opacity: 1; background: #EFF1E9; color: var(--muted); box-shadow: none; cursor: default; }
button:focus-visible, a:focus-visible, summary:focus-visible, select:focus-visible,
input:focus-visible, textarea:focus-visible, .table-scroll:focus-visible {
  outline: 3px solid var(--green); outline-offset: 3px;
}
input::placeholder, textarea::placeholder { color: var(--muted); opacity: 1; }
.shell { max-width: 1320px; padding: 0 40px; }
.topbar { height: auto; min-height: 104px; gap: 24px; border-color: var(--line); padding: 18px 0; }
.brand { font-size: 38px; font-weight: 700; color: var(--ink); }
.brand span, .brand-dot { color: var(--green); }
.topbar nav { background: #EAEFDF; border: 1px solid var(--line); border-radius: 14px; padding: 4px; font-size: 16px; }
.topbar nav a { min-height: 48px; display: flex; align-items: center; justify-content: center; padding: 10px 16px; color: var(--muted); border-radius: 10px; font-weight: 600; }
.topbar nav a[aria-current] { background: var(--white); color: var(--ink); box-shadow: 0 2px 0 #ADBBA1; }
.private { padding: 8px 12px; font-size: 14px; font-weight: 600; color: var(--muted); border-color: var(--line); background: var(--white); }
.private svg { width: 16px; height: 16px; }
.intro { padding: 42px 0 34px; gap: 28px; }
.eyebrow { width: fit-content; max-width: 100%; font-size: 13px; font-weight: 700; line-height: 1.5; letter-spacing: 1px; color: var(--muted); margin-bottom: 16px; }
.eyebrow i, .eyebrow span { background: var(--green); }
h1 { font-size: 50px; line-height: 1.12; letter-spacing: -1.4px; font-weight: 600; margin-bottom: 18px; }
h1 em { color: var(--green); }
.intro p:not(.eyebrow), .subtitle { color: var(--muted); font-size: 18px; line-height: 1.65; }
.intro-aside, .intro-note { font-size: 16px; line-height: 1.7; color: var(--muted); }
.intro-aside strong, .intro-note strong { color: var(--green); font-weight: 600; }
.intro-aside svg { opacity: 1; }
.steps { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); overflow: visible; border: 1px solid var(--line); border-radius: 16px; gap: 4px; padding: 5px; background: #EAEFDF; margin-bottom: 30px; }
.steps:has(button:nth-child(6):last-child) { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.steps button { min-width: 0; min-height: 52px; padding: 10px 6px; border: 0; border-radius: 11px; font-size: 15px; font-weight: 600; gap: 7px; color: var(--muted); white-space: normal; line-height: 1.25; }
.steps button b { font-size: 13px; color: inherit; font-weight: 700; }
.steps button.active, .steps button.active b { background: var(--green); color: var(--white); box-shadow: none; }
.steps button.done { color: var(--green); background: #F5F8EE; }
.steps button:disabled { opacity: 1; background: transparent; color: var(--muted); }
.workspace { grid-template-columns: minmax(0, 1.8fr) minmax(330px, 1fr); gap: 28px; }
.workspace.result-layout { grid-template-columns: minmax(0, 1fr); }
.stage, .input-card { padding: 32px; background: var(--white); border: 1px solid var(--green); border-radius: 24px; box-shadow: 0 5px 0 #263D30; }
.stage.result-stage { padding: 32px; }
.stage-kicker, .section-number { width: fit-content; max-width: 100%; background: var(--lime); color: var(--ink); padding: 5px 9px; border-radius: 5px; font-size: 13px; line-height: 1.5; font-weight: 700; letter-spacing: .7px; margin: 0 0 14px; }
.stage h2 { color: var(--ink); font-size: 30px; font-weight: 600; line-height: 1.2; letter-spacing: -.6px; margin-bottom: 12px; }
.stage-description { color: var(--muted); font-size: 18px; line-height: 1.6; margin-bottom: 26px; }
.choice-grid { gap: 18px; }
.choice-card { min-height: 285px; padding: 28px 22px 22px; border: 1px solid var(--green); border-radius: 20px; box-shadow: 0 4px 0 #263D30; background: #FFFFFF; color: var(--green); }
.choice-card:hover { border-color: var(--green); background: #F1F6E6; }
.choice-card.selected { background: var(--lime); border: 2px solid var(--green); box-shadow: 0 4px 0 #263D30; padding: 27px 21px 21px; }
.choice-check { width: 26px; height: 26px; right: 15px; top: 15px; border: 1px solid var(--green); font-size: 16px; }
.choice-card.selected .choice-check { background: var(--green); border-color: var(--green); color: #FFFFFF; }
.choice-card strong { font-size: 23px; font-weight: 700; color: var(--ink); line-height: 1.2; letter-spacing: -.3px; }
.choice-card small { font-size: 16px; line-height: 1.55; color: var(--muted); margin-top: 12px; }
.biome-drawing { height: 105px; margin: 13px 0 16px; }
.system-card .large-label { font-size: 48px; color: var(--green); margin: 10px 0 14px; }
.primary-button, .secondary-button, .calculate-button, .copy-button, .side-button {
  min-height: 52px; padding: 12px 18px; border-radius: 13px; font-size: 18px; line-height: 1.3; font-weight: 600;
}
.primary-button, .calculate-button { background: var(--green); color: #FFFFFF; border: 1px solid var(--green); box-shadow: 0 3px 0 #203024; }
.primary-button:hover, .calculate-button:hover { background: var(--panel); }
.secondary-button { background: #FFFFFF; border: 1px solid var(--green); color: var(--green); }
.secondary-button:hover { background: #EFF4E5; }
.stage-actions { border-color: var(--line); padding-top: 24px; margin-top: 28px; }
.text-button, .back-button { min-height: 48px; font-size: 16px; line-height: 1.4; color: var(--green); padding: 10px 4px; font-weight: 600; }
.text-button { text-underline-offset: 4px; }
.help, .notice, .map-note { font-size: 16px; line-height: 1.6; color: var(--muted); }
.notice { min-height: 25px; margin-top: 17px; }
.field-error { color: var(--error); font-size: 16px; line-height: 1.6; }
.field-grid, .field-grid.three { gap: 20px; }
label.field, .settings .field, .renque-fields .field, .forage-fields .field { font-size: 16px; line-height: 1.45; font-weight: 600; color: var(--ink); }
.input-unit { border: 1px solid #819777; border-radius: 12px; background: #FFFFFF; margin-top: 9px; min-height: 54px; }
.input-unit:focus-within, .input-wrap:focus-within { border-color: var(--green); box-shadow: 0 0 0 3px #DBEBB1; }
.input-unit input { font-size: 25px; line-height: 1.2; padding: 12px 14px; color: var(--ink); }
.input-unit span { font-size: 16px; color: var(--muted); padding-right: 14px; }
.field input[type=text], .name-input { background: #FFFFFF; border: 1px solid #819777; border-radius: 12px; padding: 13px 14px; min-height: 52px; font-size: 18px; }
.field small { font-size: 14px; line-height: 1.5; color: var(--muted); margin-top: 7px; font-weight: 400; }
.select-input { background: #FFFFFF; border: 1px solid #819777; color: var(--ink); border-radius: 12px; padding: 12px; min-height: 52px; font-size: 16px; }
.dimensions { border: 1px solid var(--line); padding: 14px 16px; color: var(--green); background: #EFF4E5; font-size: 17px; font-weight: 600; line-height: 1.6; border-radius: 12px; margin: 22px 0; }
.settings { border-color: var(--line); border-radius: 14px; padding: 0 18px; margin-top: 22px; }
.settings summary, .method summary { min-height: 56px; font-size: 17px; font-weight: 600; color: var(--ink); padding: 16px 0; gap: 12px; }
.settings input, .renque-fields input { font-size: 23px; }
.settings .help, .renque-fields .help { font-size: 15px; color: var(--muted); }
.settings .field-grid { gap: 16px; }
.catalog-head { align-items: center; gap: 16px; margin-bottom: 18px; }
.catalog-head h3, .selected-head h3, .renque-fields h3 { font-size: 20px; line-height: 1.3; font-weight: 600; }
.catalog-search { max-width: 245px; width: 46%; font-size: 17px; min-height: 50px; padding: 12px 14px; background: #FFFFFF; color: var(--ink); border: 1px solid #819777; border-radius: 12px; }
.catalog { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.species-option { padding: 16px 13px; gap: 10px; min-height: 90px; background: #FFFFFF; border: 1px solid var(--line); border-radius: 14px; color: var(--ink); }
.species-option .option-icon { font-size: 26px; color: var(--green); }
.species-option strong { font-size: 18px; line-height: 1.25; font-weight: 600; color: var(--ink); overflow-wrap: anywhere; }
.species-option small { font-size: 14px; line-height: 1.45; color: var(--muted); margin-top: 6px; }
.species-option .option-mark { color: var(--green); font-size: 23px; flex-shrink: 0; }
.species-option:hover { background: #F1F6E6; border-color: var(--green); }
.species-option.selected { background: var(--lime); border: 2px solid var(--green); padding: 15px 12px; }
.tree-tabs { display: flex; gap: 10px; margin-bottom: 18px; }
.tree-tabs button { padding: 10px 16px; border: 1px solid var(--green); border-radius: 12px; text-decoration: none; background: #FFFFFF; }
.tree-tabs button[aria-pressed=true] { background: var(--green); color: #FFFFFF; }
.selected-head { margin: 30px 0 16px; }
.selected-head span { font-size: 15px; color: var(--muted); white-space: nowrap; }
.selected-list { gap: 18px; }
.selected-card { background: #FFFFFF; border: 1px solid var(--green); border-radius: 18px; box-shadow: 0 3px 0 #263D30; overflow: hidden; }
.selected-card-header { padding: 14px 18px 10px; gap: 10px; flex-wrap: wrap; }
.selected-card-header h4 { font-size: 23px; line-height: 1.25; font-weight: 600; overflow-wrap: anywhere; flex: 1; }
.dot { width: 10px; height: 10px; }
.selected-card-header .principal-label { min-height: 44px; color: var(--green); font-size: 15px; font-weight: 600; gap: 7px; }
.principal-label input { width: 22px; height: 22px; accent-color: var(--green); }
.remove-button, .icon-button { width: 44px; height: 44px; min-width: 44px; font-size: 28px; line-height: 1; border-radius: 10px; color: var(--green); }
.remove-button:hover, .icon-button:hover { background: #EFF4E5; }
.selected-inputs { padding: 0 18px 18px; gap: 14px; }
.selected-inputs .field { font-size: 14px; line-height: 1.5; }
.selected-inputs input, .forage-fields input { font-size: 23px; padding: 11px 12px; }
.selected-inputs .input-unit span { font-size: 16px; padding-right: 12px; }
.selected-meta { padding: 0 18px 18px; gap: 16px; }
.selected-meta label { display: block; font-size: 14px; color: var(--muted); font-weight: 600; }
.selected-meta input, .selected-meta select { display: block; width: 100%; min-height: 48px; margin-top: 6px; padding: 10px 12px; background: #FFFFFF; border: 1px solid #819777; border-radius: 10px; font-size: 16px; color: var(--ink); }
.selected-meta .help { font-size: 14px; align-self: center; }
.selected-card-foot { gap: 12px; flex-wrap: wrap; border-color: var(--line); padding: 13px 18px; color: var(--muted); background: #F2F6E9; font-size: 14px; line-height: 1.6; }
.selected-card-foot strong { font-size: 16px; font-weight: 600; color: var(--green); white-space: normal; }
.selected-card-foot a { color: var(--green); font-weight: 600; }
.empty-selected { font-size: 16px; line-height: 1.6; color: var(--muted); border-color: var(--line); border-radius: 14px; padding: 24px 18px; }
.info-callout, .result-callout { font-size: 16px; line-height: 1.65; color: var(--muted); border-color: var(--line); border-radius: 12px; padding: 16px 18px; background: #EFF4E5; margin-top: 22px; }
.info-callout strong, .result-callout strong { color: var(--green); font-weight: 700; }
.sidebar { background: var(--panel); color: #FFFFFF; padding: 30px 26px; border: 1px solid var(--panel); border-radius: 24px; box-shadow: 0 5px 0 #182A20; }
.sidebar .eyebrow { font-size: 13px; color: var(--lime); letter-spacing: .8px; }
.sidebar h2 { font-size: 31px; line-height: 1.2; color: #FFFFFF; margin-bottom: 22px; }
.sidebar .context-line { font-size: 17px; line-height: 1.6; color: #E4EBD7; }
.side-total strong { font-size: 64px; font-weight: 600; line-height: 1.1; }
.side-total span { font-size: 16px; color: #E4EBD7; margin-top: 10px; }
.side-metrics { border-color: #70866A; padding: 22px 0; gap: 16px; }
.side-metrics small { font-size: 15px; line-height: 1.4; color: #E4EBD7; }
.side-metrics strong { font-size: 30px; font-weight: 600; color: #FFFFFF; }
.side-metrics div+div { border-color: #70866A; }
.side-details { font-size: 16px; }
.side-details dt, .side-details dd, .sidebar .help { color: #E4EBD7; }
.side-details dd { font-weight: 600; text-align: right; }
.sidebar .help { font-size: 16px; line-height: 1.6; }
.side-warning { font-size: 15px; line-height: 1.55; color: #F7E3B8; background: #354A35; border-color: #829470; padding: 14px; border-radius: 12px; }
.side-button { border-color: #D0E0B2; color: #FFFFFF; background: transparent; }
.side-button:hover { background: #355B3D; }
.side-status, .side-status.incomplete { padding: 8px 11px; background: #35513B; color: #F1F6E7; border-color: #829470; font-size: 14px; line-height: 1.4; }
.side-status:before { font-size: 9px; }
.result-badge { font-size: 14px; font-weight: 600; background: var(--lime); border-color: var(--line); color: var(--green); padding: 9px 13px; white-space: normal; }
.result-badge.incomplete { color: #745027; background: #F6EEDD; border-color: #BD9B68; }
.result-kpis { border-color: var(--line); background: #F2F6E9; border-radius: 16px; padding: 22px 0; margin: 26px 0; }
.result-kpis>div { padding: 0 22px; }
.result-kpis>div+div { border-color: var(--line); }
.result-kpis small { font-size: 16px; line-height: 1.4; color: var(--muted); }
.result-kpis strong { font-size: 34px; font-weight: 600; line-height: 1.2; }
.result-kpis span { font-size: 15px; color: var(--muted); }
.plot-wrap { background: #F2F6E9; border-color: var(--line); border-radius: 16px; padding: 12px; }
.plot-wrap svg { max-height: 440px; }
.legend { gap: 12px 20px; margin: 18px 0; }
.legend span { font-size: 16px; color: var(--muted); gap: 7px; }
.legend i { width: 10px; height: 10px; }
.map-note { margin-bottom: 26px; }
.result-subtitle { font-size: 23px; font-weight: 600; margin: 30px 0 18px; }
table { font-size: 17px; }
th { font-size: 15px; font-weight: 600; color: var(--muted); line-height: 1.4; padding: 0 15px 15px; }
td { color: var(--ink); padding: 16px 15px; border-color: var(--line); }
td strong { color: var(--ink); font-size: 18px; font-weight: 600; }
td small { color: var(--muted); font-size: 14px; }
.result-actions { gap: 14px; margin-top: 28px; }
.result-warnings { font-size: 16px; line-height: 1.6; color: #745027; background: #FAF3E6; border-color: #BD9B68; border-radius: 12px; padding: 16px 18px; }
.renque-fields { padding: 20px; background: #EFF4E5; border-color: var(--line); border-radius: 16px; }
.forage-fields { padding: 0 18px 18px; gap: 14px; grid-template-columns: 1fr 1fr; }
.forage-fields .field:last-child { grid-column: 1 / -1; }
.forage-fields .select-input { font-size: 16px; height: auto; padding: 12px; margin-top: 9px; }
.method { border-color: var(--line); margin-top: 30px; }
.method summary span { font-size: 25px; color: var(--green); }
.method-grid { gap: 18px 32px; padding-bottom: 16px; }
.method-grid h3 { font-size: 18px; font-weight: 600; color: var(--ink); }
.method-grid p { font-size: 16px; line-height: 1.65; color: var(--muted); }
.source-links { font-size: 15px; line-height: 1.6; color: var(--green); gap: 12px 20px; }
footer, .shell footer { font-size: 14px; line-height: 1.5; color: var(--muted); gap: 16px; padding: 28px 0 34px; }
.footer-brand { color: var(--green); font-size: 25px; }
dialog { padding: 28px; border: 1px solid var(--green); border-radius: 24px; box-shadow: 0 5px 0 #263D30; }
dialog h2 { font-size: 28px; line-height: 1.2; font-weight: 600; }
.dialog-head .eyebrow { font-size: 13px; }
#export-status, #share-help, dialog p { font-size: 16px; line-height: 1.6; color: var(--muted); }
.image-preview { border-color: var(--line); border-radius: 12px; }
dialog textarea { border-color: #819777; font-size: 17px; line-height: 1.55; }
.export-actions { gap: 14px; margin-top: 24px; }
#custom-dialog label { font-size: 16px; color: var(--ink); font-weight: 600; }
#custom-dialog input { min-height: 52px; font-size: 20px; border-color: #819777; border-radius: 12px; padding: 12px; }
.empty-result { font-size: 18px; color: var(--muted); }
input[aria-invalid=true] { box-shadow: inset 0 -3px var(--error); }

/* A calculadora simples acompanha a mesma identidade e os mesmos tamanhos. */
.top-right { flex-wrap: wrap; gap: 18px; }
.tool-label { font-size: 15px; letter-spacing: .2px; font-weight: 600; }
.calculator { grid-template-columns: 1.05fr 1fr; gap: 28px; align-items: stretch; }
.card-heading .section-number { color: var(--ink); }
.card-heading h2 { font-size: 28px; line-height: 1.2; font-weight: 600; }
.field label { font-size: 17px; font-weight: 600; }
.required { color: var(--green); font-size: 16px; }
.input-wrap { border-color: #819777; border-radius: 12px; background: #FFFFFF; min-height: 54px; }
.input-wrap input { font-size: 25px; padding: 12px 14px; }
.unit { font-size: 16px; color: var(--muted); }
.hint, .form-footnote, .examples-note { font-size: 15px; line-height: 1.6; color: var(--muted); }
.error { font-size: 16px; color: var(--error); }
.margin-heading { font-size: 17px; margin-top: 28px; }
.optional { font-size: 13px; color: var(--muted); }
.mode-switch { background: #EAEFDF; padding: 5px; border: 1px solid var(--line); border-radius: 14px; }
.mode-switch label span { min-height: 48px; padding: 10px 8px; font-size: 16px; color: var(--muted); white-space: normal; border-radius: 10px; }
.mode-switch input:checked+span { color: var(--ink); border-color: var(--green); background: var(--lime); box-shadow: none; }
.mode-switch input:focus-visible+span { outline-color: var(--green); }
.percent-field label { font-size: 16px; color: var(--ink); }
.percent-field .input-wrap input { font-size: 24px; }
.margin-explanation { font-size: 16px; line-height: 1.55; color: var(--muted); }
.results-card { background: var(--panel); border: 1px solid var(--panel); border-radius: 24px; padding: 32px; box-shadow: 0 5px 0 #182A20; color: #FFFFFF; }
.result-top { flex-wrap: wrap; gap: 12px; }
.result-top .section-number { color: var(--ink); font-size: 13px; margin: 0; }
.live-tag { font-size: 15px; color: #E4EBD7; }
.results-card h2 { font-size: 20px; font-weight: 400; color: #E4EBD7; }
.main-result strong { font-size: 72px; font-weight: 600; }
.main-result span { font-size: 18px; color: #E4EBD7; }
.adjust-note { font-size: 17px; color: #E4EBD7; }
.metrics { border-color: #70866A; }
.metrics>div+div { border-color: #70866A; padding-left: 20px; }
.metrics span { font-size: 16px; color: #E4EBD7; }
.metrics strong { font-size: 34px; font-weight: 600; }
.metrics small { font-size: 15px; color: #E4EBD7; }
.plot-head>span { font-size: 13px; color: #E4EBD7; letter-spacing: .6px; }
.plot-head small { font-size: 16px; color: var(--lime); }
.plot { opacity: 1; }
.copy-button { border-color: #D0E0B2; color: #FFFFFF; }
.copy-status { font-size: 15px; line-height: 1.5; color: #E4EBD7; }
.examples-heading h2 { font-size: 23px; font-weight: 600; }
.examples-heading p { font-size: 16px; color: var(--muted); }
.preset-grid { gap: 14px; }
.preset { padding: 18px 14px; border-color: var(--green); border-radius: 16px; box-shadow: 0 3px 0 #263D30; background: #FFFFFF; }
.preset.active { border-color: var(--green); background: var(--lime); }
.preset strong { font-size: 18px; color: var(--ink); font-weight: 600; }
.preset small { font-size: 16px; color: var(--muted); }
.crop-icon, .preset-arrow { color: var(--green); }
.crop-icon { font-size: 30px; }
.method-content, .method-content p { font-size: 16px; line-height: 1.65; color: var(--muted); }
.method-content h3 { font-size: 18px; color: var(--ink); }

@media (max-width: 1100px) {
  .shell { padding: 0 28px; }
  .topbar { gap: 18px; flex-wrap: wrap; }
  .topbar nav { font-size: 15px; }
  .intro-aside, .intro-note { display: none; }
  .stage, .stage.result-stage, .input-card, .results-card { padding: 26px; }
  .workspace { grid-template-columns: minmax(0, 1.6fr) minmax(300px, 1fr); gap: 24px; }
  .sidebar { padding: 28px 22px; }
  .selected-inputs { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .selected-inputs .field:last-child { grid-column: 1 / -1; }
  .field-grid.three { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .field-grid.three>.field:last-child { grid-column: 1 / -1; }
  .choice-grid { grid-template-columns: 1fr; }
  .choice-card { min-height: 230px; }
  .biome-drawing { height: 95px; }
  .steps { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .steps:has(button:nth-child(6):last-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .steps button { font-size: 16px; }
  .preset-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .workspace, .calculator { display: grid; grid-template-columns: minmax(0, 1fr); gap: 26px; }
  .sidebar { position: static; width: 100%; }
  .choice-grid { grid-template-columns: 1fr 1fr; }
  .choice-card { min-height: 275px; }
  .sidebar h2 br { display: none; }
  .result-head { flex-wrap: wrap; }
}
@media (max-width: 760px) {
  .shell { padding: 0 20px; max-width: 680px; }
  .topbar { padding: 20px 0 16px; gap: 14px; min-height: 88px; }
  .brand { font-size: 34px; }
  .brand svg, .brand-mark { width: 34px; height: 34px; }
  .private { font-size: 13px; margin-left: auto; }
  .topbar nav { order: 3; margin: 0; width: 100%; display: grid; grid-template-columns: 1.2fr 1fr; font-size: 15px; text-align: center; }
  .topbar nav a { padding: 10px 8px; }
  .intro { padding: 30px 0 26px; }
  h1 { font-size: 40px; line-height: 1.15; }
  .eyebrow { font-size: 12px; letter-spacing: .7px; }
  .intro p:not(.eyebrow), .subtitle { font-size: 17px; }
  .intro p:not(.eyebrow) br { display: none; }
  .steps { margin-bottom: 26px; border-radius: 14px; gap: 4px; }
  .steps button, .steps button.active { min-width: 0; min-height: 62px; padding: 9px 3px; flex-direction: column; gap: 4px; font-size: 14px; }
  .steps button b { font-size: 13px; }
  .stage, .stage.result-stage, .input-card, .results-card { padding: 26px 20px; border-radius: 20px; }
  .stage h2 { font-size: 28px; }
  .stage-description { font-size: 17px; line-height: 1.6; margin-bottom: 24px; }
  .stage-kicker { font-size: 12px; }
  .choice-card { padding: 26px 18px 20px; min-height: 285px; border-radius: 18px; }
  .choice-card.selected { padding: 25px 17px 19px; }
  .choice-card strong { font-size: 22px; }
  .choice-card small { font-size: 16px; line-height: 1.55; }
  .choice-check { right: 12px; top: 12px; }
  .system-card .large-label { font-size: 43px; }
  .biome-drawing { height: 85px; margin: 16px 0; }
  .stage-actions { gap: 12px; flex-wrap: wrap; padding-top: 22px; }
  .stage-actions .primary-button { font-size: 18px; padding: 12px 18px; }
  .catalog-head { flex-wrap: wrap; gap: 12px; }
  .catalog-head h3, .selected-head h3 { font-size: 20px; }
  .catalog-search { max-width: none; width: 100%; font-size: 17px; }
  .catalog { gap: 12px; }
  .species-option { padding: 15px 12px; gap: 9px; }
  .species-option.selected { padding: 14px 11px; }
  .species-option strong { font-size: 18px; }
  .species-option small { font-size: 14px; }
  .selected-card-header { padding: 12px 16px 10px; }
  .selected-card-header h4 { font-size: 22px; }
  .selected-inputs, .selected-meta, .forage-fields { padding-left: 16px; padding-right: 16px; gap: 14px; }
  .selected-inputs .field { font-size: 14px; }
  .selected-inputs input, .forage-fields input { font-size: 23px; padding: 11px 12px; }
  .selected-meta input, .selected-meta select { font-size: 16px; }
  .selected-meta label { font-size: 14px; }
  .selected-card-foot { padding: 14px 16px; font-size: 14px; }
  .selected-card-foot strong { font-size: 16px; }
  .sidebar { padding: 28px 22px; }
  .sidebar h2 { font-size: 30px; }
  .sidebar .context-line { font-size: 17px; }
  .sidebar .eyebrow { font-size: 13px; }
  .side-total strong { font-size: 60px; }
  .side-metrics strong { font-size: 30px; }
  .side-details { font-size: 16px; }
  .side-status { font-size: 14px; }
  .sidebar .help { font-size: 16px; }
  .side-warning { font-size: 15px; }
  .side-button { font-size: 18px; }
  .info-callout, .result-callout, .result-warnings { font-size: 16px; padding: 16px; }
  .result-head { display: block; }
  .result-badge { display: inline-block; font-size: 14px; margin-top: 5px; }
  .result-kpis { grid-template-columns: 1fr 1fr; padding: 0; }
  .result-kpis>div { padding: 18px 15px; }
  .result-kpis>div+div { border-left: 0; }
  .result-kpis>div:nth-child(2n) { border-left: 1px solid var(--line); }
  .result-kpis>div:nth-child(n+3) { border-top: 1px solid var(--line); }
  .result-kpis small { font-size: 15px; }
  .result-kpis strong { font-size: 29px; }
  .result-kpis span { font-size: 14px; }
  .plot-wrap { padding: 4px; }
  .legend span { font-size: 15px; }
  .map-note { font-size: 15px; }
  .result-subtitle { font-size: 22px; }
  .result-actions { gap: 12px; }
  .result-actions .primary-button { width: 100%; margin: 0; }
  .result-actions .secondary-button { flex: 1 1 100%; font-size: 18px; padding: 12px 16px; }
  .renque-fields { padding: 18px 16px; }
  .renque-fields .field-grid { grid-template-columns: 1fr 1fr; }
  .renque-fields .field { font-size: 16px; }
  .forage-fields .field { font-size: 15px; }
  .forage-fields .select-input { font-size: 16px; padding: 12px; }
  .method summary { font-size: 17px; }
  .method-grid { grid-template-columns: 1fr; gap: 16px; }
  .source-links { font-size: 15px; }
  footer, .shell footer { flex-wrap: wrap; font-size: 14px; gap: 10px 16px; }
  footer>span:last-child { margin: 0; width: 100%; }
  .export-actions { flex-direction: column; }
  .export-actions button { font-size: 18px; min-height: 52px; width: 100%; }
  dialog { padding: 24px 20px; }
  dialog h2 { font-size: 26px; }
  .dialog-head .eyebrow { font-size: 12px; }
  #custom-dialog .field-grid { grid-template-columns: 1fr 1fr; }
  .tool-label { display: block; font-size: 15px; }
  .top-right { margin-left: auto; }
  .card-heading h2 { font-size: 26px; }
  .main-result strong { font-size: 65px; }
  .metrics strong { font-size: 31px; }
  .preset-grid { grid-template-columns: 1fr 1fr; gap: 14px; }
  .preset { padding: 16px 12px; }
  .preset strong { font-size: 18px; }
  .preset:last-child { grid-column: 1 / -1; }
  .examples-heading { display: block; }
  .examples-heading p { margin-top: 8px; }
  .margin-row { grid-template-columns: 120px minmax(0, 1fr); gap: 16px; }
}
@media (max-width: 520px) {
  .choice-grid { grid-template-columns: 1fr; gap: 20px; }
  .choice-card, .system-card { min-height: 0; padding: 24px 20px; }
  .choice-card.selected { padding: 23px 19px; }
  .biome-drawing { height: 90px; margin: 8px 0 12px; }
  .choice-card strong { font-size: 23px; }
  .choice-card small { font-size: 16px; margin-top: 9px; }
  .system-card .large-label { margin: 0 0 10px; }
  .field-grid, .field-grid.three, .settings .field-grid, .renque-fields .field-grid { grid-template-columns: minmax(0, 1fr); }
  .field-grid.three>.field:last-child { grid-column: auto; }
  .catalog { grid-template-columns: minmax(0, 1fr); }
  .species-option { min-height: 82px; }
  .selected-meta { grid-template-columns: minmax(0, 1fr); }
  .selected-head { align-items: flex-start; }
  .selected-head h3 { max-width: 75%; }
  .selected-card-header h4 { flex-basis: 50%; }
  .stage-actions .secondary-button { width: 100%; }
  .result-kpis strong { font-size: 27px; }
  .top-right { width: 100%; justify-content: space-between; gap: 10px; }
  .margin-row { grid-template-columns: 1fr; gap: 6px; }
  .margin-explanation { max-width: none; margin-top: 6px; }
  .mode-switch { flex-direction: column; }
  .preset-arrow { display: none; }
  .preset { gap: 10px; }
}
@media (max-width: 380px) {
  .shell { padding: 0 14px; }
  .stage, .stage.result-stage, .input-card, .results-card { padding: 24px 16px; }
  h1 { font-size: 36px; }
  .private { font-size: 12px; padding: 7px 9px; }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .steps button { font-size: 14px; }
  .selected-inputs, .forage-fields { grid-template-columns: minmax(0, 1fr); }
  .selected-inputs .field:last-child, .forage-fields .field:last-child { grid-column: auto; }
  .selected-card-header .principal-label { font-size: 14px; }
  .side-metrics { grid-template-columns: minmax(0, 1fr); }
  .side-metrics div+div { border-left: 0; padding-left: 0; padding-top: 14px; border-top: 1px solid #70866A; }
  .result-kpis { grid-template-columns: minmax(0, 1fr); }
  .result-kpis>div:nth-child(2n) { border-left: 0; }
  .result-kpis>div+div { border-top: 1px solid var(--line); }
  .preset-grid { grid-template-columns: minmax(0, 1fr); }
  .metrics { grid-template-columns: minmax(0, 1fr); }
  .metrics>div+div { border-left: 0; padding: 16px 0 0; border-top: 1px solid #70866A; }
  #custom-dialog .field-grid { grid-template-columns: minmax(0, 1fr); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  .stage, .input-card, .results-card, .sidebar { box-shadow: none; }
  .topbar nav, .private, .steps, .sidebar, .stage-actions, .result-actions, .method,
  footer, .notice, .intro-aside, .intro-note, .input-card, .examples, .copy-button, .copy-status { display: none !important; }
  .shell { padding: 0; max-width: none; }
  .workspace, .calculator { display: block; }
  .stage { border: 0; }
  .results-card { background: #FFFFFF; color: #203024; border: 1px solid #819777; }
  .results-card * { color: #203024 !important; }
  .table-scroll { overflow: visible; }
}
