/* =========================================================
   MYRAYCA6 · Reformas Integrales
   ========================================================= */
:root {
  --navy: #0f2a4d;
  --navy-2: #133661;
  --navy-3: #0a1d36;
  --blue: #1d63b3;
  --sky: #2aa3e0;
  --red: #d62b2b;
  --red-2: #b81f1f;
  --stone: #f4efe7;
  --stone-2: #e9e1d4;
  --sand: #c9a46a;
  --ink: #142235;
  --muted: #5d6b7e;
  --white: #fff;
  --wa: #25d366;
  --radius: 18px;
  --shadow: 0 20px 50px -20px rgba(15, 42, 77, .35);
  --shadow-lg: 0 40px 80px -30px rgba(15, 42, 77, .5);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --font-h: 'Archivo', 'Arial Black', sans-serif;
  --font-b: 'Inter', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
  font-family: var(--font-b);
  color: var(--ink);
  background: var(--stone);
  line-height: 1.65;
  font-size: 17px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}
body.no-scroll { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
ul { list-style: none; }

.container { width: min(1240px, 92%); margin-inline: auto; }
.section { padding: clamp(80px, 11vw, 140px) 0; position: relative; }

/* ---------- Typography ---------- */
.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-family: var(--font-h); font-weight: 700; font-size: .8rem;
  letter-spacing: .18em; text-transform: uppercase; color: var(--red);
  margin-bottom: 18px;
}
.eyebrow::before { content: ''; width: 32px; height: 2px; background: currentColor; }
.eyebrow--light { color: #fff; }
.eyebrow--light::before { background: var(--red); }
.eyebrow .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--red); box-shadow: 0 0 0 0 rgba(214,43,43,.7); animation: pulse 2s infinite; }
.hero .eyebrow::before { display: none; }

.section__title {
  font-family: var(--font-h); font-weight: 800;
  font-size: clamp(2rem, 4.2vw, 3.4rem); line-height: 1.08;
  letter-spacing: -.02em; color: var(--navy); margin-bottom: 22px;
}
.section__title--light { color: #fff; }
.hl { position: relative; color: var(--blue); white-space: nowrap; }
.hl::after {
  content: ''; position: absolute; left: 0; bottom: .06em; height: .14em; width: 100%;
  background: var(--red); opacity: .85; transform: scaleX(0); transform-origin: left;
  transition: transform 1s .3s var(--ease); border-radius: 4px;
}
.in .hl::after, .hl.in::after, .section__title.in .hl::after { transform: scaleX(1); }
.hl--light { color: var(--sky); }
.section__head { max-width: 760px; margin-bottom: 56px; }
.section__head--row { max-width: none; display: flex; justify-content: space-between; align-items: flex-end; gap: 30px; flex-wrap: wrap; }
.section__lead { color: var(--muted); font-size: 1.05rem; }
p + p { margin-top: 14px; }
.link { color: var(--blue); font-weight: 600; border-bottom: 2px solid rgba(29,99,179,.25); transition: border-color .3s; }
.link:hover { border-color: var(--blue); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 14px 24px; border-radius: 999px; font-weight: 600; font-size: .98rem;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), background .3s, color .3s;
  position: relative; overflow: hidden; white-space: nowrap; will-change: transform;
}
.btn--lg { padding: 18px 30px; font-size: 1.04rem; }
.btn--block { width: 100%; }
.btn--red { background: var(--red); color: #fff; box-shadow: 0 12px 30px -10px rgba(214,43,43,.7); }
.btn--red:hover { background: var(--red-2); box-shadow: 0 18px 40px -12px rgba(214,43,43,.8); }
.btn--glass { background: rgba(255,255,255,.12); color: #fff; border: 1px solid rgba(255,255,255,.35); backdrop-filter: blur(10px); }
.btn--glass:hover { background: #fff; color: var(--navy); }
.btn--whatsapp { background: var(--wa); color: #06361b; box-shadow: 0 12px 30px -10px rgba(37,211,102,.7); }
.btn--whatsapp:hover { background: #1fbe5a; }
.btn--outline { border: 2px solid var(--navy); color: var(--navy); }
.btn--outline:hover { background: var(--navy); color: #fff; }
.btn::after {
  content: ''; position: absolute; inset: 0; background: linear-gradient(120deg, transparent 30%, rgba(255,255,255,.35) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .8s var(--ease);
}
.btn:hover::after { transform: translateX(120%); }

/* ---------- Preloader ---------- */
.preloader {
  position: fixed; inset: 0; z-index: 9999; background: var(--navy-3);
  display: grid; place-items: center; transition: opacity .7s var(--ease), visibility .7s;
}
.preloader.done { opacity: 0; visibility: hidden; }
.preloader__inner { text-align: center; }
.preloader__bricks { display: grid; grid-template-columns: repeat(3, 34px); gap: 5px; justify-content: center; margin-bottom: 22px; }
.preloader__bricks span { height: 16px; background: var(--red); border-radius: 3px; opacity: 0; transform: translateY(-30px); animation: brick .5s var(--ease) forwards; }
.preloader__bricks span:nth-child(1) { animation-delay: .05s; background: var(--blue); }
.preloader__bricks span:nth-child(2) { animation-delay: .15s; background: var(--blue); }
.preloader__bricks span:nth-child(3) { animation-delay: .25s; background: var(--blue); }
.preloader__bricks span:nth-child(4) { animation-delay: .35s; background: var(--sky); }
.preloader__bricks span:nth-child(5) { animation-delay: .45s; }
.preloader__bricks span:nth-child(6) { animation-delay: .55s; background: var(--sky); }
.preloader__logo { font-family: var(--font-h); font-weight: 900; color: #fff; font-size: 2.2rem; letter-spacing: .12em; }
.preloader__logo span { color: var(--red); font-style: italic; font-size: 1.18em; margin-left: 2px; }
.preloader__bar { width: 180px; height: 3px; background: rgba(255,255,255,.15); margin: 16px auto 0; border-radius: 3px; overflow: hidden; }
.preloader__bar i { display: block; height: 100%; width: 0; background: var(--red); animation: load 1.2s var(--ease) forwards; }
@keyframes brick { to { opacity: 1; transform: none; } }
@keyframes load { to { width: 100%; } }

/* ---------- Scroll progress ---------- */
.scroll-progress { position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 1001; background: linear-gradient(90deg, var(--red), var(--sky)); }

/* ---------- Header ---------- */
.header { position: fixed; inset: 0 0 auto; z-index: 1000; padding: 18px 0; transition: background .4s, padding .4s, box-shadow .4s, transform .4s var(--ease); color: #fff; }
.header.scrolled { background: rgba(255,255,255,.92); backdrop-filter: blur(14px); padding: 10px 0; box-shadow: 0 10px 30px -20px rgba(0,0,0,.4); color: var(--navy); }
.header.hidden { transform: translateY(-100%); }
.header__inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.logo__svg { width: 205px; height: auto; display: block; }
.header .logo__svg .logo__word { fill: #fff; transition: fill .4s; }
.header.scrolled .logo__svg .logo__word { fill: url(#lg); }
.nav { display: flex; align-items: center; gap: 6px; }
.nav__link { padding: 8px 12px; font-weight: 500; font-size: .93rem; position: relative; opacity: .92; }
.nav__link::after { content: ''; position: absolute; left: 12px; right: 12px; bottom: 2px; height: 2px; background: var(--red); transform: scaleX(0); transition: transform .35s var(--ease); }
.nav__link:hover::after, .nav__link.active::after { transform: scaleX(1); }
.nav__cta { margin-left: 10px; padding: 11px 20px; }
.burger { display: none; width: 44px; height: 44px; position: relative; z-index: 1002; }
.burger span { position: absolute; left: 10px; right: 10px; height: 2px; background: currentColor; transition: transform .4s var(--ease), opacity .3s; }
.burger span:nth-child(1) { top: 15px; } .burger span:nth-child(2) { top: 21px; } .burger span:nth-child(3) { top: 27px; }
.burger.open span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.burger.open span:nth-child(2) { opacity: 0; }
.burger.open span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero { position: relative; min-height: 100vh; min-height: 100svh; display: flex; align-items: center; overflow: hidden; color: #fff; padding: 130px 0 90px; }
.hero__bg { position: absolute; inset: -6% -2%; background-size: cover; background-position: 65% center; transform: scale(1.08); animation: kenburns 22s ease-in-out infinite alternate; will-change: transform; }
@keyframes kenburns { from { transform: scale(1.08) translate(0, 0); } to { transform: scale(1.18) translate(-1.5%, -1%); } }
.hero__overlay { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10,29,54,.72) 0%, rgba(10,29,54,0) 20%), linear-gradient(95deg, rgba(10,29,54,.92) 0%, rgba(10,29,54,.7) 38%, rgba(10,29,54,.15) 70%, rgba(10,29,54,.25) 100%), linear-gradient(0deg, rgba(10,29,54,.6), transparent 40%); }
.hero__content { position: relative; z-index: 2; }
.hero__title { font-family: var(--font-h); font-weight: 900; font-size: clamp(2.5rem, 5.2vw, 4.7rem); line-height: 1.02; letter-spacing: -.03em; margin-bottom: 26px; max-width: 980px; }
.hero__title .line { display: block; overflow: hidden; padding-bottom: .08em; }
.hero__title .line > span { display: inline-block; transform: translateY(110%); transition: transform 1.1s var(--ease); }
.hero__title em { font-style: normal; color: var(--sky); position: relative; }
.hero__title em::after { content: ''; position: absolute; left: 0; right: 0; bottom: .02em; height: .1em; background: var(--red); border-radius: 4px; transform: scaleX(0); transform-origin: left; transition: transform .9s 1.6s var(--ease); }
body.loaded .hero__title .line > span { transform: none; }
body.loaded .hero__title .line:nth-child(2) > span { transition-delay: .12s; }
body.loaded .hero__title .line:nth-child(3) > span { transition-delay: .24s; }
body.loaded .hero__title em::after { transform: scaleX(1); }
.hero__text { font-size: clamp(1.02rem, 1.4vw, 1.2rem); max-width: 600px; opacity: .9; margin-bottom: 36px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-bottom: 48px; }
.hero__badges { display: flex; flex-wrap: wrap; gap: 12px; }
.badge { display: flex; align-items: center; gap: 10px; padding: 10px 16px; border-radius: 12px; background: rgba(255,255,255,.1); border: 1px solid rgba(255,255,255,.18); backdrop-filter: blur(10px); font-size: .9rem; }
.badge svg { color: var(--sky); }
.stars { color: #ffb300; letter-spacing: 2px; }
.hero__scroll { position: absolute; bottom: 28px; left: 50%; transform: translateX(-50%); width: 28px; height: 46px; border: 2px solid rgba(255,255,255,.6); border-radius: 20px; z-index: 2; }
.hero__scroll span { position: absolute; top: 8px; left: 50%; width: 4px; height: 8px; margin-left: -2px; background: #fff; border-radius: 2px; animation: scrollDot 1.8s infinite; }
@keyframes scrollDot { 0% { opacity: 0; transform: translateY(0); } 30% { opacity: 1; } 100% { opacity: 0; transform: translateY(16px); } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(214,43,43,.7); } 70% { box-shadow: 0 0 0 12px rgba(214,43,43,0); } 100% { box-shadow: 0 0 0 0 rgba(214,43,43,0); } }

/* ---------- Marquee ---------- */
.marquee { background: var(--navy); color: #fff; padding: 22px 0; overflow: hidden; position: relative; border-top: 4px solid var(--red); }
.marquee__track { display: flex; gap: 34px; width: max-content; animation: marquee 38s linear infinite; font-family: var(--font-h); font-weight: 800; font-size: clamp(1.1rem, 2vw, 1.5rem); text-transform: uppercase; letter-spacing: .04em; }
.marquee__track b { color: var(--red); font-size: .7em; align-self: center; }
.marquee:hover .marquee__track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- About ---------- */
.about__grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: clamp(40px, 7vw, 100px); align-items: center; }
.about__media { position: relative; }
.about__img { aspect-ratio: 4 / 5; border-radius: 24px; background-size: cover; background-position: center; box-shadow: var(--shadow-lg); transition: transform .3s ease-out; transform-style: preserve-3d; }
.about__media::before { content: ''; position: absolute; inset: 30px -30px -30px 30px; border: 3px solid var(--red); border-radius: 24px; z-index: -1; }
.about__card { position: absolute; left: -30px; bottom: 50px; background: #fff; border-radius: 18px; padding: 16px 20px; display: flex; gap: 14px; align-items: center; box-shadow: var(--shadow); }
.about__card strong { display: block; color: var(--navy); font-size: 1rem; }
.about__card span { display: block; font-size: .82rem; color: var(--muted); }
.about__card .verified { color: var(--blue); display: flex; align-items: center; gap: 4px; font-weight: 600; margin-top: 2px; }
.about__card-avatar { width: 52px; height: 52px; border-radius: 50%; background: #c2410c; color: #fff; display: grid; place-items: center; font-family: var(--font-h); font-weight: 800; font-size: 1.5rem; flex-shrink: 0; }
.float { animation: float 5s ease-in-out infinite; }
@keyframes float { 50% { transform: translateY(-12px); } }
.about__stamp { position: absolute; top: -40px; right: -40px; width: 130px; height: 130px; background: var(--navy); color: #fff; border-radius: 50%; display: grid; place-items: center; box-shadow: var(--shadow); }
.about__stamp svg { position: absolute; inset: 5px; width: calc(100% - 10px); animation: spin 18s linear infinite; }
.about__stamp span { font-family: var(--font-h); font-weight: 900; font-size: 1.3rem; color: var(--red); }
@keyframes spin { to { transform: rotate(360deg); } }
.about__content p { color: var(--muted); }
.about__content strong { color: var(--ink); }
.values { display: flex; flex-wrap: wrap; gap: 10px; margin: 28px 0 36px; }
.values li { display: flex; align-items: center; gap: 8px; padding: 8px 16px; background: #fff; border-radius: 999px; font-weight: 600; font-size: .9rem; color: var(--navy); box-shadow: 0 6px 20px -12px rgba(15,42,77,.4); transition: transform .3s var(--ease), background .3s, color .3s; }
.values li span { color: #fff; background: var(--red); width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; }
.values li:hover { transform: translateY(-3px); background: var(--navy); color: #fff; }
.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.stat { padding: 22px 18px; background: #fff; border-radius: var(--radius); border-bottom: 4px solid var(--blue); box-shadow: 0 10px 30px -18px rgba(15,42,77,.35); }
.stat:nth-child(2) { border-color: var(--red); } .stat:nth-child(3) { border-color: var(--sky); }
.stat__num { font-family: var(--font-h); font-weight: 900; font-size: clamp(2rem, 3.4vw, 2.8rem); color: var(--navy); line-height: 1; }
.stat__num small { font-size: .5em; color: var(--muted); margin-left: 2px; }
.stat__label { font-size: .84rem; color: var(--muted); margin-top: 8px; line-height: 1.4; }

/* ---------- Services ---------- */
.services { background: #fff; }
.services::before { content: ''; position: absolute; inset: 0; background-image: radial-gradient(rgba(15,42,77,.07) 1px, transparent 1px); background-size: 26px 26px; pointer-events: none; }
.services__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; position: relative; }
.svc {
  position: relative; padding: 30px 26px; border-radius: 22px; background: var(--stone); overflow: hidden; cursor: pointer;
  transition: transform .5s var(--ease), box-shadow .5s var(--ease), color .4s; text-align: left; isolation: isolate; min-height: 270px;
  display: flex; flex-direction: column; transform-style: preserve-3d;
}
.svc::before { content: ''; position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; transition: opacity .6s var(--ease), transform 1s var(--ease); z-index: -2; transform: scale(1.15); background-image: var(--img); }
.svc::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(15,42,77,.75), rgba(10,29,54,.95)); opacity: 0; transition: opacity .5s; z-index: -1; }
.svc:hover, .svc:focus-visible { color: #fff; box-shadow: var(--shadow-lg); }
.svc:hover::before, .svc:focus-visible::before { opacity: 1; transform: scale(1); }
.svc:hover::after, .svc:focus-visible::after { opacity: 1; }
.svc__icon { width: 62px; height: 62px; border-radius: 50%; background: var(--blue); color: #fff; display: grid; place-items: center; margin-bottom: 22px; transition: background .4s, transform .6s var(--ease); box-shadow: 0 10px 24px -10px rgba(29,99,179,.8); }
.svc:nth-child(even) .svc__icon { background: var(--sky); }
.svc:hover .svc__icon { background: var(--red); transform: rotate(-10deg) scale(1.08); }
.svc__icon svg { width: 30px; height: 30px; }
.svc__num { position: absolute; top: 22px; right: 24px; font-family: var(--font-h); font-weight: 900; font-size: 2.6rem; color: rgba(15,42,77,.07); transition: color .4s; line-height: 1; }
.svc:hover .svc__num { color: rgba(255,255,255,.15); }
.svc h3 { font-family: var(--font-h); font-weight: 800; font-size: 1.3rem; color: var(--navy); margin-bottom: 8px; transition: color .4s; }
.svc:hover h3 { color: #fff; }
.svc p { font-size: .92rem; color: var(--muted); transition: color .4s; flex: 1; }
.svc:hover p { color: rgba(255,255,255,.85); }
.svc__more { margin-top: 18px; font-weight: 600; font-size: .88rem; color: var(--red); display: inline-flex; align-items: center; gap: 6px; }
.svc:hover .svc__more { color: #fff; }
.svc__more i { transition: transform .4s var(--ease); font-style: normal; }
.svc:hover .svc__more i { transform: translateX(6px); }

/* ---------- Projects ---------- */
.filters { display: flex; gap: 8px; flex-wrap: wrap; background: #fff; padding: 6px; border-radius: 999px; box-shadow: 0 10px 30px -18px rgba(15,42,77,.4); position: relative; }
.filter { padding: 10px 20px; border-radius: 999px; font-weight: 600; font-size: .92rem; color: var(--muted); transition: color .3s, background .3s; position: relative; z-index: 1; }
.filter.active { background: var(--navy); color: #fff; }
.filter:not(.active):hover { color: var(--navy); }
.projects__grid { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 260px; gap: 18px; }
.project { position: relative; border-radius: 20px; overflow: hidden; cursor: zoom-in; transition: opacity .5s var(--ease), transform .5s var(--ease); background: var(--navy); }
.project.wide { grid-column: span 2; }
.project.tall { grid-row: span 2; }
.project img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease), filter .6s; }
.project:hover img { transform: scale(1.08); filter: brightness(.75); }
.project__info { position: absolute; inset: auto 0 0 0; padding: 24px; color: #fff; background: linear-gradient(0deg, rgba(10,29,54,.92), transparent); transform: translateY(30%); opacity: .95; transition: transform .5s var(--ease); }
.project:hover .project__info { transform: none; }
.project__tag { display: inline-block; font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; font-weight: 700; background: var(--red); padding: 4px 10px; border-radius: 999px; margin-bottom: 8px; }
.project__info h3 { font-family: var(--font-h); font-weight: 800; font-size: 1.25rem; line-height: 1.2; }
.project__info p { font-size: .88rem; opacity: 0; transition: opacity .5s .1s; margin-top: 4px; }
.project:hover .project__info p { opacity: .85; }
.project__zoom { position: absolute; top: 18px; right: 18px; width: 44px; height: 44px; border-radius: 50%; background: #fff; color: var(--navy); display: grid; place-items: center; transform: scale(0) rotate(-90deg); transition: transform .5s var(--ease); font-size: 1.3rem; font-weight: 700; }
.project:hover .project__zoom { transform: none; }
.project.hide { display: none; }
.project.fade-in { animation: fadeUp .6s var(--ease) both; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(30px) scale(.97); } to { opacity: 1; transform: none; } }

/* ---------- Before / After ---------- */
.ba { background: var(--navy); color: #fff; overflow: hidden; }
.ba::before { content: ''; position: absolute; width: 700px; height: 700px; border-radius: 50%; background: radial-gradient(circle, rgba(42,163,224,.25), transparent 65%); top: -250px; right: -200px; }
.ba .section__head { position: relative; }
.ba__caption { max-width: 760px; opacity: .8; margin: -30px 0 40px; position: relative; }
.ba__slider { position: relative; aspect-ratio: 16 / 9; border-radius: 24px; overflow: hidden; box-shadow: 0 50px 100px -40px rgba(0,0,0,.8); user-select: none; touch-action: pan-y; --pos: 50%; }
.ba__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.ba__before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
.ba__handle { position: absolute; top: 0; bottom: 0; left: var(--pos); width: 4px; margin-left: -2px; background: #fff; pointer-events: none; box-shadow: 0 0 20px rgba(0,0,0,.4); }
.ba__knob { position: absolute; top: 50%; left: 50%; width: 60px; height: 60px; transform: translate(-50%, -50%); border-radius: 50%; background: var(--red); color: #fff; display: grid; place-items: center; border: 4px solid #fff; box-shadow: 0 10px 30px rgba(0,0,0,.4); animation: pulse 2.4s infinite; }
.ba__range { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: ew-resize; margin: 0; }
.ba__label { position: absolute; top: 20px; padding: 8px 16px; border-radius: 999px; background: rgba(10,29,54,.75); backdrop-filter: blur(8px); font-weight: 700; font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; pointer-events: none; }
.ba__label--l { left: 20px; } .ba__label--r { right: 20px; background: var(--red); }

/* ---------- Process ---------- */
.process { background: var(--stone); }
.timeline { position: relative; display: grid; grid-template-columns: repeat(5, 1fr); gap: 24px; }
.timeline__line { position: absolute; top: 38px; left: 5%; right: 5%; height: 4px; background: var(--stone-2); border-radius: 4px; }
.timeline__line i { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--blue), var(--red)); border-radius: 4px; transition: width .2s linear; }
.step { position: relative; text-align: center; }
.step__num { width: 80px; height: 80px; border-radius: 50%; background: #fff; border: 4px solid var(--stone-2); display: grid; place-items: center; margin: 0 auto 22px; font-family: var(--font-h); font-weight: 900; font-size: 1.5rem; color: var(--navy); position: relative; z-index: 1; transition: background .5s, color .5s, border-color .5s, transform .5s var(--ease); }
.step.active .step__num { background: var(--navy); color: #fff; border-color: var(--red); transform: scale(1.08); }
.step h3 { font-family: var(--font-h); font-weight: 800; font-size: 1.15rem; color: var(--navy); margin-bottom: 8px; }
.step p { font-size: .92rem; color: var(--muted); }

/* ---------- Calculator ---------- */
.calc { background: linear-gradient(180deg, #fff 0%, var(--stone) 100%); }
.calc__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(40px, 6vw, 90px); align-items: center; }
.calc__intro p { color: var(--muted); }
.calc__perks { margin-top: 26px; display: grid; gap: 10px; font-weight: 600; color: var(--navy); }
.calc__card { background: #fff; border-radius: 28px; padding: clamp(26px, 4vw, 42px); box-shadow: var(--shadow-lg); border-top: 6px solid var(--red); }
.calc__step { margin-bottom: 26px; }
.calc__label { display: block; font-weight: 700; color: var(--navy); margin-bottom: 12px; font-size: .95rem; }
.calc__label strong { color: var(--red); }
.calc__types { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ctype { padding: 12px 6px; border-radius: 14px; border: 2px solid var(--stone-2); text-align: center; font-size: .8rem; font-weight: 600; color: var(--muted); transition: all .3s var(--ease); display: flex; flex-direction: column; align-items: center; gap: 6px; line-height: 1.2; }
.ctype svg { width: 26px; height: 26px; color: var(--blue); transition: color .3s; }
.ctype:hover { border-color: var(--blue); color: var(--navy); transform: translateY(-2px); }
.ctype.active { border-color: var(--navy); background: var(--navy); color: #fff; }
.ctype.active svg { color: var(--sky); }
.range { -webkit-appearance: none; appearance: none; width: 100%; height: 8px; border-radius: 8px; background: linear-gradient(90deg, var(--red) var(--fill, 5%), var(--stone-2) var(--fill, 5%)); outline: none; }
.range::-webkit-slider-thumb { -webkit-appearance: none; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 5px solid var(--red); cursor: grab; box-shadow: 0 4px 12px rgba(0,0,0,.25); transition: transform .2s; }
.range::-webkit-slider-thumb:active { transform: scale(1.2); cursor: grabbing; }
.range::-moz-range-thumb { width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 5px solid var(--red); cursor: grab; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); background: var(--stone); padding: 5px; border-radius: 14px; }
.seg button { padding: 11px; border-radius: 10px; font-weight: 600; font-size: .92rem; color: var(--muted); transition: all .3s; }
.seg button.active { background: #fff; color: var(--navy); box-shadow: 0 4px 14px -6px rgba(0,0,0,.3); }
.calc__result { background: var(--navy); color: #fff; border-radius: 18px; padding: 22px 24px; margin-bottom: 18px; text-align: center; position: relative; overflow: hidden; }
.calc__result::before { content: ''; position: absolute; inset: 0; background: repeating-linear-gradient(45deg, transparent 0 14px, rgba(255,255,255,.03) 14px 28px); }
.calc__kicker { font-size: .8rem; text-transform: uppercase; letter-spacing: .15em; opacity: .7; position: relative; display: block; }
.calc__price { font-family: var(--font-h); font-weight: 900; font-size: clamp(1.7rem, 3.4vw, 2.5rem); margin: 4px 0; position: relative; }
.calc__price b { font-weight: 900; }
.calc__result small { opacity: .6; font-size: .78rem; position: relative; }

/* ---------- Reviews ---------- */
.reviews { background: #fff; overflow: hidden; }
.reviews__head { display: flex; justify-content: space-between; align-items: flex-end; flex-wrap: wrap; gap: 30px; margin-bottom: 50px; }
.score { display: flex; align-items: center; gap: 18px; background: var(--stone); padding: 18px 26px; border-radius: 20px; }
.score__num { font-family: var(--font-h); font-weight: 900; font-size: 3.4rem; color: var(--navy); line-height: 1; }
.stars--lg { font-size: 1.5rem; }
.score span { font-size: .85rem; color: var(--muted); }
.carousel { position: relative; overflow: hidden; padding: 12px 2px 20px; margin: -12px -2px -20px; }
.carousel__track { display: flex; gap: 24px; transition: transform .7s var(--ease); cursor: grab; }
.carousel__track.dragging { transition: none; cursor: grabbing; }
.review { flex: 0 0 calc((100% - 48px) / 3); background: var(--stone); border-radius: 24px; padding: 30px; display: flex; flex-direction: column; position: relative; user-select: none; transition: transform .4s var(--ease), box-shadow .4s; }
.review--summary { background: linear-gradient(155deg, var(--stone) 0%, #fff 100%); border: 2px solid rgba(29,99,179,.16); }
.review:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.review::before { content: '"'; position: absolute; top: 4px; right: 24px; font-family: Georgia, serif; font-size: 7rem; color: rgba(214,43,43,.12); line-height: 1; }
.review__top { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.review__top time { font-size: .8rem; color: var(--muted); }
.review p { font-size: 1.08rem; color: var(--ink); flex: 1; font-weight: 500; }
.review__tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0; }
.review__tags span { font-size: .75rem; background: #fff; padding: 4px 10px; border-radius: 999px; color: var(--blue); font-weight: 600; }
.review__author { display: flex; align-items: center; gap: 12px; padding-top: 18px; border-top: 1px solid var(--stone-2); }
.review__author i { width: 44px; height: 44px; border-radius: 50%; background: var(--navy); color: #fff; display: grid; place-items: center; font-style: normal; font-family: var(--font-h); font-weight: 800; }
.review__author strong { display: block; color: var(--navy); }
.review__author small { color: var(--muted); }
.carousel__nav { display: flex; align-items: center; justify-content: center; gap: 20px; margin-top: 36px; }
.carousel__btn { width: 52px; height: 52px; border-radius: 50%; border: 2px solid var(--navy); color: var(--navy); font-size: 1.2rem; transition: all .3s; }
.carousel__btn:hover { background: var(--navy); color: #fff; }
.carousel__dots { display: flex; gap: 8px; }
.carousel__dots button { width: 10px; height: 10px; border-radius: 10px; background: var(--stone-2); transition: all .4s var(--ease); }
.carousel__dots button.active { width: 32px; background: var(--red); }

/* ---------- Zones ---------- */
.zones { background: var(--stone); }
.zones__grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: clamp(40px, 6vw, 80px); align-items: center; }
.zones p { color: var(--muted); }
.zones__chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.chip { padding: 10px 18px; border-radius: 999px; background: #fff; font-weight: 600; font-size: .9rem; color: var(--navy); border: 2px solid transparent; transition: all .3s var(--ease); cursor: pointer; }
.chip:hover { border-color: var(--red); transform: translateY(-3px) rotate(-2deg); }
.chip.active, .chip--main { background: var(--red); color: #fff; border-color: var(--red); }
.zones__map { border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-lg); aspect-ratio: 4 / 3; border: 6px solid #fff; }
.zones__map iframe { width: 100%; height: 100%; border: 0; filter: saturate(.9); }

/* ---------- FAQ ---------- */
.faq { background: #fff; }
.faq__grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(40px, 6vw, 80px); align-items: start; }
.faq p { color: var(--muted); }
.faq__grid > div:first-child { position: sticky; top: 120px; }
.accordion { display: grid; gap: 12px; }
.acc { background: var(--stone); border-radius: 18px; overflow: hidden; transition: background .3s, box-shadow .3s; }
.acc.open { background: #fff; box-shadow: var(--shadow); }
.acc__q { width: 100%; text-align: left; padding: 22px 26px; font-weight: 700; color: var(--navy); font-size: 1.04rem; display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.acc__q i { width: 32px; height: 32px; border-radius: 50%; background: var(--navy); position: relative; flex-shrink: 0; transition: transform .4s var(--ease), background .3s; }
.acc__q i::before, .acc__q i::after { content: ''; position: absolute; top: 50%; left: 50%; width: 12px; height: 2px; background: #fff; transform: translate(-50%, -50%); }
.acc__q i::after { transform: translate(-50%, -50%) rotate(90deg); transition: transform .4s var(--ease); }
.acc.open .acc__q i { background: var(--red); transform: rotate(180deg); }
.acc.open .acc__q i::after { transform: translate(-50%, -50%) rotate(0); }
.acc__a { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .5s var(--ease); }
.acc__a > p { overflow: hidden; padding: 0 26px; }
.acc.open .acc__a { grid-template-rows: 1fr; }
.acc.open .acc__a > p { padding-bottom: 22px; }

/* ---------- CTA ---------- */
.cta { position: relative; background-size: cover; background-position: center; background-attachment: fixed; padding: clamp(100px, 14vw, 170px) 0; color: #fff; text-align: center; }
.cta__overlay { position: absolute; inset: 0; background: linear-gradient(135deg, rgba(10,29,54,.92), rgba(19,54,97,.78)); }
.cta__inner { position: relative; }
.cta h2 { font-family: var(--font-h); font-weight: 900; font-size: clamp(2.2rem, 5vw, 4rem); line-height: 1.05; letter-spacing: -.02em; margin-bottom: 16px; }
.cta p { font-size: 1.15rem; opacity: .85; margin-bottom: 36px; }
.cta__actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------- Contact ---------- */
.contact__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(40px, 6vw, 80px); align-items: start; }
.contact__info > p { color: var(--muted); margin-bottom: 30px; }
.info-card { display: flex; align-items: center; gap: 16px; padding: 18px 20px; background: #fff; border-radius: 18px; margin-bottom: 12px; transition: transform .4s var(--ease), box-shadow .4s; }
.info-card:hover { transform: translateX(8px); box-shadow: var(--shadow); }
.info-card__icon { width: 50px; height: 50px; border-radius: 14px; background: var(--navy); color: #fff; display: grid; place-items: center; flex-shrink: 0; transition: background .3s; }
.info-card:hover .info-card__icon { background: var(--red); }
.info-card small { display: block; color: var(--muted); font-size: .8rem; }
.info-card strong { color: var(--navy); font-size: 1.05rem; }
.form { background: #fff; border-radius: 28px; padding: clamp(26px, 4vw, 44px); box-shadow: var(--shadow-lg); }
.form h3 { font-family: var(--font-h); font-weight: 800; font-size: 1.6rem; color: var(--navy); margin-bottom: 26px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { position: relative; margin-bottom: 14px; }
.field input, .field select, .field textarea { width: 100%; padding: 24px 18px 10px; border-radius: 14px; border: 2px solid var(--stone-2); background: var(--stone); font: inherit; font-size: 1rem; color: var(--ink); outline: none; transition: border-color .3s, background .3s; resize: vertical; appearance: none; }
.field select { cursor: pointer; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24'%3E%3Cpath fill='%230f2a4d' d='M7 10l5 5 5-5z'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 16px center; }
.field label { position: absolute; left: 20px; top: 17px; color: var(--muted); pointer-events: none; transition: all .25s var(--ease); font-size: 1rem; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); background: #fff; }
.field input:focus + label, .field input:not(:placeholder-shown) + label,
.field textarea:focus + label, .field textarea:not(:placeholder-shown) + label,
.field select:focus + label, .field select:valid + label { top: 7px; font-size: .74rem; color: var(--blue); font-weight: 600; }
.field.error input, .field.error select, .field.error textarea { border-color: var(--red); animation: shake .4s; }
@keyframes shake { 25% { transform: translateX(-6px); } 75% { transform: translateX(6px); } }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: .85rem; color: var(--muted); margin: 6px 0 22px; cursor: pointer; }
.check input { margin-top: 3px; accent-color: var(--red); width: 18px; height: 18px; }
.check.error span { color: var(--red); }
.form__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form__msg { margin-top: 14px; font-size: .92rem; font-weight: 600; min-height: 1.4em; }
.form__msg.ok { color: #138a43; } .form__msg.err { color: var(--red); }

/* ---------- Footer ---------- */
.footer { background: var(--navy-3); color: rgba(255,255,255,.7); padding: 80px 0 30px; font-size: .94rem; }
.footer__grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.2fr; gap: 40px; padding-bottom: 50px; border-bottom: 1px solid rgba(255,255,255,.1); }
.logo__svg--footer { width: 215px; margin-left: -10px; }
.footer__sub { color: var(--sky); font-weight: 600; font-size: .82rem; letter-spacing: .14em; text-transform: uppercase; margin: 6px 0 16px; }
.footer h4 { color: #fff; font-family: var(--font-h); font-size: 1rem; margin-bottom: 18px; }
.footer li { margin-bottom: 10px; }
.footer a:hover { color: #fff; }
.footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding-top: 26px; font-size: .84rem; }

/* ---------- Floating ---------- */
.wa-float { position: fixed; right: 22px; bottom: 22px; z-index: 900; width: 62px; height: 62px; border-radius: 50%; background: var(--wa); color: #fff; display: grid; place-items: center; box-shadow: 0 14px 30px -8px rgba(37,211,102,.7); transition: transform .4s var(--ease); }
.wa-float::before { content: ''; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--wa); animation: ring 2s infinite; }
@keyframes ring { from { transform: scale(1); opacity: .8; } to { transform: scale(1.6); opacity: 0; } }
.wa-float:hover { transform: scale(1.1); }
.wa-float__tip { position: absolute; right: 74px; background: #fff; color: var(--navy); padding: 8px 14px; border-radius: 12px; font-weight: 600; font-size: .88rem; white-space: nowrap; box-shadow: var(--shadow); opacity: 0; transform: translateX(10px); transition: all .4s var(--ease); pointer-events: none; }
.wa-float:hover .wa-float__tip, .wa-float.tip .wa-float__tip { opacity: 1; transform: none; }
.to-top { position: fixed; right: 30px; bottom: 98px; z-index: 900; width: 46px; height: 46px; border-radius: 50%; background: var(--navy); color: #fff; font-size: 1.2rem; box-shadow: var(--shadow); opacity: 0; transform: translateY(20px); pointer-events: none; transition: all .4s var(--ease); }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--red); }

/* ---------- Modal ---------- */
.modal { position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center; padding: 20px; visibility: hidden; pointer-events: none; }
.modal.open { visibility: visible; pointer-events: auto; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(10,29,54,.7); backdrop-filter: blur(6px); opacity: 0; transition: opacity .4s; }
.modal.open .modal__backdrop { opacity: 1; }
.modal__box { position: relative; background: #fff; border-radius: 28px; overflow: hidden; width: min(880px, 100%); max-height: 90vh; overflow-y: auto; display: grid; grid-template-columns: 1fr 1.1fr; transform: translateY(40px) scale(.96); opacity: 0; transition: all .5s var(--ease); }
.modal.open .modal__box { transform: none; opacity: 1; }
.modal__img { background-size: cover; background-position: center; min-height: 320px; }
.modal__body { padding: 40px 36px; }
.modal__body h3 { font-family: var(--font-h); font-weight: 800; font-size: 1.9rem; color: var(--navy); margin-bottom: 12px; line-height: 1.1; }
.modal__body p { color: var(--muted); margin-bottom: 18px; }
.modal__list { display: grid; gap: 8px; margin-bottom: 26px; }
.modal__list li { display: flex; gap: 10px; font-size: .94rem; }
.modal__list li::before { content: '✓'; color: #fff; background: var(--red); width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: .7rem; flex-shrink: 0; margin-top: 2px; }
.modal__close { position: absolute; top: 14px; right: 14px; width: 42px; height: 42px; border-radius: 50%; background: #fff; color: var(--navy); font-size: 1.6rem; z-index: 2; box-shadow: var(--shadow); transition: transform .3s; line-height: 1; }
.modal__close:hover { transform: rotate(90deg); }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 2000; background: rgba(5,14,28,.95); display: grid; place-items: center; opacity: 0; visibility: hidden; transition: all .4s; }
.lightbox.open { opacity: 1; visibility: visible; }
.lightbox figure { max-width: 88vw; text-align: center; }
.lightbox img { max-height: 80vh; max-width: 88vw; border-radius: 16px; margin: auto; transform: scale(.94); transition: transform .5s var(--ease), opacity .3s; box-shadow: 0 40px 80px rgba(0,0,0,.6); }
.lightbox.open img { transform: none; }
.lightbox figcaption { color: #fff; margin-top: 16px; font-weight: 600; }
.lightbox figcaption small { display: block; opacity: .6; font-weight: 400; }
.lightbox__close { position: absolute; top: 20px; right: 24px; color: #fff; font-size: 2.6rem; width: 54px; height: 54px; }
.lightbox__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 58px; height: 58px; border-radius: 50%; background: rgba(255,255,255,.1); color: #fff; font-size: 2rem; transition: background .3s; }
.lightbox__nav:hover { background: var(--red); }
.lightbox__nav--prev { left: 24px; } .lightbox__nav--next { right: 24px; }

/* ---------- Reveal animations ---------- */
.reveal, .reveal-left { opacity: 0; transform: translateY(40px); transition: opacity 1s var(--ease), transform 1s var(--ease); }
.reveal-left { transform: translateX(-60px); }
.reveal.in, .reveal-left.in { opacity: 1; transform: none; }
.hero .reveal { transition-delay: .5s; }
body:not(.loaded) .hero .reveal { opacity: 0; transform: translateY(40px); }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .nav__link { padding: 8px 8px; font-size: .88rem; }
  .services__grid { grid-template-columns: repeat(2, 1fr); }
  .calc__types { grid-template-columns: repeat(4, 1fr); }
}
@media (max-width: 980px) {
  .burger { display: block; }
  .nav { position: fixed; inset: 0; background: var(--navy-3); color: #fff; flex-direction: column; justify-content: center; gap: 8px; transform: translateX(100%); transition: transform .6s var(--ease); }
  .nav.open { transform: none; }
  .nav__link { font-family: var(--font-h); font-size: 1.6rem; font-weight: 800; opacity: 0; transform: translateY(20px); transition: all .5s var(--ease); }
  .nav.open .nav__link { opacity: 1; transform: none; }
  .nav.open .nav__link:nth-child(2) { transition-delay: .05s; } .nav.open .nav__link:nth-child(3) { transition-delay: .1s; }
  .nav.open .nav__link:nth-child(4) { transition-delay: .15s; } .nav.open .nav__link:nth-child(5) { transition-delay: .2s; }
  .nav.open .nav__link:nth-child(6) { transition-delay: .25s; } .nav.open .nav__link:nth-child(7) { transition-delay: .3s; }
  .nav__cta { margin: 20px 0 0; }
  .header.menu-open { color: #fff; background: transparent; box-shadow: none; backdrop-filter: none; }
  .about__grid, .calc__grid, .zones__grid, .faq__grid, .contact__grid { grid-template-columns: 1fr; }
  .faq__grid > div:first-child { position: static; }
  .about__media { max-width: 520px; margin: 0 auto 30px; width: 100%; }
  .projects__grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 230px; }
  .timeline { grid-template-columns: 1fr; gap: 28px; padding-left: 10px; }
  .timeline__line { top: 0; bottom: 0; left: 48px; right: auto; width: 4px; height: auto; }
  .timeline__line i { width: 100% !important; height: var(--h, 0); }
  .step { display: flex; text-align: left; gap: 22px; align-items: flex-start; }
  .step__num { margin: 0; flex-shrink: 0; }
  .review { flex-basis: calc((100% - 24px) / 2); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .modal__box { grid-template-columns: 1fr; }
  .modal__img { min-height: 220px; }
  .cta { background-attachment: scroll; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .logo__svg { width: 160px; }
  .services__grid { grid-template-columns: 1fr; }
  .svc { min-height: 0; }
  .projects__grid { grid-template-columns: 1fr; grid-auto-rows: 260px; }
  .project.wide { grid-column: auto; } .project.tall { grid-row: auto; }
  .project__info { transform: none; } .project__info p { opacity: .85; }
  .stats { grid-template-columns: 1fr; }
  .stat { display: flex; align-items: center; gap: 16px; }
  .stat__label { margin: 0; }
  .about__stamp { width: 100px; height: 100px; top: -24px; right: -10px; }
  .about__card { left: 10px; bottom: 20px; }
  .about__media::before { inset: 16px -12px -16px 16px; }
  .calc__types { grid-template-columns: repeat(2, 1fr); }
  .review { flex-basis: 100%; }
  .form__row, .form__actions { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .ba__slider { aspect-ratio: 4 / 3.4; }
  .ba__knob { width: 48px; height: 48px; }
  .hero__actions .btn { width: 100%; }
  .filters { width: 100%; justify-content: center; border-radius: 18px; }
  .lightbox__nav { width: 44px; height: 44px; }
  .lightbox__nav--prev { left: 8px; } .lightbox__nav--next { right: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
