:root {
    /* Diseño y colores originales aprobados */
    --bg-base: #090d16;
    --surface: rgba(22, 30, 49, 0.78);
    --surface-hover: rgba(30, 41, 69, 0.88);
    --surface-card: rgba(15, 23, 42, 0.75);
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.18);
    
    --text-main: #f8fafc;
    --text-muted: #94a3b8;
    --text-sub: #64748b;
    
    --brand-from: #3b82f6;
    --brand-to: #06b6d4;
    --accent: #6366f1;
    
    --success: #10b981;
    --success-bg: rgba(16, 185, 129, 0.12);
    --success-border: rgba(16, 185, 129, 0.3);
    
    --danger: #f43f5e;
    --danger-bg: rgba(244, 63, 94, 0.12);
    --danger-border: rgba(244, 63, 94, 0.3);

    --purple: #a855f7;
    --purple-bg: rgba(168, 85, 247, 0.12);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --shadow-card: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 25px rgba(59, 130, 246, 0.25);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    scrollbar-width: thin;
    scrollbar-color: #334155 transparent;
    -webkit-tap-highlight-color: transparent;
}

::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: #334155;
    border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
    background: #475569;
}

body {
    background-color: var(--bg-base);
    background-image: 
        radial-gradient(at 0% 0%, rgba(59, 130, 246, 0.14) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(99, 102, 241, 0.14) 0px, transparent 50%),
        radial-gradient(at 50% 50%, rgba(6, 182, 212, 0.05) 0px, transparent 70%);
    background-attachment: fixed;
    color: var(--text-main);
    min-height: 100vh;
    padding: 24px 16px 60px;
    overflow-x: hidden; /* Previene scroll horizontal en móvil */
}

html {
    overflow-x: hidden;
}


.container {
    max-width: 1380px;
    margin: 0 auto;
    padding: 70px 16px 0 16px; /* Padding for mobile screens */
    box-sizing: border-box;
}

@media (min-width: 1600px) {
    .container {
        max-width: 1700px !important;
    }
}

/* HEADER */

.brand-meta h1 {
    font-size: 20px;
    font-weight: 800;
    letter-spacing: -0.01em;
    background: linear-gradient(to right, #ffffff, #93c5fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-meta p {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 600;
    background: rgba(16, 185, 129, 0.12);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.25);
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background-color: #10b981;
    border-radius: 50%;
    box-shadow: 0 0 8px #10b981;
    display: inline-block;
    animation: pulseDot 2.2s infinite ease-in-out;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* RELOJ CON DÍA, MES Y NÚMERO */
.clock-widget {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 8px 14px;
    border-radius: var(--radius-sm);
    text-align: right;
    box-shadow: 0 2px 10px rgba(0,0,0,0.25);
}

.clock-date-line {
    font-size: 11px;
    letter-spacing: 0.3px;
    font-weight: 600;
    color: var(--text-muted);
    letter-spacing: 0.02em;
}

.clock-time-line {
    font-size: 14.5px;
    font-weight: 700;
    color: #f8fafc;
    font-variant-numeric: tabular-nums;
    font-family: monospace;
    margin-top: 1px;
}

.btn-sync {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 9px 14px;
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-sync:hover {
    border-color: var(--brand-from);
    background: rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
}

.btn-sync.spinning svg {
    animation: spin 0.8s linear infinite;
}

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

/* TABS DE NAVEGACIÓN (REDISEÑO MODERNO MINIMALISTA TIPO SEGMENTED GLASS DOCK) */





.tab-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 1px solid transparent;
    color: #94a3b8;
    padding: 9px 18px;
    border-radius: 9999px;
    font-size: 13.5px;
    font-weight: 600;
    letter-spacing: 0.01em;
    cursor: pointer;
    white-space: nowrap;
    transition: all 0.22s cubic-bezier(0.16, 1, 0.3, 1);
    user-select: none;
}

.tab-btn svg {
    flex-shrink: 0;
    transition: all 0.22s ease;
    opacity: 0.75;
}

.tab-btn:hover {
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.08);
    transform: translateY(-1px);
}

.tab-btn:hover svg {
    opacity: 1;
    transform: scale(1.08);
}

.tab-btn.active {
    color: #ffffff;
    font-weight: 700;
    background: linear-gradient(135deg, rgba(37, 99, 235, 0.95) 0%, rgba(14, 165, 233, 0.92) 100%);
    border-color: rgba(125, 211, 252, 0.45);
    box-shadow: 0 6px 20px -3px rgba(14, 165, 233, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.35);
    transform: translateY(-1px);
}

.tab-btn.active svg {
    opacity: 1;
    color: #ffffff;
    filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.6));
}

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

/* PANELES */
.panel {
    display: none;
    max-width: 1400px;
    margin: 0 auto;
}
.panel.active {
    display: block;
    animation: tabSlideUpFadeIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes tabSlideUpFadeIn {
    0% {
        opacity: 0;
        transform: translateY(16px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* TARJETA DE CONTROL / FILTROS */
.control-card {
    background: var(--surface);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 20px;
    margin-bottom: 22px;
    box-shadow: var(--shadow-card);
    width: 100%;
    box-sizing: border-box;
}

/* CABECERA CON BOTÓN BLOQUE ACTUAL */
.filter-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.filter-header-title {
    font-size: 14.5px;
    font-weight: 700;
    color: #f1f5f9;
}

.btn-bloque-actual {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    color: #cbd5e1;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--radius-sm);
    padding: 6px;
    width: 32px;
    height: 32px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: none;
}
.btn-bloque-actual svg {
    width: 20px;
    height: 20px;
}
.btn-bloque-actual:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.2);
    transform: none;
    box-shadow: none;
}

.control-group {
    margin-bottom: 18px;
}
.control-group:last-child {
    margin-bottom: 0;
}

.section-label {
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.07em;
    color: var(--text-muted);
    margin-bottom: 9px;
}

/* BARRA DE BÚSQUEDA TIPO LUPA */
.search-field {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(15, 23, 42, 0.85);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 0 16px;
    width: 100%;
    margin-bottom: 12px;
    transition: all 0.2s ease;
}

.search-field:focus-within {
    border-color: var(--brand-from);
    box-shadow: var(--shadow-glow);
    background: rgba(15, 23, 42, 0.98);
}

.search-field svg {
    flex-shrink: 0;
    color: var(--text-muted);
}

.search-field input {
    flex: 1;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 13px 0 !important;
    color: #ffffff !important;
    font-size: 14px !important;
    outline: none !important;
    min-width: 0;
}

.search-field input::placeholder {
    color: var(--text-sub);
    font-size: 13.5px;
}

/* PASTILLAS SEGMENTADAS */
.pill-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.pill-row-break {
    flex-basis: 100%;
    width: 100%;
    height: 0;
    margin: 0;
    padding: 0;
}

.pill-btn {
    background: rgba(15, 23, 42, 0.7);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 7px 13px;
    border-radius: var(--radius-sm);
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.18s ease;
    white-space: nowrap;
}

.pill-btn:hover {
    color: var(--text-main);
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(30, 41, 69, 0.7);
}

.pill-btn.active {
    background: rgba(59, 130, 246, 0.22);
    border-color: var(--brand-from);
    color: #93c5fd;
    font-weight: 700;
    box-shadow: 0 0 12px rgba(59, 130, 246, 0.2);
}

.solemne-mode .normal-block {
    display: none !important;
}

.solemne-mode .solemne-block {
    display: inline-flex !important;
}

/* ALERTA DE HORARIO NO LECTIVO */
.window-alert-banner {
    display: none;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: var(--radius-md);
    margin-bottom: 18px;
    font-size: 13px;
    color: #fde68a;
    line-height: 1.4;
}

.window-alert-banner.show {
    display: flex;
}

.window-alert-banner svg {
    flex-shrink: 0;
    color: #f59e0b;
    margin-top: 1px;
}

/* BARRA DE MÉTRICAS */
.metrics-bar {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 12px 18px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin-bottom: 20px;
    font-size: 13px;
}

.metric-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
}
.metric-badge.free { color: #34d399; }
.metric-badge.occ { color: #fb7185; }

.group-title {
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin: 22px 0 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}


/* =========================================
   MALLA INTERACTIVA (PROGRESO)
   ========================================= */
.progreso-header {
    margin-bottom: 32px;
}
.progreso-header h2 {
    margin: 0 0 10px 0;
    font-size: 20px;
    color: #f8fafc;
}
.progreso-header p {
    color: #94a3b8;
    font-size: 13px;
    line-height: 1.5;
    margin: 0 0 20px 0;
}
.progreso-stats {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 15px;
}
.stat-box {
    background: rgba(255, 255, 255, 0.03);
    padding: 10px 15px;
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    min-width: 90px;
}
.stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #38bdf8;
    margin-bottom: 4px;
}
.stat-label {
    font-size: 10px;
    text-transform: uppercase;
    color: #64748b;
    letter-spacing: 0.05em;
}
.progress-bar-container {
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 999px;
    overflow: hidden;
}
.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #38bdf8, #818cf8);
    border-radius: 999px;
    transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
.malla-scroll-wrapper {
    overflow-x: auto;
    padding-bottom: 15px;
    -webkit-overflow-scrolling: touch;
    
    /* Break out of container trick */
    width: 100vw;
    margin-left: calc(-50vw + 50%);
    padding-left: max(20px, calc((100vw - 1400px) / 2));
    padding-right: max(20px, calc((100vw - 1400px) / 2));
    box-sizing: border-box;
}

@media (min-width: 1024px) {
    .malla-scroll-wrapper {
        width: calc(100vw - 290px);
        margin-left: calc(145px - 50vw + 50%);
        padding-left: max(50px, calc((100vw - 290px - 1400px) / 2));
        padding-right: max(50px, calc((100vw - 290px - 1400px) / 2));
    }
}
@media (min-width: 1600px) {
    .malla-scroll-wrapper {
        padding-left: max(50px, calc((100vw - 290px - 1700px) / 2));
        padding-right: max(50px, calc((100vw - 290px - 1700px) / 2));
    }
}

/* Scrollbar siempre visible para que no parezca que se corta */
.malla-scroll-wrapper::-webkit-scrollbar {
    height: 10px;
}
.malla-scroll-wrapper::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
    border-radius: 10px;
}
.malla-scroll-wrapper::-webkit-scrollbar-thumb {
    background: rgba(56, 189, 248, 0.4);
    border-radius: 10px;
}
.malla-scroll-wrapper::-webkit-scrollbar-thumb:hover {
    background: rgba(56, 189, 248, 0.8);
}

.malla-grid {
    display: flex;
    gap: 12px;
    min-width: max-content;
    padding-right: 20px; /* Safe padding that browsers usually respect in flex */
}
.malla-columna {
    display: flex;
    flex-direction: column;
    gap: 8px;
    width: 160px;
}
.malla-sem-title {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    color: #94a3b8;
    text-align: center;
    margin-bottom: 8px;
}
.malla-ramo-card {
    background: rgba(30, 41, 59, 0.7);
    border: 1px solid rgba(var(--ramo-color), 0.1);
    border-left: 3px solid rgba(var(--ramo-color), 0.8);
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 11px;
    margin-bottom: 8px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
    height: 85px;
    box-sizing: border-box;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}
.malla-ramo-name {

    font-size: 11px;
    letter-spacing: 0.3px;
    font-weight: 600;
    line-height: 1.3;
}
.malla-ramo-card:hover {
    background: rgba(var(--ramo-color), 0.2);
    transform: translateY(-2px);
    opacity: 1 !important;
    filter: grayscale(0) !important;
}

/* Pendiente */
.estado-pendiente {
    opacity: 0.4;
    filter: grayscale(0.5);
}
.estado-pendiente .malla-ramo-name {

    color: rgba(255, 255, 255, 0.9);
}

/* Cursando (Yellow focus) */
.estado-cursando {
    opacity: 1;
    background: rgba(251, 191, 36, 0.15);
    border-color: rgba(251, 191, 36, 0.3);
    border-left: 3px solid #fbbf24;
    box-shadow: 0 0 15px rgba(251, 191, 36, 0.2);
}
.estado-cursando .malla-ramo-name {

    color: #fbbf24;
}

/* Aprobado (Subject color solid) */
.estado-aprobado {
    opacity: 1;
    background: rgba(var(--ramo-color), 0.25);
    border-color: rgba(var(--ramo-color), 0.4);
    border-left: 4px solid rgba(var(--ramo-color), 1);
    box-shadow: 0 0 15px rgba(var(--ramo-color), 0.3);
}
.estado-aprobado .malla-ramo-name {

    color: #ffffff;
    text-shadow: 0 0 5px rgba(var(--ramo-color), 0.5);
}
.malla-ramo-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-left: 5px;
}

/* Estados */
}

}


/* =========================================
   MODO ESTUDIO (POMODORO)
   ========================================= */
.estudio-wrapper {
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 20px;
    padding-bottom: 20px;
}
.estudio-header h2 {
    font-size: 24px;
    color: #f8fafc;
    margin: 0 0 10px 0;
}
.estudio-header p {
    font-size: 14px;
    color: #94a3b8;
    margin-bottom: 30px;
    line-height: 1.5;
}
.estudio-mode-selector {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 40px;
}
.mode-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid transparent;
    color: #94a3b8;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}
.mode-btn.active {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border-color: rgba(255, 255, 255, 0.2);
}

.focus-circle {
    width: 240px;
    height: 240px;
    margin: 0 auto 40px auto;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 4px solid rgba(56, 189, 248, 0.1);
    box-shadow: 0 0 40px rgba(56, 189, 248, 0.05);
    transition: all 0.3s ease;
}
.focus-circle.estudio {
    border-color: rgba(56, 189, 248, 0.3);
    box-shadow: 0 0 40px rgba(56, 189, 248, 0.15);
}
.focus-circle.descanso {
    box-shadow: 0 0 40px rgba(34, 197, 94, 0.15);
}
.focus-circle.pulsing.estudio {
    animation: glowPulse 2s infinite alternate;
}
.focus-circle.pulsing.descanso {
    animation: glowPulseDescanso 2s infinite alternate;
}

@keyframes glowPulse {
    0% { box-shadow: 0 0 20px rgba(56, 189, 248, 0.1); }
    100% { box-shadow: 0 0 60px rgba(56, 189, 248, 0.4); border-color: rgba(56, 189, 248, 0.6); }
}
@keyframes glowPulseDescanso {
    0% { box-shadow: 0 0 20px rgba(34, 197, 94, 0.1); }
    100% { box-shadow: 0 0 60px rgba(34, 197, 94, 0.4); border-color: rgba(34, 197, 94, 0.6); }
}

.focus-time {
    font-size: 56px;
    font-weight: 800;
    color: #fff;
    letter-spacing: -0.02em;
    font-variant-numeric: tabular-nums;
}
.focus-label {
    font-size: 11px;
    letter-spacing: 0.3px;
    font-weight: 700;
    color: #94a3b8;
    letter-spacing: 0.1em;
    margin-top: 5px;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.estudio-controls {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 30px;
    margin-left: auto;
    margin-right: auto;
    width: fit-content;
}
.estudio-btn {
    padding: 14px 24px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: transform 0.1s, opacity 0.2s;
}
.estudio-btn:active { transform: scale(0.95); }
.btn-start {
    background: #38bdf8;
    color: #0f172a;
    box-shadow: 0 4px 14px rgba(56, 189, 248, 0.3);
}
.btn-pause {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.btn-reset {
    background: transparent;
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.cronometro-shell {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    padding: 0;
}

.cronometro-page {
    min-height: 60vh;
}

.cronometro-spacer {
    width: 100%;
    height: 118px;
}

.cronometro-mode-switch {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cronometro-mode-btn {
    width: 42px;
    height: 42px;
    padding: 0;
    border: 0;
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    background: transparent;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
    cursor: pointer;
}

.cronometro-mode-btn.active {
    background: rgba(56, 189, 248, 0.16);
    color: #bae6fd;
    box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.22);
}

.cronometro-display-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 0;
    width: 100%;
    margin: 0 0 20px;
    padding: 0;
}

.cronometro-display {
    display: block;
    width: 100%;
    text-align: center;
    white-space: nowrap;
}

.cronometro-time-input {
    width: 1.15em;
    height: 1em;
    padding: 0;
    border: 0;
    outline: 0;
    background: transparent;
    color: #f8fafc;
    font: inherit;
    font-variant-numeric: tabular-nums;
    text-align: center;
    letter-spacing: -0.04em;
    margin-left: -0.075em;
    margin-right: -0.075em;
    caret-color: #f8fafc;
    vertical-align: baseline;
    appearance: none;
}

.cronometro-time-separator.reloj-sec {
    color: #94a3b8;
    font-size: 0.5em;
    font-weight: 600;
    vertical-align: baseline;
}

.cronometro-time-input.reloj-sec {
    width: 1.15em;
    height: auto;
}

.cronometro-time-input:focus {
    color: #f8fafc;
    background: transparent;
    box-shadow: none;
}

.cronometro-end-time {
    margin-top: 12px;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.03em;
}

.cronometro-date {
    margin: 20px 0 0;
}

.cronometro-config {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 10px;
    margin-top: 2px;
}

.cronometro-field {
    display: flex;
    flex-direction: column;
    gap: 5px;
    color: #94a3b8;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-align: left;
    text-transform: uppercase;
}

.cronometro-field input {
    width: 82px;
    padding: 11px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    border-radius: 10px;
    background: rgba(2, 8, 23, 0.58);
    color: #f8fafc;
    font-size: 15px;
    font-weight: 700;
    outline: none;
    text-align: center;
}

.cronometro-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    min-width: 48px !important;
    height: 48px;
    padding: 0 !important;
    border-radius: 14px;
}

.cronometro-field input:focus {
    border-color: rgba(56, 189, 248, 0.65);
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.1);
}

.cronometro-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 0;
}

.cronometro-actions .estudio-btn {
    min-width: 48px;
}

.cronometro-shell .btn-reset {
    color: #94a3b8;
    border-color: rgba(148, 163, 184, 0.25);
}

@media (max-width: 500px) {
    .cronometro-shell {
        padding: 0;
    }

    .cronometro-mode-btn {
        width: 38px;
        height: 38px;
    }

    .cronometro-display-card {
        margin: 0 0 18px;
    }

    .cronometro-spacer {
        height: 92px;
    }

    .cronometro-config {
        flex-wrap: wrap;
    }

    .cronometro-actions .estudio-btn {
        min-width: 48px;
    }
}

.estudio-social-box {
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 15px;
}
.social-title {
    font-size: 12px;
    font-weight: 700;
    color: #cbd5e1;
    text-transform: uppercase;
    margin-bottom: 5px;
}
.social-desc {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
}

/* =========================================
   RELOJ MUNDIAL / CRONOMETRO (TIME.IS)
   ========================================= */
.reloj-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
}
.reloj-time {
    font-size: 80px;
    font-weight: 800;
    color: #fff;
    line-height: 1;
    font-variant-numeric: tabular-nums;
    letter-spacing: -0.04em;
    text-shadow: 0 0 40px rgba(255,255,255,0.1);
}
.reloj-sec {
    font-size: 40px;
    color: #94a3b8;
    font-weight: 600;
}
.reloj-date {
    font-size: 16px;
    color: #38bdf8;
    text-transform: capitalize;
    font-weight: 600;
    margin-bottom: 20px;
    letter-spacing: 0.05em;
}
.reloj-desc {
    font-size: 13px;
    color: #64748b;
    margin-top: 20px;
}

@media (min-width: 768px) {
    .reloj-time {
        font-size: 160px;
    }
}

/* Timer / cronometro estilo reloj del sistema */
    .tiempo-page {
        width: min(100%, 760px);
        min-height: 60vh;
        margin: 0 auto;
        padding: 34px 16px 48px;
        text-align: center;
    }

    .tiempo-mode-switch {
        display: inline-flex;
        gap: 4px;
        padding: 4px;
        margin-bottom: 54px;
        border: 1px solid rgba(255, 255, 255, 0.08);
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.58);
        box-shadow: 0 10px 30px rgba(2, 8, 23, 0.2);
    }

    .tiempo-mode-btn {
        min-width: 124px;
        padding: 10px 18px;
        border: 0;
        border-radius: 999px;
        background: transparent;
        color: #94a3b8;
        font-size: 13px;
        font-weight: 800;
        cursor: pointer;
        transition: color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    }

    .tiempo-mode-btn.active {
        color: #f8fafc;
        background: rgba(56, 189, 248, 0.16);
        box-shadow: inset 0 0 0 1px rgba(56, 189, 248, 0.3), 0 4px 14px rgba(56, 189, 248, 0.08);
    }

    .tiempo-panel {
        display: none;
    }

    .tiempo-panel.active {
        display: block;
    }

    .tiempo-wheel-picker {
        display: grid;
        grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr) auto minmax(0, 1fr);
        align-items: center;
        gap: clamp(4px, 2vw, 18px);
        max-width: 690px;
        margin: 0 auto 36px;
    }

    .tiempo-wheel {
        position: relative;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 8px;
        min-width: 0;
        touch-action: none;
        cursor: grab;
        user-select: none;
    }

    .tiempo-wheel.is-dragging {
        cursor: grabbing;
    }

    .tiempo-wheel::after {
        display: none;
    }

    .tiempo-wheel-label {
        position: relative;
        z-index: 1;
        margin-bottom: 8px;
        color: #94a3b8;
        font-size: clamp(11px, 1.8vw, 14px);
        font-weight: 700;
    }

    .tiempo-wheel-value {
        position: relative;
        z-index: 1;
        width: 100%;
        min-width: 0;
        height: 42px;
        padding: 0;
        border: 0;
        background: transparent;
        color: #334155;
        font-size: clamp(28px, 5.5vw, 54px);
        font-weight: 800;
        line-height: 1;
        font-variant-numeric: tabular-nums;
        letter-spacing: -0.04em;
        cursor: pointer;
        transition: color 0.2s ease, transform 0.2s ease;
    }

    .tiempo-wheel-value.current {
        height: 76px;
        color: #f8fafc;
        font-size: clamp(44px, 8vw, 82px);
    }

    .tiempo-wheel-value.muted {
        color: rgba(100, 116, 139, 0.55);
    }

    .tiempo-wheel-value:hover {
        color: #bae6fd;
    }

    .tiempo-wheel-colon {
        margin-top: 30px;
        color: #64748b;
        font-size: clamp(26px, 5vw, 50px);
        font-weight: 700;
    }

    .tiempo-presets {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 10px;
        margin-bottom: 34px;
    }

    .tiempo-presets button {
        min-width: 88px;
        padding: 10px 15px;
        border: 1px solid rgba(148, 163, 184, 0.16);
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.52);
        color: #cbd5e1;
        font-size: 13px;
        font-weight: 800;
        cursor: pointer;
        transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
    }

    .tiempo-presets button:hover,
    .tiempo-presets button.selected {
        border-color: rgba(56, 189, 248, 0.45);
        background: rgba(56, 189, 248, 0.12);
        color: #f8fafc;
    }

    .tiempo-primary-actions {
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 12px;
    }

    .tiempo-main-btn {
        min-width: 190px;
        padding: 15px 30px;
        border: 0;
        border-radius: 999px;
        background: linear-gradient(135deg, #38bdf8, #8b5cf6);
        color: #fff;
        font-size: 16px;
        font-weight: 800;
        cursor: pointer;
        box-shadow: 0 10px 28px rgba(56, 189, 248, 0.2);
        transition: transform 0.2s ease, box-shadow 0.2s ease;
    }

    .tiempo-main-btn:hover {
        transform: translateY(-1px);
        box-shadow: 0 14px 32px rgba(56, 189, 248, 0.28);
    }

    .tiempo-reset-btn,
    .tiempo-secondary-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        min-width: 52px;
        height: 52px;
        padding: 0 16px;
        border: 1px solid rgba(148, 163, 184, 0.18);
        border-radius: 999px;
        background: rgba(15, 23, 42, 0.62);
        color: #cbd5e1;
        font-size: 13px;
        font-weight: 800;
        cursor: pointer;
    }

    .tiempo-secondary-btn {
        min-width: 104px;
    }

    .tiempo-secondary-btn:disabled {
        cursor: not-allowed;
        opacity: 0.38;
    }

    .tiempo-end-label {
        min-height: 18px;
        margin-top: 18px;
        color: #94a3b8;
        font-size: 12px;
        font-weight: 700;
        letter-spacing: 0.04em;
    }

    .tiempo-stopwatch-display {
        margin: 44px auto 68px;
    }

    .timer-running-page {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 42px;
    }

    @property --timer-progress {
        syntax: "<number>";
        inherits: false;
        initial-value: 1;
    }

    .timer-progress-ring {
        --timer-progress: 1;
        position: relative;
        width: clamp(276px, 56vw, 410px);
        aspect-ratio: 1;
        display: grid;
        place-items: center;
        border-radius: 50%;
        background: radial-gradient(circle, rgba(56, 189, 248, 0.06) 0, rgba(56, 189, 248, 0.015) 47%, transparent 70%);
        box-shadow: 0 0 34px rgba(56, 189, 248, 0.12);
        animation: timerRingIn 0.5s cubic-bezier(0.22, 1, 0.36, 1);
    }

    .timer-progress-ring::after {
        content: "";
        position: absolute;
        inset: 0;
        border: 1px solid rgba(56, 189, 248, 0.12);
        border-radius: 50%;
        box-shadow: inset 0 0 20px rgba(56, 189, 248, 0.05);
        pointer-events: none;
    }

    .timer-segments {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        overflow: visible;
    }

    .timer-segment {
        fill: none;
        stroke: #38bdf8;
        stroke-width: 1.55;
        stroke-linecap: round;
        opacity: 0.08;
        transition: opacity 0.75s ease, filter 0.75s ease;
    }

    .timer-segment.active {
        opacity: 1;
        filter: drop-shadow(0 0 2px rgba(56, 189, 248, 0.72));
    }

    .timer-progress-ring::before {
        display: none;
    }

    .timer-progress-content {
        position: relative;
        z-index: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
    }

    .timer-progress-label {
        color: #7dd3fc;
        font-size: 16px;
        font-weight: 800;
        letter-spacing: 0.12em;
        text-transform: uppercase;
    }

    .timer-running-display {
        font-size: clamp(52px, 10vw, 96px);
        text-shadow: 0 0 26px rgba(56, 189, 248, 0.12);
    }

    .timer-finish-time {
        color: #94a3b8;
        font-size: 16px;
        font-weight: 700;
    }

    .timer-running-actions {
        margin-top: 0;
    }

    .timer-focus-mode .timer-running-actions {
        display: none;
    }

    .timer-focus-mode .timer-progress-content {
        gap: 0;
    }

    @media (min-width: 768px) {
        .timer-progress-ring {
            width: clamp(360px, 48vw, 540px);
        }

        .timer-segment {
            stroke-width: 2.05;
        }

        .timer-running-display {
            font-size: clamp(68px, 8vw, 104px);
        }
    }

    body.timer-focus-active {
        padding: 0 !important;
        overflow: hidden;
    }

    body.timer-focus-active .container {
        width: 100% !important;
        max-width: none !important;
        margin: 0 !important;
        padding: 0 !important;
    }

    body.timer-focus-active header,
    body.timer-focus-active .tabs-wrapper {
        display: none !important;
    }

    body.timer-focus-active #tab-timer {
        min-height: 100vh;
        display: block !important;
    }

    body.timer-focus-active .timer-running-page {
        min-height: 100vh;
        padding: 0;
    }

    @keyframes timerRingIn {
        from { opacity: 0; transform: scale(0.82); }
        to { opacity: 1; transform: scale(1); }
    }

    .tiempo-laps {
        width: min(100%, 430px);
        margin: 28px auto 0;
    }

    .tiempo-laps:empty {
        display: none;
    }

    .lap-row {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 13px 2px;
        border-bottom: 1px solid rgba(148, 163, 184, 0.1);
    }

    .lap-row--latest {
        border-bottom-color: rgba(99, 102, 241, 0.3);
    }

    .lap-num {
        font-size: 13px;
        color: #475569;
        font-variant-numeric: tabular-nums;
        letter-spacing: 0.02em;
    }

    .lap-row--latest .lap-num {
        color: #818cf8;
    }

    .lap-time {
        font-size: 15px;
        font-variant-numeric: tabular-nums;
        font-weight: 600;
        color: #e2e8f0;
        letter-spacing: 0.04em;
    }

    .lap-row--latest .lap-time {
        color: #c7d2fe;
    }

    @media (max-width: 520px) {
        .tiempo-page {
            padding-inline: 8px;
        }

        .tiempo-mode-switch {
            margin-bottom: 40px;
        }

        .tiempo-mode-btn {
            min-width: 108px;
        }

        .tiempo-wheel-picker {
            gap: 2px;
            margin-bottom: 30px;
        }

        .tiempo-wheel-value.current {
            font-size: clamp(38px, 12vw, 62px);
        }

        .tiempo-wheel::after {
            height: 64px;
        }

        .tiempo-main-btn {
            min-width: 160px;
        }

        .tiempo-stopwatch-display {
            margin-top: 66px;
            margin-bottom: 78px;
        }
    }
@media (min-width: 768px) {
    .reloj-sec {
        font-size: 80px;
    }
    .reloj-date {
        font-size: 24px;
        margin-bottom: 30px;
    }
    .reloj-desc {
        font-size: 18px;
        margin-top: 30px;
    }
}

/* Time.is Clone Styles */
.reloj-header h2 {
    font-size: 28px;
    font-weight: 800;
    text-align: center;
    color: #e2e8f0;
    line-height: 1.2;
    margin-bottom: 5px;
}
.reloj-header p {
    font-size: 15px;
    color: #94a3b8;
    text-align: center;
}
.reloj-cities {
    display: flex;
    gap: 15px;
    margin-top: 30px;
    justify-content: center;
}
.city-box {
    background: rgba(255, 255, 255, 0.05);
    padding: 12px 20px;
    border-radius: 8px;
    min-width: 90px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.city-name {
    font-size: 14px;
    font-weight: 700;
    color: #cbd5e1;
}
.city-time {
    font-size: 22px;
    font-weight: 400;
    color: #fff;
    margin-top: 5px;
    font-variant-numeric: tabular-nums;
}
.clickeable-time {
    cursor: pointer;
    transition: transform 0.2s;
    user-select: none;
}
.clickeable-time:active {
    transform: scale(0.98);
}
.zen-mode .hide-in-zen {
    display: none !important;
}
.zen-mode {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 70vh;
}
@media (min-width: 768px) {
    .reloj-header h2 {
        font-size: 36px;
    }
}

@media (min-width: 768px) {
    .estudio-wrapper {
        min-height: auto;
        padding-top: 30px;
    }
    .focus-circle {
        width: 400px;
        height: 400px;
        margin-top: 20px;
        margin-bottom: 40px;
        border-width: 8px;
    }
    .focus-time {
        font-size: 100px;
    }
    .focus-label {
        font-size: 20px;
        margin-top: 10px;
    }
    .estudio-wrapper .estudio-header h2 {
        font-size: 32px;
    }
    .estudio-wrapper .estudio-header p {
        font-size: 16px;
    }
}

.malla-ramo-card {
    position: relative;
    padding: 18px 10px; /* More vertical padding for absolute numbers */
    height: 85px !important;
    box-sizing: border-box;
}
.ramo-top-right, .ramo-bottom-left, .ramo-bottom-right {
    position: absolute;
    font-size: 8px;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.35);
    font-variant-numeric: tabular-nums;
    pointer-events: none;
    transition: all 0.2s ease;
}
.estado-aprobado .ramo-top-right, 
.estado-aprobado .ramo-bottom-left, 
.estado-aprobado .ramo-bottom-right {
    color: rgba(255, 255, 255, 0.7);
}
.estado-cursando .ramo-top-right, 
.estado-cursando .ramo-bottom-left, 
.estado-cursando .ramo-bottom-right {
    color: rgba(251, 191, 36, 0.7);
}
.ramo-top-right {
    top: 3px;
    right: 5px;
}
.ramo-bottom-left {
    bottom: 3px;
    left: 5px;
}
.ramo-bottom-right {
    bottom: 3px;
    right: 5px;
}
.malla-ramo-name {

    width: 100%;
    text-align: center;
    display: block;
    margin: 0 auto;
    padding: 0 16px;
    word-break: break-word;
}
.malla-ramo-icon {
    position: absolute;
    top: 50%;
    right: 5px;
    transform: translateY(-50%);
}

/* =========================================
   HORIZONTAL TIMELINE
   ========================================= */
.horizontal-timeline-wrapper {
    position: relative;
    width: 100%;
    height: 40px;
    margin-top: -24px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    overflow: visible;
}
.timeline-track {
    position: relative;
    flex: 1;
    height: 2px;
    background: rgba(255, 255, 255, 0.15);
    margin: 0 8px; /* space for arrows */
}
.timeline-track::before {
    content: '';
    position: absolute;
    left: -4px;
    top: -2px;
    border-top: 3px solid transparent;
    border-bottom: 3px solid transparent;
    border-right: 4px solid rgba(255, 255, 255, 0.15);
}
.timeline-track::after {
    content: '';
    position: absolute;
    right: -4px;
    top: -2px;
    border-top: 3px solid transparent;
    border-bottom: 3px solid transparent;
    border-left: 4px solid rgba(255, 255, 255, 0.15);
}
.timeline-center-mark {
    position: absolute;
    left: 50%;
    top: -22px;
    transform: translateX(-50%);
    font-size: 11px;
    letter-spacing: 0.3px;
    color: #cbd5e1;
    font-weight: 700;
    letter-spacing: 0.5px;
    z-index: 10;
}
.timeline-center-line {
    position: absolute;
    left: 50%;
    top: -5px;
    bottom: -5px;
    width: 2px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 2px;
    box-shadow: 0 0 6px rgba(0,0,0,0.8);
    transform: translateX(-50%);
    z-index: 9;
}
.h-dot {
    position: absolute;
    top: -4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(var(--dot-rgb), 1);
    transform: translateX(-50%);
    box-shadow: 0 0 8px rgba(var(--dot-rgb), 0.5);
    cursor: pointer;
    z-index: 15;
}
.h-dot.completed {
    box-shadow: none;
    opacity: 0.4;
    background: rgba(var(--dot-rgb), 0.5);
}
.h-dot.pulsing {
    animation: h-pulse 2s infinite;
}
@keyframes h-pulse {
    0% { box-shadow: 0 0 0 0 rgba(var(--dot-rgb), 0.7); }
    70% { box-shadow: 0 0 0 4px rgba(var(--dot-rgb), 0); }
    100% { box-shadow: 0 0 0 0 rgba(var(--dot-rgb), 0); }
}

.h-dot-multi {
    position: absolute;
    top: -4px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #e2e8f0;
    color: #0f172a;
    font-size: 7.5px;
    font-weight: 900;
    display: flex;
    align-items: center;
    justify-content: center;
    transform: translateX(-50%);
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.4);
    z-index: 15;
}
.h-dot-multi.completed {
    opacity: 0.5;
    box-shadow: none;
}
.h-dot-multi.pulsing {
    animation: h-multi-pulse 2s infinite;
}
@keyframes h-multi-pulse {
    0% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.7); }
    70% { box-shadow: 0 0 0 4px rgba(255, 255, 255, 0); }
    100% { box-shadow: 0 0 0 0 rgba(255, 255, 255, 0); }
}

.btn-clear-cache {
    background: rgba(148, 163, 184, 0.1);
    border: 1px solid rgba(148, 163, 184, 0.2);
    color: #94a3b8;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    vertical-align: middle;
    margin: 0;
}
.btn-clear-cache:hover {
    background: rgba(148, 163, 184, 0.25);
    color: #cbd5e1;
    transform: rotate(15deg);
}
.btn-clear-cache:active {
    transform: scale(0.9) rotate(0deg);
}

/* KANBAN STYLES */
.kanban-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 10px;
}
@media (max-width: 768px) {
    .kanban-grid {
        grid-template-columns: 1fr;
    }
}
.kanban-col {
    background: rgba(30, 41, 59, 0.4);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    display: flex;
    flex-direction: column;
    min-height: 400px;
}
.kanban-col-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 700;
    color: #f1f5f9;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    background: rgba(15, 23, 42, 0.6);
    border-top-left-radius: var(--radius-md);
    border-top-right-radius: var(--radius-md);
}
.kanban-count {
    background: rgba(255, 255, 255, 0.1);
    padding: 2px 8px;
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    font-size: 11px;
    letter-spacing: 0.3px;
}
.kanban-task-list {
    padding: 12px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow-y: auto;
}
.kanban-task-card {
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.kanban-task-card:hover {
    transform: translateY(-3px);
    background: rgba(30, 41, 59, 0.8);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}
.kanban-task-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 8px;
}
.kanban-delete-btn {
    background: transparent;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    border-radius: 6px;
    transition: all 0.2s;
    opacity: 0.3;
    display: flex;
    align-items: center;
    justify-content: center;
}
.kanban-task-card:hover .kanban-delete-btn {
    opacity: 1;
}
.kanban-delete-btn:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}
.kanban-task-title {
    font-size: 14px;
    font-weight: 700;
    color: #f8fafc;
    flex: 1;
}
.kanban-task-desc {
    font-size: 12px;
    color: #94a3b8;
    line-height: 1.5;
}
.kanban-task-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 4px;
    padding-top: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}
.kanban-task-actions button {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid transparent;
    color: #cbd5e1;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}
.kanban-task-actions button:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.1);
    color: #fff;
    transform: translateY(-1px);
}

@keyframes pulse-red {
    0% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.7); }
    70% { box-shadow: 0 0 0 10px rgba(239, 68, 68, 0); }
    100% { box-shadow: 0 0 0 0 rgba(239, 68, 68, 0); }
}

@keyframes ai-spin {
    100% { transform: rotate(360deg); }
}
.ai-spin {
    animation: ai-spin 1.5s linear infinite;
}

.ui-feedback-modal {
    position: fixed;
    inset: 0;
    z-index: 1300;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 18px;
    background: rgba(2, 6, 23, 0.78);
    backdrop-filter: blur(12px);
}
.ui-feedback-card {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 20px;
    width: min(360px, 92%);
    padding: 28px 22px 22px;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 20px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6);
}
.ui-feedback-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: #38bdf8;
    background: rgba(56, 189, 248, 0.14);
}
.ui-feedback-icon.warning { color: #fbbf24; background: rgba(245, 158, 11, 0.14); }
.ui-feedback-icon.danger { color: #f87171; background: rgba(239, 68, 68, 0.14); }
.ui-feedback-content h2 { margin: 3px 0 7px; color: #f8fafc; font-size: 20px; }
.ui-feedback-content p { margin: 0; color: #cbd5e1; font-size: 13px; line-height: 1.55; }
.ui-feedback-close { position: absolute; top: 14px; right: 15px; border: 0; background: transparent; color: #94a3b8; cursor: pointer; font-size: 26px; line-height: 1; }
.ui-feedback-actions { display: flex; width: 100%; gap: 12px; margin-top: 4px; }
.ui-feedback-actions button { flex: 1; }
.ui-feedback-actions button { border-radius: 8px; cursor: pointer; padding: 9px 14px; font-weight: 700; }
.ui-feedback-primary { border: 1px solid rgba(56, 189, 248, 0.35); background: linear-gradient(135deg, #38bdf8, #2563eb); color: #fff; }
.ui-feedback-secondary { border: 1px solid rgba(255,255,255,0.12); background: rgba(255,255,255,0.06); color: #cbd5e1; }
.ui-feedback-danger { border: 1px solid rgba(248,113,113,0.35); background: rgba(239,68,68,0.16); color: #fca5a5; }

/* MODERN RADIO STYLES */
.radio-card {
    position: relative;
    margin: 40px auto 0 auto;
    width: 100%;
    max-width: 320px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
}
.radio-
.radio-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 4px 10px rgba(139, 92, 246, 0.3);
}
.radio-title {
    font-size: 14.5px;
    font-weight: 700;
    color: #f1f5f9;
}
.radio-subtitle {
    font-size: 11px;
    letter-spacing: 0.3px;
    color: #94a3b8;
    margin-top: 2px;
}
.radio-controls {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 20px;
}
.radio-btn-play {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #fff;
    color: #0f172a;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: transform 0.2s;
}
.radio-btn-play:hover {
    transform: scale(1.05);
}
.radio-volume {
    -webkit-appearance: none;
    width: 100%;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    outline: none;
}
.radio-volume::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
}

/* VISUALIZER ANIMATION */
.radio-visualizer {
    position: absolute;
    top: 20px;
    right: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    height: 16px;
    transition: opacity 0.3s ease;
}
.radio-visualizer .bar {
    width: 4px;
    height: 16px;
    background: linear-gradient(180deg, #38bdf8, #a855f7);
    border-radius: 4px;
    transform-origin: bottom;
    animation: eq-bounce 1.2s ease-in-out infinite;
}
.radio-visualizer .bar:nth-child(1) { animation-duration: 0.9s; animation-delay: 0.1s; }
.radio-visualizer .bar:nth-child(2) { animation-duration: 1.1s; animation-delay: 0.4s; }
.radio-visualizer .bar:nth-child(3) { animation-duration: 0.8s; animation-delay: 0.2s; }
.radio-visualizer .bar:nth-child(4) { animation-duration: 1.2s; animation-delay: 0.5s; }
.radio-visualizer .bar:nth-child(5) { animation-duration: 1.0s; animation-delay: 0.3s; }
.radio-visualizer .bar:nth-child(6) { animation-duration: 0.9s; animation-delay: 0.6s; }
.radio-visualizer .bar:nth-child(7) { animation-duration: 1.3s; animation-delay: 0.1s; }
.radio-visualizer .bar:nth-child(8) { animation-duration: 1.1s; animation-delay: 0.4s; }

@keyframes eq-bounce {
    0%, 100% { transform: scaleY(0.3); }
    50% { transform: scaleY(1); }
}

/* Corrector IA - Yellow dots for the learning capsule */
#corrector-explicacion .status-dot {
    background: #fbbf24 !important;
    box-shadow: 0 0 6px #f59e0b !important;
}




/* ==========================================================================
   SIDEBAR LAYOUT (DASHBOARD STYLE)
   ========================================================================== */

/* Hamburger Button */
.btn-sidebar-toggle {
    display: none;
    background: rgba(15, 23, 42, 0.65);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    color: #f8fafc;
    cursor: pointer;
    padding: 11px;
    margin-right: 0;
    border-radius: 12px;
    transition: background 0.2s;
}
.btn-sidebar-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}
.brand-meta {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

/* Sidebar Overlay for Mobile */
.sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 9997;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}
.sidebar-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

/* Base Tab Button adjustments for Sidebar */
.tab-btn {
    justify-content: flex-start !important;
    padding: 12px 18px !important;
    border-radius: 12px !important;
    width: 100%;
    margin-bottom: 4px;
    text-align: left;
}

/* ESCRITORIO (PC): Sidebar Fija a la izquierda */
@media (min-width: 1024px) {
    body {
        padding-left: 290px;
    }
    
    .tabs-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 290px;
    height: 100vh;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-right: 1px solid rgba(255, 255, 255, 0.08);
    padding: 50px 24px 30px 24px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 10px 0 30px rgba(0, 0, 0, 0.4);
    box-sizing: border-box;
}
    
    .tabs {
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }
    
    /* El header original debe ajustarse si estaba absolute/fixed */
    
    
    .container {
        margin: 40px auto 40px auto !important;
        max-width: 1450px !important;
        padding: 0 50px !important;
        box-sizing: border-box;
    }
}

/* CELULAR: Drawer lateral oculto */
@media (max-width: 1023px) {
    header {
        display: flex;
        align-items: center;
        padding: 16px 16px;
        position: fixed; /* Fixed so it doesn't take up space, or sticky */
        top: 0;
        left: 0;
        z-index: 900;
        background: transparent;
        pointer-events: none; /* Let clicks pass through empty areas */
    }
    
    .mobile-header-content {
        pointer-events: auto; /* Enable clicks on the button */
    }

    .btn-sidebar-toggle {
        display: block;
    }
    
    .tabs-wrapper {
    position: fixed;
    top: 0;
    left: -320px; /* Hidden by default */
    width: 290px;
    height: 100vh;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    padding: 50px 28px 30px 28px;
    transition: left 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 9998;
    overflow-y: auto;
    box-shadow: 10px 0 40px rgba(0, 0, 0, 0.8);
    box-sizing: border-box;
}
    
    .tabs-wrapper.open {
        left: 0;
    }
    
    .tabs {
        display: flex;
        flex-direction: column;
        align-items: stretch;
    }
    
    
}

/* Mobile Header */


.mobile-header-content {
    display: flex;
    align-items: center;
    gap: 15px;
}
.mobile-title {
    font-size: 18px;
    font-weight: 800;
    background: linear-gradient(to right, #ffffff, #93c5fd);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Sidebar Branding adjustments */
.tabs-wrapper .brand-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin-bottom: 30px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
}
.tabs-wrapper .brand-meta h1 {
    font-size: 22px;
    line-height: 1.25;
    margin-bottom: 8px;
}
.tabs-wrapper .brand-meta p {
    margin-top: 4px;
    flex-wrap: wrap;
}



/* Restriccion de ancho solo para los buscadores dentro de las control cards en PC */
@media (min-width: 1024px) {
    .search-field {
        max-width: 800px;
    }
}




/* --- LOFI STYLES --- */
.focus-circle {
    position: relative;
    z-index: 1;
    /* transition border-color specifically to transparent cyan, not black */
    transition: all 0.5s ease;
}

/* Base pseudo-elements always exist but are invisible */
.focus-circle::before {
    content: '';
    position: absolute;
    inset: -7px; /* Aumentado 3px en total */ /* Move exactly over the border (4px default) */
    z-index: -1;
    background: conic-gradient(from 0deg, #a855f7, #ec4899, #38bdf8, #8b5cf6, #a855f7);
    animation: lofiSpin 4s linear infinite;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.5s ease;
    
    /* CSS Mask trick to punch a hole in the center */
    padding: 7px;
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    box-sizing: border-box;
}

@media (min-width: 1024px) {
    .focus-circle::before {
        inset: -11px;
        padding: 11px;
    }
}

/* Active Lofi Styles */
.focus-circle.lofi-active {
    border-color: rgba(56, 189, 248, 0) !important; /* Avoid black flash by fading to transparent cyan */
    box-shadow: 0 0 40px rgba(168, 85, 247, 0.2) !important;
}

.focus-circle.lofi-active::before {
    opacity: 1;
}

@keyframes lofiSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.focus-circle.lofi-active.pulsing {
    animation: glowPulseLofi 2s infinite alternate !important;
}

@keyframes glowPulseLofi {
    0% { box-shadow: 0 0 20px rgba(168, 85, 247, 0.3); }
    100% { box-shadow: 0 0 60px rgba(236, 72, 153, 0.6), 0 0 20px rgba(56, 189, 248, 0.4); }
}

/* Lofi Text Animation */
.lofi-text-anim {
    background: linear-gradient(to right, #a855f7, #38bdf8, #ec4899, #8b5cf6, #a855f7);
    background-size: 200% auto;
    color: transparent;
    -webkit-background-clip: text;
    background-clip: text;
    animation: lofiTextShine 4s linear infinite;
    font-weight: 700;
    letter-spacing: 2px;
}

@keyframes lofiTextShine {
    to {
        background-position: 200% center;
    }
}

/* Glossy Icon Buttons */
.estudio-btn-glossy {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(30, 41, 59, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #e2e8f0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.estudio-btn-glossy:hover {
    transform: translateY(-2px) scale(1.05);
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.estudio-btn-glossy:active {
    transform: translateY(1px) scale(0.95);
}

.estudio-btn-glossy.btn-start {
    background: rgba(56, 189, 248, 0.15);
    border-color: rgba(56, 189, 248, 0.3);
    color: #38bdf8;
    box-shadow: 0 4px 20px rgba(56, 189, 248, 0.2);
}

.estudio-btn-glossy.btn-start:hover {
    background: rgba(56, 189, 248, 0.25);
    box-shadow: 0 6px 25px rgba(56, 189, 248, 0.3);
}

.estudio-btn-glossy.btn-pause {
    background: rgba(244, 63, 94, 0.15); /* Rose-500 tint */
    border-color: rgba(244, 63, 94, 0.3);
    color: #f43f5e;
    box-shadow: 0 4px 20px rgba(244, 63, 94, 0.2);
}

.estudio-btn-glossy.btn-pause:hover {
    background: rgba(244, 63, 94, 0.25);
    box-shadow: 0 6px 25px rgba(244, 63, 94, 0.3);
}

.estudio-btn-glossy.btn-reset {
    color: #94a3b8;
}

.estudio-btn-glossy.btn-reset:hover {
    color: #fff;
    background: rgba(255, 255, 255, 0.15);
}

.pwa-install-btn {
    background: rgba(56, 189, 248, 0.12);
    border: 1px solid rgba(56, 189, 248, 0.28);
    color: #38bdf8;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    padding: 0;
    margin: 0;
    flex: 0 0 22px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    vertical-align: middle;
}
.pwa-install-btn[hidden] {
    display: none;
}
.pwa-install-btn:hover {
    background: rgba(56, 189, 248, 0.24);
    border-color: rgba(56, 189, 248, 0.5);
}
.pwa-install-btn:active {
    transform: scale(0.9);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}
.spin {
    animation: spin 1s linear infinite;
}

@keyframes pulseDotDynamic {
    0%, 100% { opacity: 1; transform: scale(1); box-shadow: 0 0 6px currentColor; }
    50% { opacity: 0.6; transform: scale(0.85); box-shadow: 0 0 2px currentColor; }
}
/* Estado de lineas Metro */
#metro-lineas-grid {
    display: grid !important;
    gap: 0 !important;
}

.metro-line-list {
    column-count: 1;
}

.metro-tab-detail {
    display: inline-block;
    width: 100%;
    box-sizing: border-box;
    margin: 0 0 10px;
    break-inside: avoid;
    padding: 12px 13px;
    background: #181f32;
    border: 1px solid rgba(148, 163, 184, 0.19);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease;
}

.metro-tab-detail:hover {
    background: #1b2336;
    border-color: rgba(148, 163, 184, 0.25);
    box-shadow: 0 6px 18px -6px rgba(0, 0, 0, 0.35);
    transform: translateY(-2px);
}

.metro-tab-detail.is-open {
    background: #1b2439;
    border-color: rgba(148, 163, 184, 0.28);
}

.metro-tab-detail:focus-visible {
    outline: 2px solid #7dd3fc;
    outline-offset: 2px;
}

.metro-line-list > .metro-tab-detail:first-child {
    padding-top: 14px;
}

.metro-tab-detail-head {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    column-gap: 10px;
    row-gap: 8px;
}

.metro-tab-line-mark {
    grid-row: 1 / 3;
    display: grid;
    place-items: center;
    width: 36px;
    height: 36px;
    border-radius: 7px;
    box-shadow: 0 3px 10px color-mix(in srgb, var(--metro-line-color) 38%, transparent);
    color: #fff;
    font-size: 11px;
    font-weight: 900;
}

.metro-tab-detail-title {
    grid-column: 2;
    grid-row: 1;
    display: grid;
    gap: 4px;
    min-width: 0;
}

.metro-tab-detail-title small {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    color: #64748b;
    font-size: 10px;
    font-weight: 750;
    text-transform: uppercase;
}

.metro-route {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 650;
}

.metro-route span {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.metro-route svg {
    flex: 0 0 auto;
    color: var(--metro-line-color);
}

.metro-route-single {
    color: #e2e8f0;
    font-size: 12px;
    font-weight: 650;
}

.metro-line-status-dot {
    width: 7px;
    height: 7px;
    box-shadow: 0 0 0 3px color-mix(in srgb, currentColor 16%, transparent);
}

.metro-line-state-control {
    grid-column: 3;
    grid-row: 1 / 3;
    display: inline-flex;
    align-items: center;
    align-self: center;
    justify-self: end;
    gap: 10px;
}

.metro-line-state {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 5px 9px;
    border: 1px solid;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 750;
    white-space: nowrap;
}

.estado-dot-anim {
    display: block;
    width: 6px;
    height: 6px;
    flex: 0 0 auto;
    border-radius: 50%;
    background: currentColor;
    animation: pulseDotDynamic 2.2s infinite ease-in-out;
}

.metro-state-chevron {
    flex: 0 0 auto;
    color: #94a3b8;
    transition: transform 160ms ease;
}

.metro-tab-detail.is-open .metro-state-chevron {
    transform: rotate(180deg);
}

.metro-tab-metrics {
    grid-column: 2;
    grid-row: 2;
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    color: #64748b;
    font-size: 11px;
    white-space: nowrap;
}

.metro-tab-metrics span + span {
    padding-left: 10px;
    border-left: 1px solid rgba(148, 163, 184, 0.18);
}

.metro-tab-alerts {
    position: relative;
    padding: 3px 0 0 16px;
    background: transparent;
    border: 0;
    border-radius: 0;
}

.metro-tab-alerts::before,
.metro-line-status-card::before {
    content: '';
    position: absolute;
    top: 2px;
    bottom: 2px;
    left: 0;
    width: 3px;
    border-radius: 999px;
}

.metro-tab-alerts::before {
    background: linear-gradient(#fca5a5, #ef4444);
    box-shadow: 0 0 8px rgba(248, 113, 113, 0.36);
}

.metro-tab-alerts-title {
    margin-bottom: 9px;
    color: #fca5a5;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
}

.metro-tab-alerts-list {
    display: grid;
    gap: 7px;
}

.metro-tab-alert-item {
    padding: 4px 0 7px;
    color: #cbd5e1;
    background: transparent;
    border-bottom: 0;
    font-size: 11px;
    line-height: 1.4;
}

.metro-tab-alert-meta {
    display: flex;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 3px;
}

.metro-tab-alert-meta strong {
    color: #fecaca;
}

.metro-tab-alert-meta span {
    color: #64748b;
    font-size: 10px;
    white-space: nowrap;
}

.metro-tab-alert-item:last-child {
    padding-bottom: 7px;
}

@media (max-width: 480px) {
    .metro-tab-detail {
        padding: 13px;
    }

    .metro-tab-detail-head {
        grid-template-columns: auto minmax(0, 1fr) auto;
    }

    .metro-tab-metrics {
        grid-column: 2;
        margin-left: 0;
    }

    .metro-route {
        gap: 6px;
    }
}

.metro-line-status-card {
    position: relative;
    display: block;
    padding: 2px 0 3px 16px;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0;
}

.metro-line-status-card::before {
    background: linear-gradient(#6ee7b7, #10b981);
    box-shadow: 0 0 8px rgba(52, 211, 153, 0.32);
}

.metro-line-service-detail {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.metro-line-status-card.is-operational {
}

.metro-line-status-card.is-closed {
}

.metro-line-status-card.is-closed::before {
    background: linear-gradient(#fde68a, #f59e0b);
    box-shadow: 0 0 8px rgba(251, 191, 36, 0.32);
}

.metro-line-status-copy {
    display: grid;
    gap: 3px;
    min-width: 0;
    color: #bbf7d0;
    font-size: 12px;
    line-height: 1.35;
}

.metro-line-status-copy strong {
    color: #ecfdf5;
    font-size: 13px;
}

.metro-line-status-kicker {
    color: #6ee7b7;
    font-size: 9.5px;
    font-weight: 800;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.metro-line-status-card.is-closed .metro-line-status-copy {
    color: #fde68a;
}

.metro-line-status-card.is-closed .metro-line-status-copy strong {
    color: #fffbeb;
}

.metro-line-status-card.is-closed .metro-line-status-kicker {
    color: #fcd34d;
}

.clima-refresh-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    color: #94a3b8;
    background: transparent;
    border: 0;
    cursor: pointer;
    transition: color 160ms ease, transform 160ms ease;
}

.clima-refresh-button:hover,
.clima-refresh-button:focus-visible {
    color: #7dd3fc;
    outline: none;
}

.clima-refresh-button:active {
    transform: rotate(45deg);
}

/* Fix Chrome Autofill white background breaking glassmorphism */
input:-webkit-autofill,
input:-webkit-autofill:hover, 
input:-webkit-autofill:focus, 
input:-webkit-autofill:active{
    transition: background-color 5000s ease-in-out 0s;
    -webkit-text-fill-color: #f8fafc !important;
}
