/* Shared Navbar Styles - Include on all pages */

/* Navigation */
header {
    background: #1a1a2e;
    position: sticky;
    top: 0;
    z-index: 1000;
}

header .wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
}

header .logo a {
    color: #ffffff;
    font-size: 24px;
    font-weight: 700;
    text-decoration: none;
}

header .logo .accent {
    color: #3b82f6;
    display: inline;
}

/* Nav Links */
header .nav-links {
    display: flex;
    gap: 32px;
}

header .nav-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s;
}

header .nav-links a:hover,
header .nav-links a.active {
    color: #fff;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    padding: 8px;
    gap: 5px;
}

.hamburger span {
    width: 24px;
    height: 2px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Auth Button */
.auth-btn {
    background: transparent;
    color: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.auth-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
    color: #fff;
}

/* User Profile (logged in) */
.user-profile {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    position: relative;
}

.user-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 600;
    font-size: 14px;
}

.user-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    min-width: 180px;
    z-index: 1001;
}

.user-dropdown.active {
    display: block;
}

.user-dropdown a,
.user-dropdown button {
    display: block;
    width: 100%;
    padding: 12px 16px;
    text-align: left;
    color: #1a1a2e;
    text-decoration: none;
    border: none;
    background: none;
    font-size: 14px;
    cursor: pointer;
    font-family: inherit;
}

.user-dropdown a:hover,
.user-dropdown button:hover {
    background: #f5f7fa;
}

.user-dropdown .user-email {
    padding: 12px 16px;
    border-bottom: 1px solid #e2e8f0;
    color: #718096;
    font-size: 12px;
}

/* Mobile Menu */
.mobile-menu {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    flex-direction: column;
    background: #1a1a2e;
    padding: 16px 24px;
    gap: 16px;
    z-index: 999;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    font-size: 16px;
    padding: 8px 0;
}

.mobile-menu a:hover,
.mobile-menu a.active {
    color: #fff;
}

/* Responsive */
@media screen and (max-width: 768px) {
    header .nav-links {
        display: none !important;
    }

    .hamburger {
        display: flex !important;
    }

    .auth-btn {
        display: none !important;
    }

    .user-profile {
        display: none !important;
    }

    header .logo a {
        font-size: 20px;
    }
}

/* Auth Modal */
.auth-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.auth-modal.active {
    display: flex;
}

.auth-modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 32px;
    width: 100%;
    max-width: 400px;
    margin: 16px;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

.auth-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.auth-modal-header h2 {
    font-size: 24px;
    font-weight: 600;
    color: #1a1a2e;
    margin: 0;
}

.auth-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #718096;
}

.auth-tabs {
    display: flex;
    margin-bottom: 24px;
    border-bottom: 1px solid #e2e8f0;
}

.auth-tab {
    flex: 1;
    padding: 12px;
    background: none;
    border: none;
    font-size: 14px;
    font-weight: 500;
    color: #718096;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    margin-bottom: -1px;
    font-family: inherit;
}

.auth-tab.active {
    color: #3b82f6;
    border-bottom-color: #3b82f6;
}

.auth-form {
    display: none;
}

.auth-form.active {
    display: block;
}

.auth-input-group {
    margin-bottom: 16px;
}

.auth-input-group label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #4a5568;
    margin-bottom: 6px;
}

.auth-input-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    background: #fff;
    color: #1a1a2e;
    box-sizing: border-box;
    font-family: inherit;
}

.auth-input-group input:focus {
    outline: none;
    border-color: #3b82f6;
}

.auth-submit {
    width: 100%;
    padding: 12px;
    background: #3b82f6;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 8px;
    font-family: inherit;
}

.auth-submit:hover {
    background: #2563eb;
}

.auth-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.auth-error {
    color: #ef4444;
    font-size: 13px;
    margin-top: 12px;
    display: none;
}

.auth-error.active {
    display: block;
}

.auth-success {
    color: #10b981;
    font-size: 13px;
    margin-top: 12px;
    display: none;
}

.auth-success.active {
    display: block;
}
