/* ============================================================
   TakeYourDesign — Base: reset, tipografía, utilidades
   ============================================================ */

*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img, svg, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input, textarea, select { font: inherit; color: inherit; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

h1 { font-size: var(--fs-hero); }
h2 { font-size: var(--fs-h2); }
h3 { font-size: var(--fs-h3); }

p { text-wrap: pretty; }

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

::selection { background: var(--brand); color: #fff; }

/* ---------- Layout ---------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.25rem, 4vw, 2rem);
}

.section { padding-block: var(--section-y); }
.section--tight { padding-block: calc(var(--section-y) * 0.6); }
.section--alt { background: var(--surface); }
.section--dark { background: var(--dark); color: var(--ink-dark); }

/* ---------- Encabezados de sección ---------- */

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 1.1rem;
}

.kicker::before {
  content: "";
  width: 26px;
  height: 2px;
  background: var(--brand);
  border-radius: 2px;
}

.section-head { max-width: 720px; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-head--center .kicker { justify-content: center; }

.section-head p {
  margin-top: 1.1rem;
  font-size: var(--fs-lead);
  color: var(--ink-3);
}

.section--dark .section-head p { color: var(--ink-dark-2); }

/* ---------- Botones ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 0.95rem 1.7rem;
  border-radius: var(--r-pill);
  font-weight: 600;
  font-size: 0.95rem;
  line-height: 1;
  transition: transform var(--t-fast) var(--ease), box-shadow var(--t-fast) var(--ease),
    background var(--t-fast) var(--ease), color var(--t-fast) var(--ease),
    border-color var(--t-fast) var(--ease);
  will-change: transform;
}

.btn svg { width: 16px; height: 16px; transition: transform var(--t-fast) var(--ease); }
.btn:hover svg { transform: translateX(3px); }

.btn--primary {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 10px 30px -10px var(--brand-glow);
}
.btn--primary:hover { background: var(--brand-strong); transform: translateY(-2px); box-shadow: var(--shadow-brand); }

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

.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }

.btn--ghost-dark {
  border: 1px solid var(--line-dark);
  color: var(--ink-dark);
}
.btn--ghost-dark:hover { border-color: var(--ink-dark); transform: translateY(-2px); }

/* ---------- Badges / chips ---------- */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 1rem;
  border-radius: var(--r-pill);
  border: 1px solid var(--line);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--ink-2);
  background: var(--surface);
}

.badge--dark {
  border-color: var(--line-dark);
  color: var(--ink-dark-2);
  background: rgba(255, 255, 255, 0.04);
}

.badge .dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 0 4px var(--brand-soft);
}

/* ---------- Animación reveal ---------- */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--t-slow) var(--ease), transform var(--t-slow) var(--ease);
  transition-delay: var(--reveal-delay, 0s);
}

.reveal.is-visible { opacity: 1; transform: none; }

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

/* ---------- Accesibilidad ---------- */

.skip-link {
  position: absolute;
  left: 1rem;
  top: -100%;
  z-index: 200;
  padding: 0.75rem 1.25rem;
  background: var(--brand);
  color: #fff;
  border-radius: var(--r-sm);
  font-weight: 600;
  transition: top var(--t-fast) var(--ease);
}

.skip-link:focus { top: 1rem; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  clip-path: inset(50%);
  overflow: hidden;
  white-space: nowrap;
}
