/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:        #F5F0E6;
  --bg-2:      #ECE4D3;
  --paper:     #FFFCF5;
  --ink:       #182420;
  --ink-soft:  #2A3630;
  --ink-mute:  #6D675B;
  --accent:    #275D3F;   /* verde pino — acento primario */
  --accent-2:  #B5622E;   /* cobre — SOLO el punto y microdetalles */
  --line:      rgba(24, 36, 32, 0.14);
  --night:     #182420;              /* verde-noche: hero y footer */
  --cream-on-dark: #F5F0E6;
  --sage:      #9CCDAA;              /* énfasis legible sobre oscuro */
  --line-dark: rgba(245, 240, 230, 0.16);

  --serif: "Fraunces", Georgia, serif;
  --sans:  "Inter", system-ui, -apple-system, sans-serif;

  --gutter: clamp(1.25rem, 4vw, 2.5rem);
  --section-pad: clamp(4rem, 10vw, 7.5rem);

  --ease-out:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-soft: cubic-bezier(0.25, 0.46, 0.45, 0.94);

  --radius: 14px;
  --shadow-lift: 0 18px 44px -18px rgba(24, 36, 32, 0.28);
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 { text-wrap: balance; line-height: 1.06; letter-spacing: -0.015em; }
ul, ol { list-style: none; padding: 0; }
::selection { background: var(--accent); color: var(--bg); }

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

/* =============================================================
   3. Utilities
   ============================================================= */
.container { max-width: 1120px; margin: 0 auto; padding-inline: var(--gutter); }

.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .6rem 1rem; background: var(--ink); color: var(--bg);
  z-index: 9999; border-radius: 8px; font-weight: 500;
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   4. Typography
   ============================================================= */
.kicker {
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--ink-mute);
}

.section-title {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 5.5vw, 3.4rem);
  font-weight: 550;
  font-variation-settings: "SOFT" 60, "opsz" 60;
}
.section-title .dot { color: var(--accent-2); }

.section-lead {
  max-width: 46ch;
  margin-top: 1rem;
  font-size: clamp(1rem, 1.6vw, 1.125rem);
  color: var(--ink-soft);
}

/* =============================================================
   5. Components
   ============================================================= */
.btn {
  display: inline-block;
  padding: .85rem 1.5rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: .95rem;
  line-height: 1;
  transition: transform .35s var(--ease-out), box-shadow .35s var(--ease-out),
              background-color .35s var(--ease-out), color .35s var(--ease-out);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }

.btn-primary { background: var(--accent); color: var(--bg); box-shadow: 0 10px 26px -12px rgba(39, 93, 63, .55); }
.btn-primary:hover { box-shadow: 0 16px 34px -12px rgba(39, 93, 63, .6); }

.btn-ghost { border: 1px solid var(--line); color: var(--ink-soft); background: transparent; }
.btn-ghost:hover { border-color: var(--ink); color: var(--ink); }

.btn-big { padding: 1.05rem 2rem; font-size: 1.05rem; }

.btn-nav { background: var(--ink); color: var(--bg); padding: .6rem 1.1rem; font-size: .85rem; }

.btn-pack { width: 100%; text-align: center; background: var(--ink); color: var(--bg); }
.btn-pack:hover { background: var(--accent); }

/* Logo */
.logo {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 600;
  font-size: 1.5rem;
  letter-spacing: -0.01em;
  font-variation-settings: "SOFT" 100;
}
.logo-dot { color: var(--accent-2); font-style: normal; }

/* =============================================================
   6. Sections
   ============================================================= */

/* --- Nav --- */
.nav {
  position: fixed; inset-inline: 0; top: 0;
  z-index: 100;
  transition: background-color .4s var(--ease-soft), box-shadow .4s var(--ease-soft),
              backdrop-filter .4s var(--ease-soft);
}
.nav.is-scrolled {
  background: rgba(245, 240, 230, 0.88);
  backdrop-filter: blur(10px);
  box-shadow: 0 1px 0 var(--line);
}
.nav { color: var(--cream-on-dark); }
.nav .btn-nav { background: rgba(245, 240, 230, 0.12); color: var(--cream-on-dark); border: 1px solid var(--line-dark); }
.nav .nav-links { color: rgba(245, 240, 230, 0.85); }
.nav.is-scrolled { color: var(--ink); }
.nav.is-scrolled .nav-links { color: var(--ink-soft); }
.nav.is-scrolled .btn-nav { background: var(--ink); color: var(--bg); border-color: transparent; }
.nav-inner {
  max-width: 1120px; margin: 0 auto;
  padding: .9rem var(--gutter);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.nav-links { display: none; gap: 1.75rem; font-size: .92rem; font-weight: 500; }
.nav-links a { position: relative; }
.nav-links a::after {
  content: ""; position: absolute; left: 0; bottom: -4px;
  width: 100%; height: 1.5px; background: var(--accent);
  transform: scaleX(0); transform-origin: left;
  transition: transform .35s var(--ease-out);
}
.nav-links a:hover::after { transform: scaleX(1); }

/* --- Hero (oscuro, con Aether Flow detrás) --- */
.hero {
  padding-top: clamp(7rem, 18vw, 11rem);
  padding-bottom: clamp(3.5rem, 8vw, 6rem);
  position: relative;
}
.hero-dark {
  background:
    radial-gradient(ellipse 80% 60% at 60% 20%, #1E4630 0%, transparent 60%),
    var(--night);                      /* respaldo estático: pinta ANTES del JS */
  color: var(--cream-on-dark);
}
.hero-canvas {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  opacity: 0;
  transition: opacity 1.2s var(--ease-soft);
}
.hero-canvas.is-on { opacity: 1; }
.hero-veil {
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 28% 58%, rgba(24, 36, 32, 0.62) 0%, transparent 70%),
    linear-gradient(180deg, rgba(24, 36, 32, 0.35) 0%, transparent 30%, transparent 70%, rgba(24, 36, 32, 0.55) 100%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 1; }
.hero-dark .kicker { color: rgba(245, 240, 230, 0.72); }
.hero-title {
  margin-top: 1.1rem;
  font-family: var(--serif);
  font-weight: 480;
  font-size: clamp(2.5rem, 7.2vw, 4.6rem);
  font-variation-settings: "SOFT" 45, "opsz" 100;
  max-width: 18ch;
}
.hero-title em {
  font-style: italic;
  font-weight: 540;
  color: var(--sage);
  font-variation-settings: "SOFT" 100, "opsz" 100;
}
.hero-sub {
  margin-top: 1.4rem;
  max-width: 52ch;
  font-size: clamp(1.02rem, 1.8vw, 1.2rem);
  color: rgba(245, 240, 230, 0.85);
}
.hero-actions {
  margin-top: 2.2rem;
  display: flex; flex-wrap: wrap; gap: .9rem; align-items: center;
}
.hero-dark .btn-primary {
  background: var(--accent); color: var(--cream-on-dark);
  box-shadow: 0 0 0 1px rgba(156, 205, 170, 0.28), 0 14px 34px -12px rgba(0, 0, 0, 0.5);
}
.hero-dark .btn-ghost {
  border-color: var(--line-dark); color: var(--cream-on-dark);
}
.hero-dark .btn-ghost:hover { border-color: var(--cream-on-dark); }

/* --- Marquee --- */
.marquee {
  border-block: 1px solid var(--line);
  overflow: hidden;
  padding-block: .85rem;
  background: var(--bg-2);
}
.marquee-track {
  display: flex; align-items: center; gap: 2.2rem;
  width: max-content;
  animation: marquee 28s linear infinite;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.02rem;
  color: var(--ink-soft);
  white-space: nowrap;
}
.marquee-track i { color: var(--accent-2); font-style: normal; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* --- Sections base --- */
.section { padding-block: var(--section-pad); }
.section-alt { background: var(--bg-2); border-block: 1px solid var(--line); }

/* --- Casos --- */
.cases {
  margin-top: 2.8rem;
  display: grid; gap: 1.4rem;
}
.case {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem;
  display: flex; flex-direction: column; gap: .9rem;
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .case:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
}
.case-head { display: flex; justify-content: space-between; align-items: center; gap: 1rem; flex-wrap: wrap; }
.case-tag {
  font-size: .74rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent);
  background: rgba(39, 93, 63, .08);
  border: 1px solid rgba(39, 93, 63, .18);
  padding: .3rem .7rem; border-radius: 999px;
}
.case-live { display: flex; align-items: center; gap: .45rem; font-size: .8rem; font-weight: 600; color: var(--accent); }
.live-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent);
  animation: pulse 2.4s var(--ease-soft) infinite;
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(39, 93, 63, .35); }
  50%      { box-shadow: 0 0 0 7px rgba(39, 93, 63, 0); }
}
.case-title {
  font-family: var(--serif);
  font-size: clamp(1.4rem, 3vw, 1.8rem);
  font-weight: 550;
}
.case-title em { font-style: italic; font-weight: 450; color: var(--ink-mute); font-size: .78em; }
.case-desc { color: var(--ink-soft); max-width: 58ch; }
.case-points { display: grid; gap: .4rem; margin-top: .2rem; }
.case-points li {
  padding-left: 1.2rem; position: relative;
  color: var(--ink-soft); font-size: .95rem;
}
.case-points li::before {
  content: ""; position: absolute; left: 0; top: .55em;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent-2);
}
.case-link { font-weight: 600; color: var(--accent); margin-top: .3rem; }
.case-link:hover { text-decoration: underline; text-underline-offset: 4px; }

/* --- Método --- */
.steps {
  margin-top: 2.8rem;
  display: grid; gap: 2rem;
  counter-reset: step;
}
.step { border-top: 1px solid var(--line); padding-top: 1.4rem; }
.step-num {
  font-family: var(--serif);
  font-style: italic;
  font-size: 1rem;
  color: var(--accent-2);
}
.step h3 { font-family: var(--serif); font-size: 1.3rem; font-weight: 550; margin-top: .4rem; }
.step p { color: var(--ink-soft); margin-top: .5rem; max-width: 44ch; }

/* --- Paquetes --- */
.packs { margin-top: 2.8rem; display: grid; gap: 1.4rem; }
.pack {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.8rem;
  display: flex; flex-direction: column; gap: .8rem;
  transition: transform .45s var(--ease-out), box-shadow .45s var(--ease-out);
}
@media (hover: hover) and (pointer: fine) {
  .pack:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
}
.pack-name { font-family: var(--serif); font-size: 1.45rem; font-weight: 560; }
.pack-for { font-size: .88rem; color: var(--ink-mute); margin-top: -.4rem; }
.pack-price {
  font-family: var(--serif);
  font-size: clamp(1.7rem, 3.4vw, 2.1rem);
  font-weight: 500;
  color: var(--accent);
  border-block: 1px solid var(--line);
  padding-block: .7rem;
}
.pack-unit { font-size: .55em; color: var(--ink-mute); font-family: var(--sans); font-weight: 500; }
.pack-points { display: grid; gap: .45rem; }
.pack-points li {
  padding-left: 1.35rem; position: relative;
  font-size: .95rem; color: var(--ink-soft);
}
.pack-points li::before {
  content: "—"; position: absolute; left: 0; color: var(--accent-2);
}
.pack-meta { font-size: .8rem; color: var(--ink-mute); margin-top: auto; padding-top: .6rem; }

/* --- Testimonio --- */
.quote { max-width: 780px; margin: 0 auto; text-align: center; }
.quote blockquote {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 470;
  font-size: clamp(1.25rem, 3vw, 1.7rem);
  line-height: 1.45;
  font-variation-settings: "SOFT" 90;
}
.quote figcaption {
  margin-top: 1.6rem;
  font-size: .85rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-mute);
}

/* --- CTA final --- */
.cta-final { text-align: center; }
.cta-title {
  font-family: var(--serif);
  font-size: clamp(2rem, 5.5vw, 3.2rem);
  font-weight: 520;
  max-width: 20ch;
  margin-inline: auto;
}
.cta-title em { font-style: italic; color: var(--accent); font-variation-settings: "SOFT" 100; }
.cta-final .section-lead { margin-inline: auto; text-align: center; }
.cta-final .btn-big { margin-top: 2rem; }

/* --- Footer --- */
.footer { padding-block: 2.6rem; background: var(--night); color: var(--cream-on-dark); }
.footer-inner { display: grid; gap: .35rem; }
.logo-footer { font-size: 1.3rem; }
.footer-tag { font-size: .9rem; color: rgba(245, 240, 230, 0.8); }
.footer-note { font-size: .8rem; color: rgba(245, 240, 230, 0.55); font-style: italic; }

/* =============================================================
   7. Effects — reveals (JS-gated, defensive)
   ============================================================= */
html.has-js .reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity .8s var(--ease-soft), transform .8s var(--ease-out);
}
html.has-js .reveal.is-in { opacity: 1; transform: none; }

/* =============================================================
   8. Responsive
   ============================================================= */
@media (min-width: 540px) {
  .nav-links { display: flex; }
}
@media (min-width: 720px) {
  .steps { grid-template-columns: 1fr 1fr; gap: 2.4rem 3rem; }
  .cases { grid-template-columns: 1fr 1fr; }
  .case-featured { grid-column: 1 / -1; }
}
@media (min-width: 960px) {
  .packs { grid-template-columns: repeat(3, 1fr); }
  .case-featured { display: grid; grid-template-columns: 1.1fr 1fr; column-gap: 2.5rem; align-items: start; }
  .case-featured .case-head { grid-column: 1 / -1; }
  .case-featured .case-title, .case-featured .case-desc { grid-column: 1; }
  .case-featured .case-points, .case-featured .case-link { grid-column: 2; }
  .case-featured .case-points { margin-top: 0; }
}
@media (min-width: 1280px) {
  .steps { grid-template-columns: repeat(4, 1fr); }
}

/* =============================================================
   9. Reduced motion — solo lo intrusivo
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  .marquee-track { animation: none; }
  .live-dot { animation: none; }
  html { scroll-behavior: auto; }
  /* NO se desactivan: hovers, fades, reveals */
}
