/* Import Montserrat */
@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@700;800&display=swap');

:root {
    --bg-color: #0d0d0d;
    --primary: #4b7f00;
    --primary-glow: rgba(75, 127, 0, 0.5);
    --primary-dim: rgba(75, 127, 0, 0.2);
    --pill-bg: #0d0d0d;
    --border-white: rgba(255, 255, 255, 0.3);
    --save-white: #ffffff;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Montserrat', sans-serif;
}

/* --- CLEAN ACCENT SCROLLBAR --- */
::-webkit-scrollbar {
    width: 4px;
    height: 4px;
}

::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.02);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--primary) rgba(255, 255, 255, 0.02);
}

body,
html {
    width: 100%;
    height: 100%;
    background-color: var(--bg-color);
    color: white;
    overflow-x: hidden;
}

/* --- APP LAYOUT --- */
.app-container {
    display: none;
    width: 100vw;
    min-height: 100vh;
    padding: 2rem 5%;
    flex-direction: column;
    align-items: center;
    background: radial-gradient(circle at top, #0b2d0f 0%, #0d0d0d 100%);
}

.auth-confirmed {
    display: flex !important;
}

/* --- HEADER --- */
.main-header {
    width: 100%;
    max-width: 1200px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
    /* Increased margin for better spacing */
    position: relative;
    /* Anchor for the absolute title */
    height: 60px;
    /* Consistent height */
}

.logo-text {
    font-size: 1.2rem;
    /* Slightly smaller to prevent crowding */
    font-weight: 800;
    letter-spacing: 1px;
    white-space: nowrap;
}

.page-title {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    /* Adjusted size */
    font-weight: 800;
    letter-spacing: 2px;
    margin: 0;
    /* Removed bottom margin since it's now absolute */
    white-space: nowrap;
    pointer-events: none;
    /* Allows clicking things behind it if necessary */
}

.pfp-badge {
    background-color: #333;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    border: 1px solid var(--border-white);
    transition: 0.3s;
}

.pfp-badge:hover {
    background-color: var(--primary);
    border-color: white;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 2rem;
    letter-spacing: 2px;
}

/* Container to help with alignment */
.logo-container {
    display: flex;
    align-items: center;
    height: 100%;
}

/* Style for the logo creature */


.header-logo-img:hover {
    transform: scale(1.1) rotate(-5deg);
    /* Slight animation on hover */
}

/* --- PROFILE BANNER --- */
.banner-display {
    width: 100%;
    max-width: 1000px;
    height: 300px;
    background: #111 center/cover;
    border: 2px solid var(--primary);
    border-radius: 25px;
    margin-bottom: 2.5rem;
    position: relative;
    box-shadow: 0 0 20px var(--primary-dim);
    overflow: hidden;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    justify-content: flex-end;
    align-items: flex-start;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
    cursor: pointer;
}

.banner-display:hover .banner-overlay {
    opacity: 1;
}

.header-left {
    flex: 1;
    display: flex;
    align-items: center;
    /* This aligns the text vertically to the middle of the logo */
    gap: 15px;
    height: 100%;
    /* Ensures it uses the full header height for centering */
}

.header-logo-img {
    height: 100px;
    /* Increased slightly for better visibility */
    width: auto;
    filter: drop-shadow(0 0 10px var(--primary));
    display: block;
    /* Removes any bottom inline spacing */
}

.brand-text {
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 1px;
    color: white;
    text-transform: uppercase;
    white-space: nowrap;
    line-height: 1;
    /* Prevents text from shifting up or down */
    display: flex;
    align-items: center;
}

.pencil-icon {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border: 2px solid white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    color: white;
    box-shadow: 0 0 15px var(--primary-glow);
    transition: transform 0.2s;
}

.pencil-icon:hover {
    transform: scale(1.1);
}

/* --- GRID & PILLS --- */
.controls-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    width: 100%;
    max-width: 1000px;
}

.input-pill,
.action-pill {
    background: var(--pill-bg);
    border: 1px solid var(--border-white);
    border-radius: 50px;
    height: 60px;
    padding: 0 25px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.input-pill input {
    background: transparent;
    border: none;
    color: white;
    font-weight: 600;
    outline: none;
    width: 80%;
}

.icon {
    color: var(--primary);
    filter: drop-shadow(0 0 5px var(--primary));
}

.action-pill {
    cursor: pointer;
    transition: transform 0.2s;
}

.action-pill:hover {
    transform: translateY(-2px);
}

.action-pill.manage {
    background: linear-gradient(90deg, #1b6412 0%, #048b1b 100%);
    border: none;
    justify-content: center;
    gap: 15px;
}

.action-pill.upload {
    border: 1px dashed var(--primary);
}

.save-button {
    grid-column: 1 / -1;
    height: 60px;
    background: white;
    color: black;
    border-radius: 50px;
    font-weight: 800;
    font-size: 1.2rem;
    cursor: pointer;
    border: none;
    margin-top: 1rem;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2);
    transition: all 0.3s;
}

.save-button:hover {
    background: var(--primary);
    color: white;
}

/* --- MODAL SYSTEM --- */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    padding: 20px;
}

.modal-content {
    background-color: #0d0d0d;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: inset 0 0 0 2000px rgba(0, 0, 0, 0.7);
    border: 1px solid #444;
    border-radius: 30px;
    padding: 40px;
    position: relative;
    max-width: 900px;
    width: 100%;
    transition: background 0.3s ease;
}

.close-modal {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #ff4d4d;
    color: white;
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    cursor: pointer;
    font-weight: bold;
    z-index: 10;
}

/* --- MODAL GRID LAYOUT --- */
.modal-grid {
    display: grid;
    grid-template-columns: 280px 1fr 60px;
    /* Fixed Cover, Flexible Details, Icons Sidebar */
    gap: 30px;
    align-items: start;
}

/* Imagery Section */
.cover-upload-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cover-placeholder.square-format {
    aspect-ratio: 1 / 1;
    width: 100%;
    background: #111;
    border: 2px dashed #555;
    border-radius: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-size: 0.75rem;
    cursor: pointer;
    background-size: cover;
    background-position: center;
    text-shadow: 0px 0px 5px black;
}

/* Details Section */
.modal-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #444;
    border-radius: 12px;
    color: white;
    padding: 15px;
    margin-bottom: 15px;
    outline: none;
}

textarea.modal-input {
    height: 100px;
    resize: none;
}

.modal-pill {
    width: 100%;
    background: #333;
    color: white;
    border: 1px solid #555;
    padding: 12px;
    border-radius: 50px;
    cursor: pointer;
    font-weight: bold;
    text-transform: uppercase;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.modal-pill:hover {
    background: #444;
}

/* Audio & Upload Buttons */
.audio-btn {
    border: 2px solid var(--primary) !important;
    color: #03a551 !important;
    background: transparent !important;
}

.audio-btn.ready {
    border-color: #00e676 !important;
    color: #00e676 !important;
}

.upload-trigger {
    background: var(--primary) !important;
    color: white !important;
    border: none !important;
    height: 60px;
    font-size: 1rem !important;
    margin-top: 10px;
}

/* Social Sidebar */
.social-sidebar {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.social-icon-btn {
    width: 45px;
    height: 45px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 1px solid #444;
    font-size: 1.2rem;
    transition: all 0.2s;
}

.social-icon-btn:hover {
    background: var(--primary);
    border-color: white;
}

/* --- CROPPER CONTAINER --- */
.cropper-container {
    width: 100%;
    max-height: 400px;
    background: #000;
}

/* Manage Songs List Styling */
.song-item {
    display: flex;
    align-items: center;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid #333;
    border-radius: 15px;
    padding: 12px;
    margin-bottom: 10px;
    gap: 15px;
}

.song-item-img {
    width: 50px;
    height: 50px;
    border-radius: 8px;
    background-size: cover;
    background-position: center;
    border: 1px solid var(--primary);
}

.song-item-info {
    flex: 1;
}

.song-item-info h4 {
    font-size: 0.9rem;
    margin-bottom: 2px;
}

.song-item-info p {
    font-size: 0.7rem;
    color: #888;
}

.delete-song-btn {
    background: rgba(255, 77, 77, 0.1);
    color: #ff4d4d;
    border: 1px solid #ff4d4d;
    padding: 8px 12px;
    border-radius: 50px;
    font-size: 0.7rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
}

.delete-song-btn:hover {
    background: #ff4d4d;
    color: white;
}

/* Custom Scrollbar for the list */
#song-list-container::-webkit-scrollbar {
    width: 6px;
}

#song-list-container::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 10px;
}

/* Container for the toggle and pencil icon inside the pill */
.pill-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

/* The switch - scaled down to fit neatly inside the pill */
.switch {
    position: relative;
    display: inline-block;
    width: 32px;
    height: 18px;
}

/* Hide default HTML checkbox */
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider track */
.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #333;
    transition: .3s;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* The slider knob */
.slider:before {
    position: absolute;
    content: "";
    height: 12px;
    width: 12px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

/* Checked state: Green background with black knob */
input:checked+.slider {
    background-color: #00e676;
    border-color: #00e676;
}

input:checked+.slider:before {
    transform: translateX(14px);
    background-color: #000;
}

/* DASHBOARD NAVIGATION */
.dashboard-nav {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 2rem;
    width: 100%;
    max-width: 1100px;
    padding: 0 10px;
}

.nav-item {
    background: transparent;
    border: 1px solid var(--border-white);
    color: white;
    padding: 10px 18px;
    font-weight: 700;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: 1px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.nav-item:hover {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

.nav-item.active {
    background: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* TAB TOGGLING LOGIC */
.tab-content {
    display: none;
    /* Hide all by default */
    width: 100%;
    flex-direction: column;
    align-items: center;
}

.tab-content.active {
    display: flex;
    /* Show the active one */
}

/* ABOUT SECTION CARD */
.edit-card {
    background: var(--pill-bg);
    border: 1px solid var(--border-white);
    padding: 30px;
    border-radius: 25px;
    width: 100%;
    max-width: 800px;
}

#about-bio {
    height: 200px;
    width: 1000px;
    margin-top: 15px;
}

.events-view {
    min-height: 100vh;
    padding: 100px 10%;
    background-size: cover;
    background-attachment: fixed;
}

.event-card {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    padding: 20px;
    margin-bottom: 20px;
    gap: 30px;
}

.event-date {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 80px;
    border-right: 1px solid rgba(255, 255, 255, 0.2);
    padding-right: 30px;
}

.event-date .day {
    font-size: 2.5rem;
    font-weight: 900;
}

.event-date .month {
    font-size: 0.9rem;
    letter-spacing: 2px;
    color: #999;
}

.event-details {
    flex-grow: 1;
}

.event-details h3 {
    font-size: 1.5rem;
    text-transform: uppercase;
    margin-bottom: 5px;
}

.event-details .location {
    color: #fff;
    font-weight: bold;
    margin-bottom: 5px;
}

.event-details .description {
    color: #999;
    font-size: 0.9rem;
}

.btn-tickets {
    border: 1px solid #fff;
    color: #fff;
    padding: 12px 25px;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: bold;
    transition: 0.3s;
}

.btn-tickets:hover {
    background: #fff;
    color: #000;
}

/* Target all input pills in the dashboard */
.input-pill,
.input-pill input,
input[type="text"],
input[type="date"],
input[type="datetime-local"],
textarea {
    background-color: #222 !important;
    /* Dark background */
    color: white !important;
    /* White text */


    padding: 10px;
}


/* Remove the blue outline when clicking */
input:focus {
    outline: none;
    border-color: #fff;
}

/* This ensures the date input and events inputs behave exactly like your Home inputs */
#events-section .input-pill {
    display: flex;
    align-items: center;
    width: 100%;
    /* Matches the grid cell width */
    box-sizing: border-box;
}

#events-section .input-pill input {
    flex: 1;
    background: transparent;
    border: none;
    color: white;
    outline: none;
    font-family: inherit;
}

/* Fix the date picker icon so it's visible in the dark theme */
#events-section input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1);
    cursor: pointer;
    margin-right: 5px;
}

/* Navigation Delete Button */
.nav-item.nav-delete {
    color: #ff4444;
}

.nav-item.nav-delete:hover {
    background: rgba(255, 68, 68, 0.1);
    border-bottom: 2px solid #ff4444;
}

.nav-item.nav-delete.active {
    border-bottom: 2px solid #ff4444;
    background: rgba(255, 68, 68, 0.1);
}

/* Danger Card Styling */
.danger-card {
    background: rgba(255, 68, 68, 0.05);
    border: 1px solid rgba(255, 68, 68, 0.2);
    border-radius: 15px;
}

.delete-confirm-btn {
    background: #ff4444 !important;
    border: none !important;
    max-width: 400px;
}

.delete-confirm-btn:hover {
    background: #cc0000 !important;
    transform: scale(1.02);
}

.nav-view {
    color: #00ff2a;
    /* Example blue color */
    border: 1px solid #59ff00;
    margin-left: auto;
    /* Pushes it to the right if using flexbox */
}

.nav-view:hover {
    background-color: var(--primary);
    color: white;
}



.nav-plans {
    background: linear-gradient(135deg, #ffd700, #ff8c00);
    color: #fefbfb !important;
    /* Dark text for contrast on gold */
    border-radius: 25px;
    margin-left: 10px;
    border: none;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.nav-plans::hover {
    background: linear-gradient(135deg, #ffd700, #ff8c00);
    color: #ffffff !important;
    /* Dark text for contrast on gold */
    border-radius: 25px;
    margin-left: 10px;
    border: none;
    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.2);
    position: relative;
    overflow: hidden;
}

/* --- PLANS SECTION (PREMIUM) --- */

/* The Main Card Container */
.premium-card {
    background: var(--pill-bg);
    border: 2px solid #ffd700; /* Gold border to stand out */
    padding: 40px;
    border-radius: 25px;
    width: 100%;
    
    
    text-align: center;
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.1);
}

/* Gold Badge at the top */
.premium-badge {
    display: inline-block;
    background: rgba(255, 215, 0, 0.1);
    color: #ffd700;
    padding: 8px 20px;
    border-radius: 50px;
    border: 1px solid #ffd700;
    font-size: 0.75rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

/* Price Formatting */
.price-display {
    margin: 2rem 0;
    display: flex;
    justify-content: center;
    align-items: baseline;
    gap: 5px;
}

.price-display .currency {
    font-size: 1.5rem;
    color: #ffd700;
    font-weight: 800;
}

.price-display .amount {
    font-size: 4.5rem;
    font-weight: 800;
    color: white;
    line-height: 1;
}

.price-display .period {
    color: #888;
    font-size: 1rem;
    font-weight: 700;
}

/* Specific styling for the Upgrade button to override global save-button styles */
#checkout-btn {
    background: linear-gradient(135deg, #ffd700, #ff8c00) !important;
    color: black !important;
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
    display: block;
    box-shadow: 0 5px 15px rgba(255, 140, 0, 0.3);
}

#checkout-btn:hover {
    transform: scale(1.02);
    box-shadow: 0 8px 25px rgba(255, 215, 0, 0.4);
    filter: brightness(1.1);
}

/* Feature List under the price */
.premium-features {
    list-style: none;
    margin-bottom: 2rem;
    color: #bbb;
    font-size: 0.9rem;
}

.premium-features li {
    margin-bottom: 10px;
}

.premium-features li i {
    color: #ffd700;
    margin-right: 10px;
}

/* =========================================
   DASHBOARD MOBILE OPTIMIZATIONS
   ========================================= */



.pfp-upload-container {
    display: flex;
    flex-direction: column;
    
    align-items: center;
    margin-bottom: 30px;
    margin-top: -20px; /* Pulls it up slightly over the banner */
    position: relative;
    z-index: 10;
}

.pfp-preview-wrapper {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 5px solid #0d0d0d;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    background: #222;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

.pfp-preview-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pfp-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.pfp-preview-wrapper:hover .pfp-overlay {
    opacity: 1;
}

.pfp-overlay i {
    color: white;
    font-size: 1.5rem;
}

.pfp-label {
    margin-top: 10px;
    font-size: 0.7rem;
    font-weight: 800;
    color: #888;
    letter-spacing: 1px;
}

/* Premium Neon Ring Effect */
.pfp-preview-wrapper.premium-ring {
    border: none;
    padding: 5px;
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    animation: neonGlow 3s ease infinite;
    box-shadow: 
        0 0 15px rgba(255, 0, 255, 0.5),
        0 0 30px rgba(0, 255, 255, 0.3),
        0 0 45px rgba(255, 0, 255, 0.2);
}

.pfp-preview-wrapper.premium-ring img {
    border-radius: 50%;
}

@keyframes neonGlow {
    0% {
        background-position: 0% 50%;
        box-shadow: 
            0 0 15px rgba(255, 0, 255, 0.6),
            0 0 30px rgba(0, 255, 255, 0.4);
    }
    25% {
        background-position: 50% 100%;
        box-shadow: 
            0 0 15px rgba(0, 255, 255, 0.6),
            0 0 30px rgba(255, 255, 0, 0.4);
    }
    50% {
        background-position: 100% 50%;
        box-shadow: 
            0 0 15px rgba(255, 255, 0, 0.6),
            0 0 30px rgba(255, 0, 255, 0.4);
    }
    75% {
        background-position: 50% 0%;
        box-shadow: 
            0 0 15px rgba(255, 0, 255, 0.6),
            0 0 30px rgba(0, 255, 255, 0.4);
    }
    100% {
        background-position: 0% 50%;
        box-shadow: 
            0 0 15px rgba(255, 0, 255, 0.6),
            0 0 30px rgba(0, 255, 255, 0.4);
    }
}

/* Premium Banner Effect - uses pseudo-element to preserve banner image */
body.premium-user .banner-display {
    border: none;
    position: relative;
    box-shadow: 
        0 0 15px rgba(255, 0, 255, 0.4),
        0 0 30px rgba(0, 255, 255, 0.2);
}

body.premium-user .banner-display::before {
    content: '';
    position: absolute;
    top: -5px;
    left: -5px;
    right: -5px;
    bottom: -5px;
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    border-radius: 30px;
    z-index: -1;
    animation: neonBorder 3s ease infinite;
}

/* Premium Button Effects */
body.premium-user .save-button {
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    animation: neonBorder 3s ease infinite;
    color: #000;
    font-weight: 900;
    box-shadow: 
        0 0 10px rgba(255, 0, 255, 0.5),
        0 0 20px rgba(0, 255, 255, 0.3);
}

body.premium-user .save-button:hover {
    background: linear-gradient(135deg, #00ffff, #ff00ff, #ffff00, #00ffff);
    background-size: 400% 400%;
    color: #000;
}

/* Premium Nav Items */
body.premium-user .nav-item {
    border: 2px solid transparent;
    background-image: linear-gradient(#0d0d0d, #0d0d0d), linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    background-size: 100% 100%, 400% 400%;
    animation: neonBorder 3s ease infinite;
}

body.premium-user .nav-item.active {
    background-image: linear-gradient(135deg, #ff00ff, #00ffff, #ffff00), linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    color: #000;
    font-weight: 900;
}

/* Premium Action Pills */
body.premium-user .action-pill {
    border: 2px solid transparent;
    background-image: linear-gradient(#1a1a1a, #1a1a1a), linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    background-size: 100% 100%, 400% 400%;
    animation: neonBorder 3s ease infinite;
    box-shadow: 
        0 0 8px rgba(255, 0, 255, 0.3),
        0 0 15px rgba(0, 255, 255, 0.2);
}

/* Premium Input Pills */
body.premium-user .input-pill {
    border: 2px solid transparent;
    background-image: linear-gradient(#1a1a1a, #1a1a1a), linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-origin: border-box;
    background-clip: padding-box, border-box;
    background-size: 100% 100%, 400% 400%;
    animation: neonBorder 3s ease infinite;
}

@keyframes neonBorder {
    0%, 100% { background-position: 0% 50%, 0% 50%; }
    25% { background-position: 0% 50%, 50% 100%; }
    50% { background-position: 0% 50%, 100% 50%; }
    75% { background-position: 0% 50%, 50% 0%; }
}

/* Premium Text Effects */
body.premium-user .page-title,
body.premium-user .brand-text {
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: neonText 3s ease infinite;
    filter: drop-shadow(0 0 8px rgba(255, 0, 255, 0.5));
}

/* Premium Pencil Icons */
body.premium-user .icon,
body.premium-user .pencil-icon {
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: neonText 3s ease infinite;
    filter: drop-shadow(0 0 5px rgba(255, 0, 255, 0.6)) drop-shadow(0 0 10px rgba(0, 255, 255, 0.4));
}

@keyframes neonText {
    0%, 100% { background-position: 0% 50%; }
    25% { background-position: 50% 100%; }
    50% { background-position: 100% 50%; }
    75% { background-position: 50% 0%; }
}

/* --- Store Section Styling --- */
.store-editor-card {
    padding: 30px;
}

.store-editor-header {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.store-icon {
    font-size: 3rem;
    color: #95bf47;
    text-shadow: 0 0 20px rgba(149, 191, 71, 0.4);
}

.store-editor-header h3 {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    letter-spacing: 2px;
}

.store-description {
    color: #666;
    font-size: 0.85rem;
    margin: 0;
}

.store-connection-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.store-connection-form .save-button {
    grid-column: 1 / -1;
    margin-top: 10px;
}

.store-help-link {
    text-align: center;
    margin-bottom: 30px;
}

.store-help-link a {
    color: #555;
    font-size: 0.75rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.store-help-link a:hover {
    color: #00ffcc;
}

.store-preview-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 25px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.store-preview-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.store-preview-header h4 {
    color: #fff;
    font-size: 0.85rem;
    letter-spacing: 2px;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.store-preview-header h4 i {
    color: #00ffcc;
}

.store-status {
    font-size: 0.7rem;
    padding: 5px 12px;
    border-radius: 20px;
    font-weight: 700;
    letter-spacing: 1px;
}

.store-status.connected {
    background: rgba(0, 255, 204, 0.15);
    color: #00ffcc;
    border: 1px solid rgba(0, 255, 204, 0.3);
}

.store-status:not(.connected) {
    background: rgba(255, 255, 255, 0.05);
    color: #666;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.product-preview-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
}

.store-placeholder {
    grid-column: 1 / -1;
    text-align: center;
    padding: 50px 20px;
    border: 2px dashed rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    color: #444;
}

.store-placeholder i {
    font-size: 2.5rem;
    margin-bottom: 15px;
    display: block;
}

.store-placeholder p {
    margin: 0;
    font-size: 0.85rem;
}

.product-card {
    background: rgba(30, 30, 35, 0.9);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 12px;
    text-align: center;
    transition: all 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 255, 204, 0.3);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
}

.product-card img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.product-card .product-title {
    font-size: 0.75rem;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 5px;
}

.product-card .product-price {
    color: #00ffcc;
    font-weight: 800;
    font-size: 0.85rem;
}

/* Store Settings Section */
.store-settings-section {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 20px;
    padding: 25px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 25px;
}

.store-settings-section h4 {
    color: #fff;
    font-size: 0.85rem;
    letter-spacing: 2px;
    margin: 0 0 20px 0;
    display: flex;
    align-items: center;
    gap: 10px;
}

.store-settings-section h4 i {
    color: #ff00ff;
}

.store-settings-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.setting-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.setting-item label {
    font-size: 0.75rem;
    color: #888;
    font-weight: 700;
    letter-spacing: 1px;
}

.grid-size-options {
    display: flex;
    gap: 8px;
}

.grid-option {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(30, 30, 35, 0.8);
    color: #888;
    border-radius: 8px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
}

.grid-option:hover {
    border-color: rgba(0, 255, 204, 0.3);
    color: #fff;
}

.grid-option.active {
    background: linear-gradient(135deg, #00ffcc, #00ccff);
    color: #000;
    border-color: transparent;
}

.store-select {
    background: rgba(30, 30, 35, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 10px 15px;
    border-radius: 10px;
    font-size: 0.85rem;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.store-select:hover,
.store-select:focus {
    border-color: rgba(0, 255, 204, 0.3);
    outline: none;
}

.pin-instruction {
    font-size: 0.75rem;
    color: #666;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pin-instruction i {
    color: #ffd700;
}

.product-card.pinned {
    border: 2px solid #ffd700;
    box-shadow: 0 0 15px rgba(255, 215, 0, 0.2);
}

.product-card .pin-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: #ffd700;
    color: #000;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
}

.product-card {
    position: relative;
    cursor: pointer;
}

.product-card.featured {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    padding: 20px;
}

.product-card.featured img {
    aspect-ratio: 1 / 1;
    max-height: 200px;
}

.product-card.featured .product-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: left;
}

.product-card.featured .product-title {
    font-size: 1.2rem;
    white-space: normal;
    margin-bottom: 10px;
}

.product-card.featured .product-price {
    font-size: 1.5rem;
}

.featured-label {
    background: linear-gradient(135deg, #ff00ff, #00ffff);
    color: #000;
    font-size: 0.65rem;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 20px;
    display: inline-block;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

/* Product Groups Section */
.product-groups-section {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.product-groups-section h5 {
    color: #fff;
    font-size: 0.8rem;
    letter-spacing: 1.5px;
    margin: 0 0 8px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.product-groups-section h5 i {
    color: #00ffcc;
}

.groups-description {
    font-size: 0.7rem;
    color: #666;
    margin: 0 0 15px 0;
}

.groups-manager {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.group-input-row {
    display: flex;
    gap: 10px;
}

.group-input-row input {
    flex: 1;
    background: rgba(30, 30, 35, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 10px 15px;
    border-radius: 10px;
    font-size: 0.85rem;
}

.group-input-row input::placeholder {
    color: #555;
}

.add-group-btn {
    background: linear-gradient(135deg, #00ffcc, #00ccff);
    border: none;
    color: #000;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
    transition: all 0.3s ease;
}

.add-group-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(0, 255, 204, 0.4);
}

.existing-groups {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.group-tag {
    background: rgba(255, 0, 255, 0.15);
    border: 1px solid rgba(255, 0, 255, 0.3);
    color: #ff00ff;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.group-tag .remove-group {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    padding: 0;
    font-size: 0.7rem;
}

.group-tag .remove-group:hover {
    color: #ff4444;
}

.product-card .group-selector {
    position: absolute;
    bottom: 8px;
    left: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #fff;
    padding: 6px 10px;
    border-radius: 8px;
    font-size: 0.7rem;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.product-card:hover .group-selector {
    opacity: 1;
}

.product-card .current-group {
    position: absolute;
    bottom: 8px;
    left: 8px;
    background: rgba(255, 0, 255, 0.2);
    color: #ff00ff;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}



/* Premium Logo Effect */
body.premium-user .header-logo-img {
    animation: neonLogo 3s ease infinite;
    filter: drop-shadow(0 0 10px rgba(255, 0, 255, 0.6)) drop-shadow(0 0 20px rgba(0, 255, 255, 0.4));
}

@keyframes neonLogo {
    0%, 100% { 
        filter: drop-shadow(0 0 10px rgba(255, 0, 255, 0.8)) drop-shadow(0 0 20px rgba(255, 0, 255, 0.5)) hue-rotate(0deg);
    }
    33% { 
        filter: drop-shadow(0 0 10px rgba(0, 255, 255, 0.8)) drop-shadow(0 0 20px rgba(0, 255, 255, 0.5)) hue-rotate(60deg);
    }
    66% { 
        filter: drop-shadow(0 0 10px rgba(255, 255, 0, 0.8)) drop-shadow(0 0 20px rgba(255, 255, 0, 0.5)) hue-rotate(180deg);
    }
}


/* --- USERNAME & PFP APPEARANCE --- */

.pfp-upload-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 30px;
    margin-top: 30px; /* Pulls it up to overlap the banner slightly */
    position: relative;
    z-index: 10;
}

.pfp-preview-wrapper {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 5px solid #0d0d0d;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    background: #222;
    box-shadow: 0 4px 15px rgba(0,0,0,0.5);
    transition: transform 0.3s ease;
}

.pfp-preview-wrapper:hover {
    transform: scale(1.05);
}

.pfp-preview-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.pfp-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.pfp-preview-wrapper:hover .pfp-overlay {
    opacity: 1;
}

.pfp-overlay i {
    color: white;
    font-size: 1.5rem;
}

.pfp-label {
    margin-top: 12px;
    font-size: 0.75rem;
    font-weight: 800;
    color: #888;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* --- PREMIUM NEON RING EFFECT --- */

/* Apply this class via JS if user is premium */
.pfp-preview-wrapper.premium-ring {
    border: none;
    padding: 5px; /* Creates space for the gradient border */
    background: linear-gradient(135deg, #ff00ff, #00ffff, #ff00ff, #ffff00, #ff00ff);
    background-size: 400% 400%;
    animation: neonGlow 3s ease infinite;
    box-shadow: 
        0 0 15px rgba(255, 0, 255, 0.5),
        0 0 30px rgba(0, 255, 255, 0.3);
}

.pfp-preview-wrapper.premium-ring img {
    border-radius: 50%;
    background: #0d0d0d; /* Prevents gaps in the ring */
}

@keyframes neonGlow {
    0%, 100% {
        background-position: 0% 50%;
        box-shadow: 0 0 15px rgba(255, 0, 255, 0.6), 0 0 30px rgba(0, 255, 255, 0.4);
    }
    50% {
        background-position: 100% 50%;
        box-shadow: 0 0 20px rgba(0, 255, 255, 0.6), 0 0 35px rgba(255, 255, 0, 0.4);
    }
}

/* --- COMPLETE MOBILE-FIRST REFACTOR (850PX & BELOW) --- */
@media (max-width: 850px) {
    /* 1. Reset & Global Layout */
    body {
        margin: 0;
        padding: 0;
        background-color: #0a110a; /* Dark green theme */
    }

    .app-container {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 10px 15px;
        width: 100%;
        box-sizing: border-box;
    }

    /* 2. Header Fix */
    .main-header {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        height: auto;
        padding: 15px 0;
        gap: 15px;
    }

    .header-middle {
        order: -1;
        width: 100%;
        text-align: center;
    }

    .page-title {
        font-family: 'Montserrat', sans-serif;
        font-size: 1.8rem;
        color: #00ff88;
        margin: 0;
        text-shadow: 0 0 10px rgba(0, 255, 136, 0.3);
        position: static !important;
        transform: none !important;
    }

    .header-left, .header-right {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        width: 100%;
        gap: 8px;
    }

    .header-right .nav-item {
        background: #000;
        border: 1px solid #ff00ff; /* Purple glow */
        color: white;
        padding: 6px 12px;
        font-size: 0.7rem;
        border-radius: 4px;
        white-space: nowrap;
    }

    /* 3. Banner & Profile Image */
    .banner-display {
        width: 100%;
        height: 150px;
        border-radius: 12px;
        background-size: cover;
        background-position: center;
        margin-top: 10px;
    }

    .pfp-upload-container {
        margin-top: 40px; 
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        z-index: 5;
    }

    .pfp-preview-wrapper {
        width: 120px;
        height: 120px;
        border-radius: 50%;
        border: 4px solid #000;
        box-shadow: 0 0 20px rgba(188, 59, 255, 0.7); /* Neon Purple Glow */
        overflow: hidden;
    }

    /* 4. The Icon Navigation */
    .dashboard-nav {
        display: grid;
        grid-template-columns: repeat(4, 1fr); /* 4 icons per row */
        gap: 15px;
        justify-items: center;
        align-items: center;
        width: 100%;
        max-width: 320px;
        padding: 25px 0;
        margin: 0 auto;
    }

    .dashboard-nav .nav-item {
        width: 55px;
        height: 55px;
        padding: 0;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
        background: rgba(255, 255, 255, 0.05);
        border: 2px solid rgba(255, 255, 255, 0.1);
        font-size: 0; 
        transition: all 0.2s ease;
    }

    .dashboard-nav .nav-item::before {
        font-family: "Font Awesome 6 Free";
        font-weight: 900;
        font-size: 1.3rem;
        color: white;
    }

    .dashboard-nav .nav-item[data-target="news"]::before { content: "\f015"; }
    .dashboard-nav .nav-item[data-target="about"]::before { content: "\f129"; }
    .dashboard-nav .nav-item[data-target="events"]::before { content: "\f133"; }
    .dashboard-nav .nav-item[data-target="store"]::before { content: "\f291"; }
    .dashboard-nav .nav-item[data-target="plans"]::before { content: "\f013"; }
    .dashboard-nav .nav-item.nav-songwars::before { content: "\f44b"; }
    .dashboard-nav .nav-item.nav-view::before { content: "\f06e"; }
    .dashboard-nav .nav-item[data-target="delete"]::before { content: "\f2ed"; }

    .dashboard-nav .nav-item.active {
        background: #007bff !important; 
        border-color: #007bff;
        box-shadow: 0 0 15px rgba(0, 123, 255, 0.6);
        transform: scale(1.1);
    }

    /* 5. MERCH STORE & DISPLAY SETTINGS FIXES */
    .store-connection-form {
        display: flex;
        flex-direction: column;
        gap: 15px;
        width: 100%;
    }

    /* Stack URL and Token inputs for mobile */
    .store-auth-row {
        display: flex;
        flex-direction: column; 
        gap: 10px;
    }

    /* Clean full-width gradient buttons */
    #connect-store-btn, #save-store-settings, .save-display-btn {
        width: 100%;
        height: 55px;
        background: linear-gradient(90deg, #9b59ff, #00d2ff); /* Gradient from image */
        border: none;
        color: #000;
        font-weight: 800;
        text-transform: uppercase;
        border-radius: 30px;
        margin-top: 10px;
        box-shadow: 0 4px 15px rgba(155, 89, 255, 0.4);
    }

    .store-settings-grid {
        display: flex;
        flex-direction: column;
        gap: 20px;
        background: rgba(0,0,0,0.2);
        padding: 20px;
        border-radius: 15px;
        border: 1px solid #333;
        width: 100%;
        box-sizing: border-box;
    }

    /* Stack display setting labels above their controls */
    .setting-item {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .grid-size-options {
        display: flex;
        gap: 10px;
        width: 100%;
    }

    .grid-option {
        flex: 1;
        background: #222;
        border: 1px solid #444;
        color: #fff;
        padding: 12px;
        border-radius: 8px;
        text-align: center;
        font-weight: bold;
    }

    .grid-option.active {
        background: #00ffcc; /* Cyan highlight */
        color: #000;
        border-color: #00ffcc;
    }

    /* Ensure dropdowns and switches are full-width/centered */
    .max-products-select {
        width: 100%;
        height: 45px;
        background: #1a1a1a;
        border: 1px solid #333;
        color: white;
        border-radius: 8px;
    }

    .toggle-row {
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 5px 0;
    }

    /* 6. General Form Elements */
    .tab-content { width: 100%; padding: 0; }

    .controls-grid {
        display: flex;
        flex-direction: column;
        width: 100%;
        gap: 12px;
        margin-top: 20px;
    }

    .input-pill, .action-pill, .save-button {
        width: 100%;
        height: auto;
        min-height: 55px;
        padding: 10px 15px;
        box-sizing: border-box;
        display: flex;
        align-items: center;
        border-radius: 30px;
        background: #1a1a1a;
        border: 1px solid #333;
        color: white;
    }

    .url-edit {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px 15px;
    }

    .url-prefix {
        font-size: 0.6rem;
        opacity: 0.5;
        margin-bottom: 2px;
    }
}