:root {
  --surface:#e8efed; --soft:#dce7e6; --deck:#35565e;
  --studio-rim:inset 0 1px 0 #ffffff70, inset 0 -1px 0 #12333b18;
}
:root[data-theme=dark] {
  --surface:#233e46; --soft:#2d4a52; --deck:#253f49;
  --grey:#ccd9d9; --line:#536f75;
}
.hero {background:radial-gradient(ellipse at 50% 0,#f5f8f4 0,transparent 65%),var(--surface)}
[data-theme=dark] .hero {background:radial-gradient(ellipse at 50% 0,#395861 0,transparent 65%),var(--surface)}
.hero-intro {padding-block:clamp(22px,3.4vh,44px) 20px}
.hero-location {margin-bottom:12px}
.header-contact,.btn.glass,.hotspot,.photo-expand,.lab-stages button,.anniversary {
  box-shadow:var(--studio-rim);backdrop-filter:blur(12px) saturate(1.18)
}
.btn.glass {background:linear-gradient(145deg,#f8ffff40,#8eabaa1a)}
.btn.accent {box-shadow:inset 0 1px 0 #ddfbffb5,0 3px 11px #137d8d21}

.model-lab,.contact {background:linear-gradient(130deg,#365961,#29474f)}
[data-theme=dark] :is(.model-lab,.contact) {background:linear-gradient(125deg,#304d56,#203b44)}
.form-card {padding:clamp(16px,2.2vw,33px);border:1px solid #daeff132;border-radius:20px;background:linear-gradient(145deg,#d9f8fa14,#ecfbff06);box-shadow:var(--studio-rim)}
.form-card :is(input,textarea,select){background-color:#29454c;border-color:#6d888e}
.project-study {--edge:calc(var(--inset, var(--matte, 0%)) + clamp(12px,2.8vw,46px));}
.project-study .model-area,.project-study .model-switch {display:none}
.project-study[data-model-ready=true] .model-switch {display:flex}
.project-study[data-model-ready=true][data-view=modelo] .model-area {display:block}
.project-study[data-view=modelo] > :is(picture,figcaption,.scene-detail,.photo-expand) {display:none}
.model-area {position:absolute;inset:0;color:#11393f;background:radial-gradient(ellipse at 42% 17%,#edf2e9 0%,#d2e0d9 46%,#a5bcbc 100%);}
[data-theme=dark] .model-area {background:radial-gradient(ellipse at 42% 17%,#b9cacc 0%,#8ea7aa 55%,#708b90 100%)}
.model-surface {position:absolute;inset:22px var(--edge) 40px}
.model-surface canvas {display:block;width:100%;height:100%;cursor:grab;touch-action:pan-y}
.model-surface canvas:active {cursor:grabbing}
.model-surface canvas:focus-visible {outline-offset:-4px;border-radius:18px}
.model-switch,.model-layers,.model-orbit {
  border-radius:32px;padding:4px;align-items:center;gap:2px;background:#e9f3efed;
  border:1px solid #ffffffa8;color:#193b42;box-shadow:var(--studio-rim),0 4px 20px #183c441c;
}
@supports(backdrop-filter:blur(14px)){
  .model-switch,.model-layers,.model-orbit {background:linear-gradient(148deg,#f7fff1d9,#d8eaeaaf);backdrop-filter:blur(16px) saturate(1.4)}
}
.model-switch {position:absolute;right:var(--edge);top:clamp(10px,2vw,25px);z-index:2}
.model-switch button,.model-tools button {display:inline-flex;align-items:center;justify-content:center;gap:.33em;min-height:40px;padding:6px 13px;border-radius:30px;background:transparent;color:inherit;font-size:.9rem;transition:background .18s,color .18s}
.model-switch button:hover,.model-tools button:hover {background:#fff9}
.model-switch button[aria-pressed=true],.model-layers button[aria-pressed=true] {background:linear-gradient(140deg,#35575d,#183e47);color:white;box-shadow:var(--studio-rim)}
.model-dock {position:absolute;inset:auto var(--edge) clamp(11px,1.7vw,24px);display:flex;justify-content:space-between;align-items:center;gap:12px;pointer-events:none}
.model-tools,.model-layers,.model-orbit,.model-key {display:flex;align-items:center}
.model-tools {gap:8px;pointer-events:auto}
.model-key {color:#103940;gap:9px;font-size:.85rem;line-height:1.1;background:#e9f3efd9;padding:7px 12px;border-radius:24px}
.model-rule {width:20px;height:2px;background:#167a87}
.model-orbit button {width:40px;padding:0}
@media(max-width:680px){
  .hero-intro {padding:24px 0 15px}
  .model-switch {top:10px}
  .model-surface {inset:44px .7rem 65px}
  .model-dock {flex-wrap:wrap;justify-content:center;gap:6px;bottom:10px}
  .model-key {position:absolute;bottom:calc(100% + 5px);font-size:.75rem;padding:4px 9px}
  .model-switch button,.model-tools button {min-height:39px;padding:4px 9px;font-size:.85rem}
  .model-orbit button {width:34px;padding:0}
  .model-tools {gap:4px}
  .project-study {--edge:calc(var(--inset,var(--matte,0%)) + 7px)}
}
@media(prefers-reduced-motion:reduce){.model-switch button,.model-tools button {transition:none}}
@media(min-width:681px){.hero-track{--frame-h:clamp(340px,55svh,660px)}}

:is(.model-switch,.model-layers,.model-orbit) {
  border:1px solid #ffffffe8;border-bottom-color:#91adb1c9;
  background:linear-gradient(161deg,#fffffff5 0%,#f7ffffb8 16%,#ffffff5e 38%,#c6dde1a6 59%,#ffffffdb 100%);
  box-shadow:inset 1px 2px 2px #ffffffeb,inset -1px -2px 3px #4a757954,0 6px 15px #14464a33,0 0 0 1px #78979b52;
  backdrop-filter:blur(14px) saturate(1.65);
}
.project-study[data-view=foto] .model-switch {background:linear-gradient(158deg,#fffffff2,#effffff0 21%,#dbe8e8c9 48%,#ffffffd6)}
.model-switch button[aria-pressed=true],.model-layers button[aria-pressed=true],.model-tools [data-zoom][aria-pressed=true] {
  color:white;background:linear-gradient(170deg,#75949a 0%,#3b636b 20%,#19434b 54%,#285c64 85%,#4a7378);
  box-shadow:inset 0 1px 1px #f3ffffd9,inset 0 -1px 2px #00252c9c,0 2px 3px #0a393e33;
}
.btn.glass,.header-contact,.form-card {
  background-image:linear-gradient(145deg,#ffffff36,transparent 23%,#e9ffff09 62%,#e4ffff2d);
  box-shadow:inset 1px 1px 1px #ffffff9c,inset -1px -1px 1px #e3ffff60,0 4px 12px #163a441c;
  border-color:#9cb9bb;
}

@media(max-width:450px){
 .model-switch button {font-size:.8rem;padding-inline:7px}
 .model-switch {gap:0}
 .model-tools {gap:3px}.model-tools button {padding-inline:7px}
 .model-orbit button {width:31px;padding-inline:0}
}

.project-study.revealing-model[data-view=modelo] > picture {
  display:block;position:absolute;inset:0;z-index:1;pointer-events:none;
  animation:fachada-a-maqueta 280ms ease-out both;
}
@keyframes fachada-a-maqueta {to{opacity:0}}
.orbit-hint {
  position:absolute;z-index:1;top:49%;left:50%;transform:translate(-50%,-50%);
  display:flex;align-items:center;gap:.45rem;padding:.55rem .95rem;white-space:nowrap;
  border:1px solid #deffffab;border-radius:2rem;color:white;background:#1c414ae8;
  box-shadow:inset 0 1px 1px #fff7,0 3px 14px #18333d39;pointer-events:none;
  font-size:.94rem;
}
@media(prefers-reduced-motion:no-preference){
  .orbit-hint:not([hidden]) .mi{animation:giro-sugerido 500ms ease-in-out}
}
@keyframes giro-sugerido{0%{transform:translateX(-3px) rotate(-9deg)}70%{transform:translateX(3px) rotate(9deg)}}
