/* css/style.css - Modern Design System for Universidad DASE */

/* Importar la fuente Inter de Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&display=swap');

:root {
    /* Primary Colors - UCSAR Blue Palette */
    --primary-main: #2563eb;
    --primary-dark: #1e40af;
    --primary-light: #60a5fa;
    --primary-soft: #eff6ff;

    /* Secondary & Accent Colors */
    --secondary-main: #6366f1;
    --accent-vibrant: #3b82f6;

    /* Neutrals */
    --bg-main: #f8fafc;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;

    /* Effects */
    --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);

    --transition-fast: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text-main);
    background-color: var(--bg-main);
}

/* Glassmorphism Utilities */
.glass {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.glass-dark {
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Custom UI Components */
.card-premium {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition-base);
    border: 1px solid var(--border-color);
}

.card-premium:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary-light);
}

.btn-primary-premium {
    background: linear-gradient(135deg, var(--primary-main) 0%, var(--primary-dark) 100%);
    color: white;
    font-weight: 600;
    border-radius: 0.75rem;
    padding: 0.75rem 1.5rem;
    transition: var(--transition-fast);
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.39);
}

.btn-primary-premium:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px 0 rgba(37, 99, 235, 0.45);
    filter: brightness(1.1);
}

/* Improved Tables */
.table-premium {
    width: 100%;
    border-radius: 0.75rem;
    overflow: hidden;
    border: 1px solid var(--border-color);
    background: white;
}

.table-premium th {
    background-color: #f1f5f9;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    padding: 1rem;
}

.table-premium td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition-fast);
}

.table-premium tr:last-child td {
    border-bottom: none;
}

.table-premium tr:hover td {
    background-color: var(--primary-soft);
}

/* --- Floating Labels Design System (Flowbite-like functionality) --- */

.floating-input {
    display: block;
    width: 100%;
    padding: 1.25rem 0.625rem 0.5rem;
    /* Ajustado para dar espacio al label arriba */
    font-size: 0.875rem;
    color: var(--text-main);
    background-color: transparent !important;
    /* Evitar fondos de autofill que causan "sombras" */
    border: 0;
    border-bottom: 2px solid var(--border-color);
    appearance: none;
    transition: var(--transition-fast);
}

.floating-input:focus {
    outline: none;
    border-bottom-color: var(--primary-main);
    box-shadow: none !important;
    /* Eliminar cualquier sombra de foco */
}

/* Ocultar el placeholder por defecto pero mantenerlo funcional para el peer check */
.floating-input::placeholder {
    color: transparent;
}

.floating-label {
    position: absolute;
    top: 1.25rem;
    left: 0.625rem;
    font-size: 0.875rem;
    color: var(--text-muted);
    pointer-events: none;
    transition: var(--transition-fast);
    transform-origin: 0 0;
}

/* Transición del label cuando el input tiene foco o contenido */
.floating-input:focus~.floating-label,
.floating-input:not(:placeholder-shown)~.floating-label {
    transform: translateY(-1.25rem) scale(0.85);
    color: var(--primary-main);
    font-weight: 600;
}

/* Eliminar sombras extrañas en inputs (autofill, etc) */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-box-shadow: 0 0 0 1000px transparent inset !important;
    -webkit-text-fill-color: var(--text-main) !important;
    transition: background-color 5000s ease-in-out 0s;
}

.dark-section input:-webkit-autofill {
    -webkit-text-fill-color: white !important;
}


.dark-section .floating-input:focus~.floating-label,
.dark-section .floating-input:not(:placeholder-shown)~.floating-label {
    color: #38bdf8;
    /* Light blue/cyan for better contrast on indigo */
}



/* --- End Floating Labels --- */

/* Animations */
@keyframes heartbeat {
    0% {
        transform: scale(1);
    }

    14% {
        transform: scale(1.3);
    }

    28% {
        transform: scale(1);
    }

    42% {
        transform: scale(1.3);
    }

    70% {
        transform: scale(1);
    }
}

.animate-heartbeat {
    display: inline-block;
    animation: heartbeat 1.5s ease-in-out infinite;
    transform-origin: center;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.5s ease-out forwards;
}