/* RFQ form — extends /style.css (paper + ink, rules instead of shadows). */
.q-wrap { max-width: 980px; margin: 0 auto; padding-inline: var(--gutter); }
.q-hero { background: var(--ink); color: var(--on-ink); padding-block: clamp(48px, 7vw, 88px); margin-bottom: 40px; }
.q-hero .label { color: var(--on-ink-muted); }
.q-hero h1 { font-size: clamp(1.9rem, 4vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; margin: 14px 0 18px; max-width: 18em; }
.q-hero .lede { color: var(--on-ink-muted); }

.q-alert { border: 1px solid var(--saffron-ink); border-left-width: 4px; background: #fff4ea; color: var(--ink); padding: 14px 18px; margin-bottom: 28px; }
.q-form { display: grid; gap: 36px; padding-bottom: 72px; }
.q-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.q-step { border: 0; border-top: 1px solid var(--ink); padding-top: 22px; min-width: 0; }
.q-step legend { float: left; width: 100%; font-size: 1.35rem; font-weight: 500; letter-spacing: -0.01em; margin-bottom: 8px; }
.q-step legend .idx { margin-right: 10px; vertical-align: 3px; }
.q-step > :not(legend) { clear: both; }
.q-hint { color: var(--muted); font-size: 0.95rem; margin-bottom: 16px; }
.q-err { color: #a3241a; font-size: 0.9rem; margin-top: 6px; }

.q-cats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: start; }
.q-cat { border: 1px solid var(--rule); background: #fbfaf7; }
.q-cat[open] { border-color: var(--ink); grid-column: span 2; }
.q-cat summary { list-style: none; cursor: pointer; padding: 16px 44px 16px 18px; position: relative; display: grid; gap: 2px; }
.q-cat summary::-webkit-details-marker { display: none; }
.q-cat summary::after { content: "+"; position: absolute; right: 18px; top: 14px; font: 400 1.4rem/1 var(--mono); color: var(--muted); }
.q-cat[open] summary::after { content: "–"; }
.q-cat summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.q-cat-name { font-weight: 600; font-size: 1.08rem; }
.q-cat-blurb { color: var(--muted); font-size: 0.9rem; }
.q-cat-count { font: 500 0.78rem/1.4 var(--mono); color: var(--accent); min-height: 1.1em; }
.q-svcs { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 6px 16px; padding: 4px 18px 18px; border-top: 1px solid var(--rule); padding-top: 14px; }

.q-check { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; cursor: pointer; font-size: 0.97rem; }
.q-check input { width: 18px; height: 18px; margin-top: 3px; accent-color: var(--accent); flex: none; }
.q-custom { margin-top: 16px; padding: 14px 18px; border: 1px dashed var(--rule); }

.q-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 22px; }
.q-span2 { grid-column: span 2; }
.q-field label { display: block; font-size: 0.92rem; font-weight: 500; margin-bottom: 6px; }
.q-req { color: var(--saffron-ink); }
.q-opt { color: var(--muted); font-weight: 400; }
.q-field input, .q-field select, .q-field textarea, .q-phone select {
    width: 100%; font: 400 1rem/1.4 var(--sans); color: var(--ink);
    background: #fff; border: 1px solid #bdb8ab; border-radius: 2px; padding: 11px 12px;
}
.q-field textarea { resize: vertical; min-height: 120px; }
.q-field input:focus, .q-field select:focus, .q-field textarea:focus, .q-phone select:focus { outline: 2px solid var(--accent); outline-offset: 0; border-color: var(--accent); }
.q-field [aria-invalid="true"] { border-color: #a3241a; background: #fff8f7; }
.q-phone { display: flex; gap: 8px; }
.q-phone select { width: 9.5em; flex: none; }

.q-submit { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; border-top: 1px solid var(--ink); padding-top: 22px; }
.q-submit .q-hint { margin: 0; }
.q-submit .btn { font-size: 1.02rem; padding: 1em 1.8em; cursor: pointer; }
.btn-ghost { color: var(--ink); border-color: var(--rule); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); }

.q-thanks { padding-block: clamp(56px, 8vw, 110px); }
.q-thanks h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin: 12px 0 28px; }
.q-ref { display: inline-grid; gap: 6px; border: 1px solid var(--ink); padding: 18px 24px; margin-bottom: 28px; background: #fff; }
.q-ref strong { font: 500 clamp(1.4rem, 3vw, 2rem)/1 var(--mono); letter-spacing: 0.02em; color: var(--accent-ink); }
.q-thanks p { margin-bottom: 14px; max-width: 40em; }
.q-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

@media (max-width: 720px) {
    .q-cats, .q-grid { grid-template-columns: 1fr; }
    .q-cat[open], .q-span2 { grid-column: auto; }
    .q-phone select { width: 7.5em; }
    .q-submit .btn { width: 100%; justify-content: center; }
}
.q-captcha input { max-width: 8em; }
