/* Cabecera única: réplica exacta de la cabecera de FAQ. */
body > header:first-of-type {
    box-sizing: border-box !important;
    width: 100% !important;
    min-height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, .08) !important;
    background: #050505 !important;
    box-shadow: none !important;
}

body > header:first-of-type > :first-child {
    box-sizing: border-box !important;
    width: min(1240px, calc(100% - 24px)) !important;
    min-height: 82px !important;
    margin: 0 auto !important;
    padding: 8px 0 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
}

body > header:first-of-type .ts-unified-brand {
    min-width: 0 !important;
    display: flex !important;
    align-items: center !important;
    gap: 10px !important;
    color: #fff !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    padding: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    border-radius: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
}

body > header:first-of-type .ts-unified-brand-logo {
    display: block !important;
    width: 54px !important;
    min-width: 54px !important;
    max-width: 54px !important;
    height: 54px !important;
    min-height: 54px !important;
    max-height: 54px !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    outline: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    filter: none !important;
    object-fit: cover !important;
}

#headerPrincipalTrader .ts-unified-brand-logo,
#adminHeader .ts-unified-brand-logo,
#headerPrincipalTrader .header-principal-brand img,
#adminHeader .admin-brand-logo {
    border: 0 !important;
    outline: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
}

body > header:first-of-type .ts-unified-brand::before,
body > header:first-of-type .ts-unified-brand::after {
    content: none !important;
    display: none !important;
}

body > header:first-of-type .ts-unified-brand-copy {
    min-width: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 5px !important;
}

body > header:first-of-type .ts-unified-brand-name {
    color: #fff !important;
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 20px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    letter-spacing: -.3px !important;
}

body > header:first-of-type .ts-unified-brand-name strong {
    color: #ef2933 !important;
    font-weight: 900 !important;
}

body > header:first-of-type .ts-unified-brand-section {
    color: #88888e !important;
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 10px !important;
    font-weight: 900 !important;
    line-height: 1 !important;
    letter-spacing: .9px !important;
}

/* Conserva la acción de cada página, con el acabado de la portada. */
body > header:first-of-type .small-button,
body > header:first-of-type .admin-logout-button,
body > header:first-of-type .header-principal-login,
body > header:first-of-type .ts-session-button {
    box-sizing: border-box !important;
    min-width: 145px !important;
    min-height: 46px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    margin: 0 !important;
    padding: 0 18px !important;
    border: 1px solid #91313a !important;
    border-radius: 10px !important;
    background: linear-gradient(180deg, #a8323b, #741d24) !important;
    color: #fff !important;
    font-size: 13px !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
}

@media (max-width: 700px) {
    body > header:first-of-type > :first-child {
        width: calc(100% - 16px) !important;
        min-height: 72px !important;
        padding: 8px 0 !important;
        gap: 7px !important;
    }

    body > header:first-of-type .ts-unified-brand {
        gap: 8px !important;
        overflow: hidden !important;
    }

    body > header:first-of-type .ts-unified-brand-logo {
        width: 46px !important;
        min-width: 46px !important;
        max-width: 46px !important;
        height: 46px !important;
        min-height: 46px !important;
        max-height: 46px !important;
    }

    body > header:first-of-type .ts-unified-brand-name {
        font-size: 14px !important;
        letter-spacing: -.25px !important;
    }

    body > header:first-of-type .small-button,
    body > header:first-of-type .admin-logout-button,
    body > header:first-of-type .header-principal-login,
    body > header:first-of-type .ts-session-button {
        min-width: 112px !important;
        min-height: 40px !important;
        padding: 0 10px !important;
        border-radius: 9px !important;
        font-size: 11px !important;
    }

    body > header:first-of-type .admin-email,
    body > header:first-of-type #userEmail {
        display: none !important;
    }
}

@media (max-width: 380px) {
    body > header:first-of-type .ts-unified-brand-name {
        font-size: 12px !important;
    }

    body > header:first-of-type .ts-unified-brand-logo {
        width: 42px !important;
        min-width: 42px !important;
        max-width: 42px !important;
        height: 42px !important;
        min-height: 42px !important;
        max-height: 42px !important;
    }
}
