:root {
  --bg: #f7f8fa;
  --panel: #ffffff;
  --panel-2: #eef3f2;
  --ink: #202524;
  --muted: #66706d;
  --line: #dce3e1;
  --brand: #247a7a;
  --brand-2: #d8644a;
  --accent: #d19a2e;
  --ok: #27845f;
  --warn: #ba7b18;
  --bad: #b94747;
  --radius: 8px;
  --shadow: 0 18px 40px rgba(32, 37, 36, .08);
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
}

button, input, select, textarea {
  font: inherit;
}

button {
  border: 0;
  cursor: pointer;
}

.icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
  flex: 0 0 auto;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
}

.sidebar {
  background: #202524;
  color: #f7fbfa;
  padding: 20px 14px;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.brand-block {
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px 8px 16px;
  border-bottom: 1px solid rgba(255,255,255,.14);
}

.brand-mark {
  width: 44px;
  height: 44px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  display: grid;
  place-items: center;
  font-weight: 800;
  overflow: hidden;
}

.brand-mark img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-name {
  font-weight: 800;
  line-height: 1.1;
}

.brand-sub {
  color: rgba(255,255,255,.62);
  font-size: 12px;
  margin-top: 4px;
}

.nav {
  display: grid;
  gap: 5px;
}

.nav button,
.sidebar-action {
  color: rgba(255,255,255,.78);
  background: transparent;
  display: flex;
  gap: 10px;
  align-items: center;
  width: 100%;
  padding: 11px 10px;
  border-radius: 8px;
  text-align: left;
}

.nav button.active,
.nav button:hover,
.sidebar-action:hover {
  color: #fff;
  background: rgba(255,255,255,.12);
}

.sidebar-foot {
  margin-top: auto;
  display: grid;
  gap: 8px;
}

.main {
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.topbar {
  min-height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 28px;
  border-bottom: 1px solid var(--line);
  background: rgba(247,248,250,.92);
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(12px);
}

.mobile-menu {
  display: none;
}

.page-title h1 {
  font-size: 24px;
  margin: 0;
  letter-spacing: 0;
}

.page-title p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.top-actions {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.content {
  padding: 26px 28px 42px;
  width: min(1500px, 100%);
}

.grid {
  display: grid;
  gap: 16px;
}

.grid.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

.panel, .card, .stat, .table-wrap {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.panel {
  padding: 18px;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.section-head h2 {
  font-size: 16px;
  margin: 0;
}

.section-head p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 13px;
}

.stat {
  padding: 16px;
  min-height: 112px;
  display: grid;
  gap: 12px;
}

.stat-label {
  color: var(--muted);
  font-size: 13px;
}

.stat-value {
  font-size: 30px;
  font-weight: 800;
  line-height: 1;
}

.stat-foot {
  color: var(--muted);
  font-size: 12px;
}

.btn {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 8px;
  padding: 9px 13px;
  color: var(--ink);
  background: var(--panel-2);
  border: 1px solid var(--line);
  white-space: nowrap;
}

.btn.primary {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.btn.danger {
  background: #fff0ef;
  border-color: #f4c2bd;
  color: var(--bad);
}

.btn.ghost {
  background: transparent;
}

.icon-btn {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border-radius: 8px;
  color: var(--ink);
  background: var(--panel-2);
  border: 1px solid var(--line);
}

.toolbar {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.field {
  display: grid;
  gap: 7px;
}

.field label {
  font-size: 12px;
  color: var(--muted);
  font-weight: 700;
  text-transform: uppercase;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 40px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 9px 11px;
  background: #fff;
  color: var(--ink);
}

.field textarea {
  min-height: 96px;
  resize: vertical;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.full { grid-column: 1 / -1; }

.table-wrap {
  overflow: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

th, td {
  text-align: left;
  padding: 13px 14px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
  font-size: 14px;
}

th {
  color: var(--muted);
  font-size: 12px;
  text-transform: uppercase;
  background: #fbfcfc;
}

tr:last-child td {
  border-bottom: 0;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 24px;
  padding: 4px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.pill.ok { background: #e7f5ee; color: var(--ok); }
.pill.warn { background: #fff4df; color: var(--warn); }
.pill.bad { background: #fff0ef; color: var(--bad); }
.pill.neutral { background: var(--panel-2); color: var(--muted); }
.pill.brand { background: #e4f3f3; color: var(--brand); }

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 14px;
}

.media-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.thumb {
  aspect-ratio: 16 / 10;
  background: #27302e;
  display: grid;
  place-items: center;
  color: #fff;
  overflow: hidden;
}

.thumb img,
.thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-info {
  padding: 12px;
  display: grid;
  gap: 8px;
}

.media-title {
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.meta {
  color: var(--muted);
  font-size: 12px;
}

.playlist-builder {
  display: grid;
  grid-template-columns: minmax(220px, 340px) minmax(0, 1fr);
  gap: 16px;
}

.listbox {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: #fff;
}

.list-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
  padding: 11px 12px;
  border-bottom: 1px solid var(--line);
}

.list-row:last-child { border-bottom: 0; }
.list-row.active { background: #e4f3f3; }

.timeline {
  display: grid;
  gap: 10px;
}

.timeline-item {
  display: grid;
  grid-template-columns: 54px 1fr auto auto;
  gap: 12px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
}

.tiny-thumb {
  width: 54px;
  height: 42px;
  border-radius: 6px;
  background: #27302e;
  display: grid;
  place-items: center;
  color: #fff;
  overflow: hidden;
  font-size: 12px;
}

.tiny-thumb img,
.tiny-thumb video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.segmented {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}

.segmented button {
  min-height: 36px;
  padding: 8px 11px;
  background: transparent;
  color: var(--muted);
  border-right: 1px solid var(--line);
}

.segmented button:last-child { border-right: 0; }
.segmented button.active { background: var(--brand); color: #fff; }

.player-shell {
  min-height: 100vh;
  background: #111;
  color: #fff;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.player-frame {
  width: 100vw;
  height: 100vh;
  position: relative;
  display: grid;
  place-items: center;
  background: #111;
}

.player-media {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #111;
}

.player-empty {
  text-align: center;
  max-width: 620px;
  padding: 30px;
}

.pair-code {
  font-size: clamp(42px, 9vw, 100px);
  font-weight: 900;
  letter-spacing: 8px;
  margin: 18px 0;
}

.player-badge {
  position: fixed;
  left: 18px;
  bottom: 18px;
  background: rgba(0,0,0,.6);
  border: 1px solid rgba(255,255,255,.18);
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 12px;
}

.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(16,20,19,.52);
  display: grid;
  place-items: center;
  padding: 18px;
  z-index: 50;
}

.modal {
  width: min(720px, 100%);
  max-height: 92vh;
  overflow: auto;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 28px 80px rgba(0,0,0,.24);
}

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
}

.modal-head h2 {
  margin: 0;
  font-size: 18px;
}

.modal-body {
  padding: 18px;
}

.modal-foot {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  padding: 16px 18px;
  border-top: 1px solid var(--line);
}

.toast {
  position: fixed;
  right: 18px;
  bottom: 18px;
  background: #202524;
  color: #fff;
  border-radius: 8px;
  padding: 12px 14px;
  box-shadow: var(--shadow);
  z-index: 60;
}

.empty-state {
  min-height: 220px;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  background: #fff;
  padding: 22px;
}

.dropzone {
  border: 1px dashed var(--line);
  background: #fbfcfc;
  border-radius: var(--radius);
  min-height: 142px;
  display: grid;
  place-items: center;
  text-align: center;
  padding: 18px;
}

.dropzone input {
  display: none;
}

.progress {
  height: 8px;
  background: var(--panel-2);
  border-radius: 999px;
  overflow: hidden;
}

.bar {
  height: 100%;
  background: var(--brand);
}

.two-line {
  display: grid;
  gap: 2px;
}

.nowrap {
  white-space: nowrap;
}

.hide {
  display: none !important;
}

@media (max-width: 1050px) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed;
    z-index: 40;
    transform: translateX(-100%);
    transition: transform .2s ease;
    width: 260px;
  }
  .sidebar.open { transform: translateX(0); }
  .mobile-menu { display: inline-grid; }
  .grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid.cols-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .playlist-builder { grid-template-columns: 1fr; }
}

@media (max-width: 680px) {
  .topbar {
    align-items: flex-start;
    padding: 14px;
  }
  .content { padding: 16px 14px 32px; }
  .grid.cols-4,
  .grid.cols-3,
  .grid.cols-2,
  .form-grid { grid-template-columns: 1fr; }
  .top-actions { width: 100%; justify-content: flex-start; }
  .topbar { flex-wrap: wrap; }
  .timeline-item { grid-template-columns: 46px 1fr auto; }
  .timeline-item .meta-actions { grid-column: 1 / -1; }
}

/* PosterBooking-inspired application skin */
:root {
  --bg: #f4f6fb;
  --panel: #ffffff;
  --panel-2: #f8f9fd;
  --ink: #526078;
  --muted: #a6afc0;
  --line: #e8edf8;
  --brand: #6874df;
  --brand-2: #8d69c9;
  --accent: #8bdcf2;
  --ok: #22c38a;
  --warn: #ff9c2a;
  --bad: #e55757;
  --shadow: 0 18px 48px rgba(45, 55, 96, .10);
  font-family: "Inter", "Segoe UI", Arial, sans-serif;
}

body {
  background: linear-gradient(90deg, #eef2f7 0, #f8f9fd 210px, #fff 210px);
  color: var(--ink);
}

.app-shell {
  grid-template-columns: 190px minmax(0, 1fr);
}

.sidebar {
  background:
    linear-gradient(180deg, rgba(255,255,255,.92), rgba(247,250,253,.92)),
    radial-gradient(circle at 50% 100%, rgba(210, 220, 231, .55), transparent 42%);
  color: #607088;
  padding: 14px 10px;
  box-shadow: 8px 0 28px rgba(35, 45, 70, .13);
  border-right: 1px solid #e7ebf2;
}

.brand-block {
  display: block;
  padding: 8px 10px 18px;
  border-bottom: 1px solid #dce2eb;
}

.brand-mark {
  width: 142px;
  height: 76px;
  margin: 0 auto;
  border: 1px dashed #cbd3df;
  border-radius: 6px;
  background: rgba(255,255,255,.72);
  color: #174c84;
  font-size: 18px;
  font-style: italic;
  letter-spacing: 0;
  box-shadow: none;
}

.brand-name {
  display: none;
}

.brand-sub {
  color: #2862a0;
  text-align: center;
  font-size: 8px;
  font-weight: 700;
  margin-top: -24px;
  position: relative;
}

.nav {
  gap: 2px;
  margin-top: 10px;
}

.nav button,
.sidebar-action {
  color: #627089;
  min-height: 36px;
  padding: 8px 4px;
  border-radius: 5px;
  font-size: 12px;
  gap: 8px;
}

.nav button::after,
.sidebar-action::after {
  content: "";
  width: 14px;
  height: 10px;
  margin-left: auto;
  border-radius: 3px;
  background: #aeb8c8;
}

.nav button.active,
.nav button:hover,
.sidebar-action:hover {
  color: #4d5ed8;
  background: rgba(105, 116, 223, .08);
}

.nav .icon,
.sidebar-action .icon {
  color: #aeb8c8;
}

.live-help {
  color: #ff9c2a;
}

.main {
  background: #f7f8fc;
}

.topbar {
  min-height: 44px;
  padding: 4px 14px;
  justify-content: flex-end;
  background: #f3f4f7;
  box-shadow: 0 8px 24px rgba(40, 50, 70, .10);
  border-bottom: 0;
}

.page-title {
  display: none;
}

.top-actions {
  margin-left: auto;
  gap: 7px;
}

.top-actions .btn,
.top-actions .pill {
  min-height: 32px;
  font-size: 11px;
  box-shadow: none;
}

.content {
  width: 100%;
  padding: 20px 28px 62px;
}

.panel,
.card,
.stat,
.table-wrap,
.media-card,
.listbox,
.mini-card,
.tour-card,
.upload-option,
.example-playlist {
  border: 1px solid var(--line);
  border-radius: 14px;
  box-shadow: 0 20px 50px rgba(43, 54, 86, .07);
}

.panel {
  padding: 22px;
}

.btn,
.icon-btn {
  border-radius: 3px;
  border-color: #dbe2f2;
  color: #6874df;
  background: #fff;
  text-transform: uppercase;
  font-weight: 800;
  font-size: 11px;
}

.btn.primary {
  background: #fff;
  color: #5265ff;
  border: 2px solid #5265ff;
}

.pill {
  border-radius: 18px;
  box-shadow: 0 8px 20px rgba(80, 90, 130, .06);
}

.pill.brand {
  background: #f4f5ff;
  color: #5966d8;
}

.pill.ok {
  background: #ddfbf1;
  color: #22b889;
}

.wizard-hero {
  min-height: 335px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 14px;
  text-align: center;
  background: radial-gradient(circle at 50% 10%, rgba(104, 116, 223, .10), transparent 26%), #fbf9ff;
  border-radius: 0 0 18px 18px;
  box-shadow: 0 20px 55px rgba(43, 54, 86, .11);
  margin: -20px -8px 44px;
}

.wizard-hero .rocket {
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(145deg, #5d6bd8, #7357c3);
  border-radius: 22px;
  transform: rotate(-5deg);
  box-shadow: 0 18px 34px rgba(88, 93, 190, .24);
}

.wizard-hero .rocket .icon {
  width: 42px;
  height: 42px;
}

.wizard-hero h1 {
  margin: 0;
  color: #46578f;
  font-size: 31px;
}

.wizard-hero p {
  width: min(560px, 90%);
  margin: 0;
  color: #8e9bb1;
  line-height: 1.6;
}

.hero-pills {
  display: flex;
  gap: 16px;
}

.wizard-progress {
  margin-bottom: 40px;
  border-color: #dfe6ff;
}

.wizard-progress strong {
  color: #16bf85;
  font-size: 25px;
}

.progress {
  height: 8px;
  background: #dbdde3;
  box-shadow: inset 0 1px 4px rgba(0,0,0,.16);
}

.progress-labels {
  display: flex;
  justify-content: space-between;
  color: #a7b0c0;
  font-size: 11px;
  margin-top: 14px;
}

.tour-card {
  position: relative;
  background: rgba(255,255,255,.92);
  padding: 28px 64px 44px;
  margin: 0 36px 42px;
  min-height: 220px;
  border-top: 4px solid transparent;
}

.tour-card::before {
  content: "";
  position: absolute;
  left: -18px;
  top: -46px;
  bottom: -42px;
  width: 2px;
  background: #c7d0ff;
}

.tour-card.active-step {
  border-top-color: #6874df;
}

.step-head {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 20px;
}

.step-number {
  width: 50px;
  height: 50px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: #7f8da4;
  color: #fff;
  font-size: 22px;
  font-weight: 800;
  box-shadow: 0 14px 24px rgba(89, 105, 135, .32);
}

.step-head h2 {
  color: #8a96b5;
  font-size: 21px;
  margin: 0;
}

.tour-body {
  color: #9aa5b8;
}

.tour-body h3 {
  color: #46546c;
}

.feature-list {
  display: grid;
  gap: 20px;
  margin-top: 24px;
}

.feature-list div {
  display: flex;
  gap: 14px;
  align-items: center;
}

.feature-list .icon {
  color: #7675e3;
}

.info-strip,
.success-strip {
  border: 2px solid #75c6ef;
  border-radius: 8px;
  padding: 14px 18px;
  background: #f3fbff;
  color: #7083a5;
  font-weight: 800;
  margin: 18px 0;
  box-shadow: 0 10px 18px rgba(85, 180, 226, .14);
}

.success-strip {
  border-color: #76d7c0;
  background: #effcf7;
  color: #6abfae;
}

.mini-card,
.upload-option,
.example-playlist {
  background: #fff;
  padding: 24px;
}

.mini-card h3 {
  color: #a0a9cc;
}

.mini-card p {
  color: #9da7b8;
  line-height: 1.7;
}

.upload-options {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px;
}

.upload-option {
  min-height: 148px;
  display: grid;
  place-items: center;
  align-content: center;
  color: #a6a2d2;
}

.upload-option .icon {
  width: 34px;
  height: 34px;
  margin-bottom: 14px;
}

.upload-option span {
  font-size: 11px;
  color: #aeb7c6;
}

.example-playlist {
  align-self: start;
  padding: 30px;
}

.example-playlist small {
  display: block;
  margin-bottom: 16px;
  color: #8d94a5;
}

.example-playlist div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fbfbfd;
  padding: 12px 14px;
  margin: 9px 0;
  color: #a3acbb;
}

.example-playlist b {
  background: #8ddcf3;
  color: #fff;
  border-radius: 5px;
  padding: 5px 12px;
  font-size: 11px;
}

.wizard-actions {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid #e5e9f2;
  padding: 25px 20px 32px;
}

body::after {
  content: "Live Help!";
  position: fixed;
  right: 18px;
  bottom: 18px;
  background: #2f96ff;
  color: #fff;
  border-radius: 16px;
  padding: 11px 18px;
  font-weight: 800;
  font-size: 13px;
  box-shadow: 0 8px 20px rgba(47, 150, 255, .25);
  z-index: 70;
}

body::before {
  content: "Help";
  position: fixed;
  left: 12px;
  bottom: 16px;
  background: #43b34f;
  color: #fff;
  border-radius: 18px;
  padding: 8px 18px;
  font-size: 12px;
  z-index: 70;
}

@media (max-width: 1050px) {
  .app-shell { grid-template-columns: 1fr; }
  .upload-options { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tour-card { margin-left: 0; margin-right: 0; padding: 22px; }
}

@media (max-width: 680px) {
  .wizard-hero { margin-left: 0; margin-right: 0; }
  .upload-options { grid-template-columns: 1fr; }
}
