/* ==========================================================================
   Alfipro — styles.css
   Single stylesheet for the Alfipro corporate website.
   Sections:
     1. Design tokens
     2. Reset & base
     3. Layout helpers
     4. Typography & shared elements
     5. Buttons & links
     6. Header & navigation
     7. Hero
     8. Stats
     9. About
    10. Services
    11. Approach
    12. Process timeline
    13. Contact & form
    14. Footer
    15. Back-to-top
    16. Reveal animations
    17. Responsive
   ========================================================================== */


/* ==========================================================================
   1. DESIGN TOKENS
   ========================================================================== */
:root {
  /* Brand */
  --blue:        #0a6ed1;
  --blue-dark:   #0857a5;
  --blue-darker: #063f78;
  --blue-tint:   #eaf3fd;
  --blue-tint-2: #d5e8fb;

  /* Neutrals */
  --ink:       #0e1a26;
  --ink-soft:  #22374b;
  --muted:     #5b6f83;
  --muted-2:   #8496a8;

  --white:   #ffffff;
  --bg:      #ffffff;
  --bg-alt:  #f5f8fc;
  --bg-deep: #0b1b2b;

  --line:        #e3eaf2;
  --line-strong: #cfdbe8;

  /* Shape */
  --radius-sm: 8px;
  --radius:    14px;
  --radius-lg: 22px;

  /* Shadows */
  --shadow-sm: 0 1px 2px rgba(14, 26, 38, .05), 0 2px 8px rgba(14, 26, 38, .04);
  --shadow:    0 4px 14px rgba(14, 26, 38, .06), 0 14px 34px rgba(14, 26, 38, .07);
  --shadow-lg: 0 18px 50px rgba(10, 110, 209, .18);

  /* Type */
  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
          Helvetica, Arial, sans-serif;

  /* Layout */
  --container: 1160px;
  --gutter:    clamp(1.25rem, 4vw, 2.5rem);
  --section-y: clamp(4rem, 9vw, 7.5rem);
  --header-h:  76px;

  --ease: cubic-bezier(.22, .61, .36, 1);
}


/* ==========================================================================
   2. RESET & BASE
   ========================================================================== */
*,
*::before,
*::after { box-sizing: border-box; }

* { margin: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--ink-soft);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

body.no-scroll { overflow: hidden; }

img, svg, video { display: block; max-width: 100%; }

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

button { background: none; border: 0; cursor: pointer; }

ul, ol { list-style: none; padding: 0; }

a { color: var(--blue); text-decoration: none; }

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

::selection {
  background: var(--blue);
  color: #fff;
}

/* Skip link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  z-index: 999;
  padding: .7rem 1.1rem;
  background: var(--blue);
  color: #fff;
  border-radius: 0 0 var(--radius-sm) var(--radius-sm);
  font-weight: 600;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 0; color: #fff; }

/* Hide honeypot */
.hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px; height: 1px;
  overflow: hidden;
}


/* ==========================================================================
   3. LAYOUT HELPERS
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-y); }

.section--alt {
  background: var(--bg-alt);
  border-block: 1px solid var(--line);
}

.section__head {
  max-width: 720px;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.section__intro {
  margin-top: 1rem;
  font-size: 1.075rem;
  color: var(--muted);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(2rem, 5vw, 4.5rem);
  align-items: start;
}

.grid-2--contact {
  grid-template-columns: 1fr 1fr;
  align-items: start;
}


/* ==========================================================================
   4. TYPOGRAPHY & SHARED ELEMENTS
   ========================================================================== */
h1, h2, h3, h4 {
  color: var(--ink);
  line-height: 1.18;
  letter-spacing: -.02em;
  font-weight: 700;
}

p + p { margin-top: 1.1rem; }

.eyebrow {
  display: inline-block;
  margin-bottom: .9rem;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--blue);
}

.section__title {
  font-size: clamp(1.85rem, 3.6vw, 2.65rem);
  font-weight: 800;
}

.lead {
  font-size: 1.115rem;
  color: var(--ink-soft);
  margin-bottom: 1.15rem;
}

/* Small helper for inline emphasis in body copy */
.section p { color: var(--muted); }
.lead { color: var(--ink-soft); }


/* ==========================================================================
   5. BUTTONS & LINKS
   ========================================================================== */
.btn {
  --btn-py: .8rem;
  --btn-px: 1.45rem;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;

  padding: var(--btn-py) var(--btn-px);
  border-radius: 999px;
  border: 1.5px solid transparent;

  font-weight: 600;
  font-size: .95rem;
  line-height: 1.2;
  white-space: nowrap;
  cursor: pointer;

  transition: background-color .22s var(--ease),
              color .22s var(--ease),
              border-color .22s var(--ease),
              transform .22s var(--ease),
              box-shadow .22s var(--ease);
}

.btn--lg { --btn-py: 1rem; --btn-px: 1.9rem; font-size: 1rem; }
.btn--block { width: 100%; }

.btn--primary {
  background: var(--blue);
  color: #fff;
  box-shadow: 0 6px 18px rgba(10, 110, 209, .28);
}
.btn--primary:hover {
  background: var(--blue-dark);
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(10, 110, 209, .34);
}
.btn--primary:active { transform: translateY(0); }

.btn--ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--line-strong);
}
.btn--ghost:hover {
  border-color: var(--blue);
  color: var(--blue);
  background: var(--blue-tint);
  transform: translateY(-2px);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  margin-top: 1.5rem;
  font-weight: 600;
  color: var(--blue);
}
.link-arrow::after {
  content: "→";
  transition: transform .22s var(--ease);
}
.link-arrow:hover::after { transform: translateX(5px); }


/* ==========================================================================
   6. HEADER & NAVIGATION
   ========================================================================== */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 100;
  height: var(--header-h);

  display: flex;
  align-items: center;

  background: rgba(255, 255, 255, .82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;

  transition: background-color .28s var(--ease),
              border-color .28s var(--ease),
              box-shadow .28s var(--ease);
}

.site-header.is-scrolled {
  background: rgba(255, 255, 255, .96);
  border-bottom-color: var(--line);
  box-shadow: 0 4px 22px rgba(14, 26, 38, .06);
}

.header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  width: 100%;
}

/* Logo */
.logo {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  font-size: 1.32rem;
  font-weight: 800;
  letter-spacing: -.03em;
  color: var(--ink);
  flex-shrink: 0;
}
.logo:hover { color: var(--ink); }

.logo__mark {
  display: block;
  width: 34px;
  height: 34px;
  color: var(--blue);
  flex-shrink: 0;
}
.logo__mark svg { width: 100%; height: 100%; }

.logo__text strong { color: var(--blue); font-weight: 800; }

/* Nav */
.nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.2vw, 2rem);
}

.nav__list {
  display: flex;
  align-items: center;
  gap: clamp(.9rem, 1.8vw, 1.75rem);
}

.nav__link {
  position: relative;
  display: inline-block;
  padding: .35rem 0;
  font-size: .95rem;
  font-weight: 500;
  color: var(--ink-soft);
  transition: color .2s var(--ease);
}
.nav__link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 2px;
  background: var(--blue);
  border-radius: 2px;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .28s var(--ease);
}
.nav__link:hover { color: var(--blue); }
.nav__link:hover::after,
.nav__link.is-active::after { transform: scaleX(1); }
.nav__link.is-active { color: var(--blue); font-weight: 600; }

/* Language switcher */
.lang {
  display: inline-flex;
  align-items: center;
  gap: .1rem;
  padding: .2rem;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.lang__item {
  padding: .28rem .62rem;
  border-radius: 999px;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: var(--muted);
  transition: background-color .2s var(--ease), color .2s var(--ease);
}
.lang__item:hover { color: var(--blue); }
.lang__item.is-active {
  background: var(--blue);
  color: #fff;
}

.nav__cta { --btn-py: .7rem; --btn-px: 1.25rem; font-size: .9rem; }

/* Burger */
.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: background-color .2s var(--ease);
}
.nav-toggle:hover { background: var(--bg-alt); }

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
  transition: transform .3s var(--ease), opacity .2s var(--ease);
}

.nav-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}


/* ==========================================================================
   7. HERO
   ========================================================================== */
.hero {
  position: relative;
  isolation: isolate;
  padding-top: calc(var(--header-h) + clamp(3.5rem, 9vw, 7rem));
  padding-bottom: clamp(3.5rem, 8vw, 6.5rem);
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(900px 480px at 78% -8%, rgba(10, 110, 209, .14), transparent 62%),
    radial-gradient(700px 420px at 8% 12%, rgba(10, 110, 209, .08), transparent 60%),
    linear-gradient(180deg, #ffffff 0%, #f7fafe 100%);
}

/* Subtle grid overlay */
.hero__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(14, 26, 38, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(14, 26, 38, .035) 1px, transparent 1px);
  background-size: 62px 62px;
  mask-image: radial-gradient(ellipse 85% 70% at 50% 20%, #000 25%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 85% 70% at 50% 20%, #000 25%, transparent 78%);
}

.hero__inner { max-width: 880px; }

.hero__title {
  font-size: clamp(2.1rem, 5.2vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -.035em;
  line-height: 1.1;
  margin-bottom: 1.35rem;
}

.hero__lead {
  max-width: 640px;
  font-size: clamp(1.02rem, 1.6vw, 1.18rem);
  color: var(--muted);
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: .85rem;
  margin-top: 2.1rem;
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  gap: .6rem 1.6rem;
  margin-top: 2.75rem;
  padding-top: 1.6rem;
  border-top: 1px solid var(--line);
}

.hero__badges li {
  position: relative;
  padding-left: 1.5rem;
  font-size: .9rem;
  font-weight: 500;
  color: var(--muted);
}

.hero__badges li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .58em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 4px var(--blue-tint);
}


/* ==========================================================================
   8. STATS
   ========================================================================== */
.stats {
  background: var(--bg-deep);
  color: #fff;
  padding-block: clamp(2.75rem, 5vw, 3.75rem);
  position: relative;
  overflow: hidden;
}

.stats::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(760px 300px at 15% 0%, rgba(10, 110, 209, .38), transparent 68%);
  pointer-events: none;
}

.stats__grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
}

.stat {
  display: flex;
  flex-direction: column;
  gap: .3rem;
  padding-left: 1.15rem;
  border-left: 2px solid rgba(255, 255, 255, .16);
}

.stat__value {
  font-size: clamp(1.85rem, 3.4vw, 2.5rem);
  font-weight: 800;
  letter-spacing: -.03em;
  color: #fff;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.stat__label {
  font-size: .875rem;
  color: rgba(255, 255, 255, .68);
  line-height: 1.45;
}


/* ==========================================================================
   9. ABOUT
   ========================================================================== */
.fact-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 3vw, 2.1rem);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: calc(var(--header-h) + 28px);
}

.fact-card__title {
  font-size: 1.02rem;
  font-weight: 700;
  letter-spacing: .01em;
  padding-bottom: .95rem;
  margin-bottom: .35rem;
  border-bottom: 1px solid var(--line);
}

.fact-list__row {
  display: grid;
  grid-template-columns: 42% 1fr;
  gap: .75rem;
  padding: .8rem 0;
  border-bottom: 1px dashed var(--line);
}
.fact-list__row:last-child { border-bottom: 0; padding-bottom: 0; }

.fact-list dt {
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .02em;
  color: var(--muted-2);
  text-transform: uppercase;
}

.fact-list dd {
  font-size: .925rem;
  font-weight: 500;
  color: var(--ink);
  line-height: 1.5;
}


/* ==========================================================================
   10. SERVICES
   ========================================================================== */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: clamp(1rem, 2vw, 1.5rem);
}

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.4rem, 2.6vw, 1.9rem);
  overflow: hidden;
  transition: transform .3s var(--ease),
              box-shadow .3s var(--ease),
              border-color .3s var(--ease);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 3px;
  background: linear-gradient(90deg, var(--blue), #57a9f0);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .35s var(--ease);
}

.card:hover {
  transform: translateY(-5px);
  border-color: var(--blue-tint-2);
  box-shadow: var(--shadow);
}
.card:hover::before { transform: scaleX(1); }

.card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  margin-bottom: 1.15rem;
  border-radius: 12px;
  background: var(--blue-tint);
  color: var(--blue);
  transition: background-color .3s var(--ease), color .3s var(--ease);
}
.card__icon svg { width: 24px; height: 24px; }

.card:hover .card__icon {
  background: var(--blue);
  color: #fff;
}

.card__title {
  font-size: 1.08rem;
  font-weight: 700;
  margin-bottom: .6rem;
}

.card__text {
  font-size: .935rem;
  color: var(--muted);
  line-height: 1.65;
}


/* ==========================================================================
   11. APPROACH
   ========================================================================== */
.pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: clamp(1.75rem, 3.5vw, 3rem);
}

.pillar {
  position: relative;
  padding-top: 1.5rem;
  border-top: 2px solid var(--line);
  transition: border-color .3s var(--ease);
}
.pillar:hover { border-top-color: var(--blue); }

.pillar__num {
  display: block;
  font-size: .82rem;
  font-weight: 800;
  letter-spacing: .14em;
  color: var(--blue);
  margin-bottom: .7rem;
}

.pillar__title {
  font-size: 1.08rem;
  font-weight: 700;
  margin-bottom: .55rem;
}

.pillar__text {
  font-size: .93rem;
  color: var(--muted);
  line-height: 1.65;
}


/* ==========================================================================
   12. PROCESS TIMELINE
   ========================================================================== */
.timeline {
  position: relative;
  max-width: 780px;
  margin-inline: auto;
  padding-left: 2.25rem;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 7px;
  top: 8px;
  bottom: 8px;
  width: 2px;
  background: linear-gradient(180deg, var(--blue), var(--blue-tint-2));
  border-radius: 2px;
}

.timeline__item {
  position: relative;
  padding-bottom: 2.25rem;
}
.timeline__item:last-child { padding-bottom: 0; }

.timeline__marker {
  position: absolute;
  left: -2.25rem;
  top: .45rem;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  border: 3px solid var(--blue);
  box-shadow: 0 0 0 4px var(--blue-tint);
}

.timeline__title {
  font-size: 1.06rem;
  font-weight: 700;
  margin-bottom: .45rem;
}

.timeline__text {
  font-size: .94rem;
  color: var(--muted);
  line-height: 1.65;
}


/* ==========================================================================
   13. CONTACT & FORM
   ========================================================================== */
.contact-list {
  margin-top: 2.25rem;
  border-top: 1px solid var(--line);
}

.contact-content {
  max-width: 900px;
}

.contact-list li {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 1rem;
  padding: .95rem 0;
  border-bottom: 1px solid var(--line);
}

.contact-list__label {
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: var(--muted-2);
  padding-top: .12rem;
}

.contact-list__value {
  font-size: .95rem;
  font-weight: 500;
  color: var(--ink);
}
.contact-list__value a:hover { text-decoration: underline; }

/* Form */
.form {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 3vw, 2.35rem);
  box-shadow: var(--shadow-sm);
}

.form__row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.field { margin-bottom: 1.1rem; }

.field label {
  display: block;
  margin-bottom: .42rem;
  font-size: .855rem;
  font-weight: 600;
  color: var(--ink);
}
.field label span { color: var(--blue); }

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: .78rem .95rem;
  background: var(--bg-alt);
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  font-size: .94rem;
  color: var(--ink);
  transition: border-color .2s var(--ease),
              background-color .2s var(--ease),
              box-shadow .2s var(--ease);
}

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

.field input::placeholder,
.field textarea::placeholder { color: var(--muted-2); }

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  background: #fff;
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(10, 110, 209, .12);
}

.field select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235b6f83' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right .9rem center;
  background-size: 17px;
  padding-right: 2.5rem;
  cursor: pointer;
}

/* Invalid state */
.field.has-error input,
.field.has-error select,
.field.has-error textarea {
  border-color: #d64545;
  background: #fef5f5;
}

.field__error {
  display: block;
  min-height: 0;
  margin-top: .35rem;
  font-size: .815rem;
  font-weight: 500;
  color: #c93a3a;
  opacity: 0;
  transition: opacity .2s var(--ease);
}
.field__error.is-visible { opacity: 1; }

/* Checkbox */
.checkbox {
  display: flex;
  align-items: flex-start;
  gap: .65rem;
  margin: .35rem 0 .25rem;
  font-size: .855rem;
  color: var(--muted);
  line-height: 1.55;
  cursor: pointer;
}
.checkbox input {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin-top: .18rem;
  accent-color: var(--blue);
  cursor: pointer;
}
.checkbox span span { color: var(--blue); }

.form .btn { margin-top: 1.35rem; }

.form__note {
  margin-top: .95rem;
  font-size: .885rem;
  font-weight: 500;
  text-align: center;
  min-height: 1.3rem;
}
.form__note.is-success { color: #1a7f4b; }
.form__note.is-error   { color: #c93a3a; }


/* ==========================================================================
   14. FOOTER
   ========================================================================== */
.site-footer {
  background: var(--bg-deep);
  color: rgba(255, 255, 255, .72);
  padding-top: clamp(3rem, 6vw, 4.5rem);
  font-size: .915rem;
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1.2fr;
  gap: clamp(2rem, 4vw, 3.5rem);
  padding-bottom: clamp(2.5rem, 5vw, 3.5rem);
}

.logo--footer { color: #fff; }
.logo--footer:hover { color: #fff; }
.logo--footer .logo__mark { color: var(--blue); }

.footer__tagline {
  margin-top: 1rem;
  max-width: 34ch;
  color: rgba(255, 255, 255, .6);
  line-height: 1.65;
}

.footer__heading {
  margin-bottom: 1rem;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .13em;
  text-transform: uppercase;
  color: #fff;
}

.footer__nav ul,
.footer__legal ul {
  display: grid;
  gap: .55rem;
}

.footer__nav a,
.footer__legal a {
  color: rgba(255, 255, 255, .68);
  transition: color .2s var(--ease);
}
.footer__nav a:hover,
.footer__legal a:hover { color: #fff; }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .75rem;
  padding-block: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: .835rem;
  color: rgba(255, 255, 255, .5);
}

.footer__meta { text-align: right; }


/* ==========================================================================
   15. BACK TO TOP
   ========================================================================== */
.to-top {
  position: fixed;
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1rem, 3vw, 2rem);
  z-index: 90;

  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;

  background: var(--blue);
  color: #fff;
  border-radius: 50%;
  box-shadow: 0 8px 22px rgba(10, 110, 209, .38);

  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);

  transition: opacity .28s var(--ease),
              visibility .28s var(--ease),
              transform .28s var(--ease),
              background-color .22s var(--ease);
}
.to-top svg { width: 20px; height: 20px; }

.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.to-top:hover { background: var(--blue-dark); }


/* ==========================================================================
   16. REVEAL ANIMATIONS
   ========================================================================== */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .65s var(--ease), transform .65s var(--ease);
  will-change: opacity, transform;
}

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

/* Stagger children inside grids */
.cards .reveal:nth-child(2),
.pillars .reveal:nth-child(2),
.stats .reveal:nth-child(2) { transition-delay: .07s; }

.cards .reveal:nth-child(3),
.pillars .reveal:nth-child(3),
.stats .reveal:nth-child(3) { transition-delay: .14s; }

.cards .reveal:nth-child(4),
.pillars .reveal:nth-child(4),
.stats .reveal:nth-child(4) { transition-delay: .21s; }

.cards .reveal:nth-child(5) { transition-delay: .28s; }
.cards .reveal:nth-child(6) { transition-delay: .35s; }

.timeline .reveal:nth-child(2) { transition-delay: .06s; }
.timeline .reveal:nth-child(3) { transition-delay: .12s; }
.timeline .reveal:nth-child(4) { transition-delay: .18s; }
.timeline .reveal:nth-child(5) { transition-delay: .24s; }


/* ==========================================================================
   17. RESPONSIVE
   ========================================================================== */
@media (max-width: 1024px) {
  .grid-2,
  .grid-2--contact {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .fact-card { position: static; }

  .footer__inner {
    grid-template-columns: 1fr 1fr;
  }
  .footer__brand { grid-column: 1 / -1; }
}

@media (max-width: 900px) {
  :root { --header-h: 68px; }

  /* Burger visible */
  .nav-toggle { display: flex; }

  /* Nav becomes an overlay panel */
  .nav {
    position: fixed;
    inset: var(--header-h) 0 0 0;
    z-index: 99;

    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 1.75rem;

    padding: 2rem var(--gutter) 2.5rem;
    background: #fff;
    border-top: 1px solid var(--line);
    overflow-y: auto;

    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity .3s var(--ease),
                visibility .3s var(--ease),
                transform .3s var(--ease);
  }

  .nav.is-open {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
  }

  .nav__list li { border-bottom: 1px solid var(--line); }

  .nav__link {
    display: block;
    padding: 1rem 0;
    font-size: 1.05rem;
    font-weight: 600;
  }
  .nav__link::after { display: none; }

  .lang { align-self: flex-start; }

  .nav__cta {
    width: 100%;
    --btn-py: .95rem;
    font-size: 1rem;
  }

  .stats__grid { grid-template-columns: repeat(2, 1fr); }

  .form__row { grid-template-columns: 1fr; gap: 0; }
}

@media (max-width: 640px) {
  body { font-size: .97rem; }

  .hero__actions .btn { width: 100%; }

  .hero__badges {
    flex-direction: column;
    gap: .7rem;
  }

  .stats__grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .stat {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: baseline;
    gap: 1rem;
  }

  .fact-list__row { grid-template-columns: 1fr; gap: .2rem; }

  .contact-list li { grid-template-columns: 1fr; gap: .25rem; }

  .footer__inner { grid-template-columns: 1fr; }
  .footer__bottom { flex-direction: column; }
  .footer__meta { text-align: left; }

  .timeline { padding-left: 1.85rem; }
  .timeline__marker { left: -1.85rem; }
}


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

  *,
  *::before,
  *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }

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


/* ==========================================================================
   PRINT
   ========================================================================== */
@media print {
  .site-header,
  .to-top,
  .nav-toggle,
  .hero__actions,
  .form { display: none !important; }

  body { color: #000; background: #fff; }
  .reveal { opacity: 1 !important; transform: none !important; }
  .section { padding-block: 1.5rem; break-inside: avoid; }
}


/* ==========================================================================
   NOSCRIPT fallback: reveal elements if JS is disabled
   ========================================================================== */
.no-js .reveal { opacity: 1; transform: none; }