:root {
  color-scheme: light;
  --paper: #f8f7f2;
  --text: #1e211d;
  --accent: #e4541d;
  --rule: #d2d1c9;
  font-family: "Malgun Gothic", "Apple SD Gothic Neo", system-ui, sans-serif;
  color: var(--text);
  background: var(--paper);
}
* { box-sizing: border-box; }
body, h1, h2, p, figure { margin: 0; }
body { word-break: keep-all; }
a { color: inherit; text-decoration: none; }
a:focus-visible, input:focus-visible, .choices input:focus-visible + span {
  outline: 3px solid #195da5; outline-offset: 4px;
}
.skip { position: absolute; left: 1rem; top: -5rem; background: white; padding: .6rem; z-index: 2; }
.skip:focus { top: .5rem; }
.wrap { width: min(90%, 82rem); margin-inline: auto; }
header { border-bottom: 1px solid var(--rule); }
.bar, nav, .brand, figcaption, footer, .choices { display: flex; align-items: center; }
.bar { min-height: 5rem; justify-content: space-between; gap: 1rem; }
.brand { gap: .75rem; font-size: 1.55rem; font-weight: 900; letter-spacing: -.09em; }
.mark { position: relative; display: inline-block; width: 1.8rem; height: 1.8rem; background: var(--accent); }
.mark::after { content: ""; position: absolute; inset: 25%; border: solid var(--text); border-width: 0 0 .3rem .3rem; }
nav { gap: clamp(.75rem, 3.2vw, 2.8rem); font-size: .94rem; font-weight: 650; }
nav a, .brand { padding-block: .6rem; }
nav a:hover, .brand:hover { text-decoration: underline; text-underline-offset: .35em; }
.hero { display: grid; grid-template-columns: 0.94fr 1.2fr; gap: clamp(1.5rem,4vw,5rem); align-items: center; padding: clamp(3rem,6.6vw,7rem) 0; }
.category { display: flex; align-items: center; gap: .6rem; font-size: .94rem; font-weight: 700; margin-bottom: 1.35rem; }
.category span { width: 1.8rem; height: 3px; background: var(--accent); }
h1 { font-size: clamp(2.45rem,4.65vw,4.75rem); line-height: 1.18; letter-spacing: -.09em; font-weight: 900; }
h1 span { color: var(--accent); }
.summary { margin: 1.5rem 0 1.8rem; font-size: clamp(1rem,1.2vw,1.12rem); line-height: 1.8; color: #50514b; }
.button { display: inline-flex; background: var(--text); color: white; font-size: .95rem; font-weight: 700; padding: .95rem 1.35rem; border-radius: 3px; }
.button:hover { background: #393b34; }
figure { min-width: 0; }
figure img { display: block; width: 100%; height: auto; aspect-ratio: 1.48; object-fit: cover; }
figcaption { justify-content: space-between; gap: .75rem; padding-top: .75rem; font-size: .875rem; color: #51524d; }
figcaption strong { font-family: "Arial", sans-serif; font-size: .875rem; letter-spacing: .12em; color: var(--text); }
.section { padding: clamp(2.4rem,4.5vw,4.25rem) 0; border-top: 1px solid var(--text); scroll-margin-top: 1.25rem; }
h2 { font-size: clamp(1.9rem,3vw,2.8rem); line-height: 1.2; letter-spacing: -.07em; }
h3 { margin: .3rem 0 .5rem; font-size: clamp(1.2rem,1.8vw,1.6rem); letter-spacing: -.04em; }
h3 small { font-size: .82rem; font-weight: 600; color: #53564f; letter-spacing: .06em; }
.section-head, .filter-row { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.section-head { margin-bottom: 1.6rem; }
.section-head p, .card-copy > p:not(.kind) { color: #54574f; line-height: 1.65; }
.section-head p { margin-top: .65rem; }
.actions, .filters { display: flex; align-items: center; gap: .7rem 1rem; flex-wrap: wrap; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
button:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid #195da5; outline-offset: 3px; }
.button { border: 1px solid var(--text); justify-content: center; line-height: 1.3; align-items: center; min-height: 2.8rem; }
.button.secondary { background: transparent; color: var(--text); }
.button.secondary:hover { background: #e9e8e0; }
.button:disabled { opacity: .5; cursor: default; }
.text-link { color: var(--text); text-decoration: underline; text-underline-offset: .25em; text-decoration-color: #9a9a8e; font-size: .94rem; font-weight: 650; background: transparent; border: 0; padding: 0; }
.text-link:hover { text-decoration-color: var(--accent); }
.search-tools { width: min(100%, 18rem); }
.settings label, legend, .search-tools label { display: block; font-size: .9rem; font-weight: 700; }
.settings label small { font-weight: 500; font-size: .875rem; color: #54574f; }
input:not([type=radio]), select, textarea { display: block; width: 100%; min-height: 2.8rem; border-radius: 3px; border: 1px solid #9c9e94; background-color: #fff; padding: .65rem .8rem; margin: .4rem 0 0; }
select { appearance: none; padding-right: 2.2rem; background-image: linear-gradient(45deg, transparent 50%, #3f443a 50%), linear-gradient(135deg, #3f443a 50%, transparent 50%); background-position: calc(100% - 17px) center, calc(100% - 12px) center; background-size: 5px 5px; background-repeat: no-repeat; }
textarea { resize: vertical; }
.filter-row { align-items: center; margin-bottom: 1.25rem; }
.filters { gap: .4rem; }
.filters button { border: 1px solid #c1c2b8; border-radius: 2rem; background: transparent; padding: .48rem .9rem; font-size: .9rem; }
.filters button[aria-pressed=true] { background: var(--text); color: #fff; border-color: var(--text); }
#count, .hint, .status { font-size: .875rem; color: #51564d; }
#count { white-space: nowrap; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: clamp(.9rem, 2.1vw, 2rem); }
.gallery-grid article { min-width: 0; border-bottom: 1px solid var(--rule); }
.gallery-grid img { width: 100%; height: auto; display: block; aspect-ratio: 1.65; object-fit: cover; }
.card-copy { padding: 1.05rem 0 1.25rem; }
.kind { color: #91401e; font-weight: 700; font-size: .875rem; }
.apply { display: inline-block; margin-top: .9rem; }
.empty { text-align: center; background: #efefe8; padding: 2.5rem 1rem; }
.empty button { margin-top: .75rem; }
[hidden] { display: none !important; }
.workbench { display: grid; grid-template-columns: minmax(0, .78fr) minmax(0,1.22fr); gap: clamp(2rem,5vw,5rem); align-items: start; }
.settings { min-width: 0; }
.control-pair, .measurements { display: grid; gap: .75rem; }
.control-pair { grid-template-columns: repeat(2,minmax(0,1fr)); margin: 1rem 0; }
.measurements { grid-template-columns: repeat(3,minmax(0,1fr)); margin-bottom: 1.2rem; }
fieldset { border: 0; padding: 0; margin: .95rem 0; min-width: 0; }
legend { padding: 0; margin-bottom: .45rem; }
.choices { display: flex; gap: .4rem; flex-wrap: wrap; }
.choices label { position: relative; cursor: pointer; font-weight: 500; }
.choices input { opacity: 0; position: absolute; inset: 0; margin: 0; width: 100%; height: 100%; cursor: pointer; }
.choices span { display: inline-flex; align-items: center; justify-content: center; min-width: 3rem; padding: .62rem .8rem; gap: .45rem; font-size: .9rem; border: 1px solid #bcbcb2; border-radius: 3px; }
.choices input:checked + span { border-color: var(--text); box-shadow: inset 0 0 0 1px var(--text); }
.choices i { width: .85rem; height: .85rem; border-radius: 50%; border: 1px solid #0003; }
.orange { background: #f37440; } .cream { background: #fbefcf; } .ink { background: #292d29; }
.settings .actions, #brief { margin-top: 1.2rem; }
.hint, .status { line-height: 1.6; margin-top: .55rem; }
.status:empty { display: none; }
.design-output canvas { display: block; width: 100%; height: auto; background: #dcdcd2; }
.receipt { padding: clamp(1.4rem, 3.2vw, 3rem); color: #f8f7f2; background: #242b25; }
#quote-kind { color: #ffb095; font-size: .94rem; font-weight: 700; }
.receipt-label { margin: 1.35rem 0 .2rem; }
#total { font-size: clamp(1.85rem,4vw,3.75rem); font-weight: 800; letter-spacing: -.06em; font-variant-numeric: tabular-nums; }
.receipt dl { padding-top: 1.15rem; margin: 1.35rem 0 1.15rem; border-top: 1px solid #646b62; }
.receipt dl > div { display: flex; justify-content: space-between; gap: 1rem; line-height: 1.8; }
.receipt dd { margin: 0; text-align: right; }
#quote-note { color: #d6dbd1; font-size: .875rem; line-height: 1.6; }
footer { flex-wrap: wrap; justify-content: space-between; gap: .5rem 1rem; padding: 1.5rem 0 2rem; border-top: 1px solid var(--rule); color: #565752; font-size: .9rem; }
@media (max-width: 760px) {
  .bar { min-height: 4.25rem; flex-wrap: wrap; }
  .hero, .workbench { grid-template-columns: 1fr; gap: 1.65rem; }
  .hero { padding: 2.6rem 0 2.3rem; }
  h1 { font-size: clamp(2.5rem, 8.2vw, 3.7rem); }
  .summary { margin: 1rem 0 1.3rem; }
  .category { margin-bottom: .85rem; }
  figure img { aspect-ratio: 1.65; }
  .brand { font-size: 1.3rem; gap: .45rem; }
  .mark { width: 1.45rem; height: 1.45rem; }
  .section-head { align-items: start; flex-direction: column; }
  .gallery-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .gallery-grid img { aspect-ratio: 2 / 1; }
  .search-tools { width: 100%; }
}
@media (max-width: 440px) {
  .bar { align-content: center; gap: 0 .75rem; padding-block: .5rem; }
  nav { gap: .7rem; font-size: .875rem; flex-wrap: wrap; }
  .filter-row { align-items: start; flex-direction: column; gap: .65rem; }
  .filters button { padding-inline: .7rem; }
}
