/* ==========================================================================
   METABRIGHT PUBLIC HEADER & MOBILE NAVIGATION STYLES
   Centralized header stylesheet matching index.php design.
   Included globally via layouts/header.php.
   ========================================================================== */

/* Google Fonts for Header typography */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Poppins:wght@400;500;600;700&display=swap');

/* --- TOPBAR & HEADER CONTAINER --- */
.topbar {
    width: 100%;
    padding: 18px 48px;
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    z-index: 100;
    box-shadow: 0 2px 16px rgba(15, 23, 42, 0.04);
    border-bottom: 1px solid rgba(241, 245, 249, 0.8);
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    box-sizing: border-box;
}

.topbar * {
    box-sizing: border-box;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 44px;
}

.logo {
    width: 155px;
    height: auto;
    display: block;
    transition: transform 0.2s ease;
}

.logo:hover {
    transform: scale(1.02);
}

.main-nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.main-nav a {
    text-decoration: none;
    color: #172033;
    font-size: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    transition: color 0.2s ease, transform 0.2s ease;
    position: relative;
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
}

.main-nav a:hover,
.main-nav a.active {
    color: #f59e0b;
    transform: translateY(-1px);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}

/* Register / Dashboard text link */
.btn-dashboard {
    color: #172033;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 500;
    padding: 8px 12px;
    transition: color 0.2s ease;
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
}

.btn-dashboard:hover {
    color: #d97706;
}

/* Login button: signature yellow pill */
.btn-login {
    background: #facc15;
    color: #172033;
    text-decoration: none;
    font-size: 13.5px;
    font-weight: 700;
    padding: 9px 24px;
    border-radius: 9999px;
    border: 1px solid #facc15;
    box-shadow: 0 2px 8px rgba(250, 204, 21, 0.25);
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
}

.btn-login:hover {
    background: #f5b700;
    border-color: #f5b700;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(250, 204, 21, 0.4);
    color: #172033;
}

/* --- HAMBURGER MENU --- */
.hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    cursor: pointer;
    background: none;
    border: none;
    padding: 4px;
    z-index: 200;
}

.hamburger span {
    display: block;
    width: 24px;
    height: 2.5px;
    background: #172033;
    border-radius: 4px;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.hamburger.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }

/* --- MOBILE NAV OVERLAY & DRAWER --- */
.mobile-nav-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.35);
    z-index: 150;
}

.mobile-nav-overlay.open {
    display: block;
}

.mobile-nav {
    position: fixed;
    top: 0;
    right: -280px;
    width: 260px;
    height: 100%;
    background: #ffffff;
    z-index: 160;
    padding: 24px 20px;
    box-shadow: -8px 0 30px rgba(15, 23, 42, 0.12);
    transition: right 0.35s cubic-bezier(.4, 0, .2, 1);
    display: flex;
    flex-direction: column;
    gap: 0;
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
    box-sizing: border-box;
}

.mobile-nav * {
    box-sizing: border-box;
}

.mobile-nav.open {
    right: 0;
}

.mobile-nav-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
}

.mobile-nav-header img {
    width: 120px;
}

.mobile-nav-close {
    background: none;
    border: none;
    font-size: 26px;
    cursor: pointer;
    color: #172033;
    line-height: 1;
}

.mobile-nav a {
    display: block;
    text-decoration: none;
    color: #172033;
    font-size: 15px;
    font-weight: 700;
    padding: 14px 0;
    border-bottom: 1px solid #f1f3f5;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: color 0.2s;
    font-family: 'Plus Jakarta Sans', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;
}

.mobile-nav a:hover,
.mobile-nav a.active {
    color: #facc15;
}

.mobile-nav .btn-login {
    display: block;
    text-align: center;
    margin-top: 20px;
    border-bottom: none;
    text-transform: none;
}

/* --- RESPONSIVE BREAKPOINTS --- */
@media (max-width: 992px) {
    .topbar {
        padding: 16px 24px;
    }
}

@media (max-width: 768px) {
    .main-nav {
        display: none;
    }
    .header-right {
        display: none;
    }
    .hamburger {
        display: flex;
    }
}

@media (max-width: 640px) {
    .topbar {
        padding: 14px 18px;
    }
}
