/* ============================================
   OTAKIROKU - GLOBAL STYLES
   Shared across all pages
   ============================================ */
:root {
    /* Brand Colors */
    --primary: #8b5cf6;
    --primary-rgb: 139, 92, 246;
    --primary-light: #a78bfa;
    --primary-hover: #7c3aed;
    --primary-glow: rgba(var(--primary-rgb), 0.4);
    --primary-subtle: rgba(var(--primary-rgb), 0.1);

    /* Backgrounds */
    --bg-deep: #0a0a0f;
    --bg-surface: #0f0f14;
    --bg-card: rgba(255, 255, 255, 0.03);
    --bg-elevated: #1a1a22;
    --bg-hover: #1a1a22;
    
    /* Text */
    --text-primary: #fafafa;
    --text-secondary: #a1a1aa;
    --text-muted: #52525b;
    
    /* Borders */
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --border-active: rgba(var(--primary-rgb), 0.5);
    
    /* Semantic Colors */
    --success: #22c55e;
    --warning: #f59e0b;
    --error: #ef4444;
    
    /* Layout */
    --max-w: 1200px;
    --nav-width: 680px;
    --nav-height: 54px;
    
    /* Typography */
    --font-display: 'Outfit', sans-serif;
    --font-body: 'Space Grotesk', sans-serif;
    
    /* Transitions */
    --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
    --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* === RESET === */
*, *::before, *::after { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
}

html {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-behavior: smooth;
    overflow-x: clip;
    max-width: 100vw;
}

body {
    background-color: var(--bg-deep);
    color: var(--text-secondary);
    font-family: var(--font-body);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: clip;
    max-width: 100vw;
    width: 100%;
}

a { 
    text-decoration: none; 
    color: inherit; 
    transition: color 0.2s ease; 
}

button {
    font-family: inherit;
    cursor: pointer;
}

input, select, textarea {
    font-family: inherit;
}

img {
    max-width: 100%;
    display: block;
}

/* === BACKGROUND EFFECTS === */
.bg-effects {
    position: fixed;
    inset: 0;
    z-index: -1;
    overflow: hidden;
    pointer-events: none;
    background: radial-gradient(ellipse 100% 80% at 50% 0%, rgba(var(--primary-rgb), 0.22), transparent 70%);
}

/* === LAYOUT === */
.container { 
    max-width: var(--max-w); 
    margin: 0 auto; 
    padding: 0 1.5rem; 
}

/* === NAVBAR (Drip Style) === */
.navbar {
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    width: var(--nav-width);
    height: var(--nav-height);
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-top: none;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.5);
    overflow: visible;
}

.nav-content {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    padding: 0 2rem;
    height: 100%;
    position: relative;
    z-index: 20;
}

.logo {
    display: flex;
    align-items: center;
    justify-self: start;
}
.logo img {
    height: 32px;
    width: auto;
}

.nav-links {
    display: flex;
    gap: 4px;
    height: 100%;
    justify-self: center;
}

.nav-links a {
    position: relative;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--text-primary);
}

/* Drip Effect */
.nav-links a::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 0;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-top: none;
    margin-top: -1px;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
    z-index: 10;
    opacity: 0;
    transition: height 0.3s var(--ease-spring), opacity 0.2s ease, box-shadow 0.2s ease;
}

.nav-links a:hover::after {
    opacity: 1;
    height: 12px;
}

.nav-links a.active::after {
    opacity: 1;
    height: 12px;
    border: 1px solid var(--border-active);
    border-top: none;
    box-shadow: 0 8px 10px -4px var(--primary-glow);
}

/* Nav Dropdown (extends drip effect) */
.nav-item {
    position: relative;
    height: 100%;
}

.nav-item > a {
    position: relative;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 1.5rem;
    transition: color 0.2s;
}

.nav-item > a:hover,
.nav-item > a.active {
    color: var(--text-primary);
}

.nav-item > a::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    height: 0;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-top: none;
    margin-top: -1px;
    border-bottom-left-radius: 12px;
    border-bottom-right-radius: 12px;
    z-index: 10;
    opacity: 0;
    transition: height 0.3s var(--ease-spring), opacity 0.2s ease, box-shadow 0.2s ease;
}

.nav-item:hover > a::after {
    opacity: 1;
    height: 50px;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
}

.nav-item > a.active::after {
    opacity: 1;
    height: 12px;
    border: 1px solid var(--border-active);
    border-top: none;
    box-shadow: 0 8px 10px -4px var(--primary-glow);
}

.nav-item:hover > a.active::after {
    height: 50px;
    border: 1px solid var(--border);
    border-top: none;
    box-shadow: none;
    border-bottom-left-radius: 16px;
    border-bottom-right-radius: 16px;
}

/* Hide drip effect for nav items with dropdowns */
.nav-item:has(.nav-dropdown) > a::after {
    display: none;
}

/* Nav Dropdown - Clean card style */
.nav-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    min-width: 180px;
    background: rgba(17, 19, 24, 0.98);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.6);
    opacity: 0;
    visibility: hidden;
    transition: all 0.2s ease;
    z-index: 1001;
    overflow: hidden;
    padding: 8px;
}

.nav-item:hover .nav-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Dropdown items */
.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    font-size: 0.875rem;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.15s ease;
}

.nav-dropdown-item::after {
    display: none !important;
}

.nav-dropdown-item:hover {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--text-primary);
}

.nav-dropdown-item svg {
    width: 18px;
    height: 18px;
    color: var(--primary);
    opacity: 0.8;
    flex-shrink: 0;
}

.nav-dropdown-item:hover svg {
    opacity: 1;
}

/* Dropdown divider */
.nav-dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.06);
    margin: 6px 8px;
}

/* Coming soon item - muted/disabled style */
.nav-dropdown-item.coming-soon {
    cursor: default;
    opacity: 0.5;
    color: var(--text-muted);
}

.nav-dropdown-item.coming-soon:hover {
    background: transparent;
    color: var(--text-muted);
}

.nav-dropdown-item.coming-soon svg {
    opacity: 0.5;
}

.login-btn {
    background: var(--text-primary);
    color: black;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 0.5rem 1.4rem;
    border-radius: 50px;
    border: none;
    transition: transform 0.2s, opacity 0.2s;
}

.login-btn:hover {
    opacity: 0.9;
    transform: scale(1.02);
}

/* === EXTENSION PROMO (floats beside navbar) === */
.nav-ext-promo {
    position: absolute;
    left: calc(100% + 16px);
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    gap: 42px;
    text-decoration: none;
    opacity: 0;
    animation: extPromoEnter 0.5s ease 0.3s forwards, extPromoFloat 3s ease-in-out 0.8s infinite;
}

html.oku-link-installed .nav-ext-promo {
    display: none !important;
}

@keyframes extPromoEnter {
    from { opacity: 0; transform: translateY(-50%) translateX(20px); }
    to { opacity: 1; transform: translateY(-50%) translateX(0); }
}

@keyframes extPromoFloat {
    0%, 100% { transform: translateY(-50%); }
    50% { transform: translateY(calc(-50% - 4px)); }
}

@keyframes extPromoGlow {
    0%, 100% { box-shadow: 0 0 8px rgba(139, 92, 246, 0.4), 0 0 20px rgba(139, 92, 246, 0.2); }
    50% { box-shadow: 0 0 16px rgba(139, 92, 246, 0.6), 0 0 30px rgba(139, 92, 246, 0.3); }
}

.nav-ext-promo .ext-promo-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    filter: drop-shadow(0 0 6px rgba(139, 92, 246, 0.5));
    transition: all 0.2s ease;
}

.nav-ext-promo .ext-promo-icon img {
    width: 32px;
    height: 32px;
    object-fit: contain;
}

.nav-ext-promo .ext-promo-bubble {
    background: #1f1f28;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 8px 14px;
    border-radius: 20px;
    border: 1px solid rgba(139, 92, 246, 0.4);
    white-space: nowrap;
    position: relative;
    animation: extPromoGlow 2s ease-in-out infinite;
    transition: all 0.2s ease;
}

/* Speech bubble dots — curved trail from icon to bubble */
.nav-ext-promo .ext-promo-bubble::before {
    content: '';
    position: absolute;
    left: -14px;
    top: 50%;
    transform: translateY(-50%);
    width: 10px;
    height: 10px;
    background: #1f1f28;
    border: 1px solid rgba(139, 92, 246, 0.4);
    border-radius: 50%;
}

.nav-ext-promo .ext-promo-bubble::after {
    content: '';
    position: absolute;
    left: -25px;
    top: 50%;
    transform: translateY(4px);
    width: 8px;
    height: 8px;
    background: #1f1f28;
    border: 1px solid rgba(139, 92, 246, 0.4);
    border-radius: 50%;
    box-shadow: -11px -8px 0 -1px #1f1f28, -11px -8px 0 0 rgba(139, 92, 246, 0.4);
}

.nav-ext-promo:hover .ext-promo-icon {
    transform: scale(1.1);
    filter: drop-shadow(0 0 10px rgba(139, 92, 246, 0.7));
}

.nav-ext-promo:hover .ext-promo-bubble {
    background: #2a2a36;
    border-color: rgba(139, 92, 246, 0.6);
    animation: none;
    box-shadow: 0 0 20px rgba(139, 92, 246, 0.5), 0 0 40px rgba(139, 92, 246, 0.3);
}

.nav-ext-promo:hover .ext-promo-bubble::before {
    background: #2a2a36;
    border-color: rgba(139, 92, 246, 0.6);
}

.nav-ext-promo:hover .ext-promo-bubble::after {
    background: #2a2a36;
    border-color: rgba(139, 92, 246, 0.6);
    box-shadow: -11px -8px 0 -1px #2a2a36, -11px -8px 0 0 rgba(139, 92, 246, 0.6);
}

/* Hide when viewport can't fit promo beside navbar */
@media (max-width: 1100px) {
    .nav-ext-promo {
        display: none;
    }
}

/* User Nav Button (logged in state) */
.nav-auth {
    position: relative;
    justify-self: end;
    display: flex;
    align-items: center;
    gap: 8px;
}

.nav-notification-wrapper,
.nav-user-wrapper {
    position: relative;
}

.nav-notification-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    background: transparent;
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.2s;
    position: relative;
}

.nav-notification-btn:hover {
    border-color: var(--primary);
    color: var(--text-primary);
}

.nav-notification-btn svg {
    width: 18px;
    height: 18px;
}

.nav-notification-btn .notification-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 8px;
    height: 8px;
}

.user-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    background: transparent;
    border: none;
    border-radius: 6px;
    transition: all 0.2s;
    position: relative;
    overflow: visible;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
}

.user-nav-btn.has-frame {
    border-radius: 6px;
    border: 2px solid rgba(255, 255, 255, 0.15);
    background: var(--bg-elevated);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
    padding: 1.5px;
}

/* Clip avatar image inside frame, not the whole container */
.user-nav-btn.has-frame .user-nav-avatar-img {
    border-radius: 4px;
}

.nav-avatar-chevron {
    position: absolute;
    top: 50%;
    right: -14px;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 6px solid var(--primary);
    transform: translateY(-50%);
    transition: transform 0.2s ease;
}

.nav-user-wrapper:hover .nav-avatar-chevron {
    transform: translateY(-50%) rotate(180deg);
}

.user-nav-avatar {
    width: 100%;
    height: 100%;
    border-radius: 6px;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: center;
}

.user-nav-avatar svg {
    width: 22px;
    height: 22px;
    color: var(--text-muted);
}

.user-nav-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 6px;
}

/* Notification indicator dot on profile button */
.user-nav-btn .notification-dot {
    position: absolute;
    top: 0;
    right: -8px;
    width: 10px;
    height: 10px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid var(--bg-surface);
    animation: pulse-dot 2s ease-in-out infinite;
    z-index: 5;
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

/* Admin notification indicator dot on desktop profile button */
.user-nav-btn .admin-notification-dot {
    position: absolute;
    top: -2px;
    right: -10px;
    width: 10px;
    height: 10px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid var(--bg-surface);
    z-index: 6;
}

/* Admin badge in dropdown */
.dropdown-admin-badge {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    font-weight: 600;
    border-radius: 9px;
}

/* === NOTIFICATIONS === */
/* Hover-triggered notification dropdown from notification bell */
.nav-notification-wrapper:hover .notification-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.notification-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 0;
    width: 360px;
    max-height: 480px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.2s;
    z-index: 1000;
    overflow: hidden;
}

.notification-dropdown.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 18px;
    border-bottom: 1px solid var(--border);
}

.notification-header h4 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
}

.notification-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.mark-all-read,
.clear-all-notis {
    background: none;
    border: none;
    font-size: 0.8rem;
    color: var(--primary);
    cursor: pointer;
    transition: opacity 0.2s;
}

.mark-all-read:hover,
.clear-all-notis:hover {
    opacity: 0.8;
}

.clear-all-notis {
    color: var(--text-secondary);
}

.notification-list {
    max-height: 360px;
    overflow-y: auto;
}

.notification-item {
    display: flex;
    gap: 12px;
    padding: 14px 18px;
    text-decoration: none;
    border-bottom: 1px solid var(--border);
    transition: background 0.2s;
    position: relative;
}

.notification-item:hover {
    background: var(--bg-elevated);
}

.notification-item.unread {
    background: rgba(var(--primary-rgb), 0.05);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    background: var(--primary);
    border-radius: 50%;
}

.notification-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-elevated);
    border-radius: 50%;
    flex-shrink: 0;
}

.notification-icon svg {
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
}

.notification-icon.thread_reply svg,
.notification-icon.post_reply svg {
    color: var(--primary);
}

.notification-icon.new_follower svg {
    color: #34d399;
}

.notification-icon.following_thread svg {
    color: #f472b6;
}

.notification-content {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.notification-message {
    font-size: 0.8rem;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 4px;
}

.notification-time {
    font-size: 0.75rem;
    color: #9ca3af;
}

/* Gift code notification */
.notification-gift-code {
    position: relative;
    cursor: default;
    border-left: 3px solid #fbbf24;
    text-decoration: none;
    display: flex;
    align-items: flex-start;
    padding: 14px 16px;
    gap: 12px;
    border-bottom: 1px solid var(--border-color);
}

.notification-gift-code .notification-icon.gift_code svg {
    color: #fbbf24;
}

.gift-code-display {
    font-family: 'Courier New', monospace;
    font-size: 1rem;
    font-weight: 700;
    color: #fbbf24;
    background: rgba(251, 191, 36, 0.1);
    border: 1px solid rgba(251, 191, 36, 0.3);
    border-radius: 6px;
    padding: 6px 12px;
    margin: 6px 0;
    cursor: pointer;
    display: inline-block;
    letter-spacing: 1px;
    transition: background 0.2s;
}

.gift-code-display:hover {
    background: rgba(251, 191, 36, 0.2);
}

.gift-code-dismiss-btn {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--text-secondary);
    padding: 4px;
    border-radius: 4px;
    transition: color 0.2s, background 0.2s;
    flex-shrink: 0;
    margin-top: 2px;
}

.gift-code-dismiss-btn:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.notification-empty,
.notification-loading {
    padding: 40px 20px;
    text-align: center;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.notification-footer {
    display: block;
    padding: 14px;
    text-align: center;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: none;
    border-top: 1px solid var(--border);
    transition: background 0.2s;
}

.notification-footer:hover {
    background: var(--bg-elevated);
}

@media (max-width: 480px) {
    .notification-dropdown {
        width: calc(100vw - 24px);
        left: auto;
        right: -12px;
    }
}

/* === USER DROPDOWN === */
.user-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    left: 50%;
    min-width: 180px;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateX(-50%) translateY(-10px);
    transition: all 0.2s;
    z-index: 1001;
    overflow: hidden;
}

.nav-user-wrapper:hover .user-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.user-dropdown-item {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
    padding: 10px 16px;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    background: none;
    border: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.user-dropdown-item svg {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

.user-dropdown-item span {
    flex: 1;
}

.user-dropdown-item:hover {
    background: var(--bg-elevated);
    color: var(--text-primary);
}

.user-dropdown-item.bug-report-link {
    color: var(--text-secondary);
}

.user-dropdown-item.bug-report-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.user-dropdown-item.signout {
    color: #ef4444;
}

.user-dropdown-item.signout:hover {
    background: rgba(239, 68, 68, 0.1);
    color: #ef4444;
}

.user-dropdown-item.admin-link {
    position: relative;
    color: var(--accent-purple);
}

.user-dropdown-item.admin-link:hover {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--accent-purple);
}

.user-dropdown-item.notification-link {
    position: relative;
}

.dropdown-notif-badge {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ef4444;
    color: white;
    font-size: 0.65rem;
    font-weight: 600;
    border-radius: 9px;
}

.user-dropdown-divider {
    height: 1px;
    background: var(--border);
}

/* === SHARED COMPONENTS === */
.btn-primary {
    display: inline-block;
    background: var(--primary);
    color: white;
    padding: 0.9rem 2.5rem;
    border-radius: 50px;
    font-family: var(--font-body);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 0 20px var(--primary-glow);
}

.btn-primary:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: 0 0 30px var(--primary-glow);
}

/* === SHARED PAGE STYLES === */
.content-wrapper {
    margin-top: 80px;
    padding-bottom: 6rem;
}

.page-title {
    font-family: var(--font-display);
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--text-primary);
    letter-spacing: -0.03em;
    line-height: 1.1;
}

.text-muted {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-top: 0.5rem;
}

/* === ANIMATED TEXT === */
.text-gradient,
.title-accent {
    background: linear-gradient(to right, #fff 20%, var(--primary-light) 40%, var(--primary-light) 60%, #fff 80%);
    background-size: 200% auto;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shine 3s linear infinite;
}

@keyframes shine {
    to { background-position: 200% center; }
}

/* === SCROLLBAR === */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: var(--bg-deep);
}

::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 5px;
    border: 2px solid var(--bg-deep);
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* === FOOTER === */
.footer {
    border-top: 1px solid var(--border);
    padding: 60px 24px 40px;
    margin-top: auto;
}

.footer-container {
    max-width: var(--max-w);
    margin: 0 auto;
}

.footer-main {
    display: grid;
    grid-template-columns: 200px repeat(4, 1fr);
    gap: 48px;
    align-items: start;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.footer-logo {
    display: block;
}

.footer-logo img {
    height: 68px;
    width: auto;
    opacity: 0.9;
    transition: opacity 0.2s;
}

.footer-logo:hover img {
    opacity: 1;
}

.footer-brand .footer-copyright {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
}

.footer-column h4 {
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 16px;
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-links a {
    font-size: 0.9rem;
    color: #9ca3af;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: var(--text-primary);
}

/* === RESPONSIVE === */
@media (max-width: 900px) {
    .footer-main {
        grid-template-columns: repeat(4, 1fr);
        gap: 32px;
    }

    .footer-brand {
        grid-column: 1 / -1;
        align-items: center;
    }
}

@media (max-width: 640px) {
    .navbar {
        width: calc(100% - 2rem);
        max-width: 500px;
    }

    .nav-content {
        padding: 0 1rem;
    }

    .nav-links a {
        padding: 0 0.75rem;
        font-size: 0.8rem;
    }

    .footer {
        padding: 40px 16px 32px;
    }

    .footer-main {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }
}

/* ============================================
   BACK TO TOP BUTTON
   ============================================ */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 100;
}

.back-to-top:hover {
    background: var(--primary-hover);
    transform: translateY(-2px);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top svg {
    width: 24px;
    height: 24px;
}

@media (max-width: 600px) {
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 44px;
        height: 44px;
    }

    .back-to-top svg {
        width: 20px;
        height: 20px;
    }
}

/* ===== VIEW AS OVERLAY ===== */
.view-as-overlay {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 2147483647; /* Maximum z-index to ensure it's always on top */
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 12px 24px;
    background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.95), rgba(59, 130, 246, 0.95));
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    font-size: 0.9rem;
    color: white;
    box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.3);
    pointer-events: auto;
}
.view-as-overlay svg { width: 20px; height: 20px; }
.view-as-overlay .view-info {
    display: flex;
    align-items: center;
    gap: 8px;
}
.view-as-overlay .view-actions {
    display: flex;
    gap: 8px;
}
.view-as-overlay .btn-overlay {
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    color: white;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    background: rgba(255, 255, 255, 0.1);
}
.view-as-overlay .btn-overlay:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}
.view-as-overlay .btn-overlay.primary {
    background: white;
    color: var(--primary-hover);
    border-color: white;
}
.view-as-overlay .btn-overlay.primary:hover {
    background: #f0f0f0;
}

@media (max-width: 600px) {
    .view-as-overlay {
        flex-direction: column;
        gap: 10px;
        padding: 10px 16px;
    }
}

/* ============================================
   MOBILE NAVIGATION - COMPLETE SYSTEM
   ============================================ */

/* Hamburger Button - Sleek, Modern Design */
.hamburger-btn {
    display: none;
    position: relative;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: 10px;
    cursor: pointer;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    padding: 0;
    z-index: 1002;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.hamburger-btn:hover {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary);
}

.hamburger-btn:active {
    transform: scale(0.95);
}

.hamburger-btn span {
    display: block;
    width: 18px;
    height: 2px;
    background: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    transform-origin: center;
}

.hamburger-btn.active {
    background: var(--primary);
    border-color: var(--primary);
}

.hamburger-btn.active span {
    background: white;
}

.hamburger-btn.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

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

.hamburger-btn.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}

/* Mobile Menu Overlay - Full Screen Experience */
.mobile-menu-overlay {
    display: none !important; /* Hidden - replaced by compact popups */
}

.mobile-menu-overlay.open {
    display: none !important; /* Hidden - replaced by compact popups */
}

/* Mobile Navigation Links Container */
.mobile-nav-links {
    display: flex;
    flex-direction: column;
    padding: 0 20px;
    max-width: 420px;
    margin: 0 auto;
}

/* Top Level Navigation Items */
.mobile-nav-links > a,
.mobile-nav-item > button {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 16px;
    margin: 4px 0;
    font-size: 1.15rem;
    font-weight: 600;
    font-family: var(--font-display);
    color: var(--text-primary);
    border: none;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
    min-height: 56px;
    width: 100%;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.mobile-nav-links > a:hover,
.mobile-nav-links > a:active,
.mobile-nav-item > button:hover,
.mobile-nav-item > button:active {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary);
}

.mobile-nav-links > a.active {
    background: var(--primary);
    color: white;
}

/* Dropdown Toggle Icon */
.mobile-nav-item .chevron {
    width: 20px;
    height: 20px;
    color: var(--text-muted);
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s ease;
    flex-shrink: 0;
}

.mobile-nav-item.expanded .chevron {
    transform: rotate(180deg);
    color: var(--primary);
}

/* Dropdown Submenu */
.mobile-dropdown {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 0 8px;
    border-radius: 0 0 12px 12px;
}

.mobile-nav-item.expanded .mobile-dropdown {
    max-height: 350px;
}

.mobile-dropdown a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-secondary);
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
    text-decoration: none;
    transition: all 0.2s ease;
    min-height: 52px;
    -webkit-tap-highlight-color: transparent;
}

.mobile-dropdown a:first-child {
    border-top: 1px solid rgba(255, 255, 255, 0.04);
    margin-top: 4px;
}

.mobile-dropdown a:last-child {
    border-bottom: none;
    border-radius: 0 0 8px 8px;
}

.mobile-dropdown a:hover,
.mobile-dropdown a:active {
    background: rgba(var(--primary-rgb), 0.08);
    color: var(--text-primary);
}

.mobile-dropdown a svg {
    width: 18px;
    height: 18px;
    color: var(--primary);
    opacity: 0.7;
    flex-shrink: 0;
}

/* Mobile Auth Section */
.mobile-auth-section {
    padding: 24px 20px;
    margin-top: 24px;
    max-width: 420px;
    margin-left: auto;
    margin-right: auto;
}

.mobile-auth-section .login-btn {
    display: block;
    width: 100%;
    text-align: center;
    padding: 16px 24px;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 12px;
    min-height: 52px;
}

/* Mobile User Section (when logged in) */
.mobile-user-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.mobile-user-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 10px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: 500;
    min-height: 48px;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.mobile-user-link:hover,
.mobile-user-link:active {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--text-primary);
}

.mobile-user-link svg {
    width: 20px;
    height: 20px;
    color: var(--primary);
    opacity: 0.8;
}

.mobile-user-link.admin-link {
    color: var(--primary);
}

.mobile-signout-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    margin-top: 12px;
    padding: 14px 20px;
    background: transparent;
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 10px;
    color: #f87171;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    min-height: 48px;
    transition: all 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.mobile-signout-btn:hover,
.mobile-signout-btn:active {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.5);
}

/* ============================================
   FLOATING MOBILE NAVIGATION
   ============================================ */
.floating-nav {
    display: none;
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 1001;
    flex-direction: row;
    align-items: center;
}

.floating-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: var(--bg-elevated);
    border: 2px solid var(--border);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 255, 255, 0.05);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    -webkit-tap-highlight-color: transparent;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.floating-nav-btn:active {
    transform: scale(0.92);
}

.floating-menu-btn {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    border-color: var(--primary);
    z-index: 2; /* Menu button on top */
    position: relative;
}

.floating-menu-btn:hover {
    box-shadow: 0 6px 24px rgba(var(--primary-rgb), 0.5), 0 0 0 1px rgba(var(--primary-rgb), 0.3);
    transform: scale(1.05);
}

.floating-menu-btn.active {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    border-color: #ef4444;
}

.floating-menu-btn .hamburger-lines {
    display: flex;
    flex-direction: column;
    gap: 5px;
    align-items: center;
}

.floating-menu-btn .hamburger-lines span {
    display: block;
    width: 20px;
    height: 2.5px;
    background: white;
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.floating-menu-btn.active .hamburger-lines span:nth-child(1) {
    transform: translateY(7.5px) rotate(45deg);
}

.floating-menu-btn.active .hamburger-lines span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.floating-menu-btn.active .hamburger-lines span:nth-child(3) {
    transform: translateY(-7.5px) rotate(-45deg);
}

/* Profile button - hidden by default, slides out when menu opens */
.floating-profile-btn {
    width: 48px;
    height: 48px;
    padding: 0;
    overflow: visible;
    position: absolute;
    left: 4px; /* Start behind menu button */
    opacity: 0;
    transform: scale(0.8);
    pointer-events: none;
    transition: all 0.35s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    z-index: 1;
}

/* Profile button slides out when menu is active */
.floating-nav.menu-open .floating-profile-btn {
    left: 66px; /* Slide out to the right */
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
}

.floating-profile-btn:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 16px rgba(var(--primary-rgb), 0.3);
}

.floating-profile-btn img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

.floating-profile-btn .default-avatar {
    width: 24px;
    height: 24px;
    color: var(--text-secondary);
}

/* Admin notification badge on profile button */
.floating-profile-btn .admin-badge-dot {
    position: absolute;
    top: 2px;
    right: 2px;
    width: 12px;
    height: 12px;
    background: #ef4444;
    border-radius: 50%;
    border: 2px solid var(--bg-deep);
    z-index: 10;
    pointer-events: none;
}

/* Admin menu badge */
.admin-menu-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    background: #ef4444;
    color: white;
    font-size: 0.7rem;
    font-weight: 600;
    border-radius: 9px;
    margin-left: auto;
}

/* ============================================
   COMPACT POPUP MENUS
   ============================================ */
.floating-popup-menu {
    position: fixed;
    bottom: 90px;
    left: 20px;
    min-width: 280px;
    max-width: 320px;
    background: rgba(20, 20, 28, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6),
                0 0 0 1px rgba(255, 255, 255, 0.05);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1000;
    overflow: hidden;
}

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

.popup-menu-list {
    padding: 8px;
}

.popup-menu-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    color: var(--text-primary);
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 10px;
    transition: all 0.2s ease;
    cursor: pointer;
    min-height: 44px;
    background: transparent;
    border: none;
    width: 100%;
    text-align: left;
    -webkit-tap-highlight-color: transparent;
}

.popup-menu-item:hover,
.popup-menu-item:focus {
    background: rgba(var(--primary-rgb), 0.15);
    color: var(--primary);
}

.popup-menu-item:active {
    transform: scale(0.98);
}

.popup-menu-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    opacity: 0.8;
}

.popup-menu-item:hover svg,
.popup-menu-item:focus svg {
    opacity: 1;
}

/* Expandable dropdown items in popup */
.popup-dropdown-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
}

.popup-dropdown-toggle span {
    flex: 1;
}

.popup-dropdown-toggle .chevron {
    width: 16px;
    height: 16px;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.popup-dropdown-toggle.expanded .chevron {
    transform: rotate(180deg);
}

.popup-submenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    padding-left: 12px;
}

.popup-submenu.expanded {
    max-height: 500px;
}

.popup-submenu-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s ease;
    min-height: 44px;
    -webkit-tap-highlight-color: transparent;
}

.popup-submenu-item:hover,
.popup-submenu-item:focus {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--text-primary);
}

.popup-submenu-item svg {
    width: 18px;
    height: 18px;
    opacity: 0.7;
}

.popup-submenu-item:hover svg,
.popup-submenu-item:focus svg {
    opacity: 1;
}

.popup-submenu-item.coming-soon {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* Divider in popup menu */
.popup-menu-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 8px 0;
}

/* Profile popup specific positioning - aligns with sliding profile button */
.floating-popup-menu.profile-popup {
    left: 86px; /* 20px base + 66px profile button position */
}

/* Admin link styling */
.popup-menu-item.admin-link {
    color: var(--accent-yellow);
}

.popup-menu-item.admin-link:hover {
    background: rgba(234, 179, 8, 0.15);
    color: var(--accent-yellow);
}

/* Bug report link styling */
.popup-menu-item.bug-report-link {
    color: var(--text-secondary);
}

.popup-menu-item.bug-report-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

/* Sign out button styling */
.popup-menu-item.signout-btn {
    color: #ef4444;
}

.popup-menu-item.signout-btn:hover {
    background: rgba(239, 68, 68, 0.15);
    color: #ef4444;
}

/* ============================================
   MOBILE BREAKPOINTS - 768px (Tablet)
   ============================================ */
@media (max-width: 768px) {
    /* HIDE entire navbar on mobile - use floating nav instead */
    .navbar {
        display: none !important;
    }

    /* Show floating navigation */
    .floating-nav {
        display: flex;
    }

    /* Hide old hamburger - now in floating nav */
    .hamburger-btn {
        display: none;
    }

    /* Adjust page content - no top navbar padding needed */
    .content-wrapper,
    .main-content,
    .home,
    .seasonal-page,
    .forum-layout,
    .user-profile-page,
    .anime-page,
    .schedule-page,
    .auth-page {
        padding-top: 20px !important;
    }

    /* Add bottom padding for floating nav */
    body {
        padding-bottom: 90px;
    }

    /* User dropdown hidden - use mobile menu */
    .user-dropdown {
        display: none;
    }

    /* Notification dropdown touch optimization */
    .notification-dropdown {
        position: fixed;
        top: 20px;
        left: 12px;
        right: 12px;
        width: auto;
        max-height: calc(100vh - 40px);
        transform: none;
    }

    .nav-notification-wrapper:hover .notification-dropdown {
        opacity: 0;
        visibility: hidden;
    }

    .notification-dropdown.show {
        opacity: 1;
        visibility: visible;
    }

    /* Touch target minimums */
    button,
    [role="button"],
    input[type="submit"],
    input[type="button"],
    .btn-primary,
    .btn-action,
    a.btn-primary {
        min-height: 44px;
    }

    /* Prevent iOS zoom on input focus */
    input:not([type="checkbox"]):not([type="radio"]),
    select,
    textarea {
        font-size: 16px !important;
    }

    /* === MOBILE FOOTER - Compact Horizontal === */
    .footer {
        padding: 24px 16px 20px;
        margin-top: 24px;
        text-align: center;
    }

    .footer-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 16px;
        padding: 0;
        margin: 0;
    }

    .footer-main {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 12px;
        width: 100%;
    }

    /* Brand centered at top */
    .footer-brand {
        width: 100%;
        margin-bottom: 4px;
    }

    .footer-brand .footer-copyright {
        font-size: 0.7rem;
    }

    /* Hide column headers on mobile */
    .footer-column h4 {
        display: none;
    }

    /* Flatten columns - all links flow together */
    .footer-column {
        display: contents;
    }

    .footer-links {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 0;
    }

    .footer-links li {
        display: inline;
    }

    /* Compact link pills */
    .footer-links a {
        padding: 8px 14px;
        font-size: 0.8rem;
        min-height: 40px;
        display: inline-flex;
        align-items: center;
        color: var(--text-secondary);
    }

    .footer-links a:hover {
        color: var(--text-primary);
    }

    /* Container padding */
    .container {
        padding: 0 16px;
    }

    /* Page title mobile sizing */
    .page-title {
        font-size: 1.75rem;
    }
}

/* ============================================
   MOBILE BREAKPOINTS - 600px (Large Phone)
   ============================================ */
@media (max-width: 600px) {
    .navbar {
        height: 50px;
        width: calc(100% - 12px);
    }

    .nav-content {
        padding: 0 10px;
    }

    .logo img {
        height: 18px;
    }

    .hamburger-btn {
        width: 40px;
        height: 40px;
    }

    .hamburger-btn span {
        width: 16px;
    }

    .user-nav-btn {
        width: 40px;
        height: 40px;
    }

    .nav-notification-btn {
        width: 36px;
        height: 36px;
    }

    /* Mobile menu adjustments */
    .mobile-menu-overlay {
        padding-top: 80px;
    }

    .mobile-nav-links > a,
    .mobile-nav-item > button {
        padding: 16px 14px;
        font-size: 1.1rem;
        min-height: 52px;
    }

    .mobile-dropdown a {
        padding: 14px 18px;
        min-height: 48px;
    }

    /* Page title smaller */
    .page-title {
        font-size: 1.5rem;
    }
}

/* ============================================
   MOBILE BREAKPOINTS - 480px (Small Phone)
   ============================================ */
@media (max-width: 480px) {
    .navbar {
        width: calc(100% - 8px);
    }

    /* Footer - more compact on small phones */
    .footer {
        padding: 20px 10px 16px;
    }

    .footer-container {
        gap: 12px;
    }

    .footer-main {
        gap: 10px;
    }

    .footer-links a {
        font-size: 0.75rem;
        padding: 6px 10px;
        min-height: 36px;
    }

    /* Mobile menu final adjustments */
    .mobile-nav-links {
        padding: 0 16px;
    }

    .mobile-auth-section {
        padding: 20px 16px;
    }

    .page-title {
        font-size: 1.35rem;
    }
}

/* ============================================
   TOUCH DEVICE OPTIMIZATIONS
   ============================================ */
@media (hover: none) and (pointer: coarse) {
    /* Remove hover effects on touch devices */
    .nav-item:hover .nav-dropdown,
    .nav-user-wrapper:hover .user-dropdown {
        opacity: 0;
        visibility: hidden;
    }

    /* Better tap feedback */
    button,
    a,
    [role="button"] {
        -webkit-tap-highlight-color: rgba(var(--primary-rgb), 0.15);
    }

    /* Ensure buttons have good tap areas */
    .btn-primary,
    .btn-action {
        min-height: 48px;
    }
}

/* ============================================
   SHARED MODAL STYLES
   Used by Modal.js for alerts, confirms, etc.
   ============================================ */

/* Body scroll lock when modal is open */
body.modal-open {
    overflow: hidden !important;
    position: fixed !important;
    width: 100% !important;
    height: 100% !important;
    top: 0 !important;
    left: 0 !important;
}

body.modal-open #sharedModalContainer {
    pointer-events: auto;
}

/* Modal container - ensures full screen coverage */
#sharedModalContainer {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100vh;
    z-index: 999999;
    pointer-events: none;
}

#sharedModalContainer .modal-overlay.open {
    pointer-events: auto;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
}

.modal-overlay.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* Contribution modal - visible when display is set via JS */
.modal-overlay.contribution-modal[style*="display: flex"],
.modal-overlay.contribution-modal[style*="display:flex"] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

/* =============================================
   SHARED MODAL SYSTEM - Glassmorphism Design
   All properties use !important to prevent
   page-specific CSS from overriding.
   ============================================= */

/* Overlay: lighter so blur shows through the modal */
.modal-overlay:has(> .shared-modal) {
    background: rgba(0, 0, 0, 0.45) !important;
    backdrop-filter: blur(4px) !important;
    -webkit-backdrop-filter: blur(4px) !important;
}

/* Modal card */
.modal.shared-modal {
    background: rgba(10, 10, 14, 0.82) !important;
    backdrop-filter: blur(24px) saturate(1.3) !important;
    -webkit-backdrop-filter: blur(24px) saturate(1.3) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 16px !important;
    max-width: 450px !important;
    width: 90% !important;
    transform: scale(0.95) translateY(10px) !important;
    transition: transform 0.25s cubic-bezier(0.21, 1.02, 0.73, 1) !important;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.06) !important;
    overflow: hidden !important;
    padding: 0 !important;
    margin: 0 !important;
}

.modal-overlay.open .modal.shared-modal {
    transform: scale(1) translateY(0) !important;
}

/* Danger: subtle red border only */
.modal.shared-modal.modal-danger {
    border-color: rgba(239, 68, 68, 0.25) !important;
}

.modal.shared-modal .delete-warning {
    background: rgba(255, 255, 255, 0.03) !important;
    border-color: rgba(255, 255, 255, 0.06) !important;
}

/* --- Header: seamless, no border, no background --- */
.modal.shared-modal .modal-header {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    padding: 22px 24px 0 !important;
    border: none !important;
    border-bottom: none !important;
    background: transparent !important;
    position: relative !important;
    z-index: auto !important;
    margin: 0 !important;
}

.modal.shared-modal .modal-icon {
    width: 24px !important;
    height: 24px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-shrink: 0 !important;
    background: none !important;
    border-radius: 0 !important;
    border: none !important;
    padding: 0 !important;
}

.modal.shared-modal .modal-icon svg {
    width: 22px !important;
    height: 22px !important;
}

.modal.shared-modal .modal-icon.icon-info { color: #8b5cf6 !important; }
.modal.shared-modal .modal-icon.icon-success { color: #22c55e !important; }
.modal.shared-modal .modal-icon.icon-warning { color: #eab308 !important; }
.modal.shared-modal .modal-icon.icon-danger { color: #ef4444 !important; }
.modal.shared-modal .modal-icon.icon-question { color: var(--primary, #8b5cf6) !important; }

.modal.shared-modal .modal-header h3 {
    flex: 1 !important;
    font-family: var(--font-display, 'Outfit', sans-serif) !important;
    font-size: 1.1rem !important;
    font-weight: 600 !important;
    color: var(--text-primary, #fafafa) !important;
    margin: 0 !important;
}

.modal.shared-modal .modal-close {
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    min-height: 32px !important;
    border-radius: 8px !important;
    border: none !important;
    background: transparent !important;
    color: var(--text-muted, #52525b) !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.15s ease !important;
    padding: 0 !important;
}

.modal.shared-modal .modal-close:hover {
    background: rgba(255, 255, 255, 0.08) !important;
    color: var(--text-primary, #fafafa) !important;
}

.modal.shared-modal .modal-close svg {
    width: 18px !important;
    height: 18px !important;
}

/* --- Body: seamless, same bg as card --- */
.modal.shared-modal .modal-body {
    padding: 16px 24px !important;
    background: transparent !important;
    border: none !important;
    margin: 0 !important;
}

.modal.shared-modal .modal-message {
    font-size: 0.93rem !important;
    line-height: 1.6 !important;
    color: var(--text-secondary, #a1a1aa) !important;
    margin: 0 !important;
}

/* Glass form inputs */
.modal.shared-modal .form-group input,
.modal.shared-modal .form-group textarea,
.modal.shared-modal .form-group select {
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    border-radius: 10px !important;
    color: var(--text-primary, #fafafa) !important;
    transition: border-color 0.2s ease, box-shadow 0.2s ease !important;
}

.modal.shared-modal .form-group input:focus,
.modal.shared-modal .form-group textarea:focus,
.modal.shared-modal .form-group select:focus {
    outline: none !important;
    border-color: var(--primary, #8b5cf6) !important;
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb, 139, 92, 246), 0.15) !important;
}

.modal.shared-modal .form-group label {
    color: var(--text-secondary, #a1a1aa) !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
    text-transform: none !important;
}

/* --- Footer: seamless, no border, no background --- */
.modal.shared-modal .modal-footer {
    display: flex !important;
    gap: 10px !important;
    justify-content: flex-end !important;
    background: transparent !important;
    padding: 0 24px 22px !important;
    border: none !important;
    border-top: none !important;
    margin: 0 !important;
    flex-direction: row !important;
}

/* Button base */
.modal.shared-modal .modal-footer button {
    padding: 10px 20px !important;
    border-radius: 10px !important;
    font-family: var(--font-body, 'Space Grotesk', sans-serif) !important;
    font-size: 0.88rem !important;
    font-weight: 500 !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    border: none !important;
    width: auto !important;
}

/* Cancel / secondary */
.modal.shared-modal .btn-cancel {
    background: rgba(255, 255, 255, 0.06) !important;
    color: var(--text-secondary, #a1a1aa) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.modal.shared-modal .btn-cancel:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.14) !important;
    color: var(--text-primary, #fafafa) !important;
}

/* Primary */
.modal.shared-modal .btn-primary,
.modal.shared-modal .btn-save {
    background: var(--primary, #8b5cf6) !important;
    color: white !important;
    box-shadow: 0 2px 8px rgba(139, 92, 246, 0.25) !important;
}

.modal.shared-modal .btn-primary:hover,
.modal.shared-modal .btn-save:hover {
    box-shadow: 0 4px 16px rgba(139, 92, 246, 0.35) !important;
    filter: brightness(1.1) !important;
}

/* Danger */
.modal.shared-modal .btn-danger {
    background: #ef4444 !important;
    color: white !important;
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3) !important;
}

.modal.shared-modal .btn-danger:hover {
    background: #dc2626 !important;
    box-shadow: 0 4px 16px rgba(239, 68, 68, 0.4) !important;
}

/* Secondary */
.modal.shared-modal .btn-secondary {
    background: rgba(255, 255, 255, 0.06) !important;
    color: var(--text-secondary, #a1a1aa) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.modal.shared-modal .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    border-color: rgba(255, 255, 255, 0.14) !important;
}

/* Admin Popup */
.modal.shared-modal.admin-popup {
    max-width: 500px !important;
}

.modal.shared-modal.admin-popup .admin-popup-content {
    font-size: 0.95rem !important;
    line-height: 1.7 !important;
    color: var(--text-secondary, #a1a1aa) !important;
}

.modal.shared-modal.admin-popup .admin-popup-content p {
    margin: 0 0 12px !important;
}

.modal.shared-modal.admin-popup .admin-popup-content p:last-child {
    margin-bottom: 0 !important;
}

.modal.shared-modal.admin-popup .admin-popup-content a {
    color: var(--primary, #8b5cf6) !important;
    text-decoration: underline !important;
}

.modal.shared-modal.admin-popup .admin-popup-content a:hover {
    color: var(--primary-hover, var(--primary-hover)) !important;
}

/* --- Shared Modal: Mobile --- */
@media (max-width: 768px) {
    .modal.shared-modal {
        max-width: 340px !important;
        width: 92% !important;
    }

    .modal.shared-modal .modal-header {
        padding: 18px 18px 0 !important;
    }

    .modal.shared-modal .modal-header h3 {
        font-size: 1rem !important;
    }

    .modal.shared-modal .modal-body {
        padding: 14px 18px !important;
    }

    .modal.shared-modal .modal-footer {
        padding: 0 18px 18px !important;
    }
}

@media (max-width: 600px) {
    .modal.shared-modal {
        max-width: 300px !important;
    }
}

/* =============================================
   POPUP BANNERS (Top of Page Announcements)
   ========================================= */

.popup-banner-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0;
    pointer-events: none;
}

.popup-banner {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background: var(--bg-elevated, #1a1a22);
    border-bottom: 1px solid var(--border, rgba(255, 255, 255, 0.08));
    pointer-events: auto;
    transform: translateY(-100%);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.popup-banner-visible {
    transform: translateY(0);
    opacity: 1;
}

.popup-banner-hiding {
    transform: translateY(-100%);
    opacity: 0;
}

/* Banner icon */
.popup-banner-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.popup-banner-icon svg {
    width: 18px;
    height: 18px;
}

/* Icon type colors - solid opaque backgrounds */
.popup-banner-info {
    background: linear-gradient(135deg, #1a2332 0%, #151c28 100%);
    border-left: 3px solid #3b82f6;
}

.popup-banner-info .popup-banner-icon {
    background: rgba(59, 130, 246, 0.2);
    color: #3b82f6;
}

.popup-banner-success {
    background: linear-gradient(135deg, #172420 0%, #131d1a 100%);
    border-left: 3px solid #22c55e;
}

.popup-banner-success .popup-banner-icon {
    background: rgba(34, 197, 94, 0.2);
    color: #22c55e;
}

.popup-banner-warning {
    background: linear-gradient(135deg, #252118 0%, #1e1a14 100%);
    border-left: 3px solid #eab308;
}

.popup-banner-warning .popup-banner-icon {
    background: rgba(234, 179, 8, 0.2);
    color: #eab308;
}

.popup-banner-danger {
    background: linear-gradient(135deg, #251818 0%, #1e1414 100%);
    border-left: 3px solid #ef4444;
}

.popup-banner-danger .popup-banner-icon {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

/* Banner content */
.popup-banner-content {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.popup-banner-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
}

.popup-banner-message {
    font-size: 0.85rem;
    color: var(--text-secondary, #a1a1aa);
}

/* Banner actions */
.popup-banner-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.popup-banner-btn {
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
    border: none;
    white-space: nowrap;
}

.popup-banner-btn-primary {
    background: var(--primary, #8b5cf6);
    color: white;
}

.popup-banner-btn-primary:hover {
    background: var(--primary-hover, #7c3aed);
}

.popup-banner-btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-secondary, #a1a1aa);
}

.popup-banner-btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    color: var(--text-primary, #fafafa);
}

.popup-banner-btn-danger {
    background: #ef4444;
    color: white;
}

.popup-banner-btn-danger:hover {
    background: #dc2626;
}

/* Banner close button */
.popup-banner-close {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: none;
    background: transparent;
    color: var(--text-muted, #71717a);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
    flex-shrink: 0;
    margin-left: 8px;
}

.popup-banner-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary, #fafafa);
}

/* Mobile responsive */
@media (max-width: 640px) {
    .popup-banner {
        flex-wrap: wrap;
        padding: 12px 16px;
        gap: 10px;
    }

    .popup-banner-content {
        flex-basis: calc(100% - 44px);
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }

    .popup-banner-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .popup-banner-close {
        position: absolute;
        top: 8px;
        right: 8px;
        margin-left: 0;
    }

    .popup-banner {
        position: relative;
        padding-right: 48px;
    }
}

/* =============================================
   BUG REPORT & USER REPORT MODALS
   ============================================= */

/* Modal overlay for report modals - ensure high z-index */
#bugReportModal,
#userReportModal {
    z-index: 999999 !important;
}

/* Base modal styles for report modals - use !important to override page-specific modal styles */
.modal.bug-report-modal,
.modal.user-report-modal {
    width: 100% !important;
    max-width: 520px !important;
    background: linear-gradient(180deg, rgba(30, 30, 46, 0.98) 0%, rgba(18, 18, 26, 0.98) 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    border-radius: 16px !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5) !important;
    transform: scale(0.95) translateY(20px) !important;
    transition: transform 0.3s ease !important;
    overflow: hidden !important;
    display: flex !important;
    flex-direction: column !important;
    max-height: 90vh !important;
}

.modal-overlay.open .modal.bug-report-modal,
.modal-overlay.open .modal.user-report-modal {
    transform: scale(1) translateY(0) !important;
}

/* Modal header */
.bug-report-modal .modal-header,
.user-report-modal .modal-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.bug-report-modal .modal-header h3,
.user-report-modal .modal-header h3 {
    flex: 1;
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
    margin: 0;
}

.bug-report-modal .modal-icon,
.user-report-modal .modal-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.bug-report-modal .modal-icon svg,
.user-report-modal .modal-icon svg {
    width: 22px;
    height: 22px;
}

.bug-report-modal .modal-icon.icon-warning,
.user-report-modal .modal-icon.icon-warning {
    background: rgba(234, 179, 8, 0.15);
    color: #eab308;
}

.bug-report-modal .modal-close,
.user-report-modal .modal-close {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-muted, #52525b);
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.2s;
}

.bug-report-modal .modal-close:hover,
.user-report-modal .modal-close:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary, #fafafa);
}

.bug-report-modal .modal-close svg,
.user-report-modal .modal-close svg {
    width: 18px;
    height: 18px;
}

/* Modal body */
.bug-report-modal .modal-body,
.user-report-modal .modal-body {
    padding: 20px 24px;
    overflow-y: auto;
    flex: 1;
}

/* Form groups */
.bug-report-modal .form-group,
.user-report-modal .form-group {
    margin-bottom: 16px;
}

.bug-report-modal .form-group:last-child,
.user-report-modal .form-group:last-child {
    margin-bottom: 0;
}

.bug-report-modal .form-group label,
.user-report-modal .form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary, #a1a1aa);
    margin-bottom: 8px;
}

.bug-report-modal .form-group .required,
.user-report-modal .form-group .required {
    color: #ef4444;
}

/* Input and textarea styling */
.bug-report-modal input[type="text"],
.bug-report-modal input[type="email"],
.bug-report-modal textarea,
.bug-report-modal select,
.user-report-modal input[type="text"],
.user-report-modal textarea,
.user-report-modal select {
    width: 100%;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: var(--text-primary, #fafafa);
    font-size: 0.9rem;
    font-family: inherit;
    transition: all 0.2s;
    box-sizing: border-box;
}

.bug-report-modal input[type="text"]:focus,
.bug-report-modal input[type="email"]:focus,
.bug-report-modal textarea:focus,
.bug-report-modal select:focus,
.user-report-modal input[type="text"]:focus,
.user-report-modal textarea:focus,
.user-report-modal select:focus {
    outline: none;
    border-color: var(--primary, #8b5cf6);
    background: rgba(255, 255, 255, 0.06);
}

.bug-report-modal input::placeholder,
.bug-report-modal textarea::placeholder,
.user-report-modal input::placeholder,
.user-report-modal textarea::placeholder {
    color: var(--text-muted, #52525b);
}

.bug-report-modal textarea,
.user-report-modal textarea {
    resize: vertical;
    min-height: 80px;
}

.bug-report-modal select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23a1a1aa'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 40px;
}

.bug-report-modal select option {
    background: #1a1a22;
    color: var(--text-primary);
}

/* File input styling */
.bug-report-modal .file-input-wrapper {
    position: relative;
}

.bug-report-modal .file-input-wrapper input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}

.bug-report-modal .file-input-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(255, 255, 255, 0.02);
    border: 2px dashed rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.bug-report-modal .file-input-wrapper:hover .file-input-display {
    border-color: var(--primary, #8b5cf6);
    background: rgba(var(--primary-rgb), 0.05);
}

.bug-report-modal .file-input-display svg {
    width: 40px;
    height: 40px;
    color: var(--text-muted, #52525b);
    margin-bottom: 8px;
}

.bug-report-modal .file-input-display span {
    color: var(--text-muted, #52525b);
    font-size: 0.85rem;
}

/* Screenshot preview */
.bug-report-modal .screenshot-preview {
    margin-top: 12px;
}

.bug-report-modal .screenshot-preview .preview-container {
    position: relative;
    display: inline-block;
}

.bug-report-modal .screenshot-preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.bug-report-modal .screenshot-preview .remove-preview {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 28px;
    height: 28px;
    background: rgba(239, 68, 68, 0.9);
    border: none;
    border-radius: 6px;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.bug-report-modal .screenshot-preview .remove-preview:hover {
    background: #ef4444;
}

.bug-report-modal .screenshot-preview .remove-preview svg {
    width: 16px;
    height: 16px;
}

/* Auto-captured info chips */
.bug-report-modal .auto-captured label {
    margin-bottom: 10px;
}

.bug-report-modal .auto-info {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.bug-report-modal .info-chip {
    display: inline-flex;
    padding: 4px 10px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    font-size: 0.75rem;
    color: var(--text-secondary, #a1a1aa);
    cursor: help;
}

.bug-report-modal .info-row {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    width: 100%;
}

.bug-report-modal .info-chip.error-chip {
    background: rgba(239, 68, 68, 0.15);
    border-color: rgba(239, 68, 68, 0.3);
    color: #f87171;
}

.bug-report-modal .diagnostics-note {
    font-size: 0.75rem;
    color: var(--text-muted, #6b7280);
    font-weight: 400;
}

.bug-report-modal .diagnostics-details {
    margin-top: 10px;
}

.bug-report-modal .diagnostics-details summary {
    cursor: pointer;
    font-size: 0.75rem;
    color: var(--text-muted, #6b7280);
    padding: 4px 0;
}

.bug-report-modal .diagnostics-details summary:hover {
    color: var(--text-secondary, #a1a1aa);
}

.bug-report-modal .diagnostics-details pre {
    margin-top: 8px;
    padding: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    font-size: 0.7rem;
    color: var(--text-secondary, #a1a1aa);
    overflow-x: auto;
    max-height: 200px;
    white-space: pre-wrap;
    word-break: break-all;
}

/* Modal footer */
.bug-report-modal .modal-footer,
.user-report-modal .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.2);
}

.bug-report-modal .btn-cancel,
.user-report-modal .btn-cancel {
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary, #a1a1aa);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.bug-report-modal .btn-cancel:hover,
.user-report-modal .btn-cancel:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary, #fafafa);
}

.bug-report-modal .btn-primary,
.user-report-modal .btn-danger {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.bug-report-modal .btn-primary {
    background: var(--primary, #8b5cf6);
    color: white;
}

.bug-report-modal .btn-primary:hover {
    background: var(--primary-hover, var(--primary-hover));
}

.bug-report-modal .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.user-report-modal .btn-danger {
    background: #ef4444;
    color: white;
}

.user-report-modal .btn-danger:hover {
    background: #dc2626;
}

/* User report specific - reason options */
.user-report-modal .report-target {
    font-size: 0.9rem;
    color: var(--text-secondary, #a1a1aa);
    margin-bottom: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.user-report-modal .report-target strong {
    color: var(--text-primary, #fafafa);
}

.user-report-modal .reason-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.user-report-modal .reason-option {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s;
}

.user-report-modal .reason-option:hover {
    background: rgba(255, 255, 255, 0.04);
    border-color: rgba(255, 255, 255, 0.1);
}

.user-report-modal .reason-option:has(input:checked) {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary, #8b5cf6);
}

.user-report-modal .reason-option input[type="radio"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary, #8b5cf6);
    margin-top: 2px;
    flex-shrink: 0;
}

.user-report-modal .option-content {
    flex: 1;
}

.user-report-modal .option-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary, #fafafa);
    margin-bottom: 2px;
}

.user-report-modal .option-desc {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted, #52525b);
}

/* =============================================
   CONTRIBUTION MODAL STYLES
   ============================================= */

.contribution-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 999999;
    align-items: center;
    justify-content: center;
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
}

.contribution-modal-container {
    width: 100%;
    max-width: 600px;
    background: linear-gradient(180deg, rgba(30, 30, 46, 0.98) 0%, rgba(18, 18, 26, 0.98) 100%);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.5);
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.contribution-modal-container .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contribution-modal-container .modal-header h2 {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
    margin: 0;
}

.contribution-modal-container .modal-close {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-muted, #52525b);
    cursor: pointer;
    border-radius: 8px;
    font-size: 1.5rem;
    transition: all 0.2s;
}

.contribution-modal-container .modal-close:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary, #fafafa);
}

/* Step indicators */
.contribution-steps {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 16px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contribution-steps .step {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.04);
    transition: all 0.2s;
}

.contribution-steps .step .step-number {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted);
}

.contribution-steps .step .step-label {
    font-size: 0.8rem;
    color: var(--text-muted);
}

.contribution-steps .step.active {
    background: rgba(var(--primary-rgb), 0.15);
}

.contribution-steps .step.active .step-number {
    background: var(--primary, #8b5cf6);
    color: white;
}

.contribution-steps .step.active .step-label {
    color: var(--text-primary);
}

.contribution-steps .step.completed .step-number {
    background: #22c55e;
    color: white;
}

.contribution-steps .step.completed .step-number::before {
    content: '\2713';
}

/* Modal body */
.contribution-modal-container .modal-body {
    padding: 24px;
    overflow-y: auto;
    flex: 1;
}

.contribution-step-content {
    min-height: 200px;
}

.contribution-step-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 8px 0;
}

.contribution-step-content .step-description {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin: 0 0 24px 0;
}

/* Content type grid (step 1) */
.content-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.content-type-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.content-type-option:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
}

.content-type-option.selected {
    background: rgba(var(--primary-rgb), 0.15);
    border-color: var(--primary, #8b5cf6);
}

.content-type-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.content-type-icon svg {
    width: 32px;
    height: 32px;
    color: var(--text-secondary);
}

.content-type-option.selected .content-type-icon svg {
    color: var(--primary, #8b5cf6);
}

.content-type-label {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
}

/* Action type grid (step 2) */
.action-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}

.action-type-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 24px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.action-type-option:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.1);
}

.action-type-option.selected {
    background: rgba(var(--primary-rgb), 0.15);
    border-color: var(--primary, #8b5cf6);
}

.action-type-option svg {
    width: 28px;
    height: 28px;
    color: var(--text-secondary);
}

.action-type-option.selected svg {
    color: var(--primary, #8b5cf6);
}

.action-type-option span {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary);
}

.action-type-option p {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin: 0;
}

/* Edit search section */
.edit-search-section {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.edit-search-section label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 10px;
}

.search-input-wrapper input {
    width: 100%;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    color: var(--text-primary);
    font-size: 0.9rem;
    box-sizing: border-box;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: var(--primary, #8b5cf6);
}

.search-results {
    margin-top: 12px;
    max-height: 200px;
    overflow-y: auto;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    cursor: pointer;
    margin-bottom: 8px;
    transition: all 0.2s;
}

.search-result-item:hover {
    background: rgba(255, 255, 255, 0.08);
}

.search-result-item img {
    width: 40px;
    height: 56px;
    object-fit: cover;
    border-radius: 4px;
}

.search-result-item .no-image {
    width: 40px;
    height: 56px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.search-result-item .result-info {
    flex: 1;
}

.search-result-item .result-title {
    display: block;
    font-size: 0.9rem;
    color: var(--text-primary);
    font-weight: 500;
}

.search-result-item .result-id {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
}

.selected-target {
    padding: 12px;
    background: rgba(34, 197, 94, 0.15);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-radius: 8px;
    color: #22c55e;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.selected-target .clear-selection {
    margin-left: auto;
    background: transparent;
    border: none;
    color: inherit;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0 4px;
}

.search-loading,
.no-results,
.search-error {
    padding: 16px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Form styling (step 3) */
.contribution-form {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 8px;
}

.contribution-form::-webkit-scrollbar {
    width: 6px;
}

.contribution-form::-webkit-scrollbar-track {
    background: transparent;
}

.contribution-form::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.form-section {
    margin-bottom: 24px;
}

.form-section h4 {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-secondary);
    margin-bottom: 6px;
}

.contribution-form input[type="text"],
.contribution-form input[type="url"],
.contribution-form input[type="number"],
.contribution-form input[type="date"],
.contribution-form textarea,
.contribution-form select {
    width: 100%;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: var(--text-primary);
    font-size: 0.85rem;
    font-family: inherit;
    box-sizing: border-box;
    transition: all 0.2s;
}

.contribution-form input:focus,
.contribution-form textarea:focus,
.contribution-form select:focus {
    outline: none;
    border-color: var(--primary, #8b5cf6);
    background: rgba(255, 255, 255, 0.06);
}

.contribution-form input::placeholder,
.contribution-form textarea::placeholder {
    color: var(--text-muted);
}

.contribution-form textarea {
    resize: vertical;
    min-height: 80px;
}

.contribution-form select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23a1a1aa'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
    padding-right: 34px;
}

.contribution-form select option {
    background: #1a1a22;
    color: var(--text-primary);
}

/* Genre grid */
.genre-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.genre-checkbox {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.genre-checkbox:hover {
    background: rgba(255, 255, 255, 0.08);
}

.genre-checkbox:has(input:checked) {
    background: rgba(var(--primary-rgb), 0.15);
    border-color: var(--primary, #8b5cf6);
    color: var(--text-primary);
}

.genre-checkbox input {
    display: none;
}

/* Review card (step 4) */
.review-card {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 16px;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 14px 16px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.review-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.review-badge.add {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.review-badge.edit {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

.review-type {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary);
}

.review-content {
    padding: 16px;
}

.review-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.review-item:last-child {
    border-bottom: none;
}

.review-label {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.review-value {
    font-size: 0.85rem;
    color: var(--text-primary);
    font-weight: 500;
    text-align: right;
    max-width: 60%;
}

.review-description {
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.review-description .review-label {
    display: block;
    margin-bottom: 8px;
}

.review-description p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.submission-note {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 14px 16px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 10px;
}

.submission-note svg {
    width: 20px;
    height: 20px;
    color: #3b82f6;
    flex-shrink: 0;
    margin-top: 2px;
}

.submission-note p {
    margin: 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Modal footer */
.contribution-modal-container .modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.2);
}

.contribution-modal-container .btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.contribution-modal-container .btn-secondary {
    background: rgba(255, 255, 255, 0.04);
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.contribution-modal-container .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
}

.contribution-modal-container .btn-primary {
    background: var(--primary, #8b5cf6);
    color: white;
    border: none;
}

.contribution-modal-container .btn-primary:hover {
    background: var(--primary-hover, var(--primary-hover));
}

.contribution-modal-container .btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Mobile responsive */
@media (max-width: 600px) {
    .contribution-modal-container {
        max-width: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .contribution-steps {
        gap: 4px;
        padding: 12px 16px;
    }

    .contribution-steps .step {
        padding: 6px 8px;
    }

    .contribution-steps .step .step-label {
        display: none;
    }

    .content-type-grid,
    .action-type-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .contribution-modal-container .modal-body {
        padding: 16px;
    }

    .contribution-form {
        max-height: 350px;
    }
}

/* =============================================
   SUGGEST EDIT BUTTON & CONTRIBUTE SIDEBAR
   ============================================= */

/* Sidebar contribute section - subtle styling to match other sections */
.sidebar-contribute {
    /* No special background or border - inherits from .sidebar-section */
}

.sidebar-contribute h4 {
    color: var(--text-secondary);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* No emoji before the heading */

.btn-suggest-edit {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 14px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--text-secondary);
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-suggest-edit:hover {
    background: var(--bg-hover);
    border-color: var(--text-tertiary);
    color: var(--text-primary);
}

.btn-suggest-edit:active {
    transform: translateY(0);
}

.btn-suggest-edit svg {
    width: 16px;
    height: 16px;
    color: var(--text-tertiary);
}

.btn-suggest-edit:hover svg {
    color: var(--text-secondary);
}

.contribute-hint {
    margin-top: 10px;
    font-size: 0.75rem;
    color: var(--text-tertiary);
    line-height: 1.4;
}

/* Inline contribute section (for pages without sidebar) */
.contribute-inline {
    max-width: 400px;
    margin: 40px auto 20px;
    padding: 24px;
    border-radius: 12px;
    text-align: center;
}

.contribute-inline h3 {
    color: var(--text-secondary);
    font-size: 1rem;
    margin-bottom: 16px;
}

/* ========================================
   Contribution Modal Styles
   ======================================== */

.contribution-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    padding: 20px;
    box-sizing: border-box;
}

.contribution-modal-container {
    background: var(--bg-elevated, #1a1a22);
    border: 1px solid var(--border, rgba(255, 255, 255, 0.08));
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    animation: modalSlideIn 0.2s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.95) translateY(10px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.contribution-modal .modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contribution-modal .modal-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
    margin: 0;
}

.contribution-modal .modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border: none;
    border-radius: 8px;
    color: var(--text-muted, #71717a);
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.2s;
}

.contribution-modal .modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary, #fafafa);
}

/* Progress Steps */
.contribution-steps {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 16px 24px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contribution-steps .step {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 20px;
    transition: all 0.2s;
}

.contribution-steps .step-number {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-muted, #71717a);
}

.contribution-steps .step-label {
    font-size: 0.85rem;
    color: var(--text-muted, #71717a);
}

.contribution-steps .step.active {
    background: rgba(var(--primary-rgb), 0.15);
}

.contribution-steps .step.active .step-number {
    background: var(--primary, #8b5cf6);
    color: white;
}

.contribution-steps .step.active .step-label {
    color: var(--primary, #8b5cf6);
}

.contribution-steps .step.completed .step-number {
    background: #22c55e;
    color: white;
}

.contribution-steps .step.completed .step-label {
    color: #22c55e;
}

/* Modal Body */
.contribution-modal .modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.contribution-step-content h3 {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
    margin: 0 0 8px 0;
}

.contribution-step-content .step-description {
    font-size: 0.9rem;
    color: var(--text-muted, #71717a);
    margin: 0 0 24px 0;
}

/* Content Type Grid (Step 1) */
.content-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.content-type-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 16px;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.content-type-option:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.content-type-option.selected {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary, #8b5cf6);
}

.content-type-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    color: var(--text-secondary, #a1a1aa);
}

.content-type-option.selected .content-type-icon {
    background: rgba(var(--primary-rgb), 0.2);
    color: var(--primary, #8b5cf6);
}

.content-type-icon svg {
    width: 24px;
    height: 24px;
}

.content-type-label {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--text-primary, #fafafa);
}

/* Action Type Grid (Step 2) */
.action-type-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    margin-bottom: 24px;
}

.action-type-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 24px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 2px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
}

.action-type-option:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.1);
}

.action-type-option.selected {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary, #8b5cf6);
}

.action-type-option svg {
    width: 32px;
    height: 32px;
    color: var(--text-secondary, #a1a1aa);
}

.action-type-option.selected svg {
    color: var(--primary, #8b5cf6);
}

.action-type-option span {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
}

.action-type-option p {
    font-size: 0.8rem;
    color: var(--text-muted, #71717a);
    margin: 0;
}

/* Edit Search */
.edit-search-section {
    margin-top: 24px;
}

.edit-search-section label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary, #a1a1aa);
    margin-bottom: 8px;
}

.search-input-wrapper {
    position: relative;
}

.search-input-wrapper input {
    width: 100%;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: var(--text-primary, #fafafa);
    font-size: 0.95rem;
    box-sizing: border-box;
}

.search-input-wrapper input:focus {
    outline: none;
    border-color: var(--primary, #8b5cf6);
}

.search-results {
    margin-top: 12px;
    max-height: 200px;
    overflow-y: auto;
}

.search-result-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    cursor: pointer;
    margin-bottom: 8px;
    transition: all 0.2s;
}

.search-result-item:hover {
    background: rgba(255, 255, 255, 0.06);
}

.search-result-item img {
    width: 40px;
    height: 56px;
    object-fit: cover;
    border-radius: 4px;
}

.search-result-item .no-image {
    width: 40px;
    height: 56px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
}

.search-result-item .result-info {
    display: flex;
    flex-direction: column;
}

.search-result-item .result-title {
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-primary, #fafafa);
}

.search-result-item .result-id {
    font-size: 0.75rem;
    color: var(--text-muted, #71717a);
}

.selected-target {
    padding: 12px 16px;
    background: rgba(34, 197, 94, 0.1);
    border: 1px solid rgba(34, 197, 94, 0.2);
    border-radius: 8px;
    color: #22c55e;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.selected-target .clear-selection {
    background: none;
    border: none;
    color: #22c55e;
    font-size: 1.25rem;
    cursor: pointer;
    padding: 0 4px;
}

.search-loading,
.no-results,
.search-error {
    padding: 16px;
    text-align: center;
    color: var(--text-muted, #71717a);
    font-size: 0.9rem;
}

/* Form Styles (Step 3) */
.contribution-form .form-section {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.contribution-form .form-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.contribution-form .form-section h4 {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-primary, #fafafa);
    margin: 0 0 16px 0;
}

.contribution-form .form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.contribution-form .form-group {
    margin-bottom: 16px;
}

.contribution-form .form-group:last-child {
    margin-bottom: 0;
}

.contribution-form label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary, #a1a1aa);
    margin-bottom: 6px;
}

.contribution-form input,
.contribution-form select,
.contribution-form textarea {
    width: 100%;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    color: var(--text-primary, #fafafa);
    font-size: 0.9rem;
    font-family: inherit;
    box-sizing: border-box;
}

.contribution-form input:focus,
.contribution-form select:focus,
.contribution-form textarea:focus {
    outline: none;
    border-color: var(--primary, #8b5cf6);
}

.contribution-form textarea {
    resize: vertical;
    min-height: 100px;
}

.contribution-form select {
    cursor: pointer;
}

/* Genre Grid */
.genre-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.genre-checkbox {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s;
}

.genre-checkbox:hover {
    background: rgba(255, 255, 255, 0.06);
}

.genre-checkbox input {
    width: auto;
    margin: 0;
}

.genre-checkbox input:checked + span {
    color: var(--primary, #8b5cf6);
}

.genre-checkbox span {
    font-size: 0.85rem;
    color: var(--text-secondary, #a1a1aa);
}

/* Review Card (Step 4) */
.review-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
}

.review-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.review-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
}

.review-badge.add {
    background: rgba(34, 197, 94, 0.15);
    color: #22c55e;
}

.review-badge.edit {
    background: rgba(59, 130, 246, 0.15);
    color: #3b82f6;
}

.review-type {
    font-size: 0.9rem;
    color: var(--text-secondary, #a1a1aa);
}

.review-content {
    padding: 16px;
}

.review-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.04);
}

.review-item:last-child {
    border-bottom: none;
}

.review-label {
    font-size: 0.85rem;
    color: var(--text-muted, #71717a);
}

.review-value {
    font-size: 0.85rem;
    color: var(--text-primary, #fafafa);
    text-align: right;
}

.review-description {
    padding: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.review-description .review-label {
    display: block;
    margin-bottom: 8px;
}

.review-description p {
    font-size: 0.85rem;
    color: var(--text-secondary, #a1a1aa);
    margin: 0;
    line-height: 1.5;
}

.submission-note {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 8px;
}

.submission-note svg {
    width: 20px;
    height: 20px;
    color: #3b82f6;
    flex-shrink: 0;
    margin-top: 2px;
}

.submission-note p {
    font-size: 0.85rem;
    color: var(--text-secondary, #a1a1aa);
    margin: 0;
    line-height: 1.5;
}

/* Modal Footer */
.contribution-modal .modal-footer {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 16px 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    background: rgba(0, 0, 0, 0.2);
}

.contribution-modal .btn {
    padding: 10px 24px;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    border: none;
}

.contribution-modal .btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-secondary, #a1a1aa);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.contribution-modal .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary, #fafafa);
}

.contribution-modal .btn-primary {
    background: var(--primary, #8b5cf6);
    color: white;
}

.contribution-modal .btn-primary:hover {
    background: var(--primary-hover, var(--primary-hover));
}

.contribution-modal .btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Mobile Responsive */
@media (max-width: 600px) {
    .contribution-modal-container {
        max-width: 100%;
        max-height: 100%;
        border-radius: 0;
    }

    .contribution-steps {
        flex-wrap: wrap;
        gap: 4px;
    }

    .contribution-steps .step {
        padding: 6px 10px;
    }

    .contribution-steps .step-label {
        font-size: 0.75rem;
    }

    .content-type-grid,
    .action-type-grid,
    .contribution-form .form-row {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   FEATURE TOGGLE - DISABLED STATES
   ============================================ */

.feature-disabled {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 48px 24px;
    text-align: center;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
}

.feature-disabled svg {
    width: 48px;
    height: 48px;
    color: var(--text-muted);
}

.feature-disabled h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.feature-disabled p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    max-width: 400px;
}

.feature-disabled.coming-soon svg {
    color: var(--primary);
}

.feature-disabled.maintenance svg {
    color: var(--warning);
}

.feature-disabled-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    padding: 40px 20px;
}

.feature-disabled-page .feature-disabled {
    max-width: 500px;
    width: 100%;
}

