/* =====================================================
   LANDING — Portal (alineado a salidas pedagógicas + Colorea el Páramo)
   Variables: assets/css/portal-tokens.css
   ===================================================== */

@import url('portal-tokens.css');

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Outfit', system-ui, 'Segoe UI', sans-serif;
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
    background: linear-gradient(165deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%);
    color-scheme: light;
}

/* =====================================================
   ANIMATED BACKGROUND
   ===================================================== */
.bg-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.bg-gradient {
    position: absolute;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(900px 480px at 8% 0%, rgba(96, 165, 250, 0.28), transparent 55%),
        radial-gradient(700px 420px at 95% 10%, rgba(37, 99, 235, 0.22), transparent 58%),
        radial-gradient(600px 380px at 50% 100%, rgba(29, 78, 216, 0.18), transparent 55%),
        linear-gradient(165deg, #3b82f6 0%, #2563eb 32%, #1d4ed8 62%, #1e3a8a 100%);
}

.floating-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(64px);
    opacity: 0.42;
    animation: float 20s infinite ease-in-out;
}

.shape-1 {
    width: 400px;
    height: 400px;
    background: #60a5fa;
    top: -10%;
    left: -5%;
    animation-delay: 0s;
}

.shape-2 {
    width: 300px;
    height: 300px;
    background: #48cae4;
    top: 60%;
    right: -5%;
    animation-delay: -5s;
    opacity: 0.28;
}

.shape-3 {
    width: 250px;
    height: 250px;
    background: #93c5fd;
    bottom: -5%;
    left: 30%;
    animation-delay: -10s;
}

.shape-4 {
    width: 200px;
    height: 200px;
    background: #3b82f6;
    top: 30%;
    left: 60%;
    animation-delay: -15s;
    opacity: 0.32;
}

.shape-5 {
    width: 350px;
    height: 350px;
    background: linear-gradient(135deg, #1b4c8d, #48cae4);
    top: 40%;
    left: -10%;
    animation-delay: -7s;
    opacity: 0.26;
}

.shape-6 {
    width: 280px;
    height: 280px;
    background: #1e40af;
    bottom: 20%;
    right: 20%;
    animation-delay: -12s;
    opacity: 0.2;
}

@keyframes float {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg) scale(1);
    }
    25% {
        transform: translate(30px, -30px) rotate(5deg) scale(1.05);
    }
    50% {
        transform: translate(-20px, 20px) rotate(-5deg) scale(0.95);
    }
    75% {
        transform: translate(-30px, -20px) rotate(3deg) scale(1.02);
    }
}

.grid-overlay {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(27, 67, 50, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(27, 67, 50, 0.035) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: radial-gradient(ellipse at center, black 0%, transparent 78%);
    pointer-events: none;
}

/* =====================================================
   HEADER
   ===================================================== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 14px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    transition: var(--transition-normal);
    background: rgba(255, 255, 255, 0.82);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(140, 176, 235, 0.25);
    box-shadow: 0 4px 20px rgba(12, 30, 63, 0.08);
}

.header.scrolled {
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid var(--sp-border);
    padding: 10px 5%;
    box-shadow: var(--shadow-sm);
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 14px;
}

.logo-emblema-wrap {
    width: 54px;
    height: 54px;
    flex-shrink: 0;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 5px;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.1), inset 0 0 0 1px rgba(226, 232, 240, 0.95);
    border: 2px solid #e2e8f0;
}

.logo-img {
    object-fit: contain;
}

.logo-emblema {
    width: 46px;
    height: 46px;
    border-radius: 50%;
}

.logo-text h1 {
    font-size: 1.15rem;
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    background: linear-gradient(135deg, #1b4c8d 0%, #2f6fb7 55%, #48cae4 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.logo-text span {
    font-size: 0.62rem;
    color: var(--kjic-green-light);
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-weight: 700;
}

.nav-links {
    display: flex;
    gap: 10px;
}

.nav-link {
    --nav-accent: #64748b;
    padding: 8px 14px;
    color: color-mix(in srgb, var(--nav-accent) 72%, #334155);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.85rem;
    border-radius: 999px;
    transition: color var(--transition-normal), background var(--transition-normal),
        border-color var(--transition-normal), box-shadow var(--transition-normal), transform var(--transition-fast);
    display: flex;
    align-items: center;
    gap: 7px;
    border: 1px solid color-mix(in srgb, var(--nav-accent) 30%, #e2e8f0);
    background: color-mix(in srgb, var(--nav-accent) 10%, #ffffff);
    box-shadow: 0 1px 3px color-mix(in srgb, var(--nav-accent) 14%, transparent);
}

.nav-link i {
    color: var(--nav-accent);
    font-size: 0.82rem;
}

.nav-link:hover {
    color: var(--nav-accent);
    border-color: color-mix(in srgb, var(--nav-accent) 48%, #e2e8f0);
    background: color-mix(in srgb, var(--nav-accent) 17%, #ffffff);
    box-shadow: 0 4px 14px color-mix(in srgb, var(--nav-accent) 24%, transparent);
    transform: translateY(-1px);
}

.logo-link {
    text-decoration: none;
    color: inherit;
}

/* Menú móvil */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    width: 44px;
    height: 44px;
    padding: 10px;
    border: 1px solid #94a3b8;
    border-radius: 10px;
    background: var(--btn-surface);
    cursor: pointer;
    z-index: 1002;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.08);
}

.nav-toggle-bar {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--sp-text);
    border-radius: 2px;
    transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav-toggle.is-open .nav-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-open .nav-toggle-bar:nth-child(2) {
    opacity: 0;
}

.nav-toggle.is-open .nav-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 999;
    backdrop-filter: blur(2px);
}

.nav-overlay[hidden] {
    display: none;
}

body.nav-open {
    overflow: hidden;
}

/* =====================================================
   HERO SECTION
   ===================================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 8% 80px;
}

.hero-inner {
    width: 100%;
    max-width: 1280px;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 48px;
    align-items: center;
}

.hero-panel {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.hero-content {
    flex: 1;
    max-width: 600px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 20px;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    border: 1px solid #cbd5e1;
    border-radius: 999px;
    font-size: 0.85rem;
    color: var(--sp-muted);
    margin-bottom: 30px;
    animation: fadeInUp 0.6s ease;
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.07), inset 0 1px 0 #fff;
}

.hero-badge-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--kjic-green-light);
    box-shadow: 0 0 8px rgba(64, 145, 108, 0.45);
    animation: portalPulse 1.6s infinite;
    flex-shrink: 0;
}

@keyframes portalPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.45; }
}

.hero-badge i {
    color: var(--sp-primary-flat);
}

.hero-title {
    font-size: clamp(2.5rem, 5vw, 3.8rem);
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    line-height: 1.12;
    margin-bottom: 25px;
    animation: fadeInUp 0.6s ease 0.1s backwards;
    color: var(--kjic-green-dark);
    letter-spacing: -0.03em;
}

.gradient-text {
    background: linear-gradient(135deg, #0c4a6e 0%, #0ea5e9 40%, #38bdf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
}

.hero-description {
    font-size: 1rem;
    color: var(--sp-muted);
    line-height: 1.75;
    margin-bottom: 28px;
    animation: fadeInUp 0.6s ease 0.2s backwards;
    max-width: 36rem;
    font-weight: 500;
}

.hero-actions {
    display: flex;
    flex-direction: column;
    gap: 24px;
    animation: fadeInUp 0.6s ease 0.25s backwards;
}

.hero-lead {
    margin: 0 0 18px;
    font-size: 1.08rem;
    line-height: 1.65;
    font-weight: 500;
    color: var(--sp-muted);
    animation: fadeInUp 0.6s ease 0.15s backwards;
    max-width: 36rem;
}

.hero-eslogan {
    margin: 0 0 22px;
    padding: 16px 20px;
    border-left: 4px solid var(--kjic-green-light);
    background: linear-gradient(135deg, #ffffff 0%, #f0f7ff 100%);
    border-radius: 0 14px 14px 0;
    font-size: 1.05rem;
    font-style: italic;
    color: var(--sp-muted);
    line-height: 1.65;
    max-width: 600px;
    box-shadow: 0 4px 16px rgba(27, 76, 141, 0.08);
    border: 1px solid rgba(140, 176, 235, 0.45);
    animation: fadeInUp 0.6s ease 0.15s backwards;
}

.hero-cta {
    animation: fadeInUp 0.6s ease 0.3s backwards;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 22px;
    border-radius: 13px;
    font-size: 0.98rem;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease, border-color 0.18s ease, color 0.18s ease;
    font-family: inherit;
    line-height: 1.2;
    border: 1px solid transparent;
}

/* Primario: mismo patrón que .sp-btn (salidas) */
.btn-primary {
    background: var(--sp-primary);
    color: #fff;
    box-shadow: 0 10px 22px rgba(42, 99, 168, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-primary:hover {
    transform: translateY(-1px);
    filter: brightness(1.06);
    box-shadow: 0 14px 32px rgba(27, 76, 141, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* Secundario: file-bar (Colorea) + ghost sp */
.btn-secondary {
    background: var(--btn-surface);
    color: var(--sp-text);
    border: 1px solid var(--btn-surface-border);
    box-shadow:
        0 2px 6px rgba(15, 23, 42, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.95);
    font-weight: 600;
}

.btn-secondary:hover {
    border-color: var(--kjic-green-light);
    color: var(--kjic-green-dark);
    background: #f0f7ff;
    transform: translateY(-1px);
}

.hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
}

.hero-image-wrap {
    position: relative;
    max-width: 520px;
    width: 100%;
    border-radius: var(--border-radius-xl);
    overflow: hidden;
    background: #fff;
    border: 3px solid rgba(74, 138, 213, 0.35);
    box-shadow: var(--sp-shadow-strong), 0 0 0 8px rgba(74, 138, 213, 0.08);
    animation: heroFloat 6s ease-in-out infinite;
}

.floating-card {
    width: 300px;
    height: 300px;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-xl);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    animation: heroFloat 6s ease-in-out infinite;
    box-shadow: var(--sp-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
}

.floating-card .card-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(135deg, rgba(27, 76, 141, 0.12) 0%, rgba(35, 197, 162, 0.08) 100%);
    filter: blur(36px);
    opacity: 0.7;
    z-index: -1;
}

.hero-icon {
    width: 150px;
    height: 150px;
    object-fit: contain;
    filter: drop-shadow(0 8px 20px rgba(27, 76, 141, 0.25));
    animation: pulse 3s ease-in-out infinite;
}

@keyframes heroFloat {
    0%, 100% {
        transform: translateY(0) rotateX(5deg) rotateY(-5deg);
    }
    50% {
        transform: translateY(-20px) rotateX(-5deg) rotateY(5deg);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        filter: drop-shadow(0 6px 18px rgba(42, 99, 168, 0.25));
    }
    50% {
        transform: scale(1.04);
        filter: drop-shadow(0 10px 28px rgba(42, 99, 168, 0.4));
    }
}

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

/* =====================================================
   HERO STATS
   ===================================================== */
.hero-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 0;
    flex-wrap: wrap;
}

.hero-stat {
    display: flex;
    flex-direction: column;
    gap: 2px;
    padding: 12px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    min-width: 110px;
}

.hero-stat-num {
    font-size: 2rem;
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    background: linear-gradient(135deg, #1b4c8d, #48cae4);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.1;
}

/* =====================================================
   STEAM SECTION
   ===================================================== */
.steam-section {
    padding: 80px 8%;
    background: linear-gradient(180deg, transparent 0%, rgba(14, 165, 233, 0.07) 50%, transparent 100%);
}

.steam-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 18px;
    max-width: 1100px;
    margin: 0 auto;
}

.steam-card {
    position: relative;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-lg);
    padding: 24px 20px 22px;
    text-align: center;
    overflow: hidden;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease, box-shadow 0.25s ease;
    box-shadow: var(--shadow-sm);
}

.steam-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.steam-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--steam-color, #2d6a4f);
}

.steam-card:hover {
    box-shadow: var(--sp-shadow-soft);
    transform: translateY(-4px);
}

.steam-letra {
    position: absolute;
    top: 10px;
    right: 14px;
    font-size: 2.2rem;
    font-weight: 900;
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--steam-color, #2d6a4f);
    opacity: 0.15;
    line-height: 1;
}

.steam-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 12px;
    border-radius: 14px;
    background: color-mix(in srgb, var(--steam-color, #2d6a4f) 12%, white);
    border: 1px solid color-mix(in srgb, var(--steam-color, #2d6a4f) 30%, transparent);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    color: var(--steam-color, #2d6a4f);
}

.steam-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--sp-text);
    margin-bottom: 6px;
}

.steam-card p {
    font-size: 0.82rem;
    color: var(--sp-muted);
    line-height: 1.55;
}

/* Logo completo en Acerca de */
.about-brand-logo {
    margin: 16px 0 20px;
    padding: 16px 20px;
    background: #ffffff;
    border-radius: var(--border-radius-md);
    display: inline-block;
    box-shadow: var(--shadow-md);
    border: 1px solid rgba(148, 163, 184, 0.35);
}

.about-brand-logo img {
    max-width: 280px;
    width: 100%;
    height: auto;
    display: block;
}

.tech-steam {
    min-width: 90px;
}

.steam-mini {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: var(--sp-primary);
    color: #fff;
    font-weight: 800;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.hero-stat-label {
    font-size: 0.8rem;
    color: var(--sp-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.hero-description strong {
    color: var(--kjic-green-light);
    font-weight: 700;
}

/* Hero — imagen / video exploradores */
.hero-brand-img,
.hero-brand-video {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    vertical-align: middle;
}

.hero-brand-video {
    background: #000;
}

.hero-glow {
    background: linear-gradient(135deg, rgba(27, 76, 141, 0.15) 0%, rgba(72, 202, 228, 0.12) 100%);
}

/* =====================================================
   VISION SECTION
   ===================================================== */
.vision-section {
    padding: 80px 8% 60px;
}

.pilares-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto 48px;
}

.pilar-card {
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-lg);
    padding: 28px 26px;
    box-shadow: var(--sp-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.25s ease;
}

.pilar-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.pilar-card:hover {
    box-shadow: var(--sp-shadow-strong);
    transform: translateY(-3px);
}

.pilar-icon {
    width: 52px;
    height: 52px;
    background: var(--sp-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.3rem;
    margin-bottom: 16px;
    box-shadow: 0 8px 18px rgba(34, 92, 168, 0.28);
}

.pilar-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--sp-text);
    margin-bottom: 8px;
}

.pilar-card p {
    font-size: 0.92rem;
    color: var(--sp-muted);
    line-height: 1.65;
}

.fase-banner {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    max-width: 900px;
    margin: 0 auto;
    padding: 24px 28px;
    background: linear-gradient(135deg, rgba(27, 76, 141, 0.08) 0%, rgba(35, 197, 162, 0.06) 100%);
    border: 1px solid rgba(43, 93, 158, 0.3);
    border-radius: var(--border-radius-lg);
    box-shadow: var(--shadow-sm);
}

.fase-banner-icon {
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    background: var(--sp-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
}

.fase-banner-text strong {
    display: block;
    font-size: 1rem;
    color: var(--sp-text);
    margin-bottom: 6px;
}

.fase-banner-text p {
    font-size: 0.92rem;
    color: var(--sp-muted);
    line-height: 1.65;
    margin: 0;
}

/* =====================================================
   CATEGORIAS SECTION
   ===================================================== */
.categorias-section {
    padding: 60px 8%;
    background: linear-gradient(180deg, transparent 0%, rgba(27, 76, 141, 0.03) 50%, transparent 100%);
}

.categorias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.categoria-card {
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-md);
    padding: 22px 20px;
    text-align: center;
    transition: var(--transition-normal);
    box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    opacity: 0;
    transform: scale(0.95);
    cursor: pointer;
}

.categoria-card.animate-in {
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.categoria-card:hover {
    border-color: rgba(43, 93, 158, 0.55);
    box-shadow: var(--sp-shadow-soft);
    transform: translateY(-4px) scale(1.01);
}

.categoria-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 12px;
    background: linear-gradient(180deg, #f0f6ff 0%, #e2edff 100%);
    border: 1px solid #b8cce8;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--sp-primary-flat);
}

.categoria-card h3 {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--sp-text);
    margin-bottom: 6px;
}

.categoria-card p {
    font-size: 0.8rem;
    color: var(--sp-muted);
    line-height: 1.5;
    margin-bottom: 10px;
}

.categoria-count {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    padding: 4px 10px;
    background: linear-gradient(180deg, #e8fff5 0%, #dbfaea 100%);
    color: #0f766e;
    border: 1px solid #6ee7b7;
    border-radius: 50px;
}

/* =====================================================
   FILTER BAR
   ===================================================== */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 40px;
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.filter-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 8px 16px;
    border: 1px solid #94a3b8;
    border-radius: 50px;
    background: var(--btn-surface);
    color: var(--sp-muted);
    font-family: inherit;
    font-size: 0.82rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition-normal);
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
}

.filter-btn:hover {
    border-color: var(--sp-primary-flat);
    color: var(--sp-primary-flat);
}

.filter-btn.active {
    background: var(--sp-primary);
    color: #fff;
    border-color: var(--kjic-green-dark);
    box-shadow: 0 6px 16px rgba(27, 67, 50, 0.28);
}

.projects-note {
    text-align: center;
    margin-top: 40px;
    font-size: 0.9rem;
    color: var(--sp-muted);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.projects-note i {
    color: var(--sp-primary-flat);
}

/* =====================================================
   ROADMAP SECTION
   ===================================================== */
.roadmap-section {
    padding: 100px 8%;
    background: linear-gradient(180deg, transparent 0%, rgba(27, 76, 141, 0.04) 40%, transparent 100%);
}

.roadmap-timeline {
    max-width: 700px;
    margin: 0 auto 60px;
    position: relative;
    padding-left: 36px;
}

.roadmap-timeline::before {
    content: '';
    position: absolute;
    left: 15px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: linear-gradient(180deg, #2a63a8 0%, #23a89a 60%, #cbd5e1 100%);
    border-radius: 2px;
}

.timeline-item {
    position: relative;
    margin-bottom: 32px;
    opacity: 0;
    transform: translateX(-16px);
}

.timeline-item.animate-in {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.timeline-marker {
    position: absolute;
    left: -36px;
    top: 2px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--btn-surface);
    border: 2px solid #94a3b8;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    color: var(--sp-muted);
    z-index: 1;
}

.timeline-marker.active {
    background: var(--sp-primary);
    border-color: var(--kjic-green-dark);
    color: #fff;
    box-shadow: 0 4px 12px rgba(27, 76, 141, 0.35);
}

.timeline-fase {
    display: inline-block;
    font-size: 0.72rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--sp-primary-flat);
    margin-bottom: 4px;
}

.timeline-content h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--sp-text);
    margin-bottom: 6px;
}

.timeline-content p {
    font-size: 0.9rem;
    color: var(--sp-muted);
    line-height: 1.6;
}

.roadmap-grid {
    margin-top: 20px;
}

.project-card.roadmap-placeholder {
    border-style: dashed;
    opacity: 0.55;
}

.project-card.roadmap-placeholder .project-icon {
    background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
    color: #94a3b8;
    box-shadow: none;
    border: 1px dashed #94a3b8;
}

/* =====================================================
   PROJECTS SECTION
   ===================================================== */
.projects-section {
    padding: 100px 8%;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-tag {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    border: 1px solid #cbd5e1;
    border-radius: 50px;
    font-size: 0.8rem;
    color: var(--sp-muted);
    margin-bottom: 20px;
    font-weight: 600;
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06);
}

.section-tag i {
    color: var(--sp-primary-flat);
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    margin-bottom: 15px;
    background: linear-gradient(135deg, #0c4a6e 0%, #0284c7 50%, #38bdf8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.section-tag-steam {
    border-color: rgba(72, 202, 228, 0.5);
    background: linear-gradient(180deg, #ffffff 0%, #eef6ff 100%);
}

.section-description {
    font-size: 1.1rem;
    color: var(--sp-muted);
    max-width: 600px;
    margin: 0 auto;
    font-weight: 500;
}

.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.project-card {
    position: relative;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-lg);
    padding: 32px 34px 36px;
    text-decoration: none;
    color: inherit;
    transition: var(--transition-normal);
    transform-style: preserve-3d;
    cursor: pointer;
    overflow: hidden;
    opacity: 0;
    transform: translateY(30px);
    box-shadow: var(--sp-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(6px);
    display: flex;
    flex-direction: column;
}

.project-card--with-cover {
    padding: 0 0 28px;
}

.project-cover {
    position: relative;
    width: 100%;
    height: 172px;
    flex-shrink: 0;
    overflow: hidden;
    background: linear-gradient(135deg, #e2e8f0 0%, #f1f5f9 100%);
    border-bottom: 1px solid var(--sp-border);
}

.project-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    display: block;
    transition: transform 0.45s ease;
}

.project-card--with-cover:hover .project-cover img {
    transform: scale(1.04);
}

.project-card--with-cover .project-body {
    padding: 18px 28px 0;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.project-card--with-cover .project-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.project-card--with-cover .project-icon {
    width: 44px;
    height: 44px;
    min-width: 44px;
    font-size: 1.05rem;
    margin-bottom: 0;
    border-radius: 10px;
    box-shadow: 0 6px 14px rgba(34, 92, 168, 0.28);
}

.project-card--with-cover .project-icon-img img {
    max-width: 32px;
    max-height: 32px;
}

.project-card--with-cover .project-title {
    margin-bottom: 0;
    font-size: 1.2rem;
    line-height: 1.25;
}

.project-card--with-cover .project-description {
    margin-bottom: 16px;
}

.project-card--with-cover .project-status {
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 10px rgba(15, 23, 42, 0.12);
    border: 1px solid rgba(226, 232, 240, 0.9);
}

.project-card--with-cover .project-arrow {
    bottom: 24px;
    right: 24px;
}

.project-card.animate-in {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.project-card .card-glow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--gradient-glow);
    opacity: 0;
    transition: var(--transition-normal);
    pointer-events: none;
}

.project-card:hover .card-glow {
    opacity: 0.35;
}

.project-card:hover {
    border-color: rgba(42, 99, 168, 0.55);
    box-shadow: var(--sp-shadow-strong), 0 0 0 1px rgba(74, 138, 213, 0.2);
    transform: translateY(-4px);
}

.project-icon {
    width: 70px;
    height: 70px;
    background: var(--sp-primary);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: #fff;
    margin-bottom: 25px;
    box-shadow: 0 10px 22px rgba(34, 92, 168, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.project-icon-img img {
    max-width: 55px;
    max-height: 55px;
    object-fit: contain;
}

.project-title {
    font-size: 1.45rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--sp-text);
    letter-spacing: -0.01em;
}

.project-description {
    font-size: 0.95rem;
    color: var(--sp-muted);
    line-height: 1.7;
    margin-bottom: 20px;
}

.project-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 15px;
}

.feature-tag {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    background: linear-gradient(180deg, #f0f7ff 0%, #e2edff 100%);
    border: 1px solid #b8cce8;
    border-radius: 50px;
    font-size: 0.75rem;
    color: #1d518f;
    font-weight: 600;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.project-arrow {
    position: absolute;
    bottom: 32px;
    right: 32px;
    width: 44px;
    height: 44px;
    background: var(--btn-surface);
    border: 1px solid #94a3b8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sp-muted);
    transition: var(--transition-normal);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08), inset 0 1px 0 #fff;
}

.project-card:hover .project-arrow {
    background: var(--sp-primary);
    color: #fff;
    transform: translateX(5px);
    border-color: var(--kjic-green-dark);
    box-shadow: 0 6px 16px rgba(27, 76, 141, 0.35);
}

.project-status {
    position: absolute;
    top: 25px;
    right: 25px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 50px;
    font-size: 0.75rem;
    font-weight: 600;
}

.project-status.active {
    background: linear-gradient(180deg, #e8fff5 0%, #dbfaea 100%);
    color: #0f766e;
    border: 1px solid #6ee7b7;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.6);
}

.project-status.active i {
    animation: blink 1.5s infinite;
}

.project-status.upcoming {
    background: linear-gradient(180deg, #fffbeb 0%, #fef3c7 100%);
    color: #b45309;
    border: 1px solid #fbbf24;
    box-shadow: 0 1px 0 rgba(255, 255, 255, 0.5);
}

@keyframes blink {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.3;
    }
}

/* Coming Soon Card */
.project-card.coming-soon {
    opacity: 0.7;
    cursor: default;
}

.project-card.coming-soon:hover {
    transform: none;
    border-color: var(--sp-border);
    box-shadow: var(--sp-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.project-card.coming-soon::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent 0%, rgba(241, 245, 249, 0.75) 100%);
    pointer-events: none;
}

/* Add Project Card */
.project-card.add-project {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    border-style: dashed;
    opacity: 0.5;
    cursor: default;
}

.project-card.add-project:hover {
    transform: none;
}

.add-icon {
    width: 80px;
    height: 80px;
    border: 2px dashed #94a3b8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #94a3b8;
    margin-bottom: 20px;
}

.add-project p {
    color: #94a3b8;
    font-size: 0.9rem;
    font-weight: 500;
}

/* =====================================================
   ABOUT SECTION
   ===================================================== */
.about-section {
    padding: 100px 8%;
    background: linear-gradient(180deg, transparent 0%, rgba(14, 165, 233, 0.06) 50%, transparent 100%);
}

.about-content {
    display: flex;
    align-items: center;
    gap: 80px;
    max-width: 1200px;
    margin: 0 auto;
}

.about-text {
    flex: 1;
    opacity: 0;
    transform: translateX(-30px);
}

.about-text.animate-in {
    opacity: 1;
    transform: translateX(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.about-text p {
    color: var(--sp-muted);
    line-height: 1.8;
    margin: 20px 0 30px;
    font-size: 1.02rem;
}

.tech-stack {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.tech-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 20px 25px;
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-md);
    transition: var(--transition-normal);
    box-shadow: var(--shadow-sm), inset 0 1px 0 rgba(255, 255, 255, 0.9);
}

.tech-item:hover {
    border-color: rgba(43, 93, 158, 0.5);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.tech-item i {
    font-size: 2rem;
    color: var(--sp-primary-flat);
    filter: drop-shadow(0 1px 0 rgba(255, 255, 255, 0.8));
}

.tech-item span {
    font-size: 0.85rem;
    color: var(--sp-muted);
    font-weight: 600;
}

.about-visual {
    flex: 1;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.stat-item {
    background: var(--sp-surface);
    border: 1px solid var(--sp-border);
    border-radius: var(--border-radius-lg);
    padding: 30px;
    text-align: center;
    transition: var(--transition-normal);
    opacity: 0;
    transform: scale(0.9);
    box-shadow: var(--sp-shadow-soft), inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(4px);
}

.stat-item.animate-in {
    opacity: 1;
    transform: scale(1);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.stat-item:hover {
    border-color: rgba(43, 93, 158, 0.5);
    box-shadow: var(--sp-shadow-strong);
    transform: translateY(-4px) scale(1.01);
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--sp-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 5px;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--sp-muted);
    font-weight: 600;
}

/* =====================================================
   FOOTER
   ===================================================== */
.footer {
    padding: 40px 8%;
    border-top: 1px solid rgba(140, 176, 235, 0.45);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(240, 247, 255, 0.9) 100%);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-logo-img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.footer-emblema-wrap {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(145deg, #1b4c8d, #0a1628);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3px;
    border: 1px solid rgba(74, 138, 213, 0.4);
}

.footer-logo span {
    font-size: 1.2rem;
    font-weight: 800;
    background: var(--sp-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
}

.footer-text {
    color: #64748b;
    font-size: 0.9rem;
    font-weight: 500;
}

.footer-links {
    display: flex;
    gap: 15px;
}

.footer-links a {
    width: 40px;
    height: 40px;
    background: var(--btn-surface);
    border: 1px solid #94a3b8;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--sp-muted);
    text-decoration: none;
    transition: var(--transition-normal);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.06);
}

.footer-links a:hover {
    background: var(--sp-primary);
    color: #fff;
    border-color: var(--kjic-green-dark);
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(45, 106, 79, 0.28);
}

/* =====================================================
   RESPONSIVE DESIGN
   ===================================================== */
@media (max-width: 1200px) {
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 40px;
        text-align: center;
    }

    .hero {
        padding-top: 150px;
    }

    .hero-panel,
    .hero-lead,
    .hero-description {
        max-width: 100%;
        margin-left: auto;
        margin-right: auto;
    }

    .hero-actions {
        align-items: center;
    }

    .hero-stats {
        justify-content: center;
    }

    .hero-cta {
        justify-content: center;
    }

    .hero-visual {
        margin-top: 10px;
    }
    
    .floating-card {
        width: 250px;
        height: 250px;
    }
    
    .hero-icon {
        width: 120px;
        height: 120px;
    }
    
    .about-content {
        flex-direction: column;
        text-align: center;
    }
    
    .tech-stack {
        justify-content: center;
    }
}

@media (max-width: 992px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .header {
        padding: 15px 5%;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        width: min(300px, 85vw);
        height: 100vh;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        padding: 90px 20px 30px;
        background: rgba(255, 255, 255, 0.97);
        border-left: 1px solid var(--sp-border);
        box-shadow: -8px 0 32px rgba(12, 30, 63, 0.12);
        transform: translateX(100%);
        transition: transform 0.3s ease;
        z-index: 1001;
        overflow-y: auto;
    }

    .nav-links.is-open {
        transform: translateX(0);
    }

    .nav-link {
        justify-content: flex-start;
        padding: 12px 16px;
    }
    
    .hero {
        padding: 120px 5% 60px;
    }
    
    .hero-title {
        font-size: 2rem;
    }

    .hero-stats {
        justify-content: center;
    }
    
    .vision-section,
    .steam-section,
    .categorias-section,
    .projects-section,
    .roadmap-section,
    .about-section {
        padding: 60px 5%;
    }

    .fase-banner {
        flex-direction: column;
        text-align: center;
        align-items: center;
    }

    .filter-bar {
        gap: 6px;
    }

    .filter-btn {
        font-size: 0.75rem;
        padding: 7px 12px;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .project-card {
        padding: 25px;
    }

    .project-card--with-cover {
        padding: 0 0 22px;
    }

    .project-card--with-cover .project-body {
        padding: 16px 20px 0;
    }

    .project-cover {
        height: 150px;
    }
    
    .project-arrow {
        display: none;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .floating-card {
        width: 200px;
        height: 200px;
    }
    
    .hero-icon {
        width: 90px;
        height: 90px;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .tech-stack {
        gap: 10px;
    }
    
    .tech-item {
        padding: 15px 20px;
    }
}

/* =====================================================
   SCROLLBAR CUSTOMIZATION
   ===================================================== */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #d8e8f8;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #4a8ad5 0%, #1b4c8d 100%);
    border-radius: 5px;
    border: 2px solid #d8e8f8;
}

::selection {
    background: rgba(45, 106, 79, 0.22);
    color: #1a3328;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--sp-primary-flat);
}

/* =====================================================
   LOADING ANIMATION
   ===================================================== */
.project-card:nth-child(1) { transition-delay: 0.1s; }
.project-card:nth-child(2) { transition-delay: 0.2s; }
.project-card:nth-child(3) { transition-delay: 0.3s; }
.project-card:nth-child(4) { transition-delay: 0.4s; }

.stat-item:nth-child(1) { transition-delay: 0.1s; }
.stat-item:nth-child(2) { transition-delay: 0.2s; }
.stat-item:nth-child(3) { transition-delay: 0.3s; }
.stat-item:nth-child(4) { transition-delay: 0.4s; }

/* =====================================================
   PÁGINA DE DETALLE DE PROYECTO — diseño unificado
   ===================================================== */
.page-detalle .detalle-main {
    max-width: 1040px;
    margin: 0 auto;
    padding: 108px 5% 72px;
}

.detalle-breadcrumb {
    margin-bottom: 22px;
}

.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--sp-muted);
}

.breadcrumb a {
    color: var(--sp-primary-flat);
    text-decoration: none;
    font-weight: 600;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb-sep {
    font-size: 0.65rem;
    opacity: 0.5;
}

.breadcrumb-current {
    font-weight: 600;
    color: var(--sp-text);
}

.detalle-wrap {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 48px;
}

/* Cabecera del proyecto */
.detalle-head {
    background: linear-gradient(155deg, rgba(255, 255, 255, 0.98) 0%, rgba(248, 250, 252, 0.96) 100%);
    border: 1px solid rgba(148, 163, 184, 0.35);
    border-radius: 24px;
    box-shadow:
        0 24px 48px rgba(15, 23, 42, 0.12),
        0 4px 12px rgba(15, 23, 42, 0.06),
        inset 0 1px 0 rgba(255, 255, 255, 0.95);
    overflow: hidden;
    position: relative;
    opacity: 0;
    transform: translateY(18px);
}

.detalle-head::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, #22c55e, #3b82f6, #8b5cf6, #22c55e);
    background-size: 200% 100%;
}

.detalle-head.animate-in {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.55s ease, transform 0.55s ease;
}

.detalle-head-main {
    display: flex;
    align-items: flex-start;
    gap: 28px;
    padding: 32px 32px 24px;
}

.detalle-head-icon {
    width: 96px;
    height: 96px;
    flex-shrink: 0;
    background: linear-gradient(145deg, #ecfdf5 0%, #d1fae5 100%);
    border: 2px solid rgba(34, 197, 94, 0.35);
    border-radius: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.35rem;
    color: #15803d;
    box-shadow: 0 12px 28px rgba(34, 197, 94, 0.22);
}

.detalle-head-icon img {
    max-width: 64px;
    max-height: 64px;
    object-fit: contain;
}

.detalle-head-copy {
    flex: 1;
    min-width: 0;
}

.detalle-categoria {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 7px 14px;
    background: linear-gradient(180deg, #eff6ff 0%, #dbeafe 100%);
    border: 1px solid #93c5fd;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #1d4ed8;
    margin-bottom: 12px;
}

.detalle-head h1 {
    font-size: clamp(1.85rem, 4.2vw, 2.75rem);
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    color: var(--sp-text);
    margin: 0 0 10px;
    letter-spacing: -0.03em;
    line-height: 1.15;
}

.detalle-resumen {
    font-size: 1.05rem;
    color: var(--sp-muted);
    line-height: 1.65;
    margin: 0;
    max-width: 620px;
}

/* Barra de acciones */
.detalle-action-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    padding: 18px 32px 22px;
    border-top: 1px solid rgba(148, 163, 184, 0.25);
    background: linear-gradient(180deg, rgba(241, 245, 249, 0.5) 0%, rgba(248, 250, 252, 0.85) 100%);
}

.detalle-action-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px 18px;
}

.detalle-status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #166534;
    background: linear-gradient(180deg, #dcfce7 0%, #bbf7d0 100%);
    border: 1px solid #86efac;
}

.detalle-status-pill i {
    font-size: 0.45rem;
    color: #22c55e;
}

.detalle-nota {
    font-size: 0.84rem;
    color: var(--sp-muted);
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.detalle-nota i {
    color: var(--sp-primary-flat);
}

.detalle-acciones {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.detalle-btn-primary {
    padding: 0.85rem 1.5rem !important;
    font-size: 0.95rem !important;
    font-weight: 700 !important;
    border-radius: 14px !important;
    box-shadow: 0 8px 22px rgba(34, 197, 94, 0.35) !important;
}

.detalle-btn-secondary {
    padding: 0.85rem 1.25rem !important;
    font-size: 0.92rem !important;
    border-radius: 14px !important;
}

/* Cuadrícula bento */
.detalle-bento {
    display: grid;
    grid-template-columns: 1.15fr 0.85fr 0.85fr;
    gap: 18px;
}

.detalle-card {
    background: linear-gradient(160deg, rgba(255, 255, 255, 0.97) 0%, rgba(248, 250, 252, 0.94) 100%);
    border: 1px solid rgba(148, 163, 184, 0.32);
    border-radius: 20px;
    padding: 22px 24px 24px;
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.07);
    opacity: 0;
    transform: translateY(14px);
}

.detalle-card.animate-in {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.55s ease, transform 0.55s ease;
}

.detalle-card--about { transition-delay: 0.08s; }
.detalle-card--features { transition-delay: 0.14s; }
.detalle-card--tech { transition-delay: 0.2s; }

.detalle-card-head {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.detalle-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    flex-shrink: 0;
}

.detalle-card--about .detalle-card-icon {
    background: linear-gradient(145deg, #dbeafe, #bfdbfe);
    color: #1d4ed8;
}

.detalle-card--features .detalle-card-icon {
    background: linear-gradient(145deg, #fef3c7, #fde68a);
    color: #b45309;
}

.detalle-card--tech .detalle-card-icon {
    background: linear-gradient(145deg, #ede9fe, #ddd6fe);
    color: #6d28d9;
}

.detalle-card-head h2 {
    font-size: 1rem;
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    color: var(--sp-text);
    margin: 0;
}

.detalle-card p {
    color: var(--sp-muted);
    line-height: 1.75;
    font-size: 0.95rem;
    margin: 0;
}

.detalle-feature-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.detalle-feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 14px;
    border-radius: 12px;
    background: linear-gradient(90deg, rgba(239, 246, 255, 0.9) 0%, rgba(255, 255, 255, 0.6) 100%);
    border: 1px solid rgba(147, 197, 253, 0.45);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--sp-text);
}

.detalle-feature-icon {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: #2563eb;
    font-size: 0.85rem;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.15);
}

.detalle-tech-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.detalle-tech-tag {
    padding: 8px 14px;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    font-size: 0.82rem;
    font-weight: 700;
    color: #475569;
    letter-spacing: 0.01em;
}

.detalle-relacionados {
    margin-top: 12px;
}

.detalle-relacionados-head {
    text-align: center;
    margin-bottom: 28px;
}

.detalle-relacionados-head h2 {
    font-size: 1.55rem;
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    color: var(--sp-text);
    margin: 0 0 8px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.detalle-relacionados-head h2 i {
    color: var(--sp-primary-flat);
}

.detalle-relacionados-head p {
    color: var(--sp-muted);
    margin: 0;
    font-size: 0.98rem;
}

.detalle-relacionados-grid {
    margin-top: 8px;
}

.detalle-error {
    text-align: center;
    padding: 80px 20px;
}

.detalle-error-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(180deg, #f1f5f9 0%, #e2e8f0 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: #94a3b8;
}

.detalle-error h1 {
    font-size: 1.8rem;
    margin-bottom: 12px;
    color: var(--sp-text);
}

.detalle-error p {
    color: var(--sp-muted);
    margin-bottom: 28px;
}

@media (max-width: 960px) {
    .detalle-bento {
        grid-template-columns: 1fr 1fr;
    }

    .detalle-card--about {
        grid-column: 1 / -1;
    }
}

@media (max-width: 720px) {
    .detalle-head-main {
        flex-direction: column;
        align-items: center;
        text-align: center;
        padding: 28px 22px 20px;
    }

    .detalle-resumen {
        margin-left: auto;
        margin-right: auto;
    }

    .detalle-action-bar {
        flex-direction: column;
        align-items: stretch;
        padding: 16px 22px 20px;
    }

    .detalle-action-meta {
        justify-content: center;
    }

    .detalle-acciones {
        justify-content: center;
    }

    .detalle-acciones .btn {
        flex: 1 1 auto;
        justify-content: center;
        min-width: 140px;
    }

    .detalle-bento {
        grid-template-columns: 1fr;
    }

    .page-detalle .detalle-main {
        padding: 96px 4.5% 56px;
    }
}

/* =====================================================
   PORTAL — fondo azul + blanco, tarjetas claras
   ===================================================== */
body.portal-body {
    background: #2563eb;
    background: var(--blv-bg-main);
    background-attachment: fixed;
    color: var(--text-on-bg-muted);
}

/* Tipografía neutra sobre fondo azul (sin letras azules) */
.portal-body .hero-title {
    color: var(--text-on-bg);
}

.portal-body .gradient-text {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.portal-body .section-title,
.portal-body .section-title-inline {
    background: none !important;
    -webkit-background-clip: border-box !important;
    background-clip: border-box !important;
    -webkit-text-fill-color: var(--text-on-bg) !important;
    color: var(--text-on-bg) !important;
}

.portal-body .section-tag {
    color: #ecfccb;
}

.portal-body .section-tag i {
    color: #a3e635;
}

.portal-body .hero-lead,
.portal-body .hero-description,
.portal-body .hero-stat-label,
.portal-body .section-description,
.portal-body .projects-note,
.portal-body .contact-social-intro,
.portal-body .breadcrumb {
    color: var(--text-on-bg-muted);
}

.portal-body .hero-description strong {
    color: #ffffff;
}

.portal-body .hero-stat-num {
    background: linear-gradient(135deg, #ffffff 0%, #e2e8f0 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.portal-body .hero-stat {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.16);
}

.portal-body .hero-eslogan {
    color: var(--sp-muted);
    background: linear-gradient(135deg, #ffffff 0%, #f8fafc 100%);
    border-color: #e2e8f0;
    border-left-color: #94a3b8;
}

.portal-body .hero-badge {
    color: var(--sp-muted);
}

.portal-body .logo-text h1 {
    background: none;
    -webkit-text-fill-color: var(--sp-text);
    color: var(--sp-text);
}

.portal-body .logo-text span {
    color: var(--sp-muted);
}

.portal-body .footer-text,
.portal-body .footer-eslogan,
.portal-body .footer-contact-mini a {
    color: var(--sp-muted);
}

.portal-body .contact-card h3 i,
.portal-body .contact-list strong,
.portal-body .contact-ic {
    color: var(--sp-text);
}

.portal-body .inv-panel h3 i {
    color: var(--sp-text);
}

.portal-body .inv-card-num {
    color: var(--sp-text);
}

.portal-body .inv-card span {
    color: var(--sp-muted);
}

.portal-body .portal-eslogan {
    color: var(--sp-muted);
}

.portal-body .eslogan-firma {
    color: var(--sp-text);
}

body.portal-body .bg-animation.portal-bg .bg-gradient,
.portal-bg .bg-gradient {
    background:
        radial-gradient(900px 480px at 8% 0%, var(--blv-glow-a), transparent 55%),
        radial-gradient(700px 420px at 95% 10%, var(--blv-glow-b), transparent 58%),
        radial-gradient(600px 380px at 50% 100%, var(--blv-glow-c), transparent 55%),
        var(--blv-bg-main);
}

.portal-body .header,
.portal-body .hero,
.portal-body section,
.portal-body .footer {
    position: relative;
    z-index: 1;
}

.portal-blob {
    position: absolute;
    border-radius: 50%;
    filter: blur(70px);
    opacity: 0.45;
    animation: portalFloat 14s ease-in-out infinite;
    pointer-events: none;
}
.portal-blob.a { width: 520px; height: 520px; top: -100px; right: -100px; background: radial-gradient(circle, var(--blv-glow-a), transparent 70%); }
.portal-blob.b { width: 560px; height: 560px; bottom: -180px; left: -160px; background: radial-gradient(circle, var(--blv-glow-b), transparent 70%); animation-delay: -5s; }
.portal-blob.c { width: 340px; height: 340px; top: 40%; left: 50%; transform: translate(-50%, -50%); background: radial-gradient(circle, var(--blv-glow-c), transparent 70%); animation-delay: -8s; }

@keyframes portalFloat {
    0%, 100% { transform: translateY(0) scale(1); }
    50% { transform: translateY(-20px) scale(1.03); }
}

/* Cabecera blanca */
.portal-body .header {
    background: rgba(255, 255, 255, 0.94);
    border-bottom: 1px solid rgba(140, 176, 235, 0.4);
    box-shadow: 0 4px 20px rgba(27, 76, 141, 0.08);
    z-index: 10000;
}
.portal-body .header.scrolled {
    background: rgba(255, 255, 255, 0.98);
}
.portal-body .nav-links.is-open {
    background: rgba(255, 255, 255, 0.98);
    border-left-color: rgba(74, 138, 213, 0.35);
    box-shadow: -8px 0 24px rgba(27, 76, 141, 0.1);
}

.portal-body .section-title-inline {
    font-size: clamp(1.6rem, 3vw, 2.2rem);
    font-weight: 800;
    font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
    margin-bottom: 6px;
}

.portal-body .section-header-light {
    text-align: left;
    margin-bottom: 24px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.portal-body .section-header-light .section-description {
    max-width: none;
    margin: 8px 0 0;
    text-align: left;
    color: var(--text-on-bg-muted);
}

/* Tarjetas blanco-azul */
.portal-body .pilar-card,
.portal-body .steam-card,
.portal-body .categoria-card,
.portal-body .project-card,
.portal-body .timeline-item,
.portal-body .kpi-card,
.portal-body .chart-card,
.portal-body .contact-card,
.portal-body .stat-item,
.portal-body .about-text,
.portal-body .glass-card,
.portal-body .detalle-panel,
.portal-body .detalle-head,
.portal-body .detalle-card {
    opacity: 1;
    transform: none;
}

.portal-body .glass-card,
.portal-body .pilar-card,
.portal-body .categoria-card,
.portal-body .steam-card,
.portal-body .fase-banner,
.portal-body .kpi-card,
.portal-body .project-card,
.portal-body .stat-item,
.portal-body .detalle-panel,
.portal-body .detalle-head,
.portal-body .detalle-card,
.portal-body .contact-card,
.portal-body .chart-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    border: 1px solid var(--blv-border);
    box-shadow: 5px 5px 14px rgba(0, 0, 0, 0.05), -2px -2px 6px rgba(255, 255, 255, 0.8);
    color: var(--sp-text);
}

.portal-body .pilar-card h3,
.portal-body .steam-card h3,
.portal-body .categoria-card h3,
.portal-body .timeline-content h3,
.portal-body .kpi-card strong,
.portal-body .chart-card h3,
.portal-body .contact-card h3 {
    color: var(--sp-text);
}

.portal-body .pilar-card p,
.portal-body .steam-card p,
.portal-body .categoria-card p,
.portal-body .timeline-content p,
.portal-body .kpi-card span {
    color: var(--sp-muted);
}

.portal-body .project-card.coming-soon {
    background: linear-gradient(165deg, #f8fbff 0%, #eef4fb 100%);
    border-style: dashed;
}

.portal-body .fase-banner {
    background: linear-gradient(135deg, #ffffff 0%, #e0f2fe 100%);
}

.portal-body .hero-image-wrap {
    background: #fff;
    border-color: rgba(74, 138, 213, 0.35);
    box-shadow: var(--blv-shadow-strong);
}

.portal-body .footer {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(240, 247, 255, 0.95) 100%);
    border-top: 1px solid rgba(140, 176, 235, 0.4);
}

.portal-body .about-brand-logo {
    background: linear-gradient(145deg, #ffffff 0%, #eef6ff 100%);
    border-color: rgba(74, 138, 213, 0.35);
}

.portal-body .footer-emblema-wrap {
    background: linear-gradient(145deg, #fff, #eef6ff);
    border-color: rgba(74, 138, 213, 0.35);
}

.portal-body .vision-section,
.portal-body .steam-section,
.portal-body .dashboard-section,
.portal-body .categorias-section,
.portal-body .projects-section,
.portal-body .roadmap-section,
.portal-body .about-section,
.portal-body .contact-section {
    width: 100%;
    max-width: 1400px;
    margin-left: auto;
    margin-right: auto;
}

.portal-body section[id],
.portal-body .hero[id] {
    scroll-margin-top: 92px;
}

/* KPIs y gráficas — estilo Inventario de Plantas */
.dashboard-section { padding: 60px 8%; }

/* Hojas cayendo (Inventario de Plantas) */
.inv-leaves {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 9998;
    overflow: hidden;
}
.inv-leaf {
    position: absolute;
    width: 20px;
    height: 20px;
    left: calc(var(--i, 0) * 7% - 5%);
    top: -20px;
    opacity: 0.55;
    animation: inv-leaf-fall 12s linear infinite;
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    font-size: 18px;
    color: #22c55e;
}
.inv-leaf::before { content: "\f06c"; }
.inv-leaf:nth-child(3n) { color: #f59e0b; }
.inv-leaf:nth-child(5n) { color: #d97706; }
.inv-leaf:nth-child(7n) { color: #059669; }
.inv-leaf:nth-child(1) { --i: 1; animation-delay: 0s; animation-duration: 14s; }
.inv-leaf:nth-child(2) { --i: 3; animation-delay: 2s; animation-duration: 11s; font-size: 14px; }
.inv-leaf:nth-child(3) { --i: 5; animation-delay: 4s; animation-duration: 16s; }
.inv-leaf:nth-child(4) { --i: 2; animation-delay: 1s; animation-duration: 13s; }
.inv-leaf:nth-child(5) { --i: 7; animation-delay: 3s; animation-duration: 15s; }
.inv-leaf:nth-child(6) { --i: 4; animation-delay: 5s; animation-duration: 12s; font-size: 22px; }
.inv-leaf:nth-child(7) { --i: 6; animation-delay: 0.5s; animation-duration: 17s; }
.inv-leaf:nth-child(8) { --i: 8; animation-delay: 2.5s; animation-duration: 10s; }
.inv-leaf:nth-child(9) { --i: 10; animation-delay: 6s; animation-duration: 14s; }
.inv-leaf:nth-child(10) { --i: 9; animation-delay: 1.5s; animation-duration: 11s; }
.inv-leaf:nth-child(11) { --i: 11; animation-delay: 4.5s; animation-duration: 15s; }
.inv-leaf:nth-child(12) { --i: 12; animation-delay: 3.5s; animation-duration: 13s; }
.inv-leaf:nth-child(13) { --i: 14; animation-delay: 7s; animation-duration: 16s; }
.inv-leaf:nth-child(14) { --i: 13; animation-delay: 2s; animation-duration: 12s; }
.inv-leaf:nth-child(15) { --i: 15; animation-delay: 5.5s; animation-duration: 18s; }
.inv-leaf:nth-child(16) { --i: 1; animation-delay: 8s; animation-duration: 11s; }
.inv-leaf:nth-child(17) { --i: 6; animation-delay: 1s; animation-duration: 14s; }
.inv-leaf:nth-child(18) { --i: 10; animation-delay: 6.5s; animation-duration: 13s; }

@keyframes inv-leaf-fall {
    0% { top: -20px; transform: translateX(0) rotate(0deg); opacity: 0.55; }
    10% { transform: translateX(20px) rotate(72deg); }
    20% { transform: translateX(-15px) rotate(144deg); }
    30% { transform: translateX(25px) rotate(216deg); }
    40% { transform: translateX(-10px) rotate(288deg); }
    50% { transform: translateX(15px) rotate(360deg); }
    60% { transform: translateX(-20px) rotate(432deg); }
    70% { transform: translateX(10px) rotate(504deg); }
    80% { transform: translateX(-25px) rotate(576deg); }
    90% { transform: translateX(5px) rotate(648deg); }
    100% { top: 100vh; transform: translateX(0) rotate(720deg); opacity: 0.35; }
}

@media (prefers-reduced-motion: reduce) {
    .portal-leaves { display: none; }
}

.inv-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 28px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}
.inv-card {
    background: #fff;
    border-radius: 16px;
    padding: 24px 20px;
    border: 1px solid var(--blv-border);
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.inv-card-icon {
    font-size: 2rem;
    margin-bottom: 8px;
    display: block;
}
.inv-card-icon--azul { color: #0ea5e9; }
.inv-card-icon--ambar { color: #f59e0b; }
.inv-card-icon--verde { color: #10b981; }
.inv-card-icon--violeta { color: #8b5cf6; }
.inv-card-icon--cian { color: #06b6d4; }
.inv-card-num {
    display: block;
    font-size: 2rem;
    font-weight: 800;
    color: var(--sp-text);
    margin-bottom: 4px;
    line-height: 1.1;
}
.inv-card span {
    font-size: 0.85rem;
    color: var(--sp-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}
.inv-cards-3d .inv-card-3d {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 6px 6px 16px rgba(0, 0, 0, 0.06), -2px -2px 8px rgba(255, 255, 255, 0.9);
    animation: inv-card-enter 0.5s ease backwards;
}
.inv-cards-3d .inv-card-3d:nth-child(1) { animation-delay: 0.1s; }
.inv-cards-3d .inv-card-3d:nth-child(2) { animation-delay: 0.2s; }
.inv-cards-3d .inv-card-3d:nth-child(3) { animation-delay: 0.3s; }
.inv-cards-3d .inv-card-3d:nth-child(4) { animation-delay: 0.4s; }
.inv-cards-3d .inv-card-3d:nth-child(5) { animation-delay: 0.5s; }
.inv-cards-3d .inv-card-3d:hover {
    box-shadow: 8px 8px 24px rgba(14, 165, 233, 0.15), -4px -4px 12px rgba(255, 255, 255, 1);
    transform: translateY(-6px);
}

.inv-dash-charts {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 1200px;
    margin: 0 auto;
}
.inv-panel {
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid var(--blv-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.inv-panel h3 {
    margin: 0 0 16px;
    font-size: 1rem;
    font-weight: 700;
    color: var(--sp-text);
    display: flex;
    align-items: center;
    gap: 8px;
}
.inv-panel h3 i { color: var(--sp-primary-flat); }
.inv-panel-3d {
    background: linear-gradient(145deg, #ffffff 0%, #f8fafc 100%);
    box-shadow: 5px 5px 14px rgba(0, 0, 0, 0.05), -2px -2px 6px rgba(255, 255, 255, 0.8);
    animation: inv-panel-enter 0.6s ease backwards;
}
.inv-panel-3d:hover {
    box-shadow: 8px 8px 20px rgba(14, 165, 233, 0.1), -3px -3px 10px rgba(255, 255, 255, 0.9);
}
.inv-chart-wrap {
    height: 220px;
    position: relative;
}
.inv-chart-wrap-wide {
    height: 280px;
    min-height: 280px;
}

@keyframes inv-card-enter {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes inv-panel-enter {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: scale(1); }
}

.kpi-grid {
    /* hereda .inv-cards */
}
.kpi-card.inv-card {
    display: block;
    flex-direction: column;
    align-items: center;
    min-height: auto;
    opacity: 1;
    transform: none;
}
.kpi-card.animate-in { opacity: 1; transform: none; }

.chart-card-wide { grid-column: 1 / -1; }
.chart-card { opacity: 1; transform: none; }
.chart-card.animate-in { opacity: 1; transform: none; }
.chart-box { position: relative; width: 100%; }

/* Contacto */
.contact-section { padding: 80px 8%; }
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}
.contact-card {
    padding: 24px;
    border-radius: 22px;
    opacity: 0;
    transform: translateY(16px);
}
.contact-card.animate-in { opacity: 1; transform: translateY(0); transition: opacity 0.5s ease, transform 0.5s ease; }
.contact-card h3 {
    margin: 0 0 18px;
    color: #173252;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}
.contact-card h3 i { color: var(--portal-accent); }
.contact-list { list-style: none; margin: 0 0 20px; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.contact-list li { display: flex; gap: 12px; align-items: flex-start; }
.contact-ic {
    width: 40px; height: 40px; border-radius: 10px;
    background: rgba(74, 138, 213, 0.15); color: var(--portal-accent);
    display: grid; place-items: center; flex-shrink: 0;
}
.contact-list strong { display: block; font-size: 0.78rem; color: var(--portal-accent); text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 2px; }
.contact-list a, .contact-list span { color: var(--blv-text); font-size: 0.92rem; text-decoration: none; }
.contact-list a:hover { color: var(--portal-accent-bright); text-decoration: underline; }
.btn-block { width: 100%; justify-content: center; }

.contact-social-intro { color: var(--blv-muted); font-size: 0.9rem; margin-bottom: 16px; line-height: 1.55; }
.social-grid { display: flex; flex-direction: column; gap: 10px; }
.social-link {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px; border-radius: 12px;
    background: #f8fbff;
    border: 1px solid #c5d9f2;
    color: #173252; text-decoration: none;
    font-weight: 600; font-size: 0.9rem;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}
.social-link i {
    width: 36px; height: 36px; border-radius: 10px;
    background: color-mix(in srgb, var(--social-color) 18%, #fff);
    color: var(--social-color);
    display: grid; place-items: center; font-size: 1rem;
}
.social-link:hover {
    transform: translateX(4px);
    background: #eef6ff;
    border-color: var(--social-color);
}

.contact-eslogan-card { text-align: center; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.eslogan-icon {
    width: 56px; height: 56px; border-radius: 50%;
    background: var(--blv-primary);
    display: grid; place-items: center;
    font-size: 1.4rem; color: #fff;
    margin-bottom: 16px;
    box-shadow: 0 8px 20px rgba(42, 99, 168, 0.35);
}
.portal-eslogan {
    margin: 0;
    font-size: 1.05rem;
    font-style: italic;
    color: var(--sp-muted);
    line-height: 1.7;
    border: none;
    padding: 0;
}
.eslogan-firma { margin-top: 14px; color: var(--kjic-green); font-size: 0.85rem; font-weight: 600; }

.footer-brand-block { max-width: 360px; }
.footer-eslogan {
    margin: 10px 0 0;
    font-size: 0.82rem;
    color: var(--portal-accent-bright);
    line-height: 1.5;
    font-style: italic;
}
.footer-contact-mini {
    display: flex;
    flex-direction: column;
    gap: 8px;
}
.footer-contact-mini a {
    color: var(--portal-accent-soft);
    text-decoration: none;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 8px;
}
.footer-contact-mini a:hover { color: var(--kjic-green-dark); }

@media (max-width: 768px) {
    .portal-body .hero-eslogan { font-size: 0.95rem; }
    .hero--panel .hero-panel { padding: 24px 20px; }
    .dashboard-section, .contact-section { padding: 60px 5%; }
    .chart-card-wide { grid-column: auto; }
}

/* =====================================================
   HERO — VARIANTES DE DISEÑO
   Cambiar en includes/portal_config.php → $portal_hero_layout
   Valores: panel | centrado | cinematografico
   ===================================================== */

/* Opción 1 (recomendada): panel legible + video al lado */
.hero--panel .hero-panel {
    padding: 32px 34px;
    border-radius: 22px;
    background: rgba(15, 23, 42, 0.58);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 20px 50px rgba(15, 23, 42, 0.28);
}

.hero--panel .hero-lead {
    color: #e2e8f0;
    font-style: italic;
}

.hero--panel .hero-badge {
    margin-bottom: 22px;
}

.hero--panel .hero-title {
    margin-bottom: 16px;
}

/* Opción 2: centrado editorial — video arriba, texto abajo */
.hero--centrado .hero-inner {
    grid-template-columns: 1fr;
    max-width: 760px;
    text-align: center;
}

.hero--centrado .hero-visual {
    order: -1;
}

.hero--centrado .hero-panel {
    align-items: center;
}

.hero--centrado .hero-lead,
.hero--centrado .hero-description {
    margin-left: auto;
    margin-right: auto;
}

.hero--centrado .hero-image-wrap {
    max-width: 640px;
}

.hero--centrado .hero-actions {
    align-items: center;
}

.hero--centrado .hero-stats {
    justify-content: center;
}

.hero--centrado .hero-cta {
    justify-content: center;
}

/* Opción 3: cinematográfico — video ancho, info compacta abajo */
.hero--cinematografico .hero-inner {
    grid-template-columns: 1fr;
    max-width: 960px;
    gap: 28px;
}

.hero--cinematografico .hero-panel {
    text-align: center;
    align-items: center;
}

.hero--cinematografico .hero-description {
    display: none;
}

.hero--cinematografico .hero-visual {
    order: -1;
    width: 100%;
}

.hero--cinematografico .hero-image-wrap {
    max-width: 100%;
}

.hero--cinematografico .hero-actions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    gap: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.hero--cinematografico .hero-stats {
    flex: 1;
    justify-content: flex-start;
}

.hero--cinematografico .hero-cta {
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .hero--cinematografico .hero-actions {
        flex-direction: column;
        align-items: center;
    }

    .hero--cinematografico .hero-stats {
        justify-content: center;
    }
}

/* =====================================================
   FONDO DEFINITIVO — Hero KJIC (foto + overlay azul)
   ===================================================== */
.portal-bg-photo {
    position: absolute;
    inset: 0;
    background-color: transparent;
    background-image: var(--portal-bg);
    background-size: cover;
    background-position: center 42%;
    background-repeat: no-repeat;
    pointer-events: none;
    z-index: 1;
}
.portal-body.portal-fondo-foto .portal-bg-photo::after {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--portal-photo-overlay, rgba(15, 23, 42, 0.38));
}
.portal-body.portal-fondo-foto .portal-bg .bg-gradient {
    z-index: 0;
    opacity: 1;
    background:
        radial-gradient(900px 480px at 8% 0%, rgba(96, 165, 250, 0.28), transparent 55%),
        radial-gradient(700px 420px at 95% 10%, rgba(37, 99, 235, 0.22), transparent 58%),
        radial-gradient(600px 380px at 50% 100%, rgba(29, 78, 216, 0.18), transparent 55%),
        linear-gradient(165deg, #3b82f6 0%, #2563eb 50%, #1d4ed8 100%);
}
.portal-body.portal-fondo-foto .portal-blob {
    display: none;
}

/* Acceso personal (proyectos privados) */
.footer-admin-access {
    opacity: 0.45;
    font-size: 0.85rem;
}

.footer-admin-access:hover,
.footer-admin-access--active {
    opacity: 1;
}

.footer-admin-access--active {
    background: rgba(99, 102, 241, 0.12) !important;
    border-color: rgba(99, 102, 241, 0.35) !important;
    color: #4f46e5 !important;
}

.privados-main {
    padding: 120px 24px 80px;
    max-width: 1280px;
    margin: 0 auto;
}

.privados-section .section-title {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
}

.privados-toolbar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 32px;
}

.privados-toolbar .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
}

.privados-toolbar .btn-outline {
    background: transparent;
}

