/* ============================================================
   Rockola Live 4.0 — Estilos globales
   ============================================================ */

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

:root {
    --bg:          #0f0f13;
    --bg-card:     #1a1a24;
    --bg-input:    #25253a;
    --accent:      #7c3aed;
    --accent-hover:#6d28d9;
    --accent-light:#a78bfa;
    --success:     #10b981;
    --warning:     #f59e0b;
    --danger:      #ef4444;
    --text:        #e2e8f0;
    --text-muted:  #94a3b8;
    --border:      #2d2d45;
    --radius:      10px;
    --shadow:      0 4px 24px rgba(0,0,0,0.4);
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    min-height: 100vh;
}

a { color: var(--accent-light); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---- Auth Layout ---- */
.auth-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: 1.5rem;
}

.auth-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 2.5rem 2rem;
    width: 100%;
    max-width: 420px;
}

.auth-logo {
    text-align: center;
    margin-bottom: 1.8rem;
}

.logo-icon { font-size: 2.4rem; }

.auth-logo h1 {
    font-size: 1.6rem;
    font-weight: 700;
    margin-top: .4rem;
    color: var(--accent-light);
}

.auth-logo p { color: var(--text-muted); font-size: .9rem; margin-top: .3rem; }

.auth-footer {
    text-align: center;
    margin-top: 1.2rem;
    font-size: .875rem;
    color: var(--text-muted);
}

/* ---- App Layout ---- */
.app-layout { display: flex; flex-direction: column; min-height: 100vh; }

.app-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .9rem 1.5rem;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.app-header h1 { font-size: 1.1rem; font-weight: 600; flex: 1; }
.room-code-badge { font-size: .85rem; color: var(--text-muted); }

.app-main { padding: 1.5rem; max-width: 1100px; margin: 0 auto; width: 100%; }

/* ---- Cards ---- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.card h2 { font-size: 1rem; font-weight: 600; margin-bottom: 1rem; color: var(--accent-light); }

/* ---- Forms ---- */
.form-group { margin-bottom: 1rem; }

.form-group label {
    display: block;
    font-size: .85rem;
    font-weight: 500;
    margin-bottom: .35rem;
    color: var(--text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: .6rem .9rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 6px;
    color: var(--text);
    font-size: .95rem;
    transition: border-color .15s;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
}

.form-inline { display: flex; flex-wrap: wrap; gap: 1rem; align-items: flex-end; }
.form-inline .form-group { flex: 1; min-width: 180px; margin-bottom: 0; }

/* ---- Buttons ---- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    padding: .5rem 1.1rem;
    border-radius: 6px;
    font-size: .88rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    transition: background .15s, opacity .15s;
    text-decoration: none;
    white-space: nowrap;
}

.btn:hover { opacity: .88; }
.btn-block { width: 100%; justify-content: center; }
.btn-sm { padding: .3rem .75rem; font-size: .8rem; }

.btn-primary  { background: var(--accent);   color: #fff; }
.btn-success  { background: var(--success);  color: #fff; }
.btn-warning  { background: var(--warning);  color: #000; }
.btn-danger   { background: var(--danger);   color: #fff; }
.btn-outline  { background: transparent; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { border-color: var(--accent-light); color: var(--accent-light); opacity: 1; }

/* ---- Alerts ---- */
.alert {
    padding: .75rem 1rem;
    border-radius: 6px;
    margin-bottom: 1rem;
    font-size: .9rem;
    border: 1px solid transparent;
}

.alert-error   { background: rgba(239,68,68,.15);  border-color: var(--danger);  color: #fca5a5; }
.alert-success { background: rgba(16,185,129,.15); border-color: var(--success); color: #6ee7b7; }

/* ---- Table ---- */
.table {
    width: 100%;
    border-collapse: collapse;
    font-size: .88rem;
}

.table th, .table td {
    padding: .65rem .9rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.table th { color: var(--text-muted); font-weight: 500; }
.table tr:last-child td { border-bottom: none; }
.table .actions { display: flex; gap: .4rem; flex-wrap: wrap; }

/* ---- Badges ---- */
.badge {
    display: inline-block;
    padding: .2rem .55rem;
    border-radius: 20px;
    font-size: .78rem;
    font-weight: 600;
}

.badge-active    { background: rgba(16,185,129,.2); color: #6ee7b7; }
.badge-suspended { background: rgba(245,158,11,.2); color: #fcd34d; }
.badge-deleted   { background: rgba(239,68,68,.2);  color: #fca5a5; }

/* ---- Room code ---- */
.room-code {
    font-family: monospace;
    font-size: 1rem;
    letter-spacing: .1em;
    background: var(--bg-input);
    padding: .15rem .45rem;
    border-radius: 4px;
    color: var(--accent-light);
}

/* ---- Queue list ---- */
.queue-list { list-style: none; }

.queue-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .75rem;
    border-radius: 8px;
    margin-bottom: .5rem;
    background: var(--bg-input);
    border: 1px solid var(--border);
    transition: border-color .15s;
}

.queue-item.playing {
    border-color: var(--accent);
    background: rgba(124,58,237,.1);
}

.queue-item img { border-radius: 4px; object-fit: cover; flex-shrink: 0; }

.queue-info strong { display: block; font-size: .9rem; }
.queue-info small  { color: var(--text-muted); font-size: .78rem; }

/* ---- Text utilities ---- */
.text-muted { color: var(--text-muted); }
.hidden     { display: none !important; }

/* ---- Responsive ---- */
@media (max-width: 600px) {
    .app-header { padding: .7rem 1rem; }
    .app-main   { padding: 1rem; }
    .card       { padding: 1rem; }
    .form-inline { flex-direction: column; }
    .table      { display: block; overflow-x: auto; }
}
