/* ===== ESTILOS COMUNES PARA HEADER DE TODAS LAS APLICACIONES ===== */

/* === HEADER MODERNO === */
.app-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.header-content {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 1.5rem 2rem;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.header-left {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    text-align: center;
}

.header-left > div {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    align-items: center;
    text-align: center;
}

/* === BOTÓN MODERNO VOLVER AL MENÚ === */
.button-wrap {
    position: relative;
    z-index: 2;
    border-radius: 999vw;
    background: transparent;
    pointer-events: none;
    transition: all var(--anim--hover-time, 400ms) var(--anim--hover-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.button-shadow {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: rgba(0, 0, 0, 0.1);
    filter: blur(0.25em);
    opacity: 0;
    transition: opacity var(--anim--hover-time, 400ms) var(--anim--hover-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.button-shadow::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: rgba(255, 255, 255, 0.1);
    filter: blur(0.125em);
    opacity: 0;
    transition: opacity var(--anim--hover-time, 400ms) var(--anim--hover-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.button-wrap:has(button:hover) .button-shadow {
    filter: blur(clamp(2px, 0.0625em, 6px));
    transition: filter var(--anim--hover-time, 400ms) var(--anim--hover-ease, cubic-bezier(0.25, 1, 0.5, 1));
}

.button-wrap:has(button:hover) .button-shadow::after {
    top: calc(var(--shadow-cuttoff-fix) - 0.875em);
    opacity: 1;
}

.button-wrap.volver-menu {
    position: absolute;
    left: 2rem;
    z-index: 1000;
    pointer-events: auto;
    width: 72px;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.button-wrap.volver-menu button {
    --border-width: clamp(1px, 0.0625em, 4px);
    all: unset;
    cursor: pointer;
    position: relative;
    z-index: 3;
    background: linear-gradient(-75deg, rgba(255,255,255,0.05), rgba(255,255,255,0.2), rgba(255,255,255,0.05));
    border-radius: 50%;
    box-shadow: inset 0 0.125em 0.125em rgba(0,0,0,0.05),
      inset 0 -0.125em 0.125em rgba(255,255,255,0.5),
      0 0.25em 0.125em -0.125em rgba(0,0,0,0.2),
      0 0 0.1em 0.25em inset rgba(255,255,255,0.2),
      0 4px 15px rgba(59, 130, 246, 0.3),
      0 0 20px rgba(59, 130, 246, 0.15);
    backdrop-filter: blur(clamp(1px, 0.125em, 4px));
    width: 72px;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.button-wrap.volver-menu button:hover {
    background: linear-gradient(-75deg, rgba(255,255,255,0.1), rgba(255,255,255,0.25), rgba(255,255,255,0.1));
}

.button-wrap.volver-menu button:active {
    background: linear-gradient(-75deg, rgba(255,255,255,0.15), rgba(255,255,255,0.3), rgba(255,255,255,0.15));
}

.button-wrap.volver-menu button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.button-wrap.volver-menu button:disabled:hover {
    background: linear-gradient(-75deg, rgba(255,255,255,0.05), rgba(255,255,255,0.2), rgba(255,255,255,0.05));
}

.button-wrap.volver-menu button span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    padding: 0;
}

/* === TÍTULO Y SUBTÍTULO === */
.app-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0;
    color: #1f2937;
    text-align: center;
}

.app-subtitle {
    color: #6b7280;
    font-size: 0.875rem;
    margin: 0;
    font-weight: 500;
    text-align: center;
}

/* === TEMAS === */
body.theme-dark .app-header {
    background: rgba(31, 41, 55, 0.95);
    border-bottom: 1px solid rgba(75, 85, 99, 0.3);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

body.theme-dark .app-title {
    color: #f9fafb;
}

body.theme-dark .app-subtitle {
    color: #9ca3af;
}

body.theme-light .app-header {
    background: rgba(255, 255, 255, 0.95);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

body.theme-light .app-title {
    color: #1f2937;
}

body.theme-light .app-subtitle {
    color: #6b7280;
}

/* === RESPONSIVE === */
@media (max-width: 1024px) {
    .header-content {
        padding: 1rem;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 1rem;
        position: relative;
    }
    
    .header-left {
        flex-direction: column;
        gap: 0.5rem;
        justify-content: center;
        align-items: center;
    }
    
    .header-left > div {
        order: 1;
        align-items: center;
        text-align: center;
    }
    
    .button-wrap.volver-menu {
        position: absolute;
        left: 1rem;
        top: 1rem;
        width: 60px;
        height: 60px;
    }
    
    .button-wrap.volver-menu button {
        width: 60px;
        height: 60px;
        box-shadow: inset 0 0.125em 0.125em rgba(0,0,0,0.05),
          inset 0 -0.125em 0.125em rgba(255,255,255,0.5),
          0 0.25em 0.125em -0.125em rgba(0,0,0,0.2),
          0 0 0.1em 0.25em inset rgba(255,255,255,0.2),
          0 6px 20px rgba(59, 130, 246, 0.35),
          0 0 25px rgba(59, 130, 246, 0.15);
    }
    
    .button-wrap.volver-menu button:hover {
        box-shadow: inset 0 0.125em 0.125em rgba(0,0,0,0.05),
          inset 0 -0.125em 0.125em rgba(255,255,255,0.5),
          0 0.15em 0.05em -0.1em rgba(0,0,0,0.25),
          0 0 0.05em 0.1em inset rgba(255,255,255,0.5),
          0 8px 25px rgba(59, 130, 246, 0.4),
          0 0 30px rgba(59, 130, 246, 0.2);
    }
    
    .button-wrap.volver-menu button svg {
        width: 32px;
        height: 32px;
    }
    
    .app-title {
        font-size: 1.25rem;
        justify-content: center;
        text-align: center;
    }
}

@media (max-width: 650px) {
    .app-subtitle {
        display: none;
    }
}

@media (max-width: 480px) {
    .button-wrap.volver-menu {
        position: absolute;
        left: 0.5rem;
        top: 0.5rem;
        width: 50px;
        height: 50px;
    }
    
    .button-wrap.volver-menu button {
        width: 50px;
        height: 50px;
        box-shadow: inset 0 0.125em 0.125em rgba(0,0,0,0.05),
          inset 0 -0.125em 0.125em rgba(255,255,255,0.5),
          0 0.25em 0.125em -0.125em rgba(0,0,0,0.2),
          0 0 0.1em 0.25em inset rgba(255,255,255,0.2),
          0 4px 15px rgba(59, 130, 246, 0.3),
          0 0 20px rgba(59, 130, 246, 0.1);
    }
    
    .button-wrap.volver-menu button svg {
        width: 26px;
        height: 26px;
    }
    
    .app-title {
        font-size: 1.125rem;
        justify-content: center;
        text-align: center;
    }
} 