/* ==========================================================================
   Hero v3 — Try It On Your Wall · Swipe Your Wall · Hang & Swing · Magic Particles
   Loaded on the front page only, when one of these styles is active.
   ========================================================================== */

.hx{position:relative;display:grid;grid-template-columns:minmax(0,41fr) minmax(0,59fr);align-items:stretch;background:var(--walnut);color:var(--canvas-white);min-height:min(84vh,820px);overflow:hidden;}
.hx-text{position:relative;z-index:3;align-self:center;padding:56px 40px 56px max(24px,calc((100vw - var(--maxw)) / 2 + 24px));}
.hx .label{color:var(--gold);}
.hx-h{font-family:var(--serif);font-weight:300;font-size:clamp(42px,4.7vw,70px);line-height:1.03;color:var(--canvas-white);margin:14px 0 16px;letter-spacing:-.005em;}
.hx-h em{font-style:italic;color:var(--gold);}
.hx-sub{color:rgba(245,239,228,.88);font-size:16.5px;line-height:1.6;max-width:450px;margin-bottom:24px;}
.hx-btns{display:flex;gap:10px;flex-wrap:wrap;align-items:center;}
.hx .btn{padding:15px 24px;font-size:11.5px;}
.hx .btn svg{width:17px;height:17px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round;}
.hx .btn-gold{background:var(--gold);color:var(--walnut);}
.hx .btn-gold:hover{background:#d8bb85;color:var(--walnut);}
.hx-ghost{border:1.5px solid rgba(245,239,228,.75);color:var(--canvas-white);background:transparent;}
.hx-ghost:hover{background:var(--canvas-white);color:var(--walnut);}
.hx-link{display:inline-block;margin-top:18px;color:var(--gold);font-size:14px;font-weight:500;text-decoration:underline;text-underline-offset:4px;}
.hx-stage{position:relative;min-height:520px;}
.hx-text > *{animation:hxIn .8s cubic-bezier(.2,.8,.2,1) both;}
.hx-text > :nth-child(2){animation-delay:.08s;}.hx-text > :nth-child(3){animation-delay:.16s;}.hx-text > :nth-child(4){animation-delay:.24s;}.hx-text > :nth-child(5){animation-delay:.32s;}
@keyframes hxIn{from{opacity:0;transform:translateY(18px);}}

/* ---------------------------------------------------------------- TRY IT ON YOUR WALL */
.hx-tryon{background:radial-gradient(ellipse at 75% 40%,#3b2a1c 0%,var(--walnut) 55%,#21170f 100%);}
.hx-cta{box-shadow:0 0 0 0 rgba(201,169,110,.6);animation:hxIn .8s .24s both,ctaPulse 2.6s ease-out 1.6s 3;}
@keyframes ctaPulse{0%{box-shadow:0 0 0 0 rgba(201,169,110,.55);}100%{box-shadow:0 0 0 20px rgba(201,169,110,0);}}
.hx-steps{list-style:none;display:flex;gap:18px;flex-wrap:wrap;margin-top:26px;padding:0;}
.hx-steps li{display:flex;align-items:center;gap:8px;font-size:13px;color:rgba(245,239,228,.88);}
.hx-steps b{width:24px;height:24px;border-radius:50%;border:1.5px solid var(--gold);color:var(--gold);font-size:12px;display:flex;align-items:center;justify-content:center;}
.to-demo{display:flex;align-items:center;justify-content:center;padding:40px 48px 40px 0;}
.to-demo-card{position:relative;width:min(600px,100%);aspect-ratio:1/1;border-radius:18px;overflow:hidden;box-shadow:0 40px 90px rgba(0,0,0,.55),0 0 0 1px rgba(201,169,110,.25);transform:rotate(1.2deg);}
.to-demo-room{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;}
.to-demo-set{position:absolute;left:21.1%;top:31.7%;width:57.1%;height:23%;display:flex;gap:2.27%;transform-origin:50% 50%;animation:demoSet 6.5s cubic-bezier(.45,.05,.25,1) infinite;}
.to-demo-set span{flex:1 1 0;height:100%;background:#1b1714;box-shadow:5px 10px 18px rgba(30,20,12,.42),1px 2px 4px rgba(30,20,12,.3);}
.to-demo-set img{display:block;width:100%;height:100%;object-fit:cover;}
@keyframes demoSet{
  0%{opacity:0;transform:translate(34%,70%) scale(.5) rotate(-7deg);}
  8%{opacity:1;transform:translate(34%,70%) scale(.5) rotate(-7deg);}
  44%{opacity:1;transform:translate(0,0) scale(1.05) rotate(0);}
  52%{transform:translate(0,0) scale(1) rotate(0);}
  90%{opacity:1;transform:translate(0,0) scale(1);}
  100%{opacity:0;transform:translate(0,-4%) scale(1);}
}
.to-demo-finger{position:absolute;left:62%;top:70%;width:46px;height:46px;color:#fff;filter:drop-shadow(0 4px 10px rgba(0,0,0,.45));animation:demoFinger 6.5s cubic-bezier(.45,.05,.25,1) infinite;pointer-events:none;}
.to-demo-finger svg{width:100%;height:100%;fill:rgba(255,255,255,.95);stroke:#2c1f14;stroke-width:1.1;stroke-linejoin:round;}
@keyframes demoFinger{
  0%{opacity:0;transform:translate(30%,60%) scale(1);}
  6%{opacity:1;transform:translate(30%,60%) scale(.88);}
  44%{opacity:1;transform:translate(-30%,-55%) scale(.88);}
  50%{opacity:1;transform:translate(-30%,-55%) scale(1);}
  60%,100%{opacity:0;transform:translate(-20%,-30%) scale(1);}
}
.to-demo-ring{position:absolute;left:50%;top:43%;width:62%;aspect-ratio:2.6/1;transform:translate(-50%,-50%);border:2px solid var(--gold);border-radius:12px;opacity:0;animation:demoRing 6.5s ease-out infinite;pointer-events:none;}
@keyframes demoRing{0%,46%{opacity:0;transform:translate(-50%,-50%) scale(.92);}52%{opacity:.9;}70%,100%{opacity:0;transform:translate(-50%,-50%) scale(1.12);}}
.to-demo-toast{position:absolute;left:50%;bottom:7%;transform:translate(-50%,10px);display:flex;align-items:center;gap:8px;white-space:nowrap;background:rgba(242,237,228,.96);color:var(--walnut);font-size:13px;font-weight:600;padding:10px 16px;border-radius:30px;box-shadow:0 12px 30px rgba(0,0,0,.3);opacity:0;animation:demoToast 6.5s ease infinite;max-width:92%;overflow:hidden;text-overflow:ellipsis;}
.to-demo-toast svg{width:16px;height:16px;flex-shrink:0;fill:none;stroke:#3f7a3a;stroke-width:2.6;}
@keyframes demoToast{0%,50%{opacity:0;transform:translate(-50%,10px);}56%,86%{opacity:1;transform:translate(-50%,0);}94%,100%{opacity:0;transform:translate(-50%,0);}}
.to-demo-badge{position:absolute;left:14px;top:14px;background:rgba(20,13,8,.72);color:#fff;font-size:11px;font-weight:600;letter-spacing:.12em;text-transform:uppercase;padding:7px 11px;border-radius:20px;-webkit-backdrop-filter:blur(6px);backdrop-filter:blur(6px);}

/* ---------------------------------------------------------------- SWIPE YOUR WALL */
.hx-swipe{background:radial-gradient(ellipse at 70% 45%,#3d2b1d 0%,var(--walnut) 58%,#1f150d 100%);}
.sp-stage{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:22px;padding:36px 20px;}
.sp-deck{position:relative;width:min(360px,82vw);aspect-ratio:3/4.15;touch-action:pan-y;user-select:none;-webkit-user-select:none;}
.sp-card{position:absolute;inset:0;border-radius:16px;background:linear-gradient(#f4eee3,#ece3d4);box-shadow:0 26px 60px rgba(0,0,0,.45),0 2px 0 rgba(255,255,255,.5) inset;display:flex;flex-direction:column;align-items:center;padding:7% 8% 0;will-change:transform;cursor:grab;transform-origin:50% 92%;}
.sp-card:active{cursor:grabbing;}
.sp-card .sp-art{flex:1 1 auto;min-height:0;display:flex;align-items:center;justify-content:center;width:100%;}
.sp-card .sp-art img{display:block;max-height:100%;max-width:100%;width:auto;height:auto;aspect-ratio:420/551;box-shadow:8px 16px 28px rgba(40,26,14,.38),1px 2px 5px rgba(40,26,14,.3);pointer-events:none;-webkit-user-drag:none;}
.sp-card .sp-meta{width:100%;text-align:center;padding:14px 0 18px;}
.sp-card .sp-name{display:block;font-family:var(--serif);font-size:23px;color:var(--walnut);line-height:1.15;}
.sp-card .sp-mood{display:block;margin-top:4px;font-size:10.5px;font-weight:700;letter-spacing:.14em;text-transform:uppercase;color:var(--gold-ink);}
.sp-stamp{position:absolute;top:22px;padding:6px 12px;border:3px solid;border-radius:6px;font-size:20px;font-weight:800;letter-spacing:.08em;opacity:0;pointer-events:none;background:rgba(244,238,227,.85);}
.sp-stamp.like{right:18px;color:#2e6b34;border-color:#2e6b34;transform:rotate(12deg);}
.sp-stamp.nope{left:18px;color:#8a2f22;border-color:#8a2f22;transform:rotate(-12deg);}
.sp-ctrls{display:flex;align-items:center;gap:18px;}
.sp-btn{display:flex;align-items:center;justify-content:center;border-radius:50%;background:#f4eee3;box-shadow:0 10px 24px rgba(0,0,0,.35);transition:transform .15s,background .2s;}
.sp-btn:hover{transform:scale(1.07);}
.sp-btn:active{transform:scale(.94);}
.sp-btn svg{fill:none;stroke-linecap:round;stroke-linejoin:round;}
.sp-nope{width:60px;height:60px;}
.sp-nope svg{width:24px;height:24px;stroke:#8a2f22;stroke-width:2.6;}
.sp-undo{width:44px;height:44px;background:rgba(244,238,227,.16);box-shadow:none;border:1.5px solid rgba(244,238,227,.45);}
.sp-undo svg{width:18px;height:18px;stroke:#f4eee3;stroke-width:2;}
.sp-like{width:70px;height:70px;background:var(--gold);}
.sp-like svg{width:30px;height:30px;fill:var(--walnut);stroke:none;}
.sp-tray{display:flex;align-items:center;gap:16px;margin:4px 0 6px;}
.sp-slots{display:flex;gap:10px;}
.sp-slot{width:52px;height:68px;border:1.5px dashed rgba(201,169,110,.7);border-radius:3px;display:flex;align-items:center;justify-content:center;color:var(--gold);font-size:15px;font-weight:600;overflow:hidden;transition:transform .3s cubic-bezier(.3,1.6,.5,1);}
.sp-slot.full{border:0;box-shadow:0 6px 14px rgba(0,0,0,.4);}
.sp-slot.full img{display:block;width:100%;height:100%;object-fit:cover;}
.sp-slot.pop{transform:scale(1.12);}
.sp-count{font-size:14px;color:rgba(245,239,228,.9);font-weight:500;}
.sp-done{position:relative;z-index:20;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;padding:8px 0;text-align:center;width:100%;}
.sp-stage.is-done .sp-deck,.sp-stage.is-done .sp-ctrls{display:none;}
.sp-done[hidden]{display:none;}
.sp-done > *{position:relative;z-index:1;}
.sp-done .label{color:var(--gold);font-size:13px;}
.sp-wall{position:relative;width:min(420px,86vw);aspect-ratio:1/1;border-radius:12px;overflow:hidden;box-shadow:0 24px 60px rgba(0,0,0,.5);}
.sp-wall > img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;}
.sp-wall-row{position:absolute;display:flex;}
.sp-wall-row span{flex:0 0 auto;background:#1b1714;box-shadow:4px 9px 16px rgba(30,20,12,.42);animation:hang .8s cubic-bezier(.25,1.4,.45,1) both;transform-origin:50% -30%;}
.sp-wall-row span:nth-child(2){animation-delay:.12s;}.sp-wall-row span:nth-child(3){animation-delay:.24s;}
.sp-wall-row img{display:block;width:100%;height:100%;object-fit:cover;}
.sp-sizes{justify-content:center;margin:2px 0 0;}
.sp-sizes .opt{background:#f4eee3;}
.sp-price{font-size:22px;font-weight:700;color:#fff;}
.sp-done .btn-gold{min-width:240px;}
.sp-done-links{display:flex;gap:18px;font-size:14px;}
.sp-done-links a,.sp-done-links button{color:var(--gold);text-decoration:underline;text-underline-offset:3px;font-weight:500;}
.sp-confetti{position:absolute;left:50%;top:50%;width:140%;height:140%;transform:translate(-50%,-50%);z-index:0 !important;pointer-events:none;}

/* ---------------------------------------------------------------- HANG & SWING */
.hx-swing{display:block;background:#e9e1d4;color:var(--ink);}
.sw-wall{position:relative;height:min(86vh,840px);min-height:600px;overflow:hidden;
  background:
    radial-gradient(ellipse 70% 60% at 22% 8%,rgba(255,247,232,.85) 0%,rgba(255,247,232,0) 60%),
    radial-gradient(ellipse at 50% 120%,rgba(60,40,22,.28) 0%,rgba(60,40,22,0) 55%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0.35 0 0 0 0 0.28 0 0 0 0 0.2 0 0 0 0.09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    linear-gradient(#efe8dc,#e4dbcc);
  touch-action:pan-y;}
.sw-light{position:absolute;inset:0;pointer-events:none;background:linear-gradient(115deg,rgba(255,255,255,0) 30%,rgba(255,250,238,.22) 45%,rgba(255,255,255,0) 60%);}
.sw-text{position:absolute;z-index:4;left:max(24px,calc((100vw - var(--maxw)) / 2 + 24px));top:clamp(28px,6vh,64px);max-width:540px;pointer-events:none;}
.hx-swing .label{color:var(--gold-ink);}
.hx-swing .hx-h{color:var(--walnut);font-size:clamp(40px,4.6vw,68px);}
.hx-swing .hx-h em{color:#7a5a32;}
.hx-swing .hx-sub{color:#4a3b2c;margin:0;font-size:15.5px;}
@media(hover:hover){.sw-hint-touch{display:none;}}
@media(hover:none){.sw-hint-mouse{display:none;}}
.sw-rack{position:absolute;inset:0;z-index:3;}
.sw-nail{position:absolute;width:12px;height:12px;margin:-6px 0 0 -6px;border-radius:50%;z-index:6;pointer-events:none;
  background:radial-gradient(circle at 35% 30%,#fff1c9 0,#d9b46a 30%,#9a7535 70%,#5e451c 100%);box-shadow:1px 2px 3px rgba(40,26,12,.45);}
.sw-item{position:absolute;left:0;top:0;width:0;height:0;z-index:5;transform-origin:0 0;will-change:transform;touch-action:none;cursor:grab;}
.sw-item:active{cursor:grabbing;}
.sw-wire{position:absolute;left:0;top:0;overflow:visible;pointer-events:none;}
.sw-wire line{stroke:#5c4a36;stroke-width:1.4;}
.sw-frame{position:absolute;display:block;background:#1b1714;box-shadow:0 0 0 1px rgba(0,0,0,.2);}
.sw-frame img{display:block;width:100%;height:100%;object-fit:cover;pointer-events:none;-webkit-user-drag:none;}
.sw-shadow{position:absolute;background:rgba(48,30,14,.5);filter:blur(14px);border-radius:4px;pointer-events:none;will-change:transform;}
.sw-foot{position:absolute;z-index:7;left:0;right:0;bottom:40px;display:flex;align-items:center;justify-content:space-between;gap:20px;padding:0 max(24px,calc((100vw - var(--maxw)) / 2 + 24px));}
.sw-cap{display:flex;flex-direction:column;gap:2px;background:rgba(250,246,239,.9);-webkit-backdrop-filter:blur(8px);backdrop-filter:blur(8px);padding:12px 16px;border-radius:4px;box-shadow:0 10px 30px rgba(60,40,22,.18);min-width:220px;}
.sw-cap-l{font-size:10px;font-weight:700;letter-spacing:.16em;text-transform:uppercase;color:var(--gold-ink);}
.sw-cap-n{font-family:var(--serif);font-size:21px;color:var(--walnut);line-height:1.15;}
.sw-cap-p{font-size:13px;color:var(--ink);}
.hx-swing .btn-outline{background:rgba(250,246,239,.65);}
.hx-swing .btn-outline:hover{background:var(--walnut);color:#fff;}
.sw-next svg{width:16px;height:16px;fill:none;stroke:currentColor;stroke-width:2;}
.sw-skirting{position:absolute;left:0;right:0;bottom:0;height:22px;z-index:2;background:linear-gradient(#f7f2ea,#e6ddcf);box-shadow:0 -6px 14px rgba(60,40,22,.12);}

/* ---------------------------------------------------------------- MAGIC PARTICLES */
.hx-particles{background:radial-gradient(ellipse at 68% 46%,#3a2a1d 0%,#20160e 52%,#140d08 100%);}
.px-stage{min-height:560px;cursor:crosshair;touch-action:pan-y;}
.px-canvas{position:absolute;inset:0;width:100%;height:100%;display:block;}
.px-crisp{position:absolute;inset:0;pointer-events:none;}
.px-crisp img{position:absolute;display:block;object-fit:cover;opacity:0;transition:opacity .45s ease;box-shadow:0 26px 50px rgba(0,0,0,.55);}
.px-crisp.on img{opacity:1;}
.px-touch{position:absolute;left:50%;bottom:86px;transform:translateX(-50%);z-index:4;display:flex;align-items:center;gap:8px;padding:9px 16px;border-radius:30px;background:rgba(242,237,228,.12);border:1px solid rgba(242,237,228,.35);color:#fff;font-size:12px;font-weight:600;letter-spacing:.12em;text-transform:uppercase;pointer-events:none;transition:opacity .5s;animation:pxPulse 2.2s ease-in-out infinite;}
.px-touch:before{content:"";width:8px;height:8px;border-radius:50%;background:var(--gold);box-shadow:0 0 12px var(--gold);}
.px-touch.off{opacity:0;}
@keyframes pxPulse{50%{transform:translateX(-50%) scale(1.05);}}
.px-cap{position:absolute;left:28px;bottom:24px;z-index:4;display:flex;flex-direction:column;gap:2px;color:#fff;max-width:60%;transition:opacity .4s;}
.px-cap-n{font-family:var(--serif);font-size:24px;line-height:1.15;}
.px-cap-p{font-size:13px;color:rgba(245,239,228,.85);}
.px-cap:hover .px-cap-n{color:var(--gold);}
.px-next{position:absolute;right:28px;bottom:26px;z-index:4;width:48px;height:48px;border-radius:50%;border:1.5px solid rgba(201,169,110,.7);color:var(--gold);display:flex;align-items:center;justify-content:center;transition:background .2s,transform .2s;}
.px-next:hover{background:rgba(201,169,110,.15);transform:rotate(30deg);}
.px-next svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2;}
.px-cap-v{color:var(--gold);text-decoration:underline;text-underline-offset:3px;}

/* ---------------------------------------------------------------- reduced motion */
@media(prefers-reduced-motion:reduce){
  .hx-text > *,.hx-cta,.px-touch{animation:none;}
  .to-demo-set{animation:none;}
  .to-demo-finger,.to-demo-ring{display:none;}
  .to-demo-toast{animation:none;opacity:1;transform:translate(-50%,0);}
}

/* ---------------------------------------------------------------- tablets & phones */
@media(max-width:1024px){
  .hx{grid-template-columns:1fr 1fr;}
  .hx-text{padding:44px 28px;}
}
@media(max-width:768px){
  .hx{grid-template-columns:1fr;min-height:0;}
  .hx-text{padding:24px 16px 34px;}
  .hx-h{font-size:40px;margin:10px 0 12px;}
  .hx-sub{font-size:15px;margin-bottom:18px;}
  .hx .btn{padding:14px 16px;font-size:11px;}
  .hx-btns .btn{flex:1 1 auto;}
  .hx-tryon .hx-stage,.hx-particles .hx-stage{order:-1;}
  .to-demo{padding:18px 16px 0;}
  .to-demo-card{border-radius:14px;transform:none;width:76%;}
  .hx-steps{gap:12px;margin-top:20px;}
  .hx-steps li{font-size:12px;}
  .sp-stage{padding:6px 16px 30px;gap:16px;}
  .hx-swipe .hx-text{padding-bottom:10px;}
  .hx-swipe .hx-sub{margin-bottom:12px;}
  .sp-deck{width:min(330px,80vw);}
  .sp-slot{width:44px;height:58px;}
  .sw-wall{height:auto;min-height:0;aspect-ratio:auto;padding-bottom:0;}
  .sw-text{position:relative;left:auto;top:auto;padding:26px 16px 0;max-width:none;}
  .sw-rack{position:relative;inset:auto;height:56vh;height:56svh;min-height:340px;max-height:520px;}
  .sw-foot{position:relative;bottom:auto;flex-direction:column;align-items:stretch;padding:0 16px 46px;gap:12px;}
  .sw-cap{min-width:0;}
  .px-stage{min-height:0;height:52vh;height:52svh;max-height:500px;}
  .px-touch{bottom:70px;}
  .px-cap{left:16px;bottom:16px;}
  .px-cap-n{font-size:19px;}
  .px-next{right:16px;bottom:16px;width:44px;height:44px;}
  /* particles: the buttons sit right under the art (first screen), the heading follows */
  .hx-particles .hx-text{display:contents;}
  .hx-particles .hx-text > *{margin-left:16px;margin-right:16px;}
  .hx-particles .hx-stage{order:-2;}
  .hx-particles .hx-btns{order:-1;margin-top:14px;}
  .hx-particles .hx-text > .label{margin-top:26px;}
  .hx-particles .hx-sub{margin-bottom:34px;}
}
.sp-sizes .opt{white-space:nowrap;font-size:12.5px;border-color:rgba(244,238,227,.4);}
.sp-sizes .opt.on{background:var(--gold);color:var(--walnut);border-color:var(--gold);}
@media(max-width:768px){.sp-sizes{width:100%;}.sp-sizes .opt{padding:10px 4px;font-size:12px;}}

/* swing: no text-selection highlight while dragging; dark-brown primary on the light wall */
.sw-wall{-webkit-user-select:none;user-select:none;-webkit-touch-callout:none;}
.sw-tilt[hidden]{display:none;}
.hx-swing .btn-gold{background:var(--btn);color:#fff;}
.hx-swing .btn-gold:hover{background:var(--btn-hover);color:#fff;}
@media(max-width:768px){.sw-rack{height:auto;min-height:0;max-height:none;}.sw-foot{padding-top:6px;}}
