/* ============================================
   HEADER Y MENÚ - DISEÑO INSTITUCIONAL
   Sistema Integral Galápagos - CGREG
   Versión limpia y profesional
   ============================================ */

/* Variables de color institucional */
:root {
    --header-bg: linear-gradient(135deg, #1e3a5f 0%, #2c5282 100%);
    --menu-item-hover: rgba(255, 255, 255, 0.1);
    --menu-item-active: rgba(255, 255, 255, 0.18);
    --menu-item-active-border: #5ba3ff;
    --menu-icon: #b0cde8;
    --menu-icon-active: #ffffff;
    --separator-color: rgba(255, 255, 255, 0.18);
    --shadow-header: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* ============================================
   HEADER
   ============================================ */
#header {
    background: var(--header-bg);
    box-shadow: var(--shadow-header);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

/* ============================================
   MENÚ
   ============================================ */
#header > #menu > .listado {
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
}

#header > #menu > .listado::-webkit-scrollbar {
    height: 4px;
}

#header > #menu > .listado::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

#header > #menu > .listado::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.25);
    border-radius: 2px;
}

/* Items del menú */
#header > #menu > .listado > .item,
#header > #menu > .listado > a.item {
    transition: background-color 0.2s ease;
    border-radius: 6px;
}

#header > #menu > .listado > .item:hover,
#header > #menu > .listado > a.item:hover {
    background: var(--menu-item-hover);
}

#header > #menu > .listado > .item.active,
#header > #menu > .listado > a.item.active {
    background: var(--menu-item-active);
    font-weight: 600;
    position: relative;
}

/* Indicador de item activo - Línea inferior simple */
#header > #menu > .listado > .item.active::after,
#header > #menu > .listado > a.item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 65%;
    height: 3px;
    background: var(--menu-item-active-border);
    border-radius: 3px 3px 0 0;
}

/* Iconos */
#header > #menu > .listado > .item > .item_box,
#header > #menu > .listado > a.item > .item_box {
    color: var(--menu-icon);
    transition: color 0.2s ease;
}

#header > #menu > .listado > .item:hover > .item_box,
#header > #menu > .listado > a.item:hover > .item_box,
#header > #menu > .listado > .item.active > .item_box,
#header > #menu > .listado > a.item.active > .item_box {
    color: var(--menu-icon-active);
}

/* ============================================
   BOTONES AUXILIARES
   ============================================ */
#header > .aux_menu_item {
    border-left: 1px solid var(--separator-color);
}

#header > .aux_menu_item > .item {
    transition: background-color 0.2s ease, color 0.2s ease;
    color: var(--menu-icon);
    border-radius: 6px;
}

#header > .aux_menu_item > .item:hover {
    background: var(--menu-item-hover);
    color: var(--menu-icon-active);
}


/* ============================================
   LAUNCHPAD
   ============================================ */
#launchpad {
    backdrop-filter: blur(6px);
    background: rgba(0, 0, 0, 0.75);
}

#launchpad > #content {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
}

/* Perfil en esquina del launchpad - Diseño natural y sutil */
#launchpad > #content > .launchpad_profile_corner {
    position: absolute;
    top: 1.5em;
    right: 1.5em;
    z-index: 10;
}

#launchpad > #content > .launchpad_profile_corner > .item {
    display: flex;
    align-items: center;
    gap: 0.5em;
    padding: 0.5em 0.75em;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.08);
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
    color: #495057;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

#launchpad > #content > .launchpad_profile_corner > .item:hover {
    background: #ffffff;
    border-color: rgba(0, 0, 0, 0.12);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

#launchpad > #content > .launchpad_profile_corner > .item > .item_label {
    font-weight: 500;
    font-size: 0.9em;
    color: #495057;
    white-space: nowrap;
}

#launchpad > #content > .launchpad_profile_corner > .item > .item_box {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    color: #6c757d;
}

#launchpad > #content > .launchpad_profile_corner > .item > .item_box > span {
    font-size: 1.1em;
    color: #6c757d;
}

#launchpad > #content > .launchpad_profile_corner > .item:hover > .item_box {
    background: #e9ecef;
    border-color: #dee2e6;
}

#launchpad > #content > .launchpad_profile_corner > .item > .item_box > .active {
    position: absolute;
    top: -1px;
    right: -1px;
    width: 10px;
    height: 10px;
    background: #28a745;
    border: 2px solid #ffffff;
    border-radius: 50%;
}

/* Grid de apps en launchpad */
#launchpad > #content > .grid_apps {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.5em;
    padding: 2em;
    padding-top: 5em; /* Espacio para el perfil en la esquina */
    position: relative;
}
