/**
 * Header Styles
 */

/* ═══ Top Bar ═══ */
.topbar {
    background: var(--mfr-text);
    color: #fff;
    padding: 8px 0;
    font-size: 13px;
}

.topbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.topbar-left, .topbar-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.topbar-link {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    transition: color 0.2s;
}

.topbar-link:hover {
    color: var(--mfr-yellow);
}

.topbar-menu {
    display: flex;
    gap: 15px;
    list-style: none;
    padding: 0;
    margin: 0;
}

.topbar-menu a {
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 13px;
}

/* ═══ Main Header ═══ */
.main-header {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
    padding: 15px 0;
    transition: all 0.3s;
    z-index: 1000;
}

.main-header.sticky {
    position: sticky;
    top: 0;
}

.main-header.transparent {
    background: rgba(255, 255, 255, 0.95);
}

.main-header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 4px 25px rgba(0, 0, 0, 0.08);
    padding: 10px 0;
}

.header-grid {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    gap: 30px;
}

/* Logo */
.site-logo .logo-text {
    display: flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    color: var(--mfr-text);
    font-weight: 900;
    font-size: 22px;
}

.site-logo .logo-emoji { font-size: 28px; }
.site-logo .logo-name { background: var(--mfr-gradient); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }

.site-logo img {
    max-height: 50px;
    width: auto;
}

/* Main Nav */
.main-navigation {
    display: flex;
    justify-content: center;
}

.primary-menu {
    display: flex;
    gap: 5px;
    list-style: none;
    padding: 0;
    margin: 0;
    align-items: center;
}

.primary-menu > li {
    position: relative;
}

.primary-menu a {
    display: block;
    padding: 10px 18px;
    color: var(--mfr-text);
    text-decoration: none;
    font-weight: 600;
    font-size: 15px;
    border-radius: 8px;
    transition: all 0.2s;
}

.primary-menu a:hover,
.primary-menu .current-menu-item > a {
    color: var(--mfr-purple);
    background: var(--mfr-purple-light);
}

/* Submenu */
.primary-menu .sub-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: #fff;
    box-shadow: var(--mfr-shadow);
    border-radius: 12px;
    padding: 10px;
    min-width: 200px;
    list-style: none;
    margin: 0;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s;
    z-index: 100;
}

.primary-menu li:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.primary-menu .sub-menu a {
    padding: 8px 15px;
    border-radius: 6px;
}

/* Header Actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 18px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s;
}

.header-btn .btn-text {
    display: inline;
}

.btn-whatsapp {
    background: #25d366;
    color: #fff !important;
}

.btn-whatsapp:hover {
    background: #128c7e;
    transform: translateY(-2px);
}

.btn-login, .btn-account {
    color: var(--mfr-purple);
    background: var(--mfr-purple-light);
}

.btn-login:hover, .btn-account:hover {
    background: var(--mfr-purple);
    color: #fff !important;
}

.header-btn.btn-primary {
    background: var(--mfr-gradient);
    color: #fff !important;
    padding: 12px 22px;
}

.header-btn.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(124, 58, 237, 0.4);
}

/* Mobile Toggle */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 4px;
    padding: 8px;
}

.mobile-toggle span {
    width: 24px;
    height: 3px;
    background: var(--mfr-text);
    border-radius: 2px;
    transition: all 0.3s;
}

.mobile-toggle.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    height: 100vh;
    background: #fff;
    z-index: 10000;
    padding: 20px;
    overflow-y: auto;
    transition: right 0.3s;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
}

.mobile-menu.active {
    right: 0;
}

.mobile-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--mfr-border);
    margin-bottom: 20px;
}

.mobile-menu-title {
    font-weight: 700;
    font-size: 18px;
}

.mobile-close {
    background: none;
    border: none;
    font-size: 32px;
    cursor: pointer;
    color: var(--mfr-text);
    width: 40px;
    height: 40px;
    border-radius: 50%;
}

.mobile-close:hover { background: var(--mfr-purple-light); }

.mobile-menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-list li { margin-bottom: 5px; }

.mobile-menu-list a {
    display: block;
    padding: 12px 15px;
    color: var(--mfr-text);
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
}

.mobile-menu-list a:hover {
    background: var(--mfr-purple-light);
    color: var(--mfr-purple);
}

.mobile-menu-actions {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--mfr-border);
}

.mobile-btn {
    display: block;
    text-align: center;
    padding: 12px;
    background: var(--mfr-gradient);
    color: #fff;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 700;
}

.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
}

.mobile-overlay.active {
    display: block;
}

/* Responsive */
@media (max-width: 968px) {
    .main-navigation,
    .header-actions .btn-login,
    .header-actions .btn-account,
    .header-actions .btn-primary,
    .header-actions .btn-whatsapp .btn-text {
        display: none;
    }

    .mobile-toggle {
        display: flex;
    }

    .topbar {
        font-size: 12px;
    }

    .topbar .container {
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .topbar-menu {
        display: none;
    }
}
