@import url('https://fonts.googleapis.com/css2?family=Libre+Baskerville:wght@400;700&family=Source+Sans+3:wght@400;600;700&display=swap');

/* ==========================================================================
   1. VARIABLES & DESIGN TOKENS
   ========================================================================== */
:root {
    /* Paleta Cromática */
    --color-primary: #316998;
    --color-secondary: #3C626E;
    --color-grafito: #292929;
    --color-blanco: #FEFEFE;
    --color-lima: #DADF0C;

    /* Colores Ambientales */
    --bg-header: rgba(49, 105, 152, 0.04);
    --bg-footer: rgba(49, 105, 152, 0.06);
    --bg-alt: #fcfcfc;
    --bg-card-hover: rgba(49, 105, 152, 0.02);

    /* UI Elements */
    --divider: rgba(41, 41, 41, 0.1);
    --radius-standard: 16px;
    --radius-btn: 14px;

    /* Tipografía */
    --font-main: 'Source Sans 3', sans-serif;
    --font-serif: 'Libre Baskerville', serif;

    /* Layout */
    --max-wide: 1050px;
    --max-narrow: 740px;
}

/* ==========================================================================
   2. RESET & BASE
   ========================================================================== */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--color-blanco);
    color: var(--color-grafito);
    font-family: var(--font-main);
    line-height: 1.65;
    font-size: 1.05rem;
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ==========================================================================
   3. TIPOGRAFÍA
   ========================================================================== */
h1,
h2,
h3 {
    color: var(--color-secondary);
    font-weight: 700;
    line-height: 1.2;
}

h1 {
    font-size: 2.25rem;
    margin-bottom: 1.5rem;
    letter-spacing: -0.01em;
}

h2 {
    font-size: 1.75rem;
    margin-top: 1.5rem;
    margin-bottom: 1.25rem;
    position: relative;
    padding-bottom: 0.5rem;
}

h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--color-lima);
}

h3 {
    font-size: 1.25rem;
    margin-bottom: 1.25rem;
    color: var(--color-grafito);
}

p {
    margin-bottom: 1.25rem;
}

strong {
    font-weight: 600;
    color: var(--color-grafito);
}

.font-serif {
    font-family: var(--font-serif);
    font-weight: 400;
}

/* Enlaces Globales */
a {
    color: var(--color-primary);
    text-decoration: none;
    transition: all 0.2s ease;
}

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

/* ==========================================================================
   4. LAYOUT & GRID
   ========================================================================== */
.container {
    max-width: var(--max-wide);
    margin: 0 auto;
    padding: 0 1.5rem;
}

.content-narrow {
    max-width: var(--max-narrow);
    margin: 0 auto;
}

section {
    padding: 1.5rem 0;
}

/* Secciones con fondo: el fondo es total, el ritmo lo da el padding base de section */
.alt-bg {
    background-color: var(--bg-alt);
    border-top: 1px solid var(--divider);
}

/* ==========================================================================
   5. COMPONENTES
   ========================================================================== */

/* Header & Navegación */
header {
    background-color: var(--bg-header);
    border-bottom: 1px solid var(--divider);
    padding: 1.25rem 0;
}

nav {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 1.5rem;
}

nav a {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-secondary);
    padding: 0.75rem 0.5rem;
    display: inline-block;
    border-bottom: 2px solid transparent;
}

nav a.active {
    color: var(--color-primary);
    border-bottom-color: var(--color-lima);
}

/* Hero Section */
.hero-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 2.5rem 0;
    align-items: start;
}

.hero-content p:last-child {
    margin-bottom: 0;
}

/* Tarjetas CTA del Home */
.cta-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    width: 100%;
}

.cta-card {
    background-color: var(--color-blanco);
    border-radius: var(--radius-standard);
    padding: 1.5rem;
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
    text-decoration: none;
    transition: background-color 0.2s ease;
    height: 100%;
}

.cta-card:hover {
    background-color: var(--bg-card-hover);
}

.cta-card__icon {
    flex-shrink: 0;
    width: 54px;
    /* Icon Box Fijo */
    height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cta-card__icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.cta-card__body {
    flex: 1;
}

.cta-card__body h3 {
    margin-bottom: 0.35rem;
    font-size: 1.15rem;
    color: var(--color-primary);
    position: relative;
    display: inline-block;
}

.cta-card__body h3::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 25px;
    height: 2px;
    background-color: var(--color-lima);
    opacity: 0.8;
}

.cta-card__body p {
    font-size: 0.95rem;
    color: var(--color-grafito);
    opacity: 0.85;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.cta-card__link {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--color-secondary);
}

/* Video Wrapper */
.video-wrapper {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--divider);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
}

.video-container {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
}

.video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Botones & Cards Generales */
.card {
    background-color: var(--color-blanco);
    border: 1px solid var(--divider);
    padding: 2rem;
    border-radius: var(--radius-standard);
}

.btn {
    display: inline-block;
    padding: 10px 18px;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-btn);
    transition: all 0.2s ease;
    cursor: pointer;
    border: 2px solid transparent;
    text-align: center;
}

.btn--primary {
    background-color: rgba(49, 105, 152, 0.08);
    border-color: rgba(49, 105, 152, 0.22);
    color: var(--color-primary) !important;
}

.btn--primary:hover {
    background-color: rgba(49, 105, 152, 0.15);
}

.btn--secondary {
    border-color: rgba(60, 98, 110, 0.28);
    color: var(--color-secondary) !important;
}

.btn--secondary:hover {
    background-color: rgba(60, 98, 110, 0.08);
}

/* Formulario */
.contact-grid {
    display: grid;
    gap: 1rem;
}

.field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

label {
    font-size: 0.9rem;
    font-weight: 600;
}

input,
textarea {
    padding: 0.75rem 1rem;
    border: 1px solid var(--divider);
    border-radius: 8px;
    font-family: inherit;
    font-size: 1rem;
}

.hidden-field {
    display: none !important;
}

/* ==========================================================================
   6. FOOTER
   ========================================================================== */
footer {
    padding: 4rem 0 3rem;
    background-color: var(--bg-footer);
    border-top: 1px solid var(--divider);
    text-align: center;
    font-size: 0.85rem;
    color: var(--color-secondary);
}

.footer-links {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    opacity: 0.8;
}

.footer-links a {
    color: var(--color-secondary);
    font-weight: 600;
}

.footer-links a:hover {
    color: var(--color-primary);
    text-decoration: underline;
}

/* ==========================================================================
   7. MEDIA QUERIES
   ========================================================================== */

/* Desktop Refinement */
@media (min-width: 992px) {
    .hero-grid {
        grid-template-columns: 1fr 1fr;
        column-gap: 4rem;
        row-gap: 3rem;
        align-items: center;
        padding: 4rem 0;
    }

    .cta-cards {
        grid-column: 1 / -1;
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}

/* Mobile & Tablet Adjustments */
@media (max-width: 768px) {
    h1 {
        font-size: 1.8rem;
    }

    nav {
        flex-direction: column;
        gap: 1rem;
    }

    nav ul {
        gap: 1rem;
        flex-wrap: wrap;
        justify-content: center;
    }
}

/* Utilities */
.mt-2 {
    margin-top: 1.5rem;
}

.toggle-link {
    cursor: pointer;
    font-weight: 600;
    color: var(--color-secondary);
    font-size: 0.9rem;
    margin-top: 1rem;
    text-align: center;
    list-style: none;
}

.toggle-link:hover {
    color: var(--color-primary);
    text-decoration: underline;
}

details>summary::-webkit-details-marker {
    display: none;
}

/* ==========================================================================
   8. RITMO VERTICAL (FUENTE DE VERDAD)
   ========================================================================== */

/* 
   Eliminamos el margen superior del primer elemento y el inferior del último 
   dentro de los contenedores para que el padding de 'section' sea el único 
   que controle el espacio entre bloques.
*/
section> :first-child,
section>div> :first-child,
section>.content-narrow> :first-child,
section>.container> :first-child {
    margin-top: 0 !important;
}

section> :last-child,
section>div> :last-child,
section>.content-narrow> :last-child,
section>.container> :last-child {
    margin-bottom: 0 !important;
}

/* Variante compacta opcional */
.section--tight,
.alt-bg--tight {
    padding: 1rem 0;
}

/* Reset de bordes para casos especiales */
.alt-bg--no-borders {
    border-top: none !important;
    border-bottom: none !important;
}

/* ==========================================================================
   9. SEMINARIO: SECCIÓN 3 IMÁGENES (SOLO ESTO)
   ========================================================================== */

/* Contenedor de los 3 ejes */
.seminar-pillars {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2.5rem;
}

/* Cada bloque (usa el div existente, no requiere clase nueva) */
.seminar-pillars > div {
  text-align: center;
}

/* Imagen circular */
.seminar-pillars img {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 1rem;
  object-fit: cover;
}

/* Títulos */
.seminar-pillars h3 {
  margin-bottom: 0.5rem;
}

/* Texto descriptivo */
.seminar-pillars p {
  max-width: 28ch;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

/* Solo el matraz (no afecta psi.png) */
.cta-card__icon img.icon-flask{
  max-width: 68px;   /* antes 44px -> +9% aprox */
  max-height: 68px;  /* antes 44px -> +9% aprox */
  width: auto;
  height: auto;
}

.clean-list{
  list-style: disc;
  list-style-position: inside;
  padding-left: 0;
  margin-left: 0;
}

.clean-list li{
  margin-bottom: 0.5rem;
}