/* Hale Lumina — Home page layout styles */



/* HERO base */
.hv { position: relative; min-height: 100vh; overflow: hidden; }

/* Hero A — full-bleed */
.hv-a { background: #1a1714; color: #ece4d4; display: flex; flex-direction: column; height: 100vh; padding-top: 110px; }
.hv-a-bg { position: absolute; inset: 0; }
.hv-a-bg image-slot { width: 100%; height: 100%; }
.hv-a-vignette {
  position: absolute; inset: 0; pointer-events: none;
  background:
    linear-gradient(180deg, rgba(20,18,14,.55) 0%, rgba(20,18,14,0) 28%, rgba(20,18,14,0) 50%, rgba(20,18,14,.82) 100%),
    linear-gradient(90deg, rgba(20,18,14,.5) 0%, rgba(20,18,14,0) 50%);
}
.hv-a-content {
  position: relative;
  margin-top: auto;
  padding: 0 clamp(24px, 5vw, 64px) clamp(96px, 14vh, 140px);
  z-index: 4; color: #ece4d4;
  width: 100%;
  max-width: var(--maxw);
  margin-left: auto; margin-right: auto;
}
.hv-a-content .label { color: var(--brass); }
.hv-a-h1 {
  font-family: var(--f-display); font-weight: 300;
  font-size: clamp(34px, 6.4vw, 104px); line-height: 1.04; letter-spacing: -.018em;
  margin: 24px 0 36px; max-width: 14ch; color: #f4ecdd;
}
.hv-a-h1 em { font-style: italic; font-weight: 300; color: var(--dusk); }
.hv-a-h1 em { font-style: italic; color: var(--dusk); }
.hv-a-sub { max-width: 50ch; color: rgba(236,228,212,.82); font-size: 17px; line-height: 1.55; }
.hv-a-ctas { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.hv-a-meta-l, .hv-a-meta-r {
  position: absolute; bottom: 28px; font-family: var(--f-mono);
  font-size: 10px; letter-spacing: .14em; color: rgba(236,228,212,.5); z-index: 4;
}
.hv-a-meta-l { left: clamp(24px, 5vw, 64px); }
.hv-a-meta-r { right: clamp(24px, 5vw, 64px); text-align: right; }
@media (max-width: 1024px) {
  .hv-a-meta-l, .hv-a-meta-r { display: none; }
}

/* Hero B — split */
.hv-b { display: grid; grid-template-columns: 1.05fr 1fr; min-height: 100vh; }
.hv-b-text { padding: 140px clamp(40px, 5vw, 80px) 56px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 56px; }
.hv-b-image { position: relative; }
.hv-b-image image-slot { width: 100%; height: 100%; }
.hv-b-h1 {
  font-family: var(--f-display); font-weight: 300;
  font-size: clamp(48px, 5.8vw, 88px); line-height: 1.04; letter-spacing: -.015em;
  margin: 26px 0 28px; max-width: 12ch;
}
.hv-b-h1 em { font-style: italic; color: var(--umber); }
.hv-b-ctas { display: flex; gap: 14px; margin-top: 36px; flex-wrap: wrap; }
.hv-b-meta { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em;
  color: var(--ink-mute); display: flex; justify-content: space-between; gap: 24px; }
@media (max-width: 900px) {
  .hv-b { grid-template-columns: 1fr; }
  .hv-b-image { min-height: 50vh; }
}

/* Hero C — dark monograph */
.hv-c { padding: 0; }
.hv-c-grid { padding: 140px clamp(40px, 5vw, 88px) 64px;
  display: grid; grid-template-rows: auto 1fr auto; gap: 72px; min-height: 100vh; }
.hv-c-top { display: flex; justify-content: space-between; align-items: baseline;
  color: rgba(236,228,212,.6); }
.hv-c-year { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; }
.hv-c-h1 {
  font-family: var(--f-display); font-weight: 300; font-style: italic;
  font-size: clamp(40px, 12vw, 220px); line-height: .94; letter-spacing: -.025em;
  color: #f4ecdd; max-width: 11ch; margin: 0;
}
.hv-c-h1 .brass { color: var(--brass); font-style: normal; }
.hv-c-bottom { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 48px; align-items: end; }
.hv-c-bottom .label { margin-bottom: 10px; display: block; }
.hv-c-bottom p { color: rgba(236,228,212,.72); font-size: 15px; line-height: 1.5; max-width: 30ch; }
.hv-c-ctas { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; }
@media (max-width: 900px) {
  .hv-c-bottom { grid-template-columns: 1fr; gap: 32px; }
}

/* Hero D — asymmetric atelier */
.hv-d { padding: 140px clamp(40px, 5vw, 88px) 64px; min-height: 100vh; }
.hv-d-rule { position: absolute; left: clamp(24px, 5vw, 88px); right: clamp(24px, 5vw, 88px);
  top: 110px; height: 1px; margin: 0;
  background: linear-gradient(90deg, transparent, var(--brass) 35%, var(--brass) 100%);
  opacity: .55; border: 0; }
.hv-d-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px 64px;
  margin-top: 32px;
}
.hv-d-h1 {
  grid-column: 1 / 3;
  font-family: var(--f-display); font-weight: 300;
  font-size: clamp(56px, 8.5vw, 132px); line-height: 1.0; letter-spacing: -.02em;
  max-width: 18ch; margin: 0 0 24px;
}
.hv-d-h1 em { font-style: italic; color: var(--umber); }
.hv-d-body { padding-right: 0; max-width: 50ch;
  display: flex; flex-direction: column; gap: 24px; align-self: end; }
.hv-d-ctas { display: flex; gap: 14px; margin-top: 8px; flex-wrap: wrap; }
.hv-d-tags { display: flex; gap: 16px; font-family: var(--f-mono);
  font-size: 10px; letter-spacing: .14em; color: var(--ink-mute); flex-wrap: wrap; }
.hv-d-image { align-self: stretch; min-height: 380px; }
.hv-d-image image-slot { width: 100%; height: 100%; min-height: 380px; }
@media (max-width: 900px) {
  .hv-d-grid { grid-template-columns: 1fr; }
  .hv-d-h1 { grid-column: 1; }
}

/* Height-based media queries for zoom support and maintaining 1-page bounds */
@media (max-height: 800px) {
  .hv-a { padding-top: 90px; }
  .hv-a-content { padding-bottom: clamp(40px, 6vh, 80px); }
  .hv-a-h1 { margin: 16px 0 24px; font-size: clamp(30px, 5.5vw, 76px); }
  .hv-a-ctas { margin-top: 24px; }

  .hv-b-text { padding-top: 110px; padding-bottom: 40px; gap: 32px; }
  .hv-b-h1 { margin: 16px 0 16px; font-size: clamp(36px, 5vw, 68px); }

  .hv-c-grid { padding-top: 110px; padding-bottom: 40px; gap: 36px; }
  .hv-c-h1 { font-size: clamp(36px, 10vw, 150px); }

  .hv-d { padding-top: 110px; padding-bottom: 40px; }
  .hv-d-grid { gap: 32px 32px; }
  .hv-d-h1 { font-size: clamp(44px, 7vw, 98px); }
  .hv-d-image, .hv-d-image image-slot { min-height: 280px; }
}

@media (max-height: 680px) {
  .hv-a { padding-top: 75px; }
  .hv-a-content { padding-bottom: 30px; }
  .hv-a-h1 { margin: 12px 0 16px; font-size: clamp(26px, 5vw, 56px); }
  .hv-a-sub { font-size: 15px; }
  .hv-a-ctas { margin-top: 18px; }

  .hv-b-text { padding-top: 90px; padding-bottom: 30px; gap: 20px; }
  .hv-b-h1 { margin: 10px 0 10px; font-size: clamp(30px, 4.5vw, 52px); }

  .hv-c-grid { padding-top: 90px; padding-bottom: 30px; gap: 24px; }
  .hv-c-h1 { font-size: clamp(30px, 8vw, 110px); }

  .hv-d { padding-top: 90px; padding-bottom: 30px; }
  .hv-d-grid { gap: 20px 20px; }
  .hv-d-h1 { font-size: clamp(36px, 6vw, 76px); }
  .hv-d-image, .hv-d-image image-slot { min-height: 220px; }
}

@media (max-height: 560px) {
  .hv-a { padding-top: 65px; }
  .hv-a-content { padding-bottom: 20px; }
  .hv-a-h1 { margin: 8px 0 10px; font-size: clamp(22px, 4.5vw, 38px); }
  .hv-a-sub { font-size: 13px; max-width: 45ch; line-height: 1.4; }
  .hv-a-ctas { margin-top: 12px; }

  .hv-b-text { padding-top: 75px; padding-bottom: 20px; gap: 12px; }
  .hv-b-h1 { margin: 8px 0 8px; font-size: clamp(24px, 4vw, 38px); }
  .hv-b-text .lead { font-size: 14px; }

  .hv-c-grid { padding-top: 75px; padding-bottom: 20px; gap: 16px; }
  .hv-c-h1 { font-size: clamp(24px, 7vw, 80px); }
  .hv-c-bottom p { font-size: 13px; }

  .hv-d { padding-top: 75px; padding-bottom: 20px; }
  .hv-d-grid { gap: 12px 12px; }
  .hv-d-h1 { font-size: clamp(28px, 5vw, 56px); }
  .hv-d-image, .hv-d-image image-slot { min-height: 160px; }
}

/* ─── BRAND PROMISE ──────────────────────────────────────────────── */
.brand-promise {
  display: grid; grid-template-columns: 1fr 1.1fr; gap: 80px;
  padding: var(--pad-section) clamp(24px, 5vw, 88px);
  max-width: var(--maxw); margin: 0 auto;
}
.brand-promise-left .label { display: block; margin-bottom: 28px; }
.brand-promise-left h2 { max-width: 14ch; }
.brand-promise-left p { margin-top: 32px; max-width: 44ch; }
.pillars { display: flex; flex-direction: column; }
.pillar {
  display: grid; grid-template-columns: 40px 1fr auto;
  padding: 30px 0;
  border-top: 1px solid var(--rule-soft);
  gap: 24px;
  align-items: start;
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), border-color 0.4s ease;
}
.pillar:hover {
  transform: translateX(8px);
  border-top-color: var(--brass);
}
.pillar:last-child { border-bottom: 1px solid var(--rule-soft); transition: border-color 0.4s ease; }
.pillar:last-child:hover { border-bottom-color: var(--brass); }
.pillar-num { font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em;
  color: var(--umber); margin-top: 6px; }
.pillar-title {
  font-family: var(--f-display); font-size: 30px; font-weight: 400;
  line-height: 1.1; letter-spacing: -.005em; margin: 0 0 10px;
  transition: color 0.4s ease;
}
.pillar:hover .pillar-title {
  color: var(--brass);
}
.pillar p { font-size: 15px; line-height: 1.55; max-width: 48ch; }
.pillar-arrow { 
  font-family: var(--f-mono); 
  color: var(--brass); 
  margin-top: 14px; 
  opacity: 0; 
  transform: translateX(-8px);
  transition: opacity 0.4s cubic-bezier(0.22, 1, 0.36, 1), transform 0.4s cubic-bezier(0.22, 1, 0.36, 1); 
}
.pillar:hover .pillar-arrow { 
  opacity: 1; 
  transform: translateX(0); 
}
@media (max-width: 900px) {
  .brand-promise { grid-template-columns: 1fr; gap: 56px; }
}

/* ─── PHILOSOPHY · Material / Volume / Light / Ritual ────────────── */
.philosophy { background: var(--bg-panel); }
.philosophy-inner { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.philosophy-head {
  display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px; margin-bottom: 80px;
  align-items: end;
}
.philosophy-head h2 { max-width: 12ch; }
.philosophy-head .head-meta { display: flex; flex-direction: column; gap: 18px; }
.mvlr { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.mvlr-card {
  display: flex; flex-direction: column; gap: 14px;
  cursor: pointer;
}
.mvlr-card .img-frame {
  aspect-ratio: 3 / 4;
  width: 100%;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.mvlr-card:hover .img-frame {
  transform: translateY(-8px);
  box-shadow: 0 16px 32px rgba(28,26,23,0.08), 0 0 40px rgba(176, 138, 98, 0.15);
}
.mvlr-card:hover image-slot::part(frame) {
  transform: scale(1.08);
}
.mvlr-card image-slot { width: 100%; height: 100%; }
.mvlr-card .word {
  font-family: var(--f-display); font-size: 28px; font-weight: 400;
  letter-spacing: -.005em; margin: 6px 0 0;
  transition: color 0.4s ease;
}
.mvlr-card:hover .word {
  color: var(--brass);
}
.mvlr-card p { font-size: 14px; line-height: 1.5; color: var(--ink-soft); }
.mvlr-card .num { font-family: var(--f-mono); font-size: 10px;
  letter-spacing: .14em; color: var(--brass); }
@media (max-width: 900px) {
  .philosophy-head { grid-template-columns: 1fr; gap: 40px; margin-bottom: 56px; }
  .mvlr { grid-template-columns: repeat(2, 1fr); gap: 32px 24px; }
}
@media (max-width: 560px) {
  .mvlr { grid-template-columns: 1fr; gap: 40px; }
}

/* ─── DUSK INDEX ──────────────────────────────────────────────────── */
.dusk-index-section { padding: 100px clamp(24px, 5vw, 88px); max-width: var(--maxw); margin: 0 auto; }
.dusk-index-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-bottom: 36px; gap: 40px; flex-wrap: wrap;
}
.dusk-index-head h3 { max-width: 22ch; }
.dusk-index-head .meta { font-size: 14px; color: var(--ink-soft); max-width: 40ch; }
.dusk-strip {
  position: relative;
  height: 88px;
  border-radius: 2px;
  overflow: hidden;
  background: linear-gradient(90deg,
    #F5EAD7 0%,
    #F2D49A 28%,
    #D69460 52%,
    #6E4836 76%,
    #1A1612 100%);
  cursor: pointer;
}
.dusk-strip::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.02), rgba(0,0,0,.16));
  pointer-events: none;
}
.dusk-markers {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 0;
  margin-top: 18px;
  font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em;
  color: var(--ink-soft);
}
.dusk-marker {
  display: flex; flex-direction: column; gap: 6px;
  background: transparent;
  border: 0;
  border-top: 1px solid var(--rule);
  padding: 14px 12px 0 0;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
  color: var(--ink-soft);
  transition: color .3s ease, border-color .3s ease;
}
.dusk-marker[data-active="true"] { border-top-color: var(--brass); color: var(--ink); }
.dusk-marker:hover { color: var(--ink); }
.dusk-marker-time { font-family: var(--f-mono); font-size: 10px; color: var(--ink-mute); }

/* ─── SERVICES OVERVIEW ──────────────────────────────────────────── */
.services-overview { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.services-head { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px;
  align-items: end; margin-bottom: 72px; }
.services-head h2 { max-width: 14ch; }
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  background: var(--rule-soft);
  border: 1px solid var(--rule-soft);
}
.svc-card { background: var(--bg); padding: 44px 36px 36px;
  display: flex; flex-direction: column; gap: 18px;
  min-height: 460px;
  position: relative;
  transition: background-color .35s ease, transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.svc-card:hover { 
  background: var(--bg-panel); 
  transform: translateY(-8px);
  box-shadow: 0 16px 32px rgba(28,26,23,0.08), 0 0 40px rgba(176, 138, 98, 0.15);
  z-index: 1;
}
.svc-card .label { color: var(--brass); }
.svc-card h3 {
  font-family: var(--f-display); font-size: clamp(28px, 2vw, 36px); font-weight: 400;
  margin: 6px 0 12px; max-width: 14ch;
  transition: color 0.4s ease;
}
.svc-card:hover h3 {
  color: var(--brass);
}
.svc-card p { font-size: 15px; line-height: 1.55; }
.svc-card ul { list-style: none; padding: 0; margin: 8px 0 0;
  font-family: var(--f-body); font-size: 13px; color: var(--ink-soft); line-height: 1.7; }
.svc-card ul li { padding-left: 16px; position: relative; }
.svc-card ul li::before {
  content: ""; position: absolute; left: 0; top: 11px; width: 6px; height: 1px;
  background: var(--brass);
}
.svc-card .arrow-link { margin-top: auto; }
@media (max-width: 900px) {
  .services-head { grid-template-columns: 1fr; gap: 32px; margin-bottom: 48px; }
  .svc-grid { grid-template-columns: 1fr; }
}

/* ─── PROCESS — Lumina Method ─────────────────────────────────────── */
.process { background: var(--bg-panel); }
.process-inner { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.process-head { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px;
  align-items: end; margin-bottom: 80px; }
.process-head h2 { max-width: 8ch; }
.steps { display: grid; grid-template-columns: repeat(5, 1fr); gap: 0;
  border-top: 1px solid var(--rule); }
.step {
  padding: 36px 24px 36px 0;
  border-right: 1px solid var(--rule-soft);
  display: flex; flex-direction: column; gap: 18px;
  position: relative;
  transition: transform 0.4s ease;
}
.step:last-child { border-right: none; padding-right: 0; }
.step:not(:first-child) { padding-left: 28px; }
.step-num { font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em;
  color: var(--brass); }
.step-title { font-family: var(--f-display); font-size: 28px; font-weight: 400;
  letter-spacing: -.005em; margin: 0; transition: color 0.4s ease; }
.step:hover .step-title { color: var(--brass); }
.step p { font-size: 14px; line-height: 1.55; transition: color 0.4s ease; }
.step:hover p { color: var(--ink); }
.step::before {
  content: ""; position: absolute; top: -1px; left: 0; width: 8px; height: 8px;
  background: var(--brass); border-radius: 50%;
  transform: translateY(-50%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.4s ease, background-color 0.4s ease;
}
.step:hover::before {
  transform: translateY(-50%) scale(1.5);
  box-shadow: 0 0 12px var(--brass);
  background-color: var(--dusk);
}
.step:not(:first-child)::before { left: 28px; }
@media (max-width: 1000px) {
  .steps { grid-template-columns: 1fr; }
  .step { border-right: none; border-bottom: 1px solid var(--rule-soft);
    padding-left: 28px !important; padding-right: 0; }
  .step::before { left: 0 !important; top: 32px; transform: none; }
}

/* ─── LIGHTING STRATEGY ──────────────────────────────────────────── */
.lighting-strategy { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.lighting-head { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px;
  align-items: end; margin-bottom: 64px; }
.lighting-head h2 { max-width: 12ch; }
.room-rail {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}
.room {
  display: flex; flex-direction: column; gap: 14px;
  cursor: pointer;
}
.room .img-frame { 
  aspect-ratio: 4 / 5; 
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.room:hover .img-frame {
  transform: translateY(-8px);
  box-shadow: 0 16px 32px rgba(28,26,23,0.08), 0 0 40px rgba(176, 138, 98, 0.15);
}
.room:hover image-slot::part(frame) {
  transform: scale(1.08);
}
.room image-slot { width: 100%; height: 100%; }
.room .hr-tag { font-family: var(--f-mono); font-size: 10px;
  letter-spacing: .14em; color: var(--brass); margin-top: 8px; }
.room h4 {
  font-family: var(--f-display); font-size: 22px; font-weight: 400;
  margin: 4px 0 8px; letter-spacing: -.005em;
  transition: color 0.4s ease;
}
.room:hover h4 {
  color: var(--brass);
}
.room p { font-size: 13px; line-height: 1.55; color: var(--ink-soft); }
@media (max-width: 900px) {
  .lighting-head { grid-template-columns: 1fr; gap: 32px; margin-bottom: 48px; }
  .room-rail { grid-template-columns: repeat(2, 1fr); gap: 32px 20px; }
}
@media (max-width: 600px) {
  .room-rail { grid-template-columns: 1fr; gap: 24px; }
}

/* ─── TECHNICAL PROOF ────────────────────────────────────────────── */
.tech-proof { background: var(--lava); color: #ece4d4; }
.tech-proof .label { color: var(--brass); }
.tech-proof-inner { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.tech-head { display: grid; grid-template-columns: 1fr 1.2fr; gap: 80px;
  align-items: end; margin-bottom: 80px; }
.tech-head h2 { color: #f4ecdd; max-width: 14ch; }
.tech-head p { color: rgba(236,228,212,.78); }
.tech-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 1px;
  background: rgba(236,228,212,.12); border: 1px solid rgba(236,228,212,.1); }
.tech-card {
  background: var(--lava); padding: 32px 24px;
  display: flex; flex-direction: column; gap: 16px;
  min-height: 280px;
}
.tech-card .icon { width: 28px; height: 28px; color: var(--brass); }
.tech-card h4 { font-family: var(--f-display); font-size: 22px; font-weight: 400;
  margin: 0; color: #f4ecdd; max-width: 14ch; letter-spacing: -.005em; }
.tech-card p { font-size: 13px; line-height: 1.55; color: rgba(236,228,212,.7); }
@media (max-width: 1000px) {
  .tech-head { grid-template-columns: 1fr; gap: 32px; margin-bottom: 48px; }
  .tech-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .tech-grid { grid-template-columns: 1fr; }
}

/* ─── PORTFOLIO ──────────────────────────────────────────────────── */
.portfolio-section { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px); }
.portfolio-head { display: grid; grid-template-columns: 1fr 1fr; gap: 80px;
  align-items: end; margin-bottom: 64px; }
.portfolio-head h2 { max-width: 18ch; }
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 32px;
  row-gap: 80px;
}
.proj-card { display: flex; flex-direction: column; gap: 16px; cursor: pointer; }
.proj-card .img-frame {
  aspect-ratio: var(--ar, 4 / 3);
  box-shadow: 0 4px 20px rgba(0,0,0,0.03);
  transform: translateY(0);
  transition: box-shadow 0.6s cubic-bezier(0.22, 1, 0.36, 1), transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}
.proj-card:hover .img-frame {
  box-shadow: 0 16px 36px rgba(28,26,23,0.12);
  transform: translateY(-8px);
}
:root[data-mood="night"] .proj-card .img-frame {
  box-shadow: 0 4px 24px rgba(0,0,0,0.25);
}
:root[data-mood="night"] .proj-card:hover .img-frame {
  box-shadow: 0 16px 36px rgba(0,0,0,0.45);
}
.proj-card:hover image-slot::part(frame) {
  transform: scale(1.08);
}
.proj-card image-slot { width: 100%; height: 100%; }
.proj-card .meta { display: flex; justify-content: space-between; align-items: baseline;
  margin-top: 4px; font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em;
  color: var(--ink-mute); }
.proj-card h4 {
  font-family: var(--f-display); font-size: 26px; font-weight: 400;
  margin: 2px 0 4px; letter-spacing: -.005em;
  transition: color 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.proj-card:hover h4 {
  color: var(--brass);
}
.proj-card p { font-size: 14px; max-width: 36ch; line-height: 1.5; color: var(--ink-soft); }
.proj-wide { grid-column: span 7; }
.proj-tall { grid-column: span 5; }
.proj-mid  { grid-column: span 6; }
.proj-narrow { grid-column: span 6; }
@media (max-width: 1000px) {
  .portfolio-head { grid-template-columns: 1fr; gap: 32px; margin-bottom: 48px; }
  .portfolio-grid { grid-template-columns: 1fr; }
  .proj-wide, .proj-tall, .proj-mid, .proj-narrow { grid-column: span 1; }
}

/* ─── STUDIO / ABOUT ─────────────────────────────────────────────── */
.studio { background: var(--bg-panel); }
.studio-inner { max-width: var(--maxw); margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px);
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 80px; align-items: center;
}
.studio-text h2 { max-width: 12ch; margin-bottom: 56px; }
.studio-text p { max-width: 50ch; margin-bottom: 18px; }
.studio-text .quote {
  margin: 32px 0 0;
  padding-left: 24px;
  border-left: 1px solid var(--brass);
  font-family: var(--f-display); font-style: italic; font-weight: 400;
  font-size: 22px; line-height: 1.4; color: var(--umber);
  max-width: 38ch;
}
.studio-image image-slot { width: 100%; aspect-ratio: 4 / 5; }
@media (max-width: 900px) {
  .studio-inner { grid-template-columns: 1fr; gap: 56px; }
}

/* ─── TESTIMONIALS ───────────────────────────────────────────────── */
.testimonials {
  background: var(--bg);
  transition: var(--bg-transition);
  position: relative;
}

.testimonials-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: var(--pad-section) var(--pad-x);
}

.testimonials-grid {
  display: grid;
  grid-template-columns: 1fr 1.65fr;
  gap: 80px;
  align-items: start;
}

.testimonials-meta-col {
  display: flex;
  flex-direction: column;
}

.testimonials-meta-col .label {
  display: block;
  margin-bottom: 24px;
}

.testimonials-meta-col h2 {
  max-width: 14ch;
  margin-bottom: 40px;
}

/* Builder Avatar Stamp & Info Clean Layout */
.builder-info-clean {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-top: 32px;
  border-top: 1px solid var(--rule-soft);
  padding-top: 28px;
  max-width: 380px;
}

.builder-avatar-stamp {
  position: relative;
  width: 80px;
  height: 80px;
  flex-shrink: 0;
  border-radius: 50%;
  background: var(--bg);
  border: 1px solid var(--rule-soft);
  display: flex;
  align-items: center;
  justify-content: center;
}

.stamp-letters {
  font-family: var(--f-display);
  font-size: 15px;
  font-weight: 500;
  color: var(--umber);
  letter-spacing: 0.05em;
  z-index: 2;
  margin-top: 1px;
}

.stamp-ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: stampRotate 30s linear infinite;
  pointer-events: none;
}

.stamp-text {
  font-family: var(--f-mono);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 1.1px;
  fill: var(--umber);
  opacity: 0.72;
}

.builder-details {
  display: flex;
  flex-direction: column;
}

.builder-name {
  font-family: var(--f-display);
  font-size: 22px;
  font-weight: 500;
  color: var(--ink);
  margin: 0 0 2px 0;
}

.builder-title {
  font-family: var(--f-mono);
  font-size: 10px;
  font-weight: 500;
  letter-spacing: var(--tr-label);
  color: var(--brass);
  margin: 0;
  text-transform: uppercase;
}

.builder-context {
  font-family: var(--f-body);
  font-size: 13px;
  line-height: 1.45;
  color: var(--ink-soft);
  margin: 6px 0 0 0;
}

/* Quote and Interactions */
.testimonials-quote-col {
  display: flex;
  flex-direction: column;
  gap: 40px;
}

.editorial-quote {
  font-family: var(--f-display);
  font-size: clamp(20px, 2.3vw, 26px);
  line-height: 1.5;
  font-style: italic;
  font-weight: 300;
  color: var(--ink);
  margin: 0;
}

.quote-segment {
  cursor: pointer;
  transition: opacity 0.4s ease, color 0.4s ease, border-bottom-color 0.4s ease;
  border-bottom: 1px dashed transparent;
  padding-bottom: 2px;
}

/* Luxury hover effect: fade out other lines when hovering one */
.editorial-quote:hover .quote-segment {
  opacity: 0.38;
}

.editorial-quote:hover .quote-segment:hover {
  opacity: 1 !important;
  color: var(--ink) !important;
  border-bottom-color: var(--brass);
}

.quote-segment.active {
  opacity: 1;
  color: var(--ink);
  border-bottom-color: rgba(176, 138, 98, 0.45);
}

/* Values Card Panel */
.values-breakdown-card {
  background: var(--bg-panel);
  border: 1px solid var(--rule-soft);
  border-radius: 6px;
  padding: 32px;
  min-height: 250px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transition: border-color 0.5s ease, box-shadow 0.5s ease, background-color 1s ease;
}

:root[data-mood="night"] .values-breakdown-card {
  background: rgba(29, 26, 24, 0.45);
}

.values-breakdown-card:hover {
  border-color: rgba(176, 138, 98, 0.2);
}

.desktop-only-card {
  display: flex;
  margin-top: 48px;
}

.mobile-only-card {
  display: none;
}

.values-header {
  border-bottom: 1px solid var(--rule-soft);
  padding-bottom: 16px;
}

.values-subtitle {
  font-family: var(--f-mono);
  font-size: 9px;
  font-weight: 500;
  letter-spacing: var(--tr-label);
  color: var(--brass);
  text-transform: uppercase;
}

.values-title {
  font-family: var(--f-display);
  font-size: 24px;
  font-weight: 400;
  color: var(--ink);
  margin: 4px 0 0 0;
  letter-spacing: -0.01em;
}

.values-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.value-item {
  display: flex;
  gap: 16px;
  align-items: start;
}

.value-bullet {
  width: 5px;
  height: 5px;
  background: var(--brass);
  transform: rotate(45deg);
  margin-top: 8px;
  flex-shrink: 0;
}

.value-text {
  display: flex;
  flex-direction: column;
}

.value-label {
  font-family: var(--f-body);
  font-weight: 600;
  font-size: 13.5px;
  letter-spacing: 0.01em;
  color: var(--ink);
}

.value-desc {
  font-size: 13.5px;
  line-height: 1.5;
  color: var(--ink-soft);
  margin: 2px 0 0 0;
  max-width: 58ch;
}

@keyframes stampRotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@media (max-width: 900px) {
  .testimonials-grid {
    grid-template-columns: 1fr;
    gap: 48px;
  }
  
  .builder-info-clean {
    max-width: 100%;
  }

  .desktop-only-card {
    display: none;
  }

  .mobile-only-card {
    display: flex;
    margin-top: 32px;
  }
}

/* ─── CTA ─────────────────────────────────────────────────────────── */
.cta-section { background: var(--lava); color: #ece4d4; position: relative; overflow: hidden; }
.cta-inner { max-width: var(--maxw); margin: 0 auto;
  padding: 140px clamp(24px, 5vw, 88px);
  text-align: left; position: relative; z-index: 2; }
.cta-glow {
  position: absolute; inset: -40% 30% auto auto;
  width: 60vw; height: 60vw; border-radius: 50%;
  background: radial-gradient(closest-side, rgba(199,162,122,.22), transparent 75%);
  filter: blur(20px); pointer-events: none; z-index: 1;
}
.cta-section h2 { color: #f4ecdd; max-width: 22ch; }
.cta-section h2 em { font-style: italic; color: var(--brass); }
.cta-section p { color: rgba(236,228,212,.78); max-width: 56ch; margin-top: 28px; font-size: 18px; }
.cta-buttons { display: flex; gap: 14px; margin-top: 48px; flex-wrap: wrap; }
.cta-meta { margin-top: 96px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px;
  border-top: 1px solid rgba(236,228,212,.18); padding-top: 36px; }
.cta-meta div { font-family: var(--f-mono); font-size: 11px; letter-spacing: .14em; color: rgba(236,228,212,.55); }
.cta-meta div b { display: block; font-family: var(--f-body); font-weight: 500;
  font-size: 13px; color: #f4ecdd; margin-top: 8px; letter-spacing: .05em; text-transform: none;
  transition: color 0.3s ease; }
.cta-meta div:hover b { color: var(--brass); }

@media (max-width: 900px) {
  .cta-meta { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .cta-meta { grid-template-columns: 1fr; gap: 28px; }
}

/* ─── FOOTER ─────────────────────────────────────────────────────── */
.site-footer { background: var(--bg); border-top: 1px solid var(--rule-soft); }
.footer-inner { max-width: var(--maxw); margin: 0 auto;
  padding: 80px clamp(24px, 5vw, 88px) 40px;
  display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 56px; }
.footer-inner h5 { font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em;
  text-transform: uppercase; color: var(--umber); margin: 0 0 18px; font-weight: 500; }
.footer-inner ul { list-style: none; padding: 0; margin: 0;
  display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.footer-inner a {
  color: var(--ink-soft);
  text-decoration: none;
  display: inline-block;
  transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1), color 0.3s ease;
}
.footer-inner a:hover {
  color: var(--brass);
  transform: translateX(4px);
}
.footer-brand p { font-size: 13px; line-height: 1.55; max-width: 28ch; margin-top: 16px; }
.footer-base {
  max-width: var(--maxw); margin: 0 auto;
  padding: 28px clamp(24px, 5vw, 88px) 56px;
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--f-mono); font-size: 10px; letter-spacing: .14em; color: var(--ink-mute);
  border-top: 1px solid var(--rule-soft);
}
@media (max-width: 900px) {
  .footer-inner { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 500px) {
  .footer-inner { grid-template-columns: 1fr; gap: 40px; }
}

/* Section number ribbon — appears at the top-left of major sections */
.sec-marker {
  position: absolute; top: 0; left: 0;
  padding: var(--pad-section) 0 0 clamp(24px, 5vw, 88px);
  pointer-events: none;
}

/* Image frame baseline — gives every image-slot a quiet frame */
.img-frame {
  background: var(--bone);
  position: relative;
  overflow: hidden;
}
:root[data-mood="night"] .img-frame { background: #2a2722; }

/* Subtle scroll progress brass bar */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 2px;
  background: var(--brass); z-index: 100; transform-origin: left;
  transform: scaleX(0); width: 100%; opacity: 0.85;
  transition: transform .1s linear;
  box-shadow: 0 0 8px var(--brass), 0 0 2px var(--brass);
}

/* ─── PARALLAX WINDOWS ────────────────────────────────────────────── */
.parallax-frame {
  position: relative;
  overflow: hidden;
}
.parallax-frame image-slot {
  position: absolute;
  top: -10%;
  left: 0;
  width: 100%;
  height: 120%;
  transform: translateY(var(--parallax-y, 0px)) scale(1.02);
  transition: transform 0.2s cubic-bezier(0.1, 0.9, 0.2, 1);
  will-change: transform;
}

/* ─── INTERACTIVE LUTRON-STYLE KEYPAD ────────────────────────────── */
.keypad-container {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 30px 10px;
}
.keypad-plate {
  width: 170px;
  background: linear-gradient(135deg, #5c4737 0%, #a37f5c 30%, #ceaa83 50%, #a37f5c 70%, #5c4737 100%);
  border: 1px solid rgba(43, 35, 28, 0.65);
  padding: 24px 18px;
  border-radius: 4px;
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.2),
    0 1px 3px rgba(0,0,0,0.4),
    0 16px 36px rgba(28,26,23,0.5);
  display: flex;
  flex-direction: column;
  gap: 14px;
  position: relative;
}
:root[data-mood="night"] .keypad-plate {
  border-color: rgba(0,0,0,0.8);
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.05),
    0 16px 40px rgba(0,0,0,0.8);
}
/* Beveled inner frame representing the luxury Alisse subplate reveal */
.keypad-plate::before {
  content: "";
  position: absolute;
  inset: 2px;
  border: 1px solid rgba(0,0,0,0.25);
  border-radius: 3px;
  pointer-events: none;
}
/* Realistic brass screws at top and bottom of plate */
.keypad-plate::after {
  content: "";
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #e1c099 20%, #7d5b3c 80%);
  box-shadow: inset 0 1px 1px rgba(0,0,0,0.4), 0 1px 0 rgba(255,255,255,0.25);
  left: 50%;
  transform: translateX(-50%);
  top: 8px;
}
/* Bottom screw */
.keypad-screw-bottom {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #e1c099 20%, #7d5b3c 80%);
  box-shadow: inset 0 1px 1px rgba(0,0,0,0.4), 0 1px 0 rgba(255,255,255,0.25);
  left: 50%;
  transform: translateX(-50%);
  bottom: 8px;
  pointer-events: none;
}

.keypad-button {
  background: linear-gradient(180deg, #8a6c51 0%, #6e5239 100%);
  border: 1px solid rgba(0,0,0,0.35);
  border-radius: 1px;
  padding: 15px 12px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.1),
    0 1px 2px rgba(0,0,0,0.25);
  transition: transform 0.15s cubic-bezier(0.22, 1, 0.36, 1), background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
  position: relative;
}
.keypad-button::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(255,255,255,0.08) 0%, transparent 100%);
  pointer-events: none;
}
.keypad-button:hover {
  background: linear-gradient(180deg, #9c7b5d 0%, #7e5f45 100%);
  border-color: rgba(0,0,0,0.45);
  box-shadow: 
    inset 0 1px 0 rgba(255,255,255,0.15),
    0 3px 8px rgba(0,0,0,0.18);
}
.keypad-button:active {
  transform: translateY(1.5px);
  box-shadow: 
    inset 0 2px 5px rgba(0,0,0,0.5),
    0 1px 0 rgba(255,255,255,0.05);
}

/* ─── ATMOSPHERE CONTROL SECTION ─────────────────────────────────── */
.atmosphere-section {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: var(--pad-section) clamp(24px, 5vw, 88px);
  position: relative;
  box-sizing: border-box;
}

.study-header {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 80px;
  align-items: end;
  margin-bottom: 56px;
}

@media (max-width: 900px) {
  .study-header {
    grid-template-columns: 1fr;
    gap: 24px;
    margin-bottom: 40px;
  }
}

/* ─── LIGHT MODULATOR INTERACTIVE WIDGET ──────────────────────────── */
/* Side-by-side: large photo on the left, controls on the right so the user
   can tweak a slider and see the photo change without scrolling. Photo
   gets a generous 1.7fr to 1fr ratio so it's clearly the focal point. */
.immersive-study-component {
  background: rgba(22, 19, 16, 0.95);
  border: 1px solid rgba(176, 138, 98, 0.15);
  border-radius: 8px;
  box-shadow: 0 20px 48px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.05);
  padding: 28px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-sizing: border-box;
  width: 100%;
}

.desktop-only-modulator {
  display: grid;
  grid-template-columns: 1.7fr 1fr;
  gap: 32px;
  width: 100%;
}

.mobile-only-modulator {
  display: none;
}

.study-viewport-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
  min-width: 0;
  min-height: 0;
}

.study-viewport {
  /* Fill the column height so the photo aligns with the controls panel
     beside it. min-height keeps it substantial on tall sections; the
     image inside uses object-fit: cover so nothing distorts. */
  flex: 1 1 0;
  min-height: 460px;
  position: relative;
  overflow: hidden;
  background: #090706;
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 6px;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.55);
}

.viewport-base-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.viewport-layer {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  mix-blend-mode: screen;
  pointer-events: none;
  transition: opacity 0.25s cubic-bezier(0.22, 1, 0.36, 1), filter 0.25s ease;
}

.viewport-label-tag {
  position: absolute;
  bottom: 16px;
  left: 16px;
  background: rgba(18, 16, 14, 0.85);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border: 1px solid rgba(176, 138, 98, 0.25);
  padding: 6px 12px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  gap: 10px;
  z-index: 5;
  box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.viewport-num {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--brass);
  font-weight: 600;
}

.viewport-title {
  font-family: var(--f-display);
  font-size: 12px;
  letter-spacing: 0.05em;
  color: #ece4d4;
}

.study-control-panel {
  /* Right-column stack — each section flows top to bottom alongside the
     photo. No max-width cap; let it fill its grid column naturally. */
  display: flex;
  flex-direction: column;
  gap: 24px;
  width: 100%;
  min-width: 0;
}

.control-panel-section {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
  min-width: 0;
}

.sidebar-label {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass);
  display: block;
}

.room-selector-list {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  padding: 2px 2px 6px 2px;
}

.room-selector-list::-webkit-scrollbar {
  display: none;
}

.room-selector-item {
  /* Fixed-basis thumbs in a horizontally scrollable row — keeps the right
     control column from being squeezed by 5 thumbs at full width. */
  flex: 0 0 125px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: rgba(255, 255, 255, 0.01);
  border: 1px solid rgba(255, 255, 255, 0.06);
  padding: 6px;
  border-radius: 6px;
  cursor: pointer;
  text-align: left;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  box-sizing: border-box;
}

.room-selector-item:hover {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(176, 138, 98, 0.2);
}

.room-selector-item.active {
  background: rgba(176, 138, 98, 0.1);
  border-color: var(--brass);
  box-shadow: 0 0 12px rgba(176, 138, 98, 0.15);
}

.room-thumb {
  width: 100%;
  height: 60px;
  object-fit: cover;
  border-radius: 4px;
  filter: brightness(0.6);
  transition: filter 0.3s ease;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.room-selector-item.active .room-thumb,
.room-selector-item:hover .room-thumb {
  filter: brightness(1.0);
}

.room-item-text {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.room-item-name {
  font-family: var(--f-body);
  font-size: 11px;
  color: #ece4d4;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.room-item-desc {
  display: none; /* Hide descriptions to save vertical screen space */
}

/* Tabs */
.console-tabs {
  display: flex;
  gap: 3px;
  background: rgba(18, 16, 14, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 3px;
  border-radius: 6px;
  width: 100%;
  box-sizing: border-box;
}

.console-tab {
  flex: 1;
  background: transparent;
  border: none;
  color: var(--ink-soft);
  font-family: var(--f-mono);
  font-size: 10px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 9px 8px;
  cursor: pointer;
  transition: all 0.25s ease;
  border-radius: 4px;
  text-align: center;
}

@media (max-width: 420px) {
  .console-tab {
    font-size: 8.5px;
    padding: 8px 4px;
    letter-spacing: 0.04em;
  }
}

.console-tab:hover {
  color: #ece4d4;
  background: rgba(255, 255, 255, 0.02);
}

.console-tab.active {
  color: var(--lava);
  background: var(--brass);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(176, 138, 98, 0.25);
}

/* Control area stack */
.console-control-area {
  background: rgba(18, 16, 14, 0.4);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 6px;
  padding: 20px;
  box-sizing: border-box;
}

.console-control-row {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.console-power-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.control-row-label {
  font-family: var(--f-mono);
  font-size: 9px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.control-row-val {
  font-family: var(--f-mono);
  font-size: 10px;
  color: var(--brass);
  font-weight: 500;
}

.control-slider-cell {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.control-slider-label-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

/* Slider Track & Thumb Styling */
.modulator-slider-input {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 3px;
  background: linear-gradient(to right, var(--brass) 0%, var(--brass) var(--pct, 0%), rgba(255, 255, 255, 0.1) var(--pct, 0%), rgba(255, 255, 255, 0.1) 100%);
  outline: none;
  border-radius: 2px;
  margin: 10px 0;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.modulator-slider-input::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--brass);
  border: 1px solid rgba(0, 0, 0, 0.35);
  box-shadow: 0 2px 6px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.2);
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.2s ease;
}

.modulator-slider-input::-webkit-slider-thumb:hover {
  transform: scale(1.25);
  background: #e1c099;
}

.modulator-slider-input::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--brass);
  border: 1px solid rgba(0, 0, 0, 0.35);
  box-shadow: 0 2px 6px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.2);
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1);
}

.modulator-slider-input::-moz-range-thumb:hover {
  transform: scale(1.25);
  background: #e1c099;
}

/* Switch toggle */
.studioswitch {
  position: relative;
  display: inline-block;
  width: 36px;
  height: 20px;
  margin-top: 4px;
}

.studioswitch input { 
  opacity: 0;
  width: 0;
  height: 0;
}

.studioslider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background-color: rgba(18, 16, 14, 0.6);
  border: 1px solid rgba(176, 138, 98, 0.25);
  transition: .3s cubic-bezier(0.22, 1, 0.36, 1);
}

.studioslider:before {
  position: absolute;
  content: "";
  height: 12px;
  width: 12px;
  left: 3px;
  bottom: 3px;
  background-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
  transition: .3s cubic-bezier(0.22, 1, 0.36, 1);
}

.studioswitch input:checked + .studioslider {
  background-color: rgba(176, 138, 98, 0.2);
  border-color: var(--brass);
}

.studioswitch input:checked + .studioslider:before {
  transform: translateX(16px);
  background-color: var(--brass);
  box-shadow: 0 0 8px var(--brass);
}

.studioslider.rounded {
  border-radius: 20px;
}

.studioslider.rounded:before {
  border-radius: 50%;
}

/* Scene Presets */
.study-presets-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  width: 100%;
}

@media (max-width: 600px) {
  .study-presets-grid {
    grid-template-columns: 1fr;
  }
}

.preset-card-btn {
  background: rgba(18, 16, 14, 0.45);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 6px;
  padding: 12px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  text-align: left;
  transition: all 0.25s cubic-bezier(0.22, 1, 0.36, 1);
  box-sizing: border-box;
  width: 100%;
}

.preset-card-btn:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(176, 138, 98, 0.4);
  transform: translateY(-1.5px);
}

.preset-card-btn:active {
  transform: translateY(0.5px);
}

.preset-card-btn.active {
  background: rgba(176, 138, 98, 0.08);
  border-color: var(--brass);
  box-shadow: 0 0 10px rgba(176, 138, 98, 0.15);
}

.preset-card-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.mobile-only-modulator {
  display: none;
}

.preset-card-title {
  font-family: var(--f-mono);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #ece4d4;
  transition: color 0.25s ease;
}

.preset-card-btn.active .preset-card-title {
  color: var(--brass);
}

.preset-card-sub {
  font-family: var(--f-body);
  font-size: 9px;
  color: var(--ink-soft);
  opacity: 0.85;
}

.preset-card-graph {
  display: flex;
  align-items: flex-end;
  gap: 3px;
  height: 24px;
  width: 25px;
  padding-bottom: 2px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.graph-bar {
  flex: 1;
  min-height: 1px;
  border-radius: 1px 1px 0 0;
  transition: height 0.3s cubic-bezier(0.22, 1, 0.36, 1), background-color 0.3s ease;
}

.preset-card-btn.reset.active {
  background: rgba(220, 80, 80, 0.05);
  border-color: rgba(220, 80, 80, 0.4);
  box-shadow: 0 0 10px rgba(220, 80, 80, 0.1);
}

.preset-card-btn.reset.active .preset-card-title {
  color: #ff5555;
}

/* Responsive Rules */
@media (max-width: 1024px) {
  .immersive-study-component {
    /* Tablet+phone: stack the photo over the controls — side-by-side would
       cram both columns. Photo gets back its 3:2 aspect when stacked. */
    grid-template-columns: 1fr;
    gap: 24px;
    padding: 20px;
  }
  .study-viewport {
    aspect-ratio: 3 / 2;
    min-height: 0;
    flex: none;
  }
}

.modulator-mobile-tabs {
  display: none;
}

@media (max-width: 768px) {
  .immersive-study-component {
    padding: 12px !important;
    gap: 12px !important;
    background: rgba(22, 19, 16, 0.98) !important;
    border-radius: 16px !important;
  }

  .desktop-only-modulator {
    display: none !important;
  }

  .mobile-only-modulator {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 14px;
  }

  /* Viewport for image */
  .mobile-viewport-wrapper {
    position: relative;
    width: 100%;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.04);
    pointer-events: none;
  }

  .mobile-viewport-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    pointer-events: none;
    user-select: none;
    -webkit-user-drag: none;
  }

  /* Selector row below the viewport image */
  .mobile-selectors-row {
    display: flex;
    width: 100%;
    gap: 12px;
    box-sizing: border-box;
  }

  .mobile-overlay-dropdown {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    position: relative;
  }

  .dropdown-field-label {
    font-family: var(--f-mono, monospace);
    font-size: 8px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--ink-soft);
    margin-left: 2px;
  }

  .mobile-dropdown-trigger {
    width: 100%;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(176, 138, 98, 0.3);
    color: #ece4d4; /* High contrast ivory */
    padding: 10px 14px;
    border-radius: 8px;
    font-family: var(--f-mono, monospace);
    font-size: 9.5px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    box-sizing: border-box;
    transition: all 0.25s ease;
  }

  .mobile-dropdown-trigger:active,
  .mobile-dropdown-trigger.active {
    background: var(--brass);
    color: var(--lava);
    border-color: var(--brass);
  }

  .mobile-dropdown-trigger .arrow {
    font-size: 8px;
    opacity: 0.8;
  }

  .mobile-dropdown-menu {
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    background: #1c1815; /* Solid rich dark background */
    border: 1px solid rgba(176, 138, 98, 0.4);
    border-radius: 8px;
    padding: 4px;
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 2px;
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.8);
    z-index: 25;
    box-sizing: border-box;
  }

  .mobile-dropdown-menu.right-aligned {
    left: auto;
    right: 0;
  }

  .mobile-menu-item {
    background: transparent;
    border: none;
    color: #ece4d4; /* Guaranteed contrast */
    padding: 10px 12px;
    font-family: var(--f-mono, monospace);
    font-size: 9px;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    text-align: left;
    width: 100%;
    border-radius: 6px;
    cursor: pointer;
    box-sizing: border-box;
    transition: all 0.2s ease;
  }

  .mobile-menu-item:active,
  .mobile-menu-item.active {
    background: rgba(176, 138, 98, 0.2);
    color: var(--brass);
    font-weight: 600;
  }

  /* 4 Vertical sliders row side-by-side */
  .mobile-sliders-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    width: 100%;
  }

  .mobile-slider-capsule {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    background: rgba(18, 16, 14, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.02);
    padding: 10px 4px 6px 4px;
    border-radius: 28px;
    transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    box-sizing: border-box;
  }

  .mobile-slider-capsule.selected {
    background: rgba(176, 138, 98, 0.05);
    border-color: rgba(176, 138, 98, 0.3);
    box-shadow: 0 4px 20px rgba(176, 138, 98, 0.05);
  }

  .vertical-slider-wrapper {
    position: relative;
    width: 42px;
    height: 110px;
    background: rgba(10, 8, 7, 0.7);
    border: 1px solid rgba(255, 255, 255, 0.04);
    border-radius: 21px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    touch-action: none;
  }

  .vertical-slider-input {
    position: absolute;
    width: 110px;
    height: 42px;
    top: calc(50% - 21px);
    left: calc(50% - 55px);
    transform: rotate(270deg);
    opacity: 0;
    margin: 0;
    cursor: pointer;
    z-index: 5;
    -webkit-appearance: none;
    touch-action: none;
  }

  .vertical-slider-track {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: rgba(10, 8, 7, 0.4);
  }

  .vertical-slider-fill {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    transition: height 0.1s cubic-bezier(0.22, 1, 0.36, 1);
  }

  .slider-percentage-label {
    display: block;
    text-align: center;
    font-family: var(--f-mono, monospace);
    font-size: 9px;
    font-weight: 600;
    color: #ece4d4;
    letter-spacing: 0.05em;
    margin-bottom: 2px;
    pointer-events: none;
  }

  .mobile-slider-capsule.selected .slider-percentage-label {
    color: var(--brass);
  }

  .mobile-capsule-power-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: transparent;
    border: none;
    cursor: pointer;
    gap: 4px;
    width: 100%;
    padding: 2px 0;
  }

  .mobile-capsule-power-btn .power-led {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.06);
    transition: all 0.3s ease;
  }

  .mobile-capsule-power-btn.on .power-led {
    background: #ffcc88;
    box-shadow: 0 0 6px #ffa834;
  }

  .channel-label {
    font-family: var(--f-mono, monospace);
    font-size: 8px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--ink-soft);
  }

  .mobile-slider-capsule.selected .channel-label {
    color: var(--brass);
    font-weight: 600;
  }

  /* Dynamic Warmth Slider for selected channel */
  .mobile-warmth-container {
    background: rgba(18, 16, 14, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    padding: 10px 12px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    box-sizing: border-box;
  }

  .warmth-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
  }

  .warmth-title {
    font-family: var(--f-mono, monospace);
    font-size: 8px;
    letter-spacing: 0.06em;
    color: var(--ink-soft);
  }

  .warmth-value {
    font-family: var(--f-mono, monospace);
    font-size: 8px;
    color: var(--brass);
    font-weight: 600;
  }

  .mobile-warmth-slider {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(to right, #ff8a1e, #ffdf96, #e6f0ff);
    outline: none;
    position: relative;
    cursor: pointer;
    touch-action: none;
  }

  .mobile-warmth-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #ffffff;
    border: 2px solid var(--brass);
    box-shadow: 0 2px 8px rgba(0,0,0,0.5);
    cursor: pointer;
    transition: transform 0.1s ease;
  }





