/* ============================================================
   Amigos de los Salgado — Design System v2
   ------------------------------------------------------------
   Palette from the OFFICIAL LOGO: red field, black lettering,
   white magnolias — "Justicia para Lorenzo".
   Swap values here to rebrand site-wide.
   ============================================================ */

:root {
  /* Color tokens */
  --dark:        #171414;   /* near-black — headers, footer, hero base */
  --dark-deep:   #0C0A0A;   /* darker layer for depth */
  --dark-soft:   #262121;   /* lighter panel on dark */
  --red:         #C8202D;   /* logo red — CTAs, highlights */
  --red-hi:      #EF5560;   /* readable red on dark backgrounds */
  --red-deep:    #A3141F;   /* red for text/links on cream */
  --leaf:        #3F6B4A;   /* magnolia-leaf green — sparing use */
  --cream:       #FAF4E8;   /* page background */
  --paper:       #FFFFFF;   /* card background */
  --ink:         #241F1F;   /* body text */
  --ink-soft:    #6A5E5E;   /* secondary text */
  --line:        #EADCCB;   /* hairline borders on cream */

  /* Type */
  --font-display: "Oswald", "Arial Narrow", Impact, sans-serif;
  --font-body: "Inter", -apple-system, "Segoe UI", Roboto, sans-serif;

  /* Rhythm */
  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 10px 30px rgba(23, 10, 10, 0.10);
  --shadow-lg: 0 24px 60px rgba(23, 10, 10, 0.18);
  --wrap: 1100px;
  --pad: clamp(1.1rem, 4vw, 2rem);
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--red-deep); }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--red);
  outline-offset: 2px;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  color: var(--dark);
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.3rem, 5.5vw, 3.8rem); }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.5rem); }
h1, h2 { text-transform: uppercase; letter-spacing: 0.02em; }
h3 { font-size: clamp(1.2rem, 2.4vw, 1.5rem); }
p  { margin: 0 0 1em; }
.lead { font-size: clamp(1.1rem, 2.2vw, 1.3rem); color: var(--ink-soft); }

.wrap { max-width: var(--wrap); margin-inline: auto; padding-inline: var(--pad); }
section { padding-block: clamp(3rem, 8vw, 5.5rem); }

/* Gold kicker + underline accent for section headings */
.kicker {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--red-deep);
  margin-bottom: 0.6rem;
}
.rule::after {
  content: "";
  display: block;
  width: 64px;
  height: 4px;
  border-radius: 2px;
  background: var(--red);
  margin-top: 0.55rem;
}
.center { text-align: center; }
.center .rule::after { margin-inline: auto; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 1rem;
  text-decoration: none;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 0.8em 1.7em;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-deep); }
.btn-outline { border-color: var(--red-hi); color: var(--red-hi); background: transparent; }
.btn-outline:hover { background: rgba(239, 85, 96, 0.12); }
.btn-outline-dark { border-color: var(--red-deep); color: var(--red-deep); background: transparent; }
.btn-outline-dark:hover { background: rgba(200, 32, 45, 0.07); }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(12, 10, 10, 0.96);
  backdrop-filter: blur(8px);
  color: #fff;
  border-bottom: 3px solid var(--red);
}
.nav-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 68px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  text-decoration: none;
  color: #fff;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.15rem;
  line-height: 1.1;
}
.brand .mark { width: 38px; height: 38px; flex: none; border-radius: 6px; object-fit: cover; }
.brand small {
  display: block;
  font-family: var(--font-body);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--red-hi);
  text-transform: uppercase;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav-links a {
  display: block;
  color: #E8EEF2;
  text-decoration: none;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 0.55em 0.9em;
  border-radius: 8px;
  transition: background 0.2s ease, color 0.2s ease;
}
.nav-links a:hover { background: rgba(255, 255, 255, 0.1); color: #fff; }
.nav-links a[aria-current="page"] { color: var(--red-hi); }
.nav-links .nav-cta a { background: var(--red); color: #fff; margin-left: 0.4rem; }
.nav-links .nav-cta a:hover { background: var(--red-hi); }

.nav-toggle {
  display: none;
  background: none;
  border: 0;
  padding: 0.4rem;
  cursor: pointer;
}
.nav-toggle span {
  display: block;
  width: 26px;
  height: 3px;
  border-radius: 2px;
  background: #fff;
  margin: 5px 0;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--dark-deep);
    padding: 0.6rem var(--pad) 1.2rem;
    display: none;
    border-bottom: 3px solid var(--red);
  }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 0.85em 0.9em; }
  .nav-links .nav-cta a { margin: 0.5rem 0 0; text-align: center; }
  .nav-open .nav-toggle span:nth-child(1) { transform: translateY(8px) rotate(45deg); }
  .nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .nav-open .nav-toggle span:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}

/* ---------- Hero with parallax depth layers ---------- */
.hero {
  position: relative;
  overflow: hidden;
  background: linear-gradient(180deg, var(--dark-deep) 0%, var(--dark) 55%, #2A1417 100%);
  color: #fff;
  padding-block: clamp(4.5rem, 12vw, 8rem);
}
.hero .layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  will-change: transform;
}
.hero .layer svg { width: 100%; height: 100%; }
.hero-inner { position: relative; z-index: 5; max-width: 780px; }
.hero h1 { color: #fff; }
.hero h1 .red { color: var(--red-hi); }
.hero .lead { color: #D9CFCF; max-width: 58ch; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1.6rem; }

/* Page-top hero (interior pages, shorter) */
.hero.hero-sub { padding-block: clamp(3rem, 8vw, 5rem); }

/* ---------- Cards & grids ---------- */
.grid {
  display: grid;
  gap: clamp(1rem, 2.5vw, 1.6rem);
}
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }

.card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(1.3rem, 3vw, 1.9rem);
  box-shadow: var(--shadow);
}
.card h3 { margin-top: 0.2rem; }
.card .icon {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(200, 32, 45, 0.12);
  color: var(--red-deep);
  margin-bottom: 0.9rem;
}
.card .icon svg { width: 26px; height: 26px; }

/* Dark band section */
.band {
  background: var(--dark);
  color: #E8EEF2;
}
.band h2, .band h3 { color: #fff; }
.band .card {
  background: var(--dark-soft);
  border-color: rgba(255, 255, 255, 0.12);
  color: #DCE6EB;
  box-shadow: none;
}
.band .card h3 { color: var(--red-hi); }

/* ---------- Event listing ---------- */
.event {
  display: grid;
  grid-template-columns: 92px 1fr auto;
  gap: 1.2rem;
  align-items: center;
}
.event .date {
  text-align: center;
  background: var(--dark);
  color: #fff;
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.4rem;
  font-weight: 700;
  line-height: 1.15;
}
.event .date .month {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--red-hi);
}
.event .date .day { display: block; font-size: 1.7rem; font-family: var(--font-display); }
.event .meta { font-size: 0.9rem; color: var(--ink-soft); }
.tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  border-radius: 999px;
  padding: 0.25em 0.85em;
  margin-right: 0.4rem;
}
.tag-irl    { background: rgba(200, 32, 45, 0.12); color: var(--red-deep); }
.tag-online { background: rgba(23, 20, 20, 0.08);  color: var(--dark); }
.tag-fund   { background: rgba(63, 107, 74, 0.16); color: var(--leaf); }
@media (max-width: 640px) {
  .event { grid-template-columns: 76px 1fr; }
  .event .actions { grid-column: 1 / -1; }
}

/* ---------- Forms ---------- */
.form-grid { display: grid; gap: 1rem; }
.form-grid .row2 { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
label { font-weight: 600; font-size: 0.92rem; display: block; margin-bottom: 0.35rem; color: var(--dark); }
input[type="text"], input[type="email"], input[type="tel"], select, textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.75em 0.9em;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px rgba(200, 32, 45, 0.16);
}
textarea { resize: vertical; min-height: 130px; }
.checkbox {
  display: flex;
  gap: 0.6rem;
  align-items: flex-start;
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--ink);
}
.checkbox input { width: 1.15rem; height: 1.15rem; margin-top: 0.2rem; accent-color: var(--red-deep); }
.hidden { display: none !important; }

/* ---------- Social feed page ---------- */
.embed-slot {
  background: var(--paper);
  border: 1.5px dashed var(--red);
  border-radius: var(--radius);
  min-height: 320px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 1.5rem;
  color: var(--ink-soft);
}
.social-btns { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  font-weight: 700;
  color: var(--dark);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.65em 1.3em;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease;
}
.social-btn:hover { transform: translateY(-2px); }
.social-btn svg { width: 20px; height: 20px; color: var(--red-deep); }

/* ---------- Callout / draft notes ---------- */
.todo-note {
  background: #FFF6E3;
  border: 1.5px dashed #D8A93F;
  border-radius: var(--radius-sm);
  padding: 0.8rem 1rem;
  font-size: 0.9rem;
  color: #7A5A12;
}
.todo-note strong { text-transform: uppercase; letter-spacing: 0.06em; font-size: 0.78rem; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--dark-deep);
  color: #B9C7CF;
  padding-block: 2.8rem 1.6rem;
  font-size: 0.95rem;
}
.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  margin-bottom: 2rem;
}
.site-footer h4 { color: var(--red-hi); font-size: 1.05rem; }
.site-footer a { color: #DCE6EB; text-decoration: none; }
.site-footer a:hover { color: var(--red-hi); }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.45rem; }
.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 1.2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  justify-content: space-between;
  font-size: 0.85rem;
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Hero logo (official artwork) ---------- */
.hero-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(1.5rem, 4vw, 3rem);
  flex-wrap: wrap;
}
.hero-flex > div { flex: 1 1 420px; }
.hero-logo {
  flex: 0 1 300px;
  width: clamp(200px, 26vw, 300px);
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  transform: rotate(2deg);
}
@media (max-width: 720px) { .hero-logo { margin-inline: auto; transform: none; } }

.hero-inner.hero-flex { max-width: none; }
