/* ================================================
   Efectos Premium para Lotería PR
   Animaciones, glassmorphism, y efectos modernos
   ================================================ */

/* ===== GLASSMORPHISM EFFECTS ===== */
.glass-card {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(51, 65, 85, 0.90) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(56, 189, 248, 0.3);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.6);
    border-radius: 16px;
    padding: 1.5rem;
    color: #f1f5f9;
}

.glass-dark {
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(56, 189, 248, 0.3);
    color: #f1f5f9;
}

/* ===== SMOOTH ANIMATIONS ===== */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

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

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

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

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

/* ===== ANIMATION CLASSES ===== */
.animate-slide-up {
    animation: slideInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-slide-down {
    animation: slideInDown 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-slide-left {
    animation: slideInLeft 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-slide-right {
    animation: slideInRight 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-scale {
    animation: scaleIn 0.5s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.animate-pulse {
    animation: pulse 2s ease-in-out infinite;
}

/* Stagger animations */
.stagger-1 { animation-delay: 0.1s; }
.stagger-2 { animation-delay: 0.2s; }
.stagger-3 { animation-delay: 0.3s; }
.stagger-4 { animation-delay: 0.4s; }
.stagger-5 { animation-delay: 0.5s; }

/* ===== CARD ENHANCEMENTS ===== */
.card-premium {
    position: relative;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(51, 65, 85, 0.90) 100%);
    border: 1px solid rgba(56, 189, 248, 0.3);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.6);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    color: #f1f5f9;
}

.card-premium::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.05) 0%, rgba(14, 165, 233, 0.05) 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
}

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

.card-premium:hover {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
}

/* Card with gradient border */
.card-gradient-border {
    position: relative;
    border-radius: 16px;
    padding: 2px;
    background: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
}

.card-gradient-border .card-content {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(15, 23, 42, 0.95) 100%);
    border-radius: 14px;
    padding: 1.5rem;
    color: #f1f5f9;
}

/* ===== BUTTON ENHANCEMENTS ===== */
.btn-premium {
    position: relative;
    overflow: hidden;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-premium::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-premium:hover::before {
    width: 300px;
    height: 300px;
}

.btn-premium:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.btn-premium:active {
    transform: translateY(0);
}

/* Shimmer effect for buttons */
.btn-shimmer {
    background-size: 200% 100%;
    background-image: linear-gradient(
        to right,
        #38bdf8 0%,
        #0ea5e9 50%,
        #38bdf8 100%
    );
    animation: shimmer 3s infinite;
}

/* ===== TABLE ENHANCEMENTS ===== */
.table-premium {
    border-collapse: separate;
    border-spacing: 0;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.5);
}

.table-premium thead {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
}

.table-premium thead th {
    color: #7dd3fc;
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
    padding: 1.2rem 1rem;
    border: none;
    position: relative;
}

.table-premium tbody tr {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background: rgba(30, 41, 59, 0.5);
    color: #e2e8f0;
}

.table-premium tbody tr:hover {
    background: linear-gradient(to right, rgba(56, 189, 248, 0.1), transparent);
    transform: scale(1.01);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.table-premium tbody td {
    padding: 1rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    vertical-align: middle;
}

/* ===== BADGE ENHANCEMENTS ===== */
.badge-premium {
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.8rem;
    letter-spacing: 0.3px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.badge-premium:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ===== PROGRESS BAR ENHANCEMENTS ===== */
.progress-premium {
    height: 28px;
    border-radius: 14px;
    background: rgba(0, 0, 0, 0.05);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
}

.progress-premium .progress-bar {
    border-radius: 14px;
    background: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
    box-shadow: 0 2px 8px rgba(56, 189, 248, 0.4);
    position: relative;
    overflow: hidden;
}

.progress-premium .progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: shimmer 2s infinite;
}

/* ===== INPUT ENHANCEMENTS ===== */
.form-control-premium {
    border: 2px solid rgba(56, 189, 248, 0.3);
    background: rgba(30, 41, 59, 0.8);
    color: #f1f5f9;
    border-radius: 12px;
    padding: 0.85rem 1.2rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.form-control-premium:focus {
    border-color: #38bdf8;
    background: rgba(51, 65, 85, 0.9);
    color: #f1f5f9;
    box-shadow: 0 0 0 4px rgba(56, 189, 248, 0.15), 0 4px 12px rgba(0, 0, 0, 0.5);
    transform: translateY(-2px);
}

/* ===== ALERT ENHANCEMENTS ===== */
.alert-premium {
    border: none;
    border-radius: 12px;
    padding: 1.2rem 1.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
    position: relative;
    overflow: hidden;
}

.alert-premium::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background: currentColor;
}

.alert-premium-success {
    background: linear-gradient(135deg, rgba(39, 174, 96, 0.1) 0%, rgba(46, 204, 113, 0.1) 100%);
    border-left: 4px solid #27ae60;
}

.alert-premium-danger {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.1) 0%, rgba(192, 57, 43, 0.1) 100%);
    border-left: 4px solid #e74c3c;
}

.alert-premium-info {
    background: linear-gradient(135deg, rgba(52, 152, 219, 0.1) 0%, rgba(41, 128, 185, 0.1) 100%);
    border-left: 4px solid #3498db;
}

.alert-premium-warning {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.1) 0%, rgba(230, 126, 34, 0.1) 100%);
    border-left: 4px solid #f39c12;
}

/* ===== LOADING SPINNER ===== */
.spinner-premium {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(56, 189, 248, 0.2);
    border-top-color: #38bdf8;
    border-radius: 50%;
    animation: spin 1s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

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

/* ===== TOOLTIP PREMIUM ===== */
.tooltip-premium {
    position: relative;
}

.tooltip-premium::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    padding: 8px 12px;
    background: rgba(44, 62, 80, 0.95);
    color: white;
    border-radius: 8px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.tooltip-premium:hover::after {
    opacity: 1;
    transform: translateX(-50%) translateY(-12px);
}

/* ===== SECTION HEADER ===== */
.section-header-premium {
    position: relative;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
}

.section-header-premium::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 4px;
    background: linear-gradient(135deg, #38bdf8 0%, #0ea5e9 100%);
    border-radius: 2px;
}

.section-header-premium h2 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #f1f5f9;
    margin: 0;
}

/* ===== STAT CARD ===== */
.stat-card-premium {
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.95) 0%, rgba(51, 65, 85, 0.90) 100%);
    border: 1px solid rgba(56, 189, 248, 0.3);
    border-radius: 16px;
    padding: 1.5rem;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.6);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.stat-card-premium::before {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, rgba(56, 189, 248, 0.1) 0%, rgba(14, 165, 233, 0.1) 100%);
    border-radius: 50%;
    transform: translate(30%, -30%);
}

.stat-card-premium:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.15);
}

.stat-card-premium .stat-value {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #38bdf8 0%, #7dd3fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-card-premium .stat-label {
    font-size: 0.9rem;
    color: #e2e8f0;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

/* ===== UTILITY CLASSES ===== */
.shadow-premium-sm { box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08); }
.shadow-premium-md { box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12); }
.shadow-premium-lg { box-shadow: 0 8px 32px rgba(0, 0, 0, 0.16); }
.shadow-premium-xl { box-shadow: 0 12px 48px rgba(0, 0, 0, 0.20); }

.gradient-text {
    background: linear-gradient(135deg, #38bdf8 0%, #7dd3fc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.border-gradient {
    border: 2px solid transparent;
    background-image: linear-gradient(white, white), linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    background-origin: border-box;
    background-clip: padding-box, border-box;
}
