/* Narrow-screen adaptations; the supplied desktop layout, palette and type stay intact. */
html { min-width:320px; scroll-behavior:smooth; }
body { overflow-wrap:break-word; }
button,input,select,textarea { touch-action:manipulation; }
@media (max-width:760px) { button { min-height:44px; } }
button:disabled { opacity:.5; cursor:not-allowed !important; }
input:focus-visible, button:focus-visible, a:focus-visible, [role=button]:focus-visible { outline:2px solid #14140f !important; outline-offset:3px; }
img { max-width:100%; }
.store-banner { max-width:1440px; margin:16px auto; padding:16px 20px; }
.store-banner button { margin-left:12px; background:transparent; border:1px solid currentColor; padding:6px 14px; }
.store-error { color:#7d3315; background:#fbf1ec; border:1px solid #b4471f; padding:12px; font-size:14px; line-height:1.5; }
.cart-notice { position:fixed; z-index:90; bottom:18px; left:50%; transform:translateX(-50%); max-width:calc(100% - 24px); width:max-content; padding:12px 18px; color:#f7f5f0; background:#14140f; font-size:14px; pointer-events:none; box-shadow:0 3px 12px #14140f33; }
.consent-row { display:flex; align-items:flex-start; gap:10px; font-size:12px; line-height:1.5; margin-top:10px; cursor:pointer; }
.consent-row input { width:20px; height:20px; flex:0 0 20px; margin:2px 0; accent-color:#468d44; }
.checkout-panel input { min-width:0; width:100%; }
.checkout-panel .consent-row input { width:20px; }
.order-confirmation { border:1px solid #14140f; background:#fffdf7; padding:28px; margin-bottom:24px; line-height:1.6; }
.order-confirmation-title { font-family:'Archivo Narrow',sans-serif; font-weight:700; font-size:30px; text-transform:uppercase; }
.order-confirmation button { border:1px solid #14140f; background:oklch(.72 .19 145); padding:10px 18px; font-weight:600; }
.assistant-overlay { overscroll-behavior:contain; }
.assistant-overlay [style*="overflow: auto"], .assistant-page [style*="overflow: auto"] { overscroll-behavior:contain; }
.assistant-overlay [style*="max-width: 80%"] { max-width:88% !important; min-width:0; }
.assistant-overlay [style*="line-height: 1.6"],.assistant-page [style*="line-height: 1.6"] { white-space:pre-line; }
@media(max-width:760px) {
  .store-header > div { padding:0 12px !important; }
  .store-header > div > div:first-child { flex:1 1 auto; padding-right:12px !important; min-height:60px; }
  .store-header > div > div:nth-child(2) { order:4; flex:1 0 100% !important; border:0 !important; border-top:1px solid #d8d4c8 !important; padding:0 !important; min-height:50px !important; }
  .store-header nav { padding:0 12px !important; gap:12px !important; }
  .store-header nav span { display:flex; align-items:center; min-height:44px; }
  .store-header > div > button { min-height:60px; padding:0 14px !important; }
  .store-hero { grid-template-columns:minmax(0,1fr) !important; }
  .store-hero > div:first-child { padding:32px 20px !important; }
  .store-hero > div:last-child { border-left:0 !important; border-top:1px solid #14140f; }
  .store-hero h1 { font-size:clamp(46px,10vw,72px) !important; }
  #grid-anchor > aside { flex-basis:100% !important; border-right:0 !important; border-bottom:1px solid #14140f; padding:20px !important; display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px 16px; }
  #grid-anchor > aside > div:first-child, #grid-anchor > aside > button { grid-column:1/-1; }
  #grid-anchor > aside > div { margin-bottom:8px !important; }
  #grid-anchor > div { padding:24px 16px 48px !important; }
  .sort-controls { flex-wrap:wrap; }
  .sort-controls > span { flex:1 0 100%; }
  .product-grid { grid-template-columns:repeat(auto-fill,minmax(min(268px,100%),1fr)) !important; }
  .assistant-overlay { padding:8px !important; height:100dvh; }
  .assistant-overlay > div { max-height:100% !important; }
  .assistant-overlay > div > div:first-child, .assistant-page > div > div:first-child { padding:12px !important; gap:8px !important; flex-wrap:wrap; }
  .assistant-overlay [style*="overflow: auto"], .assistant-page [style*="overflow: auto"] { padding:16px 12px !important; }
  .assistant-overlay [style*="max-width: 80%"], .assistant-page [style*="max-width: min(88%"] { max-width:100% !important; }
  .assistant-overlay > div > div:last-child, .assistant-page > div > div:last-child { padding:12px !important; }
  .assistant-overlay input,.assistant-page input, .checkout-panel input { font-size:16px !important; }
  .assistant-overlay input + button { padding:0 12px !important; }
  .assistant-overlay [style*="align-items: stretch"] > button,.assistant-page [style*="align-items: stretch"] > button { padding:0 12px !important; }
  .assistant-page { padding:0 !important; min-height:100dvh !important; }
  .assistant-page > div { max-height:100dvh !important; min-height:100dvh; }
  [style*="grid-template-columns: repeat(auto-fit, minmax(340px"] { grid-template-columns:minmax(0,1fr) !important; }
  [style*="grid-template-columns: repeat(auto-fit, minmax(360px"] { grid-template-columns:minmax(0,1fr) !important; }
}
@media(max-width:420px) {
  .store-header nav { order:3; flex:1 0 100%; min-height:44px; border-top:1px solid #d8d4c8; justify-content:space-between; padding:0 4px !important; }
  .store-header > div > button { border-right:0; }
  .store-hero h1 { font-size:46px !important; }
  .store-hero > div:first-child { padding:28px 16px !important; }
  #grid-anchor > aside { padding:16px !important; }
  .product-grid article { padding:14px !important; }
  .checkout-panel > div { padding:16px !important; }
  .checkout-panel [style*="display: flex; gap: 8px"] { flex-wrap:wrap; }
  .checkout-panel [style*="display: flex; gap: 8px"] button { flex:1 1 100%; }
  [style*="grid-template-columns: repeat(auto-fit, minmax(280px"] { grid-template-columns:minmax(0,1fr) !important; }
  .assistant-overlay [style*="flex: 0 0 88px"] { flex-basis:72px !important; }
}
@media(prefers-reduced-motion:reduce) { html { scroll-behavior:auto; } }
@media(max-width:760px) {
  button { min-width:44px; }
  .product-detail-copy { width:100%; min-width:0; }
  .product-detail-copy > div { flex-wrap:wrap; }
  .product-detail-copy td { overflow-wrap:anywhere; }
  .assistant-overlay > div > div:last-child > div:last-child > button { padding:0 12px !important; }
  footer [role=button] { display:flex; align-items:center; min-height:44px; }
}
/* Hardware wizard: part of the transcript's scroll area, never a fixed panel. */
.hardware-wizard { flex-shrink:0; width:100%; min-width:0; border:1px solid #14140f; background:#fffdf7; }
.hardware-heading { display:flex; align-items:center; flex-wrap:wrap; gap:0 12px; padding:0 14px; border-bottom:1px solid #d8d4c8; }
.hardware-toggle { display:flex; flex:1 1 260px; align-items:center; justify-content:space-between; gap:10px; min-height:52px; padding:8px 0; text-align:left; border:0; color:#14140f; background:transparent; cursor:pointer; }
.hardware-toggle > span:first-child { font-family:'Archivo Narrow',sans-serif; font-size:23px; font-weight:700; text-transform:uppercase; }
.hardware-step-label { font-family:'DM Mono',monospace; font-size:11px; color:#6f6c60; }
.hardware-content { padding:18px; }
.hardware-content h3 { margin:0 0 12px; font-family:'Archivo Narrow',sans-serif; font-size:24px; font-weight:700; line-height:1.15; text-transform:uppercase; }
.hardware-progress { display:flex; gap:5px; margin-bottom:18px; }
.hardware-progress span { height:3px; flex:1; background:#d8d4c8; }
.hardware-progress .is-active { background:oklch(.72 .19 145); }
.hardware-options { display:grid; gap:7px; }
.hardware-three { grid-template-columns:repeat(3,minmax(0,1fr)); }
.hardware-choice,.hardware-secondary,.hardware-primary { min-height:44px; padding:9px 12px; border:1px solid #14140f; border-radius:0; font-family:inherit; font-size:13px; line-height:1.3; cursor:pointer; color:#14140f; }
.hardware-choice { background:#f7f5f0; border-color:#d8d4c8; }
.hardware-choice.is-selected,.hardware-primary { background:oklch(.72 .19 145); border-color:#14140f; font-weight:600; }
.hardware-secondary { background:transparent; }
.hardware-text-link { min-height:44px; padding:7px 0; border:0; background:transparent; font-family:inherit; color:#46443c; font-size:12px; line-height:1.35; cursor:pointer; text-decoration:underline; text-underline-offset:3px; }
.hardware-hint { margin:10px 0 14px; color:#6f6c60; font-size:12px; line-height:1.5; }
.hardware-privacy { font-size:11px; margin-bottom:0; }
.hardware-gpu-actions { display:flex; flex-wrap:wrap; align-items:center; gap:8px 14px; }
.hardware-gpu-confirm { border-left:3px solid oklch(.72 .19 145); background:#f0f1e8; margin:12px 0; padding:12px; }
.hardware-gpu-confirm p { margin:0 0 10px; font-size:14px; line-height:1.5; }
.hardware-confirmed { color:#385934; font-size:12px; line-height:1.5; margin:10px 0; }
.hardware-field { display:grid; min-width:0; gap:6px; margin-top:14px; }
.hardware-field > span { color:#6f6c60; font-family:'DM Mono',monospace; font-size:10.5px; line-height:1.45; }
.hardware-field input,.hardware-field select { width:100%; min-width:0; max-width:100%; min-height:44px; border:1px solid #d8d4c8; background:#f7f5f0; color:#14140f; border-radius:0; padding:9px 10px; font-family:inherit; font-size:14px; }
.hardware-fields { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:0 14px; }
.hardware-footer { display:flex; align-items:center; justify-content:space-between; gap:8px; border-top:1px solid #d8d4c8; padding-top:14px; margin-top:18px; }
.hardware-footer .hardware-primary { margin-left:auto; }
.hardware-error { margin:12px 0 0; color:#7d3315; background:#fbf1ec; border:1px solid #b4471f; padding:10px; font-size:13px; line-height:1.5; }
.hardware-edit-result { width:fit-content; text-align:left; font-size:12px; }
@media(max-width:540px) {
  .hardware-content { padding:14px 12px; }
  .hardware-heading { padding:0 12px; }
  .hardware-toggle { flex-basis:100%; }
  .hardware-heading > .hardware-text-link { margin-top:-5px; }
  .hardware-choice { padding:8px 5px; font-size:12px; }
  .hardware-fields { grid-template-columns:minmax(0,1fr); }
  .hardware-field input,.hardware-field select { font-size:16px; }
  .hardware-footer { flex-wrap:wrap; }
  .hardware-footer .hardware-primary { padding:9px 12px; }
}
.hardware-help { margin-top:12px; color:#46443c; font-size:12px; line-height:1.5; }
.hardware-help summary { min-height:44px; padding:12px 0; cursor:pointer; text-decoration:underline; text-underline-offset:3px; }
.hardware-help p { margin:0 0 10px; }
.hardware-result-notes { font-size:12px; line-height:1.5; color:#46443c; }
.hardware-result-notes summary { min-height:44px; padding:10px 0; cursor:pointer; }
.hardware-result-notes p { padding:0 12px; border-left:2px solid #d8d4c8; margin:8px 0; }
@media(max-width:760px) {
  .assistant-overlay > div > div.assistant-header:first-child { flex-wrap:nowrap !important; align-items:center !important; gap:10px !important; }
  .assistant-overlay .assistant-header > div:first-child { flex:1 1 auto; min-width:0; gap:10px !important; }
  .assistant-overlay .assistant-header > div:first-child > span { flex-shrink:0; }
  .assistant-overlay .assistant-header > div:first-child > div { min-width:0; }
  .assistant-overlay .assistant-header > div:first-child > div > div:last-child { font-size:20px !important; }
  .assistant-overlay .assistant-header > button { flex:0 0 44px; width:44px !important; height:44px !important; }
  .assistant-overlay > div > div.assistant-composer:last-child,.assistant-page > div > div.assistant-composer:last-child { padding:8px 12px !important; }
  .assistant-overlay .assistant-suggestions,.assistant-page .assistant-suggestions { flex-wrap:nowrap !important; overflow-x:auto; scrollbar-width:thin; margin-bottom:6px !important; padding-bottom:1px; }
  .assistant-suggestions > button { flex:0 0 auto; white-space:nowrap; min-height:44px; }
  .assistant-composer .assistant-chat-input { height:44px !important; }
  .assistant-composer > div:not(.assistant-suggestions) > button { height:46px !important; padding:0 12px !important; }
  .assistant-page .assistant-composer-note { display:none; }
}
