/* =========================================================
   Asociación Down del Uruguay — Landing page
   ========================================================= */

/* =========================
   Base
========================= */
:root {
  --color-primary: rgb(88, 110, 160);
  --color-primary-hex: #586EA0;
  --color-primary-dark: #47597f;

  --color-secondary: #2D819B;
  --color-secondary-dark: #24677c;

  --color-accent: #F4D35F;
  --color-accent-dark: #e2b93a;

  --color-text: #333333;
  --color-text-soft: #5b5f68;

  --color-white: #FFFFFF;
  --color-section-light: #F6F8FC;

  --color-down5k: rgb(159, 241, 16);

  --max-width: 1280px;
  --gutter: 32px;

  --header-height: 78px;

  --radius-lg: 28px;
  --radius-md: 16px;
  --radius-sm: 8px;

  --font-heading: "Raleway", sans-serif;
  --font-body: "Open Sans", sans-serif;

  --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  width: 100%;
  overflow-x: hidden;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
  background: var(--color-white);
}

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

a {
  color: inherit;
}

ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

p {
  margin: 0 0 1em;
}

p:last-child {
  margin-bottom: 0;
}

h1, h2, h3 {
  font-family: var(--font-heading);
  font-weight: 300;
  margin: 0;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section-eyebrow {
  display: block;
  width: 45px;
  height: 4px;
  background: var(--color-accent);
  border-radius: 2px;
  margin-bottom: 24px;
}

.section-eyebrow--dark {
  background: var(--color-white);
}

.section-title {
  color: var(--color-primary-hex);
  font-size: clamp(38px, 5vw, 64px);
  line-height: 1.08;
  margin-bottom: 24px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--color-white);
  color: var(--color-primary-hex);
  padding: 12px 20px;
  z-index: 2000;
  border-radius: 0 0 8px 0;
}

.skip-link:focus {
  left: 0;
}

:focus-visible {
  outline: 3px solid var(--color-accent);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

/* =========================
   Buttons & links
========================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  border: none;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease), background-color 0.2s var(--ease);
  white-space: nowrap;
}

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

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

.btn--primary:hover {
  background: var(--color-primary-dark);
}

.btn--accent {
  background: var(--color-accent);
  color: #3a2f0b;
}

.btn--accent:hover {
  background: var(--color-accent-dark);
}

.btn--outline {
  background: transparent;
  color: var(--color-primary-hex);
  border: 1.5px solid var(--color-primary-hex);
}

.btn--outline:hover {
  background: var(--color-primary-hex);
  color: var(--color-white);
}

.link-arrow {
  color: var(--color-secondary);
  font-weight: 700;
  text-decoration: none;
  padding: 14px 8px;
  border-radius: var(--radius-sm);
}

.link-arrow:hover {
  text-decoration: underline;
}

/* =========================
   Header
========================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--color-primary-hex);
  transition: box-shadow 0.25s var(--ease);
}

.site-header.is-scrolled {
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.12);
}

.site-header__inner {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
  height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.site-header__logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.site-header__logo img {
  width: 90px;
  height: auto;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 32px;
  margin-left: auto;
}

.main-nav__list {
  display: flex;
  align-items: center;
  gap: 28px;
}

.main-nav__list a {
  color: var(--color-white);
  text-decoration: none;
  font-size: 15px;
  font-weight: 400;
  white-space: nowrap;
  opacity: 0.95;
  transition: opacity 0.2s var(--ease);
}

.main-nav__list a:hover {
  opacity: 1;
  text-decoration: underline;
}

.main-nav__cta {
  padding: 11px 24px;
}

.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 42px;
  height: 42px;
  background: transparent;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}

.menu-toggle__bar {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-white);
  border-radius: 2px;
  transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bar:nth-child(2) {
  opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle__bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-menu {
  display: none;
  background: var(--color-primary-hex);
  border-top: 1px solid rgba(255, 255, 255, 0.15);
}

.mobile-menu__list {
  display: flex;
  flex-direction: column;
  padding: 8px var(--gutter) 24px;
}

.mobile-menu__list li + li {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.mobile-menu__list a {
  display: block;
  padding: 16px 4px;
  color: var(--color-white);
  text-decoration: none;
  font-size: 16px;
}

.mobile-menu__cta {
  display: inline-flex;
  margin-top: 16px;
  width: 100%;
}

/* =========================
   Hero
========================= */
.hero {
  position: relative;
  min-height: 760px;
  display: flex;
  align-items: center;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-image: url("../assets/hero-derecha-crop.jpg");
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
}

/* Light gray gradient over the photo: solid (hiding the image) from the
   left edge to the middle of the container, then fading to fully
   transparent by the right edge so the photo shows through clearly. */
.hero__scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to right,
    #f6f8fc 0%,
    #f6f8fc 50%,
    rgba(246, 248, 252, 0) 100%
  );
}

.hero__inner {
  position: relative;
  width: 100%;
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.hero__content {
  max-width: 620px;
}

.hero__title {
  display: flex;
  flex-direction: column;
  font-size: clamp(56px, 6vw, 96px);
  line-height: 1.15;
  font-weight: 300;
  background: linear-gradient(135deg, rgb(88, 110, 160), #2D819B);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 28px;
}

.hero__text {
  max-width: 470px;
  font-size: 18px;
  color: var(--color-text);
  margin-bottom: 36px;
}

.hero__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* =========================
   Quiénes somos
========================= */
.about {
  background: var(--color-white);
  padding: 110px 0;
}

.about__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.about__content p {
  color: var(--color-text);
  font-size: 16px;
  margin-bottom: 20px;
}

.stat-card {
  display: flex;
  align-items: center;
  gap: 22px;
  background: var(--color-section-light);
  border-radius: 14px;
  padding: 24px 28px;
  margin-top: 32px;
}

.stat-card__number {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  flex-shrink: 0;
}

.stat-card__number span {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 40px;
  color: var(--color-primary-hex);
  line-height: 1;
}

.stat-card__number small {
  font-size: 13px;
  color: var(--color-text-soft);
  margin-top: 2px;
}

.stat-card__divider {
  width: 1px;
  align-self: stretch;
  background: rgba(88, 110, 160, 0.25);
  flex-shrink: 0;
}

.stat-card__text {
  font-size: 15px;
  color: var(--color-text);
  margin: 0;
}

.stat-card__text strong {
  font-weight: 700;
}

.about__media {
  position: relative;
  height: 100%;
  min-height: 460px;
}

.about__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius-lg);
}

.about__media-dot {
  position: absolute;
  top: -18px;
  right: 24px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(88, 110, 160, 0.25);
}

/* =========================
   Qué hacemos
========================= */
.activities {
  background: var(--color-section-light);
  padding: 110px 0;
}

.activities__intro {
  max-width: 720px;
  margin-bottom: 56px;
}

.activities__intro p {
  font-size: 18px;
  color: var(--color-text);
}

.accordion {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.accordion__item {
  background: var(--color-white);
  border: 1px solid rgba(88, 110, 160, 0.16);
  border-radius: 15px;
  overflow: hidden;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}

.accordion__item.is-open {
  background: var(--color-primary-hex);
  border-color: var(--color-primary-hex);
}

.accordion__header {
  margin: 0;
}

.accordion__trigger {
  display: flex;
  align-items: center;
  gap: 18px;
  width: 100%;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  padding: 24px 26px;
  min-height: 80px;
  font-family: var(--font-body);
  color: var(--color-text);
}

.accordion__item.is-open .accordion__trigger {
  color: var(--color-white);
}

.accordion__number {
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary-hex);
  flex-shrink: 0;
  width: 22px;
}

.accordion__item.is-open .accordion__number {
  color: rgba(255, 255, 255, 0.75);
}

.accordion__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  flex-shrink: 0;
  color: var(--color-primary-hex);
}

.accordion__item.is-open .accordion__icon {
  color: var(--color-white);
}

.accordion__icon svg {
  width: 100%;
  height: 100%;
}

.accordion__title {
  flex: 1;
  font-size: 17px;
  font-weight: 600;
}

.accordion__toggle {
  flex-shrink: 0;
  font-size: 22px;
  font-weight: 300;
  color: var(--color-accent);
  line-height: 1;
  transition: transform 0.3s var(--ease);
}

.accordion__item.is-open .accordion__toggle {
  transform: rotate(45deg);
}

.accordion__panel {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.35s var(--ease);
}

.accordion__item.is-open .accordion__panel {
  grid-template-rows: 1fr;
}

.accordion__panel-inner {
  overflow: hidden;
  min-height: 0;
}

.accordion__panel-inner > div,
.accordion__panel-inner {
  padding: 0 26px;
}

.accordion__item.is-open .accordion__panel-inner {
  padding-bottom: 26px;
}

.accordion__panel-inner p {
  color: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  max-width: 760px;
  padding-left: 64px;
}

.accordion__panel-inner p:last-child {
  margin-bottom: 0;
}

.accordion__panel-title {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 16px !important;
  color: var(--color-white) !important;
}

.accordion__panel-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
}

.accordion__panel-links a {
  color: var(--color-accent);
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.accordion__panel-links a:hover {
  color: var(--color-white);
}

/* =========================
   Down 5K
========================= */
.down5k {
  background: var(--color-down5k);
  padding: 90px 0;
  overflow: hidden;
}

.down5k__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.down5k__title {
  font-family: var(--font-heading);
  font-weight: 300;
  font-size: clamp(38px, 5vw, 60px);
  color: #14210a;
  margin-bottom: 20px;
  line-height: 1.05;
}

.down5k__content p {
  color: #1c2a12;
  font-size: 17px;
  margin-bottom: 28px;
}

.down5k__details {
  display: flex;
  gap: 40px;
  flex-wrap: wrap;
}

.down5k__detail {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.down5k__detail-label {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #24390f;
}

.down5k__detail-value {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 24px;
  color: #14210a;
}

.down5k__media {
  position: relative;
  padding-bottom: 32px;
  padding-left: 32px;
}

.down5k__poster {
  position: relative;
  z-index: 1;
  width: 100%;
  border-radius: var(--radius-md);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.18);
}

.down5k__photo {
  position: absolute;
  left: 0;
  bottom: 0;
  z-index: 2;
  width: 42%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 4px solid var(--color-white);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.22);
}

/* =========================
   Cómo colaborar
========================= */
.collaboration {
  background: var(--color-white);
  padding: 110px 0;
}

.collaboration__intro {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.collaboration__intro .section-eyebrow {
  margin-inline: auto;
}

.collaboration__intro p {
  font-size: 17px;
  color: var(--color-text);
}

.collaboration__cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  align-items: stretch;
}

.collab-card {
  display: flex;
  flex-direction: column;
  border-radius: 20px;
  padding: 40px 32px;
  color: var(--color-white);
}

.collab-card__icon {
  width: 30px;
  height: 30px;
  margin-bottom: 20px;
}

.collab-card__icon svg {
  width: 100%;
  height: 100%;
}

.collab-card__title {
  font-size: 26px;
  margin-bottom: 16px;
}

.collab-card__text {
  font-size: 15px;
  line-height: 1.6;
  margin-bottom: 24px;
  opacity: 0.96;
}

.collab-card__box {
  border-radius: 12px;
  padding: 20px 22px;
  margin-bottom: 28px;
  font-size: 14px;
  flex-grow: 1;
}

.collab-card__box p {
  margin-bottom: 8px;
}

.collab-card__box p:last-child {
  margin-bottom: 0;
}

.collab-card__highlight {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 20px;
  color: var(--color-accent);
  margin-bottom: 10px !important;
}

.collab-card__note {
  font-style: italic;
  opacity: 0.85;
  font-size: 13px;
}

.collab-card__btn {
  align-self: flex-start;
  width: 100%;
  justify-content: center;
}

.collab-card--socio {
  background: var(--color-primary-hex);
}

.collab-card--socio .collab-card__box {
  background: rgba(255, 255, 255, 0.14);
}

.collab-card--amigo {
  background: var(--color-secondary);
}

.collab-card--amigo .collab-card__box {
  background: rgba(255, 255, 255, 0.14);
}

.collab-card--donaciones {
  background: #fdfaf1;
  border: 1px solid var(--color-accent);
  color: var(--color-text);
}

.collab-card--donaciones .collab-card__icon,
.collab-card--donaciones .collab-card__title {
  color: var(--color-primary-hex);
}

.collab-card--donaciones .collab-card__text {
  color: var(--color-text);
}

.collab-card--donaciones .collab-card__box {
  background: #f2ede1;
  color: var(--color-text);
}

.collab-card--donaciones .collab-card__highlight {
  color: var(--color-primary-hex);
}

/* =========================
   Foto ancho completo
========================= */
.full-photo {
  position: relative;
  width: 100%;
  line-height: 0;
}

.full-photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(88, 110, 160, 0.55);
  pointer-events: none;
}

.full-photo img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 70vh;
  object-fit: cover;
}

/* =========================
   Call to action final
========================= */
.final-cta {
  position: relative;
  background: var(--color-secondary);
  padding: 130px 0;
  overflow: hidden;
  text-align: center;
}

.final-cta__imago {
  position: absolute;
  right: -140px;
  top: 50%;
  transform: translateY(-50%);
  width: 640px;
  max-width: none;
  opacity: 0.14;
  pointer-events: none;
  user-select: none;
}

.final-cta__inner {
  position: relative;
  z-index: 1;
}

.final-cta__title {
  display: flex;
  flex-direction: column;
  color: var(--color-white);
  font-size: clamp(36px, 5vw, 62px);
  line-height: 1.12;
  margin-bottom: 28px;
}

.final-cta__text {
  color: var(--color-white);
  opacity: 0.95;
  font-size: 17px;
  max-width: 640px;
  margin: 0 auto 36px;
}

/* =========================
   Footer
========================= */
.site-footer {
  background: var(--color-primary-hex);
  color: rgba(255, 255, 255, 0.92);
  padding-top: 72px;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  padding-bottom: 48px;
}

.site-footer__logo {
  width: 90px;
  margin-bottom: 20px;
}

.site-footer__col--brand p {
  font-size: 14px;
  opacity: 0.9;
}

.site-footer__heading {
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.06em;
  color: var(--color-accent);
  margin-bottom: 18px;
}

.site-footer__contact-line {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  font-size: 15px;
}

.site-footer__contact-line svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  color: var(--color-accent);
}

.site-footer__contact-line a {
  text-decoration: none;
}

.site-footer__contact-line a:hover {
  text-decoration: underline;
}

.site-footer__small {
  font-size: 13px;
  opacity: 0.75;
  margin-bottom: 16px;
}

.site-footer__address {
  font-size: 14px;
  opacity: 0.9;
}

.site-footer__links li {
  margin-bottom: 12px;
}

.site-footer__links a {
  font-size: 14px;
  text-decoration: none;
  opacity: 0.9;
}

.site-footer__links a:hover {
  opacity: 1;
  text-decoration: underline;
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  padding: 24px var(--gutter) 28px;
  text-align: center;
}

.site-footer__bottom p {
  font-size: 13px;
  opacity: 0.8;
  margin: 0;
}

/* =========================
   Reveal-on-scroll (JS-driven)
========================= */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
}

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

@media (prefers-reduced-motion: reduce) {
  .reveal {
    opacity: 1;
    transform: none;
  }
}

/* =========================
   Responsive — ≤1200px
========================= */
@media (max-width: 1200px) {
  :root {
    --gutter: 24px;
  }

  .main-nav {
    gap: 20px;
  }

  .main-nav__list {
    gap: 20px;
  }

  .collaboration__cards {
    gap: 22px;
  }
}

/* =========================
   Responsive — ≤900px (tablet / header breakpoint)
========================= */
@media (max-width: 900px) {
  .main-nav {
    display: none;
  }

  .menu-toggle {
    display: flex;
  }

  .mobile-menu[data-open="true"] {
    display: block;
  }

  .site-header__logo img {
    width: 76px;
  }

  /* Solid brand-yellow hero on phones/tablets instead of the photo:
     at these narrower, taller viewports there isn't room to keep the
     whole group visible next to the text, so a flat color reads cleaner. */
  .hero__bg {
    background-image: none;
    background-color: var(--color-accent);
  }

  .hero__scrim {
    display: none;
  }

  .about__grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .about__media {
    min-height: 0;
    aspect-ratio: 4 / 3;
    order: 2;
  }

  .about__content {
    order: 1;
  }

  .down5k__grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .down5k__media {
    order: -1;
  }

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

  .collab-card--donaciones {
    grid-column: 1 / -1;
  }

  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
    row-gap: 40px;
  }
}

/* =========================
   Responsive — ≤768px
========================= */
@media (max-width: 768px) {
  .hero {
    min-height: 700px;
  }

  .hero__title {
    font-size: clamp(48px, 12vw, 58px);
  }

  .hero__text {
    max-width: 100%;
  }

  .hero__actions {
    flex-direction: column;
    align-items: flex-start;
  }

  .about,
  .activities,
  .collaboration {
    padding: 72px 0;
  }

  .down5k {
    padding: 64px 0;
  }

  .section-title {
    font-size: clamp(34px, 8vw, 48px);
  }

  .stat-card {
    flex-wrap: wrap;
  }

  .accordion__trigger {
    padding: 18px 16px;
    gap: 12px;
  }

  .accordion__title {
    font-size: 15px;
  }

  .accordion__panel-inner p {
    padding-left: 0;
  }

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

  .collab-card--donaciones {
    grid-column: auto;
  }

  .final-cta {
    padding: 90px 0;
  }

  .final-cta__imago {
    width: 420px;
    right: -160px;
  }

  .site-footer__grid {
    grid-template-columns: 1fr;
    row-gap: 36px;
    text-align: left;
  }
}

/* =========================
   Responsive — ≤480px
========================= */
@media (max-width: 480px) {
  :root {
    --gutter: 18px;
  }

  .hero {
    min-height: 640px;
  }

  .hero__title {
    font-size: 44px;
  }

  .hero__text {
    font-size: 16px;
  }

  .btn {
    width: 100%;
  }

  .hero__actions .link-arrow {
    width: 100%;
    justify-content: center;
    text-align: center;
  }

  .stat-card__divider {
    display: none;
  }

  .down5k__details {
    gap: 24px;
  }

  .final-cta__title {
    font-size: 36px;
  }
}
