/**
 * ====================================================================
 * BASE & TYPOGRAPHY - IESTP CHIVAY (Variante Ejecutiva Anti-Glare)
 * ====================================================================
 */

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

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

body {
  font-family: var(--font-family-base);
  color: var(--color-text-body);
  background-color: var(--color-bg-body);
  background-image: radial-gradient(circle at 10% 0%, rgba(114, 150, 208, 0.1), transparent 28rem), radial-gradient(circle at 90% 38%, rgba(247, 197, 21, 0.08), transparent 24rem);
  line-height: 1.65;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--color-primary-darker);
}

::-webkit-scrollbar-thumb {
  background: var(--color-gold);
  border-radius: var(--radius-full);
  border: 2px solid var(--color-primary-darker);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-gold-dark);
}

/* Tipografía de Alto Impacto */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-family-heading);
  color: var(--color-text-dark);
  font-weight: var(--font-weight-bold);
  line-height: 1.25;
  letter-spacing: -0.025em;
  margin-bottom: 0.75rem;
}

h1 { font-size: var(--font-size-4xl); font-weight: var(--font-weight-extrabold); }
h2 { font-size: var(--font-size-3xl); font-weight: var(--font-weight-extrabold); }
h3 { font-size: var(--font-size-2xl); }
h4 { font-size: var(--font-size-xl); }
h5 { font-size: var(--font-size-lg); }
h6 { font-size: var(--font-size-base); }

p {
  margin-bottom: 1rem;
}

a {
  color: var(--color-condor-blue);
  text-decoration: none;
  transition: all var(--transition-fast);
}

a:hover {
  color: var(--color-red);
}

img, svg {
  max-width: 100%;
  height: auto;
  vertical-align: middle;
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
  line-height: inherit;
  outline: none;
}

::selection {
  background-color: var(--color-gold);
  color: var(--color-primary-dark);
}

/* Contenedores */
.container {
  width: 100%;
  max-width: var(--container-max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
}

/* Secciones con Equilibrio Visual */
.section {
  padding: 5.5rem 0;
  position: relative;
  overflow: hidden;
  background-color: rgba(244, 246, 248, 0.86);
}

.section--alt {
  background-color: rgba(233, 238, 243, 0.9);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.section--dark {
  background: var(--grad-hero);
  color: var(--color-white);
}

.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--color-white);
}

.section--dark .section-subtitle {
  color: rgba(255, 255, 255, 0.85);
}

.section-header {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 3.5rem auto;
  position: relative;
  z-index: 2;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1.15rem;
  background-color: rgba(16, 28, 48, 0.08);
  color: var(--color-primary);
  border: 1px solid rgba(16, 28, 48, 0.18);
  font-size: var(--font-size-xs);
  font-weight: var(--font-weight-bold);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  border-radius: var(--radius-full);
  margin-bottom: 1rem;
}

.section--dark .section-tag {
  background-color: rgba(245, 158, 11, 0.18);
  color: var(--color-gold);
  border-color: var(--color-gold);
}

.section-title {
  font-size: var(--font-size-3xl);
  letter-spacing: -0.03em;
  margin-bottom: 0.85rem;
  color: var(--color-primary);
}

.section-subtitle {
  font-size: var(--font-size-md);
  color: var(--color-text-muted);
  line-height: 1.65;
  font-weight: var(--font-weight-normal);
}

/* Animaciones de Reveal y Efectos */
.reveal-on-scroll {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.reveal-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Helpers & Utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-primary { color: var(--color-primary); }
.text-gold { color: var(--color-gold); }
.text-red { color: var(--color-red); }
.text-white { color: var(--color-white); }
.text-muted { color: var(--color-text-muted); }

.fw-bold { font-weight: var(--font-weight-bold); }
.fw-semibold { font-weight: var(--font-weight-semibold); }
.fw-medium { font-weight: var(--font-weight-medium); }

.hidden { display: none !important; }
