.hat-request{padding-bottom:80px}.hat-selection-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:60px;align-items:start}.hat-gallery{position:sticky;top:108px;padding:22px;background:#eee7dc;border:1px solid var(--line);border-radius:8px}.gallery-label{display:flex;justify-content:space-between;font-size:10px;letter-spacing:.08em;margin-bottom:14px}.hat-photo-frame{height:360px;display:grid;place-items:center;background:#f7f3ec;overflow:hidden;border-radius:4px}.hat-photo-frame img{width:100%;height:100%;object-fit:contain}.hat-thumbnails{display:flex;gap:10px;margin-top:14px}.hat-thumbnails button{background:var(--paper);border:1px solid var(--line);padding:4px;width:76px;min-height:70px;border-radius:4px}.hat-thumbnails img{width:100%;height:58px;object-fit:contain}.photo-note{font-size:11px;line-height:1.6;color:var(--muted)}.hat-option{padding-bottom:28px;margin-bottom:28px;border-bottom:1px solid var(--line);scroll-margin-top:110px}.hat-option h2,.hat-contact h2,.hat-review h2,.hat-success h2{font-size:25px;letter-spacing:-.035em;margin:0 0 14px}.hat-option>p{font-size:13px;color:var(--muted)}.step-label{font-size:10px!important;letter-spacing:.1em;font-weight:700;color:var(--copper)!important}.hat-models{display:grid;gap:10px}.hat-model-card{display:grid;grid-template-columns:72px 1fr;gap:15px;align-items:center;text-align:left;border:1px solid var(--line);border-radius:5px;background:#fff;padding:14px;min-height:90px;color:var(--ink)}.hat-model-card img{width:72px;height:66px;object-fit:contain}.hat-model-card strong,.hat-model-card small{display:block}.hat-model-card small{font-size:11px;color:var(--muted);margin-top:4px}.help-mark{font-size:30px;text-align:center;color:var(--copper)}#hat-description{font-size:13px;color:var(--muted);margin-top:18px}.hat-specs{display:grid;grid-template-columns:110px 1fr;gap:7px}.hat-specs dd{margin:0}.hat-color-list,.hat-methods{display:flex;flex-wrap:wrap;gap:10px}.hat-color-list button,.hat-methods button{display:flex;align-items:center;gap:10px;min-height:48px;background:#fff;border:1px solid var(--line);border-radius:5px;padding:12px;color:var(--ink);text-align:left}.hat-color-list .swatch{width:25px;height:25px;border:1px solid #0003;border-radius:50%}.hat-methods button{display:block;width:100%}.hat-methods small{display:block;color:var(--muted);font-size:11px;margin-top:5px}.artwork-drop{padding:22px;border:1px dashed var(--copper);border-radius:6px;background:#fff;display:grid;gap:12px}.artwork-drop.dragging{background:#efe0ce}.artwork-drop label{font-weight:700;font-size:14px}.artwork-drop input{max-width:100%;font-size:12px}.artwork-drop input::file-selector-button{min-height:44px;background:var(--paper);border:1px solid var(--line);border-radius:4px;padding:8px 14px;color:var(--ink)}.artwork-preview{background:#fff;border:1px solid var(--line);padding:20px;margin:16px 0;overflow-wrap:anywhere}.artwork-preview img{max-width:240px;width:100%;height:160px;object-fit:contain;background:#f7f3ec}.artwork-preview p{font-size:12px}.artwork-status-options{border:0;padding:0;margin:20px 0}.artwork-status-options legend{font-size:13px;font-weight:700;margin-bottom:10px}.artwork-status-options label{display:flex;align-items:center;gap:8px;font-size:13px;min-height:44px}.artwork-status-options input{width:18px;height:18px;accent-color:var(--copper)}.hat-option .field{margin-top:18px}.hat-request small,.hat-request .form-help{font-size:12px;color:var(--muted)}.pricing-note{padding:20px;background:#ede2d3;border-radius:6px;margin:20px 0}.pricing-note strong{font-size:14px}.pricing-note p{font-size:12px;margin-bottom:0}.field-error{color:#963a21!important;font-size:12px!important;margin:6px 0!important}.field-error:empty{display:none}.hat-request [aria-invalid=true]{border-color:#963a21;outline-color:#963a21}.hat-contact,.hat-review{display:grid;grid-template-columns:1fr 1fr;gap:60px;padding:40px 0;border-top:1px solid var(--line);scroll-margin-top:110px}.hat-contact p,.hat-review p{font-size:14px;color:var(--muted)}.hat-contact a{text-decoration:underline}.hat-summary{margin:0 0 25px}.summary-row{display:grid;grid-template-columns:90px minmax(0,1fr) auto;gap:12px;padding:10px 0;border-bottom:1px solid var(--line);font-size:12px}.summary-row dt{color:var(--muted)}.summary-row dd{margin:0;overflow-wrap:anywhere}.summary-row a{font-size:11px;color:var(--copper);text-decoration:underline;min-height:30px}.hat-review .button{width:100%;white-space:normal}.hat-success{padding:30px;background:#eee2d1;border:1px solid var(--line);border-radius:6px;scroll-margin-top:110px}.hat-success p{font-size:13px;overflow-wrap:anywhere}.hat-mobile-continue{display:none}.hat-request input,.hat-request textarea{width:100%;max-width:100%}.hat-request input[type=radio]{width:18px}.hat-request fieldset{min-width:0}.hat-request .studio-controls{min-width:0}.hat-request .quantity-options{margin-top:16px}.hat-option,.hat-contact,.hat-review{min-width:0}
@media(max-width:980px){.hat-selection-layout,.hat-contact,.hat-review{gap:28px}.hat-photo-frame{height:300px}}@media(max-width:720px){.hat-selection-layout,.hat-contact,.hat-review{grid-template-columns:1fr;gap:28px}.hat-gallery{position:static;padding:16px}.hat-photo-frame{height:300px}.hat-contact .brief-grid{grid-template-columns:1fr}.hat-mobile-continue{display:block;position:fixed;bottom:0;left:0;right:0;padding:10px 16px calc(10px + env(safe-area-inset-bottom));background:var(--paper);border-top:1px solid var(--line);z-index:110}.hat-mobile-continue .button{width:100%;min-height:46px}.hat-mobile-continue.near-contact{display:none}.hat-request{padding-bottom:35px}.hat-contact,.hat-review{padding:30px 0}.summary-row{grid-template-columns:75px minmax(0,1fr) auto;gap:8px}.hat-success .button,.hat-success .small-button{width:100%;margin-top:10px}}

.hat-models{grid-template-columns:1fr 1fr;max-height:360px;overflow:auto;padding:5px;margin:12px -5px;scrollbar-color:var(--copper) var(--paper)}.hat-model-card{grid-template-columns:1fr;padding:10px;gap:6px}.hat-model-card img{width:100%;height:85px}.hat-model-card strong{font-size:12px}.hat-model-card small{font-size:10px}.hat-color-list img{width:44px;height:44px;object-fit:contain}#hat-search{min-height:46px;padding:10px;border:1px solid var(--line);border-radius:5px;background:#fff}#hat-description a{text-decoration:underline;color:var(--copper);font-size:12px}.hat-request .artwork-status-options input{flex-shrink:0}.hat-model-card:focus-visible{outline-offset:-3px}

/* Bound the photo independently of its intrinsic dimensions so no brim is cropped. */
.hat-gallery{scroll-margin-top:110px;top:100px;padding:18px}
.hat-photo-frame{position:relative;display:block;height:clamp(260px,46vh,400px);background:#fff;isolation:isolate}
.hat-photo-frame #hat-photo{position:absolute;inset:0;display:block;width:100%;height:100%;min-height:0;max-height:100%;object-fit:contain}
.hat-photo-frame #hat-photo[hidden]{display:none}
#photo-placeholder{padding:70px 20px;text-align:center}
.hat-decoration{position:absolute;transform:translate(-50%,-50%);pointer-events:none;filter:drop-shadow(0 1px 1px #0007)}
.hat-decoration svg{display:block;width:100%;height:100%;overflow:visible}
.hat-decoration.is-embroidery{filter:drop-shadow(.5px .5px 0 #0008)}
.decoration-fieldset{border:0;padding:0;margin:22px 0;min-width:0}
.decoration-fieldset legend{font-size:13px;font-weight:700;margin-bottom:12px}
.hat-shapes{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:8px}
.hat-shapes button{background:#fff;border:1px solid var(--line);border-radius:5px;min-height:80px;padding:8px 4px;color:var(--ink)}
.hat-shapes svg{width:58px;height:38px;display:block;margin:0 auto 5px}
.hat-shapes span{display:block;font-size:10px;line-height:1.3}
.hat-materials{display:flex;gap:8px;flex-wrap:wrap}
.hat-materials button{display:flex;align-items:center;gap:8px;border:1px solid var(--line);border-radius:5px;min-height:46px;padding:8px 12px;background:#fff;color:var(--ink);font-size:12px}
.material-chip{width:22px;height:22px;border-radius:50%;border:1px solid #0004}
.border-option{display:flex;gap:10px;align-items:center;font-size:13px;min-height:44px}
.hat-request .border-option input{width:18px;height:18px;accent-color:var(--copper)}
.preview-design-link{display:inline-block;margin-top:16px}
.hat-thumbnails button{min-height:54px;width:62px}.hat-thumbnails img{height:42px}
@media(max-width:720px){.hat-gallery{position:static;scroll-margin-top:90px}.hat-photo-frame{height:300px}.hat-shapes{grid-template-columns:repeat(3,minmax(0,1fr))}}

#hat-color-preview{position:absolute;inset:0;width:100%;height:100%;object-fit:contain;pointer-events:none}#hat-color-preview[hidden]{display:none}.hat-decoration{z-index:1}
