/* Smartphone-first circa-2015 CSS 3 styles for Journey XR Control (`journey-xr-c`). */

* {
    box-sizing: border-box;
}

.hidden {
    display: none !important;
}

html,
body {
    margin: 0;
    padding: 0;
    min-height: 100%;
    background: #09071a;
    color: #eef2ff;
    font-family: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    -webkit-text-size-adjust: 100%;
    overflow-x: hidden;
}

.ctrl-shell {
    max-width: 520px;
    margin: 0 auto;
    padding: 10px 12px 28px 12px;
}

/* Top Navigation Bar */
.top-bar {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    padding: 8px 10px;
    margin-bottom: 10px;
    background: #13112d;
    border: 1px solid #2b2759;
    border-radius: 14px;
}

.back-link {
    display: inline-block;
    padding: 8px 10px;
    border-radius: 9px;
    background: #1f1c45;
    border: 1px solid #3c377a;
    color: #dbeafe;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.back-link:active {
    background: #2f2a68;
}

.top-brand {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: 0.08em;
    color: #ffffff;
}

.top-icon {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    margin-right: 6px;
    background: #ffffff;
}

.comms-badge {
    font-family: monospace;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 8px;
    border-radius: 999px;
    background: #1c2448;
    color: #7dd3fc;
    white-space: nowrap;
}

.comms-badge.is-offline {
    background: #4c1d2c;
    color: #fda4af;
}

/* Cards */
.card {
    position: relative;
    padding: 14px;
    margin-bottom: 12px;
    background: #13112d;
    border: 1px solid #2c285e;
    border-radius: 16px;
    overflow: hidden;
}

.accent-bar {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: #38f2ff;
}

.now-card {
    padding-top: 16px;
}

.now-head {
    display: -webkit-flex;
    display: flex;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    -webkit-align-items: center;
    align-items: center;
}

.now-thumb-wrap {
    width: 72px;
    height: 46px;
    border-radius: 9px;
    overflow: hidden;
    margin-right: 10px;
    border: 1px solid #3c377a;
    background: #1b1740;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}

.now-thumb {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.now-titles {
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-width: 0;
    padding-right: 8px;
}

.eyebrow {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.16em;
    color: #38f2ff;
}

.now-title {
    margin: 3px 0 2px 0;
    font-size: 20px;
    font-weight: 800;
    line-height: 1.2;
    color: #ffffff;
}

.now-sub {
    font-size: 12.5px;
    color: #cbd5e1;
}

.vr-badge {
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
    font-size: 10.5px;
    font-weight: 800;
    letter-spacing: 0.08em;
    padding: 4px 8px;
    border-radius: 999px;
    background: #1e2a54;
    border: 1px solid #38bdf8;
    color: #7dd3fc;
}

.vr-badge.is-vr {
    background: #581c87;
    border-color: #e879f9;
    color: #f5d0fe;
}

.prog-row {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    margin: 12px 0;
}

.prog-track {
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    height: 8px;
    border-radius: 999px;
    background: #221f4a;
    overflow: hidden;
    margin-right: 10px;
}

.prog-fill {
    width: 0%;
    height: 100%;
    border-radius: 999px;
    background: #38f2ff;
    transition: width 160ms linear;
}

.prog-timer {
    font-family: monospace;
    font-size: 13px;
    font-weight: 700;
    color: #e0f2fe;
    min-width: 38px;
    text-align: right;
}

.quick-transport {
    display: -webkit-flex;
    display: flex;
    margin: 0 -3px;
}

.quick-transport .btn-ctl {
    -webkit-flex: 1 1 0;
    flex: 1 1 0;
    margin: 0 3px;
}

/* Section Headers */
.card-head {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    margin-bottom: 10px;
}

.card-title {
    margin: 0;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: #c7d2fe;
}

.sub-head {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    -webkit-justify-content: space-between;
    justify-content: space-between;
    margin: 12px 0 6px 0;
}

.sub-label {
    font-size: 12px;
    font-weight: 700;
    color: #cbd5e1;
}

.val-pill {
    font-family: monospace;
    font-size: 12px;
    padding: 3px 9px;
    border-radius: 999px;
    background: #1d2c54;
    color: #38f2ff;
    white-space: nowrap;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}

.val-muted {
    font-family: monospace;
    font-size: 12px;
    color: #93c5fd;
}

/* Buttons & Pills */
.btn-ctl,
.mini-btn,
.pill-btn {
    min-height: 44px;
    padding: 8px 10px;
    border-radius: 11px;
    border: 1px solid #3a3578;
    background: #1d1a44;
    color: #f1f5f9;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    touch-action: manipulation;
    transition: background-color 120ms ease, border-color 120ms ease;
}

.btn-ctl:active,
.mini-btn:active,
.pill-btn:active {
    background: #312c6e;
}

.btn-primary {
    background: #0284c7;
    border-color: #38bdf8;
    color: #ffffff;
}

.btn-accent {
    background: #7c3aed;
    border-color: #c084fc;
    color: #ffffff;
}

.btn-ctl.is-on,
.mini-btn.is-on,
.pill-btn.is-active {
    background: #164e63;
    border-color: #38f2ff;
    color: #e0f2fe;
}

.mini-btn {
    min-height: 36px;
    padding: 5px 11px;
    font-size: 12px;
}

.pill-row {
    display: -webkit-flex;
    display: flex;
    margin: 6px -3px 0 -3px;
}

.pill-row .pill-btn {
    -webkit-flex: 1 1 0;
    flex: 1 1 0;
    margin: 0 3px;
    min-height: 40px;
    padding: 6px 4px;
    font-size: 12px;
}

.pill-wrap {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-wrap: wrap;
    flex-wrap: wrap;
    margin: 4px -3px 0 -3px;
}

.pill-wrap .pill-btn {
    -webkit-flex: 1 1 28%;
    flex: 1 1 28%;
    margin: 3px;
    min-height: 38px;
    padding: 6px 4px;
    font-size: 11.5px;
}

.toggle-grid {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-wrap: wrap;
    flex-wrap: wrap;
    margin: 10px -4px 0 -4px;
}

.toggle-grid .btn-ctl {
    -webkit-flex: 1 1 46%;
    flex: 1 1 46%;
    margin: 4px;
    font-size: 12.5px;
}

/* World Cards */
.world-grid {
    display: -webkit-flex;
    display: flex;
    -webkit-flex-direction: column;
    flex-direction: column;
}

.world-card {
    display: -webkit-flex;
    display: flex;
    -webkit-align-items: center;
    align-items: center;
    width: 100%;
    padding: 8px 10px 8px 8px;
    margin-bottom: 8px;
    border-radius: 13px;
    border: 1px solid #35306d;
    background: #19163c;
    color: #f8fafc;
    text-align: left;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    touch-action: manipulation;
}

.world-card:last-child {
    margin-bottom: 0;
}

.world-card.is-current {
    background: #231e54;
    border-color: #38f2ff;
}

.world-thumb-wrap {
    width: 96px;
    height: 58px;
    border-radius: 9px;
    overflow: hidden;
    margin-right: 11px;
    border: 2px solid #35306d;
    background: #120f2b;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
    position: relative;
}

.world-card.is-current .world-thumb-wrap {
    border-color: #38f2ff;
}

.world-thumb {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.world-thumb-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
}

.world-card-body {
    -webkit-flex: 1 1 auto;
    flex: 1 1 auto;
    min-width: 0;
}

.world-card-name {
    font-size: 15px;
    font-weight: 800;
    color: #ffffff;
}

.world-card-sub {
    font-size: 12px;
    color: #cbd5e1;
    margin-top: 2px;
}

.world-card-audio {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 4px;
}

.world-card-tag {
    margin-left: 8px;
    padding: 4px 8px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.08em;
    background: #29255c;
    color: #93c5fd;
    -webkit-flex-shrink: 0;
    flex-shrink: 0;
}

.world-card.is-current .world-card-tag {
    background: #38f2ff;
    color: #081226;
}

/* Range Sliders */
.range-input {
    width: 100%;
    height: 36px;
    margin: 2px 0;
    accent-color: #38f2ff;
    cursor: pointer;
}

.slider-block {
    margin-top: 4px;
}

.pulse-cta {
    width: 100%;
    min-height: 48px;
    margin-bottom: 8px;
    border-radius: 12px;
    border: 1px solid #f472b6;
    background: #86198f;
    color: #ffffff;
    font-size: 14px;
    font-weight: 800;
    letter-spacing: 0.03em;
    cursor: pointer;
    touch-action: manipulation;
}

.pulse-cta:active {
    background: #a21caf;
}

/* Bottom Floating Toast */
.toast {
    position: fixed;
    left: 50%;
    bottom: 16px;
    transform: translateX(-50%);
    z-index: 50;
    max-width: 90%;
    padding: 10px 16px;
    border-radius: 999px;
    background: #0f172a;
    border: 1px solid #38f2ff;
    color: #f8fafc;
    font-size: 13px;
    font-weight: 700;
    text-align: center;
}
