@import url('open-iconic/font/css/open-iconic-bootstrap.min.css');

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    font-family: "Segoe UI", Helvetica, Arial, sans-serif;
    background-color: #0f172a;
    color: #fff;
}

/* -------------------------
   GLOBAL
--------------------------*/

h1, h2, h3, h4 {
    margin: 0;
}

a {
    color: #3b82f6;
}

.content {
    padding: 20px;
}

/* -------------------------
   LOGIN PAGE
--------------------------*/

.login-wrapper {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.login-card {
    width: 100%;
    max-width: 420px;
    background: #1e293b;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
}

.app-title {
    text-align: center;
    font-size: 32px;
    margin-bottom: 10px;
}

.login-subtitle {
    text-align: center;
    margin-bottom: 30px;
    color: #cbd5f5;
}


.login-error {
    margin-top: 15px;
    padding: 10px;
    background: #7f1d1d;
    border-radius: 6px;
    text-align: center;
}

.validation-message {
    font-size: 13px;
    color: #f87171;
    margin-top: 5px;
}

/* -------------------------
   FORM
--------------------------*/

.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 20px;
}

label {
    margin-bottom: 6px;
    font-size: 14px;
    color: #cbd5f5;
}

.input-field {
    width: 100%;
    padding: 12px;
    border-radius: 6px;
    border: none;
    background: #0f172a;
    color: #fff;
    font-size: 16px;
}

    .input-field:focus {
        outline: 2px solid #3b82f6;
    }


.forgot-link {
    color: #93c5fd;
    font-size: 14px;
    text-decoration: none;
}

    .forgot-link:hover {
        text-decoration: underline;
    }


/* -------------------------
   BUTTON
--------------------------*/

.login-btn {
    width: 100%;
    padding: 14px;
    background: #3b82f6;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    color: white;
    cursor: pointer;
    transition: background .2s ease;
}

    .login-btn:hover {
        background: #2563eb;
    }



.spinner {
    width: 18px;
    height: 18px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    display: inline-block;
    margin-right: 8px;
    animation: spin 0.7s linear infinite;
}

.loading-text {
    vertical-align: middle;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}



/* -------------------------
   ONBOARDING
--------------------------*/

.onboarding-wrapper {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.onboarding-card {
    width: 100%;
    max-width: 420px;
    background: #1e293b;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.4);
    text-align: center;
}

    .onboarding-card h1 {
        margin-bottom: 10px;
    }

.onboarding-subtitle {
    margin-bottom: 30px;
    color: #cbd5f5;
}

@media (max-width: 600px) {

    .onboarding-card {
        padding: 30px 20px;
    }
}





/* -------------------------
   DASHBOARD
--------------------------*/

.dashboard-container {
    padding: 30px;
}

.dashboard-header {
    margin-bottom: 25px;
}

.dashboard-subtitle {
    color: #94a3b8;
    margin-top: 5px;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 20px;
}

/* -------------------------
   CARDS
--------------------------*/

.dashboard-card {
    background: #1e293b;
    border-radius: 10px;
    padding: 20px;
}

.side-card {
    text-align: center;
}

/* -------------------------
   TABLE
--------------------------*/

.album-cell {
    width: 60px;
}

.album-art {
    width: 42px;
    height: 42px;
    border-radius: 6px;
    object-fit: cover;
}

.request-table table {
    width: 100%;
    border-collapse: collapse;
}

.request-table th {
    text-align: left;
    padding-bottom: 10px;
    color: #cbd5f5;
}

.request-table td {
    padding: 10px 0;
    border-top: 1px solid #334155;
}

.actions {
    display: flex;
    gap: 8px;
}

.no-requests {
    text-align: center;
    padding: 20px;
    color: #94a3b8;
}

/* -------------------------
   BUTTONS
--------------------------*/

.btn-approve {
    background: #16a34a;
    border: none;
    padding: 6px 12px;
    border-radius: 5px;
    color: white;
    cursor: pointer;
}

    .btn-approve:hover {
        background: #15803d;
    }

.btn-deny {
    background: #dc2626;
    border: none;
    padding: 6px 12px;
    border-radius: 5px;
    color: white;
    cursor: pointer;
}

    .btn-deny:hover {
        background: #b91c1c;
    }

/* -------------------------
   MOBILE REQUEST CARDS
--------------------------*/

.mobile-album-art {
    width: 56px;
    height: 56px;
    border-radius: 8px;
    object-fit: cover;
    margin-bottom: 10px;
}

.mobile-requests {
    display: none;
}

.request-card {
    background: #0f172a;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
}

.request-song {
    font-weight: bold;
}

.request-artist {
    color: #94a3b8;
}

.request-meta {
    font-size: 13px;
    margin-top: 6px;
}

.request-actions {
    margin-top: 12px;
    display: flex;
    gap: 10px;
}

.no-requests-card {
    text-align: center;
    color: #94a3b8;
}

/* -------------------------
   STATS
--------------------------*/

.stat {
    margin-top: 20px;
}

.stat-number {
    font-size: 32px;
    font-weight: bold;
}

.stat-label {
    display: block;
    color: #94a3b8;
}

/* -------------------------
   QR
--------------------------*/

.qr-placeholder {
    background: #0f172a;
    height: 160px;
    border-radius: 8px;
    margin-top: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* -------------------------
   MOBILE
--------------------------*/

@media (max-width: 900px) {

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .request-table {
        display: none;
    }

    .mobile-requests {
        display: block;
    }
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
}

.request-badge {
    background: #2563eb;
    padding: 8px 14px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 14px;
}

.song-cell {
    font-weight: 600;
}

.song-title {
    font-size: 18px;
    font-weight: 600;
}

.song-artist {
    color: #94a3b8;
    margin-bottom: 8px;
}

.song-meta {
    font-size: 13px;
    color: #94a3b8;
    margin-top: 4px;
}


.tip-banner {
    background: #1e293b;
    border: 1px solid #2563eb;
    border-radius: 8px;
    padding: 18px;
    margin-bottom: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

    .tip-banner p {
        margin: 4px 0 0 0;
        color: #94a3b8;
        font-size: 14px;
    }

.setup-tip-btn {
    background: #2563eb;
    border: none;
    padding: 10px 16px;
    border-radius: 6px;
    color: white;
    font-weight: 600;
    cursor: pointer;
}

    .setup-tip-btn:hover {
        background: #1d4ed8;
    }

.dashboard-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    gap: 20px;
    flex-wrap: wrap;
}

.dashboard-title h1 {
    margin: 0;
}

.dj-card {
    background: #1e293b;
    padding: 12px 18px;
    border-radius: 8px;
    border: 1px solid #334155;
    text-align: right;
    min-width: 160px;
}

.dj-label {
    font-size: 12px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.dj-name {
    font-size: 20px;
    font-weight: 700;
    color: #3b82f6;
}


/* -------------------------
   Settings
--------------------------*/

.settings-container {
    max-width: 900px;
    margin: auto;
    padding: 30px;
}

.settings-subtitle {
    color: #94a3b8;
    margin-bottom: 30px;
}

.settings-card {
    background: #1e293b;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 20px;
}

    .settings-card h2 {
        margin-bottom: 15px;
    }

    .settings-card select {
        cursor: pointer;
    }




/* ===================================================
   REQUEST PAGE
=================================================== */

.request-page {
    display: flex;
    justify-content: center;
    padding: 40px 20px;
}

.request-container {
    width: 100%;
    max-width: 720px;
}

/* -------------------
   HEADER
------------------- */

.request-header {
    text-align: center;
    margin-bottom: 28px;
}

.request-title {
    font-size: 32px;
    font-weight: 700;
}

.request-subtitle {
    color: #94a3b8;
    margin-top: 6px;
    font-size: 14px;
}

/* -------------------
   QUEUE
------------------- */

.queue-card {
    background: #1e293b;
    border-radius: 14px;
    padding: 18px;
    margin-bottom: 24px;
    border: 1px solid #334155;
}

.section-header {
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
    color: #cbd5f5;
}

.queue-item {
    display: flex;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #334155;
}

    .queue-item:last-child {
        border-bottom: none;
    }

    /* highlight the next song */

    .queue-item:first-child {
        background: #0f172a;
        border-radius: 10px;
        padding: 12px;
    }

.queue-art {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    object-fit: cover;
}

.queue-title {
    font-weight: 600;
}

.queue-artist {
    color: #94a3b8;
}

.queue-requester {
    font-size: 12px;
    color: #64748b;
}

/* -------------------
   SEARCH
------------------- */

.search-card {
    background: #1e293b;
    border-radius: 14px;
    padding: 18px;
    margin-bottom: 24px;
    border: 1px solid #334155;
    position: sticky;
    top: 0;
    z-index: 5;
}

.search-box {
    display: flex;
    gap: 10px;
}

.song-search {
    flex: 1;
    padding: 14px;
    border-radius: 10px;
    border: none;
    background: #0f172a;
    color: white;
    font-size: 16px;
}

    .song-search:focus {
        outline: 2px solid #2563eb;
    }

.search-btn {
    background: #2563eb;
    border: none;
    padding: 14px 18px;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
}

    .search-btn:hover {
        background: #1d4ed8;
    }

    .search-btn:disabled {
        opacity: .6;
    }

/* -------------------
   RESULTS
------------------- */

.results-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.song-card {
    display: flex;
    gap: 14px;
    background: #1e293b;
    padding: 16px;
    border-radius: 14px;
    align-items: center;
    border: 1px solid #334155;
    transition: transform .15s ease, box-shadow .15s ease;
}

    .song-card:hover {
        transform: translateY(-2px);
        box-shadow: 0 6px 16px rgba(0,0,0,.4);
    }

.song-art {
    width: 72px;
    height: 72px;
    border-radius: 10px;
    object-fit: cover;
}

.song-info {
    flex: 1;
}

.song-name {
    font-weight: 600;
}

.song-artist {
    color: #94a3b8;
}

/* request button */

.request-btn {
    margin-top: 8px;
    background: #22c55e;
    border: none;
    padding: 10px 16px;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    cursor: pointer;
}

    .request-btn:hover {
        background: #16a34a;
    }

/* -------------------
   SPINNER
------------------- */

.spinner {
    width: 16px;
    height: 16px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
    animation: spin .7s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* -------------------
   MOBILE
------------------- */

@media (max-width:600px) {

    .request-container {
        max-width: 100%;
    }

    .song-card {
        padding: 18px;
    }

    .song-art {
        width: 64px;
        height: 64px;
    }
}


/* =========================
REQUEST MODAL
========================= */

.request-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.65);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-card {
    background: #1e293b;
    border-radius: 14px;
    padding: 25px;
    width: 90%;
    max-width: 420px;
    box-shadow: 0 20px 40px rgba(0,0,0,.5);
}

    .modal-card h3 {
        margin-bottom: 15px;
    }

.modal-input {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: none;
    margin-bottom: 15px;
    background: #0f172a;
    color: white;
}

.submit-btn {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: none;
    background: #16a34a;
    color: white;
    font-weight: 600;
    cursor: pointer;
}

    .submit-btn:hover {
        background: #15803d;
    }

.cancel-btn {
    margin-top: 10px;
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    border: none;
    background: #334155;
    color: white;
    cursor: pointer;
}

    .cancel-btn:hover {
        background: #475569;
    }


/* =========================
TIP SECTION
========================= */

.tip-section {
    margin-top: 20px;
    padding: 16px;
    border-radius: 10px;
    background: #0f172a;
    border: 1px solid #334155;
    text-align: center;
}

.tip-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 12px;
    color: #cbd5f5;
}

.tip-buttons {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.tip-btn {
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    text-decoration: none;
    display: inline-block;
    transition: transform .15s ease, box-shadow .15s ease;
}

    .tip-btn:hover {
        transform: translateY(-2px);
        box-shadow: 0 4px 10px rgba(0,0,0,0.35);
    }

    /* CashApp */

    .tip-btn.cashapp {
        background: #00d632;
        color: black;
    }

    /* Venmo */

    .tip-btn.venmo {
        background: #3d95ce;
        color: white;
    }

    /* PayPal */

    .tip-btn.paypal {
        background: #0070ba;
        color: white;
    }


/* -------------------------
   ERROR UI
--------------------------*/

/* -------------------------
   BLAZOR ERROR UI
--------------------------*/

#blazor-error-ui {
    display: none;
    position: fixed;
    bottom: 0;
    width: 100%;
    background: #b91c1c;
    color: white;
    padding: 10px 16px;
    font-size: 14px;
    z-index: 1000;
}

    #blazor-error-ui .reload {
        color: white;
        font-weight: 600;
        margin-left: 12px;
    }

    #blazor-error-ui .dismiss {
        position: absolute;
        right: 12px;
        top: 8px;
        cursor: pointer;
        font-size: 18px;
    }

/* -------------------------
   MOBILE OPTIMIZATION
--------------------------*/

@media (max-width: 600px) {

    .login-card {
        padding: 30px 20px;
        border-radius: 10px;
    }

    .app-title {
        font-size: 26px;
    }
}



/* -------------------------
   LAYOUT
--------------------------*/

.app-layout {
    display: flex;
    min-height: 100vh;
}

/* -------------------------
   TOP BAR (mobile)
--------------------------*/

.top-bar {
    display: none;
    height: 60px;
    background: #1e293b;
    align-items: center;
    padding: 0 15px;
    border-bottom: 1px solid #334155;
}

.app-logo {
    font-weight: 700;
    font-size: 18px;
    margin-left: 10px;
}

.mobile-menu-btn {
    background: none;
    border: none;
    color: white;
    font-size: 22px;
    cursor: pointer;
}

/* -------------------------
   SIDEBAR
--------------------------*/

.sidebar {
    width: 230px;
    background: #1e293b;
    border-right: 1px solid #334155;
    padding: 20px;
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 25px;
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

    .nav-links a {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 10px 12px;
        border-radius: 6px;
        color: #cbd5f5;
        text-decoration: none;
        transition: background .15s;
    }

        .nav-links a:hover {
            background: #0f172a;
        }

    .nav-links .active {
        background: #2563eb;
        color: white;
    }

.logout-link {
    margin-top: 20px;
    color: #f87171;
}

/* -------------------------
   MAIN CONTENT
--------------------------*/

.main-content {
    flex: 1;
    padding: 30px;
}

/* -------------------------
   MOBILE NAV
--------------------------*/

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,.5);
    z-index: 5;
}

@media(max-width:900px) {

    .sidebar {
        position: fixed;
        left: -260px;
        top: 0;
        height: 100%;
        z-index: 10;
        transition: left .25s;
    }

        .sidebar.open {
            left: 0;
        }

    .top-bar {
        display: flex;
    }

    .app-layout {
        flex-direction: column;
    }

    .main-content {
        padding: 20px;
    }
}
