:root {
    --primary-blue: #357DAC;
    --primary-blue-dark: #2a6590;
    --primary-blue-light: #4a8bc2;
    --success-green: #4CAF50;
    --success-green-dark: #45a049;
    --error-red: #D9534F;
    --warning-yellow: #F0AD4E;
    --white: #ffffff;
    --gray-light: #F4F4F4;
    --gray-medium: #9E9E9E;
    --gray-dark: #212121;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-weight: 400;
    line-height: 1.6;
    color: var(--gray-dark);
    background: var(--gray-light);
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* Header Styles */
.header {
    background: var(--primary-blue);
    padding: 24px 0;
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.header-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.logo-section {
    display: flex;
    align-items: center;
    gap: 16px;
}

.logo-image {
    width: 240px;
    height: auto;
    display: block;
    margin: 0 auto;
}

.project-info h2 {
    font-size: 14px;
    font-weight: 500;
    letter-spacing: 0.5px;
    opacity: 0.8;
    margin-bottom: 4px;
}

.project-info h1 {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 1px;
}

.system-title {
    text-align: center;
}

.system-title h1 {
    font-size: 28px;
    font-weight: 600;
    margin-bottom: 12px;
}

.title-underline {
    width: 80px;
    height: 3px;
    background: var(--white);
    margin: 0 auto;
    border-radius: 2px;
}

/* Banner Homenaje */
.banner-homenaje {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    padding: 2.5rem 2rem;
    margin: 2rem auto;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    max-width: 1200px;
}

.banner-content {
    max-width: 1000px;
    margin: 0 auto;
    text-align: center;
}

.banner-title {
    color: var(--white);
    font-family: 'Inter', sans-serif;
    font-size: 2.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    line-height: 1.3;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
}

.banner-message {
    background: rgba(255, 255, 255, 0.98);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: var(--shadow-md);
}

.banner-message p {
    color: var(--gray-dark);
    font-family: 'Inter', sans-serif;
    font-size: 1.1rem;
    line-height: 1.6;
    margin: 0;
    font-weight: 400;
}

@media (max-width: 768px) {
    .banner-homenaje {
        margin: 1.5rem 1rem;
        padding: 2rem 1.5rem;
    }

    .banner-title {
        font-size: 1.75rem;
    }

    .banner-message {
        padding: 1.5rem;
    }

    .banner-message p {
        font-size: 1rem;
    }
}

/* Main Content */
.main-content {
    background: var(--white);
    padding: 48px 0;
}

.subsystems-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

/* Subsystem Cards */
.subsystem-card {
    background: var(--gray-light);
    border-radius: 16px;
    padding: 32px 24px;
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-md);
    border: 1px solid #e0e0e0;
    text-decoration: none;
    color: inherit;
}

.subsystem-card:hover {
    background: var(--white);
    transform: translateY(-12px) scale(1.03);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-blue);
}

.subsystem-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-blue);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.subsystem-card:hover::before {
    transform: scaleX(1);
}

.card-icon {
    width: 64px;
    height: 64px;
    background: var(--primary-blue);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    transition: all 0.3s ease;
}

.card-icon i {
    font-size: 28px;
    color: var(--white);
}

.subsystem-card:hover .card-icon {
    transform: scale(1.15) rotate(5deg);
    box-shadow: 0 0 20px rgba(53, 125, 172, 0.3);
    background: var(--primary-blue-light);
}

.card-content h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--gray-dark);
    margin-bottom: 8px;
    line-height: 1.3;
}

.card-content p {
    font-size: 14px;
    color: var(--gray-medium);
    line-height: 1.5;
}

.card-overlay {
    display: none;
    /* Ocultamos completamente el overlay */
}

.access-btn {
    display: none;
    /* Ocultamos el botón de acceso */
}

/* Footer */
.footer {
    background: var(--gray-dark);
    color: var(--gray-medium);
    padding: 32px 0;
    text-align: center;
    margin-top: 48px;
}

.footer-content {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
}

.copyright {
    font-size: 14px;
    line-height: 1.6;
}

.footer-links {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-link {
    color: var(--gray-medium);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s ease;
}

.footer-link:hover {
    color: var(--white);
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.loading-overlay.show {
    display: flex;
}

.loading-spinner {
    background: var(--white);
    padding: 48px;
    border-radius: 16px;
    text-align: center;
    box-shadow: var(--shadow-xl);
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--neutral-200);
    border-top: 4px solid var(--primary-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        padding: 0 12px;
    }

    .header {
        padding: 24px 0;
    }

    .logo-section {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .logo-circle {
        width: 50px;
        height: 50px;
    }

    .logo-text {
        font-size: 14px;
    }

    .project-info h1 {
        font-size: 20px;
    }

    .system-title h1 {
        font-size: 24px;
        line-height: 1.3;
    }

    .subsystems-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .subsystem-card {
        padding: 24px 20px;
    }

    .card-icon {
        width: 56px;
        height: 56px;
    }

    .card-icon i {
        font-size: 24px;
    }

    .card-content h3 {
        font-size: 16px;
    }

    .main-content {
        padding: 32px 0;
    }

    .footer-links {
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .header-content {
        gap: 20px;
    }

    .system-title h1 {
        font-size: 22px;
    }

    .subsystems-grid {
        gap: 16px;
    }

    .subsystem-card {
        padding: 20px 16px;
    }

    .footer-links {
        flex-direction: column;
        gap: 12px;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.scale-in {
    animation: scaleIn 0.4s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* Focus styles for accessibility */
.subsystem-card:focus,
.access-btn:focus,
.footer-link:focus {
    outline: 2px solid var(--primary-blue);
    outline-offset: 2px;
}