/* ============================================================
   ATTIA CAPITAL — Design System
   Premium · Minimal · Apple-inspired
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Literata:ital,wght@0,300;0,400;0,500;0,600;1,300;1,400&family=Plus+Jakarta+Sans:wght@300;400;500;600;700&display=swap');

/* ── CSS Variables ─────────────────────────────────────────── */
:root {
  color-scheme: light;

  /* Brand */
  --clr-primary:   #0F1821;
  --clr-secondary: #5E6064;
  --clr-tertiary:  #8C7E6A;
  --clr-neutral:   #E4E1DB;

  /* Light mode surfaces */
  --bg:          #FAFAF8;
  --bg-surface:  #FFFFFF;
  --bg-raised:   #F2F0EC;
  --tx:          #0F1821;
  --tx-2:        #5E6064;
  --tx-3:        #8C7E6A;
  --border:      rgba(15, 24, 33, 0.10);
  --border-sub:  rgba(15, 24, 33, 0.06);

  /* Buttons */
  --btn-bg:      #0F1821;
  --btn-tx:      #FAFAF8;
  --btn-bg-h:    #1c2f42;

  /* Typography */
  --ff-head: 'Literata', Georgia, 'Times New Roman', serif;
  --ff-body: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;

  /* Type scale (fluid) */
  --fs-2xs:  0.6875rem;   /* 11px */
  --fs-xs:   0.75rem;     /* 12px */
  --fs-sm:   0.875rem;    /* 14px */
  --fs-base: 1rem;        /* 16px */
  --fs-md:   1.125rem;    /* 18px */
  --fs-lg:   1.375rem;    /* 22px */
  --fs-xl:   1.75rem;     /* 28px */
  --fs-2xl:  2.25rem;     /* 36px */
  --fs-3xl:  3rem;        /* 48px */
  --fs-4xl:  3.75rem;     /* 60px */
  --fs-5xl:  4.75rem;     /* 76px */

  /* Spacing */
  --sp-1:  4px;
  --sp-2:  8px;
  --sp-3:  12px;
  --sp-4:  16px;
  --sp-5:  20px;
  --sp-6:  24px;
  --sp-8:  32px;
  --sp-10: 40px;
  --sp-12: 48px;
  --sp-16: 64px;
  --sp-20: 80px;
  --sp-24: 96px;
  --sp-32: 128px;

  /* Layout */
  --nav-h:        68px;
  --max-w:        1160px;
  --px:           clamp(20px, 5.5vw, 72px);
  --section-py:   clamp(80px, 11vw, 148px);
  --gap:          clamp(14px, 2vw, 28px);

  /* Radii */
  --r-sm:   8px;
  --r-md:   14px;
  --r-lg:   20px;
  --r-xl:   28px;
  --r-full: 9999px;

  /* Shadows */
  --sh-sm:  0 1px 3px rgba(15,24,33,.05), 0 1px 2px rgba(15,24,33,.04);
  --sh-md:  0 4px 18px rgba(15,24,33,.08), 0 2px 8px rgba(15,24,33,.05);
  --sh-lg:  0 8px 36px rgba(15,24,33,.11), 0 4px 14px rgba(15,24,33,.07);
  --sh-xl:  0 20px 64px rgba(15,24,33,.15);

  /* Transitions */
  --t-fast:   120ms cubic-bezier(0.4,0,0.2,1);
  --t-base:   200ms cubic-bezier(0.4,0,0.2,1);
  --t-slow:   360ms cubic-bezier(0.4,0,0.2,1);
  --t-spring: 420ms cubic-bezier(0.34,1.56,0.64,1);
}

/* ── Dark Mode ─────────────────────────────────────────────── */
[data-theme="dark"] {
  color-scheme: dark;

  --bg:         #0F1821;
  --bg-surface: #141e28;
  --bg-raised:  #192432;
  --tx:         #E4E1DB;
  --tx-2:       #9A9791;
  --tx-3:       #8C7E6A;
  --border:     rgba(228,225,219,.10);
  --border-sub: rgba(228,225,219,.05);

  --btn-bg:   #E4E1DB;
  --btn-tx:   #0F1821;
  --btn-bg-h: #ccc9c3;

  --sh-sm:  0 1px 3px rgba(0,0,0,.25);
  --sh-md:  0 4px 18px rgba(0,0,0,.38);
  --sh-lg:  0 8px 36px rgba(0,0,0,.50);
  --sh-xl:  0 20px 64px rgba(0,0,0,.62);
}

/* ── Reset ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--ff-body);
  font-size: var(--fs-base);
  font-weight: 400;
  line-height: 1.65;
  color: var(--tx);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background 280ms ease, color 280ms ease;
}

img, svg, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }
address { font-style: normal; }

/* ── Scroll offset for fixed nav ───────────────────────────── */
section[id], div[id] {
  scroll-margin-top: var(--nav-h);
}

/* ── Utilities ─────────────────────────────────────────────── */
.section-wrap {
  width: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--px);
}

.eyebrow {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--tx-3);
  margin-bottom: var(--sp-4);
}
.eyebrow::before {
  content: '';
  display: block;
  width: 20px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}

.section-title {
  font-family: var(--ff-head);
  font-size: clamp(var(--fs-2xl), 4.2vw, var(--fs-4xl));
  font-weight: 400;
  line-height: 1.12;
  letter-spacing: -.028em;
  color: var(--tx);
  margin-bottom: var(--sp-5);
}

.section-sub {
  font-size: var(--fs-md);
  color: var(--tx-2);
  line-height: 1.72;
  max-width: 540px;
  margin-bottom: 0;
}

.section-header { margin-bottom: var(--sp-16); }

/* ── Reveal animation ──────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition:
    opacity  .55s cubic-bezier(0.22,1,0.36,1),
    transform .55s cubic-bezier(0.22,1,0.36,1);
}
.reveal.in {
  opacity: 1;
  transform: translateY(0);
}
/* Natural stagger — intervals grow slightly for an organic feel */
.reveal:nth-child(2) { transition-delay: .07s; }
.reveal:nth-child(3) { transition-delay: .15s; }
.reveal:nth-child(4) { transition-delay: .24s; }
.reveal:nth-child(5) { transition-delay: .34s; }
.reveal:nth-child(6) { transition-delay: .45s; }

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  padding: 13px 26px;
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  letter-spacing: .02em;
  border-radius: var(--r-full);
  border: 1.5px solid transparent;
  transition: background 180ms ease, border-color 180ms ease,
              color 180ms ease, transform 220ms cubic-bezier(0.34,1.56,0.64,1),
              box-shadow 220ms ease;
  white-space: nowrap;
  cursor: pointer;
}

.btn--solid {
  background: var(--btn-bg);
  color: var(--btn-tx);
  border-color: var(--btn-bg);
}
.btn--solid:hover {
  background: var(--btn-bg-h);
  border-color: var(--btn-bg-h);
  transform: translateY(-2px);
  box-shadow: var(--sh-md);
}
.btn--solid:active { transform: translateY(0); }

.btn--outline {
  background: transparent;
  color: var(--tx);
  border-color: var(--border);
}
.btn--outline:hover {
  background: var(--bg-raised);
  border-color: var(--tx-2);
  transform: translateY(-2px);
}

.btn--full { width: 100%; }

/* ── Navigation ────────────────────────────────────────────── */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 900;
  height: var(--nav-h);
  background: rgba(10, 16, 24, 0.18); /* subtle tint over hero video */
  transition: background var(--t-base), box-shadow var(--t-base), backdrop-filter var(--t-base);
}
.nav.scrolled {
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
  box-shadow: 0 1px 0 var(--border);
}

/* Nav links always white over video (hero zone) — solo desktop */
@media (min-width: 769px) {
  .nav:not(.scrolled) .nav__logo,
  .nav:not(.scrolled) .nav__link {
    color: rgba(255,255,255,0.88);
  }
  .nav:not(.scrolled) .nav__link:hover {
    color: #fff;
  }
  .nav:not(.scrolled) .nav__link.nav__cta {
    color: #fff;
    border-color: rgba(255,255,255,0.45);
    background: rgba(255,255,255,0.1);
  }
  .nav:not(.scrolled) .nav__link.nav__cta:hover {
    background: rgba(255,255,255,0.22);
    border-color: rgba(255,255,255,0.7);
  }
}

/* Theme btn y logo blancos sobre video (todos los tamaños) */
.nav:not(.scrolled) .theme-btn {
  color: rgba(255,255,255,0.75);
  background: rgba(255,255,255,0.1);
  border-color: rgba(255,255,255,0.2);
}
.nav:not(.scrolled) .theme-btn:hover {
  color: #fff;
  background: rgba(255,255,255,0.2);
}

.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
  max-width: var(--max-w);
  margin-inline: auto;
  padding-inline: var(--px);
}

.nav__logo {
  display: flex;
  align-items: center;
  transition: opacity var(--t-fast);
}
.nav__logo:hover { opacity: .78; }

.nav__logo-img {
  height: 28px;
  width: auto;
  display: block;
  transition: opacity var(--t-base);
}

/* Sobre el video (nav sin scroll): mostrar logo claro */
.nav:not(.scrolled) .nav__logo-img--dark  { display: none; }
.nav:not(.scrolled) .nav__logo-img--light { display: block; }

/* Con scroll en light mode: mostrar logo oscuro */
.nav.scrolled .nav__logo-img--dark  { display: block; }
.nav.scrolled .nav__logo-img--light { display: none; }

/* Dark mode con scroll: mostrar logo claro */
[data-theme="dark"] .nav.scrolled .nav__logo-img--dark  { display: none; }
[data-theme="dark"] .nav.scrolled .nav__logo-img--light { display: block; }

.nav__menu {
  display: flex;
  align-items: center;
  gap: var(--sp-8);
}

.nav__link {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--tx-2);
  position: relative;
  transition: color var(--t-fast);
}
.nav__link::after {
  content: '';
  position: absolute;
  left: 0; bottom: -3px;
  width: 0; height: 1px;
  background: var(--tx);
  transition: width var(--t-base);
}
.nav__link:hover,
.nav__link.active { color: var(--tx); }
.nav__link:hover::after,
.nav__link.active::after { width: 100%; }

.nav__link.nav__cta {
  color: var(--tx);
  font-weight: 600;
  padding: 7px 18px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-full);
  transition: background var(--t-base), border-color var(--t-base),
              color var(--t-base), transform var(--t-base);
}
.nav__link.nav__cta::after { display: none; }
.nav__link.nav__cta:hover {
  background: var(--tx);
  color: var(--bg);
  border-color: var(--tx);
  transform: translateY(-1px);
}

.nav__controls {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
}

/* Theme toggle */
.theme-btn {
  position: relative;
  width: 40px; height: 40px;
  border-radius: var(--r-full);
  display: flex; align-items: center; justify-content: center;
  color: var(--tx-2);
  background: var(--bg-raised);
  border: 1px solid var(--border);
  transition: background var(--t-base), color var(--t-base), transform var(--t-spring);
}
.theme-btn:hover { color: var(--tx); transform: scale(1.08); }

.theme-btn__sun,
.theme-btn__moon {
  position: absolute;
  transition: opacity var(--t-base), transform var(--t-base);
}
.theme-btn__sun  { opacity: 1; transform: rotate(0deg) scale(1); }
.theme-btn__moon { opacity: 0; transform: rotate(90deg) scale(.6); }
[data-theme="dark"] .theme-btn__sun  { opacity: 0; transform: rotate(-90deg) scale(.6); }
[data-theme="dark"] .theme-btn__moon { opacity: 1; transform: rotate(0deg) scale(1); }

/* Hamburger */
.hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  width: 40px; height: 40px;
  align-items: center; justify-content: center;
  border-radius: var(--r-sm);
  transition: background var(--t-fast);
}
.hamburger:hover { background: var(--bg-raised); }
.hamburger span {
  display: block;
  width: 21px; height: 1.5px;
  background: var(--tx);
  border-radius: 2px;
  transform-origin: center;
  transition: transform var(--t-base), opacity var(--t-base);
}
.hamburger.open span:nth-child(1) { transform: translateY(6.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; transform: scaleX(0); }
.hamburger.open span:nth-child(3) { transform: translateY(-6.5px) rotate(-45deg); }

/* ── Hero ──────────────────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-top: var(--nav-h);
  padding-bottom: clamp(var(--sp-12), 6vw, var(--sp-20));
  padding-inline: var(--px);
  overflow: hidden;
  isolation: isolate;
}

/* Background image */
.hero__bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  z-index: -2;
  pointer-events: none;
  user-select: none;
}

/* Dark gradient overlay for contrast */
.hero__overlay {
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(
    105deg,
    rgba(10, 16, 24, 0.72) 0%,
    rgba(10, 16, 24, 0.48) 55%,
    rgba(10, 16, 24, 0.28) 100%
  );
}

.hero__content {
  position: relative;
  width: 100%;
  max-width: 860px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  z-index: 1;
}

.hero__eyebrow {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: rgba(228, 225, 219, 0.65);
  margin-bottom: var(--sp-6);
}
.hero__eyebrow::before {
  content: '';
  display: block;
  width: 20px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}

.hero__title {
  font-family: var(--ff-head);
  font-size: clamp(2.6rem, 6.5vw, 5.25rem);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -.032em;
  color: #FFFFFF;
  margin-bottom: var(--sp-6);
  text-shadow: 0 2px 32px rgba(10,16,24,0.55), 0 1px 8px rgba(10,16,24,0.4);
}
.hero__title em {
  font-style: italic;
  color: var(--clr-neutral);
  opacity: .85;
}

.hero__sub {
  font-size: clamp(var(--fs-base), 1.6vw, var(--fs-lg));
  color: rgba(228, 225, 219, 0.78);
  line-height: 1.72;
  margin-bottom: var(--sp-8);
  max-width: 520px;
}

/* Bullet list */
.hero__bullets {
  display: flex;
  flex-direction: column;
  gap: var(--sp-3);
  margin-bottom: var(--sp-10);
}

.hero__bullet {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-size: var(--fs-base);
  font-weight: 500;
  color: rgba(228, 225, 219, 0.80);
}
.hero__bullet svg {
  flex-shrink: 0;
  color: var(--clr-neutral);
  opacity: .75;
}

/* Buttons sobre video */
.hero .btn--solid {
  background: #FFFFFF;
  color: var(--clr-primary);
  border-color: #FFFFFF;
}
.hero .btn--solid:hover {
  background: var(--clr-neutral);
  border-color: var(--clr-neutral);
}
.hero .btn--outline {
  color: #FFFFFF;
  border-color: rgba(255,255,255,0.45);
  background: rgba(255,255,255,0.08);
  backdrop-filter: blur(8px);
}
.hero .btn--outline:hover {
  background: rgba(255,255,255,0.18);
  border-color: rgba(255,255,255,0.7);
}

.hero__btns {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3);
}

/* ── Stats ─────────────────────────────────────────────────── */
.stats {
  padding: var(--sp-16) var(--px);
  background: var(--bg-surface);
  border-block: 1px solid var(--border);
}

.stats__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0;
  max-width: var(--max-w);
  margin-inline: auto;
}

.stats__item {
  flex: 1 1 160px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--sp-1);
  padding: var(--sp-6) var(--sp-6);
}

.stats__sep {
  width: 1px;
  height: 52px;
  background: var(--border);
  flex-shrink: 0;
  align-self: center;
}

.stats__row {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 2px;
  line-height: 1;
}

.stats__num {
  font-family: var(--ff-head);
  font-size: clamp(var(--fs-2xl), 3.2vw, var(--fs-3xl));
  font-weight: 500;
  letter-spacing: -.032em;
  color: var(--tx);
}

.stats__pre, .stats__suf {
  font-family: var(--ff-head);
  font-size: clamp(var(--fs-xl), 2.4vw, var(--fs-2xl));
  font-weight: 300;
  color: var(--tx-3);
}

.stats__lbl {
  font-size: var(--fs-xs);
  font-weight: 500;
  color: var(--tx-2);
  letter-spacing: .02em;
}

@media (max-width: 640px) {
  .stats__inner {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
  }
  .stats__sep { display: none; }
  .stats__item {
    padding: var(--sp-6) var(--sp-4);
    border-bottom: 1px solid var(--border);
  }
  .stats__item:nth-child(odd)  { border-right: 1px solid var(--border); }
  .stats__item:nth-last-child(-n+2) { border-bottom: none; }
}

/* ── Value Proposition ─────────────────────────────────────── */
.value {
  padding-block: var(--section-py);
}

.value__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: var(--gap);
}

.value__grid--row {
  grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 900px) {
  .value__grid--row { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .value__grid--row { grid-template-columns: 1fr; }
}

.value-card {
  padding: var(--sp-8);
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  transition: border-color var(--t-base), transform var(--t-base), box-shadow var(--t-base);
}
.value-card:hover {
  border-color: var(--tx-3);
  transform: translateY(-4px);
  box-shadow: var(--sh-md);
}

.value-card__icon {
  width: 44px; height: 44px;
  border-radius: var(--r-md);
  background: var(--bg-raised);
  display: flex; align-items: center; justify-content: center;
  color: var(--tx-3);
  margin-bottom: var(--sp-5);
  transition: background var(--t-base);
}
.value-card:hover .value-card__icon { background: var(--clr-neutral); }
[data-theme="dark"] .value-card:hover .value-card__icon { background: var(--bg-raised); }

.value-card__title {
  font-family: var(--ff-head);
  font-size: var(--fs-lg);
  font-weight: 500;
  letter-spacing: -.02em;
  color: var(--tx);
  line-height: 1.28;
  margin-bottom: var(--sp-3);
}

.value-card__text {
  font-size: var(--fs-sm);
  color: var(--tx-2);
  line-height: 1.72;
}

/* ── Portfolio ─────────────────────────────────────────────── */
.portfolio {
  padding-block: var(--section-py);
  background: var(--bg-raised);
}

.portfolio__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--gap);
}

/* Property card */
.prop-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: transform var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.prop-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh-lg);
  border-color: var(--tx-3);
}
.prop-card--featured { border-color: rgba(140,126,106,.35); }

/* Card image */
.prop-card__img {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--bg-raised);
}
.prop-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .7s cubic-bezier(0.22,1,0.36,1);
}
.prop-card:hover .prop-card__img img {
  transform: scale(1.04);
}

.prop-tag {
  position: absolute;
  top: var(--sp-3);
  left: var(--sp-3);
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #fff;
  background: rgba(15,24,33,.55);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 4px 10px;
  border-radius: var(--r-full);
}

.prop-card__body {
  padding: var(--sp-5) var(--sp-6);
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: var(--sp-4);
}

.prop-card__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--sp-4);
}

.prop-return {
  font-family: var(--ff-head);
  font-size: var(--fs-xl);
  font-weight: 500;
  letter-spacing: -.02em;
  color: var(--tx);
  line-height: 1;
  flex-shrink: 0;
}
.prop-return--done { color: var(--clr-tertiary); }

.prop-name {
  font-family: var(--ff-head);
  font-size: var(--fs-lg);
  font-weight: 500;
  letter-spacing: -.022em;
  color: var(--tx);
  line-height: 1.2;
  margin-bottom: var(--sp-1);
}

.prop-loc {
  display: flex;
  align-items: center;
  gap: var(--sp-1);
  font-size: var(--fs-sm);
  color: var(--tx-3);
  font-weight: 500;
}

.prop-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.prop-units {
  font-size: var(--fs-sm);
  color: var(--tx-2);
}

.prop-badge {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  padding: 3px 10px;
  border-radius: var(--r-full);
}
.prop-badge--active { background: rgba(140,126,106,.12); color: var(--clr-tertiary); }
.prop-badge--done   { background: rgba(94,96,100,.10);  color: var(--tx-2); }

.prop-card__foot {
  padding: var(--sp-3) var(--sp-6) var(--sp-5);
}

.prop-bar {
  height: 3px;
  background: var(--border);
  border-radius: var(--r-full);
  overflow: hidden;
  margin-bottom: var(--sp-2);
}
.prop-bar__fill {
  height: 100%;
  width: 0%;
  background: var(--clr-tertiary);
  border-radius: var(--r-full);
  transition: width 1.2s cubic-bezier(0.22,1,0.36,1) .15s;
}
.prop-bar__fill--done { background: var(--tx-2); }

.prop-return-label {
  font-size: var(--fs-2xs);
  color: var(--tx-3);
  font-weight: 500;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.portfolio__cta {
  margin-top: var(--sp-12);
  text-align: center;
}

/* ── Simulator ─────────────────────────────────────────────── */
.simulator {
  padding-block: var(--section-py);
  background: var(--bg);
}

.simulator__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-16);
  align-items: center;
}

.simulator__desc {
  font-size: var(--fs-base);
  color: var(--tx-2);
  line-height: 1.65;
  margin-top: var(--sp-4);
  margin-bottom: var(--sp-10);
}

/* Controls */
.sim-controls {
  display: flex;
  flex-direction: column;
  gap: var(--sp-8);
}

.sim-control__header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: var(--sp-3);
}

.sim-control__label {
  font-size: var(--fs-2xs);
  font-weight: 600;
  letter-spacing: .08em;
  color: var(--tx-2);
  text-transform: uppercase;
}

.sim-control__val {
  font-family: var(--ff-head);
  font-size: var(--fs-xl);
  font-weight: 500;
  color: var(--tx);
  letter-spacing: -.02em;
}

.sim-control__val--bold {
  font-weight: 600;
}

/* Slider track */
.sim-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 2px;
  background: var(--border);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
  position: relative;
}

.sim-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--tx);
  border: 3px solid var(--bg-surface);
  box-shadow: 0 0 0 1.5px var(--tx), 0 2px 8px rgba(0,0,0,.18);
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}

.sim-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--tx);
  border: 3px solid var(--bg-surface);
  box-shadow: 0 0 0 1.5px var(--tx), 0 2px 8px rgba(0,0,0,.18);
  cursor: pointer;
}

.sim-slider:hover::-webkit-slider-thumb,
.sim-slider:focus::-webkit-slider-thumb {
  transform: scale(1.15);
  box-shadow: 0 0 0 1.5px var(--tx), 0 4px 14px rgba(0,0,0,.22);
}

.sim-control__range {
  display: flex;
  justify-content: space-between;
  margin-top: var(--sp-2);
  font-size: var(--fs-xs);
  color: var(--tx-3);
}

/* Results panel */
.sim-results {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: var(--sp-8) var(--sp-10);
  display: flex;
  flex-direction: column;
}

.sim-result {
  padding-block: var(--sp-6);
  border-bottom: 1px solid var(--border);
}

.sim-result:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.sim-result:first-child { padding-top: 0; }

.sim-result__label {
  font-size: var(--fs-2xs);
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--tx-2);
  margin-bottom: var(--sp-2);
}

.sim-result__value {
  font-family: var(--ff-head);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  font-weight: 500;
  color: var(--tx);
  letter-spacing: -.03em;
  line-height: 1.1;
  margin-bottom: var(--sp-1);
  transition: color .3s;
}

.sim-result--total .sim-result__value {
  color: var(--clr-tertiary);
  font-size: clamp(1.8rem, 3.5vw, 2.6rem);
}

.sim-result__desc {
  font-size: var(--fs-xs);
  color: var(--tx-3);
}

@media (max-width: 900px) {
  .simulator__grid {
    grid-template-columns: 1fr;
    gap: var(--sp-10);
  }
  .sim-results { padding: var(--sp-6) var(--sp-6); }
}

/* ── Process ───────────────────────────────────────────────── */
.process {
  padding-top: var(--sp-10);
  padding-bottom: var(--section-py);
}

.process > .section-wrap {
  border-top: 1px solid var(--border);
  padding-top: var(--sp-10);
}

.process__steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: var(--sp-12) var(--sp-10);
}

.process__step { display: flex; flex-direction: column; gap: var(--sp-4); }

.process__num {
  font-family: var(--ff-head);
  font-size: clamp(3rem, 5vw, 5rem);
  font-weight: 300;
  letter-spacing: -.04em;
  color: var(--border);
  line-height: 1;
  transition: color var(--t-slow);
}
.process__step:hover .process__num { color: var(--tx-3); }

.process__title {
  font-family: var(--ff-head);
  font-size: var(--fs-lg);
  font-weight: 500;
  letter-spacing: -.02em;
  color: var(--tx);
  line-height: 1.28;
}

.process__text {
  font-size: var(--fs-sm);
  color: var(--tx-2);
  line-height: 1.76;
}

/* ── Team Carousel ─────────────────────────────────────────── */
.team {
  padding-block: var(--section-py);
  background: var(--bg-raised);
}

.team__carousel-wrap { position: relative; }

.team__carousel {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap);
  overflow: hidden;
}

/* Each card is always rendered; JS controls which 3 are visible */
.team-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  overflow: hidden;
  transition: transform var(--t-base), box-shadow var(--t-base), border-color var(--t-base);
}
.team-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh-md);
  border-color: var(--tx-3);
}
.team-card.hidden { display: none; }

.team-card__photo {
  width: 100%;
  aspect-ratio: 3/ 4;
  overflow: hidden;
  background: var(--bg-raised);
}
.team-card__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  transition: transform .7s cubic-bezier(0.22,1,0.36,1);
}
.team-card:hover .team-card__photo img { transform: scale(1.03); }

.team-card__info {
  padding: var(--sp-5) var(--sp-6);
  display: flex;
  flex-direction: column;
  gap: var(--sp-1);
}

.team-card__name {
  font-family: var(--ff-head);
  font-size: var(--fs-lg);
  font-weight: 500;
  color: var(--tx);
  letter-spacing: -.018em;
  line-height: 1.25;
}

.team-card__role {
  font-size: var(--fs-xs);
  color: var(--tx-3);
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.team-card__bio {
  font-size: var(--fs-sm);
  color: var(--tx-2);
  line-height: 1.6;
  margin-top: var(--sp-3);
  padding-top: var(--sp-3);
  border-top: 1px solid var(--border);
}

/* Carousel controls */
.team__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-5);
  margin-top: var(--sp-8);
}

.carousel-btn {
  width: 44px; height: 44px;
  border-radius: var(--r-full);
  border: 1.5px solid var(--border);
  background: var(--bg-surface);
  color: var(--tx-2);
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  transition: all var(--t-base);
}
.carousel-btn:hover {
  background: var(--tx);
  color: var(--bg);
  border-color: var(--tx);
  transform: scale(1.06);
}
.carousel-btn:disabled {
  opacity: .3;
  cursor: not-allowed;
  transform: none;
}

.carousel-dots {
  display: flex;
  gap: var(--sp-2);
  align-items: center;
}
.carousel-dot {
  width: 7px; height: 7px;
  border-radius: var(--r-full);
  background: var(--border);
  border: none;
  cursor: pointer;
  transition: all var(--t-base);
  padding: 0;
}
.carousel-dot.active {
  background: var(--tx);
  width: 22px;
}

@media (max-width: 640px) {
  .team__carousel { grid-template-columns: 1fr; }
}

/* ── Partners ──────────────────────────────────────────────── */
.partners {
  padding-block: var(--section-py);
}

.partners__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: var(--gap);
}

.partner-card {
  padding: var(--sp-8);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  transition: border-color var(--t-base), background var(--t-base), transform var(--t-base), box-shadow var(--t-base);
}
.partner-card:hover {
  border-color: var(--tx-3);
  background: var(--bg-surface);
  transform: translateY(-3px);
  box-shadow: var(--sh-sm);
}

.partner-card__logo {
  font-family: var(--ff-head);
  font-size: var(--fs-xl);
  font-weight: 500;
  letter-spacing: -.022em;
  color: var(--tx);
  line-height: 1.2;
  margin-bottom: var(--sp-3);
}

.partner-card__desc {
  font-size: var(--fs-sm);
  color: var(--tx-2);
  line-height: 1.68;
}

/* ── Contact ───────────────────────────────────────────────── */
.contact {
  padding-block: var(--section-py);
  background: var(--bg-raised);
}

.contact__grid {
  display: grid;
  gap: var(--sp-16);
}
@media (min-width: 860px) {
  .contact__grid {
    grid-template-columns: 1fr 1fr;
    gap: var(--sp-20);
    align-items: start;
  }
}

.contact__sub {
  font-size: var(--fs-md);
  color: var(--tx-2);
  line-height: 1.72;
  max-width: 420px;
  margin-bottom: var(--sp-10);
}

.contact__details { display: flex; flex-direction: column; }

.contact__row {
  display: flex;
  align-items: baseline;
  gap: var(--sp-4);
  padding-block: var(--sp-4);
  border-bottom: 1px solid var(--border-sub);
  transition: opacity var(--t-fast);
}
.contact__row:hover { opacity: .75; }

.contact__lbl {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--tx-3);
  min-width: 58px;
}

.contact__val {
  font-size: var(--fs-sm);
  font-weight: 500;
  color: var(--tx);
}

/* ── Form ──────────────────────────────────────────────────── */
.contact__right {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--r-xl);
  padding: clamp(var(--sp-8), 5vw, var(--sp-12));
  box-shadow: var(--sh-md);
}

.form {
  display: flex;
  flex-direction: column;
  gap: var(--sp-5);
}

.form__group {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
}

.form__label {
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: .07em;
  text-transform: uppercase;
  color: var(--tx-3);
}
.form__label span { color: var(--clr-tertiary); }

.form__input,
.form__select {
  width: 100%;
  padding: 12px 15px;
  font-family: var(--ff-body);
  font-size: var(--fs-sm);
  color: var(--tx);
  background: var(--bg-raised);
  border: 1.5px solid var(--border);
  border-radius: var(--r-md);
  outline: none;
  transition: border-color var(--t-fast), background var(--t-fast), box-shadow var(--t-fast);
  appearance: none;
  -webkit-appearance: none;
}
.form__input::placeholder { color: var(--tx-3); opacity: .7; }
.form__input:focus,
.form__select:focus {
  border-color: var(--tx-3);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(140,126,106,.14);
}
.form__input.invalid { border-color: #c0392b; }
.form__error {
  font-size: var(--fs-xs);
  color: #c0392b;
  display: none;
}
.form__error.show { display: block; }

.form__select-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.form__select { flex: 1; padding-right: 38px; cursor: pointer; }
.form__chevron {
  position: absolute;
  right: 13px;
  color: var(--tx-3);
  pointer-events: none;
  flex-shrink: 0;
}

/* Spinner icon spin animation */
.btn__spinner svg { animation: spin .9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.form__disclaimer {
  font-size: var(--fs-xs);
  color: var(--tx-3);
  line-height: 1.6;
  text-align: center;
}

/* ── Footer ────────────────────────────────────────────────── */
.footer {
  background: var(--clr-primary);
  padding: var(--sp-16) var(--px) var(--sp-10);
}
[data-theme="dark"] .footer { background: #07111a; }

.footer__inner {
  max-width: var(--max-w);
  margin-inline: auto;
}

.footer__top {
  display: flex;
  flex-direction: column;
  gap: var(--sp-10);
  padding-bottom: var(--sp-10);
  border-bottom: 1px solid rgba(228,225,219,.1);
  margin-bottom: var(--sp-8);
}
@media (min-width: 560px) {
  .footer__top {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }
}

.footer__logo-img {
  display: block;
  height: 24px;
  width: auto;
  margin-bottom: var(--sp-3);
  opacity: .9;
}
.footer__tagline {
  font-size: var(--fs-sm);
  color: rgba(228,225,219,.45);
  line-height: 1.6;
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-3) var(--sp-6);
}
.footer__links a {
  font-size: var(--fs-sm);
  color: rgba(228,225,219,.55);
  transition: color var(--t-fast);
}
.footer__links a:hover { color: var(--clr-neutral); }

.footer__disclaimer {
  font-size: var(--fs-xs);
  color: rgba(228,225,219,.3);
  line-height: 1.68;
  margin-bottom: var(--sp-4);
  max-width: 780px;
}
.footer__copy {
  font-size: var(--fs-xs);
  color: rgba(228,225,219,.35);
}

/* ── FAQ ───────────────────────────────────────────────────── */
.faq {
  padding-top: var(--sp-10);
  padding-bottom: var(--section-py);
  background: var(--bg-raised);
}

.faq > .section-wrap {
  border-top: 1px solid var(--border);
  padding-top: var(--sp-10);
}

.faq__list {
  max-width: 760px;
  margin-inline: auto;
  display: flex;
  flex-direction: column;
  border-top: 1px solid var(--border);
}

.faq__item {
  border-bottom: 1px solid var(--border);
}

.faq__q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-6);
  padding: var(--sp-6) 0;
  font-family: var(--ff-head);
  font-size: var(--fs-lg);
  font-weight: 500;
  color: var(--tx);
  letter-spacing: -.015em;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  transition: color var(--t-fast);
}
.faq__q:hover { color: var(--tx-3); }

.faq__icon {
  flex-shrink: 0;
  color: var(--tx-3);
  transition: transform var(--t-base);
}
.faq__item.open .faq__icon { transform: rotate(180deg); }

.faq__a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 320ms cubic-bezier(0.22,1,0.36,1);
}
.faq__item.open .faq__a {
  grid-template-rows: 1fr;
}

.faq__a-inner {
  overflow: hidden;
  min-height: 0;
  font-size: var(--fs-base);
  color: var(--tx-2);
  line-height: 1.75;
  padding-bottom: 0;
  transition: padding-bottom 320ms cubic-bezier(0.22,1,0.36,1);
}
.faq__item.open .faq__a-inner {
  padding-bottom: var(--sp-6);
}

/* ── Toast ─────────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: var(--sp-8);
  right: var(--sp-8);
  z-index: 9999;
  padding: var(--sp-4) var(--sp-6);
  background: var(--tx);
  color: var(--bg);
  border-radius: var(--r-md);
  font-size: var(--fs-sm);
  font-weight: 500;
  box-shadow: var(--sh-xl);
  max-width: 320px;
  opacity: 0;
  transform: translateY(12px) scale(.97);
  pointer-events: none;
  transition: opacity 260ms ease, transform 340ms cubic-bezier(0.34,1.56,0.64,1);
}
.toast.show {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* ── Mobile Navigation ─────────────────────────────────────── */
@media (max-width: 768px) {

  .hamburger { display: flex; }

  /* Dropdown panel compacto — no cubre toda la pantalla */
  .nav__menu {
    position: fixed;
    top: calc(var(--nav-h) + 8px);
    left: 16px;
    right: 16px;
    bottom: auto;                      /* altura automática, no full screen */
    z-index: 850;

    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: var(--sp-1);

    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--r-xl);
    box-shadow: 0 16px 48px rgba(10,16,24,.18), 0 4px 12px rgba(10,16,24,.10);
    padding: var(--sp-3);

    /* Estado inicial: invisible */
    opacity: 0;
    transform: translateY(-8px) scale(0.98);
    pointer-events: none;
    transform-origin: top center;
    transition: opacity 200ms ease, transform 260ms cubic-bezier(0.22,1,0.36,1);
  }

  [data-theme="dark"] .nav__menu {
    box-shadow: 0 16px 48px rgba(0,0,0,.45), 0 4px 12px rgba(0,0,0,.30);
  }

  .nav__menu.open {
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
  }

  /* Cada ítem de la lista ocupa todo el ancho */
  .nav__menu li { width: 100%; }

  /* Links: compactos, con hover de fondo */
  .nav__link {
    display: block;
    width: 100%;
    text-align: left;
    font-size: var(--fs-sm);
    font-weight: 500;
    color: var(--tx);
    padding: 11px var(--sp-4);
    border-radius: var(--r-md);
    transition: background var(--t-fast), color var(--t-fast);
  }
  .nav__link::after { display: none; }
  .nav__link:hover {
    background: var(--bg-raised);
    color: var(--tx);
  }

  /* Separador visual antes del CTA */
  .nav__menu li:last-child {
    border-top: 1px solid var(--border);
    margin-top: var(--sp-1);
    padding-top: var(--sp-1);
  }

  /* CTA: botón sólido dentro del panel */
  .nav__link.nav__cta {
    display: block;
    width: 100%;
    text-align: center;
    font-size: var(--fs-sm);
    font-weight: 700;
    color: var(--btn-tx);
    background: var(--btn-bg);
    border: 1.5px solid var(--btn-bg);
    border-radius: var(--r-md);
    padding: 11px var(--sp-4);
    transition: background var(--t-base), opacity var(--t-base);
  }
  .nav__link.nav__cta:hover {
    background: var(--btn-bg-h);
    border-color: var(--btn-bg-h);
    color: var(--btn-tx);
    transform: none;
  }

  /* Hamburger: color correcto en cada contexto */
  .hamburger span                              { background: var(--tx); }
  .hamburger.open span                         { background: var(--tx); }
  .nav:not(.scrolled) .hamburger:not(.open) span { background: #fff; }
}

/* ── Hero responsive ───────────────────────────────────────── */
@media (max-width: 600px) {
  .hero__title { font-size: clamp(2.2rem, 9vw, 2.8rem); }
  .hero__sub   { font-size: var(--fs-base); }
  .hero__btns  { flex-direction: column; width: 100%; }
  .hero__btns .btn { width: 100%; justify-content: center; }
}

/* ── Reduced motion ────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}

/* ── Focus visible ─────────────────────────────────────────── */
:focus-visible {
  outline: 2px solid var(--clr-tertiary);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}
