/* ===== Mirror Hall — Dubai Aktiviteleri immersive exhibition prototype =====
   Vertical exhibition panels distributed in real 3D depth. Continuous
   distance-based interpolation drives every transform — no discrete
   slots, no carousel library. See mirror-hall.js. */

.mh{
  position:relative;
  overflow:hidden;
  min-height:86vh;
  display:flex;
  flex-direction:column;
  justify-content:center;
  padding:56px 0 40px;
  background:
    radial-gradient(ellipse 80% 70% at 50% 35%, rgba(11,36,56,.6) 0%, transparent 72%),
    linear-gradient(180deg,#061525 0%,#071A2B 55%,#0B2438 100%);
  border-top:1px solid rgba(201,165,92,.16);
  border-bottom:1px solid rgba(201,165,92,.16);
}

/* Quiet background UI — the gallery is the hero, this is ambience only */
.mh-ui{position:absolute;inset:0;z-index:0;pointer-events:none;overflow:hidden}
.mh-ui-coord{position:absolute;top:26px;left:clamp(20px,4vw,54px);display:flex;flex-direction:column;gap:3px;font-family:'Jost',sans-serif;font-size:.6rem;letter-spacing:.14em;color:rgba(159,175,190,.34);opacity:.7}
.mh-ui-code{font-size:.66rem;letter-spacing:.26em;color:rgba(201,165,92,.4);font-weight:600}
.mh-ui-label{position:absolute;top:26px;right:clamp(20px,4vw,54px);text-align:right;font-family:'Jost',sans-serif;font-size:.56rem;letter-spacing:.16em;text-transform:uppercase;color:rgba(159,175,190,.28);line-height:1.75}
.mh-ui-label b{color:rgba(201,165,92,.42);font-weight:600}

.mh-head{max-width:560px;margin:0 auto 20px;text-align:center;position:relative;z-index:2}
.mh-head .eyebrow{font-size:.66rem;letter-spacing:.28em;text-transform:uppercase;color:rgba(216,188,122,.75);font-weight:600;display:inline-flex;align-items:center;gap:10px}
.mh-head .eyebrow::before{content:"";width:22px;height:1px;background:rgba(201,165,92,.5)}
.mh-head h2{font-family:'Cormorant Garamond',serif;font-size:clamp(1.7rem,3.2vw,2.3rem);color:#fff;margin:10px 0 8px;font-weight:600;line-height:1.1}
.mh-head p{color:rgba(215,223,231,.7);font-size:.88rem;margin:0;line-height:1.5}

.mh-stage{
  position:relative;
  z-index:1;
  flex:1 1 auto;
  min-height:420px;
  height:clamp(420px,58vh,680px);
  perspective:1000px;
  perspective-origin:50% 68%;
  touch-action:pan-y;
  cursor:grab;
  user-select:none;
  -webkit-user-select:none;
}
.mh-stage.dragging{cursor:grabbing}

.mh-track{
  position:absolute;
  inset:0;
  transform-style:preserve-3d;
  pointer-events:none;
}

.mh-card{
  position:absolute;
  top:50%;
  left:50%;
  width:260px;
  height:420px;
  margin:-210px 0 0 -130px;
  will-change:transform,opacity,filter;
  pointer-events:auto;
}

.mh-card-inner{
  position:relative;
  width:100%;
  height:100%;
  border-radius:10px;
  overflow:hidden;
  background:#0B2438;
  border:1px solid rgba(255,255,255,.055);
  box-shadow:0 26px 60px -18px rgba(0,0,0,.65);
  transition:border-color .4s ease,box-shadow .4s ease;
}
.mh-card.is-active .mh-card-inner{
  border-color:rgba(201,165,92,.4);
  box-shadow:0 50px 110px -20px rgba(0,0,0,.8),0 0 70px -16px rgba(201,165,92,.28);
}

.mh-card-media{position:absolute;inset:0}
.mh-card-media img{width:100%;height:100%;object-fit:cover;display:block}
.mh-card-media::after{
  content:"";
  position:absolute;
  left:0;right:0;bottom:0;
  height:36%;
  background:linear-gradient(0deg,rgba(6,15,25,.92) 0%,rgba(6,15,25,.55) 45%,transparent 100%);
}
.mh-card-media::before{
  content:"";
  position:absolute;inset:0;
  background:rgba(6,15,25,.16);
  transition:background .35s ease;
}
.mh-card.is-active .mh-card-media::before{background:rgba(6,15,25,0)}

.mh-badge{
  position:absolute;
  top:14px;
  left:14px;
  z-index:2;
  padding:5px 10px;
  border-radius:999px;
  background:rgba(6,15,25,.55);
  border:1px solid rgba(201,165,92,.5);
  backdrop-filter:blur(6px);
  -webkit-backdrop-filter:blur(6px);
  color:#D8BC7A;
  font-size:.56rem;
  letter-spacing:.1em;
  text-transform:uppercase;
  font-weight:600;
  white-space:nowrap;
}

.mh-card-content{
  position:absolute;
  left:0;right:0;bottom:0;
  z-index:2;
  padding:0 18px 18px;
}
.mh-kicker{
  display:block;
  font-size:.6rem;
  letter-spacing:.2em;
  text-transform:uppercase;
  color:#D8BC7A;
  font-weight:600;
  margin-bottom:6px;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
}
.mh-title{
  font-family:'Cormorant Garamond',serif;
  color:#fff;
  font-weight:600;
  line-height:1.16;
  margin:0 0 12px;
  display:-webkit-box;
  -webkit-box-orient:vertical;
  -webkit-line-clamp:2;
  overflow:hidden;
}
.mh-actions{display:flex;align-items:center;justify-content:space-between;gap:14px;overflow:hidden}
.mh-link{
  flex:0 1 auto;
  color:rgba(216,188,122,.92);
  font-size:.68rem;
  letter-spacing:.1em;
  text-transform:uppercase;
  font-weight:600;
  white-space:nowrap;
  border-bottom:1px solid rgba(216,188,122,.4);
  padding-bottom:2px;
  transition:color .25s ease,border-color .25s ease;
}
.mh-link:hover{color:#fff;border-color:#fff}
.mh-btn{
  flex:0 0 auto;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  padding:8px 14px;
  border-radius:999px;
  border:1px solid #1f8f57;
  background:#1f8f57;
  color:#fff;
  font-size:.6rem;
  letter-spacing:.04em;
  text-transform:uppercase;
  font-weight:600;
  white-space:nowrap;
  transition:background .25s ease,border-color .25s ease,transform .25s ease;
}
.mh-btn:hover{background:#1a784b;border-color:#1a784b;transform:translateY(-1px)}

.mh-reflection{
  position:absolute;
  top:100%;
  left:0;
  width:100%;
  height:28%;
  transform:scaleY(-.58);
  transform-origin:top;
  pointer-events:none;
  filter:blur(10px) brightness(.9);
  -webkit-mask-image:linear-gradient(to bottom, rgba(0,0,0,.85), transparent 42%);
  mask-image:linear-gradient(to bottom, rgba(0,0,0,.85), transparent 42%);
}

/* Real floor plane: a soft light pool at the card bases, sinking into
   deep midnight navy — perceived subconsciously, not a visible surface. */
.mh-floor-plane{
  position:absolute;
  left:0;right:0;
  top:calc(50% + 150px);
  bottom:-10%;
  z-index:0;
  pointer-events:none;
  background:
    radial-gradient(ellipse 46% 60% at 50% 0%, rgba(30,58,86,.4) 0%, transparent 70%),
    linear-gradient(180deg, rgba(18,38,58,.22) 0%, rgba(8,19,31,.7) 45%, #050d17 100%);
}

.mh-floor-line{
  position:absolute;
  left:8%;
  right:8%;
  top:calc(50% + 236px);
  height:1px;
  background:linear-gradient(90deg,transparent,rgba(201,165,92,.08) 30%,rgba(201,165,92,.08) 70%,transparent);
  z-index:1;
  pointer-events:none;
}
.mh-floor-line::before{
  content:"";
  position:absolute;
  left:50%;top:0;
  width:380px;height:90px;
  transform:translate(-50%,-4px);
  background:radial-gradient(ellipse 50% 100% at 50% 0%, rgba(201,165,92,.05) 0%, transparent 78%);
  pointer-events:none;
}

.mh-hint{
  text-align:center;
  margin:16px 0 0;
  font-size:.6rem;
  letter-spacing:.16em;
  text-transform:uppercase;
  color:rgba(159,175,190,.55);
  position:relative;
  z-index:2;
}

/* Mobile-only progress indicator (counter + thin line). Hidden on
   desktop/tablet by default — shown only inside the <=720px block below. */
.mh-progress-m{display:none}

/* Tablet: a reduced version of the desktop perspective effect, not the
   phone layout. Center card dominant, 2–3 cards visible, milder rotation,
   substantially flattened depth, touch drag/swipe (same pointer pipeline
   as desktop), no heavy reflection. mirror-hall.js dampens z/rotateY/
   reflection specifically for this band — desktop formulas are untouched. */
@media(min-width:721px) and (max-width:1100px){
  .mh{min-height:74vh;padding:44px 0 30px}
  .mh-stage{height:clamp(340px,50vh,540px);perspective:1400px;perspective-origin:50% 60%}
  .mh-card{width:210px;height:340px;margin:-170px 0 0 -105px}
  .mh-floor-line{top:calc(50% + 196px)}
}

/* Mobile: a dedicated, non-3D subsystem — native horizontal scroll-snap,
   one dominant card with small neighbour peeks. No rotateY, no translateZ,
   no reflection, no fixed oversized stage. mirror-hall.js skips render()/
   drag/wheel entirely below this breakpoint and lets the browser own the
   scrolling; only the active/snapped card reveals its CTA row. */
@media(max-width:720px){
  .mh{
    min-height:0;
    display:block;
    padding:22px 0 28px;
  }
  .mh-ui{display:none}
  .mh-head{margin:0 0 14px}
  .mh-head h2{font-size:1.34rem}
  .mh-head p{font-size:.78rem;max-width:90%;margin:0 auto}
  .mh-floor-plane,.mh-floor-line,.mh-hint{display:none}

  .mh-progress-m{
    display:flex;
    align-items:center;
    gap:10px;
    padding:0 7.5vw;
    margin:0 0 10px;
  }
  .mh-progress-m b{
    font-family:'Jost',sans-serif;
    font-size:.62rem;
    letter-spacing:.14em;
    color:rgba(216,188,122,.85);
    font-weight:600;
    white-space:nowrap;
  }
  .mh-progress-m-track{
    flex:1 1 auto;
    height:1px;
    background:rgba(255,255,255,.1);
    position:relative;
    overflow:hidden;
    border-radius:1px;
  }
  .mh-progress-m-fill{
    position:absolute;
    left:0;top:0;bottom:0;
    width:0%;
    background:linear-gradient(90deg,rgba(201,165,92,.5),#D8BC7A);
    transition:width .25s ease;
  }

  .mh-stage{
    position:relative;
    z-index:1;
    flex:0 0 auto;
    height:auto;
    min-height:0;
    perspective:none;
    touch-action:pan-x;
    cursor:auto;
    user-select:auto;
    -webkit-user-select:auto;
    overflow:visible;
  }
  .mh-track{
    position:relative;
    inset:auto;
    transform-style:flat;
    display:flex;
    align-items:stretch;
    gap:12px;
    overflow-x:auto;
    overflow-y:hidden;
    scroll-snap-type:x mandatory;
    -webkit-overflow-scrolling:touch;
    scroll-padding-inline:7.5vw;
    padding:2px 7.5vw 14px;
    pointer-events:auto;
  }
  .mh-track::-webkit-scrollbar{display:none}
  .mh-card{
    position:relative;
    top:auto;left:auto;margin:0;
    flex:0 0 86vw;
    width:86vw;
    height:clamp(360px,60vh,540px);
    scroll-snap-align:center;
    scroll-snap-stop:always;
    transform:none;
    filter:none;
    opacity:.5;
    z-index:auto!important;
    transition:opacity .3s ease;
  }
  .mh-card.is-active{opacity:1}
  .mh-reflection{display:none}

  .mh-badge{top:12px;left:12px;padding:4px 9px;font-size:.52rem}
  .mh-card-content{padding:0 16px 16px}
  .mh-kicker{opacity:1!important;margin-bottom:5px}
  .mh-title{
    margin-bottom:10px;
    opacity:1!important;
    font-size:1.18rem!important;
  }
  .mh-actions{
    opacity:0;
    pointer-events:none;
    transition:opacity .25s ease;
  }
  .mh-card.is-active .mh-actions{
    opacity:1;
    pointer-events:auto;
  }
  .mh-link{font-size:.7rem}
  .mh-btn{font-size:.62rem;padding:11px 16px;min-height:0}
}

@media(prefers-reduced-motion:reduce){
  .mh-card-inner{transition:none}
}

/* Prototype-review only: the old 3-column catalog grid stays in the DOM
   (data untouched) but is not shown while Mirror Hall is under review —
   the gallery itself is meant to become the activity browser. */
.mh-legacy-hidden{display:none}
