/**
 * AMOSH System - Header Styles (Mobile-First)
 * Estilos consolidados dos headers desktop e mobile
 * Fase 3 da refatoração de responsividade - Mobile-First
 * Atualizado em: 29/11/2025
 */

/* ===== BASE MOBILE STYLES (< 768px) ===== */

/* Dropdown Styles */
.show-dropdown {
    display: block;
    position: absolute;
    will-change: transform;
    top: 0px;
    left: 0px;
    transform: translate3d(-145px, 70px, 0px);
}

.overlay-dropdown {
    display: none;
    width: 100%;
    height: 100%;
    position: fixed;
    background: rgba(0, 0, 0, .1);
    z-index: 9;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
}

.overlay-dropdown.show {
    display: block;
}

/* SVG Notification - Mobile base */
.svg-notification {
    fill: var(--amosh-primary, #3e017a);
    stroke: var(--amosh-primary, #3e017a);
}

/* Header Mobile Base Styles */
.header-mobile {
    background: var(--amosh-primary-light, #5d119c) !important;
    height: 60px;
}

.header-mobile .burger-icon span,
.header-mobile .burger-icon span::before,
.header-mobile .burger-icon span::after,
.header-mobile .burger-icon:hover span,
.header-mobile .burger-icon:hover span::before,
.header-mobile .burger-icon:hover span::after {
    background: white;
}

/* Quick User Toggle - Mobile */
#kt_quick_user_toggle span span {
    background-color: var(--amosh-primary-light, rgb(93, 17, 156)) !important;
}

/* Topbar Church Container - Mobile Base (circular on very small screens) */
.topbar-church-container {
    display: flex;
    align-items: center;
    padding: 4px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition-base, 0.2s ease);
    border: 1px solid rgba(255, 255, 255, 0.12);
    min-height: var(--touch-min, 44px);
}

.topbar-church-container:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.2);
}

/* Church Logo - Mobile Base */
.topbar-church-logo {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.25);
    flex-shrink: 0;
}

.topbar-church-logo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.topbar-church-logo .logo-initials {
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    text-transform: uppercase;
}

/* Church Info - Hidden on Mobile */
.topbar-church-info {
    display: none;
}

/* Dropdown Arrow - Hidden on Mobile */
.topbar-dropdown-arrow {
    display: none;
}

/* Notification Button - Mobile Base */
.topbar-notification-btn {
    width: 34px;
    height: 34px;
    min-width: var(--touch-min, 44px);
    min-height: var(--touch-min, 44px);
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition-base, 0.2s ease);
    position: relative;
}

.topbar-notification-btn:hover {
    background: rgba(255, 255, 255, 0.14);
    border-color: rgba(255, 255, 255, 0.2);
}

.topbar-notification-btn .pulse-ring {
    position: absolute;
    top: -1px;
    right: -1px;
    width: 10px;
    height: 10px;
    background: #ff4757;
    border-radius: 50%;
    border: 2px solid var(--amosh-primary, #3e017a);
}

.topbar-notification-btn .pulse-ring::before {
    content: '';
    position: absolute;
    inset: -3px;
    border-radius: 50%;
    background: rgba(255, 71, 87, 0.4);
    animation: pulse-notification 2s ease-out infinite;
}

@keyframes pulse-notification {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    100% {
        transform: scale(1.6);
        opacity: 0;
    }
}

/* Topbar Gap */
.topbar {
    gap: 12px;
}

/* Mobile Header User Button */
#kt_header_mobile_topbar_toggle .symbol img {
    border-radius: 100%;
    object-fit: cover;
}

/* =====================================================
   BREAKPOINT: SM (375px+) - iPhone SE+
   ===================================================== */
@media screen and (min-width: 375px) {
    .show-dropdown {
        transform: translate3d(-185px, 70px, 0px);
    }
}

/* =====================================================
   BREAKPOINT: SM (480px+) - Mobile Grande
   ===================================================== */
@media screen and (min-width: 480px) {
    .show-dropdown {
        transform: translate3d(-245px, 70px, 0px);
    }

    .topbar-church-container {
        padding: 5px 10px 5px 5px;
        gap: 8px;
        border-radius: 30px;
    }

    .topbar-church-logo {
        width: 30px;
        height: 30px;
        border-width: 2px;
    }
}

/* =====================================================
   BREAKPOINT: MD (768px+) - Tablet
   ===================================================== */
@media screen and (min-width: 768px) {
    .show-dropdown {
        transform: translate3d(-300px, 70px, 0px);
    }

    /* Show Church Info */
    .topbar-church-info {
        display: flex;
        flex-direction: column;
        text-align: left;
        max-width: 160px;
        line-height: 1.1;
    }

    .topbar-church-name {
        font-size: 13px;
        font-weight: 600;
        color: #fff;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .topbar-church-label {
        font-size: 9px;
        color: rgba(255, 255, 255, 0.6);
        text-transform: uppercase;
        letter-spacing: 0.5px;
        font-weight: 500;
    }

    /* Show Dropdown Arrow */
    .topbar-dropdown-arrow {
        display: block;
        margin-left: 2px;
        color: rgba(255, 255, 255, 0.5);
        font-size: 10px;
        transition: transform var(--transition-base, 0.2s ease);
    }

    .dropdown.show .topbar-dropdown-arrow {
        transform: rotate(180deg);
    }

    /* Topbar Church Container - Tablet */
    .topbar-church-container {
        gap: 10px;
        padding: 6px 14px 6px 6px;
    }

    /* Church Logo - Tablet */
    .topbar-church-logo {
        width: 34px;
        height: 34px;
        border-width: 2px;
    }

    /* Notification Button - Tablet */
    .topbar-notification-btn {
        width: 38px;
        height: 38px;
    }
}

/* =====================================================
   BREAKPOINT: MD+ (901px+) - Large Tablet
   ===================================================== */
@media screen and (min-width: 901px) {
    /* SVG Notification - White for darker backgrounds */
    .svg-notification {
        fill: white;
        stroke: white;
    }
}

/* =====================================================
   BREAKPOINT: LG (992px+) - Desktop
   ===================================================== */
@media screen and (min-width: 992px) {
    /* Header Desktop Gradient */
    #kt_header {
        background: var(--amosh-gradient, linear-gradient(90deg, #3e017a 0%, #a44e8d 100%)) !important;
    }
}
