/* ============================================================
   Diseño con IA para programadores — ConquerBlocks
   Brand: paper/cream base · black sections · orange gradient.
   Heavy display type · pixel-block motifs · rounded cards.
   ============================================================ */

:root {
  /* --- color: 60 paper / 30 black / 10 orange --- */
  --paper:     #f3eee2;   /* 60 — warm cream */
  --paper-2:   #ece5d5;
  --card:      #fbf8f1;   /* light surface */
  --ink:       #14110d;   /* 30 — near-black */
  --ink-2:     #1c1916;
  --line:      #ddd5c4;
  --line-dark: #2c2823;

  --text:      #1a1612;   /* on paper */
  --muted:     #6c6458;   /* on paper */
  --on-dark:   #f6f1e7;   /* on black */
  --on-dark-mut: #b3aa99;

  /* orange brand gradient */
  --o-1: #ffc01e;
  --o-2: #ff7e1b;
  --o-3: #f0481e;
  --accent: #f26419;
  --grad: linear-gradient(135deg, var(--o-1) 0%, var(--o-2) 48%, var(--o-3) 100%);

  --good: #1f9e6e;
  --bad:  #e0492c;

  /* --- type --- */
  --font-display: 'Sora', system-ui, sans-serif;
  --font-text: 'Inter', system-ui, sans-serif;

  --fs-hero: clamp(2.8rem, 7vw, 5.4rem);
  --fs-h2:   clamp(2rem, 4vw, 3.25rem);
  --fs-h3:   1.18rem;
  --fs-lead: clamp(1.05rem, 1.6vw, 1.3rem);

  /* --- spacing (8px scale) --- */
  --s-1: 0.5rem; --s-2: 1rem; --s-3: 1.5rem; --s-4: 2rem;
  --s-5: 3rem; --s-6: 4.5rem; --s-7: 7rem;

  --radius: 22px;
  --radius-sm: 14px;
  --maxw: 1160px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-text);
  line-height: 1.65; color: var(--text);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
svg { display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.04; letter-spacing: -0.03em; font-weight: 800; }
em { font-style: normal; }
strong { font-weight: 700; }

.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: var(--s-3); }
.grad-text {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem;
  font-family: var(--font-display); font-weight: 700; font-size: 0.95rem;
  padding: 0.85rem 1.6rem; border-radius: 12px; border: 2px solid transparent;
  cursor: pointer; transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s, color 0.18s;
  white-space: nowrap;
}
.btn--solid { background: var(--grad); color: #fff; box-shadow: 0 10px 24px -8px rgba(242,100,25,0.6); }
.btn--solid:hover { transform: translateY(-2px); box-shadow: 0 16px 30px -8px rgba(242,100,25,0.75); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--text); }
.btn--ghost:hover { background: var(--text); color: var(--paper); transform: translateY(-2px); }
.btn--sm { padding: 0.6rem 1.2rem; font-size: 0.88rem; }
.btn--lg { padding: 1.05rem 2.1rem; font-size: 1.05rem; }
/* on dark sections */
.section--dark .btn--ghost, .cta .btn--ghost { color: var(--on-dark); border-color: rgba(246,241,231,0.5); }
.section--dark .btn--ghost:hover, .cta .btn--ghost:hover { background: var(--on-dark); color: var(--ink); }

/* ============================================================
   Pixel-block motif (brand decoration)
   ============================================================ */
.pixels { position: absolute; display: grid; grid-template-columns: repeat(3, 1fr); gap: 4px; width: 96px; z-index: 1; pointer-events: none; opacity: 0.95; }
.pixels span { aspect-ratio: 1; border-radius: 4px; background: var(--grad); }
.pixels span:nth-child(3n+1) { opacity: 0.35; }
.pixels span:nth-child(2) { opacity: 0; }
.pixels span:nth-child(7) { opacity: 0; }
.pixels--tl { top: var(--s-5); left: var(--s-3); }
.pixels--col { display: grid; grid-template-columns: 1fr; width: 34px; gap: 5px; }
.pixels--col span:nth-child(odd) { opacity: 1; }
.pixels--col span:nth-child(even) { opacity: 0.4; }
.pixels--r { top: 38%; right: var(--s-3); }

/* ============================================================
   Nav
   ============================================================ */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(243,238,226,0.82); backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent; transition: border-color 0.3s, box-shadow 0.3s;
}
.nav.is-stuck { border-color: var(--line); box-shadow: 0 6px 20px -16px rgba(0,0,0,0.4); }
.nav__inner { display: flex; align-items: center; justify-content: space-between; height: 74px; gap: var(--s-3); }

.brand { display: inline-flex; align-items: center; }
.brand__logo { height: 46px; width: auto; border-radius: 10px; display: block; }

.nav__links { display: flex; gap: var(--s-4); }
.nav__links a { color: var(--text); font-size: 0.95rem; font-weight: 600; font-family: var(--font-display); transition: color 0.2s; }
.nav__links a:hover { color: var(--accent); }

/* ============================================================
   Sections
   ============================================================ */
.section { position: relative; padding: var(--s-7) 0; }
.section--alt { background: var(--paper-2); }
.section--dark { background: var(--ink); color: var(--on-dark); }
.section--dark .section__lead, .section--dark .ab__card p { color: var(--on-dark-mut); }

.kicker { display: inline-block; font-family: var(--font-display); font-weight: 700; font-size: 0.8rem; letter-spacing: 0.1em; text-transform: uppercase; margin-bottom: var(--s-2); color: var(--accent); }
.section__title { font-size: var(--fs-h2); max-width: 20ch; margin-bottom: var(--s-3); }
.section--dark .section__title { color: var(--on-dark); }
.section__lead { font-size: var(--fs-lead); color: var(--muted); max-width: 62ch; }
.section__lead--center { margin-top: var(--s-5); text-align: center; margin-inline: auto; }

/* ============================================================
   Hero
   ============================================================ */
.hero { position: relative; padding: var(--s-7) 0 var(--s-6); overflow: hidden; }
.hero__inner { position: relative; z-index: 2; max-width: 980px; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-family: var(--font-display); font-weight: 600; font-size: 0.82rem; letter-spacing: 0.02em;
  color: var(--text); background: var(--card);
  padding: 0.45rem 1rem; margin-bottom: var(--s-3);
  border: 1px solid var(--line); border-radius: 999px;
}
.eyebrow::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--grad); }
.hero__title { font-size: var(--fs-hero); margin-bottom: var(--s-3); }
.hero__sub { font-size: var(--fs-lead); color: var(--muted); max-width: 640px; margin-bottom: var(--s-4); }
.hero__actions { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-bottom: var(--s-5); }
.hero__meta { display: flex; flex-wrap: wrap; gap: var(--s-5); list-style: none; }
.hero__meta li { display: flex; flex-direction: column; }
.hero__meta strong { font-family: var(--font-display); font-weight: 800; font-size: 1.7rem; color: var(--text); line-height: 1; }
.hero__meta span { font-size: 0.85rem; color: var(--muted); margin-top: 0.25rem; }

/* ============================================================
   A -> B  (on dark)
   ============================================================ */
.ab { display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch; gap: var(--s-3); margin-top: var(--s-5); }
.ab__card { background: var(--ink-2); border: 1px solid var(--line-dark); border-radius: var(--radius); padding: var(--s-4); }
.ab__card--b { border-color: rgba(242,100,25,0.55); box-shadow: 0 30px 60px -34px rgba(242,100,25,0.5); }
.ab__tag { display: inline-block; font-family: var(--font-display); font-size: 0.78rem; font-weight: 700; color: var(--on-dark-mut); margin-bottom: var(--s-2); text-transform: uppercase; letter-spacing: 0.05em; }
.ab__tag--ok { color: var(--o-2); }
.ab__card h3 { font-size: 1.4rem; margin-bottom: var(--s-2); color: var(--on-dark); }
.ab__card p { margin-bottom: var(--s-3); }
.ab__list { list-style: none; display: grid; gap: 0.55rem; }
.ab__list li { position: relative; padding-left: 1.7rem; font-size: 0.95rem; color: var(--on-dark); }
.ab__list li::before { position: absolute; left: 0; top: 0; font-weight: 800; }
.ab__list--bad li::before { content: "✕"; color: var(--bad); }
.ab__list--good li::before { content: "✓"; color: var(--good); }
.ab__arrow { display: grid; place-items: center; font-size: 2rem; color: var(--o-2); font-family: var(--font-display); }
.ab__note { margin-top: var(--s-4); text-align: center; font-size: var(--fs-lead); color: var(--on-dark); max-width: 58ch; margin-inline: auto; }

/* ============================================================
   Bases
   ============================================================ */
.bases { display: grid; grid-template-columns: repeat(5, 1fr); gap: var(--s-2); margin-top: var(--s-5); }
.base { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: var(--s-3); transition: transform 0.25s var(--ease), box-shadow 0.25s; }
.base:hover { transform: translateY(-4px); box-shadow: 0 18px 30px -22px rgba(0,0,0,0.35); }
.base__n { font-family: var(--font-display); font-weight: 800; font-size: 0.95rem; }
.base h3 { font-size: 1.1rem; margin: 0.5rem 0 0.3rem; }
.base p { font-size: 0.88rem; color: var(--muted); }

/* ============================================================
   Clases (accordion, on dark)
   ============================================================ */
.classes { list-style: none; margin-top: var(--s-5); display: grid; gap: var(--s-1); }
.class { background: var(--ink-2); border: 1px solid var(--line-dark); border-radius: var(--radius-sm); overflow: hidden; transition: border-color 0.25s, background 0.25s; }
.class:hover { border-color: #3a342c; }
.class.is-open { border-color: rgba(242,100,25,0.6); }
.class__head { width: 100%; display: flex; align-items: center; gap: var(--s-3); padding: var(--s-3); background: none; border: none; color: var(--on-dark); cursor: pointer; text-align: left; font-family: var(--font-text); }
.class__num { font-family: var(--font-display); font-weight: 800; font-size: 1rem; width: 2ch; flex-shrink: 0; }
.class__title { font-family: var(--font-display); font-weight: 700; font-size: var(--fs-h3); flex: 1; }
.class__toggle { position: relative; width: 18px; height: 18px; flex-shrink: 0; }
.class__toggle::before, .class__toggle::after { content: ""; position: absolute; background: var(--on-dark-mut); border-radius: 2px; transition: transform 0.3s var(--ease), background 0.3s; }
.class__toggle::before { top: 8px; left: 0; width: 18px; height: 2px; }
.class__toggle::after { top: 0; left: 8px; width: 2px; height: 18px; }
.class.is-open .class__toggle::after { transform: scaleY(0); }
.class.is-open .class__toggle::before { background: var(--o-2); }
.class__body { max-height: 0; overflow: hidden; transition: max-height 0.4s var(--ease); padding-left: calc(var(--s-3) + 2ch + var(--s-3)); padding-right: var(--s-3); }
.class.is-open .class__body { max-height: 340px; }
.class__body p { color: var(--on-dark-mut); padding-bottom: var(--s-2); }
.class.is-open .class__body { padding-bottom: var(--s-3); }
.class__out { font-size: 0.95rem; color: var(--on-dark) !important; }
.class__out span { color: var(--o-2); font-weight: 700; font-family: var(--font-display); }

/* ============================================================
   Valor
   ============================================================ */
.value { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--s-2); margin-top: var(--s-5); }
.value__card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--s-4); position: relative; transition: transform 0.25s var(--ease), box-shadow 0.25s; }
.value__card::before { content: ""; position: absolute; left: var(--s-4); top: var(--s-4); width: 32px; height: 4px; border-radius: 2px; background: var(--grad); }
.value__card:hover { transform: translateY(-4px); box-shadow: 0 22px 40px -26px rgba(0,0,0,0.35); }
.value__card h3 { font-size: 1.3rem; margin: var(--s-3) 0 0.5rem; }
.value__card p { color: var(--muted); }

/* ============================================================
   Formato (on dark)
   ============================================================ */
.formato { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: var(--s-6); align-items: center; }
.formato__stats { display: grid; grid-template-columns: 1fr 1fr; gap: var(--s-2); }
.stat { background: var(--ink-2); border: 1px solid var(--line-dark); border-radius: var(--radius); padding: var(--s-4) var(--s-3); text-align: center; }
.stat__big { display: block; font-family: var(--font-display); font-weight: 800; font-size: 2.8rem; line-height: 1; color: var(--on-dark); margin-bottom: 0.4rem; }
.stat__big small { font-size: 1rem; font-weight: 700; }
.stat__label { font-size: 0.82rem; color: var(--on-dark-mut); }

/* ============================================================
   CTA (orange)
   ============================================================ */
.cta { position: relative; padding: var(--s-7) 0; text-align: center; overflow: hidden; background: var(--grad); color: #fff; }
.cta__inner { position: relative; z-index: 2; max-width: 760px; }
.cta h2 { font-size: var(--fs-h2); color: #fff; margin-bottom: var(--s-2); }
.cta p { color: rgba(255,255,255,0.92); font-size: var(--fs-lead); margin-bottom: var(--s-4); }
.cta__actions { display: flex; flex-wrap: wrap; gap: var(--s-2); justify-content: center; }
.cta .btn--solid { background: var(--ink); color: #fff; box-shadow: 0 10px 24px -8px rgba(0,0,0,0.5); }
.cta .btn--ghost { color: #fff; border-color: rgba(255,255,255,0.7); }
.cta .btn--ghost:hover { background: #fff; color: var(--accent); }

/* ============================================================
   Footer
   ============================================================ */
.footer { border-top: 1px solid var(--line-dark); padding: var(--s-5) 0; background: var(--ink); color: var(--on-dark); }
.footer__inner { display: flex; flex-direction: column; align-items: center; gap: 0.8rem; text-align: center; }
.footer .brand__logo { height: 56px; }
.footer__tag { font-family: var(--font-display); color: var(--on-dark-mut); font-size: 0.95rem; }
.footer__copy { color: #7d7568; font-size: 0.85rem; }

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

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .ab { grid-template-columns: 1fr; }
  .ab__arrow { transform: rotate(90deg); }
  .bases { grid-template-columns: repeat(2, 1fr); }
  .value { grid-template-columns: 1fr; }
  .formato { grid-template-columns: 1fr; gap: var(--s-4); }
  .pixels--r { display: none; }
}
@media (max-width: 520px) {
  .bases { grid-template-columns: 1fr; }
  .hero { padding-top: var(--s-6); }
  .class__title { font-size: 1.02rem; }
  .pixels--tl { display: none; }
}
