/* PAUL SAGOO: THE BUILD (2 Oct 2026). Styles for js/build.js, product page only.
   On a wide screen the build sits at the foot of the stage and the photograph
   makes room for it; on a phone it rides, sticky, under the step row. */

/* ---- the stage makes room (desktop only; --bld-h is the deck's real height) ---- */
@media (min-width: 901px) {
  .pdp__stage.bld-on .stage-photo .stage-photo__img { padding-bottom: calc(var(--buybar-h, 88px) + 96px + var(--bld-h, 0px)); }
  .pdp__stage.bld-on .stage-photo__caption { bottom: calc(var(--buybar-h, 88px) + 42px + var(--bld-h, 0px)); }
  .pdp__stage.bld-on .stage-photo__dots { bottom: calc(var(--buybar-h, 88px) + 16px + var(--bld-h, 0px)); }
  .pdp__stage.bld-on .stage-zoom { bottom: calc(var(--buybar-h, 88px) + 16px + var(--bld-h, 0px)); }
}
.bld-flick .stage-photo__track { animation: bldFlick .75s ease-out; }
@keyframes bldFlick {
  0% { opacity: .15; filter: saturate(1.9) brightness(1.12); }
  28% { opacity: 1; }
  42% { opacity: .55; }
  60% { opacity: 1; filter: saturate(1.25); }
  100% { opacity: 1; filter: none; }
}

/* ---- the block ---- */
.bld { color: #12110e; font-family: var(--font-body); box-sizing: border-box; }
.bld *, .bld *::before, .bld *::after { box-sizing: border-box; }
.bld p { margin: 0; }
.bld--deck, .bld--band { grid-template-columns: minmax(0, 1fr); }
.bld__card, .bld__strip { min-width: 0; }
.bld--deck { position: absolute; left: 24px; right: 24px; bottom: calc(var(--buybar-h, 88px) + 14px); z-index: 7;
  background: rgba(250, 248, 243, 0.96); border: 1px solid rgba(18, 17, 14, 0.12);
  padding: 14px 20px 12px 20px; display: grid; gap: 10px; cursor: default; }
/* Paul's peeking portrait (js/paulnudge.js) rests on the left edge of the screen: leave him room */
@media (min-width: 901px) and (hover: hover) { .bld--deck { padding-left: 92px; } }
.bld__card { display: grid; grid-template-columns: minmax(150px, 230px) minmax(0, 1fr); gap: 20px; align-items: center; }
.bld__fig { min-width: 0; }
.bld-svg { width: 100%; height: auto; display: block; overflow: visible; filter: drop-shadow(0 6px 10px rgba(18, 17, 14, 0.12)); }
.bld__txt { min-width: 0; }
.bld .bld__eye { font-size:var(--fs-caps); font-weight: 500; line-height: 1.4; letter-spacing: 0.2em; text-transform: uppercase; color: var(--gold-ink, #7c6536); }
.bld .bld__cap { font-family: var(--font-display); font-weight: 500; font-size:var(--fs-lead); line-height: 1.3; color: #12110e; margin-top: 4px; }
.bld .bld__small { font-size:var(--fs-small); line-height: 1.4; color: #5f5c56; margin-top: 4px; }
.bld__extra:empty { display: none; }
.bld__extra { margin-top: 8px; }

/* the strip: the parts of this pair */
.bld__strip { border-top: 1px solid rgba(18, 17, 14, 0.12); padding-top: 10px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; }
.bld .bld__chips { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; min-width: 0; }
.bld .bld__chips:empty::before { content: 'Your pair builds here, part by part.'; font-size:var(--fs-small); line-height: 30px; color: #5f5c56; }
.bld__li { display: block; margin: 0; padding: 0; }
.bld .bld-chip { display: inline-flex; align-items: center; gap: 7px; min-height: 30px; min-width: 0; margin: 0; padding: 0 12px 0 7px;
  border: 1px solid rgba(18, 17, 14, 0.16); border-radius: 999px; background: #fff; color: #12110e;
  font: 400 0.74rem/1 var(--font-body); letter-spacing: 0.01em; text-transform: none; white-space: nowrap; cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease; }
@media (hover: hover) { .bld .bld-chip:hover { border-color: rgba(18, 17, 14, 0.5); } }
.bld .bld-chip:focus-visible { outline: 2px solid #12110e; outline-offset: 2px; }
.bld-chip__sw { flex: 0 0 16px; width: 16px; height: 16px; border-radius: 50%; border: 1px solid rgba(18, 17, 14, 0.2); }
.bld-chip__lens { flex: 0 0 16px; width: 16px; height: 16px; fill: rgba(220, 232, 238, 0.6); stroke: #12110e; stroke-width: 1.1; }
.bld .bld-chip--num { padding: 0 13px; border-color: var(--gold, #c9a24a); font-family: var(--font-display); font-size:var(--fs-body); font-weight: 500; letter-spacing: 0.02em; }
.bld .bld__note { font-size:var(--fs-caps); line-height: 1.4; color: #5f5c56; }

/* the review: the whole pair, named */
.bld.is-review .bld__eye { font-family: var(--font-display); font-size:var(--fs-body); letter-spacing: 0; text-transform: none; color: #12110e; }
.bld.is-review .bld__cap { font-family: var(--font-body); font-size:var(--fs-small); line-height: 1.5; color: #2b2924; }

/* ---- the drawing ---- */
.bld-svg .bld-ff { fill: var(--bld-frame, #111); stroke: rgba(18, 17, 14, 0.3); stroke-width: 1px; vector-effect: non-scaling-stroke; transition: fill .6s ease; }
.bld-svg .bld-ol { fill: none; stroke: rgba(18, 17, 14, 0.3); }
.bld-svg .bld-fs { stroke: var(--bld-frame, #111); transition: stroke .6s ease; }
.bld-svg.is-fade stop { transition: stop-color .7s ease, stop-opacity 1.3s ease; }
.bld-svg .bld-view { opacity: 0; transition: opacity .5s ease; }
.bld-svg.is-view .bld-view { opacity: 1; }
.bld-svg .bld-sharp, .bld-svg .bld-softv { opacity: 0.36; }
.bld-svg .bld-softv { display: none; }
.bld-svg.is-vari .bld-softv { display: inline; }
.bld-svg .bld-wash { opacity: 0; transition: opacity .5s ease; }
.bld-svg.is-view.is-vari .bld-wash { opacity: 0.5; }
.bld-svg .bld-bif { opacity: 0; transition: opacity .4s ease; }
.bld-svg.is-bif .bld-bif { opacity: 1; }
.bld-svg .bld-bif g { opacity: 0; transition: opacity .4s ease; }
.bld-svg.is-view .bld-bif g { opacity: 1; }
.bld-svg .bld-glare { opacity: 0; transition: opacity 1.3s ease; }
.bld-svg.is-glare .bld-glare { opacity: 0.9; }
.bld-svg.is-glare.is-pol .bld-glare { opacity: 0.04; }
.bld-svg.is-sweeping .bld-glare { opacity: 0; transition-duration: .2s; }
.bld-svg .bld-blue { opacity: 0; transition: opacity .6s ease; }
.bld-svg.is-blue .bld-blue { opacity: 0.55; }
.bld-svg.is-glint .bld-blue { animation: bldGlint 1.4s ease-out; }
@keyframes bldGlint { 0% { opacity: 0; } 30% { opacity: 1; } 55% { opacity: .35; } 75% { opacity: .9; } 100% { opacity: .55; } }

/* thickness: the edge of the lens, getting thinner */
.bld__edge { display: flex; align-items: center; gap: 12px; }
.bld__edge svg { flex: 0 0 88px; width: 88px; height: auto; display: block; }
.bld__edge .bld__small { margin-top: 0; }
.bld-edgep { fill: rgba(176, 205, 218, 0.55); stroke: #12110e; stroke-opacity: .65; stroke-width: 1; transition: d .7s cubic-bezier(.2, .7, .2, 1); }

/* Transitions: indoors and out */
.bld__sun { display: inline-flex; border: 1px solid rgba(18, 17, 14, 0.22); }
.bld .bld__sunb { min-height: 34px; min-width: 0; padding: 0 14px; margin: 0; border: 0; border-radius: 0; background: transparent; color: #12110e; cursor: pointer;
  font: 500 0.68rem/1 var(--font-body); letter-spacing: 0.14em; text-transform: uppercase; transition: background-color .25s ease, color .25s ease; }
.bld .bld__sunb[aria-pressed="true"] { background: #12110e; color: #f4f1ea; }
.bld .bld__sunb:focus-visible { outline: 2px solid #12110e; outline-offset: 2px; }

/* the number, on the temple */
.bld-temple { width: 100%; max-width: 300px; height: auto; display: block; overflow: visible; }
.bld-temple .bld-ff { fill: var(--bld-frame, #111); }
.bld-eng { fill: #c9a24a; font-family: var(--font-body); font-size:var(--fs-caps); font-weight: 600; letter-spacing: 1.6px;
  paint-order: stroke; stroke: rgba(18, 17, 14, 0.35); stroke-width: 0.6px; }
.bld-eng.is-dark { fill: #5a4512; stroke: rgba(255, 250, 235, 0.5); }
.bld-laser { fill: #fff3c4; filter: drop-shadow(0 0 3px #ffcf4a) drop-shadow(0 0 6px #ffcf4a); }

/* ---- motion: a settle, a step, a reveal ---- */
.bld__li.is-new { animation: bldSettle .65s cubic-bezier(.2, .8, .25, 1.15) both; }
@keyframes bldSettle { 0% { opacity: 0; transform: translateY(8px) scale(.88); } 60% { opacity: 1; transform: translateY(-2px) scale(1.03); } 100% { opacity: 1; transform: none; } }
.bld .bld-chip.is-upd { animation: bldUpd .5s ease-out; }
@keyframes bldUpd { 0% { box-shadow: 0 0 0 0 rgba(201, 162, 74, .0); border-color: var(--gold, #c9a24a); } 40% { box-shadow: 0 0 0 4px rgba(201, 162, 74, .28); } 100% { box-shadow: 0 0 0 0 rgba(201, 162, 74, 0); } }
.bld__card.is-step .bld__txt { animation: bldIn .55s ease-out; }
@keyframes bldIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.bld__card.is-flick .bld__fig { animation: bldFig .75s ease-out; }
@keyframes bldFig { 0% { opacity: .3; } 30% { opacity: 1; } 45% { opacity: .6; } 100% { opacity: 1; } }
.bld.is-reveal .bld__fig { animation: bldReveal 2.1s cubic-bezier(.2, .7, .2, 1); }
@keyframes bldReveal { 0% { opacity: 0; transform: scale(.92) translateY(6px); filter: blur(3px); } 60% { opacity: 1; filter: none; } 100% { transform: none; } }
.bld.is-reveal .bld__li { animation: bldSettle .6s cubic-bezier(.2, .8, .25, 1.15) both; }
.bld.is-reveal .bld__li:nth-child(2) { animation-delay: .12s; }
.bld.is-reveal .bld__li:nth-child(3) { animation-delay: .24s; }
.bld.is-reveal .bld__li:nth-child(4) { animation-delay: .36s; }
.bld.is-reveal .bld__li:nth-child(5) { animation-delay: .48s; }
.bld.is-reveal .bld__li:nth-child(6) { animation-delay: .6s; }
.bld.is-reveal .bld__li:nth-child(7) { animation-delay: .72s; }

/* ---- on a phone: compact, sticky under the step row ---- */
.bld--band { position: sticky; top: calc(var(--nav-h, 64px) + var(--bld-progh, 52px)); z-index: 19;
  margin: 0 calc(var(--pad) * -1); padding: 8px var(--pad) 8px; background: var(--paper, #f4f1ea);
  border-bottom: 1px solid rgba(18, 17, 14, 0.14); display: grid; gap: 6px; }
.bld--band .bld__card { grid-template-columns: 132px minmax(0, 1fr); gap: 12px; }
/* on a phone the review list below says it all; keep the band short */
.bld--band.is-review .bld__cap { display: none; }
.bld--band .bld-svg { filter: none; }
.bld--band .bld__eye { font-size:var(--fs-caps); letter-spacing: 0.16em; }
.bld--band .bld__cap { font-size:var(--fs-body); line-height: 1.25; margin-top: 2px; }
.bld--band .bld__extra { margin-top: 5px; }
.bld--band .bld__strip { display: block; padding-top: 6px; }
.bld--band .bld__chips { flex-wrap: nowrap; overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: none; padding-bottom: 1px; }
.bld--band .bld__chips::-webkit-scrollbar { display: none; }
.bld--band .bld-chip { min-height: 28px; font-size:var(--fs-small); }
.bld--band .bld-chip--num { font-size:var(--fs-body); }
.bld--band .bld__note { margin-top: 4px; font-size:var(--fs-caps); }
.bld--band .bld__sunb { min-height: 32px; padding: 0 12px; }
.bld--band .bld__edge svg { flex-basis: 64px; width: 64px; }
.bld--band .bld-temple { max-width: 220px; }
.bld--band.is-review .bld__eye { font-size:var(--fs-body); }
.bld--band.is-review .bld__cap { font-size:var(--fs-small); }

@media (prefers-reduced-motion: reduce) {
  .bld, .bld *, .bld-svg *, .bld-flick .stage-photo__track { animation: none !important; transition: none !important; }
}
