/* ============================================================
   TRABAJOS EXTRAORDINARIOS — Lina editorial microsite
   ============================================================
   Section 1: nav/footer support styles, copied verbatim from
              holalina.mx (do not "improve" these — they exist
              only to keep the shared chrome pixel-identical).
   Section 2: brand tokens for the rest of the page.
   Section 3: layout + components for this microsite.
   ============================================================ */

/* ---------- 1. Replicated nav/footer styles (from holalina.mx) ---------- */

body { padding-top: 72px; }

#navbar a, #navbar a:hover { text-decoration: none; }
#navbar button, #lang-menu button {
  font-family: "Apercu", -apple-system, BlinkMacSystemFont, system-ui, sans-serif;
  -webkit-appearance: none; appearance: none; cursor: pointer;
}
.nav-outline {
  background-color: transparent !important;
  border: 2px solid rgba(255,255,255,0.3) !important;
  border-style: solid !important;
  color: white !important;
}
.nav-outline:hover {
  background-color: #8B5CF6 !important;
  border-color: white !important;
  color: white !important;
}
.nav-cta {
  background-color: white !important;
  border: 1px solid #2D2C2B !important;
  border-style: solid !important;
  color: #03030D !important;
  box-shadow: 6px 6px 0 #2D2C2B !important;
}
.nav-cta:hover {
  background-color: #25D366 !important;
  color: white !important;
}
#lang-menu {
  background-color: #2D2DCC !important;
  border: 2px solid rgba(255,255,255,0.2) !important;
  border-style: solid !important;
}
#lang-menu .lang-opt {
  background-color: transparent !important;
  color: white !important;
  border: none !important;
  box-shadow: none !important;
}
#lang-menu .lang-opt:hover {
  background-color: rgba(255,255,255,0.1) !important;
  color: white !important;
}
footer a, footer a:hover { color: inherit; text-decoration: none; }
.navbar-shrunk { padding-top: 10px !important; padding-bottom: 10px !important; }

@media (max-width: 640px) {
  body { padding-top: 64px; }
}

/* ---------- 2. Brand tokens (microsite body copy) ---------- */

:root {
  --cream:        #f6f3ec;
  --ink:          #2d2c2b;
  --lina-blue:    #4338f5;
  --lina-blue-edge: #2d2dcc;
  --yellow:       #f5c542;
  --pink:         #ff81a9;
  --green:        #069641;
  --purple:       #8e5aff;
  --white:        #ffffff;
  --muted:        #6b6a66;
  --line:         #ded9cb;

  --font-head: "Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-body: "Apercu", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --shadow-brutal: 5px 5px 0 var(--ink);
  --shadow-brutal-sm: 3px 3px 0 var(--ink);
  --radius-lg: 20px;
  --radius-md: 14px;
  --radius-sm: 8px;
}

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

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
html, body {
  /* The replicated nav's buttons (shrink-0, copied verbatim from
     holalina.mx) can run wider than very narrow phones, same as on the
     live site. overflow-x:hidden here stops that from inflating the
     whole document's layout width — it keeps the overflow contained to
     the nav bar itself instead of stretching every section below it. */
  overflow-x: hidden;
}
body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  max-width: 100vw;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

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

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 24px;
}
.container--narrow {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Marker highlight (behind 1-2 words, lower third, hand-drawn feel) ---------- */
.marker {
  position: relative;
  white-space: nowrap;
}
.marker span {
  position: relative;
  z-index: 1;
}
.marker::after {
  content: "";
  position: absolute;
  left: -0.06em;
  right: -0.06em;
  bottom: 0.03em;
  height: 0.38em;
  background: var(--yellow);
  z-index: 0;
  transform: rotate(-0.6deg);
  border-radius: 2px 6px 3px 7px / 4px 3px 6px 2px;
}

/* ---------- Sticker tag ---------- */
.sticker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--yellow);
  color: var(--ink);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 8px 18px;
  border: 2px solid var(--ink);
  border-radius: 999px;
  box-shadow: var(--shadow-brutal-sm);
  transform: rotate(-3deg);
}
.sticker--pink { background: var(--pink); }
.sticker--green { background: var(--green); color: var(--white); }
.sticker--purple { background: var(--purple); color: var(--white); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 16px;
  padding: 15px 28px;
  border: 2px solid var(--ink);
  border-radius: 12px;
  box-shadow: var(--shadow-brutal);
  text-decoration: none;
  cursor: pointer;
  transition: transform .12s cubic-bezier(0.34,1.56,0.64,1), box-shadow .12s cubic-bezier(0.34,1.56,0.64,1);
}
.btn:active {
  transform: translate(3px, 3px);
  box-shadow: 2px 2px 0 var(--ink);
}
.btn-primary {
  background: var(--lina-blue);
  color: var(--white);
}
.btn-primary:hover { background: #2f2fe0; }
.btn-whatsapp {
  background: #25d366;
  color: var(--white);
}
.btn-whatsapp:hover { background: #1fba59; }
.btn-ghost {
  background: var(--white);
  color: var(--ink);
}
.btn-ghost:hover { background: var(--cream); }

/* ---------- Hero ---------- */
.hero {
  padding: 72px 0 56px;
  text-align: center;
}
.hero__sticker-wrap {
  display: flex;
  justify-content: center;
  margin-bottom: 28px;
}
.hero__title {
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  line-height: 1.08;
  letter-spacing: -0.01em;
  max-width: 920px;
  margin: 0 auto;
}
.hero__lede {
  margin: 26px auto 0;
  max-width: 580px;
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--muted);
}
.hero__cta {
  margin-top: 36px;
}

/* ---------- Manifesto band ---------- */
.manifesto {
  background: var(--lina-blue);
  color: var(--cream);
  padding: 88px 0;
}
.manifesto__inner {
  max-width: 780px;
  margin: 0 auto;
  text-align: center;
}
.manifesto h2 {
  font-size: clamp(1.8rem, 4.2vw, 2.9rem);
  line-height: 1.18;
  color: var(--white);
}
.manifesto p {
  margin-top: 24px;
  font-size: clamp(1rem, 1.6vw, 1.15rem);
  color: rgba(246,243,236,0.86);
  line-height: 1.65;
}

/* ---------- Stories grid ---------- */
.stories {
  padding: 88px 0;
}
.stories__head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 48px;
}
.stories__head h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
}
.stories__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
}
.story-card {
  position: relative;
  display: block;
  min-height: 460px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--ink);
  box-shadow: var(--shadow-brutal);
  overflow: hidden;
  text-decoration: none;
  color: var(--white);
  background-size: cover;
  background-position: center;
  transition: transform .18s var(--ease, cubic-bezier(.34,1.56,.64,1)), box-shadow .18s;
}
.story-card:hover {
  transform: translate(-2px, -2px);
  box-shadow: 8px 8px 0 var(--ink);
}
.story-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(0,0,0,0.82) 100%);
}
/* Optional dedicated image layer — only used when a card needs its photo
   nudged (e.g. a slight zoom) independently of the card's border/shadow.
   Cards that set background-image directly on .story-card (the default)
   don't use this. */
.story-card__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-size: cover;
  background-position: center;
}
.story-card__bg--zoom-3 {
  transform: scale(1.03);
}
.story-card__content {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 24px;
  z-index: 2;
}
.story-card__meta {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--yellow);
}
.story-card__name {
  margin-top: 8px;
  font-family: var(--font-head);
  font-size: 1.7rem;
  line-height: 1.15;
}
.story-card__link {
  display: inline-block;
  margin-top: 14px;
  font-weight: 700;
  font-size: 14px;
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 3px;
  text-underline-offset: 4px;
}

/* ---------- Closing CTA ---------- */
.closing {
  padding: 96px 0 100px;
  text-align: center;
}
.closing h2 {
  font-size: clamp(1.9rem, 4.6vw, 3rem);
  max-width: 680px;
  margin: 0 auto;
}
.closing__cta {
  margin-top: 32px;
}

/* ============================================================
   Story page (historia-N.html)
   ============================================================ */

.story-hero {
  position: relative;
  min-height: 62vh;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
  color: var(--white);
}
.story-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05) 30%, rgba(0,0,0,0.85) 100%);
}
.story-hero__inner {
  position: relative;
  z-index: 1;
  max-width: 860px;
  margin: 0 auto;
  padding: 56px 24px 48px;
  width: 100%;
}
.story-hero__title {
  margin-top: 18px;
  font-size: clamp(2rem, 5.2vw, 3.6rem);
  line-height: 1.1;
}
.story-hero__meta {
  margin-top: 16px;
  font-size: 15px;
  letter-spacing: 0.02em;
  color: rgba(255,255,255,0.85);
}
/* Author/photo-credit line, e.g. for a photo-essay byline under the
   kicker — smaller and more muted than .story-hero__meta. */
.story-hero__byline {
  margin-top: 10px;
  font-size: 13px;
  color: rgba(255,255,255,0.7);
}
.story-hero__byline a {
  color: inherit;
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.article {
  padding: 64px 0 40px;
}
.article__lede {
  font-family: var(--font-head);
  font-size: clamp(1.2rem, 2.4vw, 1.5rem);
  line-height: 1.5;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 36px;
}
.article h2 {
  font-size: clamp(1.4rem, 2.8vw, 1.9rem);
  margin-top: 48px;
  margin-bottom: 18px;
}
.article p {
  margin: 0 0 20px;
  font-size: 1.05rem;
  line-height: 1.75;
  color: #3a3835;
}
.pull-quote {
  margin: 40px 0;
  padding: 4px 0 4px 28px;
  border-left: 4px solid var(--yellow);
}
.pull-quote p {
  font-family: var(--font-head);
  font-style: italic;
  font-size: clamp(1.25rem, 2.6vw, 1.6rem);
  line-height: 1.45;
  color: var(--ink);
  margin: 0;
}
.pull-quote cite {
  display: block;
  margin-top: 14px;
  font-style: normal;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  color: var(--muted);
}
.inline-figure {
  margin: 40px 0;
}
.inline-figure img {
  border-radius: var(--radius-md);
  border: 2px solid var(--ink);
  box-shadow: var(--shadow-brutal-sm);
}
.inline-figure figcaption {
  margin-top: 12px;
  font-size: 14px;
  color: var(--muted);
}
/* Modifier for inline photos in portrait orientation — keeps horizontal
   inline photos (and the .story-hero cover, untouched) at full column
   width, but narrows and centers vertical ones so they don't tower over
   the article text. */
.inline-figure.figure-vertical img {
  display: block;
  max-width: 460px;
  margin-inline: auto;
}
.inline-figure.figure-vertical figcaption {
  text-align: center;
}

.hero-facts {
  margin: 44px 0;
  background: var(--white);
  border: 2px solid var(--ink);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-brutal-sm);
  padding: 28px;
}
.hero-facts dl {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  margin: 0;
}
.hero-facts dt {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--lina-blue);
}
.hero-facts dd {
  margin: 6px 0 0;
  font-size: 15px;
  color: var(--ink);
}

/* Photo-essay gallery — a grid of mixed horizontal/vertical photos at a
   uniform height, for stories that are a gallery rather than a
   quote-driven narrative. auto-fit already collapses to 1 column on
   narrow phones and ~2 inside the narrow article column on desktop. */
.gallery {
  margin: 48px 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
}
.gallery img {
  width: 100%;
  height: 340px;
  object-fit: cover;
  border-radius: var(--radius-md);
  border: 2px solid var(--ink);
  box-shadow: var(--shadow-brutal-sm);
}

.next-story {
  background: #ece8dc;
  padding: 64px 0;
  text-align: center;
}
.next-story__label {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}
.next-story__name {
  margin-top: 10px;
  font-size: clamp(1.6rem, 3.6vw, 2.3rem);
}
.next-story__link {
  display: inline-block;
  margin-top: 20px;
}
.back-link {
  display: inline-block;
  margin-top: 20px;
  font-size: 15px;
  font-weight: 700;
  text-decoration: underline;
  text-decoration-color: var(--yellow);
  text-decoration-thickness: 3px;
  text-underline-offset: 4px;
}

@media (max-width: 640px) {
  .hero { padding: 48px 0 40px; }
  .manifesto, .stories { padding: 56px 0; }
  .closing { padding: 64px 0 72px; }
  .article { padding: 44px 0 24px; }
}
