:root{color-scheme:dark;--ink:#100e0c;--light:#f5efe4;--gold:#f3c974;--muted:#c5baaa;--edge:#524536;font-family:"DM Sans",system-ui,sans-serif;scroll-behavior:smooth}
*{box-sizing:border-box}
body{margin:0;background:#0c0b09;color:var(--light);line-height:1.55}
a{color:inherit;text-decoration:none}
button,input,select,textarea{font:inherit}
button,.button{cursor:pointer;background:var(--gold);color:#1d1406;border:1px solid transparent;border-radius:3px;padding:.75rem 1rem;font-weight:750;display:inline-flex;align-items:center;gap:.7rem;justify-content:center}
:is(a,button,input,select,textarea,summary):focus-visible{outline:3px solid #b26f1e;outline-offset:4px}
.outline{background:transparent;color:inherit;border-color:var(--edge)}
.wrap{width:min(1120px,calc(100% - 3rem));margin-inline:auto}
.top{min-height:76px;display:flex;align-items:center;justify-content:space-between;gap:1rem;flex-wrap:wrap;padding-block:12px}
header{border-bottom:1px solid #332a20}
.brand,nav,.actions,.filters{display:flex;align-items:center;gap:1rem;flex-wrap:wrap}
.brand{gap:.45rem;font-weight:850;letter-spacing:.1em}
.brand img{object-fit:contain}
.brand span,.eyebrow,em{color:var(--gold)}
nav{gap:clamp(.6rem,2vw,1.7rem)}
nav a:hover,.text-link:hover{text-decoration:underline}
nav a[aria-current="page"]{color:var(--gold);text-decoration:underline;text-underline-offset:.3em}
.hero{min-height:560px;display:grid;grid-template-columns:1.05fr .95fr;align-items:center;gap:2rem;padding-block:3rem}
.hero-art{background:radial-gradient(ellipse,#533b1d,#0c0b09 70%);display:grid;place-items:center}
.hero-art img{width:min(100%,310px);height:auto;display:block}
.eyebrow{text-transform:uppercase;font-weight:800;letter-spacing:.13em;font-size:.75rem}
h1,h2{font-family:"Instrument Serif",Georgia,serif;font-weight:400;line-height:.99;margin:.25em 0}
h1{font-size:clamp(5rem,12vw,10rem);letter-spacing:-.075em}
h2{font-size:clamp(2.5rem,5vw,4rem);letter-spacing:-.045em}
.section h1{font-size:clamp(2.5rem,5vw,4rem);letter-spacing:-.045em}
h3{font-size:1.15rem;margin:0}
p{margin:.6em 0 1em}
.intro{font-size:1.14rem;color:var(--muted);max-width:32rem}
.actions{margin-top:1.5rem}
.text-link{border-bottom:1px solid currentColor}
.paper{background:#f3eddf;color:#221912;color-scheme:light}
.paper .eyebrow{color:#795018}
.section{padding-block:clamp(3rem,7vw,5.5rem)}
.filters{margin:1.4rem 0;gap:.55rem}
.filters button[aria-pressed="true"]{background:#2b2116;color:#fff}
.products{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:1rem}
.product{border:1px solid #d7cbba;background:#faf5eb;display:flex;flex-direction:column}
.product-art{aspect-ratio:1.35;background:#d8c8ab;display:grid;place-items:center;overflow:hidden;color:#695034;font-family:Georgia,serif;font-style:italic;font-size:1.5rem;text-align:center}
.product-art img{width:100%;height:100%;object-fit:cover}
.product-body{padding:1rem;display:grid;gap:.55rem;flex:1;align-content:start}
.product-body p{margin:0;color:#584c3e}
.product-body button{justify-self:start;margin-top:.35rem}
.catalogue{padding-block:clamp(2rem,5vw,4.5rem)}
.catalogue-heading,.catalogue-tools{display:flex;align-items:end;justify-content:space-between;gap:1rem;flex-wrap:wrap}
.catalogue h1{font-size:clamp(3rem,6vw,5.7rem);letter-spacing:-.05em}
.catalogue-heading p{margin-bottom:0}
.catalogue-search{min-width:min(100%,16rem)}
.catalogue-search input{background:#fffaf1;color:#221912;border-color:#b8ab98}
.catalogue-tools{align-items:center;border-block:1px solid #d6cab7;margin:1.8rem 0 1.25rem}
.catalogue-tools .filters{margin:.7rem 0}
.catalogue-tools button{border-color:#b6a994;border-radius:999px;padding:.45rem .85rem}
.catalogue-tools p{margin:0 0 .5rem;color:#584c3e;font-size:.9rem}
.catalogue .products{grid-template-columns:repeat(auto-fill,minmax(min(100%,225px),1fr));gap:1.15rem}
.catalogue .product{overflow:hidden;border-radius:9px;background:#fffcf6}
.product-photo{display:block;width:100%;aspect-ratio:1;object-fit:cover;background:#eae0d1}
.catalogue .product-body{grid-template-rows:auto 1fr auto auto;align-content:stretch}
.product-reference{font-size:.82rem;color:#594a36;text-decoration:underline;text-underline-offset:.15em}
.catalogue .product-body .eyebrow{color:#795018;font-size:.65rem}
.catalogue .product-body button{width:100%;min-height:44px}
.catalogue-note{margin-top:2rem;color:#584c3e;font-size:.9rem}
.quote{display:grid;grid-template-columns:1fr 1fr;gap:clamp(1.5rem,7vw,6rem)}
.quote p,.muted{color:var(--muted)}
form{display:grid;gap:1rem}
label{display:grid;gap:.35rem;font-weight:650}
input,select,textarea{width:100%;background:#1d1915;color:var(--light);border:1px solid var(--edge);padding:.65rem;border-radius:3px}
textarea{resize:vertical}
.faq{max-width:780px}
details{padding:1rem 0;border-bottom:1px solid #cabda9}
summary{font-weight:700;cursor:pointer}
dialog{width:min(94vw,520px);max-height:90dvh;background:#14110e;color:var(--light);border:1px solid var(--edge);border-radius:6px;padding:1.3rem}
dialog::backdrop{background:#000b}
#product-dialog{width:min(96vw,1040px)}
.studio-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:1.25rem}
.studio-preview{display:grid;align-content:center;justify-items:center;background:#2a231b;border:1px solid var(--edge);padding:.8rem;text-align:center}
.studio-preview p{margin:.35rem 0;color:var(--muted)}
@media(max-width:720px){.studio-layout{grid-template-columns:1fr}.studio-preview{grid-row:1}}
.editor{min-width:0;margin:0;border:1px solid var(--edge);padding:1rem}
.editor legend{padding-inline:.5rem}
.studio-actions,#art-properties,#art-text-fields,#art-format{grid-column:1/-1}
.studio-actions{display:flex;flex-wrap:wrap;align-items:center;gap:.5rem}
.studio-actions label{flex:1;min-width:min(100%,14rem)}
.studio-actions button{padding:.5rem .65rem}
.editor-advanced{grid-column:1/-1;border-color:var(--edge);padding:.65rem 0}
.editor-advanced summary{margin-bottom:.4rem}
.editor-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:.8rem}
.editor input[type=color]{min-height:2.6rem}
.product-preview{position:relative;width:min(100%,340px);aspect-ratio:1;overflow:hidden;background:#f6ece0;border-radius:5px;isolation:isolate}
.product-preview img{display:block;width:100%;height:100%;object-fit:fill}
.product-preview canvas{position:absolute;left:var(--art-x,50%);top:var(--art-y,50%);width:var(--art-w,45%);height:var(--art-h,40%);transform:translate(-50%,-50%);mix-blend-mode:multiply;cursor:grab;touch-action:none}
.product-preview canvas:active{cursor:grabbing}
.product-preview.is-wrap-preview canvas{cursor:default;touch-action:auto}
.product-preview.show-boundary canvas{outline:1px dashed #805c35;outline-offset:0}
.product-preview.is-round-preview canvas{border-radius:50%}
.product-preview.is-wrap-preview.show-boundary canvas{outline:none}
.product-preview canvas:focus-visible{outline:2px dashed #8a5922;outline-offset:0}
.product-preview.is-flat{display:grid;place-items:center;background:#fff}
.product-preview.is-flat img{visibility:hidden}
.product-preview.is-flat canvas{position:static;grid-area:1/1;width:auto;height:auto;max-width:90%;max-height:90%;transform:none}
.product-preview.is-flat img{grid-area:1/1}
.preview-flat{display:flex;align-items:center;gap:.45rem;margin-top:.65rem;font-size:.9rem}
.preview-flat input{width:auto}
.editor p{font-size:.9rem}
button:disabled{opacity:.6;cursor:default}
@media(max-width:480px){.editor-grid{grid-template-columns:1fr}}
.dialog-head{display:flex;align-items:start;justify-content:space-between;gap:1rem}
.dialog-head h2{font-size:2.45rem;margin:0}
.line{border-bottom:1px solid var(--edge);padding:1rem 0;overflow-wrap:anywhere}
.line-controls{display:flex;align-items:end;gap:.8rem}
.line-controls label{width:7rem}
#cart-quote{margin-top:1rem}
#quote-result textarea{margin-bottom:.5rem}
.sr-only{position:absolute;width:1px;height:1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap}
[hidden]{display:none!important}

/* Workspace, tools and order controls use separate rows so the cart action stays visible. */
#product-dialog{box-sizing:border-box;width:min(1240px,96vw);height:min(840px,94dvh);max-height:none;padding:0;border-radius:14px;overflow:hidden;background:#fbf8f1;color:#241e17;color-scheme:light}
#product-form{height:100%;grid-template-rows:auto minmax(0,1fr) auto;gap:0}
.studio-header,.studio-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:12px clamp(12px,2vw,24px);background:#171411;color:#fff9ec;margin:0}
.studio-header h2{margin:0;font-size:clamp(1.25rem,2.4vw,2rem);line-height:1.15}
.studio-kicker{margin:0 0 .25rem;color:#f2c678;font-size:.75rem}
#product-form .editor{border:0;padding:0;min-height:0;overflow:auto}
#product-form .studio-layout{display:grid;grid-template-columns:minmax(0,1.7fr) minmax(255px,1fr);gap:0;min-height:100%}
#product-form .studio-preview{position:sticky;top:0;display:grid;align-content:start;justify-items:stretch;gap:14px;align-self:start;padding:clamp(12px,2vw,24px);background:#eeeae2;border:0;text-align:left}
.studio-view-tools,.studio-switch,.studio-import,.studio-order,.studio-panel-heading{display:flex;align-items:center;gap:8px}
.studio-view-tools,.studio-panel-heading{justify-content:space-between;flex-wrap:wrap}
.studio-switch{padding:3px;border:1px solid #d6cdbf;border-radius:8px;background:#fff;gap:2px}
.studio-switch button{padding:.45rem .65rem;background:transparent;color:#554639;border:0;border-radius:5px}
.studio-switch button[aria-pressed=true]{background:#211c16;color:#fff}
.studio-stage{position:relative;display:grid;place-items:center;min-height:clamp(240px,44vh,450px);background:#e2dbcf;border:1px solid #d2c9ba;border-radius:10px;padding:16px}
.studio-stage .product-preview{width:min(100%,360px,44vh)}
.studio-stage .product-preview.is-flat{width:min(100%,640px);aspect-ratio:auto;overflow:visible;background:transparent;border-radius:0}
.studio-stage .product-preview.is-flat img{display:none}
.studio-stage .product-preview.is-flat canvas{display:block;width:auto;height:auto;max-width:100%;max-height:34vh;background:var(--surface-color,#fff);box-shadow:0 4px 18px #382b221f}
.studio-empty{position:absolute;pointer-events:none;font-size:.9rem;color:#6b5c4d;text-align:center;padding:4px 12px}
.studio-caption p,#product-form .studio-preview p{color:#554639;font-size:.8rem;margin:0}
.studio-panel{padding:16px;display:grid;align-content:start;gap:12px;border-left:1px solid #ded5c7;min-width:0}
.studio-panel h3{margin:0}
.studio-panel .color-note{margin:0;font-size:.78rem;color:#625447}
.studio-panel-heading span{font-size:.8rem;color:#665647}
.studio-panel :is(input,textarea,select){background:#fff;color:#231e18;border-color:#c9bfaf;min-width:0}
.studio-panel label{font-size:.85rem;min-width:0}
.studio-import>*{flex:1}
.studio-upload{position:relative;cursor:pointer}
.studio-upload:focus-within{outline:2px solid #89601d;outline-offset:2px}
.studio-layers{display:grid;gap:10px}
.studio-details{border:1px solid #ddd3c5;border-radius:7px;padding:8px}
.studio-details[open] summary{margin-bottom:8px}
.studio-details summary{font-size:.85rem}
.studio-footer p{font-size:.78rem;color:#f5ddab;margin:0}
.studio-download{background:transparent;color:inherit;padding:.25rem 0;text-decoration:underline;border:0}
.studio-order input{width:4.7rem;background:#30291f;color:#fff}
.studio-order label{font-size:.76rem}
.studio-order button{white-space:nowrap}
@media(max-width:720px){
  #product-dialog{height:96dvh}
  #product-form .studio-layout{grid-template-columns:1fr}
  #product-form .studio-preview{position:static;grid-row:auto}
  .studio-stage{min-height:175px}
  .studio-stage .product-preview{max-width:235px}
  .studio-stage .product-preview.is-flat{max-width:100%}
  .studio-panel{border-left:0}
  .studio-footer{flex-wrap:wrap}
  .studio-order{margin-left:auto}
}
@media(max-width:750px){.hero{min-height:0;grid-template-columns:1fr;gap:1rem}.hero-art img{width:min(70%,320px)}.products{grid-template-columns:repeat(2,minmax(0,1fr))}.quote{grid-template-columns:1fr}.wrap{width:calc(100% - 2rem)}}
@media(max-width:440px){.products{grid-template-columns:1fr}.top{justify-content:center}.intro{font-size:1rem}}
@media(prefers-reduced-motion:reduce){:root{scroll-behavior:auto}}

@media(prefers-reduced-motion:no-preference){
  .hero > :first-child{animation:appear .65s ease-out both}
  .hero-art{animation:appear .75s .12s ease-out both}
  .hero-art img{animation:luna-float 2.1s .8s ease-in-out 2}
  .catalogue-heading,.quote{animation:appear .4s ease-out both}
  @media(hover:hover){
    .product,.actions .button{transition:transform .2s ease,box-shadow .2s ease}
    .product:hover,.actions .button:hover{transform:translateY(-3px);box-shadow:0 8px 20px #32241624}
  }
}
@keyframes appear{
  from{opacity:0;transform:translateY(12px)}
  to{opacity:1;transform:translateY(0)}
}
@keyframes luna-float{
  0%,100%{transform:translateY(0)}
  50%{transform:translateY(-7px)}
}
