@charset "UTF-8";

:root {
  --background: #f5f6f7;
  --surface: #ffffff;
  --surface-soft: #f5f7fa;
  --navy: #16324f;
  --ink: #152b40;
  --muted: #526273;
  --border: #d4dce4;
  --border-strong: #7c8b9a;
  --accent: #bd4215;
  --accent-hover: #9e340c;
  --accent-soft: #fff0e8;
  --error: #982d25;
  --error-soft: #fff1ee;
  --radius: 10px;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--background);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-variant-numeric: tabular-nums;
  scroll-behavior: smooth;
  scroll-padding-top: 132px;
}

* { box-sizing: border-box; }
body { min-width: 0; margin: 0; padding-bottom: calc(96px + env(safe-area-inset-bottom)); font-size: 16px; line-height: 1.5; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary { touch-action: manipulation; -webkit-tap-highlight-color: transparent; }
button, select, summary { cursor: pointer; }
button:disabled { cursor: not-allowed; opacity: .55; }
a { color: inherit; }
[hidden] { display: none !important; }
svg { display: block; flex-shrink: 0; }
button svg, .tool-nav svg, .tool-heading-icon svg, .privacy-note svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
h1, h2, h3, h4, p, label, legend, strong { overflow-wrap: anywhere; }
h1, h2, h3, h4, p { margin-top: 0; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline-offset: 2px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; z-index: 100; top: 12px; left: 12px; padding: 12px 16px; border-radius: 6px; background: var(--navy); color: #fff; transform: translateY(-160%); }
.skip-link:focus { transform: translateY(0); }

/* The tool switcher stays within reach on a phone. */
.site-header { position: sticky; z-index: 30; top: 0; background: var(--surface); border-bottom: 1px solid var(--border); box-shadow: 0 2px 8px rgb(21 43 64 / 3%); }
.header-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; max-width: 1320px; margin: 0 auto; padding: 10px 16px; }
.brand { display: inline-flex; grid-column: 1; grid-row: 1; justify-self: start; align-items: center; gap: 7px; color: var(--navy); text-decoration: none; font-size: 23px; font-weight: 780; letter-spacing: -.75px; line-height: 1; }
.brand-mark { width: 30px; height: 30px; }
.brand-mark svg { width: 100%; height: 100%; }
.brand-dot { color: var(--accent); }
.tool-nav { display: grid; grid-column: 1 / -1; grid-row: 2; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
.tool-nav-button { display: flex; align-items: center; justify-content: center; gap: 7px; min-width: 0; min-height: 44px; padding: 9px 7px; border: 1px solid transparent; border-radius: 6px; color: var(--muted); background: #f2f5f8; font-size: 14px; font-weight: 650; text-decoration: none; line-height: 1.3; }
.tool-nav-button:hover { color: var(--navy); background: #e8eef4; }
.tool-nav-button.is-active, .tool-nav-button[aria-current="page"] { color: var(--navy); background: #e7eef6; border-color: #b9cadc; }
.tool-nav-button svg { display: none; width: 18px; height: 18px; }
.tool-nav-button { overflow-wrap: anywhere; hyphens: auto; }
.tool-nav-button span { min-width: 0; }
.header-note { display: none; }
.language-menu { position: relative; grid-column: 2; grid-row: 1; justify-self: end; align-self: center; color: var(--navy); font-size: 14px; }
.language-label { display: none; }
.language-menu > summary { display: flex; align-items: center; min-height: 44px; gap: 5px; padding: 8px; border: 1px solid var(--border); border-radius: 6px; background: var(--surface); list-style: none; }
.language-menu > summary::-webkit-details-marker { display: none; }
.language-menu > summary::after { content: '⌄'; margin-left: 3px; }
.language-menu nav { position: absolute; top: calc(100% + 5px); right: 0; z-index: 50; display: grid; width: 170px; max-width: calc(100vw - 32px); padding: 5px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); box-shadow: 0 5px 20px rgb(21 43 64 / 12%); }
.language-menu nav a { display: flex; align-items: center; min-height: 44px; padding: 8px 12px; border-radius: 4px; text-decoration: none; }
.language-menu nav a:hover, .language-menu nav a[aria-current] { background: #e7eef6; }
.region-field { grid-column: 1 / -1; }

.page-shell { max-width: 1320px; margin: 0 auto; padding: 20px 16px 28px; }
.page-intro { margin-bottom: 16px; }
h1 { margin-bottom: 6px; color: var(--ink); font-size: 27px; font-weight: 750; line-height: 1.2; letter-spacing: -.65px; }
.intro-description { margin-bottom: 10px; color: var(--muted); font-size: 16px; line-height: 1.45; }
.privacy-note { display: flex; align-items: flex-start; gap: 7px; margin: 0; color: var(--muted); font-size: 14px; line-height: 1.5; }
.privacy-note svg { width: 17px; height: 17px; margin-top: 2px; color: var(--navy); }

/* Optional project controls are collapsed so the calculator comes first. */
.project-options { margin-bottom: 10px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); }
.project-options > summary { display: flex; align-items: center; gap: 9px; min-height: 50px; padding: 11px 14px; font-size: 14px; font-weight: 650; color: var(--navy); list-style: none; }
.project-options > summary::-webkit-details-marker { display: none; }
.project-options > summary::after { content: "+"; font-size: 22px; font-weight: 400; line-height: 1; }
.project-options[open] > summary::after { content: "−"; }
#project-options-summary { margin-left: auto; color: var(--muted); font-weight: 500; white-space: nowrap; }
.project-options[open] > summary { border-bottom: 1px solid var(--border); }
.project-toolbar { display: grid; gap: 16px; padding: 16px 14px 8px; }
.project-settings { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.project-name-field { grid-column: 1 / -1; }
.project-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.settings-help { margin: 0; padding: 0 14px 16px; color: var(--muted); font-size: 14px; }
.project-status { min-height: 21px; margin: 0 0 17px; color: var(--muted); font-size: 14px; line-height: 1.5; }
.error-summary { margin: 0 0 18px; padding: 14px; border: 1px solid #d6a499; border-radius: 8px; background: var(--error-soft); color: var(--error); font-size: 15px; line-height: 1.6; }
.error-summary p { margin-bottom: 0; }
.error-summary ul { margin: 6px 0 0; padding-left: 20px; }

.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field label, .field-label { color: var(--ink); font-size: 14px; font-weight: 600; line-height: 1.4; }
input, select, textarea { display: block; width: 100%; min-width: 0; min-height: 48px; padding: 10px 11px; border: 1px solid var(--border-strong); border-radius: 6px; color: var(--ink); background: var(--surface); font-size: 16px; line-height: 1.4; }
input:hover, select:hover, textarea:hover { border-color: #677d91; }
input:focus, select:focus, textarea:focus { border-color: var(--navy); }
input::placeholder, textarea::placeholder { color: #627386; opacity: 1; }
input[aria-invalid="true"], select[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: var(--error); background: #fff8f6; }
select { appearance: none; padding-right: 32px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' fill='none'%3E%3Cpath d='m1 1 5 5 5-5' stroke='%2316324f' stroke-width='1.6' stroke-linecap='round'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; }
textarea { min-height: 108px; resize: vertical; }
input[type="checkbox"], input[type="radio"] { display: inline-block; width: 20px; height: 20px; min-height: 20px; margin: 0; accent-color: var(--navy); flex-shrink: 0; }
.field-help, .section-help, .small-note, .summary-note { color: var(--muted); font-size: 14px; line-height: 1.55; }
.field-help { margin: 0; }
.optional { color: var(--muted); font-weight: 400; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; }
.field-full { grid-column: 1 / -1; }
.length-field { min-width: 0; margin: 0; padding: 0; border: 0; }
.length-field > legend { padding: 0; margin-bottom: 7px; color: var(--ink); font-size: 14px; font-weight: 650; }
.length-parts { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.length-parts .field { gap: 5px; }
.length-parts .field label { font-weight: 450; }
.feet-inches > .length-field { grid-column: 1 / -1; }
.custom-row { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 14px 12px; min-width: 0; margin: 0; padding: 15px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-soft); }
.custom-row legend { max-width: 100%; color: var(--navy); font-size: 14px; font-weight: 650; padding: 0 5px; }
.custom-row > .field:first-of-type { grid-column: 1 / -1; }
.custom-row > button { grid-column: 1 / -1; justify-self: end; }
.document-options { margin-top: 18px; border-top: 1px solid var(--border); }
.document-options > summary { display: flex; align-items: center; min-height: 48px; color: var(--navy); font-size: 14px; font-weight: 650; }
.document-options > .form-grid { margin: 8px 0 18px; }
.export-settings { margin-top: 20px; margin-bottom: 13px; }
#labor-cost-help { margin-top: 12px; }
.site-footer > a { min-height: 44px; display: inline-flex; align-items: center; }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 14px; border: 1px solid transparent; border-radius: 6px; font-size: 15px; font-weight: 650; text-decoration: none; line-height: 1.4; text-align: center; transition: background-color .15s, border-color .15s; }
.button-primary { color: #fff; background: var(--accent); border-color: var(--accent); }
.button-primary:hover:not(:disabled) { background: var(--accent-hover); border-color: var(--accent-hover); }
.button-secondary { color: var(--navy); background: #f1f5f9; border-color: #bccbd9; }
.button-secondary:hover:not(:disabled) { background: #e4edf6; border-color: #8ba4bb; }
.button-quiet, .button-text { color: var(--navy); background: transparent; }
.button-quiet:hover:not(:disabled), .button-text:hover:not(:disabled) { background: #eaf0f6; }
.button-small { min-height: 44px; padding: 9px 10px; font-size: 14px; }
.button-text { padding-right: 6px; padding-left: 6px; }
.button-text span[aria-hidden] { font-size: 20px; font-weight: 400; line-height: 1; }
.button-full { width: 100%; margin-top: 14px; }

/* Each tool is a single accessible form flow, with no step gates. */
.tool-panel { scroll-margin-top: 32px; }
.tool-heading { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.tool-layout, .calculator-inputs { display: grid; gap: 16px; min-width: 0; }
.card { min-width: 0; padding: 16px 14px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.section-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 8px; margin-bottom: 9px; }
.section-heading > div { display: flex; align-items: center; gap: 8px; min-width: 0; }
.step-number { display: grid; place-items: center; flex-shrink: 0; width: 27px; height: 27px; border-radius: 5px; color: var(--accent); background: var(--accent-soft); font-size: 13px; font-weight: 700; }
h3 { margin-bottom: 0; color: var(--ink); font-size: 18px; font-weight: 700; line-height: 1.35; letter-spacing: -.2px; }
.section-heading h3 { font-size: 17px; }
.section-help { margin: 0 0 17px; }
.rooms-list { display: grid; gap: 17px; }
fieldset.room-row, fieldset.product-card { min-inline-size: 0; margin: 0; }
.room-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; gap: 15px 12px; padding: 15px 12px; border: 1px solid #d2dce6; border-radius: 8px; background: var(--surface-soft); }
.room-row > legend, .product-card > legend { max-width: 100%; padding: 0 6px; color: var(--navy); font-size: 14px; font-weight: 700; white-space: normal; overflow-wrap: anywhere; }
.room-options { grid-column: 1 / -1; min-width: 0; padding-top: 3px; border-top: 1px solid var(--border); }
.room-options > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 44px; padding: 8px 2px; color: var(--navy); font-size: 14px; font-weight: 600; line-height: 1.5; list-style: none; }
.room-options > summary::-webkit-details-marker { display: none; }
.room-options > summary::after { content: "+"; flex-shrink: 0; font-size: 22px; font-weight: 400; line-height: 1; }
.room-options[open] > summary::after { content: "−"; }
.room-options > .field { margin-top: 12px; }
.room-options > .remove-button { display: flex; width: max-content; max-width: 100%; margin: 12px 0 0 auto; }
.checkbox-field { display: flex; align-items: center; gap: 9px; min-height: 48px; color: var(--ink); font-size: 14px; line-height: 1.5; }
.remove-button { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 46px; padding: 10px; border: 1px solid #c8d2dc; border-radius: 6px; background: var(--surface); color: var(--muted); font-size: 14px; font-weight: 600; line-height: 1.4; text-align: center; }
.remove-button:hover:not(:disabled) { color: var(--error); background: var(--error-soft); border-color: #d4a59b; }
.allowance-row { display: grid; gap: 10px; margin-top: 18px; padding-top: 17px; border-top: 1px solid var(--border); }
.allowance-field { max-width: 235px; }
.input-with-suffix { position: relative; display: flex; max-width: 120px; }
.input-with-suffix input { padding-right: 34px; }
.input-with-suffix > span { position: absolute; right: 13px; top: 12px; color: var(--muted); pointer-events: none; }
.products-list { display: grid; gap: 18px; }
.product-card { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; padding: 16px 12px; border: 1px solid #cbd7e3; border-radius: 8px; background: #f8fafc; }
.product-card > .field:first-of-type { grid-column: 1 / -1; }
.product-card > .remove-button { grid-column: 1 / -1; justify-self: end; }
.pricing-help { margin-top: 16px; padding: 12px; border-left: 3px solid #aabed1; background: var(--surface-soft); }

/* Purchase quantities and costs use the same structure in every tool. */
.results-column { min-width: 0; }
.summary-shell { min-width: 0; padding: 18px 14px; border: 1px solid #c1cfdd; border-radius: var(--radius); background: #edf3f8; }
.summary-heading { margin-bottom: 18px; padding-bottom: 13px; border-bottom: 1px solid #cbd8e5; }
.summary-heading h3 { font-size: 21px; }
.calculator-results { scroll-margin-top: 32px; min-width: 0; }
.result-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 19px 13px; min-width: 0; }
#estimate-results .metric:last-child { grid-column: 1 / -1; border-top: 2px solid #b9cadc; padding-top: 16px; }
#estimate-results .metric:last-child .metric-label { color: var(--navy); font-weight: 650; }
#estimate-results .metric:last-child .metric-value { font-size: 32px; }
.metric { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.metric-label { display: block; color: var(--muted); font-size: 14px; line-height: 1.4; }
.metric-value { display: block; color: var(--navy); font-size: 22px; font-weight: 750; line-height: 1.25; letter-spacing: -.45px; overflow-wrap: anywhere; }
.results-card { min-width: 0; margin-top: 18px; padding: 16px 12px; border: 1px solid #c7d4e1; border-radius: 8px; background: var(--surface); }
.results-card h3 { margin-bottom: 12px; font-size: 17px; }
.results-card > .button { width: 100%; margin-top: 16px; font-size: 14px; }
.comparison-badge { display: inline-block; margin: 0 0 15px; padding: 5px 8px; border: 1px solid #c1d7c6; border-radius: 4px; color: #28543a; background: #eaf4ed; font-size: 14px; font-weight: 600; line-height: 1.4; }
.small-note { margin: 16px 0 0; }
.summary-note { margin: 16px 0 0; }
.inline-error { margin: 0; padding: 12px; border: 1px solid #d6a499; border-radius: 6px; color: var(--error); background: var(--error-soft); font-size: 15px; line-height: 1.6; }
.estimate-lines { display: grid; gap: 14px; }
.estimate-line { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 12px; min-width: 0; padding: 14px 12px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-soft); }
.estimate-line h3 { margin-bottom: 5px; font-size: 17px; }
.estimate-line .small-note { margin: 0; }
.estimate-line > strong { max-width: 125px; color: var(--navy); font-size: 17px; font-weight: 700; text-align: right; }
.estimate-line > button { grid-column: 1 / -1; justify-self: end; }
.empty-state { margin: 0; padding: 18px 14px; border: 1px dashed #acbdcc; border-radius: 8px; color: var(--muted); background: #f8fafc; font-size: 15px; line-height: 1.6; }

.calculation-notes { display: grid; gap: 10px; margin-top: 24px; }
.calculation-notes details { min-width: 0; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); }
.calculation-notes summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 48px; padding: 12px 14px; color: var(--navy); font-size: 14px; font-weight: 600; line-height: 1.5; list-style: none; }
.calculation-notes summary::-webkit-details-marker { display: none; }
.calculation-notes summary::after { content: "+"; font-size: 22px; font-weight: 400; line-height: 1; }
.calculation-notes details[open] summary::after { content: "−"; }
.details-content { padding: 0 14px 4px; color: var(--muted); font-size: 14px; line-height: 1.65; }
.details-content p { margin-bottom: 13px; }
.details-content strong { color: var(--ink); font-weight: 650; }
.site-footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 20px; max-width: 1288px; margin: 0 auto; padding: 19px 16px 25px; border-top: 1px solid var(--border); color: var(--muted); font-size: 14px; }
.footer-brand { color: var(--navy); font-size: 17px; font-weight: 750; text-decoration: none; letter-spacing: -.4px; }
.site-footer p { margin: 0; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 4px 18px; }
.site-footer nav a { display: inline-flex; align-items: center; min-height: 44px; text-underline-offset: 3px; }
.information-page { padding-bottom: 0; }
.reading-shell { max-width: 920px; }
.prose { line-height: 1.7; }
.prose h2 { margin: 26px 0 12px; font-size: 23px; line-height: 1.3; letter-spacing: -.35px; }
.prose h3 { margin: 24px 0 9px; font-size: 18px; }
.prose p, .prose ul, .prose ol { margin-bottom: 18px; }
.prose a:not(.button) { color: var(--navy); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.prose a:not(.button):hover { color: var(--accent); }
.prose .card { margin: 20px 0; }
.prose .card h2:first-child { margin-top: 0; }
.prose .card p:last-child { margin-bottom: 0; }
.notice-preview { padding: 14px 16px; border-left: 4px solid var(--navy); border-radius: 4px; background: #e7eef6; font-size: 14px; }
.legal-updated { color: var(--muted); font-size: 14px; }
.table-scroll { max-width: 100%; overflow-x: auto; margin: 20px 0; }
.table-scroll table { width: 100%; min-width: 580px; border-collapse: collapse; font-size: 14px; line-height: 1.6; }
.table-scroll th, .table-scroll td { padding: 12px; border: 1px solid var(--border-strong); text-align: left; vertical-align: top; }
.table-scroll thead { background: var(--surface-soft); }
.table-scroll code { overflow-wrap: anywhere; }
.tool-content { max-width: 80ch; margin: 32px auto 20px; padding: 24px 0 4px; border-top: 1px solid var(--border); }
.tool-content h2:first-child { margin-top: 0; }
.breadcrumbs { margin-bottom: 22px; color: var(--muted); font-size: 14px; }
.breadcrumbs ol { display: flex; flex-wrap: wrap; gap: 4px 9px; margin: 0; padding: 0; list-style: none; }
.breadcrumbs li { display: inline-flex; align-items: center; gap: 9px; }
.breadcrumbs li + li::before { content: "/"; color: var(--muted); }
.breadcrumbs a { display: inline-flex; align-items: center; min-height: 32px; }
.article-label { margin-bottom: 9px !important; color: var(--accent); font-size: 14px; font-weight: 650; }
.guide-grid { display: grid; gap: 16px; }
.guide-grid .card { margin: 0; }
.guide-next { margin-top: 32px; padding: 22px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.guide-next h2 { margin-top: 0; }
.guide-next p:last-child { margin: 18px 0 0; }
.mobile-summary { position: fixed; z-index: 40; right: 0; bottom: 0; left: 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); border-top: 1px solid #b8c8d8; background: #fff; box-shadow: 0 -4px 16px rgb(21 43 64 / 7%); }
.mobile-summary > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.mobile-summary span { color: var(--muted); font-size: 14px; line-height: 1.35; }
.mobile-summary strong { color: var(--navy); font-size: 20px; font-weight: 750; line-height: 1.2; letter-spacing: -.3px; }
.mobile-summary .button { flex-shrink: 0; font-size: 14px; min-height: 46px; padding-right: 12px; padding-left: 12px; }
.mobile-summary .button span { color: inherit; font-size: 18px; }
.editing-field .mobile-summary { display: none; }

/* A translated action must not squeeze a monetary value into broken digits. */
@media (max-width: 420px) {
  .brand { font-size: 21px; }
  body { padding-bottom: calc(148px + env(safe-area-inset-bottom)); }
  .mobile-summary { display: grid; grid-template-columns: minmax(0, 1fr); gap: 9px; }
  .mobile-summary > div { flex-direction: row; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; }
  .mobile-summary span { flex: 1 1 110px; }
  .mobile-summary strong { white-space: nowrap; overflow-wrap: normal; }
  .mobile-summary .button { width: 100%; }
}
.print-document { display: none; }

@media (min-width: 640px) {
  .header-inner { grid-template-columns: auto minmax(210px, 420px) auto; align-items: center; justify-content: space-between; padding: 13px 24px; gap: 12px; }
  .language-menu { grid-column: 3; grid-row: 1; max-width: 100%; }
  .language-label { display: inline; }
  .tool-nav { grid-column: 2; grid-row: 1; }
  .tool-nav-button svg { display: block; }
  .brand { font-size: 25px; }
  .brand-mark { width: 34px; height: 34px; }
  .page-shell { padding: 25px 24px 32px; }
  h1 { font-size: 32px; }
  .project-toolbar { padding: 18px 18px 10px; }
  .project-settings { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .project-name-field { grid-column: 1 / -1; }
  .settings-help { padding-right: 18px; padding-left: 18px; }
  .card { padding: 22px; }
  .section-heading h3 { font-size: 18px; }
  .room-row { padding: 18px; }
  .feet-inches > .length-field { grid-column: auto; }
  .allowance-row { grid-template-columns: minmax(190px, .6fr) minmax(0, 1fr); align-items: center; gap: 20px; }
  .summary-shell { padding: 22px; }
  .results-card { padding: 18px; }
  .metric-value { font-size: 25px; }
  .calculation-notes { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
  .site-footer { padding-right: 24px; padding-left: 24px; }
  .mobile-summary { padding-right: 24px; padding-left: 24px; }
}

@media (min-width: 1024px) {
  :root { scroll-padding-top: 110px; }
  body { padding-bottom: 0; }
  .header-inner { grid-template-columns: auto minmax(360px, 440px) auto; gap: 28px; padding: 17px 32px; }
  .header-note { display: none; }
  .tool-nav-button { font-size: 15px; }
  .page-shell { padding: 30px 32px 38px; }
  .page-intro { margin-bottom: 22px; }
  h1 { font-size: 34px; }
  .project-options { margin-bottom: 10px; }
  .project-options > summary { padding-right: 18px; padding-left: 18px; }
  .project-toolbar { grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 20px; }
  .project-settings { max-width: 640px; }
  .project-actions { justify-content: end; max-width: 390px; }
  .project-status { margin-bottom: 24px; }
  .tool-layout { grid-template-columns: minmax(0, 1fr) minmax(330px, .48fr); align-items: start; gap: 24px; }
  .calculator-inputs { gap: 20px; }
  .products-list { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
  .products-list:has(> :only-child) { grid-template-columns: minmax(0, 1fr); }
  .product-card { padding: 16px 14px; }
  .results-column { position: sticky; top: 110px; }
  .summary-shell { padding: 21px 18px; }
  .metric-value { font-size: 23px; }
  .calculator-results, .tool-panel { scroll-margin-top: 32px; }
  .site-footer { padding-right: 32px; padding-left: 32px; }
  .mobile-summary { display: none; }
}

@media (min-width: 1280px) {
  .tool-layout { grid-template-columns: minmax(0, 1fr) 370px; gap: 28px; }
  .card { padding: 24px; }
  .summary-shell { padding: 24px 22px; }
  .project-toolbar { grid-template-columns: minmax(0, 1fr) minmax(330px, .6fr); }
}

@media (prefers-reduced-motion: reduce) {
  :root { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0s !important; animation-duration: 0s !important; }
}

/* The root-owned print renderer emits a complete document, not the input form. */
@media print {
  @page { margin: 18mm; }
  :root, body { padding: 0; background: #fff; color: #000; }
  body > * { display: none !important; }
  body > .print-document { display: block !important; font: 11pt/1.5 system-ui, sans-serif; }
  body.information-page > main { display: block !important; max-width: none; padding: 0; }
  .information-page .breadcrumbs, .information-page .button, .information-page .guide-next { display: none !important; }
  .print-document h1 { margin: 0 0 16pt; font-size: 24pt; color: #16324f; }
  .print-document h2 { font-size: 15pt; margin: 18pt 0 8pt; }
  .print-document .print-brand { color: #16324f; font-weight: 700; }
  .print-document table { width: 100%; border-collapse: collapse; margin: 18pt 0; }
  .print-document th, .print-document td { border-bottom: 1px solid #ccd6ca; padding: 9pt 6pt; text-align: left; vertical-align: top; }
  .print-document th:nth-child(2), .print-document td:nth-child(2) { text-align: right; min-width: 90pt; }
  .print-document td p { margin: 5pt 0 0; font-size: 10pt; }
  .print-document dl { display: grid; grid-template-columns: 1fr auto; gap: 8pt 20pt; }
  .print-document dd { margin: 0; text-align: right; }
  .print-document dt:last-of-type, .print-document dd:last-of-type { font-weight: 700; font-size: 15pt; padding-top: 10pt; border-top: 2px solid #16324f; }
  .print-document .print-notes { white-space: pre-wrap; overflow-wrap: anywhere; }
}
