/* =============================================================
   JJM THEME — global.css
   Design tokens, reset, tipografía y helpers de layout.
   Importado primero en functions.php.
   ============================================================= */

/* ---- Google Fonts ------------------------------------------ */
@import url('https://fonts.googleapis.com/css2?family=Bebas+Neue&family=Barlow+Condensed:wght@400;600;700;800&family=Barlow:wght@300;400;500;600&display=swap');

/* ---- Tokens ------------------------------------------------- */
:root {
  /* Marca */
  --c-red:        #B10608;
  --c-red-hover:  #8a0406;
  --c-black:      #030406;
  --c-gray:       #D6D6D6;
  --c-gray-mid:   #888888;
  --c-gray-dark:  #1a1a1f;
  --c-gray-card:  #0f0f14;
  --c-white:      #ffffff;
  --c-green-wa:   #25d366;

  /* Tipografía */
  --font-display:  'Bebas Neue', sans-serif;
  --font-heading:  'Barlow Condensed', sans-serif;
  --font-body:     'Barlow', sans-serif;

  /* Espaciado — escala 4px */
  --sp-1:  4px;
  --sp-2:  8px;
  --sp-3:  12px;
  --sp-4:  16px;
  --sp-5:  20px;
  --sp-6:  24px;
  --sp-8:  32px;
  --sp-10: 40px;
  --sp-12: 48px;
  --sp-16: 64px;
  --sp-24: 96px;

  /* Layout */
  --max-width:    1200px;
  --gutter:       24px;
  --navbar-h:     64px;

  /* Radios */
  --radius-sm:  2px;
  --radius-md:  4px;
  --radius-lg:  8px;

  /* Transiciones */
  --t-fast:   0.15s ease;
  --t-base:   0.25s ease;
  --t-slow:   0.4s ease;

  /* Sombras */
  --shadow-sm:  0 2px 8px rgba(0,0,0,0.4);
  --shadow-md:  0 4px 24px rgba(0,0,0,0.5);
  --shadow-lg:  0 8px 48px rgba(0,0,0,0.6);

  /* Clip-path reutilizables — angled corners */
  --clip-corner-sm: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
  --clip-corner-md: polygon(0 0, calc(100% - 12px) 0, 100% 12px, 100% 100%, 12px 100%, 0 calc(100% - 12px));
  --clip-corner-lg: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
}

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

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

body {
  background-color: var(--c-black);
  color: var(--c-gray);
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

/* ---- Layout helpers ----------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section-pad  { padding: var(--sp-24) 0; }
.section-pad-sm { padding: var(--sp-16) 0; }

/* ---- Tipografía base ---------------------------------------- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--c-white);
  line-height: 0.95;
  letter-spacing: 0.02em;
}

p { line-height: 1.7; }

/* ---- Label de sección -------------------------------------- */
.section-label {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  font-family: var(--font-heading);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--c-red);
  margin-bottom: var(--sp-4);
}
.section-label::before {
  content: '';
  display: block;
  width: 32px;
  height: 2px;
  background: var(--c-red);
  flex-shrink: 0;
}

/* ---- Botones ----------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 14px var(--sp-8);
  transition: background var(--t-fast), transform var(--t-fast), border-color var(--t-base), color var(--t-base);
  line-height: 1;
  white-space: nowrap;
}

.btn-primary {
  background: var(--c-red);
  color: var(--c-white);
  clip-path: var(--clip-corner-sm);
}
.btn-primary:hover {
  background: var(--c-red-hover);
  transform: translateY(-1px);
}

.btn-outline {
  background: transparent;
  color: var(--c-white);
  border: 2px solid rgba(255,255,255,0.3);
}
.btn-outline:hover {
  border-color: var(--c-white);
}

.btn-ghost {
  background: transparent;
  color: var(--c-gray);
  padding: 10px var(--sp-4);
}
.btn-ghost:hover { color: var(--c-white); }

/* ---- Scroll reveal ----------------------------------------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
.reveal-d1 { transition-delay: 0.1s; }
.reveal-d2 { transition-delay: 0.2s; }
.reveal-d3 { transition-delay: 0.3s; }
.reveal-d4 { transition-delay: 0.4s; }

/* ---- Accesibilidad ----------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--c-red);
  outline-offset: 3px;
}

/* ---- Divisor con línea roja -------------------------------- */
.red-divider {
  width: 100%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--c-red), transparent);
  margin: var(--sp-8) 0;
}

/* ---- Tag / Badge ------------------------------------------- */
.tag {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--c-red);
  padding: 3px 10px;
  border: 1px solid var(--c-red);
}

/* ---- Responsive breakpoints -------------------------------- */
@media (max-width: 1024px) {
  :root { --gutter: 20px; }
}
@media (max-width: 768px) {
  :root {
    --gutter: 16px;
    --sp-24:  64px;
    --sp-16:  48px;
  }
}
@media (max-width: 480px) {
  :root { --sp-24: 48px; }
}
