/* ============================================
   ESTILOS PRINCIPALES - SISTEMA ACADÉMICO LUDAIL
   ============================================ */

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

:root {
    --primary-color: #ff00ff;
    --secondary-color: #9400d3;
    --accent-color: #9400d3;
    --dark-color: #2d0a3d;
    --light-color: #f8f0ff;
    --text-color: #4a1a6b;
    --white: #ffffff;
    --gradient-primary: linear-gradient(135deg, #ff00ff 0%, #ff00ff 50%, #ff00ff 100%);
    --gradient-secondary: linear-gradient(135deg, #ff00ff 0%, #ff00ff 50%, #ff00ff 100%);
    --gradient-accent: linear-gradient(135deg, #9400d3 0%, #9400d3 100%);
    --shadow-sm: 0 4px 15px rgba(148, 0, 211, 0.3);
    --shadow-md: 0 10px 35px rgba(148, 0, 211, 0.4);
    --shadow-lg: 0 20px 60px rgba(148, 0, 211, 0.5);
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #ff00ff 0%, #ff00ff 50%, #ff00ff 100%);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ============================================
   HEADER
   ============================================ */

.header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    box-shadow: var(--shadow-md);
    animation: slideDown 0.8s ease-out;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

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

.logo {
    width: 60px;
    height: 60px;
    object-fit: contain;
    animation: logo3D 4s ease-in-out infinite;
    filter: drop-shadow(0 0 15px rgba(255, 0, 255, 0.8));
    transition: all 0.3s ease;
}

.logo:hover {
    animation: logo3DHover 2s ease-in-out infinite;
    filter: drop-shadow(0 0 25px rgba(255, 0, 255, 1)) drop-shadow(0 0 50px rgba(148, 0, 211, 0.8));
    transform: scale(1.1);
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav {
    display: flex;
    gap: 30px;
    position: relative;
    z-index: 1001;
}

.nav-link {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    position: relative;
    transition: all 0.3s ease;
    pointer-events: auto;
    cursor: pointer;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gradient-primary);
    transition: width 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link:hover::after {
    width: 100%;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 100px;
    background: linear-gradient(135deg, rgba(255, 0, 255, 0.95) 0%, rgba(255, 0, 255, 0.95) 50%, rgba(255, 0, 255, 0.95) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: rotate 20s linear infinite;
}

.hero-content {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 50px;
    z-index: 1;
    flex-wrap: wrap;
}

.hero-text {
    flex: 1;
    min-width: 300px;
    text-align: center;
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-subtitle {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 300;
}

.hero-logo {
    flex: 1;
    min-width: 300px;
    display: flex;
    justify-content: center;
}

.hero-logo-img {
    width: 300px;
    height: 300px;
    object-fit: contain;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3));
    animation: heroLogoFloat 3s ease-in-out infinite, heroLogoGlow 2s ease-in-out infinite alternate;
}

/* ============================================
   ARTICLE SECTION
   ============================================ */

.article-section {
    padding: 100px 0;
    background: linear-gradient(180deg, #ff00ff 0%, #ff00ff 50%, #ff00ff 100%);
    position: relative;
    overflow: hidden;
}

.featured-article {
    background: var(--gradient-primary);
    padding: 60px 50px;
    border-radius: 40px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 30px 80px rgba(255, 0, 255, 0.6);
    animation: articlePulse 3s ease-in-out infinite;
    border: 3px solid rgba(255, 255, 255, 0.3);
}

.article-icon {
    font-size: 5rem;
    margin-bottom: 25px;
    animation: iconBounce 1.5s ease-in-out infinite;
    filter: drop-shadow(0 10px 20px rgba(255, 255, 255, 0.5));
}

.article-title {
    font-size: 3rem;
    font-weight: 800;
    color: var(--white);
    margin-bottom: 25px;
    text-shadow: 0 5px 15px rgba(0, 0, 0, 0.4), 0 0 30px rgba(255, 255, 255, 0.5);
    animation: titleGlow 2s ease-in-out infinite;
}

.article-text {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.98);
    font-weight: 500;
    line-height: 2;
    max-width: 900px;
    margin: 0 auto;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.article-decoration {
    position: absolute;
    bottom: -100px;
    left: -100px;
    width: 300px;
    height: 300px;
    background: radial-gradient(circle, rgba(255, 105, 180, 0.4) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 4s ease-in-out infinite;
}

.article-decoration-2 {
    position: absolute;
    top: -100px;
    right: -100px;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(255, 0, 255, 0.3) 0%, transparent 70%);
    border-radius: 50%;
    animation: float 5s ease-in-out infinite reverse;
}

/* ============================================
   MÓDULOS SECTION
   ============================================ */

.modulos-section {
    padding: 100px 0;
    background: var(--light-color);
}

.section-title {
    font-size: 3rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 20px;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-subtitle {
    font-size: 1.3rem;
    text-align: center;
    color: var(--text-color);
    margin-bottom: 60px;
    font-weight: 400;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.card {
    background: linear-gradient(145deg, #00bcd4 0%, #00acc1 50%, #0097a7 100%);
    border-radius: 25px;
    overflow: hidden;
    box-shadow: 0 15px 40px rgba(0, 188, 212, 0.4);
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    opacity: 0;
    transform: translateY(50px);
    border: 3px solid rgba(0, 131, 143, 0.5);
}

.card:hover {
    transform: translateY(-20px) scale(1.05);
    box-shadow: 0 30px 70px rgba(0, 188, 212, 0.6);
    border-color: rgba(0, 131, 143, 0.8);
}

.card-image {
    position: relative;
    height: 280px;
    overflow: hidden;
    border-bottom: 3px solid rgba(0, 131, 143, 0.4);
}

.card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover .card-image img {
    transform: scale(1);
}

.card-zoom-icon {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 50px;
    height: 50px;
    background: rgba(0, 188, 212, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    border: 2px solid #ffffff;
}

.card-zoom-icon:hover {
    background: rgba(0, 131, 143, 1);
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.card-zoom-icon svg {
    width: 28px;
    height: 28px;
    fill: #ffffff;
}

.card-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, rgba(0, 188, 212, 0.3) 0%, rgba(0, 131, 143, 0.9) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.card:hover .card-overlay {
    opacity: 1;
}

.card-icon {
    font-size: 3rem;
    transform: translateY(20px);
    transition: transform 0.3s ease;
}

.card:hover .card-icon {
    transform: translateY(0);
}

.card-content {
    padding: 30px;
    background: linear-gradient(180deg, #ffffff 0%, #e0f7fa 100%);
}

.card-title {
    font-size: 1.7rem;
    font-weight: 800;
    color: #006064;
    margin-bottom: 15px;
    text-shadow: 0 2px 5px rgba(0, 188, 212, 0.3);
}

.card-description {
    font-size: 1.1rem;
    color: #006064;
    line-height: 1.8;
    font-weight: 500;
}

/* ============================================
   QR SECTION
   ============================================ */

.qr-section {
    padding: 100px 0;
    background: linear-gradient(180deg, #f0f4ff 0%, var(--white) 100%);
}

.qr-container {
    display: flex;
    justify-content: center;
}

.qr-card {
    background: var(--white);
    border-radius: 30px;
    padding: 50px;
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 40px;
    max-width: 600px;
    animation: fadeIn 1s ease-out;
}

.qr-image {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

#qrcode {
    padding: 20px;
    background: var(--white);
    border-radius: 15px;
    box-shadow: var(--shadow-md);
}

#qrcode img {
    width: 200px !important;
    height: 200px !important;
}

.qr-content {
    flex: 1;
    text-align: center;
}

.qr-title {
    font-size: 2rem;
    font-weight: 700;
    color: var(--dark-color);
    margin-bottom: 15px;
    background: var(--gradient-secondary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.qr-text {
    font-size: 1.2rem;
    color: var(--text-color);
    margin-bottom: 25px;
    font-weight: 400;
}

.qr-button {
    display: inline-block;
    padding: 15px 40px;
    background: var(--gradient-primary);
    color: var(--white);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-md);
}

.qr-button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-lg);
}

/* ============================================
   QR REGISTRO SECTION
   ============================================ */

.qr-register-section {
    padding: 80px 0;
    background: linear-gradient(180deg, #ff00ff 0%, #ff00ff 100%);
    position: relative;
    overflow: hidden;
}

.qr-register-container {
    max-width: 500px;
    margin: 0 auto;
}

.qr-register-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8f0ff 100%);
    border-radius: 30px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(148, 0, 211, 0.4);
    border: 3px solid rgba(148, 0, 211, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.qr-register-image {
    margin-bottom: 25px;
}

.qr-register-image #qrcode-register {
    display: flex;
    justify-content: center;
    align-items: center;
}

.qr-register-image #qrcode-register img {
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(148, 0, 211, 0.3);
}

.qr-register-title {
    font-size: 2rem;
    font-weight: 800;
    color: #ff00ff;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(255, 0, 255, 0.3);
}

.qr-register-text {
    font-size: 1.2rem;
    color: #4a1a6b;
    margin-bottom: 25px;
    font-weight: 500;
}

.qr-register-button {
    display: inline-block;
    padding: 15px 40px;
    background: linear-gradient(135deg, #ff00ff 0%, #9400d3 100%);
    color: #ffffff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 10px 30px rgba(148, 0, 211, 0.4);
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.qr-register-button:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(148, 0, 211, 0.6);
}

/* ============================================
   QR REGALO SECTION
   ============================================ */

.qr-regalo-section {
    padding: 80px 0;
    background: linear-gradient(180deg, #ff00ff 0%, #ff00ff 100%);
    position: relative;
    overflow: hidden;
}

.qr-regalo-container {
    max-width: 500px;
    margin: 0 auto;
}

.qr-regalo-card {
    background: linear-gradient(145deg, #ffffff 0%, #f8f0ff 100%);
    border-radius: 30px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(148, 0, 211, 0.4);
    border: 3px solid rgba(148, 0, 211, 0.3);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.qr-regalo-image {
    margin-bottom: 25px;
}

.qr-regalo-image #qrcode-regalo {
    display: flex;
    justify-content: center;
    align-items: center;
}

.qr-regalo-image #qrcode-regalo img {
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(148, 0, 211, 0.3);
}

.qr-regalo-title {
    font-size: 2rem;
    font-weight: 800;
    color: #ff00ff;
    margin-bottom: 15px;
    text-shadow: 0 2px 10px rgba(255, 0, 255, 0.3);
}

.qr-regalo-text {
    font-size: 1.2rem;
    color: #4a1a6b;
    margin-bottom: 25px;
    line-height: 1.6;
}

.qr-regalo-button {
    display: inline-block;
    padding: 15px 40px;
    background: linear-gradient(135deg, #ff00ff 0%, #9400d3 100%);
    color: #ffffff;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    box-shadow: 0 10px 30px rgba(148, 0, 211, 0.4);
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.qr-regalo-button:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(148, 0, 211, 0.6);
}

/* ============================================
   REGISTRO SECTION
   ============================================ */

.registro-section {
    padding: 100px 0;
    background: linear-gradient(180deg, #ff00ff 0%, #ff00ff 100%);
    position: relative;
    overflow: hidden;
}

.registro-form-container {
    max-width: 700px;
    margin: 50px auto 0;
}

.registro-form {
    background: linear-gradient(145deg, #ffffff 0%, #f8f0ff 100%);
    border-radius: 30px;
    padding: 50px;
    box-shadow: 0 20px 60px rgba(148, 0, 211, 0.4);
    border: 3px solid rgba(148, 0, 211, 0.3);
}

.form-group {
    margin-bottom: 30px;
}

.form-group label {
    display: block;
    font-size: 1.1rem;
    font-weight: 700;
    color: #4a1a6b;
    margin-bottom: 10px;
}

.form-input {
    width: 100%;
    padding: 15px 20px;
    border: 2px solid rgba(148, 0, 211, 0.3);
    border-radius: 15px;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #4a1a6b;
}

.form-input:focus {
    outline: none;
    border-color: #ff00ff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.3);
}

.form-input.readonly {
    background: linear-gradient(135deg, #e0f7fa 0%, #b2ebf2 100%);
    color: #006064;
    font-weight: 600;
    cursor: not-allowed;
}

.price-button-container {
    margin: 40px 0;
}

.price-button {
    width: 100%;
    padding: 25px 30px;
    background: linear-gradient(135deg, #ff00ff 0%, #9400d3 100%);
    border: none;
    border-radius: 20px;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    box-shadow: 0 15px 40px rgba(148, 0, 211, 0.5);
    transition: all 0.3s ease;
    animation: pricePulse 2s ease-in-out infinite;
    border: 3px solid rgba(255, 255, 255, 0.3);
}

.price-button:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 50px rgba(148, 0, 211, 0.7);
}

.price-text {
    font-size: 1.5rem;
    font-weight: 800;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.discount-text {
    font-size: 1.1rem;
    font-weight: 600;
    color: #ff69b4;
    text-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
}

.final-price {
    font-size: 1.8rem;
    font-weight: 900;
    color: #ffffff;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    animation: priceGlow 1.5s ease-in-out infinite alternate;
}

.form-actions {
    margin-top: 30px;
}

.form-submit-button {
    width: 100%;
    padding: 18px 40px;
    background: linear-gradient(135deg, #00bcd4 0%, #0097a7 100%);
    border: none;
    border-radius: 50px;
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(0, 188, 212, 0.4);
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.form-submit-button:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 15px 40px rgba(0, 188, 212, 0.6);
}

.button-icon {
    font-size: 1.5rem;
}

@keyframes pricePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
}

@keyframes priceGlow {
    0% {
        text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    }
    100% {
        text-shadow: 0 2px 20px rgba(255, 255, 255, 0.8), 0 0 30px rgba(255, 105, 180, 0.6);
    }
}

/* ============================================
   DATOS SECTION
   ============================================ */

.datos-section {
    padding: 100px 0;
    background: linear-gradient(180deg, #ff00ff 0%, #ff00ff 100%);
    position: relative;
    overflow: hidden;
}

.datos-table-container {
    margin-top: 50px;
}

.table-actions {
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.search-container {
    flex: 1;
    min-width: 300px;
}

.search-input {
    width: 100%;
    padding: 12px 20px;
    border: 2px solid rgba(148, 0, 211, 0.3);
    border-radius: 50px;
    font-size: 1rem;
    font-family: 'Poppins', sans-serif;
    transition: all 0.3s ease;
    background: #ffffff;
    color: #4a1a6b;
}

.search-input:focus {
    outline: none;
    border-color: #ff00ff;
    box-shadow: 0 0 20px rgba(255, 0, 255, 0.3);
}

.search-input::placeholder {
    color: #9400d3;
    opacity: 0.6;
}

.borrar-todos-button {
    padding: 12px 30px;
    background: linear-gradient(135deg, #ff4444 0%, #cc0000 100%);
    border: none;
    border-radius: 50px;
    color: #ffffff;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(255, 68, 68, 0.4);
    transition: all 0.3s ease;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.borrar-todos-button:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 15px 40px rgba(255, 68, 68, 0.6);
}

.table-responsive {
    overflow-x: auto;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(148, 0, 211, 0.4);
}

.datos-table {
    width: 100%;
    border-collapse: collapse;
    background: linear-gradient(145deg, #ffffff 0%, #f8f0ff 100%);
    border: 3px solid rgba(148, 0, 211, 0.3);
}

.datos-table thead {
    background: linear-gradient(135deg, #ff00ff 0%, #9400d3 100%);
}

.datos-table th {
    padding: 20px;
    text-align: left;
    color: #ffffff;
    font-weight: 700;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
}

.datos-table tbody tr {
    border-bottom: 2px solid rgba(148, 0, 211, 0.2);
    transition: all 0.3s ease;
}

.datos-table tbody tr:hover {
    background: linear-gradient(135deg, rgba(0, 188, 212, 0.1) 0%, rgba(0, 131, 143, 0.1) 100%);
    transform: scale(1.01);
}

.datos-table td {
    padding: 18px 20px;
    color: #4a1a6b;
    font-weight: 500;
    font-size: 1rem;
}

.datos-table tbody tr.no-data td {
    text-align: center;
    color: #9400d3;
    font-weight: 600;
    font-size: 1.2rem;
    padding: 40px;
}

/* ============================================
   FOOTER
   ============================================ */

.footer {
    background: #ff00ff;
    padding: 50px 0;
    position: relative;
    overflow: hidden;
}

.footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: var(--gradient-primary);
}

.footer-content {
    text-align: center;
    position: relative;
    z-index: 1;
}

.footer-text-container {
    max-width: 1000px;
    margin: 0 auto;
}

.footer-text {
    font-size: 1.6rem;
    color: rgba(255, 255, 255, 0.95);
    line-height: 2.2;
    font-weight: 600;
    text-shadow: 0 0 20px rgba(148, 0, 211, 0.8);
    white-space: normal;
    word-wrap: break-word;
}

.footer-decoration {
    margin-top: 30px;
}

.footer-line {
    width: 150px;
    height: 6px;
    background: #9400d3;
    margin: 0 auto;
    border-radius: 3px;
    animation: pulse 1.5s infinite;
    box-shadow: 0 0 20px rgba(148, 0, 211, 0.8);
}

/* ============================================
   ANIMACIONES
   ============================================ */

@keyframes slideDown {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes bounce {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes typing {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

@keyframes articlePulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 30px 80px rgba(255, 0, 255, 0.6);
    }
    50% {
        transform: scale(1.02);
        box-shadow: 0 40px 100px rgba(255, 0, 255, 0.8);
    }
}

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

@keyframes titleGlow {
    0%, 100% {
        text-shadow: 0 5px 15px rgba(0, 0, 0, 0.4), 0 0 30px rgba(255, 255, 255, 0.5);
    }
    50% {
        text-shadow: 0 5px 25px rgba(0, 0, 0, 0.6), 0 0 50px rgba(255, 255, 255, 0.8), 0 0 80px rgba(255, 105, 180, 0.6);
    }
}

@keyframes logo3D {
    0% {
        transform: rotateY(0deg) rotateX(0deg);
    }
    25% {
        transform: rotateY(15deg) rotateX(5deg);
    }
    50% {
        transform: rotateY(0deg) rotateX(0deg);
    }
    75% {
        transform: rotateY(-15deg) rotateX(-5deg);
    }
    100% {
        transform: rotateY(0deg) rotateX(0deg);
    }
}

@keyframes logo3DHover {
    0% {
        transform: rotateY(0deg) rotateX(0deg) scale(1.1);
    }
    25% {
        transform: rotateY(25deg) rotateX(10deg) scale(1.15);
    }
    50% {
        transform: rotateY(0deg) rotateX(0deg) scale(1.1);
    }
    75% {
        transform: rotateY(-25deg) rotateX(-10deg) scale(1.15);
    }
    100% {
        transform: rotateY(0deg) rotateX(0deg) scale(1.1);
    }
}

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

@keyframes heroLogoGlow {
    0% {
        filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3)) drop-shadow(0 0 20px rgba(255, 0, 255, 0.5));
    }
    100% {
        filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.3)) drop-shadow(0 0 40px rgba(255, 0, 255, 0.8)) drop-shadow(0 0 60px rgba(148, 0, 211, 0.6));
    }
}

/* Animaciones de entrada */
.animate-fade-in {
    animation: fadeIn 1s ease-out forwards;
}

.animate-fade-in-delay {
    animation: fadeIn 1s ease-out 0.3s forwards;
    opacity: 0;
}

.animate-slide-up {
    animation: slideUp 1s ease-out forwards;
    opacity: 0;
}

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

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out forwards;
}

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

.animate-typewriter {
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid var(--accent-color);
    animation: typing 15s steps(100) infinite, blink 0.75s step-end infinite;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 1024px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .hero-subtitle {
        font-size: 1.2rem;
    }
    
    .hero-logo-img {
        width: 200px;
        height: 200px;
    }
    
    .cards-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
    
    .qr-card {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .header .container {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav {
        gap: 20px;
    }
    
    .hero-content {
        flex-direction: column;
        text-align: center;
    }
    
    .hero-title {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1rem;
    }
    
    .article-title {
        font-size: 1.8rem;
    }
    
    .article-text {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .cards-grid {
        grid-template-columns: 1fr;
    }
    
    .qr-card {
        padding: 30px;
    }
    
    .footer-text {
        font-size: 0.9rem;
        white-space: normal;
        border: none;
        animation: none;
    }
}

@media (max-width: 480px) {
    .logo-text {
        font-size: 1.2rem;
    }
    
    .hero-title {
        font-size: 1.5rem;
    }
    
    .featured-article {
        padding: 30px 20px;
    }
    
    .article-title {
        font-size: 1.5rem;
    }
    
    .article-text {
        font-size: 0.9rem;
    }
    
    .card-image {
        height: 200px;
    }
    
    .card-title {
        font-size: 1.2rem;
    }
    
    .card-description {
        font-size: 0.9rem;
    }
}

/* ============================================
   SCROLLBAR PERSONALIZADO
   ============================================ */

::-webkit-scrollbar {
    width: 10px;
}

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

::-webkit-scrollbar-thumb {
    background: var(--gradient-primary);
    border-radius: 5px;
}

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

/* ============================================
   MODAL DE IMAGEN
   ============================================ */

.image-modal {
    display: none;
    position: fixed;
    z-index: 10000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.95);
    animation: fadeInModal 0.3s ease;
}

.modal-content {
    margin: auto;
    display: block;
    width: 90%;
    max-width: 1200px;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 10px;
    box-shadow: 0 0 50px rgba(255, 0, 255, 0.5);
    animation: zoomInModal 0.3s ease;
}

.modal-close {
    position: absolute;
    top: 20px;
    right: 35px;
    color: #ffffff;
    font-size: 50px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
    z-index: 10001;
    text-shadow: 0 0 20px rgba(255, 0, 255, 0.8);
}

.modal-close:hover,
.modal-close:focus {
    color: var(--accent-color);
    text-decoration: none;
    cursor: pointer;
    transform: scale(1.2);
}

#modalCaption {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 700px;
    text-align: center;
    color: #ccc;
    padding: 10px 0;
    height: 150px;
    font-size: 1.2rem;
}

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

@keyframes zoomInModal {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@media only screen and (max-width: 700px) {
    .modal-content {
        width: 100%;
    }
}

/* ============================================
   BOTONES FLOTANTES DE NAVEGACIÓN
   ============================================ */

.scroll-button {
    position: fixed;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: 3px solid #9400d3;
    background: linear-gradient(135deg, #ff00ff 0%, #ff00ff 100%);
    color: #ffffff;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    z-index: 9999;
    box-shadow: 0 5px 20px rgba(148, 0, 211, 0.5);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
}

.scroll-button.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-button:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(148, 0, 211, 0.7);
    background: linear-gradient(135deg, #9400d3 0%, #9400d3 100%);
}

.scroll-button:active {
    transform: scale(0.95);
}

.scroll-up {
    bottom: 30px;
}

.scroll-down {
    bottom: 100px;
}

.scroll-button span {
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    .scroll-button {
        width: 50px;
        height: 50px;
        right: 20px;
        font-size: 20px;
    }
    
    .scroll-up {
        bottom: 20px;
    }
    
    .scroll-down {
        bottom: 80px;
    }
}
