/*
  NEO-CYBERPUNK DISRUPTIVE DESIGN
  By Gemini
  Project: JUAMPI IA
*/

/* ------------------- */
/* 1. Root & Variables */
/* ------------------- */

:root {
    /* Color Palette - Harmonized with index.html */
    --color-background: #080c0a;
    --color-surface: #101113;
    --color-primary: #00d9ff;
    /* JUAMPI Primary */
    --color-secondary: #7c3aed;
    /* JUAMPI Secondary */
    --color-accent: #f472b6;
    /* JUAMPI Accent */
    --color-text-primary: #ffffff;
    --color-text-secondary: rgba(255, 255, 255, 0.8);
    --color-border: rgba(255, 255, 255, 0.1);
    --color-border-accent: rgba(0, 217, 255, 0.3);

    /* Legacy/Alias variables for compatibility */
    --juampi-primary: var(--color-primary);
    --juampi-secondary: var(--color-secondary);
    --juampi-accent: var(--color-accent);
    --juampi-dark: var(--color-background);

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    --font-mono: 'JetBrains Mono', monospace;
    --font-display: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;

    /* Sizing & Spacing */
    --spacing-unit: 1rem;
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    --container-width: 1400px;
    /* Updated to match nav-container */
    --article-width: 820px;

    /* Effects */
    --shadow-glow: 0 0 20px rgba(0, 217, 255, 0.3);
    --transition-fast: all 0.25s ease;
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ------------------- */
/* 2. Global Resets    */
/* ------------------- */

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

html {
    scroll-behavior: smooth;
}

body {
    background-color: var(--color-background);
    color: var(--color-text-primary);
    font-family: var(--font-sans);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
}

body::after {
    content: " ";
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(12, 20, 16, 0) 50%, rgba(0, 12, 8, 0.25) 50%),
        linear-gradient(90deg, rgba(24, 255, 120, 0.05), rgba(0, 160, 96, 0.06));
    background-size: 100% 4px, 2px 100%;
    z-index: -1;
    pointer-events: none;
    mix-blend-mode: screen;
    animation: scanlines 0.7s linear infinite alternate-reverse;
    opacity: 0.75;
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 25% 20%, rgba(80, 255, 180, 0.06), transparent 35%),
        radial-gradient(circle at 75% 10%, rgba(48, 180, 120, 0.05), transparent 32%),
        radial-gradient(circle at 50% 80%, rgba(50, 200, 130, 0.04), transparent 40%);
    background-size: cover;
    z-index: -2;
}

@keyframes scanlines {
    0% {
        transform: translateY(0);
    }

    100% {
        transform: translateY(-1px);
    }
}

/* ------------------- */
/* 3. Typography       */
/* ------------------- */

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--color-text-primary);
    margin-bottom: 1rem;
}

h1 {
    font-size: clamp(3rem, 6vw, 4.5rem);
}

h2 {
    font-size: clamp(2rem, 5vw, 2.5rem);
}

h3 {
    font-size: clamp(1.5rem, 4vw, 1.75rem);
}

p {
    margin-bottom: var(--spacing-unit);
    color: var(--color-text-secondary);
}

a {
    color: var(--color-primary);
    text-decoration: none;
    transition: var(--transition-fast);
}

a:hover {
    color: #fff;
    text-shadow: 0 0 10px var(--color-primary);
}

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

.text-gradient {
    background: linear-gradient(90deg, var(--color-primary), var(--color-secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}


/* ------------------- */
/* 4. Layout           */
/* ------------------- */

.container,
.article-content-modern {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 calc(var(--spacing-unit) * 1.5);
}

.article-content-modern {
    max-width: var(--article-width);
}

.section {
    padding: calc(var(--spacing-unit) * 6) 0;
}

.grid {
    display: grid;
    gap: calc(var(--spacing-unit) * 2);
}

.grid-cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.grid-cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.grid-cols-4 {
    grid-template-columns: repeat(4, 1fr);
}

@media (max-width: 992px) {

    .grid-cols-3,
    .grid-cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .stories-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    .hero {
        padding-top: 100px;
    }

    .grid,
    .grid-cols-2,
    .grid-cols-3,
    .grid-cols-4,
    .stories-grid {
        grid-template-columns: 1fr;
    }

    .container,
    .article-content-modern {
        padding: 0 var(--spacing-unit);
    }

    .section {
        padding: calc(var(--spacing-unit) * 4) 0;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
        gap: 1rem;
    }
}


/* ------------------- */
/* 5. Components       */
/* ------------------- */

/* --- Navbar --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1020;
    background: linear-gradient(140deg, rgba(6, 18, 14, .24), rgba(14, 32, 28, .18));
    backdrop-filter: blur(26px) saturate(165%);
    -webkit-backdrop-filter: blur(26px) saturate(165%);
    border-bottom: 1px solid rgba(0, 217, 255, .32);
    box-shadow:
        0 16px 48px rgba(0, 0, 0, .32),
        inset 0 1px 0 rgba(255, 255, 255, .12),
        inset 0 0 0 1px rgba(255, 255, 255, .04);
    height: 80px;
    transition: var(--transition-fast);
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.75rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 100%;
    background: linear-gradient(135deg, rgba(255, 255, 255, .08), rgba(0, 217, 255, .06));
    border: 1px solid rgba(255, 255, 255, .2);
    border-radius: 20px;
    box-shadow:
        0 14px 36px rgba(0, 0, 0, .24),
        inset 0 1px 0 rgba(255, 255, 255, .16),
        inset 0 0 0 1px rgba(255, 255, 255, .05);
    backdrop-filter: blur(16px) saturate(150%);
    -webkit-backdrop-filter: blur(16px) saturate(150%);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: .75rem;
    text-decoration: none;
    color: #fff;
    font-weight: 700;
    font-size: 1.125rem;
    font-family: var(--font-display);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.nav-logo:hover {
    transform: translateY(-3px);
}

.nav-logo .logo-text {
    display: inline-flex;
    align-items: baseline;
    gap: 0.35rem;
    letter-spacing: 0.5px;
    position: relative;
    transition: all 0.3s ease;
}

.nav-logo .logo-juampi {
    color: #ffffff;
    text-transform: uppercase;
    font-weight: 800;
}

.nav-logo .logo-ia {
    color: var(--color-primary);
    text-transform: uppercase;
    font-weight: 800;
    text-shadow: 0 0 10px rgba(0, 217, 255, 0.6), 0 0 18px rgba(0, 217, 255, 0.4);
}

.nav-logo:hover .logo-ia {
    text-shadow: 0 0 14px rgba(0, 217, 255, 0.8), 0 0 26px rgba(147, 51, 234, 0.35);
}

.nav-logo img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    box-shadow: 0 0 20px rgba(0, 217, 255, .3);
    transition: all 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    animation: float-logo 6s ease-in-out infinite;
    position: relative;
}

.nav-logo:hover img {
    transform: rotate(360deg) scale(1.1);
    box-shadow:
        0 0 40px rgba(0, 217, 255, 0.6),
        0 0 60px rgba(147, 51, 234, 0.4),
        inset 0 0 20px rgba(0, 217, 255, 0.2);
    animation: none;
}

@keyframes float-logo {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
        box-shadow: 0 0 20px rgba(0, 217, 255, .3);
    }
    50% {
        transform: translateY(-5px) rotate(5deg);
        box-shadow: 0 0 30px rgba(0, 217, 255, .5);
    }
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-link {
    color: rgba(255, 255, 255, .8);
    text-decoration: none;
    font-weight: 500;
    padding: .5rem 1rem;
    border-radius: .5rem;
    transition: all .25s;
}

.nav-link:hover,
.nav-link.active {
    color: #fff;
    background: rgba(255, 255, 255, .1)
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 1.25rem;
    cursor: pointer;
    padding: .5rem;
    border-radius: .5rem;
    transition: transform 0.3s ease, background-color 0.25s ease;
}

.mobile-menu-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.mobile-menu-toggle:active {
    transform: scale(0.95);
}

.mobile-menu-toggle i {
    transition: transform 0.3s ease;
    display: inline-block;
}

.mobile-menu-toggle.active i {
    transform: rotate(90deg);
}

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: 120px;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 20% 50%, rgba(0, 217, 255, .1) 0, transparent 50%), radial-gradient(circle at 80% 20%, rgba(124, 58, 237, .1) 0, transparent 50%);
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

.hero-banner {
    margin-bottom: 2rem;
}

.hero-banner img {
    max-width: 100%;
    height: auto;
    border-radius: 1.5rem;
    box-shadow: 0 16px 64px rgba(0, 217, 255, .2);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: linear-gradient(135deg, #00d9ff 0, #7c3aed 50%, #f472b6 100%);
    color: #fff;
    padding: .5rem 1rem;
    border-radius: 9999px;
    font-size: .875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: linear-gradient(135deg, #00d9ff 0, #7c3aed 50%, #f472b6 100%);
    color: #fff;
    padding: .5rem 1rem;
    border-radius: 9999px;
    font-size: .875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.hero-title {
    font-size: clamp(3.5rem, 7vw, 5rem);
    font-weight: 800;
    font-family: var(--font-display);
    line-height: .9;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #d9dde3 0, #00d9ff 50%, #7c3aed 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.hero-subtitle {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
    color: rgba(255, 255, 255, .8);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    padding: .75rem 1.5rem;
    border-radius: .75rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all .25s;
    position: relative;
    overflow: hidden;
    font-family: var(--font-sans);
}

.btn-primary {
    background: linear-gradient(135deg, #00d9ff 0, #7c3aed 50%, #f472b6 100%);
    color: #fff;
    box-shadow: 0 0 20px rgba(0, 217, 255, .3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 40px rgba(0, 217, 255, .4);
}

.btn-secondary {
    background: rgba(255, 255, 255, .1);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, .2);
    color: #fff;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, .15);
    transform: translateY(-2px);
}

/* --- Cards (General Purpose) --- */
.card {
    background: rgba(16, 17, 19, 0.5);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: calc(var(--spacing-unit) * 2);
    transition: var(--transition-slow);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.card:hover {
    transform: translateY(-5px);
    border-color: var(--color-border-accent);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}

/* --- Section Styles --- */
.section {
    padding: calc(var(--spacing-unit) * 6) 0;
}

.section-title {
    text-align: center;
    font-size: clamp(2rem, 5vw, 3rem);
    margin-bottom: calc(var(--spacing-unit) * 3);
    background: linear-gradient(120deg, #001f3f 0%, #003d7a 25%, #0066cc 50%, #4da6ff 75%, #ffffff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    font-weight: 700;
    text-shadow: 0 0 30px rgba(0, 102, 204, 0.2);
    letter-spacing: -0.01em;
}

.section-subtitle {
    text-align: center;
    max-width: 600px;
    margin: 0 auto calc(var(--spacing-unit) * 4);
    font-size: 1.1rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    line-height: 1.6;
    background: linear-gradient(120deg, rgba(255, 255, 255, 0.9) 0%, rgba(0, 217, 255, 0.8) 50%, rgba(255, 255, 255, 0.7) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 0 20px rgba(0, 217, 255, 0.15);
}

/* --- Special Cards --- */
.glass-card {
    background: linear-gradient(135deg, rgba(16, 17, 19, 0.7), rgba(16, 17, 19, 0.3));
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: calc(var(--spacing-unit) * 2);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    transition: var(--transition-slow);
    cursor: pointer;
}

.glass-card:hover {
    transform: translateY(-8px);
    border-color: var(--color-border-accent);
    box-shadow: 0 20px 60px rgba(0, 229, 255, 0.1);
}

/* Small Buttons */
.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    transition: var(--transition-fast);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.article-title-modern {
    font-size: clamp(2.5rem, 6vw, 4rem);
    text-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
}

.article-subtitle-modern {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
}

.article-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-top: 2rem;
    color: var(--color-text-secondary);
}

.article-featured-image {
    width: 100%;
    border-radius: var(--radius-lg);
    margin-bottom: 3rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.article-section {
    margin-bottom: 4rem;
}

.article-section .section-title {
    font-size: 2rem;
    color: var(--color-primary);
    margin-bottom: 2rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--color-border);
}

.article-rich-text {
    display: grid;
    gap: 1rem;
    color: var(--color-text-primary);
    font-size: 1.05rem;
    line-height: 1.75;
}

.article-rich-text p {
    margin: 0 0 0.85rem;
}

.article-rich-text p:last-child {
    margin-bottom: 0;
}

.article-rich-text h2,
.article-rich-text h3,
.article-rich-text h4 {
    margin: 0.5rem 0 0.25rem;
    color: var(--color-primary);
    line-height: 1.3;
}

.article-rich-text h2 {
    font-size: clamp(1.35rem, 3.5vw, 1.75rem);
}

.article-rich-text h3 {
    font-size: clamp(1.15rem, 3vw, 1.3rem);
}

.article-rich-text h4 {
    font-size: clamp(1.05rem, 2.5vw, 1.1rem);
}

.article-rich-text ul,
.article-rich-text ol {
    padding-left: 1.25rem;
    margin: 0.25rem 0 0;
    display: grid;
    gap: 0.35rem;
}

.article-rich-text li {
    color: var(--color-text-primary);
}

.article-rich-text a {
    color: var(--color-accent);
    text-decoration: underline;
    text-decoration-thickness: 2px;
}

.article-rich-text blockquote {
    margin: 0;
    padding: 1rem 1.25rem;
    border-left: 4px solid var(--color-primary);
    background: rgba(255, 255, 255, 0.04);
    border-radius: var(--radius-md);
}

.article-rich-text img {
    max-width: 100%;
    border-radius: var(--radius-md);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.25);
}

.article-summary-card {
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.02), rgba(0, 217, 255, 0.06));
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    padding: 1.25rem 1.5rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.28);
}

.article-summary-card .article-rich-text {
    gap: 0.8rem;
    line-height: 1.7;
}

.article-rich-text .entrada {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.08), rgba(255, 255, 255, 0.02));
    border-left: 4px solid var(--color-primary);
    border-radius: var(--radius-md);
    padding: 1.25rem 1.5rem;
    color: var(--color-text-primary);
    font-size: clamp(1.05rem, 3vw, 1.35rem);
    line-height: 1.7;
    letter-spacing: -0.01em;
}

.article-rich-text .entrada strong {
    color: #e5e7eb;
    font-weight: 800;
}

.article-rich-text .cuerpo-noticia {
    display: grid;
    gap: 0.9rem;
}

.article-rich-text .cuerpo-noticia p {
    margin: 0;
    color: var(--color-text-primary);
    line-height: 1.75;
}

.article-rich-text .cita-destacada {
    margin: 0;
    padding: 1.25rem 1.5rem;
    background: rgba(255, 255, 255, 0.04);
    border-left: 4px solid var(--color-primary);
    border-radius: var(--radius-md);
    font-style: italic;
    font-weight: 700;
    color: #e5e7eb;
}

.article-rich-text .declaracion {
    margin: 0;
    padding: 1rem 1.25rem;
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid rgba(255, 255, 255, 0.35);
    border-radius: var(--radius-md);
    color: rgba(255, 255, 255, 0.92);
}

.article-rich-text .contexto {
    margin: 0.5rem 0 0;
    padding: 1.1rem 1.25rem 1.2rem;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-lg);
    background: linear-gradient(145deg, rgba(15, 23, 42, 0.65), rgba(15, 23, 42, 0.4));
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.28);
}

.article-rich-text .contexto h3 {
    margin: 0 0 0.4rem;
    font-size: clamp(1.05rem, 2.6vw, 1.25rem);
    color: #c7d2fe;
}

.article-rich-text .contexto p {
    margin: 0;
    line-height: 1.65;
    color: rgba(229, 231, 235, 0.95);
}

.article-text {
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Glass Cards for Articles */
.glass-card {
    background: linear-gradient(135deg, rgba(16, 17, 19, 0.5), rgba(16, 17, 19, 0.2));
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: calc(var(--spacing-unit) * 2);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

/* --- Story Cards (Migrated from inteligencia-positiva.html) --- */
.story-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    height: 100%;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    position: relative;
}

.story-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.1), rgba(124, 58, 237, 0.1));
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
    z-index: 0;
}

.story-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow:
        0 15px 40px -15px rgba(0, 217, 255, 0.4),
        0 5px 20px rgba(124, 58, 237, 0.2);
    border-color: var(--color-primary);
}

.story-card:hover::before {
    opacity: 1;
}

.story-card:active {
    transform: translateY(-4px) scale(0.98);
    transition: transform 0.1s ease;
}

.story-card > * {
    position: relative;
    z-index: 1;
}

.story-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.story-content {
    padding: 1.5rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.story-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: #fff;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.story-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #fff;
    line-height: 1.3;
}

.story-excerpt {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 1.5rem;
    line-height: 1.5;
    flex-grow: 1;
}

.story-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
}

/* --- Mini Cards (Positive Value & Common Uses) --- */
.mini-cards {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

/* Stories grid layout */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem;
}

.mini-card {
    padding: 1rem;
    border-radius: 0.75rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.mini-card h4 {
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.mini-card p {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.8);
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* --- Stories Grid (Responsive Layout: 3/2/1) --- */
.stories-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 2rem;
}

@media (max-width: 992px) {
    .stories-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.5rem;
    }
}

@media (max-width: 768px) {
    .stories-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
        /* Scroll snapping para navegación tipo Instagram */
        scroll-snap-type: y mandatory;
        overflow-y: auto;
        max-height: 100vh;
        padding-bottom: 2rem;
    }

    .story-card {
        scroll-snap-align: start;
        scroll-snap-stop: always;
        min-height: 85vh;
        margin-bottom: 1rem;
    }

    /* Mejorar la transición entre cards en móvil */
    .story-card:active {
        transform: scale(0.95);
    }
}

/* --- Concept Grid (for basicos-ia pages) --- */
.concept-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.concept-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    padding: 2rem;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.concept-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 157, 255, 0.2);
}

.concept-icon {
    font-size: 2.5rem;
    color: var(--color-primary);
    margin-bottom: 1rem;
}

.concept-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--color-primary);
    color: #0a0a0a;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}

/* --- Model Leaderboard Widget --- */
/* Model Grid - Editorial Clean Style */
.model-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.model-card {
    background: linear-gradient(135deg, rgba(16, 17, 19, 0.8), rgba(16, 17, 19, 0.5));
    border: 1px solid var(--color-border);
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3), 0 0 0 0 rgba(0, 217, 255, 0);
    text-decoration: none;
    color: var(--color-text-primary);
    position: relative;
    overflow: hidden;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
}

.model-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #00d9ff, #7c3aed, #00d9ff);
    background-size: 200% 100%;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.model-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 0 30px rgba(0, 217, 255, 0.4);
    border-color: rgba(0, 217, 255, 0.6);
    background: linear-gradient(135deg, rgba(16, 17, 19, 0.85), rgba(16, 17, 19, 0.6));
}

.model-card:hover::before {
    opacity: 1;
    animation: shimmer 2s linear infinite;
}

@keyframes shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

.model-card-header {
    display: flex;
    align-items: flex-start;
    gap: 0.85rem;
}

.model-header-content {
    flex: 1;
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.75rem;
}

.model-icon {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    display: grid;
    place-items: center;
    font-weight: 800;
    font-size: 0.9rem;
    letter-spacing: -0.02em;
    color: #0a0a0a;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.4), 0 0 15px rgba(0, 217, 255, 0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.model-card:hover .model-icon {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.5), 0 0 20px rgba(0, 217, 255, 0.4);
}

/* Model Icon Colors */
.logo-openai {
    background: linear-gradient(135deg, #00e5ff, #6affc7);
}

.logo-claude {
    background: linear-gradient(135deg, #8c62ff, #f5d0ff);
}

.logo-gemini {
    background: linear-gradient(135deg, #4da3ff, #82ffe9);
}

.logo-llama {
    background: linear-gradient(135deg, #ff9a62, #ffd27f);
}

.logo-mistral {
    background: linear-gradient(135deg, #ff6b8a, #ffd3a5);
}

.logo-grok {
    background: linear-gradient(135deg, #ff9f4a, #ffd35a);
}

/* Model Card Content */
.model-name {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
    color: var(--color-text-primary);
    line-height: 1.3;
}

.model-badge {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.25rem 0.6rem;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    white-space: nowrap;
}

.badge-top {
    background: rgba(0, 217, 255, 0.15);
    color: #00d9ff;
    border: 1px solid rgba(0, 217, 255, 0.4);
    box-shadow: 0 0 10px rgba(0, 217, 255, 0.2);
}

.badge-new {
    background: rgba(52, 211, 153, 0.15);
    color: #34d399;
    border: 1px solid rgba(52, 211, 153, 0.4);
    box-shadow: 0 0 10px rgba(52, 211, 153, 0.2);
}

.badge-open {
    background: rgba(251, 191, 36, 0.15);
    color: #fbbf24;
    border: 1px solid rgba(251, 191, 36, 0.4);
    box-shadow: 0 0 10px rgba(251, 191, 36, 0.2);
}

.model-tagline {
    margin: 0;
    font-size: 0.95rem;
    color: var(--color-text-secondary);
    line-height: 1.5;
}

.model-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: 999px;
    background: rgba(0, 217, 255, 0.08);
    border: 1px solid rgba(0, 217, 255, 0.2);
    color: rgba(0, 217, 255, 0.9);
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.pill:hover {
    background: rgba(0, 217, 255, 0.15);
    border-color: rgba(0, 217, 255, 0.4);
}

.pill i {
    font-size: 0.8rem;
    opacity: 0.7;
}

.model-card-footer {
    margin-top: auto;
    padding-top: 0.5rem;
}

.btn-model-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.25rem;
    background: linear-gradient(135deg, #00d9ff, #00b8d9);
    color: #0a0a0a;
    border-radius: 8px;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 700;
    transition: all 0.2s ease;
    border: none;
    box-shadow: 0 2px 8px rgba(0, 217, 255, 0.4), 0 0 20px rgba(0, 217, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.btn-model-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.btn-model-link:hover {
    background: linear-gradient(135deg, #00b8d9, #0099b8);
    transform: translateX(2px);
    box-shadow: 0 4px 12px rgba(0, 217, 255, 0.5);
}

.btn-model-link:hover::before {
    left: 100%;
}

.btn-model-link i {
    font-size: 0.8rem;
    transition: transform 0.2s ease;
}

.btn-model-link:hover i {
    transform: translateX(2px);
}

/* Model Cards Responsive */
@media (max-width: 768px) {
    .model-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }

    .model-card {
        padding: 1.25rem;
    }

    .model-name {
        font-size: 1.05rem;
    }

    .model-tagline {
        font-size: 0.92rem;
    }

    .pill {
        font-size: 0.82rem;
        padding: 0.35rem 0.65rem;
    }
}

@media (max-width: 640px) {
    .model-grid {
        gap: 1rem;
    }

    .model-card {
        padding: 1.15rem;
        gap: 0.9rem;
    }

    .model-icon {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }

    .model-name {
        font-size: 1rem;
    }

    .model-badge {
        font-size: 0.7rem;
        padding: 0.2rem 0.5rem;
    }

    .model-tagline {
        font-size: 0.88rem;
    }

    .pill {
        font-size: 0.78rem;
        padding: 0.3rem 0.6rem;
        gap: 0.35rem;
    }

    .btn-model-link {
        padding: 0.6rem 1.1rem;
        font-size: 0.85rem;
    }
}

/* --- Compact model logo band (index) --- */
.model-logo-band {
    display: grid;
    gap: 1.25rem;
    padding: 1.75rem;
    border-radius: 1.25rem;
    background: radial-gradient(circle at 20% 20%, rgba(80, 255, 180, 0.1), transparent 30%),
        radial-gradient(circle at 80% 15%, rgba(0, 217, 255, 0.07), transparent 28%),
        linear-gradient(135deg, rgba(16, 32, 24, 0.92), rgba(10, 16, 12, 0.9));
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.model-logo-band .band-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.model-logo-band .band-title {
    margin: 0;
    font-size: clamp(1.3rem, 3vw, 1.6rem);
}

.model-logo-band .band-subtitle {
    margin: 0;
    color: rgba(255, 255, 255, 0.72);
}

.model-logo-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.9rem;
}

.model-logo-tile {
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 0.9rem;
    padding: 0.9rem;
    background: rgba(255, 255, 255, 0.03);
    display: flex;
    align-items: center;
    gap: 0.65rem;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08), 0 12px 30px rgba(0, 0, 0, 0.35);
}

.model-logo-tile span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 14px;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: #0a0a0a;
}

.model-logo-tile strong {
    display: block;
    font-size: 0.95rem;
    color: #f5f9f7;
}

.model-logo-tile small {
    display: block;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0.2rem;
}

@media (max-width: 900px) {
    .model-logo-band {
        padding: 1.5rem;
    }

    .model-logo-row {
        grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
        gap: 0.75rem;
    }

    .model-logo-tile {
        padding: 0.75rem;
    }

    .model-logo-tile span {
        width: 44px;
        height: 44px;
        border-radius: 12px;
        font-size: 0.95rem;
    }

    .model-logo-tile strong {
        font-size: 0.92rem;
        line-height: 1.2;
    }

    .model-logo-tile small {
        font-size: 0.82rem;
    }
}

@media (max-width: 640px) {
    .model-logo-band {
        padding: 1.15rem;
        gap: 1rem;
    }

    .model-logo-band .band-header {
        align-items: flex-start;
        gap: 0.4rem 0.6rem;
    }

    .model-logo-row {
        grid-template-columns: 1fr;
        gap: 0.65rem;
    }

    .model-logo-tile {
        padding: 0.7rem;
        gap: 0.55rem;
    }

    .model-logo-tile span {
        width: 40px;
        height: 40px;
        border-radius: 11px;
        font-size: 0.88rem;
    }

    .model-logo-tile strong {
        font-size: 0.88rem;
    }

    .model-logo-tile small {
        font-size: 0.78rem;
    }
}

/* --- Timeline Image --- */
.timeline-image {
    width: 100%;
    border-radius: 0.75rem;
    margin-bottom: 1rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* --- Glass Tag --- */
.glass-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    font-size: 0.875rem;
    font-weight: 600;
}

.btn-link {
    color: var(--color-primary);
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    transition: color 0.3s ease;
}

.btn-link:hover {
    color: #fff;
}

.loading-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* --- Neo-Cyberpunk Timeline --- */
.timeline-section {
    position: relative;
    padding: 4rem 0;
}

.timeline-modern {
    position: relative;
    max-width: 1000px;
    margin: 0 auto;
}

/* Central Line */
.timeline-modern::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 4px;
    background: linear-gradient(to bottom, transparent, var(--color-primary), var(--color-secondary), transparent);
    transform: translateX(-50%);
    box-shadow: 0 0 15px var(--color-primary);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    margin-bottom: 4rem;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

/* Dot on the line */
.timeline-marker {
    position: absolute;
    left: 50%;
    width: 20px;
    height: 20px;
    background: var(--color-background);
    border: 3px solid var(--color-accent);
    border-radius: 50%;
    transform: translateX(-50%);
    z-index: 2;
    box-shadow: 0 0 15px var(--color-accent);
    transition: all 0.3s ease;
}

.timeline-item:hover .timeline-marker {
    background: var(--color-accent);
    box-shadow: 0 0 25px var(--color-accent);
    transform: translateX(-50%) scale(1.2);
}

/* Content Card */
.timeline-content {
    width: 45%;
    position: relative;
    background: rgba(16, 17, 19, 0.6);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all 0.3s ease;
}

.timeline-content:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.15);
}

/* Alternating Layout */
.timeline-item:nth-child(odd) {
    flex-direction: row;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-item:nth-child(odd) .timeline-content {
    margin-right: auto;
    text-align: right;
}

.timeline-item:nth-child(even) .timeline-content {
    margin-left: auto;
    text-align: left;
}

/* Year/Date Styling */
.timeline-date {
    display: inline-block;
    font-family: var(--font-mono);
    font-weight: 700;
    font-size: 1.5rem;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
    text-shadow: 0 0 10px rgba(0, 217, 255, 0.5);
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
    .timeline-modern::before {
        left: 20px;
    }

    .timeline-item {
        flex-direction: column !important;
        align-items: flex-start;
        margin-left: 0;
    }

    .timeline-marker {
        left: 20px;
        transform: translateX(-50%);
    }

    .timeline-item:hover .timeline-marker {
        transform: translateX(-50%) scale(1.2);
    }

    .timeline-content {
        width: calc(100% - 50px);
        margin-left: 50px !important;
        margin-right: 0 !important;
        text-align: left !important;
    }
}

/* --- Tech Grid --- */
.tech-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
}

.tech-card {
    padding: 1.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 1rem;
    transition: all 0.3s ease;
}

.tech-card:hover {
    transform: translateY(-5px);
    border-color: var(--color-primary);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.1);
}

.tech-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--color-primary);
}


/* --- Footer --- */
.footer {
    background: var(--color-surface);
    padding: calc(var(--spacing-unit) * 4) 0;
    border-top: 1px solid var(--color-border);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: calc(var(--spacing-unit) * 3);
    margin-bottom: 3rem;
}

.footer-brand .footer-logo {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.footer-column h4 {
    margin-bottom: 1.5rem;
    color: var(--color-text-primary);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: var(--color-text-secondary);
}

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

.footer-bottom {
    border-top: 1px solid var(--color-border);
    padding-top: 2rem;
    text-align: center;
    color: var(--color-text-secondary);
    font-size: 0.9rem;
}


/* ------------------- */
/* 8. Mobile Specifics */
/* ------------------- */

@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: block;
        z-index: 999;
    }

    .navbar .nav-menu {
        position: fixed;
        top: 80px;
        left: auto;
        right: 0;
        bottom: 0;
        width: 100vw;
        background: rgba(10, 10, 11, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
        gap: 1.5rem;
        padding: 2rem;
        transform: translateX(100%);
        transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
        will-change: transform;
        z-index: 1000;
        list-style: none;
        margin: 0;
    }

    .navbar .nav-menu.active {
        transform: translateX(0);
    }

    /* Overlay/Backdrop */
    .nav-overlay {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(4px);
        -webkit-backdrop-filter: blur(4px);
        z-index: 999;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.35s ease, visibility 0.35s ease;
    }

    .nav-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    body.menu-open {
        overflow: hidden;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-brand {
        margin-bottom: 2rem;
    }

    .article-header-modern {
        padding: calc(var(--spacing-unit) * 6) 0;
    }
}


/* ------------------- */
/* 9. Animations       */
/* ------------------- */
.animate-fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Fix for article header overlap with fixed navbar */
.article-header-modern {
    padding-top: 120px !important;
    padding-bottom: 4rem;
}

/* --- Hybrid Contact Layout --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.contact-left {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-right {
    height: 100%;
    min-height: 600px;
}

@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-right {
        min-height: 500px;
    }
}

/* --- Chat Widget --- */
.chat-container {
    background: rgba(16, 17, 19, 0.6);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.chat-header {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #00d9ff, #7c3aed);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.5);
}

.chat-messages {
    flex-grow: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    scroll-behavior: smooth;
}

.message {
    max-width: 80%;
    padding: 1rem;
    border-radius: 1rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
}

.message.bot {
    background: rgba(255, 255, 255, 0.05);
    border-bottom-left-radius: 0;
    align-self: flex-start;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.message.user {
    background: linear-gradient(135deg, #00d9ff, #7c3aed);
    border-bottom-right-radius: 0;
    align-self: flex-end;
    color: white;
    box-shadow: 0 5px 15px rgba(0, 217, 255, 0.2);
}

.chat-input-area {
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--color-border);
    display: flex;
    gap: 1rem;
}

.chat-input {
    flex-grow: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    padding: 0.75rem 1.5rem;
    color: white;
    outline: none;
    transition: all 0.3s ease;
}

.chat-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.1);
}

.chat-send-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--color-primary);
    border: none;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-send-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--color-primary);
}

/* Bot and User message styles (used by chat.js) */
.bot-message {
    background: rgba(255, 255, 255, 0.05);
    border-bottom-left-radius: 0;
    align-self: flex-start;
    border: 1px solid rgba(255, 255, 255, 0.1);
    max-width: 80%;
    padding: 1rem;
    border-radius: 1rem;
    animation: fadeIn 0.3s ease;
}

.user-message {
    background: linear-gradient(135deg, #00d9ff, #7c3aed);
    border-bottom-right-radius: 0;
    align-self: flex-end;
    color: white;
    box-shadow: 0 5px 15px rgba(0, 217, 255, 0.2);
    max-width: 80%;
    padding: 1rem;
    border-radius: 1rem;
    animation: fadeIn 0.3s ease;
}

.message-content {
    line-height: 1.6;
    font-size: 0.95rem;
}

.message-time {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.5);
    margin-top: 0.5rem;
    text-align: right;
}

.typing-indicator {
    max-width: 80px !important;
    padding: 0.75rem 1.25rem !important;
}

.typing-dots {
    display: flex;
    gap: 0.4rem;
    align-items: center;
    justify-content: center;
}

.typing-dots span {
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 50%;
    animation: typingDot 1.4s infinite ease-in-out;
}

.typing-dots span:nth-child(1) {
    animation-delay: 0s;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingDot {
    0%, 60%, 100% {
        transform: translateY(0);
        opacity: 0.6;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

/* ------------------- */
/* 9. Animations       */
/* ------------------- */
.animate-fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.animate-fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Fix for article header overlap with fixed navbar */
.article-header-modern {
    padding-top: 120px !important;
    padding-bottom: 4rem;
}

/* --- Hybrid Contact Layout --- */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: start;
}

.contact-left {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.contact-right {
    height: 100%;
    min-height: 600px;
}

@media (max-width: 992px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }

    .contact-right {
        min-height: 500px;
    }
}

/* --- Chat Widget --- */
.chat-container {
    background: rgba(16, 17, 19, 0.6);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.chat-header {
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    gap: 1rem;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #00d9ff, #7c3aed);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.5);
}

.chat-messages {
    flex-grow: 1;
    padding: 1.5rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    scroll-behavior: smooth;
}

.message {
    max-width: 80%;
    padding: 1rem;
    border-radius: 1rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
}

.message.bot {
    background: rgba(255, 255, 255, 0.05);
    border-bottom-left-radius: 0;
    align-self: flex-start;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.message.user {
    background: linear-gradient(135deg, #00d9ff, #7c3aed);
    border-bottom-right-radius: 0;
    align-self: flex-end;
    color: white;
    box-shadow: 0 5px 15px rgba(0, 217, 255, 0.2);
}

.chat-input-area {
    padding: 1.5rem;
    background: rgba(0, 0, 0, 0.2);
    border-top: 1px solid var(--color-border);
    display: flex;
    gap: 1rem;
}

.chat-input {
    flex-grow: 1;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--color-border);
    border-radius: 999px;
    padding: 0.75rem 1.5rem;
    color: white;
    outline: none;
    transition: all 0.3s ease;
}

.chat-input:focus {
    border-color: var(--color-primary);
    box-shadow: 0 0 15px rgba(0, 217, 255, 0.1);
}

.chat-send-btn {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--color-primary);
    border: none;
    color: #000;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-send-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 0 15px var(--color-primary);
}

/* --- Donation Card --- */
.donation-card {
    transition: transform 0.3s ease;
}

.donation-card:hover {
    transform: translateY(-5px);
}

/* ------------------- */
/* 10. Home Page Redesign */
/* ------------------- */

.hero-super-title {
    font-size: clamp(1.9rem, 4.6vw, 3.8rem);
    line-height: 1;
    margin-bottom: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.05em;
    font-family: var(--font-display);
    color: #ffffff;
}

.hero-super-title .gradient-white {
    background: linear-gradient(to right, #ffffff, #e5e7eb, #9ca3af);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    color: transparent;
    display: inline-block;
}

.hero-super-title .neon-blue {
    color: #00d9ff;
    text-shadow: 0 0 20px rgba(0, 217, 255, 0.6), 0 0 40px rgba(0, 217, 255, 0.4);
    font-style: italic;
    font-family: var(--font-mono);
    display: inline-block;
}

/* Clase reutilizable para títulos cinematográficos */
.cinematic-title {
    font-size: clamp(2rem, 6vw, 4rem);
    line-height: 1.1;
    margin-bottom: 1.5rem;
    background: linear-gradient(120deg, #001f3f 0%, #003d7a 25%, #0066cc 50%, #4da6ff 75%, #ffffff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 0 40px rgba(0, 102, 204, 0.3);
    font-weight: 800;
    letter-spacing: -0.02em;
    font-family: var(--font-display);
}

.highlight-gradient {
    background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-secondary) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    position: relative;
    display: inline-block;
}

/* =========================================
   CINEMATIC REVEAL - Estilo Agencia (Revelación Cinematográfica)
   ========================================= */
.reveal-container {
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 1.2;
    text-align: center;
}

.line-wrapper {
    overflow: hidden;
    display: block;
}

.line-text {
    display: block;
    transform: translateY(100%);
    animation: reveal-text 1.2s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.line-1 {
    animation-delay: 0.2s;
    background: linear-gradient(to right, #fff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.line-2 {
    animation-delay: 0.4s;
    color: #818cf8;
}

@keyframes reveal-text {
    from {
        transform: translateY(110%) rotateX(10deg);
        opacity: 0;
    }
    to {
        transform: translateY(0) rotateX(0deg);
        opacity: 1;
    }
}

/* MEDIA QUERIES PARA MÓVIL */
@media (max-width: 768px) {
    .reveal-container {
        font-size: 2.5rem;
    }
}

/* Feature Cards */
.feature-card {
    --feature-tilt: 1.25deg;
    --feature-glow: 0.22;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, rgba(16, 17, 19, 0.7), rgba(16, 17, 19, 0.4));
    background-size: 140% 140%;
    background-position: 50% 50%;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: 2rem;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: all 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    transform: perspective(1000px) rotateX(0deg) rotateY(0deg);
}

.feature-card:hover {
    transform: perspective(1000px) rotateX(var(--feature-tilt)) rotateY(calc(var(--feature-tilt) * -1.4)) translateY(-12px) scale(1.02);
    background-position: 60% 40%;
    border-color: var(--color-border-accent);
    box-shadow:
        0 25px 70px rgba(0, 217, 255, var(--feature-glow)),
        0 0 40px rgba(0, 217, 255, calc(var(--feature-glow) - 0.05)),
        inset 0 0 60px rgba(0, 217, 255, calc(var(--feature-glow) - 0.1));
}

@keyframes pulse-glow {
    0%, 100% {
        box-shadow:
            0 25px 70px rgba(0, 217, 255, 0.25),
            0 0 40px rgba(0, 217, 255, 0.2),
            inset 0 0 60px rgba(0, 217, 255, 0.05);
    }
    50% {
        box-shadow:
            0 25px 70px rgba(0, 217, 255, 0.35),
            0 0 60px rgba(0, 217, 255, 0.3),
            inset 0 0 80px rgba(0, 217, 255, 0.1);
    }
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0; right: 0;
    width: 150px; height: 150px;
    background: radial-gradient(circle, rgba(0, 217, 255, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    transform: translate(30%, -30%);
    transition: transform 0.8s cubic-bezier(0.68, -0.55, 0.265, 1.55), opacity 0.6s ease, filter 0.6s ease;
    opacity: 0.35;
    pointer-events: none;
}

.feature-card:hover::before {
    transform: translate(18%, -18%) scale(1.4);
    opacity: 0.65;
    filter: blur(1px);
}

.feature-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius-lg);
    padding: 2px;
    background: linear-gradient(135deg, #00d9ff, #9333ea, #f472b6);
    background-size: 200% 200%;
    background-position: 40% 60%;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s ease, background-position 0.9s ease;
    pointer-events: none;
}

.feature-card:hover::after {
    opacity: 0.5;
    background-position: 80% 30%;
}

.feature-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    background: rgba(255,255,255,0.05);
    width: 60px; height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    border: 1px solid rgba(255,255,255,0.1);
    color: var(--color-primary);
    box-shadow: 0 0 20px rgba(0, 217, 255, 0.2);
}

/* Stats Row */
.stats-row {
    display: flex;
    gap: 3rem;
    justify-content: center;
    margin-top: 3rem;
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    color: #fff;
    display: block;
    font-family: var(--font-mono);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--color-text-secondary);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Mobile Adjustments for Home */
@media (max-width: 768px) {
    .hero-super-title {
        font-size: 2.5rem;
        line-height: 1.1;
        letter-spacing: -0.03em;
    }

    .hero-super-title .gradient-white,
    .hero-super-title .neon-blue {
        display: block;
        word-break: break-word;
    }

    .hero-super-title .neon-blue {
        text-shadow: 0 0 15px rgba(0, 217, 255, 0.5), 0 0 30px rgba(0, 217, 255, 0.3);
    }

    .highlight-gradient {
        display: inline; /* Allow wrapping */
        white-space: normal;
    }
    
    .stats-row {
        gap: 1.5rem;
        flex-direction: row;
        justify-content: space-around;
    }
    
    .stat-item {
        flex: 1 1 auto;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    /* Fix for asymmetric grid on mobile */
    .grid-cols-2 {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }
    
    /* Remove rotation on mobile for cleaner look */
    .glass-card[style*="rotate"] {
        transform: rotate(0deg) !important;
        margin-top: 1rem;
    }

    .feature-card {
        padding: 1.5rem;
    }
}

/* Animations */
.fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
    opacity: 0;
    transform: translateY(20px);
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Voice button pulse animation */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}

/* ------------------- */
/* 11. Preloader       */
/* ------------------- */

#preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--color-background);
    z-index: 9999;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 5px solid var(--color-border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 1s ease-in-out infinite;
}

/* ------------------- */
/* 12. Modal           */
/* ------------------- */

.modal {
    display: none;
    position: fixed;
    z-index: 1050;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
}

.modal-content {
    background-color: var(--color-surface);
    margin: 6% auto;
    padding: 3rem;
    border: 1px solid var(--color-border);
    width: 90%;
    max-width: 900px;
    border-radius: var(--radius-lg);
    position: relative;
    box-shadow: 0 0 50px rgba(0, 217, 255, 0.2);
}

.close-button {
    color: var(--color-text-secondary);
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
}

.close-button:hover,
.close-button:focus {
    color: var(--color-primary);
    text-decoration: none;
    cursor: pointer;
}

/* Navigation arrows for modal */
.modal-nav-arrow {
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    width: 50px;
    height: 50px;
    background: rgba(0, 217, 255, 0.1);
    border: 1px solid rgba(0, 217, 255, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1051;
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
}

.modal[style*="display: block"] .modal-nav-arrow {
    opacity: 0.4;
    pointer-events: auto;
}

.modal-nav-arrow:hover {
    opacity: 1 !important;
    background: rgba(0, 217, 255, 0.2);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 0 20px rgba(0, 217, 255, 0.4);
}

.modal-nav-arrow.prev {
    left: 20px;
}

.modal-nav-arrow.next {
    right: 20px;
}

.modal-nav-arrow i {
    color: var(--color-primary);
    font-size: 1.25rem;
}

/* Swipe hint animation */
@keyframes swipeHint {
    0%, 100% {
        transform: translateX(0);
    }
    50% {
        transform: translateX(5px);
    }
}

.modal-nav-arrow.hint {
    animation: swipeHint 2s ease-in-out infinite;
}

/* Hide arrows on mobile (swipe is enough) */
@media (max-width: 768px) {
    .modal-nav-arrow {
        display: none;
    }
}

.article-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.article-date {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    color: var(--color-text-secondary);
    font-size: 0.95rem;
}

.article-hero {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--color-border);
    box-shadow: 0 15px 45px rgba(0, 0, 0, 0.35);
    margin: 1.25rem 0 1.5rem;
}

.article-lede {
    font-size: 1.05rem;
    color: var(--color-text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.article-insights {
    display: grid;
    gap: 2rem;
    grid-template-columns: 1fr;
    margin-top: 3rem;
}

.insight-card {
    position: relative;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.02));
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 1.25rem;
    padding: 2.5rem;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.insight-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, transparent, var(--color-primary), transparent);
    opacity: 0.5;
}

.insight-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.2);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(0, 217, 255, 0.1);
}

/* Impacto Positivo - Verde/Emerald theme */
.insight-card:first-child::before {
    background: linear-gradient(90deg, transparent, #10b981, #34d399, transparent);
}

.insight-card:first-child:hover {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(16, 185, 129, 0.15);
}

/* Cómo Aplicarlo - Azul/Blue theme */
.insight-card:last-child::before {
    background: linear-gradient(90deg, transparent, #3b82f6, #60a5fa, transparent);
}

.insight-card:last-child:hover {
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4), 0 0 40px rgba(59, 130, 246, 0.15);
}

.insight-header {
    display: flex;
    align-items: flex-start;
    gap: 1.25rem;
}

.insight-icon {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    display: grid;
    place-items: center;
    color: #0a0a0a;
    font-size: 1.5rem;
    box-shadow: 0 0 30px rgba(0, 217, 255, 0.25);
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.insight-card:hover .insight-icon {
    transform: scale(1.1);
    box-shadow: 0 0 40px rgba(0, 217, 255, 0.4);
}

.insight-eyebrow {
    display: block;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--color-text-secondary);
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.insight-header h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin: 0;
    color: var(--color-text-primary);
}

.insight-text {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.8;
    font-size: 1.05rem;
}

/* Article Content Styles (contenidoCompleto) */
.article-body {
    margin: 2rem 0;
    color: rgba(255, 255, 255, 0.95);
}

.article-paragraph {
    font-size: 1.125rem;
    line-height: 1.9;
    margin: 1.25rem 0;
    color: rgba(255, 255, 255, 0.92);
}

.article-subtitle {
    font-size: 1.75rem;
    font-weight: 700;
    margin: 2.5rem 0 1.25rem 0;
    color: var(--color-primary);
    line-height: 1.3;
}

.article-section-header {
    font-size: 1.4rem;
    font-weight: 600;
    margin: 2rem 0 1rem 0;
    color: rgba(255, 255, 255, 0.95);
    line-height: 1.4;
}

/* Responsive typography for mobile */
@media (max-width: 768px) {
    .article-paragraph {
        font-size: 1rem;
        line-height: 1.75;
        margin: 1rem 0;
    }

    .article-subtitle {
        font-size: 1.5rem;
        margin: 2rem 0 1rem 0;
    }

    .article-section-header {
        font-size: 1.25rem;
        margin: 1.5rem 0 0.75rem 0;
    }

    .insight-text {
        font-size: 0.95rem;
        line-height: 1.7;
    }

    .insight-text ul {
        padding-left: 1.25rem;
    }

    .insight-text li {
        margin: 0.5rem 0;
    }

    .insight-text h4 {
        font-size: 1.15rem;
        margin: 1.25rem 0 0.5rem 0;
    }

    .donation-cta h3 {
        font-size: 1.5rem !important;
    }

    .donation-cta p {
        font-size: 1rem !important;
    }

    .donation-cta a {
        font-size: 1rem !important;
        padding: 0.875rem 1.5rem !important;
    }

    /* Donation banner top - mobile */
    .donation-banner-top {
        flex-direction: column !important;
        text-align: center !important;
        padding: 1rem !important;
    }

    .donation-banner-top > div:first-child {
        flex-direction: column !important;
        text-align: center !important;
    }

    .donation-banner-top a {
        width: 100% !important;
        justify-content: center !important;
        padding: 0.7rem 1.25rem !important;
        font-size: 0.85rem !important;
    }

    .donation-banner-top p {
        font-size: 0.85rem !important;
    }

    .donation-banner-top p:last-child {
        font-size: 0.75rem !important;
    }
}

.insight-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
    display: grid;
    gap: 0.5rem;
}

.insight-list li {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.5rem;
    align-items: start;
    color: var(--color-text-secondary);
    line-height: 1.5;
}

.insight-list i {
    color: var(--color-primary);
    margin-top: 0.1rem;
}

/* Action Steps List - For "Cómo Aplicarlo" section */
.action-steps {
    list-style: none;
    padding: 0;
    margin: 1rem 0 0;
    counter-reset: step-counter;
}

.action-steps li {
    counter-increment: step-counter;
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.25rem;
    padding-left: 0;
}

.action-steps li::before {
    content: counter(step-counter);
    background: linear-gradient(135deg, #3b82f6, #60a5fa);
    color: #0a0a0a;
    font-weight: 800;
    font-size: 1rem;
    min-width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
}

.action-steps li strong {
    color: #60a5fa;
    font-weight: 600;
}

/* Call to Action in insights */
.insight-cta {
    margin-top: 1rem;
    padding: 1rem 1.5rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(96, 165, 250, 0.05));
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.insight-cta i {
    font-size: 1.25rem;
    color: #60a5fa;
}

.insight-cta p {
    margin: 0;
    color: rgba(255, 255, 255, 0.95);
    font-weight: 500;
    font-size: 0.95rem;
}

@media (min-width: 900px) {
    .article-insights {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .modal-content {
        padding: 1.5rem;
        width: 95%;
        margin: 3% auto;
    }

    .insight-card {
        padding: 1.25rem;
    }
}

/* ------------------- */
/* 13. Dynamic Article Components */
/* ------------------- */

/* Article Sections with Numbered Headings */
.article-section {
    margin: 2.5rem 0;
}

.article-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--color-text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.section-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 700;
    color: #0a0a0a;
    flex-shrink: 0;
}

.article-text {
    font-size: 1.05rem;
    line-height: 1.8;
    color: var(--color-text-secondary);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.25rem;
    margin: 2rem 0;
}

.stat-card {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.05), rgba(124, 58, 237, 0.05));
    border: 1px solid rgba(0, 217, 255, 0.2);
    border-radius: 1rem;
    padding: 1.5rem;
    text-align: center;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 217, 255, 0.15);
    border-color: var(--color-primary);
}

.stat-value {
    font-size: 2.5rem;
    font-weight: 800;
    font-family: var(--font-mono);
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 0.5rem;
    line-height: 1.2;
}

.stat-context {
    font-size: 0.85rem;
    color: var(--color-text-secondary);
    line-height: 1.5;
    min-height: 2.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Pull Quotes */
.pull-quote {
    margin: 3rem 0;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.02);
    border-left: 4px solid var(--color-primary);
    border-radius: 0 1rem 1rem 0;
    position: relative;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.pull-quote i {
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    font-size: 2rem;
    color: var(--color-primary);
    opacity: 0.3;
}

.pull-quote p {
    font-size: 1.25rem;
    font-style: italic;
    line-height: 1.6;
    color: var(--color-text-primary);
    margin: 0 0 0 2.5rem;
    font-weight: 500;
}

/* Juampi IA Inline Insights */
.juampi-insight-inline {
    margin: 2rem 0;
    padding: 1.5rem;
    background: linear-gradient(135deg, rgba(251, 191, 36, 0.1), rgba(245, 158, 11, 0.05));
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 1rem;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.juampi-insight-inline .insight-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    color: #fbbf24;
}

.juampi-insight-inline .insight-header i {
    font-size: 1.25rem;
}

.juampi-insight-inline .insight-header strong {
    font-size: 1rem;
    font-weight: 700;
}

.juampi-insight-inline p {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.6;
    margin: 0;
    font-size: 1rem;
}

/* Social Actions */
.article-social-block {
    margin-top: 3rem;
    padding-top: 1rem;
}

.social-actions {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
    padding: 1.5rem;
    border: 1px solid var(--color-border);
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
    box-shadow: 0 14px 40px rgba(0, 0, 0, 0.08);
}

.social-actions__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.social-question {
    margin: 0;
    color: var(--color-text-primary);
    font-size: 1.05rem;
    font-weight: 600;
}

.social-like-group {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.social-like-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.65rem 1.1rem;
    border-radius: 12px;
    border: 1px solid var(--color-primary);
    background: transparent;
    color: var(--color-primary);
    font-weight: 700;
    font-size: 0.98rem;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, color 0.18s ease;
    min-width: 140px;
    justify-content: center;
}

.social-like-label {
    font-weight: 700;
    font-size: 0.98rem;
    color: inherit;
}

.social-like-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 26px rgba(0, 0, 0, 0.12);
    background: color-mix(in srgb, var(--color-primary) 10%, transparent);
}

.social-like-button:active {
    transform: scale(0.97);
}

.social-like-button.is-active {
    background: var(--color-primary);
    color: #ffffff;
    box-shadow: 0 12px 30px color-mix(in srgb, var(--color-primary) 28%, transparent);
}

.social-like-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 26px;
    padding: 0.15rem 0.6rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.18);
    font-size: 0.9rem;
    font-weight: 700;
}

.social-like-button.is-active .social-like-count {
    background: rgba(255, 255, 255, 0.18);
    border-color: rgba(255, 255, 255, 0.38);
}

.social-share-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.65rem;
    flex-wrap: wrap;
    padding-top: 0.25rem;
}

.social-share-button {
    width: 46px;
    height: 46px;
    border-radius: 999px;
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(255, 255, 255, 0.08);
    color: var(--color-text-primary);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.15rem;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, color 0.18s ease;
}

.social-share-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.12);
    background: rgba(255, 255, 255, 0.14);
}

.social-share-button:active {
    transform: scale(0.97);
}

.social-share-button.whatsapp { color: #25d366; border-color: rgba(37, 211, 102, 0.25); }
.social-share-button.twitter { color: #0f1419; border-color: rgba(15, 20, 25, 0.2); }
.social-share-button.linkedin { color: #0a66c2; border-color: rgba(10, 102, 194, 0.25); }
.social-share-button.instagram { color: #e1306c; border-color: rgba(225, 48, 108, 0.25); }
.social-share-button.email { color: var(--color-primary); border-color: color-mix(in srgb, var(--color-primary) 35%, transparent); }

.social-share-button.whatsapp:hover { background: rgba(37, 211, 102, 0.12); box-shadow: 0 12px 26px rgba(37, 211, 102, 0.25); }
.social-share-button.twitter:hover { background: rgba(15, 20, 25, 0.08); box-shadow: 0 12px 26px rgba(15, 20, 25, 0.2); }
.social-share-button.linkedin:hover { background: rgba(10, 102, 194, 0.1); box-shadow: 0 12px 26px rgba(10, 102, 194, 0.25); }
.social-share-button.instagram:hover { background: rgba(225, 48, 108, 0.12); box-shadow: 0 12px 26px rgba(225, 48, 108, 0.25); }
.social-share-button.email:hover { background: color-mix(in srgb, var(--color-primary) 15%, transparent); box-shadow: 0 12px 26px color-mix(in srgb, var(--color-primary) 25%, transparent); }

.social-share-button:focus-visible,
.social-like-button:focus-visible {
    outline: 2px solid var(--color-accent);
    outline-offset: 3px;
}

.social-feedback-thanks,
.copy-success {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    justify-content: center;
    color: var(--color-primary);
    font-weight: 600;
    animation: fadeIn 0.3s ease;
    margin: 0;
}

.copy-success {
    margin-top: 0.35rem;
}

@media (max-width: 768px) {
    .social-actions__header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .social-like-group {
        width: 100%;
        justify-content: center;
    }

    .social-actions {
        padding: 1.25rem;
    }

    .social-share-row {
        width: 100%;
        gap: 0.85rem;
    }
}

@media (max-width: 520px) {
    .social-like-button {
        width: 100%;
    }

    .social-share-button {
        width: 44px;
        height: 44px;
    }
}

/* Mobile Responsiveness for New Components */
@media (max-width: 768px) {
    .article-section-title {
        font-size: 1.25rem;
    }

    .section-number {
        width: 28px;
        height: 28px;
        font-size: 0.8rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-value {
        font-size: 2rem;
    }

    .pull-quote {
        padding: 1.5rem;
        margin: 2rem 0;
    }

    .pull-quote i {
        font-size: 1.5rem;
        top: 1rem;
        left: 1rem;
    }

    .pull-quote p {
        font-size: 1.1rem;
        margin-left: 2rem;
    }

    .juampi-insight-inline {
        padding: 1.25rem;
    }

}

/* ------------------- */
/* Mobile-First Optimization for Article Cards */
/* ------------------- */

/* Tablets and Medium Devices */
@media (max-width: 992px) {
    .story-card {
        padding: 20px;
    }

    .story-content {
        padding: 1.25rem;
    }

    .story-title {
        font-size: 1.15rem;
    }

    .mini-card p {
        -webkit-line-clamp: 4; /* Show more lines on tablets */
    }
}

/* Mobile Devices - Primary Optimization */
@media (max-width: 768px) {
    .story-card {
        padding: 16px 12px;
        margin-bottom: 16px;
    }

    .story-image {
        height: 200px; /* Consistent mobile height */
        border-radius: 8px;
    }

    .story-content {
        padding: 16px;
    }

    .story-badge {
        font-size: 11px;
        padding: 4px 10px;
        margin-bottom: 10px;
        display: inline-block;
        max-width: 120px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }

    .story-title {
        font-size: 16px;
        font-weight: 700;
        line-height: 1.4;
        margin-bottom: 10px;
        word-break: break-word;
        hyphens: auto;
    }

    .story-excerpt {
        font-size: 13px;
        line-height: 1.6;
        margin-bottom: 12px;
        display: -webkit-box;
        -webkit-line-clamp: 3;
        -webkit-box-orient: vertical;
        overflow: hidden;
        color: rgba(255, 255, 255, 0.7);
    }

    /* Mini cards - Valor Positivo & Usos Comunes */
    .mini-cards {
        gap: 12px;
        margin-bottom: 16px;
    }

    .mini-card {
        padding: 12px;
        border-radius: 8px;
    }

    .mini-card h4 {
        font-size: 13px;
        margin-bottom: 6px;
        font-weight: 700;
    }

    .mini-card p {
        font-size: 12px;
        line-height: 1.5;
        -webkit-line-clamp: 4; /* Show MORE content on mobile */
        word-break: break-word;
        hyphens: auto;
    }

    .story-meta {
        font-size: 11px;
        padding-top: 10px;
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    /* Button improvements */
    .btn-link {
        font-size: 12px;
        padding: 8px 12px;
        display: inline-flex;
        align-items: center;
        gap: 6px;
    }
}

/* Small Mobile Devices */
@media (max-width: 480px) {
    .story-card {
        padding: 12px;
    }

    .story-content {
        padding: 12px;
    }

    .story-image {
        height: 180px;
    }

    .story-title {
        font-size: 15px;
        line-height: 1.3;
    }

    .story-excerpt {
        font-size: 12px;
        -webkit-line-clamp: 2; /* Tighter on very small screens */
    }

    .mini-card {
        padding: 10px;
    }

    .mini-card h4 {
        font-size: 12px;
    }

    .mini-card p {
        font-size: 11px;
        -webkit-line-clamp: 3;
    }

    .btn-link {
        font-size: 11px;
        padding: 7px 10px;
    }
}

/* Expandable content for mobile (preparation) */
.mobile-expandable {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
}

.mobile-expandable.expanded {
    max-height: 1000px;
    transition: max-height 0.5s ease-in;
}

/* Expand toggle button - Hidden on desktop, visible on mobile */
.expand-toggle {
    width: 100%;
    padding: 10px 12px;
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.1), rgba(147, 51, 234, 0.1));
    border: 1px solid rgba(0, 217, 255, 0.3);
    border-radius: 8px;
    color: var(--color-primary);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    display: none; /* Hidden by default on desktop */
    align-items: center;
    justify-content: center;
    gap: 6px;
}

/* Show expand toggle only on tablets and mobile */
@media (max-width: 992px) {
    .expand-toggle {
        display: flex; /* Show on tablets and mobile */
    }
}

.expand-toggle:hover {
    background: linear-gradient(135deg, rgba(0, 217, 255, 0.2), rgba(147, 51, 234, 0.2));
    border-color: rgba(0, 217, 255, 0.5);
}

.expand-toggle:active {
    transform: scale(0.98);
}

.expand-toggle i {
    transition: transform 0.3s ease;
}

.expand-toggle.expanded i {
    transform: rotate(180deg);
}

/* ------------------- */
/* 14. Accessibility   */
/* ------------------- */

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

/* ----------------------------- */
/* 15. Article side actions      */
/* ----------------------------- */

/* Article Layout - Clean Editorial */
.article-layout {
    display: block;
    max-width: 800px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.article-content {
    position: relative;
}
