/* Pine green + cranberry on cool snow white. Layout: one designer section (preview left, steps right), short supporting sections below. */
:root {
  --snow: #F6F3EC;
  --card: #FFFFFF;
  --ink: #17201A;
  --muted: #5B675F;
  --line: #DCE3DA;
  --pine: #1F3B2D;
  --pine-2: #2D5A42;
  --berry: #B3263E;
  --gold: #C9A24A;
  --display: "Playfair Display", Georgia, serif;
  --body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { margin: 0; }
body { background: var(--snow); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
h1, h2 { font-family: var(--display); font-weight: 700; text-wrap: balance; letter-spacing: -0.01em; margin: 0; }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

.festive { position: relative; overflow: hidden; color: #F4EEDF;
  background: radial-gradient(120% 90% at 50% 0%, #2B6B47 0%, #17402A 55%, #0F2C1D 100%); }
.snow { position: absolute; inset: 0; pointer-events: none; opacity: .8;
  background-image:
    radial-gradient(2px 2px at 20px 30px, #fff 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 90px 120px, #fff 50%, transparent 51%),
    radial-gradient(2.5px 2.5px at 150px 60px, rgba(255,255,255,.9) 50%, transparent 51%),
    radial-gradient(1.5px 1.5px at 60px 170px, #fff 50%, transparent 51%),
    radial-gradient(2px 2px at 180px 190px, rgba(255,255,255,.8) 50%, transparent 51%);
  background-size: 200px 200px; animation: snowfall 14s linear infinite; }
@keyframes snowfall { from { background-position: 0 0; } to { background-position: 40px 400px; } }
.promo { position: relative; background: var(--berry); color: #FBE9EC; font-size: 14px; display: flex; flex-wrap: wrap; gap: 6px 10px; justify-content: center; align-items: center; padding: 8px 16px; text-align: center; }
.promo strong { color: #fff; }
.promo-sep { opacity: .5; }
.promo-clock { background: rgba(0,0,0,.18); border-radius: 999px; padding: 2px 10px; font-variant-numeric: tabular-nums; font-weight: 600; color: #FFE7A8; }

.topbar { position: relative; display: flex; justify-content: space-between; align-items: center; padding: 16px clamp(16px, 4vw, 40px) 8px; max-width: 1200px; margin: 0 auto; }
.brand { font-family: var(--display); font-size: 26px; font-weight: 700; color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.brand-mark { flex: none; filter: drop-shadow(0 2px 4px rgba(0,0,0,.3)); }
.cart-btn { display: inline-flex; align-items: center; gap: 8px; background: rgba(255,255,255,.1); color: #fff; border: 1px solid rgba(255,255,255,.35); border-radius: 999px; padding: 8px 14px; cursor: pointer; font-weight: 600; }
.cart-btn:hover { background: rgba(255,255,255,.18); }
.cart-count { background: var(--berry); color: #fff; border-radius: 999px; min-width: 22px; height: 22px; display: inline-grid; place-items: center; font-size: 12px; padding: 0 6px; }

/* string of lights */
.lights { position: relative; height: 34px; margin: 0 auto; max-width: 1400px;
  background:
    radial-gradient(circle at 14px 20px, #FF5A5A 0 5px, rgba(255,90,90,.45) 6px, transparent 11px) 0 0 / 112px 34px repeat-x,
    radial-gradient(circle at 42px 24px, #FFD45C 0 5px, rgba(255,212,92,.45) 6px, transparent 11px) 0 0 / 112px 34px repeat-x,
    radial-gradient(circle at 70px 20px, #6EE7A0 0 5px, rgba(110,231,160,.45) 6px, transparent 11px) 0 0 / 112px 34px repeat-x,
    radial-gradient(circle at 98px 24px, #7DB7FF 0 5px, rgba(125,183,255,.45) 6px, transparent 11px) 0 0 / 112px 34px repeat-x,
    linear-gradient(transparent 11px, rgba(8,22,14,.85) 11px 13px, transparent 13px) 0 0 / 100% 34px no-repeat;
  animation: twinkle 2.4s ease-in-out infinite alternate; }
@keyframes twinkle { from { filter: brightness(1) saturate(1); } to { filter: brightness(1.35) saturate(1.2); } }

.hero { position: relative; max-width: 1200px; margin: 0 auto; padding: 18px clamp(16px, 4vw, 40px) 56px; display: block; }
.hero-text { display: flex; flex-direction: column; align-items: flex-start; gap: 14px; }
.hero-art { margin: 0; display: flex; justify-content: center; }
.hero-art canvas { width: 100%; max-width: 360px; height: auto; border-radius: 20px; box-shadow: 0 18px 40px rgba(0,0,0,.35); background: #fff; }
@media (max-width: 760px) { .hero { grid-template-columns: 1fr; } .hero-art canvas { max-width: 240px; } }
.hero h1 { font-size: clamp(36px, 6vw, 64px); line-height: 1.04; color: #fff; }
.hero p { color: #E4EDE5; font-size: 18px; margin: 0; max-width: 56ch; }
.trust { display: inline-flex; align-items: center; gap: 10px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.25); border-radius: 999px; padding: 6px 14px 6px 10px; font-size: 14px; color: #F4EEDF; }
.trust strong { color: #fff; }
.trust a { color: #FFE7A8; }
.usa { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; color: #E4EDE5; }
.usa svg { border-radius: 2px; box-shadow: 0 0 0 1px rgba(255,255,255,.3); flex: none; }
.usa strong { color: #fff; }
.ship-note { margin: -2px 0 0; text-align: center; font-size: 13px; color: var(--muted); }
.stars { display: inline-flex; gap: 2px; }
.stars svg { width: 16px; height: 16px; fill: #F2C14E; }
.cta { display: inline-block; background: var(--gold); color: #1B1405; font-weight: 700; text-decoration: none; padding: 14px 26px; border-radius: 999px; font-size: 16px; box-shadow: 0 6px 20px rgba(0,0,0,.25); }
.cta:hover { background: #D8B25C; }

main { max-width: 1200px; margin: -28px auto 0; padding: 0 clamp(16px, 4vw, 40px); position: relative; }

/* Designer */
.designer { padding-top: 0; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: clamp(20px, 3vw, 40px); align-items: start; padding-bottom: 48px; }
.preview-col { position: sticky; top: 12px; }
.preview-wrap { position: relative; background: var(--card); border-radius: 20px; overflow: hidden; border: 1px solid var(--line); }
#preview { display: block; width: 100%; height: auto; touch-action: none; cursor: grab; }
#preview.dragging { cursor: grabbing; }
.preview-status { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); background: rgba(23,32,26,.86); color: #fff; padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; white-space: nowrap; }
.drag-hint { position: absolute; left: 50%; top: 14px; transform: translateX(-50%); display: inline-flex; align-items: center; gap: 8px; background: rgba(23,32,26,.88); color: #fff; padding: 8px 14px; border-radius: 999px; font-size: 14px; font-weight: 600; white-space: nowrap; pointer-events: none; animation: nudge 1.6s ease-in-out infinite; }
@keyframes nudge { 0%,100% { transform: translateX(-50%); } 50% { transform: translateX(calc(-50% + 6px)); } }
.view-toggle { display: flex; justify-content: center; gap: 4px; margin: 10px auto 0; background: #E7ECE5; border-radius: 999px; padding: 4px; width: max-content; max-width: 100%; }
.view-toggle button { border: 0; background: transparent; border-radius: 999px; padding: 8px 16px; font-weight: 600; font-size: 14px; cursor: pointer; color: var(--muted); }
.view-toggle button[aria-checked="true"] { background: #fff; color: var(--pine); box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.frame-tools { display: flex; align-items: center; gap: 10px; justify-content: center; margin-top: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; }
.zbtn { width: 36px; height: 36px; border-radius: 50%; border: 1px solid #C9D3CB; background: #fff; font-size: 20px; line-height: 1; cursor: pointer; flex: none; }
.zbtn:hover { border-color: var(--pine-2); }
.zoom-wrap { display: flex; align-items: center; gap: 8px; flex: 1; max-width: 260px; }
.zoom-label { font-size: 13px; font-weight: 700; color: var(--muted); }
.zoom-wrap input { flex: 1; accent-color: var(--pine); }
.preview-hint { color: var(--muted); font-size: 13px; text-align: center; margin: 8px 0 0; }

.steps { display: flex; flex-direction: column; gap: 14px; }
.step { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px 18px; margin: 0; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.step legend { float: left; width: 100%; padding: 0; font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 10px; }
.step legend + * { clear: both; }
.num { width: 24px; height: 24px; border-radius: 50%; background: var(--pine); color: #fff; display: inline-grid; place-items: center; font-size: 13px; }

.drop { display: flex; flex-direction: column; align-items: center; gap: 2px; border: 2px dashed #B9C7BC; border-radius: 14px; padding: 18px; cursor: pointer; text-align: center; background: #FAFBF8; transition: border-color .15s, background .15s; }
.drop:hover, .drop.over { border-color: var(--pine-2); background: #F1F6F1; }
.drop input { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.drop:focus-within { outline: 3px solid var(--gold); outline-offset: 2px; }
.drop-title { font-weight: 700; color: var(--pine); }
.drop-sub { font-size: 13px; color: var(--muted); }
.photo-tools { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 18px; }
.toggle { display: inline-flex; align-items: center; gap: 8px; font-weight: 600; cursor: pointer; }
.toggle input { width: 18px; height: 18px; accent-color: var(--pine); }
.slider { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.slider input { accent-color: var(--pine); width: 140px; }
.link-btn { background: none; border: 0; color: var(--pine-2); text-decoration: underline; cursor: pointer; padding: 0; font-size: 14px; }

.field { display: flex; flex-direction: column; gap: 4px; font-size: 14px; font-weight: 600; }
.field em { font-weight: 400; color: var(--muted); font-style: normal; }
.field input, .field select { border: 1px solid #C9D3CB; border-radius: 10px; padding: 11px 12px; font-size: 16px; font-weight: 400; background: #fff; width: 100%; }
.field input:focus, .field select:focus { border-color: var(--pine-2); outline: none; box-shadow: 0 0 0 3px rgba(45,90,66,.18); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { border: 1px solid #C9D3CB; background: #fff; border-radius: 999px; padding: 8px 14px; cursor: pointer; font-size: 14px; font-weight: 600; display: inline-flex; align-items: center; gap: 6px; transition: border-color .12s, background .12s; }
.chip:hover { border-color: var(--pine-2); }
.chip[aria-checked="true"] { background: var(--pine); border-color: var(--pine); color: #fff; }
.chip .delta { font-weight: 500; opacity: .75; font-size: 12px; }
.swatches .chip { padding: 6px 12px 6px 6px; }
.sw { width: 24px; height: 24px; border-radius: 50%; border: 1px solid rgba(0,0,0,.12); }
.sw-snow { background: #FBFAF6; }
.sw-festive { background: #A3192F; }
.sw-evergreen { background: #1F4732; }
.sw-memorial { background: linear-gradient(#2E3A5C, #8391B8); }
.sublabel { font-size: 13px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; margin-bottom: -4px; }
.size-row { display: flex; align-items: center; gap: 12px; font-size: 14px; font-weight: 600; color: var(--muted); }
.size-row input { flex: 1; max-width: 260px; accent-color: var(--pine); }
.blurb { margin: -4px 0 0; color: var(--muted); font-size: 14px; }

.qty-row { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; }
.qty { display: inline-flex; align-items: center; border: 1px solid #C9D3CB; border-radius: 999px; overflow: hidden; background: #fff; }
.qty button { width: 42px; height: 42px; border: 0; background: none; font-size: 20px; cursor: pointer; }
.qty button:hover { background: #F1F6F1; }
.qty output { min-width: 32px; text-align: center; font-weight: 700; font-variant-numeric: tabular-nums; }
.qty-note { margin: 0; font-size: 13px; color: var(--muted); flex: 1 1 200px; }

.buy { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; display: flex; flex-direction: column; gap: 12px; position: sticky; bottom: 0; box-shadow: 0 -6px 20px rgba(23,32,26,.06); }
.price-line { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.price { font-size: 28px; font-weight: 700; font-variant-numeric: tabular-nums; }
.price-note { color: var(--berry); font-weight: 600; font-size: 14px; }
.primary, .secondary { border-radius: 999px; padding: 14px 20px; font-weight: 700; font-size: 16px; cursor: pointer; border: 2px solid var(--berry); width: 100%; }
.primary { background: var(--berry); color: #fff; }
.primary:hover { background: #9C1F35; border-color: #9C1F35; }
.primary:disabled { opacity: .6; cursor: progress; }
.secondary { background: #fff; color: var(--berry); }
.secondary:hover { background: #FBEFF1; }
.form-error { color: var(--berry); margin: 0; font-size: 14px; font-weight: 600; }

/* Supporting sections */
section.showcase, section.deals, section.how, section.memorial, section.faq { padding: 40px 0; border-top: 1px solid var(--line); }
section h2 { font-size: clamp(26px, 3.2vw, 34px); color: var(--pine); }
section.showcase h2::before, section.deals h2::before, section.how h2::before, section.faq h2::before { content: ""; display: inline-block; width: .7em; height: .7em; margin-right: .35em; background: var(--gold); clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); vertical-align: .05em; }
section > p { color: var(--muted); max-width: 62ch; margin: 8px 0 0; }
.deal-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin-top: 20px; }
.deal { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px; display: flex; flex-direction: column; gap: 4px; }
.deal-pop { border: 2px solid var(--berry); }
.tag-pop { position: absolute; top: -11px; left: 14px; background: var(--berry); color: #fff; font-size: 12px; font-weight: 700; padding: 2px 10px; border-radius: 999px; }
.deal-qty { color: var(--muted); font-weight: 600; font-size: 14px; }
.deal-price { font-size: 30px; font-weight: 700; font-variant-numeric: tabular-nums; color: var(--ink); }
.deal-save { color: var(--berry); font-weight: 600; font-size: 14px; }
.show-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; margin-top: 20px; }
.show-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; padding: 0; cursor: pointer; text-align: left; display: flex; flex-direction: column; }
.show-card:hover { border-color: var(--pine-2); }
.show-card canvas { width: 100%; height: auto; display: block; background: #fff; }
.show-card span { padding: 8px 12px 12px; font-size: 14px; font-weight: 600; }
.show-card small { display: block; color: var(--muted); font-weight: 500; }
.sample-tag { position: absolute; top: 12px; left: 12px; background: rgba(255,255,255,.92); color: var(--pine); font-size: 12px; font-weight: 700; padding: 4px 10px; border-radius: 999px; border: 1px solid var(--line); }
.how ol { margin: 16px 0 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; counter-reset: s; }
.how li { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 18px; counter-increment: s; }
.how li::before { content: counter(s); display: inline-grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--gold); color: #fff; font-weight: 700; margin-bottom: 8px; }
.how li strong { display: block; }
.memorial > div { background: linear-gradient(135deg, #2E3A5C, #66749C); color: #EEF1F9; border-radius: 20px; padding: clamp(22px, 4vw, 40px); display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.memorial h2 { color: #fff; }
.memorial p { margin: 0; max-width: 60ch; }
.memorial .secondary { width: auto; border-color: #fff; color: #2E3A5C; }
.faq details { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; margin-top: 10px; max-width: 760px; }
.faq summary { font-weight: 700; cursor: pointer; }
.faq details p { margin: 8px 0 0; color: var(--muted); }
.foot { background: #12301F; color: #CFE0D4 !important; text-align: center; color: var(--muted); font-size: 14px; padding: 28px 16px 40px; border-top: 1px solid var(--line); }

/* Drawer */
.drawer-backdrop { position: fixed; inset: 0; background: rgba(15,22,17,.45); z-index: 40; }
.drawer { position: fixed; top: 0; right: 0; height: 100%; width: min(420px, 100%); background: var(--snow); z-index: 41; display: flex; flex-direction: column; transform: translateX(100%); transition: transform .25s ease; box-shadow: -10px 0 30px rgba(0,0,0,.15); }
.drawer.open { transform: none; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { font-size: 24px; color: var(--pine); }
.icon-btn { background: none; border: 0; font-size: 20px; cursor: pointer; width: 40px; height: 40px; border-radius: 50%; }
.icon-btn:hover { background: #E8EEE7; }
.drawer-body { flex: 1; overflow-y: auto; padding: 12px 18px; display: flex; flex-direction: column; gap: 10px; }
.empty { color: var(--muted); text-align: center; padding: 30px 0; }
.citem { display: grid; grid-template-columns: 72px minmax(0,1fr) auto; gap: 12px; align-items: center; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 10px; }
.citem img { width: 72px; height: 72px; object-fit: contain; border-radius: 10px; background: #EEF2EC; }
.citem-title { font-weight: 700; }
.citem-sub { font-size: 13px; color: var(--muted); }
.citem-qty { display: inline-flex; align-items: center; gap: 6px; margin-top: 4px; }
.citem-qty button { width: 28px; height: 28px; border-radius: 50%; border: 1px solid #C9D3CB; background: #fff; cursor: pointer; }
.citem-qty span { min-width: 18px; text-align: center; font-variant-numeric: tabular-nums; font-weight: 600; }
.citem-remove { background: none; border: 0; color: var(--muted); text-decoration: underline; cursor: pointer; font-size: 13px; align-self: start; }
.drawer-foot { border-top: 1px solid var(--line); padding: 14px 18px 18px; display: flex; flex-direction: column; gap: 8px; background: var(--card); }
.sum-row { display: flex; justify-content: space-between; font-size: 15px; font-variant-numeric: tabular-nums; }
.sum-row.total { font-weight: 700; font-size: 18px; }
#sumSaveRow { color: var(--berry); font-weight: 600; }
.upsell { margin: 2px 0 4px; font-size: 14px; color: var(--pine-2); font-weight: 600; }
.upsell:empty { display: none; }

@media (max-width: 600px) {
  .brand { font-size: 20px; }
  .cart-btn > span:not(.cart-count) { display: none; }
  .promo-sep { display: none; }
  .promo { font-size: 13px; }
}
.mini-preview { position: fixed; top: 12px; right: 12px; z-index: 30; width: 96px; padding: 0; border: 2px solid #fff; border-radius: 14px; overflow: hidden; background: #fff; box-shadow: 0 8px 24px rgba(0,0,0,.25); cursor: pointer; }
.mini-preview canvas { display: block; width: 100%; height: auto; }
@media (max-width: 900px) {
  .designer { grid-template-columns: 1fr; }
  .preview-col { position: static; }
  .preview-wrap { max-width: 460px; margin: 0 auto; }
  #preview { max-height: 56vh; width: auto; margin: 0 auto; }
  .buy { padding: 10px 14px; gap: 8px; }
  .buy .price { font-size: 22px; }
  .buy .primary { padding: 12px 18px; }
  .ship-note { display: none; }
  .deal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .how ol { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } .drag-hint, .snow, .lights { animation: none; } }
