/* Tipografía Base */
body {
    font-family: 'Inter', sans-serif;
}
h1, h2, h3, .font-mono {
    font-family: 'Fira Code', monospace;
}

/* Línea de Tiempo en Experiencia */
.timeline-item {
    position: relative;
    padding-left: 3rem;
    padding-bottom: 2rem;
    border-left-width: 2px;
}
.timeline-item:last-child {
    border-left-color: transparent;
}
.timeline-dot {
    position: absolute;
    left: -0.6rem;
    top: 0;
    height: 1.2rem;
    width: 1.2rem;
    border-width: 2px;
    border-radius: 50%;
}

/* --- Animación de logos de fondo --- */
#hero-logos {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}
.logo-bg {
    position: absolute;
    display: flex;
    align-items: center;
    justify-content: center;
    list-style: none;
    background-color: rgba(156, 163, 175, 0.15); /* Fondo para modo claro */
    border-radius: 50%;
    bottom: -150px;
    animation: float 25s linear infinite;
}
.dark .logo-bg {
    background-color: rgba(255, 255, 255, 0.07); /* Fondo para modo oscuro */
}
.logo-bg img {
    width: 60%;
    height: 60%;
    object-fit: contain;
}
.logo-bg:nth-child(1) { left: 25%; width: 80px; height: 80px; animation-delay: 0s; }
.logo-bg:nth-child(2) { left: 10%; width: 30px; height: 30px; animation-delay: 1s; animation-duration: 6s; }
.logo-bg:nth-child(3) { left: 70%; width: 30px; height: 30px; animation-delay: 0s; }
.logo-bg:nth-child(4) { left: 40%; width: 60px; height: 60px; animation-delay: 0s; animation-duration: 9s; }
.logo-bg:nth-child(5) { left: 65%; width: 30px; height: 30px; animation-delay: 0s; }
.logo-bg:nth-child(6) { left: 75%; width: 110px; height: 110px; animation-delay: 0s;}
.logo-bg:nth-child(7) { left: 35%; width: 90px; height: 90px; animation-delay: 0s; }
.logo-bg:nth-child(8) { left: 50%; width: 35px; height: 35px; animation-delay: 1s; animation-duration: 22.5s; }
.logo-bg:nth-child(9) { left: 20%; width: 25px; height: 25px; animation-delay: 1s; animation-duration: 17.5s; }
.logo-bg:nth-child(10) { left: 85%; width: 70px; height: 70px; animation-delay: 0s; animation-duration: 5.5s; }
.logo-bg:nth-child(11) { left: 5%; width: 50px; height: 50px; animation-delay: 1s; animation-duration: 10s; }
.logo-bg:nth-child(12) { left: 90%; width: 40px; height: 40px; animation-delay: 1s; animation-duration: 15s; }
.logo-bg:nth-child(13) { left: 30%; width: 45px; height: 45px; animation-delay: 0.5s; animation-duration: 14s; }
.logo-bg:nth-child(14) { left: 60%; width: 75px; height: 75px; animation-delay: 0s; animation-duration: 7.5s; }
.logo-bg:nth-child(15) { left: 15%; width: 35px; height: 35px; animation-delay: 0s; animation-duration: 11s; }

@keyframes float {
    0% { transform: translateY(0) rotate(0deg); opacity: 0; }
    25% { opacity: 0.2; }
    50% { transform: translateY(-50vh) rotate(360deg); }
    75% { opacity: 0.2; }
    100% { transform: translateY(-120vh) rotate(720deg); opacity: 0; }
}

/* Estado del menú móvil */
body.menu-open, body.modal-open {
    overflow: hidden;
}

/* Estilos del filtro de proyectos */
.filter-btn {
    padding: 0.5rem 1rem;
    border-radius: 9999px;
    transition: all 0.2s ease-in-out;
    border: 2px solid transparent;
    font-weight: 600;
}
.filter-btn:hover {
    color: #3b82f6; /* text-blue-600 */
}
.filter-btn.active {
    background-color: #3b82f6; /* bg-blue-600 */
    color: white;
}
.dark .filter-btn:hover {
    color: #60a5fa; /* dark:text-blue-400 */
}
.dark .filter-btn.active {
    background-color: #60a5fa; /* dark:bg-blue-400 */
    color: #1e293b; /* dark:text-slate-900 */
}

/* --- Estilos para el Menú Desplegable --- */
.dropdown {
    position: relative;
    display: inline-block;
}
.dropdown-btn {
    padding-right: 2.5rem !important;
}
.dropdown-btn.active {
    background-color: #3b82f6;
    color: white;
}
.dark .dropdown-btn.active {
    background-color: #60a5fa;
    color: #1e293b;
}
.dropdown-menu {
    position: absolute;
    display: none;
    top: 100%;
    left: 0;
    margin-top: 0.5rem;
    background-color: white;
    min-width: 200px;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    border: 1px solid #e5e7eb;
    z-index: 50;
    max-height: 300px;
    overflow-y: auto;
    scrollbar-width: thin;
}
.dark .dropdown-menu {
    background-color: #1e293b;
    border-color: #334155;
}

/* ***** INICIO DEL CAMBIO: Estilos para la búsqueda en el dropdown ***** */
.dropdown-search-container {
    padding: 0.5rem;
    border-bottom: 1px solid #e5e7eb;
}
.dark .dropdown-search-container {
    border-bottom-color: #334155;
}
.dropdown-search-input {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border-radius: 0.375rem;
    border: 1px solid #d1d5db;
    background-color: #fff;
    color: #1f2937;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}
.dark .dropdown-search-input {
    background-color: #334155;
    border-color: #4b5563;
    color: #e5e7eb;
}
.dropdown-search-input:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.4);
}
.dark .dropdown-search-input:focus {
    border-color: #60a5fa;
    box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.4);
}
/* ***** FIN DEL CAMBIO ***** */

.dropdown-item {
    display: block;
    width: 100%;
    text-align: left;
    padding: 0.75rem 1rem;
    font-weight: 500;
    transition: background-color 0.2s;
}
.dropdown-item:hover {
    background-color: #f3f4f6;
}
.dark .dropdown-item:hover {
    background-color: #334155;
}

/* --- Estilos para la Barra Deslizadora del Menú --- */
.dropdown-menu::-webkit-scrollbar { width: 8px; }
.dropdown-menu::-webkit-scrollbar-thumb { border-radius: 10px; }
.dropdown-menu { scrollbar-color: #94a3b8 #f1f5f9; }
.dropdown-menu::-webkit-scrollbar-track { background: #f1f5f9; }
.dropdown-menu::-webkit-scrollbar-thumb { background-color: #94a3b8; }
.dark .dropdown-menu { scrollbar-color: #64748b #334155; }
.dark .dropdown-menu::-webkit-scrollbar-track { background: #334155; }
.dark .dropdown-menu::-webkit-scrollbar-thumb { background-color: #64748b; }


/* Modal de Proyecto */
#project-modal { transition: opacity 0.3s ease; }
#modal-content-box { transition: transform 0.3s ease, opacity 0.3s ease; }

/* --- Estilos para la Barra Deslizadora del Carrusel --- */
#carousel-container { cursor: grab; scrollbar-width: thin; }
#carousel-container:active { cursor: grabbing; }
#carousel-container::-webkit-scrollbar { height: 8px; }
#carousel-container::-webkit-scrollbar-thumb { background-color: #60a5fa; border-radius: 10px; }
#carousel-container { scrollbar-color: #60a5fa #e2e8f0; }
#carousel-container::-webkit-scrollbar-track { background: #e2e8f0; border-radius: 10px; }
#carousel-container::-webkit-scrollbar-thumb { border: 2px solid #e2e8f0; }
.dark #carousel-container { scrollbar-color: #60a5fa #374151; }
.dark #carousel-container::-webkit-scrollbar-track { background: #374151; }
.dark #carousel-container::-webkit-scrollbar-thumb { border-color: #374151; }

/* --- Estilos para la Barra Deslizadora del Modal de Proyectos --- */
#modal-content-box > .overflow-y-auto::-webkit-scrollbar { width: 8px; }
#modal-content-box > .overflow-y-auto::-webkit-scrollbar-thumb { border-radius: 10px; }
#modal-content-box > .overflow-y-auto { scrollbar-color: #94a3b8 #f1f5f9; }
#modal-content-box > .overflow-y-auto::-webkit-scrollbar-track { background: #f1f5f9; }
#modal-content-box > .overflow-y-auto::-webkit-scrollbar-thumb { background-color: #94a3b8; }
.dark #modal-content-box > .overflow-y-auto { scrollbar-color: #64748b #334155; }
.dark #modal-content-box > .overflow-y-auto::-webkit-scrollbar-track { background: #334155; }
.dark #modal-content-box > .overflow-y-auto::-webkit-scrollbar-thumb { background-color: #64748b; }

/* --- CAMBIO: Estilos de Etiquetas de Categoría (Colores Suaves) --- */
.tag-base {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 9999px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid transparent;
    line-height: 1.5;
}

/* Power BI y SQL (Azul) */
.tag-power-bi, .tag-sql {
    background-color: #dbeafe; /* blue-100 */
    color: #1d4ed8; /* blue-700 */
}
.dark .tag-power-bi, .dark .tag-sql {
    background-color: #1e3a8a; /* blue-900 */
    color: #93c5fd; /* blue-300 */
}

/* Python (Dorado) */
.tag-python {
    background-color: #fef9c3; /* yellow-100 */
    color: #a16207; /* yellow-700 */
}
.dark .tag-python {
    background-color: #78350f; /* amber-900 */
    color: #fcd34d; /* amber-300 */
}

/* Web y JavaScript (Verde azulado) */
.tag-web {
    background-color: #d1fae5; /* emerald-100 */
    color: #047857; /* emerald-700 */
}
.dark .tag-web {
    background-color: #064e3b; /* emerald-900 */
    color: #6ee7b7; /* emerald-300 */
}

/* Excel (Verde) */
.tag-excel {
    background-color: #dcfce7; /* green-100 */
    color: #166534; /* green-700 */
}
.dark .tag-excel {
    background-color: #14532d; /* green-900 */
    color: #86efac; /* green-300 */
}

/* Etiqueta genérica (Gris) */
.tag-generic {
    background-color: #e5e7eb; /* gray-200 */
    color: #4b5563; /* gray-600 */
}
.dark .tag-generic {
    background-color: #374151; /* gray-700 */
    color: #d1d5db; /* gray-300 */
}

/* --- Estilos para Acordeón de Medidas DAX --- */
.dax-accordion {
    border: 1px solid #e2e8f0; /* slate-200 */
    border-radius: 0.5rem;
    overflow: hidden;
    margin-top: 1rem;
}
.dark .dax-accordion {
    border-color: #334155; /* slate-700 */
}

.dax-accordion-item {
    border-bottom: 1px solid #e2e8f0; /* slate-200 */
}
.dark .dax-accordion-item {
    border-bottom-color: #334155; /* slate-700 */
}
.dax-accordion-item:last-child {
    border-bottom: none;
}

.dax-accordion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem 1rem;
    cursor: pointer;
    background-color: #f8fafc; /* slate-50 */
    transition: background-color 0.2s;
}
.dark .dax-accordion-header {
    background-color: #1e293b; /* slate-800 */
}
.dax-accordion-header:hover {
    background-color: #f1f5f9; /* slate-100 */
}
.dark .dax-accordion-header:hover {
    background-color: #334155; /* slate-700 */
}

.dax-accordion-header h4 {
    font-family: 'Fira Code', monospace;
    font-weight: 600;
    color: #1d4ed8; /* blue-700 */
}
.dark .dax-accordion-header h4 {
    color: #93c5fd; /* blue-300 */
}

.dax-accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease-out;
    background-color: #ffffff;
    padding: 0 1rem;
}
.dark .dax-accordion-content {
    background-color: #0f172a; /* slate-900 */
}

/* ***** ESTE ES EL CAMBIO ***** */
.dax-accordion-content.open {
    max-height: 1200px; /* Aumentado de 500px a 1200px */
    padding: 1rem;
}
/* ***** FIN DEL CAMBIO ***** */

.dax-accordion-content p {
    margin-bottom: 0.75rem;
    font-style: italic;
    color: #475569; /* slate-600 */
}
.dark .dax-accordion-content p {
    color: #94a3b8; /* slate-400 */
}

.dax-accordion-content pre {
    background-color: #1e293b; /* slate-800 */
    color: #e2e8f0; /* slate-200 */
    padding: 1rem;
    border-radius: 0.375rem;
    overflow-x: auto;
    font-family: 'Fira Code', monospace;
    font-size: 0.875rem;
}
.dark .dax-accordion-content pre {
    background-color: #020617; /* slate-950 */
}
