/* =========================================================
   Puerto Ambientalis — Design System
   Ver design-system/puerto-ambientalis/MASTER.md para el detalle
   Tipografía cargada desde <link> en el <head> de cada página
   (preconnect + link, no @import — @import bloquea el render
   en cadena; un <link> en <head> permite que el navegador la
   pida en paralelo con el resto del CSS).
   ========================================================= */

:root {
  /* Color */
  --color-primary: #0E7C86;
  --color-primary-dark: #0B4F56;
  --color-primary-light: #E6F4F5;
  --color-secondary: #16A34A;
  --color-secondary-light: #EAF7EE;
  --color-accent: #C2410C;
  --color-accent-hover: #9A3412;
  --color-on-primary: #FFFFFF;
  --color-on-accent: #FFFFFF;
  --color-background: #FFFFFF;
  --color-surface-alt: #F5FAFA;
  --color-foreground: #0F172A;
  --color-body: #334155;
  --color-muted-foreground: #64748B;
  --color-border: #E2E8F0;
  --color-destructive: #DC2626;

  /* Typography — Fraunces (display serif, editorial character) +
     Public Sans (body, clean/legible, not Inter/Roboto) */
  --font-heading: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --font-body: 'Public Sans', 'Segoe UI', sans-serif;
  --text-xs: 0.8125rem;
  --text-sm: 0.9375rem;
  --text-base: 1rem;
  --text-lg: 1.1875rem;
  --text-xl: 1.5rem;
  --text-2xl: clamp(1.75rem, 1.3rem + 2vw, 2.25rem);
  --text-3xl: clamp(2.375rem, 1.35rem + 4.5vw, 3.75rem);

  /* Spacing */
  --space-xs: 0.25rem;
  --space-sm: 0.5rem;
  --space-md: 1rem;
  --space-lg: 1.5rem;
  --space-xl: 2rem;
  --space-2xl: 3rem;
  --space-3xl: 4rem;
  --space-4xl: 6rem;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 12px 24px rgba(15, 23, 42, 0.12);
  --shadow-xl: 0 24px 48px rgba(15, 23, 42, 0.16);

  /* Layout */
  --container-max: 1180px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --header-height: 76px;
  --ease-standard: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
body, h1, h2, h3, h4, p, figure, blockquote { margin: 0; }
ul[class], ol[class] { list-style: none; margin: 0; padding: 0; }
img, svg, picture { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; }

/* NOTE: deliberately NOT setting overflow-x on html/body — GSAP's
   ScrollTrigger documents that as a known source of broken scroll-position
   detection on some browsers (it can stop treating body as the scrolling
   element), which likely explains the animation glitches seen after adding
   it. The wave/watermark clipping relies on overflow:hidden on their own
   direct containers instead (.hero, .page-hero, the SVGs themselves). */
body {
  font-family: var(--font-body);
  color: var(--color-body);
  background: var(--color-background);
  font-size: var(--text-base);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100dvh;
  width: 100%;
}

h1, h2, h3, h4 {
  font-family: var(--font-heading);
  color: var(--color-foreground);
  line-height: 1.15;
  font-weight: 600;
  letter-spacing: -0.01em;
  font-optical-sizing: auto;
}

h1 { font-size: var(--text-3xl); font-weight: 500; letter-spacing: -0.02em; }
h2 { font-size: var(--text-2xl); font-weight: 500; letter-spacing: -0.015em; }
h3 { font-size: var(--text-xl); font-weight: 600; }

p.lead { font-size: var(--text-lg); color: var(--color-muted-foreground); }

/* ---------- Accessibility helpers ---------- */
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: absolute; left: 1rem; top: 1rem;
  transform: translateY(-150%);
  background: var(--color-primary-dark); color: #fff;
  padding: 0.75rem 1.25rem; border-radius: var(--radius-sm);
  z-index: 200; transition: transform 200ms var(--ease-standard);
}
.skip-link:focus { transform: translateY(0); }

:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 2px;
  border-radius: 4px;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--space-lg);
}
@media (min-width: 768px) {
  .container { padding-inline: var(--space-2xl); }
}

/* Base texture: a faint dotted graticule (nautical-chart grid) instead of a
   flat fill — the recurring motif that ties every section together. Sections
   with their own gradient (.hero, .page-hero, .cta-banner) override this
   fully via the `background` shorthand, so it only shows where intended. */
section {
  padding-block: var(--space-4xl);
  position: relative;
  background-color: var(--color-background);
  background-image: radial-gradient(circle at 1px 1px, rgba(14,124,134,0.09) 1px, transparent 0);
  background-size: 26px 26px;
}
section > .container { position: relative; z-index: 1; }
.section-alt {
  background-color: var(--color-surface-alt);
  background-image: radial-gradient(circle at 1px 1px, rgba(14,124,134,0.12) 1px, transparent 0);
  background-size: 26px 26px;
}
.section-dark {
  background-color: var(--color-primary-dark);
  background-image:
    radial-gradient(circle at 1px 1px, rgba(255,255,255,0.08) 1px, transparent 0),
    linear-gradient(160deg, var(--color-primary-dark), #083A40);
  background-size: 26px 26px, auto;
  color: #E7F5F4;
}
.section-dark h2, .section-dark h3 { color: #FFFFFF; }

/* Corner watermark — nested contour lines like a hydrographic chart,
   used behind coverage/geography sections. Purely decorative. */
.chart-watermark {
  position: absolute; top: 0; right: 0; bottom: 0; left: 0;
  overflow: hidden; z-index: 0; pointer-events: none;
}
.chart-watermark svg { position: absolute; top: 0; right: 0; width: min(46vw, 480px); height: 100%; }

.section-head { max-width: 640px; margin-bottom: var(--space-2xl); }
.section-head.center { margin-inline: auto; text-align: center; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--font-heading); font-weight: 500; font-style: italic;
  font-size: var(--text-lg); letter-spacing: 0.005em;
  color: var(--color-primary); margin-bottom: var(--space-sm);
}
.section-dark .eyebrow { color: #7FD7C4; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-family: var(--font-heading); font-weight: 600; font-size: var(--text-sm);
  padding: 0.9rem 1.6rem; border-radius: 999px;
  cursor: pointer; transition: transform 200ms var(--ease-standard), box-shadow 200ms var(--ease-standard), background 200ms var(--ease-standard);
  white-space: nowrap;
}
.btn svg { width: 18px; height: 18px; aspect-ratio: 1 / 1; flex-shrink: 0; }
.btn-primary {
  background: var(--color-accent); color: var(--color-on-accent);
  box-shadow: var(--shadow-md);
}
.btn-primary:hover { background: var(--color-accent-hover); transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.btn-outline {
  background: transparent; border: 1.5px solid currentColor; color: inherit;
}
.btn-outline:hover { background: rgba(255,255,255,0.08); transform: translateY(-2px); }
.btn-ghost { background: var(--color-primary-light); color: var(--color-primary-dark); }
.btn-ghost:hover { background: #d7ecec; transform: translateY(-2px); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-height);
  display: flex; align-items: center;
  background: rgba(255,255,255,0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: box-shadow 250ms var(--ease-standard), border-color 250ms var(--ease-standard);
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); border-color: var(--color-border); }
.site-header .container { display: flex; align-items: center; justify-content: space-between; gap: var(--space-lg); }
.brand { display: flex; align-items: center; }
.brand img { height: 50px; width: auto; }
@media (max-width: 420px) { .brand img { height: 42px; } }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: var(--radius-sm);
  cursor: pointer;
}
.nav-toggle:hover { background: var(--color-primary-light); }
.nav-toggle svg { width: 26px; height: 26px; aspect-ratio: 1 / 1; flex-shrink: 0; }

.main-nav {
  display: flex; align-items: center; gap: var(--space-2xl);
}
.main-nav ul { display: flex; align-items: center; gap: var(--space-xl); }
.main-nav a:not(.btn) {
  font-family: var(--font-heading); font-weight: 500; font-size: var(--text-sm);
  color: var(--color-body); padding: 0.4rem 0.1rem; position: relative;
}
.main-nav a:not(.btn)::after {
  content: ''; position: absolute; left: 0; bottom: -4px; height: 2px; width: 0;
  background: var(--color-accent); transition: width 200ms var(--ease-standard);
}
.main-nav a:not(.btn):hover::after,
.main-nav a[aria-current="page"]::after { width: 100%; }
.main-nav a[aria-current="page"] { color: var(--color-primary-dark); }
.nav-cta { display: flex; align-items: center; gap: var(--space-md); }

@media (max-width: 900px) {
  .nav-toggle { display: inline-flex; }
  .main-nav {
    /* Explicit top/left/right + height instead of the `inset` shorthand
       and bottom:0 — some mobile browsers resolve those unreliably on a
       fixed element, collapsing it to near-zero height instead of filling
       the screen. This is the compatible, spelled-out equivalent. */
    position: fixed;
    top: var(--header-height); left: 0; right: 0;
    height: calc(100vh - var(--header-height));
    height: calc(100dvh - var(--header-height));
    z-index: 150;
    background: #fff; flex-direction: column; align-items: flex-start;
    padding: var(--space-xl) var(--space-lg); gap: var(--space-xl);
    transform: translateY(-12px); opacity: 0; pointer-events: none;
    transition: opacity 220ms var(--ease-standard), transform 220ms var(--ease-standard);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }
  .main-nav ul { flex-direction: column; align-items: flex-start; gap: var(--space-lg); width: 100%; }
  .main-nav a:not(.btn) { font-size: var(--text-xl); }
  .nav-cta { width: 100%; }
  .nav-cta .btn { width: 100%; }
  .main-nav.is-open { opacity: 1; transform: translateY(0); pointer-events: auto; }
  body.nav-open { overflow: hidden; }
}
@media (min-width: 901px) {
  .nav-toggle { display: none; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden;
  padding-block: var(--space-4xl) var(--space-3xl);
  background: linear-gradient(170deg, var(--color-primary-dark) 0%, var(--color-primary) 62%, #12959f 100%);
  color: #F0FBFA;
}
.hero__waves { position: absolute; left: 0; right: 0; bottom: -2px; line-height: 0; }
/* Fixed height (not height:auto) so the wave never grows tall enough to
   intrude on the text above it on wide viewports — with preserveAspectRatio
   ="none" on the SVG itself, it just flattens gracefully instead of scaling
   up with the width. The SVG box itself always stays exactly 100% wide —
   simple, predictable sizing that never needs to change. */
.hero__waves svg { width: 100%; height: 64px; display: block; overflow: hidden; }
.hero__waves .wave-layer { position: absolute; left: 0; right: 0; bottom: -2px; line-height: 0; }
.hero__waves .wave-layer--back { opacity: 0.5; transform: translateY(6px) scale(1.02); }
.hero__waves .wave-layer--front { opacity: 1; }
/* The motion lives INSIDE the fixed-size SVG instead: the wave path is
   drawn 3 times side by side in the viewBox's own coordinate space (see the
   HTML), only the middle copy sits inside the visible 0..1440 window at
   rest. main.js slides this <g> left/right in that same coordinate space —
   since the pattern is truly periodic, sliding it in either direction just
   reveals more of the identical shape, no seam, nothing to clip. */
/* No will-change here on purpose — promoting this SVG <g> to its own
   compositing layer is the likely reason Safari on iOS was letting the
   drifting wave content escape its overflow:hidden clip and widen the
   whole page. The animation is cheap enough without the hint. */

/* Parallax float on hero art / badges — disabled under reduced motion via JS */
[data-parallax] { will-change: transform; }

/* ---------- Scroll progress bar ---------- */
.scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 100%;
  transform: scaleX(0); transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--color-accent), var(--color-secondary));
  z-index: 200; pointer-events: none;
}
.hero .container { position: relative; z-index: 2; }
.hero-grid { display: grid; gap: var(--space-2xl); align-items: center; }
@media (min-width: 960px) { .hero-grid { grid-template-columns: 1.1fr 0.9fr; } }
.hero h1 { color: #FFFFFF; max-width: 16ch; }
.hero p.lead { color: #D3ECEA; max-width: 46ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: var(--space-md); margin-top: var(--space-xl); }
.hero-badges { display: flex; flex-wrap: wrap; gap: var(--space-sm); margin-top: var(--space-2xl); }
.hero-badge {
  display: inline-flex; align-items: center; gap: 0.4rem;
  background: rgba(8,40,44,0.35); border: 1px solid rgba(255,255,255,0.4);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  box-shadow: 0 1px 3px rgba(0,0,0,0.15);
  padding: 0.5rem 0.9rem; border-radius: 999px; font-size: var(--text-xs);
  font-family: var(--font-heading); font-weight: 600; color: #fff;
}
.hero-badge svg { width: 15px; height: 15px; aspect-ratio: 1 / 1; flex-shrink: 0; }

/* 4:3 box via the padding-bottom technique rather than the `aspect-ratio`
   property — same reliability issue seen elsewhere in this project (an
   explicit aspect-ratio here didn't always hold either). */
.hero-art {
  position: relative; border-radius: var(--radius-lg);
  background: rgba(8,40,44,0.28); border: 1px solid rgba(255,255,255,0.28);
  overflow: hidden; box-shadow: var(--shadow-xl);
}
.hero-art::before { content: ''; display: block; padding-bottom: 75%; }
.hero-art img, .hero-art svg {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block;
}

.page-hero {
  background: linear-gradient(170deg, var(--color-primary-dark), var(--color-primary));
  color: #F0FBFA; padding-block: calc(var(--space-4xl) - 1rem) calc(var(--space-4xl) + 0.5rem);
  position: relative; overflow: hidden;
}
.page-hero h1 { color: #fff; max-width: 22ch; }
.page-hero p.lead { color: #D3ECEA; max-width: 56ch; }
.breadcrumb { display: flex; gap: 0.4rem; align-items: center; font-size: var(--text-sm); color: #BFE3E0; margin-bottom: var(--space-md); }

/* ---------- Cards ---------- */
.card-grid { display: grid; gap: var(--space-xl); grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.card {
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-md);
  padding: var(--space-xl); box-shadow: var(--shadow-sm);
  transition: transform 220ms var(--ease-standard), box-shadow 220ms var(--ease-standard), border-color 220ms var(--ease-standard);
}
.card:hover {
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(-4px);
  box-shadow: var(--shadow-lg); border-color: var(--color-primary-light);
}
/* Contact form: stays put on hover — no tilt, no lift. It's a rectangle
   full of inputs someone is trying to click into, not a decorative card. */
#contact-form:hover {
  transform: none; box-shadow: var(--shadow-sm); border-color: var(--color-border);
}

/* Photo card — a .card variant whose image bleeds to the edges (top
   corners follow the card's own border-radius via overflow:hidden), with
   the usual card padding kept for the text underneath.
   The aspect ratio uses the classic padding-bottom technique rather than
   the `aspect-ratio` property — the latter rendered unreliably here (an
   image stretched to fill the card's full height instead of holding its
   3:2 ratio), the same category of issue seen earlier with icon sizing. */
.photo-card { padding: 0; overflow: hidden; }
.photo-card__media { position: relative; width: 100%; padding-bottom: 66.666%; overflow: hidden; }
.photo-card__media img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.photo-card h3 { padding-inline: var(--space-xl); margin-top: var(--space-lg); }
.photo-card p { padding-inline: var(--space-xl); padding-bottom: var(--space-xl); margin-top: var(--space-sm); }
/* Icon reveal target for the clip-path "wipe open" entrance (see main.js) */
.card__icon { transform-origin: 50% 50%; }
.card--on-dark {
  background: rgba(8,40,44,0.4); border-color: rgba(255,255,255,0.22);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.card--on-dark:hover { border-color: rgba(255,255,255,0.4); }
.card__icon {
  width: 52px; height: 52px; border-radius: var(--radius-sm);
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--color-primary-light); color: var(--color-primary-dark);
  margin-bottom: var(--space-md);
  flex-shrink: 0; /* stay square inside flex rows (.contact-info__item) even
    when the sibling text is long enough to want to shrink it */
}
.card__icon svg { width: 26px; height: 26px; aspect-ratio: 1 / 1; flex-shrink: 0; }
.card h3 { margin-bottom: var(--space-sm); }
.card p { color: var(--color-muted-foreground); font-size: var(--text-sm); }

/* ---------- Process / Timeline ---------- */
.process { display: grid; gap: var(--space-xl); counter-reset: step; }
@media (min-width: 800px) { .process { grid-template-columns: repeat(3, 1fr); } }
.process__step {
  position: relative; background: #fff; border: 1px solid var(--color-border);
  border-radius: var(--radius-md); padding: var(--space-xl); box-shadow: var(--shadow-sm);
  transition: transform 220ms var(--ease-standard), box-shadow 220ms var(--ease-standard), border-color 220ms var(--ease-standard);
}
.process__step:hover {
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(-3px);
  box-shadow: var(--shadow-md); border-color: var(--color-primary-light);
}
.process__num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 999px; background: var(--color-accent); color: #fff;
  font-family: var(--font-heading); font-weight: 700; margin-bottom: var(--space-md);
}
@media (min-width: 800px) {
  .process__step:not(:last-child)::after {
    content: ''; position: absolute; top: 40px; right: -20px; width: 20px; height: 2px;
    background: var(--color-border);
  }
}

/* ---------- Chips / tags ---------- */
.chip-row { display: flex; flex-wrap: wrap; gap: var(--space-sm); }
.chip {
  display: inline-flex; align-items: center; gap: 0.4rem;
  padding: 0.5rem 1rem; border-radius: 999px; font-size: var(--text-sm);
  font-family: var(--font-heading); font-weight: 500;
  background: var(--color-secondary-light); color: #115C2C;
  border: 1px solid #CDEFD8;
}
.chip svg { width: 16px; height: 16px; aspect-ratio: 1 / 1; flex-shrink: 0; }
.chip--muted { background: var(--color-primary-light); color: var(--color-primary-dark); border-color: #CDEBEB; }

/* ---------- Coverage list ---------- */
.coverage-grid { display: grid; gap: var(--space-md); grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.coverage-item {
  display: flex; align-items: center; gap: var(--space-md);
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-md);
  padding: var(--space-lg);
  transition: transform 220ms var(--ease-standard), box-shadow 220ms var(--ease-standard), border-color 220ms var(--ease-standard);
}
.coverage-item:hover {
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(-3px);
  box-shadow: var(--shadow-md); border-color: var(--color-primary-light);
}
.coverage-item__icon {
  width: 44px; height: 44px; border-radius: 999px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--color-primary); color: #fff;
}
.coverage-item__icon svg { width: 20px; height: 20px; aspect-ratio: 1 / 1; flex-shrink: 0; }
.coverage-item strong { display: block; font-family: var(--font-heading); font-size: var(--text-base); color: var(--color-foreground); }
.coverage-item span { font-size: var(--text-xs); color: var(--color-muted-foreground); }

/* ---------- Values / stats ---------- */
.value-grid { display: grid; gap: var(--space-xl); grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.value-item { text-align: left; }
.value-item .card__icon { background: var(--color-secondary-light); color: #115C2C; }

.stat-row { display: grid; gap: var(--space-xl); grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); text-align: center; }
.stat-item strong { display: block; font-family: var(--font-heading); font-size: var(--text-3xl); color: #fff; }
.stat-item span { font-size: var(--text-sm); color: #BFE3E0; }

/* ---------- CTA banner ---------- */
.cta-banner {
  background: linear-gradient(135deg, var(--color-secondary), #0E7C86);
  border-radius: var(--radius-lg); color: #fff;
  padding: var(--space-3xl) var(--space-2xl);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: var(--space-xl);
}
.cta-banner h2 { color: #fff; margin-bottom: 0.4rem; }
.cta-banner p { color: #E6F7EF; }

/* ---------- Forms ---------- */
.form-grid { display: grid; gap: var(--space-lg); }
@media (min-width: 700px) { .form-grid.two-col { grid-template-columns: 1fr 1fr; } }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field.full { grid-column: 1 / -1; }
.field label {
  font-family: var(--font-heading); font-weight: 600; font-size: var(--text-sm); color: var(--color-foreground);
}
.field .required { color: var(--color-accent); }
.field input, .field textarea, .field select {
  font: inherit; padding: 0.85rem 1rem; border: 1.5px solid var(--color-border);
  border-radius: var(--radius-sm); background: #fff; color: var(--color-foreground);
  transition: border-color 180ms var(--ease-standard), box-shadow 180ms var(--ease-standard);
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: none; border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(14,124,134,0.16);
}
.field textarea { resize: vertical; min-height: 130px; }
.field small { font-size: var(--text-xs); color: var(--color-muted-foreground); }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--color-destructive); }
.field-error { color: var(--color-destructive); font-size: var(--text-xs); display: none; }
.field.has-error .field-error { display: block; }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status {
  display: none; padding: var(--space-md) var(--space-lg); border-radius: var(--radius-sm);
  font-size: var(--text-sm); margin-top: var(--space-lg);
}
.form-status.is-visible { display: block; }
.form-status.success { background: var(--color-secondary-light); color: #115C2C; border: 1px solid #CDEFD8; }
.form-status.error { background: #FDECEC; color: #8A1C1C; border: 1px solid #F6C6C6; }

/* ---------- Contact info blocks ---------- */
.contact-info {
  display: grid; gap: var(--space-lg); grid-template-columns: repeat(auto-fit, minmax(240px,1fr));
  align-items: stretch; margin-bottom: var(--space-2xl);
}
/* With fewer than 4 items (e.g. phone/WhatsApp not active yet), stretching each
   card to fill an 1fr column leaves them oddly wide and empty-looking. Cap the
   column width and center the row instead, so 2-3 cards read as an intentional
   compact layout rather than a grid with pieces missing. */
.contact-info--compact { grid-template-columns: repeat(auto-fit, minmax(280px, 420px)); justify-content: center; }
.contact-info__item a { white-space: nowrap; }
@media (max-width: 420px) { .contact-info__item a { white-space: normal; } }
.contact-info__item {
  background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius-md);
  padding: var(--space-lg); display: flex; gap: var(--space-md); align-items: flex-start;
  transition: transform 220ms var(--ease-standard), box-shadow 220ms var(--ease-standard), border-color 220ms var(--ease-standard);
}
.contact-info__item:hover {
  transform: perspective(900px) rotateX(var(--tilt-y, 0deg)) rotateY(var(--tilt-x, 0deg)) translateY(-3px);
  box-shadow: var(--shadow-md); border-color: var(--color-primary-light);
}
.contact-info__item .card__icon { margin-bottom: 0; }
.contact-info__item > div { min-width: 0; }
.contact-info__item strong { display: block; font-family: var(--font-heading); color: var(--color-foreground); margin-bottom: 0.2rem; }
.contact-info__item a { overflow-wrap: break-word; word-break: break-word; }
.contact-info__item .pending {
  font-size: var(--text-xs); color: var(--color-accent); font-weight: 600;
  display: inline-flex; align-items: center; gap: 0.3rem; margin-top: 0.3rem;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--color-primary-dark); color: #CFE9E6; padding-block: var(--space-3xl) var(--space-xl);
}
.footer-grid { display: grid; gap: var(--space-2xl); grid-template-columns: 2.2fr 1fr 1fr 1fr; }
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 500px) { .footer-grid { grid-template-columns: 1fr; } }
.footer-grid h4 { color: #fff; font-size: var(--text-sm); text-transform: uppercase; letter-spacing: 0.06em; margin-bottom: var(--space-md); }
.footer-grid ul { display: flex; flex-direction: column; gap: var(--space-sm); }
.footer-grid a { font-size: var(--text-sm); color: #CFE9E6; transition: color 180ms; }
.footer-grid a:hover { color: #fff; }
.footer-brand-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 14px;
  background: #fff; border-radius: 16px; padding: 24px 28px;
  width: 100%; max-width: 320px; box-sizing: border-box;
}
.footer-brand-card img { width: 100%; height: auto; display: block; }
.footer-brand-card__divider { width: 34px; height: 2px; border-radius: 2px; background: var(--color-primary); flex-shrink: 0; }
.footer-brand-card__slogan {
  font-size: 12.5px; line-height: 1.65; letter-spacing: 0.08em; text-transform: uppercase;
  font-weight: 600; color: var(--color-primary);
}
.footer-brand p { font-size: var(--text-sm); color: #A9D2CE; max-width: 32ch; margin-top: var(--space-md); }
.social-row { display: flex; gap: var(--space-sm); margin-top: var(--space-lg); }
.social-row a {
  width: 40px; height: 40px; border-radius: 999px; background: rgba(255,255,255,0.1);
  display: inline-flex; align-items: center; justify-content: center;
}
.social-row a:hover { background: rgba(255,255,255,0.2); }
.social-row svg { width: 18px; height: 18px; aspect-ratio: 1 / 1; flex-shrink: 0; }
.footer-bottom {
  margin-top: var(--space-2xl); padding-top: var(--space-lg); border-top: 1px solid rgba(255,255,255,0.12);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: var(--space-md);
  font-size: var(--text-xs); color: #9CC7C2;
}

/* ---------- Utilities ---------- */
.text-center { text-align: center; }
.mt-lg { margin-top: var(--space-lg); }
.reveal { will-change: transform, opacity; }

/* ---------- Spotlight hover glow ----------
   Soft brand-colored glow that follows the cursor over info cards.
   Pointer/hover devices only (set up in main.js) — never applied on touch,
   so it costs nothing on mobile. --spot-x/--spot-y are set by JS in px,
   relative to the element itself. */
@media (hover: hover) and (pointer: fine) {
  .glow-target {
    position: relative;
    --glow-rgb: 125, 199, 205; /* light, airy teal — a wash, not a solid tint */
  }
  .glow-target > * { position: relative; z-index: 1; }
  .glow-target::before {
    content: '';
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: inherit;
    background: radial-gradient(
      280px circle at var(--spot-x, 50%) var(--spot-y, 50%),
      rgba(var(--glow-rgb), 0.09),
      transparent 62%
    );
    opacity: 0;
    transition: opacity 280ms ease;
    pointer-events: none;
  }
  .glow-target:hover::before,
  .glow-target:focus-within::before { opacity: 1; }

  /* On dark surfaces the same light wash needs a touch more presence to
     read against the dark background — matches the eyebrow accent already
     used on dark sections. */
  .section-dark .glow-target { --glow-rgb: 176, 230, 222; }
  .section-dark .glow-target::before {
    background: radial-gradient(
      280px circle at var(--spot-x, 50%) var(--spot-y, 50%),
      rgba(var(--glow-rgb), 0.16),
      transparent 62%
    );
  }
}
