/* ============================================
   SHARED.CSS v4.1 - Updated for IMCollectibles
   Path: /var/www/improtectors.com/mint/assets/css/shared.css

   CHANGES IN v4.1:
   - Hamburger menu replaces nav-center
   - Wider dropdown (320px)
   - Gold gradient scrollbar
   - Gold dividers between sections
   - New menu structure
   ============================================ */

:root {
    --gold: #d6ba66;
    --gold-light: #e8d38a;
    --gold-dark: #b89d4a;
    --bg-dark: #0a0a0f;
    --bg-card: #12121a;
    --border: rgba(214, 186, 102, 0.15);
    --border-gold: rgba(214, 186, 102, 0.3);
    --text: #e8e6e3;
    --text-muted: #8a8a8a;
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-dark);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
    padding-top: 75px; /* Account for fixed header */
}

.bg-gradient {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(ellipse at 20% 20%, rgba(214, 186, 102, 0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 80%, rgba(214, 186, 102, 0.05) 0%, transparent 50%),
                radial-gradient(ellipse at 50% 50%, rgba(214, 186, 102, 0.03) 0%, transparent 70%);
    pointer-events: none; z-index: 0;
}

/* ============================================
   TOP BAR / HEADER - v4.1 (Hamburger Menu)
   ============================================ */
.top-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    height: 75px;
    background: rgba(10, 10, 15, 0.97);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.5rem;
    z-index: 1000;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--gold);
    font-weight: 600;
    font-size: 1.25rem;
}

.logo img {
    width: 45px;
    height: 45px;
    border-radius: 50%;
}

.logo:hover {
    color: var(--gold-light);
}

/* Header Controls (Wallet + Hamburger) */
.header-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.wallet-status {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 50px;
    font-size: 1rem;
}

.wallet-status .dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--error);
}

.wallet-status.connected .dot {
    background: var(--success);
}

.wallet-status .address {
    color: var(--text-muted);
}

.wallet-status.connected .address {
    color: var(--gold);
}

.connect-btn {
    padding: 0.6rem 1.25rem;
    background: linear-gradient(135deg, var(--gold-dark), var(--gold));
    color: #000;
    text-decoration: none;
    border: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s;
    font-family: inherit;
}

.connect-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(214, 186, 102, 0.4);
}

.connect-btn.hidden {
    display: none;
}

/* ============================================
   HAMBURGER BUTTON
   ============================================ */
.hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 10px;
    cursor: pointer;
    padding: 0;
    gap: 5px;
    transition: all 0.3s;
}

.hamburger:hover {
    border-color: var(--gold);
}

.hamburger span {
    display: block;
    width: 20px;
    height: 2px;
    background: var(--gold);
    border-radius: 2px;
    transition: all 0.3s;
}

.hamburger.active {
    border-color: var(--gold);
}

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

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

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

/* ============================================
   DROPDOWN MENU - v4.1 (320px + Gold Scrollbar)
   ============================================ */

/* Custom Gold Scrollbar */
.dropdown-menu::-webkit-scrollbar {
    width: 8px;
}

.dropdown-menu::-webkit-scrollbar-track {
    background: var(--bg-dark);
    border-radius: 4px;
}

.dropdown-menu::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, var(--gold-dark), var(--gold));
    border-radius: 4px;
}

.dropdown-menu::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, var(--gold), var(--gold-light));
}

/* Firefox scrollbar */
.dropdown-menu {
    scrollbar-width: thin;
    scrollbar-color: var(--gold) var(--bg-dark);
}

.dropdown-menu {
    position: fixed;
    top: 75px;
    right: 0;
    width: 320px;
    max-height: calc(100vh - 75px);
    overflow-y: auto;
    background: var(--bg-card);
    border: 1px solid rgba(214, 186, 102, 0.4);
    border-top: none;
    border-radius: 0 0 0 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    visibility: hidden;
    transform: translateX(20px);
    transition: all 0.3s ease;
}

.dropdown-menu.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

.dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.9rem 1.25rem;
    color: var(--text);
    text-decoration: none;
    font-size: 1rem;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

.dropdown-menu a:hover,
.dropdown-menu a.active {
    background: rgba(214, 186, 102, 0.1);
    color: var(--gold);
    border-left-color: var(--gold);
}

/* External link indicator */
.dropdown-menu a[target="_blank"]::after {
    content: '↗';
    margin-left: auto;
    font-size: 0.85rem;
    opacity: 0.5;
}

/* Gold Gradient Dividers */
.dropdown-menu .divider {
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 0.5rem 1rem;
    opacity: 0.4;
}

/* Section Labels */
.dropdown-menu .section-label {
    padding: 0.6rem 1.25rem 0.4rem;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--gold);
    opacity: 0.7;
}

/* Wallet Section in Dropdown */
.dropdown-wallet {
    padding: 1rem 1.25rem;
    border-top: 1px solid rgba(214, 186, 102, 0.4);
    margin-top: 0.5rem;
}

.dropdown-wallet .wallet-status {
    width: 100%;
    justify-content: center;
    margin-bottom: 0.75rem;
}

.dropdown-wallet .connect-btn,
.dropdown-wallet .disconnect-btn {
    display: block;
    width: 100%;
    text-align: center;
}

.disconnect-btn {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 0.6rem 1.25rem;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s;
    cursor: pointer;
    font-family: inherit;
}

.disconnect-btn:hover {
    border-color: var(--error);
    color: var(--error);
}

/* Menu Backdrop */
.menu-backdrop {
    position: fixed;
    top: 75px;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
}

.menu-backdrop.active {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   LEGACY STYLES (kept for backward compat)
   ============================================ */
.nav-center { display: none; }
.nav-dropdown { display: none; }
.mobile-menu { display: none; }
.wallet-area { display: none; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 600px) {
    .top-bar {
        padding: 0 1rem;
    }
    
    .logo span {
        display: none;
    }
    
    .wallet-status .address {
        max-width: 80px;
        overflow: hidden;
        text-overflow: ellipsis;
    }
    
    .dropdown-menu {
        width: 100%;
        border-radius: 0;
        border-left: none;
        border-right: none;
    }
}

/* ============================================
   COLLECTION CARDS (for mint pages)
   ============================================ */
.collections-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 900px;
    margin: 0 auto;
}

.collection-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    display: block;
}

.collection-card:hover {
    border-color: var(--gold);
    transform: translateY(-4px);
    box-shadow: 0 10px 40px rgba(214, 186, 102, 0.15);
}

.collection-card.disabled {
    opacity: 0.6;
    pointer-events: none;
}

.collection-card.sold-out {
    background: linear-gradient(135deg, var(--bg-card), rgba(100, 100, 100, 0.1));
}

.collection-image {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.collection-name {
    font-family: 'Lora', serif;
    font-size: 1.1rem;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.collection-desc {
    color: var(--text-muted);
    font-size: 0.85rem;
    margin-bottom: 1rem;
    line-height: 1.5;
}

.collection-stats {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.stat {
    text-align: center;
}

.stat-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gold);
}

.stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Status badges */
.status-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.35rem 0.75rem;
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-active {
    background: rgba(16, 185, 129, 0.2);
    color: var(--success);
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-coming {
    background: rgba(214, 186, 102, 0.2);
    color: var(--gold);
    border: 1px solid rgba(214, 186, 102, 0.3);
}

.badge-sold-out {
    background: rgba(100, 100, 100, 0.3);
    color: #888;
    border: 1px solid rgba(100, 100, 100, 0.4);
}

.badge-burn {
    background: rgba(239, 68, 68, 0.2);
    color: var(--error);
    border: 1px solid rgba(239, 68, 68, 0.3);
}

/* ============================================
   BUTTONS & CARDS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--gold-dark), var(--gold));
    color: #000;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(214, 186, 102, 0.4);
}

.btn-secondary {
    background: transparent;
    border: 1px solid var(--border-gold);
    color: var(--gold);
}

.btn-secondary:hover {
    background: rgba(214, 186, 102, 0.1);
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 1.5rem;
}

.card-title {
    font-family: 'Lora', serif;
    font-size: 1.25rem;
    color: var(--gold);
    margin-bottom: 1rem;
}

/* ============================================
   MAIN CONTENT AREAS
   ============================================ */
.main {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    min-height: calc(100vh - 75px);
}

.content {
    text-align: center;
    max-width: 1200px;
    width: 100%;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1rem;
}

.hero-logo {
    width: 120px;
    height: 120px;
    margin-bottom: 2rem;
    filter: drop-shadow(0 0 30px rgba(214, 186, 102, 0.4));
}

h1 {
    font-family: 'Lora', serif;
    font-size: 2.5rem;
    color: var(--gold);
    margin-bottom: 0.75rem;
    text-shadow: 0 0 40px rgba(214, 186, 102, 0.3);
}

.subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
    margin-bottom: 3rem;
}

/* ============================================
   UTILITIES
   ============================================ */
.hidden {
    display: none !important;
}

.loading {
    text-align: center;
    padding: 2rem;
    color: var(--text-muted);
}

.loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid var(--gold);
    border-top-color: transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 0.5rem;
    vertical-align: middle;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ============================================
   RESPONSIVE ADJUSTMENTS
   ============================================ */
@media (max-width: 768px) {
    h1 {
        font-size: 1.75rem;
    }
    
    .collections-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .main {
        padding: 1.5rem 1rem;
    }
}
