/* Shared Navigation Styles v3 - User Dropdown */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: linear-gradient(135deg, #0f0f1e 0%, #1a1a2e 100%);
    color: #e0e0e0;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    padding-top: 72px;
}

/* Header */
.app-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(26, 26, 46, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    height: 64px;
    max-width: 1600px;
    margin: 0 auto;
}

/* Brand */
.nav-brand a {
    font-size: 18px;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-decoration: none;
}

/* Navigation Links */
.nav-links {
    display: flex;
    gap: 4px;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    color: #a0a0a0;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.nav-links a .icon {
    font-size: 16px;
}

.nav-links a .label {
    font-size: 13px;
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #ffffff;
}

.nav-links a.active {
    background: rgba(102, 126, 234, 0.15);
    color: #667eea;
}

/* Nav Actions - Right Side */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* Status Badge Container - slightly smaller */
.status-badge-container {
    transform: scale(0.9);
    transform-origin: right center;
}

/* User Dropdown */
.user-dropdown {
    position: relative;
}

.user-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    cursor: pointer;
    transition: all 0.2s;
}

.user-btn:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
}

.user-avatar {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    color: white;
}

.user-name {
    font-size: 13px;
    font-weight: 500;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dropdown-arrow {
    font-size: 8px;
    color: #888;
    transition: transform 0.2s;
}

.user-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

/* User Menu Dropdown */
.user-menu {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    width: 220px;
    background: rgba(30, 30, 50, 0.98);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s ease;
    z-index: 200;
}

.user-menu.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.user-menu-header {
    padding: 14px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.user-email {
    font-size: 13px;
    color: #fff;
    font-weight: 500;
    margin-bottom: 4px;
    word-break: break-all;
}

.user-tier {
    font-size: 11px;
    color: #667eea;
    text-transform: capitalize;
}

.user-menu-items {
    padding: 8px;
}

.user-menu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    color: #c0c0c0;
    text-decoration: none;
    font-size: 13px;
    border-radius: 6px;
    transition: all 0.2s;
    background: none;
    border: none;
    width: 100%;
    cursor: pointer;
    text-align: left;
}

.user-menu-item:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
}

.user-menu-item .icon {
    font-size: 14px;
}

/* Responsive */
@media (max-width: 900px) {
    .nav-links a .label {
        display: none;
    }
    
    .nav-links a {
        padding: 10px 12px;
    }
    
    .nav-links a .icon {
        font-size: 18px;
    }
    
    .user-name {
        display: none;
    }
}

@media (max-width: 600px) {
    .header-content {
        padding: 0 12px;
    }
    
    .nav-brand a {
        font-size: 14px;
    }
    
    .nav-links {
        gap: 2px;
    }
    
    .nav-links a {
        padding: 8px;
    }
}

/* ============================================
   GENERAL PAGE ELEMENTS
   ============================================ */

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px;
}

/* Cards */
.card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 24px;
}

.card h2 {
    margin-bottom: 16px;
    color: #ffffff;
}

/* Buttons */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.1);
    color: #e0e0e0;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.15);
}

.btn-danger {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.3);
}

/* Inputs */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
textarea,
select {
    width: 100%;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: #e0e0e0;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.2s;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
}

/* Labels */
label {
    display: block;
    margin-bottom: 8px;
    color: #b0b0b0;
    font-size: 14px;
    font-weight: 500;
}

/* Form Groups */
.form-group {
    margin-bottom: 20px;
}

/* Utility Classes */
.hidden { display: none !important; }
.text-center { text-align: center; }

/* Messages */
.message {
    padding: 12px 16px;
    border-radius: 8px;
    margin-bottom: 16px;
    font-size: 14px;
}

.message-success {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #10b981;
}

.message-error {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #ef4444;
}

/* Loading Spinner */
.spinner {
    border: 3px solid rgba(255, 255, 255, 0.1);
    border-top: 3px solid #667eea;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
