/* Wall shelf configurator — the bits that are wall-shelf-only, plus the
 * standalone page chrome.
 *
 * Everything shared with the shelf and the bench (tokens, cards, segmented
 * pills, sliders, value boxes, price, CTA, trust badges, orbit hint,
 * responsive behaviour) lives in ../base.css, which the shells link — and
 * widget.js injects — ahead of this file. The few rules here that must beat it
 * are written `.unfn-cfg.unfn-wall-shelf …`, so the cascade never depends on
 * load order.
 *
 * Sections: 1) the widget's own drawing, 2) the standalone page around it
 * (store header, marketing bands) — the storefront supplies its own chrome, so
 * section 2 only ever renders on unfnshedapps.com/configurator/wall-shelf/ and
 * the Access-gated internal copy. Every section-2 rule is scoped to
 * `body.wall-shelf-standalone`, which both of those shells carry and no
 * Shopify page does.
 */

/* =========================================================================
   1. The wall shelf's 2D measured drawing
   ========================================================================= */

/* The drawing is inset from the card so its dimension labels have room; the
   3D canvas fills its surface edge to edge. */
.unfn-cfg.unfn-wall-shelf #wall-shelf-view2d { padding: 10px; display: grid; grid-template-rows: minmax(0, 1fr); }
.unfn-cfg.unfn-wall-shelf #wall-shelf-drawing { width: 100%; height: 100%; min-height: 0; }
/* Plywood tones, shared with the 3D materials (--wood-*) so the unit looks
   like the same object in either view. Strokes stay hairline at any zoom. */
.unfn-cfg.unfn-wall-shelf .drawing-part { fill: var(--wood-part); stroke: var(--wood-line); stroke-width: 0.28; vector-effect: non-scaling-stroke; }
.unfn-cfg.unfn-wall-shelf .drawing-top { fill: var(--wood-top); }
.unfn-cfg.unfn-wall-shelf .drawing-measurements { pointer-events: none; }
.unfn-cfg.unfn-wall-shelf .drawing-dim { stroke: rgba(21, 19, 15, 0.5); stroke-width: 0.26; vector-effect: non-scaling-stroke; }
/* The wall the unit hangs on, in the side view: a heavy line with lighter
   drafting hatch behind it. Weighted above the part outlines so it reads as
   structure rather than another board. */
.unfn-cfg.unfn-wall-shelf .drawing-wall { stroke: rgba(21, 19, 15, 0.72); stroke-width: 0.9; vector-effect: non-scaling-stroke; }
.unfn-cfg.unfn-wall-shelf .drawing-hatch { stroke: rgba(21, 19, 15, 0.32); stroke-width: 0.26; vector-effect: non-scaling-stroke; }


/* =========================================================================
   2. Standalone page chrome (unfnshedapps.com/configurator/wall-shelf/)
   ========================================================================= */

body.wall-shelf-standalone { --ws-page: #fff; --ws-ink: #15130f; --ws-muted: rgba(21, 19, 15, 0.62); --ws-faint: rgba(21, 19, 15, 0.42); --ws-line: rgba(21, 19, 15, 0.1); --ws-accent: #f25a38; --ws-shadow: 0 1px 2px rgba(21, 19, 15, 0.04), 0 12px 32px rgba(21, 19, 15, 0.07); }

body.wall-shelf-standalone, body.wall-shelf-standalone *, body.wall-shelf-standalone *::before, body.wall-shelf-standalone *::after { box-sizing: border-box; }
html:has(body.wall-shelf-standalone) { scroll-behavior: smooth; }
body.wall-shelf-standalone { color-scheme: light; margin: 0; background: var(--ws-page); color: var(--ws-ink); font-family: "Instrument Sans", system-ui, -apple-system, sans-serif; font-size: 16px; line-height: 1.45; -webkit-font-smoothing: antialiased; }

body.wall-shelf-standalone .skip-link { position: fixed; z-index: 100; top: 8px; left: 8px; padding: 10px 14px; border-radius: 8px; background: var(--ws-ink); color: #fff; transform: translateY(-150%); }
body.wall-shelf-standalone .skip-link:focus { transform: translateY(0); }

body.wall-shelf-standalone .store-header { border-bottom: 1px solid var(--ws-line); background: #fff; }
body.wall-shelf-standalone .store-header__main { width: min(1320px, calc(100% - 48px)); min-height: 88px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
body.wall-shelf-standalone .store-logo { display: inline-flex; align-items: center; min-height: 44px; }
body.wall-shelf-standalone .store-logo img { width: 154px; height: auto; display: block; }
body.wall-shelf-standalone .store-actions { display: flex; align-items: center; gap: 8px; }
body.wall-shelf-standalone .store-actions a { position: relative; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 50%; color: var(--ws-ink); transition: background-color 150ms ease-out, scale 150ms ease-out; }
body.wall-shelf-standalone .store-actions a:hover { background: rgba(21, 19, 15, 0.05); }
body.wall-shelf-standalone .store-actions a:active { scale: 0.96; }
body.wall-shelf-standalone .store-actions svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
body.wall-shelf-standalone .cart-count { position: absolute; top: 3px; right: 1px; min-width: 17px; height: 17px; padding: 0 4px; display: grid; place-items: center; border-radius: 999px; background: var(--ws-accent); color: #fff; font-size: 10px; font-weight: 700; }
body.wall-shelf-standalone .quick-nav { width: min(1320px, calc(100% - 48px)); min-height: 52px; margin: 0 auto; display: flex; align-items: center; justify-content: center; gap: clamp(24px, 3.6vw, 54px); overflow-x: auto; scrollbar-width: none; }
body.wall-shelf-standalone .quick-nav::-webkit-scrollbar { display: none; }
body.wall-shelf-standalone .quick-nav a { flex: none; color: var(--ws-ink); font-size: 13px; text-decoration: none; transition: color 150ms ease-out; }
body.wall-shelf-standalone .quick-nav a:hover { color: var(--ws-accent); }

body.wall-shelf-standalone main { width: 100%; }
body.wall-shelf-standalone .wall-shelf-configurator-embed, body.wall-shelf-standalone .page-band { width: min(1160px, calc(100% - 48px)); margin-inline: auto; }
body.wall-shelf-standalone .wall-shelf-configurator-embed { padding: 40px 0 86px; }
body.wall-shelf-standalone .wall-shelf-configurator-embed > h1 { margin: 0; font-family: "Instrument Serif", Georgia, serif; font-size: clamp(43px, 7vw, 67px); font-weight: 400; letter-spacing: -0.015em; line-height: 1.02; text-align: center; }
body.wall-shelf-standalone .wall-shelf-configurator-embed > h1 em, body.wall-shelf-standalone .wall-shelf-story h2 em, body.wall-shelf-standalone .bottom-cta h2 em { color: var(--ws-accent); font-weight: 400; }
body.wall-shelf-standalone .wall-shelf-configurator-embed__lede { margin: 6px auto 26px; color: var(--ws-muted); font-size: 17px; text-align: center; }

body.wall-shelf-standalone .page-band { padding: 82px 0; }
body.wall-shelf-standalone .section-kicker { margin: 0 0 12px; color: #9a8f83; font-size: 12px; font-weight: 650; letter-spacing: 0.14em; text-transform: uppercase; }
body.wall-shelf-standalone .page-band h2 { margin: 0 0 26px; font-family: "Instrument Serif", Georgia, serif; font-size: clamp(32px, 4.5vw, 42px); font-weight: 400; letter-spacing: -0.01em; line-height: 1.08; }
body.wall-shelf-standalone .wall-shelf-details { border-top: 1px solid var(--ws-line); }
body.wall-shelf-standalone .detail-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; }
body.wall-shelf-standalone .detail-grid article { min-height: 175px; padding: 24px; border-radius: 20px; background: #fff; box-shadow: var(--ws-shadow), inset 0 0 0 1px var(--ws-line); }
body.wall-shelf-standalone .detail-grid h3 { margin: 0 0 10px; display: flex; align-items: center; gap: 10px; font-family: "Instrument Serif", Georgia, serif; font-size: 23px; font-weight: 400; }
body.wall-shelf-standalone .detail-grid h3::before { content: ""; width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--ws-accent); }
body.wall-shelf-standalone .detail-grid p, body.wall-shelf-standalone .wall-shelf-story p, body.wall-shelf-standalone .studio-band p, body.wall-shelf-standalone .wall-shelf-faq p, body.wall-shelf-standalone .bottom-cta p { color: var(--ws-muted); }
body.wall-shelf-standalone .detail-grid p { margin: 0; max-width: 52ch; font-size: 15px; line-height: 1.55; }
body.wall-shelf-standalone .wall-shelf-story { max-width: 948px; }
body.wall-shelf-standalone .story-lead { max-width: 58ch; margin: 0 0 34px; font-size: 19px; line-height: 1.65; }
body.wall-shelf-standalone .story-grid { display: grid; grid-template-columns: 1.2fr 0.8fr; gap: 34px; align-items: center; }
body.wall-shelf-standalone .story-visual { min-height: 390px; display: grid; place-items: center; border-radius: 20px; overflow: hidden; background: linear-gradient(135deg, #f3eee7, #e2d8ca); box-shadow: inset 0 0 0 1px var(--ws-line); color: #9a8f83; font-size: 12px; font-weight: 650; letter-spacing: 0.12em; text-transform: uppercase; }
body.wall-shelf-standalone .story-copy h3 { margin: 0 0 14px; font-family: "Instrument Serif", Georgia, serif; font-size: 28px; font-weight: 400; line-height: 1.08; }
body.wall-shelf-standalone .story-copy p { margin: 0 0 16px; line-height: 1.65; }
body.wall-shelf-standalone .studio-band { min-height: 470px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; overflow: hidden; border-radius: 20px; background: #f5f2ed; box-shadow: var(--ws-shadow), inset 0 0 0 1px var(--ws-line); }
body.wall-shelf-standalone .studio-copy { padding: clamp(36px, 6vw, 72px); display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
body.wall-shelf-standalone .studio-copy h2 { margin-bottom: 14px; }
body.wall-shelf-standalone .studio-copy p { max-width: 40ch; margin: 0 0 26px; line-height: 1.65; }
body.wall-shelf-standalone .studio-copy a, body.wall-shelf-standalone .bottom-cta a { min-height: 44px; padding: 12px 22px; display: inline-flex; align-items: center; justify-content: center; border-radius: 999px; background: var(--ws-ink); color: #fff; font-size: 14px; font-weight: 650; text-decoration: none; transition: background-color 150ms ease-out, scale 150ms ease-out; }
body.wall-shelf-standalone .studio-copy a:hover, body.wall-shelf-standalone .bottom-cta a:hover { background: var(--ws-accent); }
body.wall-shelf-standalone .studio-copy a:active, body.wall-shelf-standalone .bottom-cta a:active { scale: 0.96; }
body.wall-shelf-standalone .studio-image { min-height: 470px; background: linear-gradient(140deg, rgba(21,19,15,0.06), rgba(21,19,15,0.18)), url("https://cdn.shopify.com/s/files/1/0808/8063/2114/files/IMG_3192_2.jpg") center/cover; }
body.wall-shelf-standalone .wall-shelf-faq { max-width: 948px; }
body.wall-shelf-standalone .wall-shelf-faq details { margin-bottom: 12px; padding: 0 22px; border-radius: 20px; background: #fff; box-shadow: var(--ws-shadow), inset 0 0 0 1px var(--ws-line); }
body.wall-shelf-standalone .wall-shelf-faq summary { min-height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 18px; cursor: pointer; list-style: none; font-weight: 620; }
body.wall-shelf-standalone .wall-shelf-faq summary::-webkit-details-marker { display: none; }
body.wall-shelf-standalone .wall-shelf-faq summary::after { content: "+"; color: var(--ws-faint); font-size: 24px; font-weight: 400; transition: rotate 180ms ease-out; }
body.wall-shelf-standalone .wall-shelf-faq details[open] summary::after { rotate: 45deg; }
body.wall-shelf-standalone .wall-shelf-faq details p { margin: -4px 0 0; padding: 0 0 22px; max-width: 70ch; line-height: 1.65; }
body.wall-shelf-standalone .wall-shelf-faq a { color: inherit; text-underline-offset: 3px; }
body.wall-shelf-standalone .wall-shelf-faq summary:focus-visible { outline: 2px solid var(--ws-accent); outline-offset: 3px; }
body.wall-shelf-standalone .bottom-cta { max-width: 948px; padding-bottom: 110px; text-align: center; }
body.wall-shelf-standalone .bottom-cta h2 { margin-bottom: 12px; }
body.wall-shelf-standalone .bottom-cta p { margin: 0 0 24px; }

@media (max-width: 900px) {
  body.wall-shelf-standalone .story-grid { grid-template-columns: 1fr; }
  body.wall-shelf-standalone .story-visual { min-height: 340px; }
}

@media (max-width: 700px) {
  body.wall-shelf-standalone .store-header__main { width: calc(100% - 32px); min-height: 70px; }
  body.wall-shelf-standalone .store-logo img { width: 130px; }
  body.wall-shelf-standalone .quick-nav { width: 100%; min-height: 46px; padding: 0 16px; justify-content: flex-start; gap: 24px; }
  body.wall-shelf-standalone .wall-shelf-configurator-embed, body.wall-shelf-standalone .page-band { width: min(100% - 32px, 1160px); }
  body.wall-shelf-standalone .wall-shelf-configurator-embed { padding: 28px 0 62px; }
  body.wall-shelf-standalone .wall-shelf-configurator-embed__lede { margin-bottom: 16px; font-size: 15px; }
  .unfn-cfg.unfn-wall-shelf #wall-shelf-view2d { padding: 4px; }
  body.wall-shelf-standalone .detail-grid { grid-template-columns: 1fr; }
  body.wall-shelf-standalone .detail-grid article { min-height: 0; padding: 20px; }
  body.wall-shelf-standalone .page-band { padding: 62px 0; }
  body.wall-shelf-standalone .studio-band { width: calc(100% - 32px); grid-template-columns: 1fr; }
  body.wall-shelf-standalone .studio-image { min-height: 300px; grid-row: 1; }
  body.wall-shelf-standalone .studio-copy { padding: 34px 26px 40px; }
}

@media (max-width: 430px) {
  body.wall-shelf-standalone .store-actions { gap: 0; }
  body.wall-shelf-standalone .store-actions a { width: 40px; height: 40px; }
}

@media (prefers-reduced-motion: reduce) {
  html:has(body.wall-shelf-standalone) { scroll-behavior: auto; }
  body.wall-shelf-standalone .store-header *, body.wall-shelf-standalone .page-band * { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
