:root {
  --navy: #143a66;
  --navy-mid: #1f4f88;
  --navy-soft: #2f66a8;
  --red: #b22234;
  --red-soft: #c94c5a;
  --white: #ffffff;
  --off: #f3f7fb;
  --muted: #4a5568;
  --shadow: 0 24px 60px rgba(20, 58, 102, 0.28);
  --font-display: "Newsreader", Georgia, serif;
  --font-body: "Sora", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --header-h: 4.25rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--navy);
  background: var(--off);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

.container {
  width: min(1120px, calc(100% - 1.5rem));
  margin-inline: auto;
}

section[id],
#top {
  scroll-margin-top: calc(var(--header-h) + 0.5rem);
}

/* —— Header (mobile first) —— */
.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 60;
  padding: 0.75rem 0;
  /* Let clicks reach the sibling nav links underneath the header bar */
  pointer-events: none;
  transition: background 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(20, 58, 102, 0.94);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.22);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-height: 3rem;
  position: relative;
  z-index: 2;
}

.brand {
  display: flex;
  align-items: center;
  color: var(--white);
  z-index: 60;
  position: relative;
  pointer-events: auto;
}

.brand-logo {
  height: 36px;
  width: auto;
  max-width: min(200px, 55vw);
  object-fit: contain;
}

.menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.3);
  background: transparent;
  color: var(--white);
  width: 44px;
  height: 44px;
  border-radius: 4px;
  cursor: pointer;
  z-index: 2;
  position: relative;
  pointer-events: auto;
}

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  height: 100dvh;
  max-height: 100dvh;
  padding: calc(var(--header-h) + 1rem) 1.25rem 2rem;
  padding-bottom: max(2rem, env(safe-area-inset-bottom));
  background: rgba(18, 52, 92, 0.98);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  transform: translate3d(100%, 0, 0);
  transition: transform 0.35s var(--ease);
  z-index: 55;
  overflow-x: hidden;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  visibility: hidden;
  pointer-events: none;
}

.nav.is-open {
  transform: translate3d(0, 0, 0);
  visibility: visible;
  pointer-events: auto;
}

.nav a {
  color: rgba(255, 255, 255, 0.82);
  font-size: 1.15rem;
  font-weight: 500;
  padding: 0.85rem 0.9rem;
  border-radius: 4px;
  border-left: 3px solid transparent;
  transition: color 0.25s var(--ease), background 0.25s var(--ease), border-color 0.25s var(--ease);
}

.nav a:hover,
.nav a:focus-visible {
  color: var(--white);
  background: rgba(255, 255, 255, 0.06);
}

.nav a.is-active {
  color: var(--white);
  background: rgba(178, 34, 52, 0.18);
  border-left-color: var(--red);
}

.lang-toggle {
  display: inline-flex;
  align-self: flex-start;
  margin-top: 1rem;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  overflow: hidden;
}

.lang-toggle button {
  border: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.7);
  padding: 0.4rem 0.55rem;
  cursor: pointer;
  font-size: 0.72rem;
  letter-spacing: 0.04em;
  font-weight: 600;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.lang-toggle button.is-active {
  background: rgba(255, 255, 255, 0.16);
  color: var(--white);
}

.lang-flag {
  width: 1.15rem;
  height: 0.8rem;
  border-radius: 2px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25);
  flex-shrink: 0;
}

body.nav-open {
  overflow: hidden;
  touch-action: none;
  position: fixed;
  inset: 0 0 auto;
  width: 100%;
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  align-items: end;
  color: var(--white);
  overflow: hidden;
  background: var(--navy);
}

.hero-media {
  position: absolute;
  inset: 0;
}

.hero-liberty {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 28% center;
  z-index: 0;
}

.hero-flag {
  position: absolute;
  /* Torch tip in hero photo ≈ 18% from top — keep flag top on that line */
  top: 18%;
  right: max(0.75rem, 3.5vw);
  z-index: 2;
  width: min(54vw, 240px);
  aspect-ratio: 16 / 9;
  border-radius: 2px;
  overflow: hidden;
  pointer-events: none;
  opacity: 0.34;
  filter: saturate(0.48) brightness(0.78) contrast(0.9);
  box-shadow: none;
  background: transparent;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 78%, transparent 100%),
    linear-gradient(to right, transparent 0%, #000 6%, #000 94%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to bottom, #000 0%, #000 78%, transparent 100%),
    linear-gradient(to right, transparent 0%, #000 6%, #000 94%, transparent 100%);
  mask-composite: intersect;
}

.hero-flag::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  background: linear-gradient(
    145deg,
    rgba(16, 42, 78, 0.55) 0%,
    rgba(16, 42, 78, 0.32) 45%,
    rgba(16, 42, 78, 0.48) 100%
  );
  pointer-events: none;
}

.hero-flag-video {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 0.35s ease;
}

.hero-flag-video.is-playing {
  opacity: 1;
}

.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background:
    linear-gradient(105deg, rgba(16, 42, 78, 0.86) 0%, rgba(16, 42, 78, 0.55) 48%, rgba(178, 34, 52, 0.16) 100%),
    linear-gradient(to top, rgba(16, 42, 78, 0.9) 0%, rgba(16, 42, 78, 0.25) 42%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 3;
  padding: 6.5rem 0 3.25rem;
}

.hero-kicker {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75);
  margin-bottom: 0.85rem;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.15s forwards;
}

.hero h1 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2.35rem, 11vw, 5.4rem);
  line-height: 0.98;
  letter-spacing: -0.02em;
  max-width: 12ch;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.28s forwards;
}

.hero-lead {
  margin: 1.15rem 0 0;
  max-width: 34rem;
  font-size: clamp(0.98rem, 3.4vw, 1.15rem);
  color: rgba(255, 255, 255, 0.86);
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.42s forwards;
}

.hero-actions {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 1.75rem;
  opacity: 0;
  animation: rise 0.9s var(--ease) 0.55s forwards;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 48px;
  width: 100%;
  padding: 0.8rem 1.25rem;
  border-radius: 3px;
  border: 1px solid transparent;
  font-size: 0.92rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: transform 0.25s var(--ease), background 0.25s var(--ease), border-color 0.25s var(--ease);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  background: var(--red);
  color: var(--white);
}

.btn-primary:hover {
  background: var(--red-soft);
}

.phone-display {
  cursor: default;
  pointer-events: none;
  text-decoration: none;
  user-select: text;
}

span.btn.phone-display:hover {
  transform: none;
  background: var(--red);
}

.btn-ghost {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.35);
}

.btn-ghost:hover {
  border-color: var(--white);
}

.hero-stripe {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--navy) 0 34%, var(--white) 34% 42%, var(--red) 42%);
  z-index: 3;
}

/* —— Sections —— */
.section {
  padding: 3.5rem 0;
}

.section-head {
  max-width: 40rem;
  margin-bottom: 1.75rem;
}

.section-head p.eyebrow {
  margin: 0 0 0.55rem;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red);
  font-weight: 600;
}

.section-head h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 7vw, 3rem);
  line-height: 1.12;
  letter-spacing: -0.02em;
}

.section-head .sub {
  margin: 0.8rem 0 0;
  color: var(--muted);
  font-size: 0.98rem;
}

.about {
  background: var(--off);
}

.office {
  background: var(--white);
}

.about-grid,
.contact-grid,
.services-grid,
.photo-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.about-copy p {
  color: var(--muted);
  margin: 0 0 1rem;
}

.values {
  list-style: none;
  margin: 1.25rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.75rem;
}

.values li {
  display: grid;
  grid-template-columns: 18px 1fr;
  gap: 0.7rem;
  align-items: start;
  color: var(--navy);
  font-weight: 500;
  font-size: 0.95rem;
}

.values li::before {
  content: "";
  width: 10px;
  height: 10px;
  margin-top: 0.4rem;
  background: var(--red);
  border-radius: 1px;
}

.about-panel {
  position: relative;
  min-height: 260px;
  border-radius: 4px;
  overflow: hidden;
  background: var(--navy);
  box-shadow: var(--shadow);
}

.about-panel img {
  width: 100%;
  height: 100%;
  min-height: 260px;
  object-fit: cover;
  opacity: 0.78;
}

.about-panel-caption {
  position: absolute;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  color: var(--white);
  font-family: var(--font-display);
  font-size: 1.15rem;
  line-height: 1.25;
}

.photo {
  margin: 0;
  overflow: hidden;
  border-radius: 4px;
  background: var(--navy);
}

.photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
  transition: transform 0.6s var(--ease);
}

.photo:hover img {
  transform: scale(1.04);
}

.photo-lg img {
  aspect-ratio: 16 / 10;
}

.services {
  background:
    radial-gradient(circle at top right, rgba(178, 34, 52, 0.08), transparent 40%),
    var(--off);
}

.service {
  background: var(--white);
  border: 1px solid rgba(11, 31, 58, 0.08);
  border-radius: 4px;
  padding: 1.25rem 1.15rem 1.35rem;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s var(--ease);
}

.service:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 40px rgba(11, 31, 58, 0.1);
  border-color: rgba(178, 34, 52, 0.25);
}

.service-num {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: var(--red);
  font-weight: 700;
}

.service h3 {
  margin: 0.5rem 0 0.55rem;
  font-family: var(--font-display);
  font-size: 1.3rem;
  line-height: 1.15;
}

.service p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

.service ul {
  margin: 0.9rem 0 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.3rem;
}

.service li {
  position: relative;
  padding-left: 0.9rem;
  font-size: 0.86rem;
  color: var(--navy-mid);
}

.service li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 6px;
  height: 2px;
  background: var(--red);
}

.cta-band {
  background: linear-gradient(120deg, var(--navy) 0%, var(--navy-mid) 55%, #3a1a22 100%);
  color: var(--white);
  padding: 2.75rem 0;
}

.cta-inner {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.25rem;
}

.cta-inner h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 6vw, 2.5rem);
  max-width: 18ch;
  line-height: 1.12;
}

.cta-inner p {
  margin: 0.5rem 0 0;
  color: rgba(255, 255, 255, 0.78);
  max-width: 36rem;
}

.cta-inner .btn {
  width: auto;
  min-width: 11rem;
}

.contact {
  background: var(--white);
}

.contact-card {
  background: var(--navy);
  color: var(--white);
  border-radius: 4px;
  padding: 1.5rem 1.25rem;
}

.contact-card h3 {
  margin: 0 0 1.1rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
}

.contact-meta {
  display: grid;
  gap: 1rem;
}

.contact-meta dt {
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
  margin-bottom: 0.2rem;
}

.contact-meta dd {
  margin: 0;
  font-size: 0.98rem;
}

.contact-meta a:hover {
  color: #ffd7dc;
}

.form {
  display: grid;
  gap: 0.9rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.9rem;
}

.field label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--navy);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  border: 1px solid rgba(11, 31, 58, 0.16);
  border-radius: 3px;
  padding: 0.85rem 0.9rem;
  background: var(--off);
  color: var(--navy);
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--navy-mid);
  box-shadow: 0 0 0 3px rgba(30, 58, 95, 0.12);
}

.field textarea {
  min-height: 130px;
  resize: vertical;
}

.form-status {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 600;
  min-height: 1.2em;
}

.form-status.is-ok {
  color: #1f7a4d;
}

.form-status.is-err {
  color: var(--red);
}

.site-footer {
  background: #0f2f54;
  color: rgba(255, 255, 255, 0.72);
  padding: 2rem 0;
  font-size: 0.86rem;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-brand {
  display: grid;
  gap: 0.5rem;
}

.footer-brand img {
  height: 32px;
  width: auto;
}

.footer-brand p {
  margin: 0;
  max-width: 28rem;
}

.footer-meta {
  display: grid;
  gap: 0.65rem;
}

.footer-credit {
  margin: 0;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: rgba(255, 255, 255, 0.48);
}

.footer-credit a {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  transition: color 0.25s var(--ease), border-color 0.25s var(--ease);
}

.footer-credit a:hover,
.footer-credit a:focus-visible {
  color: var(--white);
  border-bottom-color: rgba(255, 255, 255, 0.55);
}

.hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

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

@keyframes heroZoom {
  from {
    transform: scale(1.04);
  }
  to {
    transform: scale(1.1);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal,
  .nav,
  .btn {
    animation: none !important;
    transition: none !important;
  }

  .header-flag-video {
    display: none;
  }

  .hero-flag-video {
    display: none;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

[data-lang] {
  display: none !important;
}

html[lang="en"] [data-lang="en"],
html[lang="es"] [data-lang="es"],
html[lang="fr"] [data-lang="fr"],
html[lang="ht"] [data-lang="ht"] {
  display: revert !important;
}

/* —— Tablet+ —— */
@media (min-width: 640px) {
  .container {
    width: min(1120px, calc(100% - 2rem));
  }

  .brand-logo {
    height: 40px;
  }

  .hero-flag {
    width: min(44vw, 340px);
    top: 17.5%;
    right: max(1.25rem, 5vw);
  }

  .hero-actions {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .btn {
    width: auto;
  }

  .photo-grid {
    grid-template-columns: 1fr 1fr;
  }

  .photo-lg {
    grid-column: 1 / -1;
  }

  .services-grid {
    grid-template-columns: 1fr 1fr;
  }

  .form-row {
    grid-template-columns: 1fr 1fr;
  }

  .section {
    padding: 4.5rem 0;
  }

  .about-panel,
  .about-panel img {
    min-height: 320px;
  }
}

/* —— Desktop —— */
@media (min-width: 900px) {
  .menu-btn {
    display: none;
  }

  /* Nav mirrors header container: logo left, links right */
  .nav {
    position: fixed;
    top: 0;
    left: 50%;
    right: auto;
    bottom: auto;
    width: min(1120px, calc(100% - 2rem));
    height: var(--header-h);
    max-height: none;
    margin: 0;
    padding: 0 0 0 min(260px, 42%);
    background: transparent;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
    gap: 0.35rem 1.1rem;
    transform: translateX(-50%);
    overflow: visible;
    visibility: visible;
    pointer-events: none;
    z-index: 70;
    box-sizing: border-box;
  }

  .nav a,
  .nav .lang-toggle,
  .nav .lang-toggle button {
    pointer-events: auto;
  }

  .nav.is-open {
    transform: translateX(-50%);
  }

  body.nav-open {
    overflow: visible;
    touch-action: auto;
    position: static;
    width: auto;
    top: auto;
  }

  .nav a {
    font-size: 0.88rem;
    padding: 0.35rem 0.15rem;
    border-left: 0;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    background: transparent;
  }

  .nav a:hover,
  .nav a:focus-visible {
    background: transparent;
  }

  .nav a.is-active {
    background: transparent;
    border-left: 0;
    border-bottom-color: var(--red);
    color: var(--white);
  }

  .lang-toggle {
    margin-top: 0;
    margin-left: 0.35rem;
    align-self: center;
  }

  .lang-toggle button {
    min-height: 0;
    padding: 0.3rem 0.45rem;
    font-size: 0.68rem;
  }

  .brand-logo {
    height: 44px;
    max-width: min(240px, 52vw);
  }

  .hero-content {
    padding: 7.5rem 0 4.5rem;
  }

  .hero-flag {
    width: min(36vw, 420px);
    top: 17%;
    right: max(2rem, 5.5vw);
  }

  .hero-liberty {
    object-position: 34% center;
  }

  .lang-flag {
    width: 1rem;
    height: 0.7rem;
  }

  .about-grid {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 2.5rem;
    align-items: center;
  }

  .contact-grid {
    grid-template-columns: 0.9fr 1.1fr;
    gap: 2rem;
  }

  .services-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .photo-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
    grid-template-rows: auto auto;
    gap: 0.85rem;
  }

  .photo-lg {
    grid-column: auto;
    grid-row: 1 / span 2;
    min-height: 100%;
  }

  .photo-lg img {
    aspect-ratio: auto;
    min-height: 100%;
    height: 100%;
  }

  .cta-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }

  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-end;
    gap: 1.5rem;
  }

  .footer-meta {
    text-align: right;
  }

  .section {
    padding: 5.5rem 0;
  }

  .section-head {
    margin-bottom: 2.5rem;
  }

  .about-panel,
  .about-panel img {
    min-height: 380px;
  }

  .contact-card {
    padding: 2rem 1.75rem;
    min-height: 100%;
  }
}
