/* ============================================================
   RESURGENCIA — Sitio web · estilos de componentes
   Carga después de brand.css. Usa los tokens de marca.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--sand-100); color: var(--fg1);
  font-family: var(--font-sans); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
::selection { background: var(--sage-400); color: var(--forest); }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 3px; border-radius: 4px; }

/* ---------- layout ---------- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 32px; }
.container-narrow { max-width: 820px; margin: 0 auto; padding: 0 32px; }
.section { padding: 96px 0; }
.section-sm { padding: 64px 0; }
.section--forest { background: var(--forest); color: var(--fg-invert); }
.section--espresso { background: var(--espresso); color: var(--fg-invert); }
.section--sage { background: var(--sage-100); }
.section--paper { background: var(--sand-100); }
.center { text-align: center; }
.stack > * + * { margin-top: var(--s-5); }

/* ---------- type helpers ---------- */
.eyebrow { font-family: var(--font-sans); font-weight: 600; font-size: 13px; line-height: 1; letter-spacing: 0.16em; text-transform: uppercase; color: var(--fg2); }
.eyebrow--invert { color: var(--sage-400); }
.eyebrow--forest { color: var(--forest-500); }
.script { font-family: var(--font-script); font-weight: 400; }
.serif { font-family: var(--font-serif); }
.muted { color: var(--fg2); }
.muted-invert { color: var(--fg-invert-2); }

h1, h2, h3, h4 { margin: 0; font-family: var(--font-serif); font-weight: 400; letter-spacing: -0.02em; color: inherit; }
.display { font-weight: 300; font-size: clamp(48px, 7vw, 84px); line-height: 1.0; letter-spacing: -0.025em; }
.h-xl { font-size: clamp(36px, 5vw, 60px); line-height: 1.04; }
.h-lg { font-size: clamp(30px, 4vw, 46px); line-height: 1.08; }
.h-md { font-size: clamp(24px, 3vw, 34px); line-height: 1.12; }
.lead { font-family: var(--font-sans); font-size: clamp(17px, 1.4vw, 20px); line-height: 1.6; color: var(--fg2); }
.lead--invert { color: var(--fg-invert-2); }
p { margin: 0; line-height: 1.6; }
.prose p + p { margin-top: 1.1em; }
.prose { font-size: 18px; line-height: 1.7; color: var(--fg2); }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: 9px; cursor: pointer;
  font-family: var(--font-sans); font-weight: 600; font-size: 15px; line-height: 1;
  padding: 14px 28px; border-radius: 999px; border: 1.5px solid transparent;
  text-decoration: none; transition: all var(--dur-fast) var(--ease); white-space: nowrap;
}
.btn:active { transform: scale(.97); }
.btn--primary { background: var(--forest); color: var(--sand-100); }
.btn--primary:hover { background: var(--forest-900); }
.btn--secondary { background: transparent; color: var(--forest); border-color: var(--forest); }
.btn--secondary:hover { background: var(--sage-200); }
.btn--ghost { background: transparent; color: var(--forest); padding-left: 8px; padding-right: 8px; }
.btn--ghost:hover { color: var(--forest-900); gap: 13px; }
.btn--invert { background: var(--sand-100); color: var(--forest); }
.btn--invert:hover { background: var(--white); }
.btn--sm { padding: 10px 20px; font-size: 14px; }
.btn--lg { padding: 17px 34px; font-size: 16px; }

/* ---------- pills / tags ---------- */
.pill { display: inline-flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 600; padding: 7px 15px; border-radius: 999px; letter-spacing: 0.02em; }
.pill--sage { background: var(--sage-400); color: var(--forest); }
.pill--blue { background: var(--blue-400); color: var(--forest); }
.pill--sand { background: var(--sand-400); color: var(--espresso); }
.pill--forest { background: var(--forest); color: var(--sand-100); }
.pill--outline { background: transparent; color: var(--fg2); border: 1px solid var(--line); }
.pill--outline-invert { background: transparent; color: var(--fg-invert-2); border: 1px solid var(--line-invert); }

/* ---------- arch photo (signature device) ---------- */
.arch {
  position: relative; overflow: hidden; border-radius: 999px 999px 18px 18px;
  background: var(--forest);
}
.arch--sm { border-radius: 999px 999px 12px 12px; }
.arch > img { width: 100%; height: 100%; object-fit: cover; filter: saturate(0.86) contrast(0.97) sepia(0.08); }
.arch__scrim { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,30,24,.62) 0%, rgba(0,30,24,.05) 48%, rgba(0,30,24,0) 70%); }
.arch__cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 28px; z-index: 2; }
.arch__cap .t { font-family: var(--font-serif); font-size: 26px; color: var(--sand-100); line-height: 1.1; }
.arch__cap .s { font-family: var(--font-sans); font-size: 14px; color: var(--fg-invert-2); margin-top: 5px; }
/* grain overlay */
.grain::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .12; mix-blend-mode: soft-light; z-index: 3;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 160px 160px;
}

/* ---------- cards ---------- */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--r-lg); overflow: hidden; transition: transform var(--dur) var(--ease), box-shadow var(--dur) var(--ease); }
.card--hover:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); }
.card__body { padding: 26px 28px 30px; }
.card__title { font-family: var(--font-serif); font-size: 24px; color: var(--forest); line-height: 1.12; }
.card__meta { font-size: 14px; color: var(--fg3); margin-top: 10px; }

/* event/list row */
.row { display: grid; grid-template-columns: 220px 1fr auto; gap: 28px; align-items: center; padding: 28px 0; border-top: 1px solid var(--line); }
.row:last-child { border-bottom: 1px solid var(--line); }
.row__date { font-weight: 600; font-size: 16px; color: var(--forest-500); letter-spacing: 0.02em; }
.row__title { font-family: var(--font-serif); font-size: 30px; color: var(--forest); line-height: 1.06; }
.row__sub { font-size: 15px; color: var(--fg2); margin-top: 6px; }

/* ---------- grids ---------- */
.grid { display: grid; gap: 28px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* ---------- header / nav ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(243,242,231,.85); backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.site-header__bar { max-width: 1200px; margin: 0 auto; padding: 0 32px; height: 74px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-header__logo img { height: 21px; }
.site-nav { display: flex; gap: 30px; align-items: center; }
.site-nav a { font-size: 14.5px; font-weight: 500; color: var(--fg2); text-decoration: none; transition: opacity var(--dur-fast) var(--ease); }
.site-nav a:hover { opacity: .6; }
.site-nav a.is-active { color: var(--forest); font-weight: 600; }
.site-header__cta { display: flex; align-items: center; gap: 12px; }
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 8px; color: var(--forest); }
.nav-toggle svg { width: 26px; height: 26px; }
.mobile-nav { display: none; }

/* ---------- footer ---------- */
.site-footer { background: var(--espresso); color: var(--fg-invert-2); padding: 72px 0 36px; }
.site-footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 40px; }
.site-footer__brand img { height: 22px; }
.site-footer__brand p { font-size: 14px; line-height: 1.6; margin-top: 18px; max-width: 250px; }
.site-footer h4 { font-family: var(--font-sans); font-weight: 600; font-size: 13px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--sand); margin-bottom: 16px; }
.site-footer__col a { display: block; font-size: 14.5px; color: var(--fg-invert-2); text-decoration: none; padding: 5px 0; transition: color var(--dur-fast) var(--ease); }
.site-footer__col a:hover { color: var(--sand-100); }
.site-footer__bottom { max-width: 1200px; margin: 48px auto 0; padding: 24px 32px 0; border-top: 1px solid rgba(228,228,206,.15); display: flex; justify-content: space-between; font-size: 12.5px; }

/* ---------- forms ---------- */
.form { display: grid; gap: 18px; }
.field label { display: block; font-size: 13.5px; font-weight: 600; color: var(--fg2); margin-bottom: 7px; }
.field input, .field select, .field textarea {
  width: 100%; font-family: var(--font-sans); font-size: 15px; padding: 13px 16px;
  border: 1px solid var(--line); border-radius: 12px; background: var(--white); color: var(--fg1);
  outline: none; transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}
.field textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--forest); box-shadow: 0 0 0 3px rgba(28,80,67,.18); }
.field--row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.form-note { font-size: 13px; color: var(--fg3); }
.form-status { font-size: 14.5px; padding: 13px 16px; border-radius: 12px; display: none; }
.form-status.is-ok { display: block; background: var(--sage-200); color: var(--forest); }
.form-status.is-err { display: block; background: #f3ddd5; color: var(--critical); }

/* ---------- hero ---------- */
.hero { padding: 64px 0 40px; }
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero__media { height: 520px; }

/* ---------- misc ---------- */
.divider-marquee { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: 22px 0; overflow: hidden; }
.marquee-track { display: flex; gap: 44px; justify-content: center; flex-wrap: wrap; align-items: center; }
.marquee-track span { font-family: var(--font-display); font-size: 21px; color: var(--forest); }
.marquee-track .sep { color: var(--line-strong); }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; margin-bottom: 36px; }
.section-head .h-lg { margin-top: 12px; }
.arch-mark { display: inline-block; width: 26px; height: 33px; border: 1.5px solid currentColor; border-bottom: none; border-radius: 26px 26px 0 0; }
.scroll-reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.scroll-reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { .scroll-reveal { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .section { padding: 64px 0; }
  .hero__grid { grid-template-columns: 1fr; gap: 32px; }
  .hero__media { height: 380px; }
  .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .site-footer__grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .site-nav, .site-header__cta .btn { display: none; }
  .nav-toggle { display: inline-flex; }
  .row { grid-template-columns: 1fr; gap: 6px; align-items: start; }
  .row__date { order: -1; }
}
@media (max-width: 560px) {
  .container, .container-narrow { padding: 0 22px; }
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .field--row { grid-template-columns: 1fr; }
  .site-footer__grid { grid-template-columns: 1fr; }
  .site-footer__bottom { flex-direction: column; gap: 8px; }
  .section-head { flex-direction: column; align-items: flex-start; }
}

/* mobile nav panel */
.mobile-nav { position: fixed; inset: 0; z-index: 60; background: var(--forest); color: var(--sand-100); padding: 28px 32px; transform: translateX(100%); transition: transform var(--dur) var(--ease); display: flex; flex-direction: column; }
.mobile-nav.is-open { transform: none; }
.mobile-nav__top { display: flex; justify-content: space-between; align-items: center; }
.mobile-nav__top img { height: 22px; }
.mobile-nav__close { background: none; border: none; color: var(--sand-100); cursor: pointer; padding: 8px; }
.mobile-nav__close svg { width: 26px; height: 26px; }
.mobile-nav__links { display: flex; flex-direction: column; gap: 4px; margin-top: 48px; }
.mobile-nav__links a { font-family: var(--font-serif); font-size: 32px; color: var(--sand-100); text-decoration: none; padding: 12px 0; border-bottom: 1px solid var(--line-invert); }
.mobile-nav__foot { margin-top: auto; display: flex; flex-direction: column; gap: 14px; }
