@import "tokens/colors.css";
@import "tokens/typography.css";
@import "tokens/spacing.css";
@import "tokens/fonts.css";

html, body {
  margin: 0;
  background: var(--surface-page);
  color: var(--text-primary);
  font-family: var(--font-body);
}

a { color: var(--color-ink); text-decoration: none; }
a:hover { color: var(--color-mauve-dark); }

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

/* Intro screen — shown on first load, fades out to reveal the page */
#intro-screen {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--color-ivory);
  transition: opacity 700ms ease, visibility 700ms ease;
}
#intro-screen p {
  font-family: 'Personal Vogue', serif;
  font-style: italic;
  font-size: clamp(28px, 5vw, 44px);
  color: var(--color-ink);
  margin: 0;
  padding: 0 24px;
  text-align: center;
}
#intro-screen.intro-hide {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}
body.intro-active {
  overflow: hidden;
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  left: 20px;
  right: 20px;
  bottom: 20px;
  z-index: 9000;
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: opacity 400ms ease, transform 400ms ease, visibility 400ms;
  pointer-events: none;
}
.cookie-banner.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
  pointer-events: auto;
}
.cookie-banner-inner {
  max-width: 720px;
  margin: 0 auto;
  background: rgba(28,33,33,0.96);
  backdrop-filter: blur(14px);
  border-radius: 24px;
  box-shadow: var(--shadow-card);
  padding: 24px 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cookie-banner-inner p {
  font-family: 'Poppins', sans-serif;
  font-size: 14px;
  line-height: 1.6;
  color: rgba(238,233,227,0.9);
  margin: 0;
}
.cookie-banner-inner a {
  color: var(--color-blush);
  text-decoration: underline;
}
.cookie-banner-actions {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.cookie-btn {
  font-family: 'Poppins', sans-serif;
  font-weight: 600;
  font-size: 14px;
  border-radius: 999px;
  padding: 12px 22px;
  cursor: pointer;
  border: 1px solid transparent;
}
.cookie-btn-solid {
  background: var(--color-ivory);
  color: var(--color-ink);
}
.cookie-btn-ghost {
  background: transparent;
  color: var(--color-ivory);
  border-color: rgba(238,233,227,0.4);
}
@media (max-width: 600px) {
  .cookie-banner { left: 12px; right: 12px; bottom: 12px; }
  .cookie-banner-inner { padding: 20px; }
}

@media (prefers-reduced-motion: no-preference) {
  [data-reveal] {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 700ms cubic-bezier(0.22,1,0.36,1), transform 700ms cubic-bezier(0.22,1,0.36,1);
  }
  [data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Nav — single floating pill, expands into a link pill below on click */
.nav-menu-trigger {
  display: flex;
  align-items: center;
  gap: 10px;
  background: none;
  border: none;
  cursor: pointer;
  font-family: 'Personal Vogue', serif;
  font-size: 20px;
  color: var(--color-ink);
  padding: 4px;
}
.nav-menu-trigger .icon-x { display: none; }
.nav-menu.is-open .nav-menu-trigger .icon-menu { display: none; }
.nav-menu.is-open .nav-menu-trigger .icon-x { display: block; }

.nav-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  transform: translate(-50%, -6px);
  background: rgba(238,233,227,0.92);
  backdrop-filter: blur(14px);
  border-radius: 999px;
  box-shadow: var(--shadow-card);
  padding: 8px;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 200ms ease, transform 200ms ease, visibility 200ms;
}
.nav-menu.is-open .nav-dropdown,
.nav-menu:focus-within .nav-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translate(-50%, 0);
  pointer-events: auto;
}
.nav-dropdown a {
  font-family: 'Poppins', sans-serif;
  font-size: 15px;
  font-weight: 500;
  color: var(--color-ink);
  padding: 12px 18px;
  border-radius: 999px;
}
.nav-dropdown a:hover {
  background: rgba(28,33,33,0.06);
  color: var(--color-ink);
}
@media (max-width: 600px) {
  .nav-dropdown { flex-direction: column; align-items: stretch; }
}

/* Hero — full-bleed video, no side padding */
.hero-bleed {
  width: 100%;
  position: relative;
  overflow: hidden;
  background: var(--color-ink);
  min-height: 720px;
}
.hero-bleed video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Escritorio — shared parallax photo behind "Quiénes somos" + cita + P.D., not cropped between sections */
.photo-band {
  position: relative;
  overflow: hidden;
  background: var(--color-ink);
}
.photo-band-img {
  position: absolute;
  top: -22%;
  left: 0;
  width: 100%;
  height: 144%;
  background-size: cover;
  background-position: center;
  z-index: 0;
  will-change: transform;
}
.photo-band-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(28,33,33,0.74) 0%, rgba(28,33,33,0.58) 45%, rgba(28,33,33,0.58) 65%, rgba(28,33,33,0.78) 100%);
}
.photo-band > section {
  position: relative;
  z-index: 2;
}
.quote-overlap {
  margin-top: -64px;
  border-radius: 40px 40px 0 0;
}

/* Shelf — next section overlaps the hero's bottom edge with a rounded lid */
.shelf {
  position: relative;
  z-index: 2;
  margin-top: -40px;
  border-radius: 40px 40px 0 0;
  background: var(--surface-page);
}

/* Ansiedad — full-bleed photo with floating stat pills */
.stat-bleed {
  width: 100%;
  position: relative;
  overflow: hidden;
  min-height: 480px;
  background: var(--color-ink);
}
.stat-bleed img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* Velo: apaga un poco la foto (más hacia abajo) para que las barras se lean */
.stat-veil {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(28,33,33,0.12) 0%, rgba(28,33,33,0.24) 42%, rgba(28,33,33,0.58) 100%);
}
.stat-bars {
  position: absolute;
  z-index: 2;
  left: 24px;
  right: 24px;
  bottom: 24px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: 640px;
  margin-left: auto;
}
.stat-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  backdrop-filter: blur(10px);
  border-radius: 999px;
  padding: 16px 24px;
  font-family: 'Poppins', sans-serif;
  color: #EEE9E3;
}
.stat-bar .stat-label { font-size: 15px; font-weight: 500; }
.stat-bar .stat-value { font-size: 15px; font-weight: 700; }
@media (max-width: 600px) {
  .stat-bars { left: 16px; right: 16px; bottom: 16px; max-width: none; }
  .stat-bar { padding: 12px 18px; }
}

/* Glow — soft warm-glow gradient on the ivory base, shared by "para quién" and "PD" */
.glow-section {
  background:
    radial-gradient(ellipse 800px 600px at 12% 8%, rgba(163,143,133,0.35), transparent 60%),
    radial-gradient(ellipse 640px 520px at 88% 92%, rgba(210,181,177,0.28), transparent 55%),
    var(--surface-page);
}

/* Cómo trabajamos — photo swaps side on mobile/tablet */
.work-grid {
  display: grid;
  grid-template-columns: 1fr 460px;
  gap: 56px;
  align-items: center;
}
.work-grid .work-photo { order: 2; }
.work-grid .work-text { order: 1; }
@media (max-width: 900px) {
  .work-grid { grid-template-columns: 1fr; gap: 32px; }
  .work-grid .work-photo { order: -1; }
  .work-grid .work-text { order: 0; }
}

/* Para quién es / Team — 2 columns desktop, stacked on mobile */
.who-grid,
.team-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
}
@media (max-width: 900px) {
  .who-grid,
  .team-grid {
    grid-template-columns: 1fr;
  }
  .team-card {
    flex-direction: column;
    text-align: center;
  }
}
