:root {
  --bg: #0a0a0b;
  --panel: #121214;
  --panel-alt: #1a1a1f;
  --border: #34343a;
  --text: #fafafa;
  --muted: #b8b8be;
  --accent: #9f1239;
  --accent-soft: #7f1d1d;
  --silver: #d0d0d4;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: linear-gradient(180deg, #16161a 0%, #0a0a0b 100%);
  color: var(--text);
  font-family: "Segoe UI", sans-serif;
}

.app-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 250px 1fr;
}

.sidebar {
  background: #050505;
  border-right: 1px solid #18181b;
  padding: 18px 14px;
}

.logo-wrap {
  margin-bottom: 22px;
}

.logo {
  width: 100%;
  display: block;
  border-radius: 10px;
}

.sidebar-group {
  display: grid;
  gap: 8px;
}

.sidebar-label {
  color: var(--silver);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin: 8px 2px 4px;
}

.sidebar-btn,
.topbar-btn,
.action-btn {
  border: 1px solid transparent;
  background: #232327;
  color: var(--text);
  padding: 12px 16px;
  border-radius: 10px;
  cursor: pointer;
  font: inherit;
}

.sidebar-btn.is-active,
.topbar-btn.is-active,
.action-btn.is-primary {
  background: var(--accent);
}

.content {
  padding: 36px 40px;
}

.section-kicker {
  color: var(--accent);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
}

.section-title {
  margin: 12px 0;
  font-size: 48px;
}

.section-copy,
.status-text {
  color: var(--muted);
}

.topbar {
  display: flex;
  gap: 12px;
  margin: 26px 0 24px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--silver);
}

.panel {
  background: rgba(18, 18, 20, 0.94);
  border: 1px solid #1f1f25;
  border-radius: 18px;
  padding: 22px;
}

.panel-head,
.editor-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin-top: 18px;
}

.media-card,
.video-row {
  background: var(--panel-alt);
  border: 1px solid var(--border);
  border-radius: 14px;
  overflow: hidden;
}

.media-body,
.video-row {
  padding: 14px;
}

.media-name,
.video-name {
  font-weight: 600;
}

.media-key,
.video-meta,
.media-detail {
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px;
  word-break: break-all;
}

.empty-state {
  padding: 18px;
  border: 1px dashed var(--border);
  border-radius: 14px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.02);
}

.list-grid {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.table-shell {
  overflow: auto;
  margin-top: 18px;
  border: 1px solid var(--border);
  border-radius: 16px;
}

.editor-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 1300px;
}

.editor-table th,
.editor-table td {
  border-bottom: 1px solid #232327;
  padding: 10px;
  vertical-align: top;
}

.editor-table th {
  background: #17171c;
  color: var(--silver);
  text-align: left;
  position: sticky;
  top: 0;
}

.editor-table input,
.editor-table textarea {
  width: 100%;
  border: 1px solid var(--border);
  background: #0e0e11;
  color: var(--text);
  border-radius: 10px;
  padding: 10px 12px;
  font: inherit;
}

.editor-table textarea {
  min-height: 92px;
  resize: vertical;
}

.remove-row-btn {
  background: transparent;
  border: 1px solid var(--accent-soft);
  color: var(--silver);
  border-radius: 10px;
  padding: 10px 12px;
  cursor: pointer;
}

code {
  color: var(--silver);
}

@media (max-width: 1100px) {
  .app-shell {
    grid-template-columns: 1fr;
  }

  .sidebar {
    border-right: 0;
    border-bottom: 1px solid #18181b;
  }
}
