:root {
    --bg-top: #f3d19b;
    --bg-bottom: #f7ead3;
    --panel-top: #6e4314;
    --panel-bottom: #180d05;
    --panel-line: rgba(255, 255, 255, 0.08);
    --text-main: #fff7ee;
    --text-soft: rgba(255, 245, 231, 0.78);
    --text-muted: rgba(255, 245, 231, 0.56);
    --accent: #d2a25b;
    --accent-strong: #f3c36f;
    --surface: rgba(255, 255, 255, 0.06);
    --danger: #f7927d;
    --shadow: 0 32px 64px rgba(64, 28, 0, 0.28);
    --font-main: "Trebuchet MS", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html,
body {
    margin: 0;
    min-height: 100%;
    font-family: var(--font-main);
}

body {
    background:
        radial-gradient(circle at top left, rgba(255, 255, 255, 0.35), transparent 32%),
        linear-gradient(180deg, var(--bg-top), var(--bg-bottom));
    color: var(--text-main);
}

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

button,
input,
a {
    font: inherit;
}

.page-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 24px;
}

.phone-stage {
    width: 100%;
    display: flex;
    justify-content: center;
}

.player-shell {
    width: min(100%, 390px);
}

.player-card {
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.05), transparent 24%),
        linear-gradient(180deg, var(--panel-top), var(--panel-bottom));
    border: 1px solid rgba(255, 243, 220, 0.12);
    border-radius: 28px;
    padding: 18px;
    box-shadow: var(--shadow);
    backdrop-filter: blur(14px);
}

.player-topbar,
.track-copy,
.station-panel,
.queue-header,
.admin-track-card,
.admin-hero,
.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.player-topbar {
    margin-bottom: 14px;
    color: #5f360d;
}

.status-time {
    font-size: 0.9rem;
    font-weight: 700;
}

.chip-group {
    display: flex;
    gap: 6px;
}

.chip {
    padding: 5px 10px;
    border-radius: 999px;
    background: rgba(72, 34, 4, 0.18);
    font-size: 0.74rem;
    color: #5f360d;
}

.chip-primary {
    background: #5b287e;
    color: white;
}

.menu-link,
.primary-link,
.link-button {
    text-decoration: none;
    color: inherit;
}

.menu-link {
    color: #5f360d;
    font-size: 0.82rem;
    font-weight: 700;
}

.artwork-wrap {
    position: relative;
    border-radius: 22px;
    overflow: hidden;
    aspect-ratio: 1 / 1;
    margin-bottom: 18px;
    background:
        linear-gradient(180deg, rgba(249, 210, 134, 0.82), rgba(99, 49, 11, 0.92)),
        radial-gradient(circle at top, rgba(255, 246, 212, 0.45), transparent 42%);
}

.artwork-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.artwork-fallback {
    width: 100%;
    height: 100%;
    display: grid;
    place-items: center;
    text-align: center;
    letter-spacing: 0.08em;
    background:
        linear-gradient(135deg, rgba(255, 221, 164, 0.18), rgba(52, 20, 0, 0.2)),
        radial-gradient(circle at center, rgba(255, 229, 161, 0.28), transparent 54%);
}

.artwork-fallback span {
    display: block;
    font-size: 1rem;
    color: rgba(255, 247, 238, 0.72);
}

.artwork-fallback strong {
    display: block;
    margin-top: 6px;
    font-size: clamp(2.2rem, 9vw, 3.8rem);
}

.live-badge {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 2;
    padding: 7px 10px;
    border-radius: 999px;
    background: rgba(16, 7, 2, 0.72);
    border: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 0.74rem;
    font-weight: 700;
}

.track-copy h1,
.station-panel h2,
.queue-header h3,
.admin-hero h1,
.section-heading h2 {
    margin: 0;
}

.track-copy h1 {
    font-size: clamp(1.9rem, 7vw, 2.5rem);
}

.track-artist,
.station-tagline,
.hero-copy,
.helper-copy {
    margin: 6px 0 0;
    color: var(--text-soft);
}

.eyebrow {
    margin: 0 0 6px;
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 0.16em;
    color: var(--text-muted);
}

.ghost-heart,
.mini-button,
.transport,
.primary-button,
.danger-button,
.primary-link {
    border: none;
    cursor: pointer;
    transition: transform 0.18s ease, background 0.18s ease, opacity 0.18s ease;
}

.ghost-heart,
.mini-button,
.transport.ghost,
.danger-button {
    background: var(--surface);
    color: var(--text-main);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.ghost-heart,
.mini-button {
    padding: 10px 14px;
    border-radius: 14px;
}

.timeline-block {
    margin-top: 18px;
}

.timeline-labels {
    display: flex;
    justify-content: space-between;
    color: var(--text-soft);
    font-size: 0.82rem;
    margin-bottom: 8px;
}

.progress-range {
    width: 100%;
    accent-color: var(--accent-strong);
}

.transport-row {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-top: 18px;
}

.transport {
    min-height: 48px;
    border-radius: 16px;
    display: grid;
    place-items: center;
    color: var(--text-main);
}

.transport.play,
.primary-button,
.primary-link {
    background: linear-gradient(180deg, var(--accent-strong), var(--accent));
    color: #2b1705;
    font-weight: 800;
}

.link-button {
    display: grid;
    place-items: center;
}

.track-links {
    margin-top: 10px;
}

.music-link,
.inline-link {
    color: var(--accent-strong);
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 700;
}

.station-panel,
.queue-panel,
.admin-card,
.admin-hero {
    margin-top: 18px;
    padding: 16px;
    border-radius: 22px;
    background: var(--surface);
    border: 1px solid var(--panel-line);
}

.sync-box {
    text-align: right;
}

.sync-box small {
    display: block;
    margin-top: 6px;
    color: var(--text-muted);
}

.queue-panel {
    padding-top: 14px;
}

.queue-list,
.track-list {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

.queue-item,
.admin-track-card {
    padding: 12px 14px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.06);
}

.queue-copy,
.admin-track-copy {
    display: flex;
    align-items: center;
    gap: 12px;
}

.queue-copy {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
}

.queue-copy span,
.admin-track-copy p,
.admin-track-copy small,
.empty-queue {
    color: var(--text-soft);
}

.queue-index {
    width: 34px;
    height: 34px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.08);
    color: var(--accent-strong);
    font-weight: 700;
    flex-shrink: 0;
}

.empty-queue {
    margin: 0;
}

.admin-body {
    min-height: 100vh;
    padding: 26px;
    color: #2b1705;
}

.admin-shell {
    width: min(1180px, 100%);
    margin: 0 auto;
}

.admin-hero {
    background:
        linear-gradient(135deg, rgba(113, 65, 17, 0.92), rgba(28, 12, 2, 0.96)),
        radial-gradient(circle at top right, rgba(255, 214, 146, 0.25), transparent 42%);
    color: #fff7ee;
}

.primary-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 18px;
    border-radius: 16px;
}

.admin-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-top: 18px;
}

.stack-form {
    display: grid;
    gap: 14px;
}

.stack-form label {
    display: grid;
    gap: 7px;
}

.stack-form span {
    color: #6f4a23;
    font-size: 0.92rem;
}

.stack-form input {
    width: 100%;
    padding: 13px 14px;
    border-radius: 14px;
    border: 1px solid rgba(111, 74, 35, 0.18);
    background: rgba(255, 255, 255, 0.92);
    color: #2b1705;
}

.stack-form input::placeholder {
    color: rgba(111, 74, 35, 0.48);
}

.stack-form input:focus {
    outline: 2px solid rgba(210, 162, 91, 0.45);
    border-color: rgba(210, 162, 91, 0.8);
}

.admin-body .admin-card,
.admin-body .list-card {
    background: rgba(255, 251, 244, 0.8);
    border-color: rgba(111, 74, 35, 0.12);
    box-shadow: 0 18px 40px rgba(107, 62, 15, 0.08);
}

.admin-body .eyebrow {
    color: rgba(111, 74, 35, 0.62);
}

.admin-body .hero-copy {
    color: rgba(255, 247, 238, 0.84);
}

.admin-body .section-heading h2,
.admin-body .admin-track-copy strong,
.admin-body .helper-copy strong {
    color: #2b1705;
}

.admin-body .admin-track-card {
    background: rgba(255, 255, 255, 0.86);
    border-color: rgba(111, 74, 35, 0.1);
}

.admin-body .admin-track-copy p,
.admin-body .admin-track-copy small,
.admin-body .empty-queue,
.admin-body .helper-copy {
    color: #6f4a23;
}

.admin-body .mini-button,
.admin-body .danger-button {
    color: #7d2d1f;
    border-color: rgba(111, 74, 35, 0.16);
    background: rgba(255, 248, 238, 0.92);
}

.admin-body .inline-link {
    color: #8c4b0f;
}

.primary-button,
.danger-button {
    padding: 13px 16px;
    border-radius: 15px;
}

.danger-button {
    color: var(--danger);
}

.list-card {
    margin-top: 18px;
}

.admin-message {
    margin-top: 14px;
    padding: 12px 14px;
    border-radius: 14px;
}

.admin-message.success {
    background: rgba(113, 202, 157, 0.14);
    color: #d8ffec;
}

.admin-message.error {
    background: rgba(247, 146, 125, 0.16);
    color: #ffe8e2;
}

.admin-body .admin-message.success {
    background: #e7f7ee;
    color: #1d5a38;
    border: 1px solid rgba(29, 90, 56, 0.12);
}

.admin-body .admin-message.error {
    background: #fdecea;
    color: #8d2c1d;
    border: 1px solid rgba(141, 44, 29, 0.12);
}

button:hover,
a:hover {
    transform: translateY(-1px);
}

@media (max-width: 820px) {
    .admin-body {
        padding: 18px;
    }

    .admin-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .page-shell,
    .admin-body {
        padding: 14px;
    }

    .player-card,
    .admin-card,
    .admin-hero {
        border-radius: 24px;
    }

    .player-topbar,
    .track-copy,
    .station-panel,
    .queue-header,
    .admin-hero,
    .section-heading,
    .admin-track-card {
        flex-direction: column;
        align-items: stretch;
    }

    .transport-row {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }

    .sync-box {
        text-align: left;
    }
}
