/* =========================================================
   Vision Smart · sistema visual común
   Base: caso de éxito Zittana v49
   ========================================================= */

/* ---------- TOKENS ---------- */
:root {
  --purple: #803b93;       /* violeta */
  --purple-deep: #462051;  /* ciruela */
  --glow: #b389be;         /* orquídea */
  --lila: #e6d8e9;
  --mist: #f5eff6;         /* neblina */
  --black: #0D0D0D;
  --white: #FFFFFF;
  --ink: #171717;
  --muted: #6B6B6B;
  --line: #E5E5E5;
  --line-dark: #2A2A2A;
  --soft: #F2F2F2;
  --danger: #B3261E;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --cut: polygon(0 0, calc(100% - 22px) 0, 100% 22px, 100% 100%, 0 100%);
}

/* ---------- BASE ---------- */
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; width: 100%; }
/* overflow-x va en body, nunca en html (rompe position: sticky) */
body {
  font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--white);
  color: var(--ink);
  overflow-x: hidden;
  width: 100%;
  position: relative;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; display: block; }
a { text-decoration: none; color: inherit; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: var(--ink); }
::selection { background: var(--purple); color: var(--white); }
:focus-visible { outline: 2px solid var(--purple); outline-offset: 3px; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 640px) { .wrap { padding: 0 20px; } }
@media (min-width: 641px) { .nowrap-desktop { white-space: nowrap; } }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: translateY(0); } }

/* ---------- PATRÓN VS ---------- */
.pat-vs {
  background-color: var(--white);
  background-image: url('../img/patron-vs-suave.svg');
  background-size: 400px 280px;
  background-repeat: repeat;
}

/* ---------- BARRA DE PROGRESO ---------- */
#progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0%;
  background: linear-gradient(90deg, var(--purple), var(--glow));
  z-index: 100; transition: width 0.1s linear;
}

/* ---------- NAV ---------- */
header.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,0.97);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  max-width: 1200px; margin: 0 auto; padding: 16px 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav-logo img { height: 44px; width: auto; }
.nav-links { display: flex; gap: 32px; font-size: 14px; font-weight: 500; }
.nav-links a {
  padding: 6px 0; border-bottom: 2px solid transparent; opacity: 0.65;
  transition: opacity 0.2s, color 0.2s, border-color 0.2s;
}
.nav-links a:hover { opacity: 1; }
.nav-links a[aria-current="page"] { opacity: 1; color: var(--purple); border-color: var(--purple); }
.nav-links { align-items: center; }
.nav-links a.nav-cta {
  display: inline-flex; align-items: center; gap: 6px;
  background: var(--purple); color: var(--white); opacity: 1;
  padding: 10px 18px; border-radius: 12px; border: none; font-weight: 700;
  transition: background 0.2s;
}
.nav-links a.nav-cta:hover, .nav-links a.nav-cta[aria-current="page"] { background: var(--purple-deep); color: var(--white); }
.nav-cta .dd { width: 13px; height: 13px; transition: transform 0.25s var(--ease); }
.nav-cta:hover .dd { transform: translateX(4px); }
.nav-toggle { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; margin-right: -10px; }
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  display: block; width: 22px; height: 2px; background: var(--ink); position: relative;
  transition: transform 0.25s var(--ease), background 0.25s;
}
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; }
.nav-toggle span::before { top: -7px; }
.nav-toggle span::after { top: 7px; }
.nav-open .nav-toggle span { background: transparent; }
.nav-open .nav-toggle span::before { transform: translateY(7px) rotate(45deg); }
.nav-open .nav-toggle span::after { transform: translateY(-7px) rotate(-45deg); }
@media (max-width: 900px) {
  .nav-inner { padding: 12px 20px; }
  .nav-logo img { height: 38px; }
  .nav-toggle { display: inline-flex; }
  .nav-links {
    position: absolute; top: 100%; left: 0; right: 0;
    flex-direction: column; gap: 0; padding: 8px 20px 20px;
    background: var(--white); border-bottom: 1px solid var(--line);
    font-size: 17px;
    clip-path: inset(0 0 100% 0); visibility: hidden;
    transition: clip-path 0.4s var(--ease), visibility 0s linear 0.4s;
  }
  .nav-links a { padding: 14px 0; border-bottom: 1px solid var(--line); opacity: 1; }
  .nav-links a:last-child { border-bottom: none; }
  .nav-links a[aria-current="page"] { border-color: var(--line); }
  .nav-links { align-items: stretch; }
  .nav-links a.nav-cta { justify-content: center; margin-top: 14px; padding: 15px 18px; border-bottom: none; }
  .nav-open .nav-links { clip-path: inset(0 0 0 0); visibility: visible; transition: clip-path 0.4s var(--ease); }
}

/* ---------- BOTONES ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 700; font-size: 14.5px; line-height: 1.2; padding: 15px 26px; border-radius: 12px;
  transition: transform 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn-solid { background: var(--purple); color: var(--white); }
.btn-solid:hover { background: var(--purple-deep); }
.btn-ghost { background: var(--white); border: 1.5px solid var(--purple); color: var(--purple); }
.btn-ghost:hover { background: var(--purple); color: var(--white); }
.btn .dd { width: 14px; height: 14px; transition: transform 0.25s var(--ease); }
.btn:hover .dd { transform: translateX(5px); }

/* ---------- ÍCONOS DEL SISTEMA ---------- */
.vs-ico { width: 40px; height: 40px; flex-shrink: 0; }
.vs-ico .acc { fill: var(--lila); transform: translate(2px, 2px); transition: transform 0.35s ease; }
.vs-ico .ln { fill: none; stroke: var(--purple); stroke-width: 2; stroke-linejoin: miter; stroke-miterlimit: 8; }
.vs-ico:hover .acc, .has-ico:hover .vs-ico .acc { transform: translate(0, 0); }

/* ---------- TÍTULOS ---------- */
.eyebrow-line {
  font-size: clamp(20px, 2.8vw, 30px);
  font-weight: 900; line-height: 1.1; letter-spacing: -0.01em;
  text-transform: uppercase; color: var(--ink);
  opacity: 0; animation: rise 0.6s ease-out forwards;
}
h1.hero-title {
  position: relative; display: inline-block;
  font-size: clamp(46px, 7.2vw, 92px);
  font-weight: 900; font-style: italic; line-height: 1.05; letter-spacing: -0.02em;
  text-transform: uppercase; color: var(--purple-deep);
  margin-top: 4px;
  opacity: 0; animation: rise 0.6s ease-out 0.15s forwards;
}
.hero-title .hl { position: relative; display: inline-block; z-index: 1; }
.hero-title .hl::before {
  content: ""; position: absolute; left: -6px; right: -6px; top: 6%; bottom: 6%;
  background: var(--lila); z-index: -1;
  transform: scaleX(0); transform-origin: left;
  animation: sweepIn 0.5s ease-out 0.65s forwards;
}
.hero-title .bracket {
  position: absolute; top: -10px; bottom: -10px; width: 2px; background: var(--ink);
  opacity: 0; animation: bracketIn 0.3s ease-out forwards;
}
.hero-title .bracket.left { left: -14px; animation-delay: 0.55s; }
.hero-title .bracket.right { right: -14px; animation-delay: 0.95s; }
@media (max-width: 640px) {
  .hero-title .bracket.left { left: -8px; }
  .hero-title .bracket.right { right: -8px; }
}
@keyframes sweepIn { to { transform: scaleX(1); } }
@keyframes bracketIn { from { opacity: 0; transform: scaleY(0); } to { opacity: 1; transform: scaleY(1); } }
.hero-sub {
  max-width: 520px; font-size: 17.5px; line-height: 1.6; color: #3a3a3a;
  margin-top: 22px;
  opacity: 0; animation: rise 0.7s ease-out 0.45s forwards;
}
.kicker { font-size: 13px; font-weight: 700; color: var(--purple); margin-bottom: 14px; }
h2.block-title { font-size: clamp(30px, 4vw, 44px); font-weight: 800; letter-spacing: -0.01em; max-width: 760px; line-height: 1.15; }
.block-body { max-width: 660px; font-size: 16.5px; line-height: 1.75; color: var(--muted); margin-top: 22px; }

/* ---------- ENCABEZADO DE PÁGINA INTERNA ---------- */
.page-hero { padding: 72px 0 64px; overflow: hidden; }
.page-hero h1.hero-title { margin-left: 14px; }
@media (max-width: 640px) {
  .page-hero h1.hero-title, .simple-page h1.hero-title { font-size: 40px; }
  .page-hero { padding: 48px 0 44px; }
  .page-hero h1.hero-title { margin-left: 8px; }
}

/* ---------- TARJETA CON ESQUINA CORTADA ---------- */
/* El corte no se combina con border-radius */
.card-cut { background: var(--mist); padding: 28px; clip-path: var(--cut); }

/* ---------- FORMULARIOS ---------- */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; gap: 18px; } }
.field label { display: block; font-size: 14px; font-weight: 500; margin-bottom: 8px; color: var(--ink); }
.field label small { font-weight: 400; color: var(--muted); font-size: 13px; }
.field input, .field textarea {
  display: block; width: 100%;
  font: 400 16px/1.4 'Roboto', sans-serif; color: var(--ink);
  background: var(--white); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px;
  -webkit-appearance: none; appearance: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 150px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: #9a9a9a; }
.field input:hover, .field textarea:hover { border-color: var(--glow); }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--purple); box-shadow: 0 0 0 3px var(--lila); }
.field .err { display: none; font-size: 13px; color: var(--danger); margin-top: 6px; }
.field.invalid input, .field.invalid textarea { border-color: var(--danger); }
.field.invalid .err { display: block; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.form-alert {
  display: none; margin-bottom: 24px; padding: 14px 18px; border-radius: 12px;
  font-size: 14.5px; line-height: 1.5;
  background: #FBEAEA; color: var(--danger); border: 1px solid #F1C4C2;
}
.form-alert.show { display: block; }
.form-actions { margin-top: 28px; }
.form-actions .btn[disabled] { opacity: 0.7; cursor: progress; }

/* ---------- LISTA DE CONTACTO ---------- */
.contact-list { list-style: none; display: grid; gap: 14px; }
.contact-list a { display: inline-flex; align-items: center; gap: 12px; font-size: 15px; color: var(--ink); transition: color 0.2s; }
.contact-list a:hover { color: var(--purple); }
.contact-list svg { width: 22px; height: 22px; flex-shrink: 0; }
.contact-list .ln { fill: none; stroke: var(--purple); stroke-width: 2; stroke-linejoin: miter; }

/* ---------- PÁGINA: CONTACTO ---------- */
.contact-section { padding: 72px 0 110px; }
.contact-grid { display: grid; grid-template-columns: 1.3fr 0.7fr; gap: 64px; align-items: start; }
.contact-aside { display: grid; gap: 36px; }
.contact-aside .card-cut h2 { font-size: 22px; font-weight: 900; line-height: 1.25; color: var(--purple-deep); margin-top: 14px; }
.contact-aside .card-cut p { font-size: 15px; line-height: 1.55; margin: 10px 0 22px; }
@media (max-width: 900px) {
  .contact-section { padding: 48px 0 80px; }
  .contact-grid { grid-template-columns: 1fr; gap: 48px; }
}

/* ---------- PÁGINAS SIMPLES (gracias, 404) ---------- */
.simple-page { min-height: 62vh; display: flex; align-items: center; padding: 80px 0; }
.simple-page .wrap { width: 100%; }
.simple-page h1.hero-title { margin-left: 14px; }
@media (max-width: 640px) { .simple-page h1.hero-title { margin-left: 8px; } }
.simple-page .hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 32px; opacity: 0; animation: rise 0.7s ease-out 0.5s forwards; }

/* ---------- FRANJA DE CIFRAS ---------- */
.stats-band { background: var(--black); color: var(--white); padding: 60px 0 56px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.stat { padding: 0 26px; border-left: 1px solid var(--line-dark); }
.stat:first-child { border-left: none; padding-left: 0; }
.stat-num { font-size: clamp(36px, 4.6vw, 52px); font-weight: 800; color: var(--purple); line-height: 1; transition: transform 0.25s ease; }
.stat:hover .stat-num { transform: scale(1.06); }
.stat-label { font-size: 13.5px; color: #B8B8B8; margin-top: 10px; line-height: 1.4; }
@media (max-width: 860px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 34px 0; }
  .stat { border-left: none; padding: 0 12px; }
  .stat:nth-child(odd) { padding-left: 0; }
}

/* ---------- CÍRCULO DE ACCIÓN ---------- */
.circle-link {
  display: inline-flex; align-items: center; justify-content: space-between; gap: 18px; flex-shrink: 0;
  min-width: 220px; height: 76px; padding: 0 26px;
  background: var(--purple); color: var(--white); font-weight: 700; font-size: 16px; line-height: 1.2;
  clip-path: var(--cut); transition: background 0.3s ease;
}
.circle-link:hover { background: var(--purple-deep); }
.circle-link svg { width: 16px; height: 16px; flex-shrink: 0; transition: transform 0.3s var(--ease); }
.circle-link:hover svg { transform: translateY(4px); }

/* ---------- PÁGINA: SOBRE NOSOTROS ---------- */
.about-hero { padding: 72px 0 80px; overflow: hidden; }
.about-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
.about-grid h1.hero-title { margin-left: 14px; }
.about-grid .block-body { margin-top: 18px; max-width: 560px; }
.about-grid .block-body + .block-body { margin-top: 0; }
.map-card { background: var(--mist); border-radius: 18px; padding: 36px 24px; display: flex; justify-content: center; }
.ar-map { height: min(520px, 62vh); width: auto; overflow: visible; }
.ar-map path { fill: var(--lila); stroke: var(--white); stroke-width: 1.2; stroke-linejoin: round; opacity: 0; }
.ar-map .dot { fill: var(--white); stroke: var(--purple-deep); stroke-width: 2; opacity: 0; transform-box: fill-box; transform-origin: center; }
.ar-map.run .base path, .ar-map.run .hl path { animation: mapIn 0.6s ease forwards; }
.ar-map.run .hl path { animation: mapIn 0.6s ease forwards, mapHi 0.6s ease forwards; animation-delay: 0s, calc(0.9s + var(--i) * 0.4s); }
.ar-map.run .dot { animation: dotIn 0.4s ease forwards, dotPulse 2s ease-in-out infinite; animation-delay: calc(1.25s + var(--d) * 1s), calc(3.2s + var(--d) * 1s); }
@keyframes mapIn { to { opacity: 1; } }
@keyframes mapHi { to { fill: var(--purple); } }
@keyframes dotIn { from { opacity: 0; transform: scale(0); } to { opacity: 1; transform: scale(1); } }
@keyframes dotPulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.35); } }

.about-agency { padding: 110px 0; }
.agency-grid { display: grid; grid-template-columns: 1fr auto; gap: 72px; align-items: center; }
.agency-grid .circle-link { justify-self: start; }
.agency-grid .block-body { margin-top: 18px; }
.agency-grid .block-body.strong { color: var(--ink); font-weight: 500; }
.team-section { background: var(--mist); border-radius: 40px 40px 0 0; padding: 96px 0 110px; scroll-margin-top: 80px; }
.team-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 20px; margin-top: 44px; }
.team-card {
  padding: 1.5px; clip-path: var(--cut);
  background: linear-gradient(var(--purple), var(--purple)) left top / 0% 100% no-repeat, var(--lila);
  transition: background-size 1.1s var(--ease) calc(var(--i, 0) * 0.12s);
}
.team-grid.run .team-card { background-size: 100% 100%, auto; }
.team-inner { height: 100%; background: var(--white); clip-path: polygon(0 0, calc(100% - 21px) 0, 100% 21px, 100% 100%, 0 100%); }
.team-photo { aspect-ratio: 4 / 5; background: var(--lila); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--purple); font-size: 13px; font-weight: 500; overflow: hidden; }
.team-photo svg { width: 30px; height: 30px; }
.team-photo img { width: 100%; height: 100%; object-fit: cover; }
.team-name { font-size: 16px; font-weight: 700; padding: 16px 16px 0; line-height: 1.3; }
.team-role { font-size: 13.5px; font-weight: 500; color: var(--purple); padding: 4px 16px 18px; line-height: 1.35; }
.about-cta { padding: 110px 0; text-align: center; }
.about-cta h2 { font-size: clamp(30px, 4vw, 44px); font-weight: 800; letter-spacing: -0.01em; margin-bottom: 28px; }
@media (max-width: 1100px) { .team-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 900px) {
  .about-hero { padding: 48px 0 60px; }
  .about-grid { grid-template-columns: 1fr; gap: 40px; }
  .map-card { padding: 28px 16px; }
  .ar-map { height: 440px; }
  .about-agency { padding: 80px 0; }
  .agency-grid { grid-template-columns: 1fr; gap: 36px; }
  .circle-link { min-width: 200px; height: 68px; font-size: 15px; }
  .team-section { border-radius: 28px 28px 0 0; padding: 72px 0 80px; }
  .about-cta { padding: 80px 0; }
}
@media (max-width: 640px) {
  .about-grid h1.hero-title { margin-left: 8px; font-size: 40px; }
  .team-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; }
  .team-name { font-size: 14.5px; padding: 12px 12px 0; }
  .team-role { font-size: 12.5px; padding: 3px 12px 14px; }
}

/* ---------- ETIQUETAS DE VALORES ---------- */
.value-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 26px; opacity: 0; animation: rise 0.7s ease-out 0.55s forwards; }
.value-chips span { font-size: 13px; font-weight: 600; padding: 9px 15px; border-radius: 999px; background: var(--soft); border: 1px solid var(--line); color: var(--ink); cursor: default; transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease; }
.value-chips span:hover { background: var(--purple); border-color: var(--purple); color: var(--white); transform: translateY(-3px); }

/* ---------- PÁGINA: SERVICIOS ---------- */
.svc-hero { padding: 72px 0 80px; overflow: hidden; }
.svc-hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
.svc-hero-grid h1.hero-title { margin-left: 14px; }
.svc-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.svc-tile {
  background: var(--mist); clip-path: var(--cut); padding: 24px 22px 22px; min-height: 150px;
  display: flex; flex-direction: column; justify-content: space-between; gap: 18px;
  font-size: 17px; font-weight: 700; color: var(--purple-deep); line-height: 1.25;
  transition: background 0.3s ease, color 0.3s ease;
}
.svc-tile .dd { width: 14px; height: 14px; flex-shrink: 0; transition: transform 0.25s var(--ease); }
.svc-tile span { display: flex; align-items: flex-end; justify-content: space-between; gap: 10px; }
.svc-tile:hover { background: var(--lila); }
.svc-tile:hover .dd { transform: translateX(5px); }
.svc-tile:hover .vs-ico .acc { transform: translate(0, 0); }

.svc-section { background: var(--black); color: var(--white); padding: 110px 0 60px; }
.svc-layout { display: grid; grid-template-columns: 260px 1fr; gap: 80px; align-items: start; }
.svc-nav { position: sticky; top: 110px; }
.svc-nav p { font-size: 13px; font-weight: 700; color: var(--glow); margin-bottom: 16px; }
.svc-nav a {
  display: block; padding: 12px 0 12px 18px; font-size: 15px; font-weight: 500; color: #8A8A8A;
  border-left: 2px solid var(--line-dark); transition: color 0.25s, border-color 0.25s;
}
.svc-nav a:hover { color: var(--white); }
.svc-nav a.on { color: var(--white); font-weight: 700; border-left-color: var(--purple); }
.svc-block { padding-bottom: 64px; margin-bottom: 64px; border-bottom: 1px solid var(--line-dark); scroll-margin-top: 110px; }
.svc-block:last-child { border-bottom: none; margin-bottom: 0; }
.svc-block .vs-ico .acc { fill: var(--purple-deep); }
.svc-block .vs-ico .ln { stroke: var(--glow); }
.svc-block h2 { font-size: clamp(28px, 3.4vw, 40px); font-weight: 800; letter-spacing: -0.01em; line-height: 1.15; margin-top: 18px; }
.svc-block h3 { font-size: 18px; font-weight: 700; margin-top: 30px; }
.svc-block p { font-size: 16.5px; line-height: 1.7; color: #B8B8B8; margin-top: 14px; max-width: 680px; }
.svc-label { font-size: 13px !important; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--glow) !important; margin-top: 28px !important; }
.svc-list { list-style: none; margin-top: 12px; display: grid; gap: 10px; max-width: 680px; }
.svc-list li { position: relative; padding-left: 26px; font-size: 16px; line-height: 1.5; color: #E5E5E5; }
.svc-list li::before {
  content: ""; position: absolute; left: 0; top: 5px; width: 14px; height: 14px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b389be' stroke-width='2.6'%3E%3Cpath d='M6 6l6 6-6 6'/%3E%3Cpath d='M13 6l6 6-6 6'/%3E%3C/svg%3E") no-repeat center / contain;
}
.svc-block .footer-btn { margin-top: 32px; }

.brands-section { padding: 110px 0; }
.brands-grid { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; margin-top: 44px; }
.brand { background: var(--mist); clip-path: var(--cut); height: 120px; display: flex; align-items: center; justify-content: center; padding: 18px; }
.brand img { height: var(--h); width: auto; max-width: 100%; object-fit: contain; opacity: 0.8; transition: opacity 0.25s ease, transform 0.25s ease; }
.brand:hover img { opacity: 1; transform: scale(1.04); }

.closing-cta { padding: 120px 0; text-align: center; }
.closing-tag { display: inline-block; font-size: 13px; font-weight: 500; color: var(--purple-deep); background: var(--lila); padding: 7px 14px; border-radius: 12px; margin-bottom: 22px; }
.closing-cta h2 { font-size: clamp(30px, 4.4vw, 52px); font-weight: 800; letter-spacing: -0.01em; line-height: 1.15; }
.closing-cta h2 span { color: var(--purple); }
.closing-cta .circle-link { margin-top: 40px; }
.circle-link.go:hover svg { transform: translateX(5px); }

@media (max-width: 1100px) { .brands-grid { grid-template-columns: repeat(4, 1fr); } }
@media (max-width: 900px) {
  .svc-hero { padding: 48px 0 60px; }
  .svc-hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .svc-section { padding: 80px 0 40px; }
  .svc-layout { grid-template-columns: 1fr; gap: 0; }
  .svc-nav { display: none; }
  .svc-block { padding-bottom: 48px; margin-bottom: 48px; }
  .brands-section, .closing-cta { padding: 80px 0; }
}
@media (max-width: 640px) {
  .svc-hero-grid h1.hero-title { margin-left: 8px; font-size: 40px; }
  .svc-tiles { gap: 12px; }
  .svc-tile { padding: 18px 16px; min-height: 130px; font-size: 15px; }
  .brands-grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
  .brand { height: 84px; padding: 12px; }
  .brand img { height: calc(var(--h) * 0.72); }
}

/* ---------- PÁGINA: INICIO ---------- */
.home-hero { position: relative; overflow: hidden; padding: 110px 0 120px; text-align: center; }
.home-hero .pat-hot {
  position: absolute; inset: 0; pointer-events: none;
  background-image: url('../img/patron-vs-hot.svg'); background-size: 400px 280px;
  -webkit-mask-image: radial-gradient(circle 200px at var(--mx, -999px) var(--my, -999px), #000 0%, transparent 100%);
  mask-image: radial-gradient(circle 200px at var(--mx, -999px) var(--my, -999px), #000 0%, transparent 100%);
}
.home-hero .wrap { position: relative; }
.home-hero h1.hero-title { display: block; font-size: clamp(56px, 10.5vw, 150px); margin-top: 10px; color: var(--purple); }
.home-hero h1 .w1 { margin-right: 0.18em; }
.home-hero h1 .hl { color: var(--purple-deep); }
.home-hero .hero-sub { max-width: 620px; margin: 30px auto 0; }
.home-hero .hero-actions { display: flex; justify-content: center; margin-top: 34px; opacity: 0; animation: rise 0.7s ease-out 0.6s forwards; }
@media (max-width: 640px) {
  .home-hero { padding: 70px 0 80px; }
  .home-hero h1 .w1 { display: block; margin-right: 0; margin-bottom: 0.08em; }
}

.marquee-section { padding: 72px 0 80px; border-top: 1px solid var(--line); }
.center-kicker { text-align: center; }
.marquee { overflow: hidden; margin-top: 30px;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent); }
.marquee { cursor: grab; touch-action: pan-y; -webkit-user-select: none; user-select: none; }
.marquee.dragging { cursor: grabbing; }
.marquee img { -webkit-user-drag: none; pointer-events: none; }
.marquee-track { display: flex; gap: 16px; width: max-content; will-change: transform; animation: marquee 60s linear infinite; }
.marquee.js .marquee-track { animation: none; }
.marquee .brand { width: 190px; flex-shrink: 0; }
@keyframes marquee { to { transform: translateX(calc(-50% - 8px)); } }

@media (max-width: 640px) { .marquee .brand { width: 140px; height: 84px; } .marquee .brand img { height: calc(var(--h) * 0.72); } }

.home-about { background: var(--black); color: var(--white); padding: 110px 0; }
.home-about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: start; }
.home-about .kicker { color: var(--glow); }
.home-about h2 { font-size: clamp(30px, 3.6vw, 44px); font-weight: 800; line-height: 1.15; letter-spacing: -0.01em; }
.home-about p { font-size: 16.5px; line-height: 1.75; color: #B8B8B8; }
.home-about .footer-btn { margin-top: 30px; }

.home-svc { padding: 110px 0; }
.home-svc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-top: 44px; }
.home-svc-card { background: var(--mist); clip-path: var(--cut); padding: 28px 24px 26px; display: flex; flex-direction: column; gap: 12px; transition: background 0.3s ease; }
.home-svc-card:hover { background: var(--lila); }
.home-svc-card:hover .vs-ico .acc { transform: translate(0, 0); }
.home-svc-card h3 { font-size: 19px; font-weight: 800; color: var(--purple-deep); line-height: 1.25; margin-top: 6px; }
.home-svc-card p { font-size: 15px; line-height: 1.55; color: var(--ink); flex: 1; }
.home-svc-card .case-link { padding-top: 6px; }
.home-svc-card:hover .case-link svg { transform: translateX(5px); }

.case-slider { background: var(--black); color: var(--white); padding: 110px 0; overflow: hidden; }
.slides { position: relative; }
.slide { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 64px; align-items: center; }
.slide[hidden] { display: none; }
.slide.in .slide-text > * { animation: rise 0.6s ease-out both; }
.slide.in .slide-media { animation: rise 0.7s ease-out both; }
.slide-count { font-size: 14px; font-weight: 700; color: var(--glow); }
/* Contador + nombre: siempre ocupan el alto de dos renglones y quedan juntos abajo */
.slide-head { font-size: clamp(48px, 7.5vw, 104px); min-height: calc(2em + 34px); display: flex; flex-direction: column; justify-content: flex-end; }
.slide-name { font-size: 1em; font-weight: 900; font-style: italic; text-transform: uppercase; color: var(--purple); line-height: 1; letter-spacing: -0.02em; margin-top: 14px; }
.slide-desc { font-size: 16.5px; line-height: 1.7; color: #B8B8B8; margin-top: 22px; max-width: 520px; }
.slide-rubro { display: inline-block; margin-top: 18px; font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--white); }
.slide-controls { display: flex; align-items: center; gap: 12px; margin-top: 34px; }
.slide-arrow { width: 52px; height: 52px; border-radius: 50%; border: 1px solid rgba(255,255,255,0.45); color: var(--white); display: flex; align-items: center; justify-content: center; transition: background 0.25s, border-color 0.25s; }
.slide-arrow:hover { background: var(--purple); border-color: var(--purple); }
.slide-arrow svg { width: 18px; height: 18px; }
.slide-controls .footer-btn { margin-left: 10px; }
.slide-media { position: relative; aspect-ratio: 4 / 5; border-radius: 18px; overflow: hidden; }
.slide-media img { width: 100%; height: 100%; object-fit: cover; }
.slide-media .case-logo { position: absolute; left: 18px; bottom: 18px; }

.why-section { background: var(--mist); padding: 110px 0; }
.why-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.why-grid .block-body { margin-top: 18px; }
.why-steps { list-style: none; display: grid; gap: 28px; position: relative; }
.why-steps li { position: relative; display: grid; grid-template-columns: 76px 1fr; gap: 22px; align-items: center; transition: opacity 0.5s ease; }
.why-num { width: 76px; height: 76px; border-radius: 50%; border: 1.5px solid var(--purple); background: var(--white); color: var(--purple); font-size: 26px; font-weight: 800; display: flex; align-items: center; justify-content: center; transition: background 0.45s ease, color 0.45s ease, transform 0.45s var(--ease); }
.why-steps::before, .why-steps::after { content: ""; position: absolute; left: 37px; top: 38px; width: 2px; z-index: 0; }
.why-steps li { z-index: 1; }
.why-steps::before { bottom: 38px; background: var(--lila); }
.why-steps::after { height: calc((100% - 76px) * var(--fill, 0)); background: var(--purple); transition: height 0.9s var(--ease); }
.why-steps.armed li:not(.on) { opacity: 0.45; }
.why-steps li.on .why-num { background: var(--purple); color: var(--white); transform: scale(1.06); }
.why-steps li:hover { opacity: 1 !important; }
.why-steps li:hover .why-num { transform: scale(1.1); }

.why-steps h3 { font-size: 17px; font-weight: 800; letter-spacing: 0.04em; text-transform: uppercase; }
.why-steps p { font-size: 15px; line-height: 1.6; color: var(--muted); margin-top: 6px; }
.why-section .value-chips { opacity: 1; animation: none; }
.why-section .value-chips span { background: var(--white); }
.why-section .value-chips span:hover { background: var(--purple); border-color: var(--purple); color: var(--white); }

.partners-section { padding: 110px 0 100px; }
.partners-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 44px; }
.partner { height: 120px; border: 1px solid var(--line); border-radius: 12px; display: flex; align-items: center; justify-content: center; padding: 20px 26px; background: var(--white); transition: border-color 0.25s, transform 0.25s; }
.partner:hover { border-color: var(--glow); transform: translateY(-3px); }
.partner img { max-width: 100%; max-height: 56px; width: auto; height: auto; }
.partner.google { padding: 8px 26px; }
.partner img.badge { height: 100%; width: auto; max-height: none; }

.home-cta { padding: 110px 0; }
.home-cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.home-cta.closing-split h2 { font-size: clamp(30px, 4.4vw, 52px); }
.home-cta.closing-split h2 span { color: var(--purple); }
.home-cta h2 { font-size: clamp(34px, 5vw, 60px); font-weight: 800; line-height: 1.1; letter-spacing: -0.01em; }
.home-cta .closing-tag { margin-bottom: 18px; }

@media (max-width: 1000px) { .home-svc-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) {
  .home-about, .home-svc, .case-slider, .why-section, .partners-section, .home-cta { padding: 80px 0; }
  .home-about-grid, .why-grid { grid-template-columns: 1fr; gap: 32px; }
  .slide { grid-template-columns: 1fr; gap: 36px; }
  .slide-media { max-width: 420px; }
  .partners-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .partner { height: 96px; padding: 16px; }
  .home-cta-inner { flex-direction: column; align-items: center; text-align: center; }
  .home-cta .circle-link { align-self: center; }
}
@media (max-width: 560px) {
  .home-svc-grid { grid-template-columns: 1fr; }
  .why-steps li { grid-template-columns: 60px 1fr; gap: 16px; }
  .why-num { width: 60px; height: 60px; font-size: 21px; }
  .why-steps::before, .why-steps::after { left: 29px; top: 30px; }
  .why-steps::before { bottom: 30px; }
  .why-steps::after { height: calc((100% - 60px) * var(--fill, 0)); }
  .slide-controls { flex-wrap: wrap; }
}

/* ---------- MENÚ INFERIOR (MOBILE) ---------- */
.tabbar { display: none; }
@media (max-width: 900px) {
  .nav-toggle, .nav-links { display: none !important; }
  .nav-inner { justify-content: center; }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); align-items: end;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
    height: calc(76px + env(safe-area-inset-bottom, 0px));
    padding: 0 6px calc(10px + env(safe-area-inset-bottom, 0px));
    background: rgba(255,255,255,0.97); border-top: 1px solid var(--line);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    transition: transform 0.35s var(--ease);
  }
  .tabbar.hide { transform: translateY(100%); }
  .tab { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 500; color: var(--muted); line-height: 1; }
  .tab svg { width: 25px; height: 25px; }
  .tab .acc { fill: var(--lila); transform: translate(2px, 2px); transition: transform 0.3s ease; }
  .tab .ln { fill: none; stroke: var(--muted); stroke-width: 2; stroke-linejoin: miter; transition: stroke 0.3s ease; }
  .tab[aria-current="page"] { color: var(--purple); font-weight: 700; }
  .tab[aria-current="page"] .ln { stroke: var(--purple); }
  .tab[aria-current="page"] .acc { transform: translate(0, 0); }
  .tab-cta .tab-circ {
    width: 60px; height: 60px; border-radius: 50%; margin-top: -30px;
    background: var(--purple); border: 4px solid var(--white);
    box-shadow: 0 6px 16px rgba(70,32,81,0.3);
    display: flex; align-items: center; justify-content: center; transition: background 0.3s ease;
  }
  .tab-cta .tab-circ svg { width: 27px; height: 27px; }
  .tab-cta .ln { stroke: var(--white) !important; }
  .tab-cta .acc { fill: var(--purple-deep); }
  .tab-cta[aria-current="page"] .tab-circ { background: var(--purple-deep); }
  .tab-cta[aria-current="page"] .acc { fill: var(--purple); }
}

/* ---------- AVISO DE COOKIES ---------- */
.cookie-banner {
  position: fixed; left: 24px; bottom: 24px; z-index: 95; max-width: 460px;
  background: var(--white); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 18px 50px rgba(0,0,0,0.16); padding: 22px 22px 20px;
  transform: translateY(20px); opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform 0.4s var(--ease), opacity 0.4s ease, visibility 0s linear 0.4s;
}
.cookie-banner.show { transform: translateY(0); opacity: 1; visibility: visible; pointer-events: auto; transition: transform 0.4s var(--ease), opacity 0.4s ease; }
.cookie-banner p { font-size: 14px; line-height: 1.55; color: var(--ink); }
.cookie-banner p a { color: var(--purple); font-weight: 500; text-decoration: underline; }
.cookie-actions { display: flex; gap: 10px; margin-top: 16px; }
.cookie-actions .btn { padding: 11px 20px; font-size: 14px; }
@media (max-width: 900px) {
  .cookie-banner { left: 12px; right: 12px; max-width: none; bottom: calc(88px + env(safe-area-inset-bottom, 0px)); padding: 18px; }
  .cookie-actions .btn { flex: 1; }
}
.footer-legal { display: flex; flex-wrap: wrap; gap: 6px 18px; }
.footer-legal button { color: rgba(255,255,255,0.8); font-size: inherit; font-family: inherit; padding: 0; transition: color 0.2s; }
.footer-legal button:hover { color: var(--white); }

/* ---------- FORMULARIO: PRIVACIDAD ---------- */
.form-privacy { font-size: 13px; line-height: 1.5; color: var(--muted); margin-top: 14px; }
.form-privacy a { color: var(--purple); font-weight: 500; text-decoration: underline; }

/* ---------- PÁGINA LEGAL ---------- */
.legal { padding: 64px 0 100px; }
.legal-body { max-width: 780px; }
.legal-body h2 { font-size: 22px; font-weight: 800; color: var(--purple-deep); margin: 44px 0 12px; }
.legal-body p, .legal-body li { font-size: 16px; line-height: 1.75; color: #3a3a3a; }
.legal-body p + p { margin-top: 12px; }
.legal-body ul { margin: 12px 0 0 20px; }
.legal-body li + li { margin-top: 6px; }
.legal-body .table-scroll { overflow-x: auto; margin: 18px 0 6px; }
.legal-body table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
@media (max-width: 640px) { .legal-body table { font-size: 13.5px; } .legal-body th, .legal-body td { padding: 10px 8px; } }
.legal-body th { text-align: left; background: var(--mist); color: var(--purple-deep); font-weight: 700; padding: 12px 14px; }
.legal-body td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; line-height: 1.5; color: #3a3a3a; }
.legal-date { margin-top: 40px !important; font-size: 14px !important; color: var(--muted) !important; }

/* ---------- CASOS: PROYECTO ANTERIOR / SIGUIENTE ---------- */
.project-nav { gap: 12px !important; flex-wrap: wrap; }
.project-nav .paint-btn {
  width: auto; min-width: 230px; height: 76px; margin: 0; padding: 0 26px; border: none; border-radius: 0; overflow: visible;
  display: inline-flex; align-items: center; justify-content: space-between; gap: 18px; text-align: left;
  font-size: 16px; font-weight: 700; background: var(--purple); color: var(--white);
  clip-path: polygon(0 0, calc(100% - 22px) 0, 100% 22px, 100% 100%, 0 100%);
  transition: background 0.3s ease;
}
.project-nav .paint-btn::before { display: none; }
.project-nav .paint-btn span { padding: 0; color: inherit !important; }
.project-nav .paint-btn svg { width: 16px; height: 16px; flex-shrink: 0; transition: transform 0.3s var(--ease); }
.project-nav .paint-btn.next:hover { background: var(--purple-deep); }
.project-nav .paint-btn.next:hover svg { transform: translateX(5px); }
.project-nav .paint-btn.prev { background: var(--mist); color: var(--purple-deep); clip-path: polygon(22px 0, 100% 0, 100% 100%, 0 100%, 0 22px); }
.project-nav .paint-btn.prev:hover { background: var(--lila); }
.project-nav .paint-btn.prev:hover svg { transform: translateX(-5px); }
@media (max-width: 560px) {
  .project-nav .paint-btn { min-width: 0; flex: 1; height: 64px; padding: 0 16px; font-size: 14px; gap: 10px; }
}

/* ---------- CASOS: AJUSTES DE CONTENIDO ---------- */
.metrics-grid.metrics-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 860px) { .metrics-grid .metric:nth-child(odd) { padding-left: 0; } }
@media (max-width: 860px) { .metrics-grid.metrics-3 { grid-template-columns: repeat(3, 1fr); gap: 0; } .metrics-grid.metrics-3 .metric-num { font-size: 32px; } }
@media (max-width: 560px) { .metrics-grid.metrics-3 { grid-template-columns: 1fr; gap: 28px; } .metrics-grid.metrics-3 .metric { padding: 0; } }
.phase-body .phase-desc:not(:last-child) { padding-bottom: 12px; }
.quote-section .quote-text { position: relative; z-index: 1; font-size: clamp(24px, 3.2vw, 34px); font-weight: 600; line-height: 1.35; max-width: 820px; letter-spacing: -0.01em; }
.quote-section .quote-link { margin-top: 30px; }
.chart-svg { overflow: visible; }
.chart-svg .chart-val { fill: #fff; font: 700 15px Roboto, sans-serif; }
.chart-svg .chart-month { fill: #B8B8B8; font: 500 12px Roboto, sans-serif; }
.chart-svg.chart-small .chart-val { font-size: 28px; }
.chart-svg.chart-small .chart-month { font-size: 24px; }
@media (max-width: 640px) { .chart-svg { height: auto; } }

/* ---------- FOOTER ---------- */
.site-footer {
  position: relative; z-index: 8; /* por encima de secciones sticky (ej. testimonio del caso) */
  background: var(--purple); color: rgba(255,255,255,0.8);
  padding: 72px 0 32px; overflow: hidden; font-size: 14px; margin-top: -1px;
}
.site-footer .curve { position: absolute; bottom: 0; right: 0; height: 105%; width: auto; max-width: none; z-index: 0; pointer-events: none; }
.site-footer .wrap { position: relative; z-index: 1; }
.footer-grid {
  display: grid; grid-template-columns: 1.4fr 0.9fr 1.3fr 1fr; gap: 40px;
  padding-bottom: 44px; border-bottom: 1px solid rgba(255,255,255,0.2);
}
.footer-logo img { height: 44px; width: auto; }
.footer-tagline { margin-top: 18px; line-height: 1.6; max-width: 240px; }
.footer-nav, .footer-contact { list-style: none; display: grid; gap: 10px; align-content: start; }
.site-footer a { color: rgba(255,255,255,0.8); transition: color 0.2s; }
.site-footer a:hover { color: var(--white); }
.footer-contact a { display: inline-flex; align-items: center; gap: 10px; }
.footer-contact svg { width: 18px; height: 18px; flex-shrink: 0; }
.footer-contact .ln { fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: miter; }
.footer-cta-title { font-size: 16px; font-weight: 700; color: var(--white); margin-bottom: 14px; }
a.footer-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 20px; border-radius: 12px;
  background: var(--purple); color: var(--white); border: 1px solid rgba(255,255,255,0.55);
  font-size: 13.5px; font-weight: 700; line-height: 1.4;
  transition: background 0.25s ease, border-color 0.25s ease;
}
.footer-btn svg { width: 14px; height: 14px; transition: transform 0.25s ease; }
a.footer-btn:hover { background: var(--purple-deep); border-color: rgba(255,255,255,0.8); }
.footer-btn:hover svg { transform: translateX(3px); }
.footer-bottom { padding-top: 22px; font-size: 13px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 24px; }
@media (max-width: 900px) {
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 36px 24px; }
}
@media (max-width: 560px) {
  .site-footer .curve { height: 40%; }
  .site-footer { padding-top: 56px; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
}

/* ---------- PÁGINA EN CONSTRUCCIÓN ---------- */
.wip-note { display: inline-flex; align-items: center; gap: 10px; margin-top: 26px; font-size: 14px; font-weight: 500; color: var(--purple-deep);
  background: var(--lila); padding: 8px 14px; border-radius: 12px; opacity: 0; animation: rise 0.7s ease-out 0.4s forwards; }

/* ---------- PORTFOLIO ---------- */
.cases-section { padding: 72px 0 110px; }
.cases-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 28px; }
@media (max-width: 400px) { .cases-grid { grid-template-columns: 1fr; } }
.case-card { display: flex; flex-direction: column; background: var(--mist); clip-path: var(--cut); transition: transform 0.35s var(--ease); }
.case-card:hover { transform: translateY(-6px); }
.case-media { position: relative; aspect-ratio: 4 / 3; overflow: hidden; background: var(--purple-deep); }
.case-media img { width: 100%; height: 100%; object-fit: cover; object-position: center 15%; transition: transform 0.6s var(--ease); }
.case-card:hover .case-media img { transform: scale(1.04); }
.case-media .stat-pill {
  position: absolute; left: 16px; bottom: 16px; background: var(--white); border-radius: 16px; padding: 12px 16px;
  display: flex; flex-direction: column; box-shadow: 0 12px 26px rgba(0,0,0,0.2);
}
.case-media .stat-pill .num { font-size: 22px; font-weight: 800; color: var(--purple); line-height: 1.1; }
.case-media .stat-pill .lab { font-size: 11.5px; color: var(--muted); font-weight: 600; }
.case-body { padding: 26px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.case-logo { align-self: flex-start; display: inline-flex; background: var(--white); border: 1px solid var(--purple); border-radius: 12px; padding: 7px 14px; }
.case-logo img { height: 13px; width: auto; }
.case-rubro { font-size: 12.5px !important; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--purple) !important; margin-top: 8px; }
.case-body h2 { font-size: 26px; font-weight: 900; font-style: italic; text-transform: uppercase; color: var(--purple-deep); letter-spacing: -0.01em; margin-top: 6px; }
.case-body p { font-size: 15px; line-height: 1.55; color: var(--ink); }
.case-link { margin-top: auto; padding-top: 10px; display: inline-flex; align-items: center; gap: 8px; font-size: 14.5px; font-weight: 700; color: var(--purple); }
.case-link svg { width: 14px; height: 14px; transition: transform 0.25s var(--ease); }
.case-card:hover .case-link svg { transform: translateX(5px); }

/* ---------- MODAL DE CALENDLY ---------- */
#calendly-modal {
  position: fixed; inset: 0; z-index: 500;
  background: rgba(0,0,0,0.55);
  display: none; align-items: center; justify-content: center;
  padding: 20px;
}
#calendly-modal.open { display: flex; }
#calendly-modal .modal-box {
  background: #fff; border-radius: 16px; overflow: hidden;
  width: 100%; max-width: 1100px; height: 90vh; max-height: 820px;
  position: relative; box-shadow: 0 20px 60px rgba(0,0,0,0.4);
}
#calendly-modal .modal-close {
  position: absolute; top: 10px; right: 14px; z-index: 2;
  background: #fff; border-radius: 50%; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15); font-size: 20px; color: #222;
}
#calendly-modal .calendly-inline-widget { width: 100%; height: 100%; min-width: 320px; }

/* ---------- MOBILE: el footer se extiende detrás del menú inferior (va al final para ganarle a la regla base) ---------- */
@media (max-width: 900px) {
  .site-footer { padding-bottom: calc(32px + 76px + env(safe-area-inset-bottom, 0px)); }
}

/* ---------- MOBILE: "Nuestro equipo" vuelve arriba del texto, como en la v18 ---------- */
@media (max-width: 900px) {
  .agency-grid .circle-link { order: -1; justify-self: stretch; }
}
