/* ============================================================
   Vähävaraisten lemmikkiapu ry - "Sininen hetki"
   Design system: output/lemmikkiapu/03-design-system.md
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --mustikka: #251C46;      /* superficie oscura dominante */
  --mustikka-syva: #1C1536; /* footer */
  --ilta: #372A6B;          /* cards sobre oscuro */
  --ilta-2: #443680;        /* variante de plinto */
  --hilla: #FFA94D;         /* acento sobre oscuro, CTAs */
  --hilla-kirkas: #FFBC72;  /* hover del CTA */
  --hilla-teksti: #A05600;  /* ambar oscurecido para texto sobre claro (AA) */
  --lumi: #F5F3FA;          /* superficie clara tintada al hue de marca */
  --uni: #E9E4F6;           /* banda tranquila */
  --tassu: #2A2150;         /* tinta sobre claro */
  --muted-light: #575077;   /* texto atenuado sobre claro */
  --muted-dark: #BFB6E0;    /* texto atenuado sobre oscuro */

  --font-display: "Bricolage Grotesque", "Schibsted Grotesk", system-ui, sans-serif;
  --font-body: "Schibsted Grotesk", system-ui, -apple-system, sans-serif;

  --radius-card: 16px;
  --radius-piece: 20px;
  --shadow-piece: 0 16px 32px -20px rgba(18, 11, 42, .55);

  --space-section: clamp(4rem, 9vw, 7.5rem);
  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --container: 1160px;

  --z-sticky: 20;
  --z-panel: 30;
  --z-skip: 40;

  --head-h: 72px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--head-h) + 12px);
}

body {
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--tassu);
  background: var(--lumi);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg { display: block; max-width: 100%; }
/* hidden debe ganar SIEMPRE, tambien sobre .btn { display: inline-flex } */
[hidden] { display: none !important; }
ul[class], ol[class] { list-style: none; padding: 0; }
a { color: inherit; }
button { font: inherit; }

h1, h2, h3 {
  font-family: var(--font-display);
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: balance;
  font-weight: 700;
}
p { text-wrap: pretty; }

:focus-visible {
  outline: 3px solid var(--hilla-teksti);
  outline-offset: 3px;
  border-radius: 4px;
}
.on-dark :focus-visible,
.site-head :focus-visible {
  outline-color: var(--hilla);
}

::selection { background: var(--hilla); color: var(--tassu); }

/* ---------- Skip link ---------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: var(--z-skip);
  background: var(--hilla);
  color: var(--tassu);
  font-weight: 700;
  padding: .8rem 1.4rem;
  border-radius: 0 0 12px 0;
}
.skip-link:focus-visible {
  left: 0;
  outline-offset: -3px;
}

/* ---------- Utilidades ---------- */
.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.section { padding-block: var(--space-section); }
.on-dark { background: var(--mustikka); color: var(--lumi); }
.on-dark h2, .on-dark h3 { color: var(--lumi); }

.kicker {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  font-weight: 600;
  font-size: .9375rem;
  color: var(--hilla-teksti);
  margin-bottom: .9rem;
}
.kicker .glyph { flex: none; width: 25px; height: 20px; }
.on-dark .kicker { color: var(--hilla); }
.band-hilla .kicker { color: var(--tassu); }

h2 { font-size: clamp(1.85rem, 3.6vw, 2.75rem); margin-bottom: 1.1rem; }
.lead { max-width: 65ch; }
.small { font-size: .875rem; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;
  min-height: 48px;
  padding: .8rem 1.7rem;
  border-radius: 999px;
  border: 0;
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  cursor: pointer;
  transition: background-color .15s ease-out, border-color .15s ease-out, transform .15s ease-out;
}
.btn .arrow { transition: transform .15s ease-out; }
.btn:hover .arrow { transform: translateX(4px); }

.btn-solid { background: var(--hilla); color: var(--tassu); }
.btn-solid:hover { background: var(--hilla-kirkas); }

.btn-outline {
  background: transparent;
  border: 2px solid rgba(245, 243, 250, .55);
  color: var(--lumi);
}
.btn-outline:hover { border-color: var(--lumi); background: rgba(245, 243, 250, .08); }

.btn-outline-dark {
  background: transparent;
  border: 2px solid var(--tassu);
  color: var(--tassu);
}
.btn-outline-dark:hover { background: rgba(42, 33, 80, .08); }

.btn-lg { min-height: 56px; font-size: 1.15rem; padding: 1rem 2.2rem; }

/* ---------- Header ---------- */
.site-head {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: var(--z-sticky);
  background: color-mix(in oklab, var(--mustikka) 86%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--lumi);
}
.head-row {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: var(--head-h);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  text-decoration: none;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-right: auto;
  min-height: 44px;
}
/* v3: nombre oficial completo junto al logo, en ambar hilla (peticion de Sari).
   Dos lineas SIEMPRE (tambien en desktop): asi convive con 7 items + pill.
   Contraste medido: #FFA94D sobre mustikka 8.3:1, sobre el header al 86%
   encima de lumi (peor caso) 5.5:1, AA cumplido en ambos. */
.brand-name {
  display: flex;
  flex-direction: column;
  color: var(--hilla);
  font-size: 1rem;
  line-height: 1.16;
}
.brand-mark { position: relative; width: 36px; height: 36px; flex: none; }
.brand-mark svg { width: 100%; height: 100%; color: var(--hilla); }
.brand-mark .brand-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.brand-mark.no-img .brand-img { display: none; }
/* el PNG es la marca real: cuando carga, oculta el SVG de reserva para que el corazon calado se vea hueco de verdad (sin que el SVG se cuele por el hueco) */
.brand-mark:not(.no-img) svg { display: none; }

.site-nav { display: block; }
.nav-links {
  display: flex;
  align-items: center;
  gap: .15rem;
}
/* v3: 7 items + pill + nombre completo. En desktop el menu compacta cuerpo y
   padding para caber con aire, y respira mas a partir de 1280. */
.nav-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: .5rem .55rem;
  border-radius: 999px;
  text-decoration: none;
  font-weight: 500;
  font-size: .875rem;
  white-space: nowrap;
  transition: background-color .15s ease-out;
}
.nav-links a:hover { background: rgba(245, 243, 250, .1); }
@media (min-width: 1280px) {
  .nav-links a { font-size: .9375rem; padding-inline: .75rem; }
}

.head-pill {
  min-height: 44px;
  padding: .55rem 1.2rem;
  font-size: .975rem;
  flex: none;
}

.nav-toggle {
  display: none;
  flex: none;
  align-items: center;
  gap: .5rem;
  min-height: 44px;
  min-width: 44px;
  padding: .5rem .9rem;
  background: transparent;
  border: 2px solid rgba(245, 243, 250, .35);
  border-radius: 999px;
  color: var(--lumi);
  font-weight: 600;
  cursor: pointer;
}
.nav-toggle:hover { border-color: var(--lumi); }
.nav-toggle .bars { display: inline-block; width: 16px; }
.nav-toggle .bars::before {
  content: "";
  display: block;
  height: 2px;
  background: currentColor;
  box-shadow: 0 5px 0 currentColor, 0 -5px 0 currentColor;
  margin-block: 5px;
}

/* v3: breakpoint del hamburguesa adelantado de 919 a 1099px, los 7 items no
   caben con aire por debajo (margen que dio Sari, ver 02-contenido [nav]). */
@media (max-width: 1099px) {
  .nav-toggle { display: inline-flex; }
  /* Panel anclado al header: absolute + display, nunca fixed ni transform
     (el backdrop-filter del header convierte a fixed en trampa). */
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--mustikka);
    border-top: 1px solid rgba(245, 243, 250, .1);
    box-shadow: 0 28px 40px -28px rgba(0, 0, 0, .65);
    padding: .5rem 1rem 1.25rem;
  }
  .site-head.is-open .site-nav { display: block; }
  .nav-links { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-links a {
    min-height: 48px;
    font-size: 1.1rem;
    border-radius: 12px;
    padding-inline: 1rem;
  }
  .head-pill { padding-inline: 1rem; font-size: .9rem; }
}

/* ============================================================
   HERO: el ensamblaje (la firma)
   Piezas en CSS keyframes puros: corre a la carga, sin depender
   de CDN ni JS. Regla del reveal cumplida por construccion.
   ============================================================ */
.hero {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(56rem 34rem at 84% 88%, rgba(255, 169, 77, .16), transparent 62%),
    radial-gradient(40rem 26rem at 8% 10%, rgba(68, 54, 128, .55), transparent 70%),
    var(--mustikka);
  color: var(--lumi);
  padding-top: calc(var(--head-h) + clamp(2rem, 6vw, 4.5rem));
  padding-bottom: clamp(3.5rem, 7vw, 6rem);
}
.hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(1.5rem, 3.5vw, 3rem);
  align-items: center;
}

.hero-copy { animation: copy-in .6s cubic-bezier(.22, 1, .36, 1) both .15s; }
.hero-copy .kicker { color: var(--hilla); }
.hero h1 {
  font-size: clamp(2.4rem, 5.6vw, 4.4rem);
  margin-bottom: 1.2rem;
}
.hero-sub {
  max-width: 54ch;
  color: var(--muted-dark);
  font-size: 1.125rem;
  margin-bottom: 1.8rem;
}
.hero-ctas { display: flex; flex-wrap: wrap; gap: .8rem; margin-bottom: 1rem; }
.hero-note { color: var(--muted-dark); font-size: .9rem; }

/* --- El escenario: tres animales sueltos sobre el fondo del hero ---
   Desktop: dimensionados por ALTURA (dominan el hero, apoyados en el suelo,
   pueden sangrar por el borde izquierdo del hero de forma intencionada).
   Movil: override mas abajo, dimensionado por ancho (tamano compacto). */
.hero-stage {
  position: relative;
  height: clamp(470px, 46vw, 660px);
  align-self: end;
}
/* linea de suelo comun: leve halo ambar que asienta al grupo */
.hero-ground {
  position: absolute;
  left: -10%;
  right: 0;
  bottom: 5%;
  height: 60px;
  background: radial-gradient(58% 120% at 50% 0, rgba(255, 169, 77, .16), transparent 72%);
  pointer-events: none;
}

.hero-animal {
  position: absolute;
  bottom: 5%;
  height: var(--h, 70%);
  transform-origin: 50% 100%;
  animation: drop-in .9s both;
  animation-delay: var(--d, 0s);
}
.hero-animal .animal-img {
  height: 100%;
  width: auto;
  filter: drop-shadow(0 24px 30px rgba(12, 7, 30, .5));
  pointer-events: none;
}
.hero-animal .animal-img.is-missing { display: none; }

/* sombra de contacto: los animales "pisan" el hero, sin caja */
.hero-animal::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -3%;
  width: 74%;
  height: 26px;
  transform: translateX(-50%);
  background: radial-gradient(50% 100% at 50% 50%, rgba(8, 4, 22, .6), transparent 72%);
  filter: blur(3px);
  opacity: 0;
  z-index: -1;
  animation: shadow-in .45s ease-out both;
  animation-delay: calc(var(--d) + .5s);
  pointer-events: none;
}
/* anillo de impacto mecanico al asentarse */
.hero-animal::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -1%;
  width: 62%;
  aspect-ratio: 4 / 1;
  transform: translateX(-50%) scale(.4);
  border: 2px solid rgba(255, 169, 77, .7);
  border-radius: 50%;
  opacity: 0;
  animation: impact-ring .5s ease-out both;
  animation-delay: calc(var(--d) + .48s);
  pointer-events: none;
}

/* Jerarquia escalonada (desktop, dimensionado SOLO por altura -> width:auto,
   asi el ratio natural del PNG se respeta siempre, nunca se estira).
   Perro protagonista a tope de alto y anclado al borde izquierdo (sangra un
   poco por la izquierda, intencionado). Gato claramente menor a su derecha,
   conejo el mas pequeno a la derecha del gato, con hueco visible entre ellos. */
.a-koira { --d: .35s; --h: 104%; left: -15%; z-index: 3; }
.a-kissa { --d: 1.1s;  --h: 56%;  left: 37%;  z-index: 2; }
.a-kani  { --d: 1.85s; --h: 40%;  left: 69%;  z-index: 1; }

/* degradacion sin png: silueta de corazon en su hueco, nada roto */
.hero-animal.no-img {
  width: 34%;
  height: auto;
  aspect-ratio: 3 / 4;
  border-radius: 18px;
  background:
    radial-gradient(14rem 12rem at 50% 30%, rgba(255, 169, 77, .18), transparent 60%),
    linear-gradient(160deg, var(--ilta), var(--mustikka));
}
.hero-animal.no-img::after { opacity: 1; animation: none; }

@keyframes drop-in {
  0% {
    transform: translateY(-120vh) scale(1, 1);
    animation-timing-function: cubic-bezier(.55, 0, .82, .4);
  }
  55% {
    transform: translateY(0) scale(1, 1);
    animation-timing-function: cubic-bezier(.25, .6, .4, 1);
  }
  68% { transform: translateY(0) scale(1.05, .92); animation-timing-function: cubic-bezier(.4, 0, .5, 1); }
  84% { transform: translateY(0) scale(.99, 1.02); }
  100% { transform: translateY(0) scale(1, 1); }
}
@keyframes shadow-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes impact-ring {
  0%   { opacity: .55; transform: translateX(-50%) scale(.4); }
  100% { opacity: 0;   transform: translateX(-50%) scale(1.5); }
}
@keyframes copy-in {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* decoracion parallax del hero */
.fx { position: absolute; pointer-events: none; }
.fx-ring {
  border: 2px solid rgba(255, 169, 77, .22);
  border-radius: 50%;
}
.fx-disc { border-radius: 50%; background: rgba(68, 54, 128, .5); }
.hero .fx-1 { width: 220px; height: 220px; top: 8%; right: -60px; }
.hero .fx-2 { width: 90px; height: 90px; bottom: 14%; left: -30px; }

/* ============================================================
   Secciones de la home
   ============================================================ */

/* ---------- Missio ---------- */
.missio-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.missio-text p + p { margin-top: 1rem; }
.missio-text p { max-width: 62ch; }

.photo-frame {
  overflow: hidden;
  border-radius: var(--radius-card);
  position: relative;
}
.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.frame-45 { aspect-ratio: 4 / 5; }
.frame-32 { aspect-ratio: 3 / 2; }
.photo-frame.no-img {
  background:
    radial-gradient(18rem 14rem at 70% 20%, rgba(255, 169, 77, .25), transparent 60%),
    linear-gradient(160deg, var(--ilta), var(--mustikka));
}
.photo-frame.no-img img { display: none; }
.photo-frame.no-img::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'%3E%3Cpath fill='rgba(255,169,77,.4)' d='M32 56C18 46 8 38 8 26 8 18 14 12 22 12c4 0 8 2 10 6 2-4 6-6 10-6 8 0 14 6 14 14 0 12-10 20-24 30Z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 72px;
}

.data-band {
  position: relative;
  overflow: hidden;
  margin-top: clamp(2.5rem, 6vw, 4.5rem);
  background: var(--mustikka);
  color: var(--lumi);
  border-radius: 24px;
  padding: clamp(2rem, 5vw, 3.5rem);
}
.data-band .fx-1 { width: 260px; height: 260px; top: -80px; right: 6%; }
.data-band .fx-2 { width: 70px; height: 70px; bottom: -20px; left: 42%; }
.data-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
}
.data-num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  letter-spacing: -0.02em;
  color: var(--hilla);
  line-height: 1;
  margin-bottom: .5rem;
  font-variant-numeric: tabular-nums;
}
.data-label { color: var(--muted-dark); max-width: 26ch; }
.data-source {
  position: relative;
  margin-top: 1.75rem;
  color: var(--muted-dark);
  font-size: .8125rem;
}

.pull-quote {
  margin: clamp(2.5rem, 6vw, 4rem) auto 0;
  max-width: 46ch;
  text-align: center;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.3rem, 2.6vw, 1.75rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.pull-quote footer {
  margin-top: .9rem;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: .9rem;
  color: var(--muted-light);
}

/* ---------- Näin autamme ---------- */
.aid-intro { max-width: 58ch; margin-bottom: clamp(2rem, 4vw, 3rem); }
.aid-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(1.5rem, 3vw, 2.5rem);
  align-items: stretch;
}
.aid-card {
  border-radius: var(--radius-card);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.aid-card .photo-frame { border-radius: 0; }
.aid-body { padding: clamp(1.5rem, 3vw, 2.25rem); display: flex; flex-direction: column; gap: .9rem; flex: 1; }
.aid-card h3 { font-size: 1.35rem; }
.aid-vet { background: #FFFFFF; }
.aid-ruoka { background: var(--mustikka); color: var(--lumi); }
.aid-ruoka .aid-body p { color: var(--muted-dark); }
.aid-list li {
  position: relative;
  padding-left: 1.4rem;
  margin-top: .35rem;
  font-weight: 500;
}
.aid-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: .62em;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--hilla-teksti);
}
.aid-ruoka .aid-list li::before { background: var(--hilla); }
.aid-close {
  margin-top: clamp(1.75rem, 3vw, 2.5rem);
  max-width: 56ch;
  font-weight: 500;
}

/* ---------- Tarvitsetko apua ---------- */
.band-quiet {
  background: var(--uni);
  text-align: center;
}
.band-quiet h2 { margin-bottom: 1rem; }
.band-quiet p {
  max-width: 56ch;
  margin: 0 auto 2rem;
}

/* ---------- Tarinat ---------- */
.stories-head { max-width: 68ch; }
.honesty {
  color: var(--muted-dark);
  font-size: .95rem;
  max-width: 68ch;
  margin-bottom: clamp(2rem, 4vw, 3rem);
}
.stories {
  position: relative;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
}
.story {
  background: var(--ilta);
  border-radius: var(--radius-card);
  padding: clamp(1.5rem, 3vw, 2.1rem);
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.story .piece-glyph { display: block; width: 30px; height: 30px; color: var(--hilla); }
.story .piece-glyph svg { width: 100%; height: 100%; }
.story blockquote {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.3rem;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.story h3 { color: var(--hilla); font-size: 1.05rem; letter-spacing: 0; }
.story p { color: var(--muted-dark); font-size: .975rem; }
.tarinat-band { position: relative; overflow: hidden; }
.tarinat-band .fx-1 { width: 340px; height: 340px; top: -120px; left: -100px; }
.tarinat-band .fx-2 { width: 120px; height: 120px; bottom: -40px; right: 4%; }

/* ---------- Lupaus (1 €) ---------- */
.band-hilla {
  position: relative;
  overflow: hidden;
  background: var(--hilla);
  color: var(--tassu);
}
.band-hilla .fx-ring { border-color: rgba(42, 33, 80, .18); }
.band-hilla .fx-1 { width: 300px; height: 300px; top: -100px; right: -80px; }
.band-hilla p.lead { max-width: 62ch; }

.euro-flow {
  display: grid;
  grid-template-columns: auto minmax(60px, 1fr) auto;
  align-items: center;
  gap: clamp(1rem, 3vw, 2.5rem);
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
}
.euro-coin {
  width: clamp(112px, 14vw, 150px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--mustikka);
  color: var(--lumi);
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  box-shadow: inset 0 0 0 5px rgba(245, 243, 250, .18);
}
.euro-path { width: 100%; height: auto; }
.euro-path path {
  fill: none;
  stroke: var(--mustikka);
  stroke-width: 3.5;
  stroke-linecap: round;
}
.euro-dest { display: flex; flex-direction: column; gap: 1rem; }
.euro-dest li {
  background: var(--mustikka);
  color: var(--lumi);
  border-radius: 14px;
  padding: 1.1rem 1.5rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(1.05rem, 2vw, 1.3rem);
}
.euro-connector { display: none; }

/* ---------- Liity jäseneksi ---------- */
.liity-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.liity-body p { max-width: 58ch; }
.lupaus-note { margin-top: 1rem; color: rgba(42, 33, 80, .75); }

/* tarjetas de cuota (kannatus / yritys) */
.fee-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 1.5rem);
  margin-top: 1.6rem;
}
.fee-card {
  background: #FFFFFF;
  border-radius: var(--radius-card);
  padding: 1.5rem 1.6rem;
  display: flex;
  flex-direction: column;
  gap: .5rem;
  box-shadow: 0 12px 28px -22px rgba(18, 11, 42, .4);
}
.fee-card-yritys { background: var(--mustikka); color: var(--lumi); }
.fee-label { font-weight: 700; font-size: .95rem; color: var(--hilla-teksti); }
.fee-card-yritys .fee-label { color: var(--hilla); }
.fee-price {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.7rem, 2.8vw, 2.2rem);
  letter-spacing: -0.02em;
  line-height: 1.05;
  font-variant-numeric: tabular-nums;
}
.fee-per { font-size: .55em; font-weight: 600; margin-left: .35em; letter-spacing: 0; }
.fee-desc { font-size: .95rem; color: var(--muted-light); }
.fee-card-yritys .fee-desc { color: var(--muted-dark); }

/* ---------- Bloque de pago maksulinkki + QR (v3, oculto hasta tener URL/QR reales) ---------- */
.pay-now {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  background: var(--mustikka);
  color: var(--lumi);
  border-radius: var(--radius-card);
  padding: clamp(1.75rem, 4vw, 2.5rem);
}
.pay-now h3 { font-size: 1.35rem; margin-bottom: .8rem; }
.pay-now p { max-width: 62ch; color: var(--muted-dark); }
.pay-now-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.25rem 2rem;
  margin-top: 1.4rem;
}
.pay-qr {
  border-radius: 12px;
  background: #FFFFFF;
  padding: 8px;
}

/* ---------- Formularios (jäsenlomake + avunpyyntölomake) ---------- */
.member-form, .help-form {
  margin-top: clamp(2.5rem, 5vw, 3.5rem);
  background: #FFFFFF;
  border-radius: var(--radius-card);
  padding: clamp(1.75rem, 4vw, 2.75rem);
  box-shadow: 0 18px 40px -30px rgba(18, 11, 42, .45);
}
.member-form h3 { font-size: 1.4rem; margin-bottom: 1.4rem; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.1rem 1.5rem;
}
.form-field { display: flex; flex-direction: column; gap: .35rem; }
.form-field-wide { grid-column: 1 / -1; }
.form-field label {
  font-weight: 600;
  font-size: .95rem;
}
.form-field input,
.form-field textarea {
  font: inherit;
  color: var(--tassu);
  background: var(--lumi);
  border: 2px solid rgba(42, 33, 80, .22);
  border-radius: 12px;
  padding: .7rem .9rem;
  min-height: 48px;
  width: 100%;
}
.form-field textarea { min-height: 120px; resize: vertical; }
.form-field input:focus-visible,
.form-field textarea:focus-visible {
  outline: 3px solid var(--hilla-teksti);
  outline-offset: 1px;
  border-color: var(--hilla-teksti);
}
.field-hint { font-size: .85rem; color: var(--muted-light); }
.form-radios {
  border: 0;
  padding: 0;
  margin: 1.4rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: .6rem 1rem;
}
.form-radios legend {
  font-weight: 600;
  font-size: .95rem;
  padding: 0;
  margin-bottom: .6rem;
}
.radio-option {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  min-height: 48px;
  padding: .5rem 1.1rem;
  border: 2px solid rgba(42, 33, 80, .22);
  border-radius: 999px;
  font-weight: 500;
  cursor: pointer;
}
.radio-option:hover { border-color: var(--hilla-teksti); }
.radio-option:has(input:checked) {
  border-color: var(--hilla-teksti);
  background: rgba(255, 169, 77, .14);
  font-weight: 600;
}
.radio-option input {
  width: 20px;
  height: 20px;
  margin: 0;
  accent-color: var(--hilla-teksti);
}
.help-form > .form-field { margin-top: 1.4rem; }
.form-actions { margin-top: 1.6rem; display: flex; flex-wrap: wrap; align-items: center; gap: 1rem 1.5rem; }
.form-note { color: var(--muted-light); font-size: .875rem; max-width: 44ch; }

/* ---------- Tukijat ---------- */
.tukijat-band {
  position: relative;
  overflow: hidden;
  background: var(--uni);
}
.tukijat-band .fx-ring { border-color: rgba(42, 33, 80, .14); }
.tukijat-band .fx-1 { width: 280px; height: 280px; top: -100px; right: -80px; }
.tukijat-band .fx-2 { width: 80px; height: 80px; bottom: -24px; left: 6%; background: rgba(255, 169, 77, .3); }
.tukijat-intro { max-width: 58ch; margin-bottom: clamp(2rem, 4vw, 3rem); }
.sponsor-grid {
  position: relative;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.25rem, 2.5vw, 2rem);
  align-items: stretch;
}
.sponsor-card {
  background: #FFFFFF;
  border-radius: var(--radius-card);
  padding: clamp(1.75rem, 4vw, 2.5rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: .9rem;
  box-shadow: 0 18px 40px -30px rgba(18, 11, 42, .45);
}
/* marca real de NordSur: leon + wordmark con sus colores oficiales
   (azul marino #0A102E + azul electrico #2244EC, ver nordsur.net) */
.sponsor-brand {
  align-self: start;
  display: inline-flex;
  align-items: center;
  gap: .8rem;
  text-decoration: none;
}
.sponsor-logo {
  width: 60px;
  height: 60px;
  border-radius: 14px;
  flex: none;
  object-fit: contain; /* PHP: logos subidos desde el panel, proporcion no garantizada */
}
.sponsor-name {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(1.7rem, 3.8vw, 2.4rem);
  letter-spacing: -0.01em;
  line-height: 1;
  color: #0A102E;
}
.sponsor-name span { color: #2244EC; }
.sponsor-brand:hover .sponsor-name { text-decoration: underline; text-decoration-color: #2244EC; text-underline-offset: 6px; }
/* v3: logos horizontales (wordmarks sobre blanco) con altura comun, la zona de
   marca de cada tarjeta mide lo mismo para que los 4 logos queden alineados */
.sponsor-brand { min-height: 64px; }
.sponsor-logo-wide {
  height: 52px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
}
a.sponsor-brand .sponsor-logo-wide { transition: opacity .15s ease-out; }
a.sponsor-brand:hover .sponsor-logo-wide { opacity: .8; }
.sponsor-line { color: var(--muted-light); }
.sponsor-invite { background: var(--mustikka); color: var(--lumi); justify-content: flex-start; }
/* la tarjeta de invitacion cierra la parrilla a todo el ancho bajo los 4 logos */
.sponsor-invite { grid-column: 1 / -1; }

/* Añadido en la version PHP: wordmark tipografico cuando la empresa no tiene logo subido */
.sponsor-wordmark {
  align-self: start;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(2rem, 4.5vw, 2.9rem);
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1;
  color: var(--tassu);
  text-decoration: none;
  border-bottom: 3px solid var(--hilla);
  padding-bottom: .2em;
}
.sponsor-wordmark span { color: var(--hilla-teksti); }
.sponsor-wordmark:hover span { color: var(--tassu); }
.sponsor-invite h3 { font-size: 1.35rem; }
.sponsor-invite p { color: var(--muted-dark); max-width: 46ch; }
.sponsor-invite .btn-outline-dark {
  align-self: start;
  border-color: rgba(245, 243, 250, .55);
  color: var(--lumi);
}
.sponsor-invite .btn-outline-dark:hover { border-color: var(--lumi); background: rgba(245, 243, 250, .08); }

/* ---------- Tule mukaan ---------- */
.volunteer-band { position: relative; overflow: hidden; }
.volunteer-band .fx-1 { width: 260px; height: 260px; bottom: -90px; right: -70px; }
.volunteer {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
}
.volunteer p { max-width: 56ch; }
.volunteer p + p { margin-top: 1rem; }
.volunteer .aid-list li::before { background: var(--hilla); }
.volunteer .btn { margin-top: 1.5rem; }
.volunteer-list { color: var(--lumi); }
.volunteer-welcome { margin-top: 1.2rem; font-weight: 600; color: var(--hilla); }
.sometiimi {
  background: var(--ilta);
  border-radius: var(--radius-card);
  padding: 1.4rem 1.6rem;
  font-weight: 500;
  margin-bottom: 1.4rem;
}

/* ---------- UKK (acordeon) ---------- */
.ukk .container { max-width: 860px; }
.accordion details {
  border-bottom: 1px solid rgba(42, 33, 80, .16);
}
.accordion summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  min-height: 56px;
  padding: 1.05rem 0;
  cursor: pointer;
  font-weight: 600;
  font-size: 1.1rem;
  list-style: none;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
  content: "+";
  font-family: var(--font-display);
  font-size: 1.7rem;
  font-weight: 600;
  line-height: 1;
  color: var(--hilla-teksti);
  transition: transform .2s cubic-bezier(.22, 1, .36, 1);
  flex: none;
}
.accordion details[open] summary::after { transform: rotate(45deg); }
.accordion details > p {
  padding-bottom: 1.4rem;
  max-width: 66ch;
  color: var(--muted-light);
}

/* ---------- Yhteystiedot ---------- */
.contact-band { background: var(--uni); }
.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 6fr) minmax(0, 6fr);
  gap: clamp(2rem, 4vw, 3.5rem);
  align-items: start;
}
.contact-name { font-weight: 700; font-size: 1.15rem; }
/* email como boton: la direccion no se muestra nunca en texto */
.contact-mail-btn { margin-block: .9rem .6rem; }
.contact-reply { color: var(--muted-light); }

/* huecos de redes previstos, sin enlace hasta que existan los perfiles */
.social-soon {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5rem;
  margin-top: 1.1rem;
}
.social-chip {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: .2rem .85rem;
  border: 1.5px solid currentColor;
  border-radius: 999px;
  font-weight: 600;
  font-size: .85rem;
  opacity: .55;
}
.social-note { font-size: .8125rem; opacity: .75; }
.contact-help {
  background: var(--lumi);
  border-radius: var(--radius-card);
  padding: 1.75rem 2rem;
}
.contact-help p { margin-bottom: 1rem; font-weight: 500; }
.arrow-link {
  font-weight: 700;
  color: var(--tassu);
  text-decoration-color: var(--hilla-teksti);
  text-underline-offset: 4px;
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  gap: .4rem;
}
.arrow-link:hover .arrow { transform: translateX(4px); }
.arrow-link .arrow { transition: transform .15s ease-out; }

/* ---------- Footer ---------- */
.site-foot {
  background: var(--mustikka-syva);
  color: var(--muted-dark);
  padding-block: clamp(2.5rem, 5vw, 4rem) 1.75rem;
}
.foot-grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 4fr) minmax(0, 3fr);
  gap: clamp(1.75rem, 4vw, 3rem);
  margin-bottom: 2.25rem;
}
.foot-brand {
  display: flex;
  align-items: flex-start;
  gap: .7rem;
}
.foot-brand .brand-mark { width: 32px; height: 32px; }
.foot-name { color: var(--lumi); font-weight: 700; }
.foot-tagline { font-size: .95rem; }
.foot-nav { display: flex; flex-direction: column; gap: .1rem; }
.foot-nav a, .foot-mail {
  color: var(--muted-dark);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  min-height: 40px;
}
.foot-nav a:hover, .foot-mail:hover { color: var(--hilla); }
.foot-legal {
  border-top: 1px solid rgba(245, 243, 250, .1);
  padding-top: 1.5rem;
  font-size: .8125rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .75rem;
}

/* ============================================================
   hae-apua.html: la habitacion tranquila
   ============================================================ */
.apua-hero {
  padding-top: calc(var(--head-h) + clamp(2.5rem, 6vw, 4.5rem));
  padding-bottom: clamp(3rem, 6vw, 5rem);
}
.apua-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: center;
}
.apua-hero h1 { font-size: clamp(2.1rem, 4.6vw, 3.4rem); margin-bottom: 1.1rem; }
.apua-hero .hero-sub { color: var(--muted-light); }
.apua-section { padding-block: clamp(2.75rem, 6vw, 4.5rem); }
.apua-section .container { max-width: 860px; }
.apua-section p { max-width: 62ch; }
.apua-section h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); }

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1rem, 2.5vw, 1.5rem);
  margin-top: 1.75rem;
  counter-reset: none;
}
.step {
  background: #FFFFFF;
  border-radius: var(--radius-card);
  padding: 1.6rem;
}
.step h3 { font-size: 1.15rem; margin-bottom: .6rem; color: var(--hilla-teksti); }
.step p { font-size: .975rem; color: var(--muted-light); }

.limits { margin-top: 1.4rem; }
.lead-narrow { max-width: 52ch; }

/* destacado de alcance nacional */
.apua-highlight {
  background: var(--mustikka);
  color: var(--lumi);
  border-radius: var(--radius-card);
  padding: clamp(1.4rem, 3vw, 2rem);
  margin-top: 1.75rem;
}
.apua-highlight p { max-width: 60ch; font-weight: 500; }

/* seccion del formulario de ayuda */
.apua-lomake { background: var(--uni); }
.lomake-intro { margin-bottom: .5rem; }
.lomake-kysy {
  margin-top: 1.75rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .75rem 1.25rem;
}
.btn-ask { flex: none; }

.note-urgent {
  margin-top: 1.75rem;
  background: var(--uni);
  border-radius: 14px;
  padding: 1.2rem 1.5rem;
  font-weight: 600;
  max-width: 100%;
}

.apua-final { text-align: center; padding-block: clamp(3.5rem, 8vw, 6rem); }
.apua-final p { margin-inline: auto; }
.apua-final .btn { margin-top: 1.75rem; }
.apua-final .micro { margin-top: 1.1rem; color: var(--muted-light); font-size: .9rem; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 980px) {
  .missio-grid, .liity-grid, .apua-hero-grid { grid-template-columns: 1fr; }
  .aid-grid { grid-template-columns: 1fr; }
  .contact-grid, .volunteer { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .missio-grid .photo-frame { max-width: 520px; }
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-copy { order: -1; }
  .hero-stage {
    height: clamp(190px, 52vw, 300px);
    max-width: 540px;
    margin-inline: auto;
    width: 100%;
    margin-top: .5rem;
  }
  /* movil: vuelve al dimensionado por ancho (tamano compacto, intacto) */
  .hero-animal { bottom: 0; height: auto; }
  .hero-animal .animal-img { width: 100%; height: auto; }
  .a-koira { width: 40%; left: 1%; }
  .a-kissa { width: 32%; left: 35%; }
  .a-kani  { width: 26%; left: 66%; }
  .hero-ground { left: 0; bottom: -2%; }
  .stories { grid-template-columns: 1fr; }
  .sponsor-grid { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .data-grid { grid-template-columns: 1fr; gap: 1.5rem; }
  .euro-flow { grid-template-columns: 1fr; justify-items: center; text-align: center; }
  .euro-path { display: none; }
  .euro-connector {
    display: block;
    width: 4px;
    height: 34px;
    border-radius: 2px;
    background: var(--mustikka);
  }
  .euro-dest { width: 100%; max-width: 420px; }
}

@media (max-width: 560px) {
  :root { --head-h: 64px; }
  .head-row { gap: .5rem; }
  .brand { gap: .45rem; }
  /* nombre completo en dos lineas a cuerpo menor (contrato v3: 13-14px, nunca recortado) */
  .brand-name { font-size: .8125rem; line-height: 1.2; }
  .brand-mark { width: 30px; height: 30px; }
  /* boton de menu solo icono: el aria-label conserva el nombre accesible */
  .toggle-label { display: none; }
  .nav-toggle { width: 44px; justify-content: center; padding: .5rem; gap: 0; }
  .head-pill { padding-inline: .85rem; font-size: .85rem; }
  .hero-ctas .btn { flex: 1 1 100%; }
  .foot-grid { grid-template-columns: 1fr; }
  .fee-cards { grid-template-columns: 1fr; }
  .form-actions .btn { flex: 1 1 100%; }
  .radio-option { flex: 1 1 100%; }
}

/* ============================================================
   Reduced motion: piezas ya colocadas con fade suave, sin caida.
   Un solo bloque que atenua TODO el motion.
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-animal, .hero-copy {
    animation: rm-fade .6s ease-out both;
  }
  /* piezas ya colocadas: sin caida, sin impacto, sombra de contacto fija */
  .hero-animal::before { animation: none; opacity: 0; }
  .hero-animal::after { animation: none; opacity: 1; }
  .btn, .btn .arrow, .arrow-link .arrow,
  .nav-links a, .accordion summary::after {
    transition: none;
  }
}
@keyframes rm-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* ---------- Añadido en la versión PHP: confirmación de envío de formularios ---------- */
.form-ok,
.form-err {
  margin: 0 0 1.1rem;
  padding: .85rem 1.1rem;
  border-radius: 14px;
  font-weight: 600;
}
.form-ok {
  background: #E8F6EC;
  color: #1B5E33;
  border: 1.5px solid #9FD8B0;
}
.form-err {
  background: #FBECEC;
  color: #8C2B2B;
  border: 1.5px solid #E7A9A9;
}
