/* =========================================================
   RECORRIDOS VIRTUALES 360° — Grupo Nocito
   Landing independiente. Reutiliza la identidad visual del
   sitio institucional (tipografía Archivo, negro/naranja,
   radios asimétricos, tarjetas oscuras) pero es un proyecto
   aparte, sin dependencias de esa web.
   ========================================================= */

@font-face {
  font-family: 'Archivo';
  src: url('../assets/fonts/Archivo-Variable.ttf') format('truetype-variations'),
       url('../assets/fonts/Archivo-Variable.ttf') format('truetype');
  font-weight: 100 900;
  font-stretch: 62.5% 125%;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Archivo';
  src: url('../assets/fonts/Archivo-Italic-Variable.ttf') format('truetype-variations'),
       url('../assets/fonts/Archivo-Italic-Variable.ttf') format('truetype');
  font-weight: 100 900;
  font-stretch: 62.5% 125%;
  font-style: italic;
  font-display: swap;
}

:root {
  --black: #000000;
  --near-black: #0a0a0a;
  --card-dark: #2b2b2b;
  --card-dark-alt: #333333;
  --white: #ffffff;
  --orange: #ff6a1a;
  --orange-dark: #e35a00;
  --gray-text: #b3b3b3;
  --gray-line: #3a3a3a;

  --font: 'Archivo', 'Segoe UI', Arial, sans-serif;
  --weight-bold: 700;
  --weight-semibold: 600;
  --weight-medium: 500;
  --weight-regular: 400;

  --pad: 120px;
  --header-h: 88px;

  --radius-lg: 28px;
  --radius-md: 16px;
  --radius-sm: 10px;
  --radius-pill: 999px;
}

* { box-sizing: border-box; }
button, input, textarea, select { font-family: inherit; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--black);
  color: var(--white);
  font-family: var(--font);
  font-weight: var(--weight-regular);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
  max-width: 1520px;
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

h1, h2, h3, h4 {
  margin: 0;
  font-weight: var(--weight-bold);
  line-height: 1.08;
  letter-spacing: -0.02em;
}
h2 { font-size: clamp(26px, 3.4vw, 40px); }
section { position: relative; }

@media (max-width: 760px) {
  :root { --pad: 20px; --header-h: 72px; }
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 200;
  background: var(--black);
  border-bottom: 1px solid var(--gray-line);
  height: var(--header-h);
}
.nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 100%;
}
.brand-lockup { display: flex; align-items: center; gap: 12px; }
.logo-mark { width: 36px; height: 36px; flex: none; display: block; }
.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 18px;
  border: 1px solid var(--gray-line);
  border-radius: var(--radius-pill);
  font-size: 13px;
  font-weight: var(--weight-medium);
  transition: border-color .2s ease, background .2s ease, color .2s ease;
  white-space: nowrap;
}
.header-cta:hover { background: var(--white); color: var(--black); border-color: var(--white); }
.nav-actions { display: flex; align-items: center; gap: 12px; }
.header-cta-ghost { border-color: var(--gray-line); color: var(--gray-text); }
.header-cta-ghost:hover { background: var(--white); color: var(--black); border-color: var(--white); }
.header-cta-wa .short { display: none; }
@media (max-width: 560px) {
  .header-cta-wa .long { display: none; }
  .header-cta-wa .short { display: inline; }
  .nav-actions { gap: 8px; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background: var(--black);
  padding: clamp(48px, 7vw, 88px) 0 clamp(56px, 8vw, 96px);
}
.hero::before {
  content: "";
  position: absolute;
  top: -35%;
  left: -15%;
  width: 85%;
  height: 170%;
  background: radial-gradient(50% 50% at 50% 50%, rgba(255,106,26,.30) 0%, rgba(120,45,0,.10) 45%, rgba(0,0,0,0) 72%);
  animation: lavaDrift 22s ease-in-out infinite;
  will-change: transform;
  pointer-events: none;
  z-index: 0;
}
@keyframes lavaDrift {
  0%   { transform: translate(0%, 0%) scale(1); }
  25%  { transform: translate(18%, 14%) scale(1.12); }
  50%  { transform: translate(8%, 30%) scale(0.94); }
  75%  { transform: translate(22%, 6%) scale(1.05); }
  100% { transform: translate(0%, 0%) scale(1); }
}
@media (prefers-reduced-motion: reduce) {
  .hero::before { animation: none; }
}
.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: clamp(28px, 4vw, 56px);
  align-items: center;
}
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: var(--weight-bold);
  letter-spacing: 0.10em;
  text-transform: uppercase;
  color: var(--orange);
  margin-bottom: 20px;
}
.hero-eyebrow .dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 4px rgba(255,106,26,.22);
}
.hero-title {
  font-size: clamp(34px, 4.6vw, 60px);
  opacity: 0;
  animation: heroIn .8s cubic-bezier(.16,1,.3,1) .1s forwards;
}
.hero-title em {
  font-style: normal;
  color: var(--orange);
}
.hero-actions {
  margin-top: 28px;
  display: flex;
  align-items: center;
  gap: 22px;
  flex-wrap: wrap;
  opacity: 0;
  animation: heroIn .8s cubic-bezier(.16,1,.3,1) .22s forwards;
}
@keyframes heroIn {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: translateY(0); }
}
@media (prefers-reduced-motion: reduce) {
  .hero-title, .hero-actions { opacity: 1; animation: none; }
}

.btn-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 15px 26px;
  background: var(--orange);
  color: var(--black);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: -0.01em;
  text-transform: uppercase;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
}
.btn-pill svg { flex: none; transition: transform .3s ease; }
.btn-pill:hover svg { transform: translateY(3px); }

.hero-stats {
  margin-top: 44px;
  display: flex;
  gap: clamp(24px, 4vw, 48px);
  flex-wrap: wrap;
}
.hero-stat-num {
  font-size: clamp(26px, 3vw, 34px);
  font-weight: var(--weight-bold);
  color: var(--white);
  line-height: 1;
}
.hero-stat-label {
  margin-top: 6px;
  font-size: 12px;
  font-weight: var(--weight-medium);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--gray-text);
}

/* Visual: caja con radio asimétrico + pill superpuesto (firma visual del sitio institucional) */
.hero-visual { position: relative; }
.hero-badge-area {
  position: absolute;
  top: 0; left: 0;
  z-index: 3;
  display: inline-flex;
  padding: 12px;
  background: var(--black);
  border-radius: 0 36px 36px 0;
}
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  background: var(--white);
  color: var(--black);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
  border-radius: var(--radius-pill);
}
.hero-badge .ring {
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 2px solid var(--orange);
  border-top-color: transparent;
  animation: spin 2.2s linear infinite;
}
@media (prefers-reduced-motion: reduce) { .hero-badge .ring { animation: none; } }

.hero-photo-box {
  position: relative;
  background: var(--black);
  padding: 12px;
  border-radius: 0 40px 40px 40px;
  overflow: hidden;
  min-height: 380px;
}
.hero-photo-stack {
  position: relative;
  width: 100%;
  height: 100%;
  min-height: 356px;
  border-radius: 0 30px 30px 30px;
  overflow: hidden;
}
.hero-photo-stack img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transition: opacity 1.4s ease;
}
.hero-photo-stack img.active { opacity: 1; }
.hero-photo-stack::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(195deg, rgba(0,0,0,0) 35%, rgba(0,0,0,.55) 68%, rgba(0,0,0,.88) 100%);
}
.hero-photo-caption {
  position: absolute;
  left: 32px;
  right: 32px;
  bottom: 32px;
  z-index: 2;
  font-size: 13px;
  font-weight: var(--weight-semibold);
  letter-spacing: 0.02em;
  text-shadow: 0 2px 10px rgba(0,0,0,.55);
}
.hero-photo-caption span {
  display: block;
  font-size: 11px;
  font-weight: var(--weight-regular);
  color: rgba(255,255,255,.75);
  margin-top: 2px;
}

/* ---------- Controles: tabs de edificio + filtro de ambientes ---------- */
.controls-wrap {
  position: sticky;
  top: var(--header-h);
  z-index: 150;
  background: rgba(10,10,10,.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--gray-line);
}
.controls-row {
  display: flex;
  align-items: center;
  gap: 20px;
  padding-top: 16px;
  padding-bottom: 16px;
  flex-wrap: wrap;
  justify-content: space-between;
}
.tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.tab-btn {
  padding: 9px 16px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--gray-line);
  background: transparent;
  color: var(--gray-text);
  font-size: 13px;
  font-weight: var(--weight-medium);
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
  white-space: nowrap;
}
.tab-btn:hover { border-color: var(--white); color: var(--white); }
.tab-btn.active { background: var(--white); color: var(--black); border-color: var(--white); }

.chip-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.chip-label {
  font-size: 11px;
  font-weight: var(--weight-bold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--gray-text);
  margin-right: 4px;
}
.chip-btn {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--gray-line);
  background: transparent;
  color: var(--white);
  font-size: 12px;
  font-weight: var(--weight-medium);
  cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.chip-btn:hover { border-color: var(--orange); }
.chip-btn.active { background: var(--orange); color: var(--black); border-color: var(--orange); }

.results-count {
  font-size: 12px;
  color: var(--gray-text);
  white-space: nowrap;
}
.results-count strong { color: var(--white); }

@media (max-width: 700px) {
  .controls-row { gap: 12px; }
  .tabs { order: 1; width: 100%; overflow-x: auto; flex-wrap: nowrap; padding-bottom: 2px; }
  .chip-row { order: 2; }
  .results-count { order: 3; }
}

/* ---------- Secciones de edificio ---------- */
.buildings { padding: clamp(48px, 7vw, 88px) 0 clamp(64px, 9vw, 110px); }
.building-block { margin-bottom: clamp(56px, 8vw, 96px); scroll-margin-top: calc(var(--header-h) + 84px); }
.building-block:last-child { margin-bottom: 0; }

.building-index-row {
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-bottom: 20px;
}
.building-index {
  font-size: 13px;
  font-weight: var(--weight-bold);
  color: var(--orange);
  letter-spacing: 0.04em;
}
.building-index-line {
  flex: 1;
  height: 1px;
  background: var(--gray-line);
}

.building-banner {
  position: relative;
  border-radius: 20px;
  overflow: hidden;
  min-height: 300px;
  display: flex;
  align-items: flex-end;
}
.building-banner img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .6s ease;
}
.building-block:hover .building-banner img { transform: scale(1.03); }
.building-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.08) 0%, rgba(0,0,0,.12) 40%, rgba(0,0,0,.72) 72%, rgba(0,0,0,.94) 100%);
}
.building-banner-content {
  position: relative;
  z-index: 2;
  width: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  padding: 28px clamp(20px, 3vw, 40px);
}
.building-brand-pill {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 2;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--white);
  border-radius: 50%;
}
.building-brand-pill svg { width: 100%; height: 100%; padding: 13px; box-sizing: border-box; display: block; }
.building-address {
  font-size: clamp(24px, 3vw, 34px);
  font-weight: var(--weight-bold);
  line-height: 1.05;
  text-shadow: 0 2px 12px rgba(0,0,0,.5);
}
.building-hood {
  font-size: 14px;
  color: rgba(255,255,255,.78);
  margin-top: 2px;
  line-height: 1.3;
  text-shadow: 0 1px 8px rgba(0,0,0,.6);
}
.building-count {
  font-size: 12px;
  font-weight: var(--weight-bold);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--white);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: var(--radius-pill);
  background: rgba(0,0,0,.35);
}

/* ---------- Grilla de unidades ---------- */
.unit-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 14px;
}
@media (max-width: 480px) {
  .unit-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
}

.unit-card {
  position: relative;
  background: var(--card-dark);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  overflow: hidden;
  text-align: left;
  cursor: pointer;
  padding: 0;
  color: var(--white);
  font-family: inherit;
  transition: transform .22s cubic-bezier(.16,1,.3,1), border-color .22s ease, background .22s ease;
}
.unit-card:hover,
.unit-card:focus-visible {
  transform: translateY(-4px);
  border-color: var(--orange);
  background: var(--card-dark-alt);
  outline: none;
}
.unit-card[hidden] { display: none; }

.unit-card-top {
  position: relative;
  padding: 18px 16px 0;
}
.unit-number {
  font-size: 26px;
  font-weight: var(--weight-bold);
  letter-spacing: -0.01em;
  line-height: 1;
}
.unit-360-badge {
  position: absolute;
  top: 14px;
  right: 12px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  border-radius: var(--radius-pill);
  background: rgba(255,106,26,.14);
  border: 1px solid rgba(255,106,26,.4);
  color: var(--orange);
  font-size: 10px;
  font-weight: var(--weight-bold);
  letter-spacing: 0.03em;
}
.unit-360-badge svg { width: 10px; height: 10px; }

.unit-card-bottom {
  margin-top: 16px;
  padding: 12px 16px 16px;
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.unit-rooms {
  font-size: 12px;
  font-weight: var(--weight-medium);
  color: var(--gray-text);
  line-height: 1.3;
}
.unit-go {
  width: 32px; height: 32px;
  flex: none;
  border-radius: 50%;
  border: 1px solid var(--gray-line);
  display: grid;
  place-items: center;
  color: var(--white);
  transition: background .2s ease, border-color .2s ease, color .2s ease, transform .25s ease;
}
.unit-card:hover .unit-go {
  background: var(--orange);
  border-color: var(--orange);
  color: var(--black);
  transform: rotate(45deg);
}

.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: var(--gray-text);
  font-size: 14px;
  border: 1px dashed var(--gray-line);
  border-radius: var(--radius-md);
}
.empty-state[hidden] { display: none; }

/* ---------- Modal visor ---------- */
.viewer-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(12px, 3vw, 32px);
  background: rgba(0,0,0,.86);
  backdrop-filter: blur(8px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}
.viewer-overlay.open { opacity: 1; pointer-events: auto; }

.viewer-modal {
  width: 100%;
  max-width: 1120px;
  background: var(--near-black);
  border: 1px solid var(--gray-line);
  border-radius: 0 32px 32px 32px;
  overflow: hidden;
  transform: translateY(18px) scale(.98);
  transition: transform .32s cubic-bezier(.16,1,.3,1);
}
.viewer-overlay.open .viewer-modal { transform: none; }

.viewer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--gray-line);
}
.viewer-head-info { display: flex; align-items: center; gap: 12px; min-width: 0; }
.viewer-head-title { font-size: 14px; font-weight: var(--weight-bold); white-space: nowrap; }
.viewer-head-sub { font-size: 12px; color: var(--gray-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.viewer-head-actions { display: flex; align-items: center; gap: 10px; flex: none; }

.btn-outline-sm {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 14px;
  border: 1px solid var(--gray-line);
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: var(--weight-medium);
  color: var(--white);
  white-space: nowrap;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.btn-outline-sm:hover { background: var(--orange); border-color: var(--orange); color: var(--black); }

.viewer-close {
  width: 36px; height: 36px;
  border-radius: 50%;
  border: 1px solid var(--gray-line);
  background: none;
  color: var(--white);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: none;
  transition: background .2s ease, border-color .2s ease, transform .2s ease;
}
.viewer-close:hover { background: var(--white); color: var(--black); transform: rotate(90deg); }

.viewer-frame-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  background: #111;
}
.viewer-frame-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.viewer-loading {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--gray-text);
  font-size: 13px;
  transition: opacity .25s ease;
}
.viewer-loading .ring {
  width: 18px; height: 18px;
  border-radius: 50%;
  border: 2px solid var(--gray-line);
  border-top-color: var(--orange);
  animation: spin .8s linear infinite;
}
.viewer-frame-wrap.loaded .viewer-loading { opacity: 0; pointer-events: none; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .viewer-loading .ring { animation: none; } }

@media (max-width: 560px) {
  .viewer-head { flex-wrap: wrap; }
  .viewer-head-actions { width: 100%; justify-content: space-between; }
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--gray-line); padding-top: 56px; }

.footer-top {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1fr 1fr;
  gap: 32px 40px;
  padding-bottom: 44px;
}
@media (max-width: 900px) {
  .footer-top { grid-template-columns: 1fr 1fr; row-gap: 32px; }
}
@media (max-width: 560px) {
  .footer-top { grid-template-columns: 1fr; }
}

.footer-about { display: flex; flex-direction: column; gap: 16px; }
.footer-about .logo-mark { width: 34px; height: 34px; }
.footer-about-text { font-size: 13px; color: var(--gray-text); line-height: 1.6; max-width: 260px; margin: 0; }

.footer-contact-block { display: flex; flex-direction: column; }
.footer-contact-block h4 {
  color: var(--orange);
  font-size: 12px;
  font-weight: var(--weight-bold);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 0 0 16px;
}
.footer-contact-block a,
.footer-contact-block .footer-line {
  font-size: 13px;
  margin-bottom: 8px;
  color: #d8d8d8;
  line-height: 1.4;
}
.footer-contact-block a { text-decoration: underline; text-underline-offset: 3px; width: fit-content; }
.footer-contact-block a:hover { color: var(--orange); }
.footer-contact-block a.footer-phone { font-weight: var(--weight-bold); color: var(--white); text-decoration: none; }
.footer-contact-block a.footer-phone:hover { color: var(--orange); }
.footer-contact-block .footer-line-label { color: var(--gray-text); }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px 24px;
  flex-wrap: wrap;
  padding-top: 22px;
  padding-bottom: 22px;
  border-top: 1px solid var(--gray-line);
  font-size: 12px;
  color: var(--gray-text);
}

/* ---------- WhatsApp flotante ---------- */
.whatsapp-float {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--orange);
  border: 3px solid var(--white);
  color: #fff;
  display: grid;
  place-items: center;
  box-shadow: 0 6px 20px rgba(0,0,0,.4);
  z-index: 400;
  transition: transform .2s ease, box-shadow .2s ease;
}
.whatsapp-float:hover { transform: scale(1.08); box-shadow: 0 8px 26px rgba(0,0,0,.5); }
@media (max-width: 560px) {
  .whatsapp-float { right: 16px; bottom: 16px; width: 50px; height: 50px; }
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .7s cubic-bezier(.16,1,.3,1), transform .7s cubic-bezier(.16,1,.3,1);
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}
