/* Select Series admin — layout modeled on the GS Slowpitch admin, in Select Series black & gold. */

:root {
  --gold: #D4A843;
  --gold-light: #F0D078;
  --gold-ink: #8A6A12;
  --gold-tint: #FBF4E2;
  --gradient-gold: linear-gradient(135deg, #D4A843, #F0D078 50%, #D4A843);
  --black: #0A0A0A;
  --bg: #F6F5F1;
  --card: #FFFFFF;
  --line: #E7E4DC;
  --line-2: #F0EEE8;
  --ink: #141414;
  --ink-2: #4A4A4A;
  --ink-3: #7A7A7A;
  --blue: #2457B8;   --blue-bg: #EAF0FB;
  --amber: #A16207;  --amber-bg: #FDF3DC;
  --green: #15803D;  --green-bg: #E6F4EA;
  --teal: #0F766E;   --teal-bg: #E2F3F1;
  --red: #B42318;    --red-bg: #FDECEA;
  --gray: #5F6368;   --gray-bg: #EFEFEC;
  --purple: #6D3FC0; --purple-bg: #F1EBFB;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(0,0,0,.04), 0 4px 14px rgba(0,0,0,.04);
  --header-h: 52px;
  --sidebar-w: 228px;
  --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --display: 'Oswald', 'Arial Narrow', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body { font-family: var(--font); font-size: 14px; color: var(--ink); background: var(--bg); -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; background: none; border: 0; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.boot { display: grid; place-items: center; height: 100vh; color: var(--ink-3); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
[hidden] { display: none !important; }

/* ── Shell ─────────────────────────────────────────── */
.topbar {
  position: fixed; inset: 0 0 auto 0; height: var(--header-h); z-index: 40;
  display: flex; align-items: center; gap: 12px; padding: 0 18px;
  background: linear-gradient(90deg, #0A0A0A 0%, #1E1A10 70%, #2B2210 100%); color: #fff;
  border-bottom: 1px solid #000;
}
.topbar .brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 15px; }
.topbar .brand img { width: 30px; height: 30px; object-fit: contain; }
.topbar .brand span { color: var(--gold-light); font-family: var(--display); letter-spacing: .5px; text-transform: uppercase; font-weight: 600; }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 14px; font-size: 13px; color: #D9D4C6; }
.topbar .right .sep { width: 1px; height: 16px; background: #4A4430; }
.topbar .right a:hover, .topbar .right button:hover { color: var(--gold-light); }
.topbar .menu-btn { display: none; width: 36px; height: 36px; border-radius: 8px; align-items: center; justify-content: center; }
.topbar .menu-btn svg { width: 22px; height: 22px; }

.sidebar {
  position: fixed; top: var(--header-h); bottom: 0; left: 0; width: var(--sidebar-w); z-index: 30;
  background: #fff; border-right: 1px solid var(--line); padding: 18px 12px 24px; overflow-y: auto;
}
.sidebar .group { font-size: 10.5px; font-weight: 700; letter-spacing: 1.4px; color: var(--ink-3); text-transform: uppercase; padding: 14px 10px 6px; }
.sidebar .group:first-child { padding-top: 0; }
.sidebar a { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; color: var(--ink-2); font-weight: 500; }
.sidebar a svg { width: 17px; height: 17px; color: var(--ink-3); flex-shrink: 0; }
.sidebar a:hover { background: var(--line-2); color: var(--ink); }
.sidebar a.active { background: var(--gold-tint); color: var(--gold-ink); font-weight: 600; }
.sidebar a.active svg { color: var(--gold-ink); }
.sidebar .count { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--black); color: var(--gold-light); font-size: 11px; font-weight: 700; display: grid; place-items: center; }
.sidebar .tag { margin-left: auto; font-size: 10px; font-weight: 600; color: var(--ink-3); border: 1px solid var(--line); border-radius: 999px; padding: 1px 7px; }

.main { margin-left: var(--sidebar-w); padding: calc(var(--header-h) + 26px) 32px 60px; min-height: 100vh; }
.page { max-width: 1240px; margin: 0 auto; }
.scrim { display: none; }

@media (max-width: 900px) {
  .topbar .menu-btn { display: inline-flex; }
  .topbar .right .hide-sm { display: none; }
  .sidebar { transform: translateX(-100%); transition: transform .2s ease; box-shadow: 0 10px 40px rgba(0,0,0,.2); }
  body.nav-open .sidebar { transform: none; }
  body.nav-open .scrim { display: block; position: fixed; inset: var(--header-h) 0 0 0; background: rgba(0,0,0,.3); z-index: 25; }
  .main { margin-left: 0; padding: calc(var(--header-h) + 18px) 16px 48px; }
}

/* ── Page header ───────────────────────────────────── */
.page-head { display: flex; align-items: flex-start; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { font-size: 24px; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.page-head .sub { color: var(--ink-3); margin-top: 3px; }
.page-head .actions { margin-left: auto; display: flex; gap: 8px; flex-wrap: wrap; }
.crumb { display: inline-flex; align-items: center; gap: 4px; color: var(--ink-3); font-weight: 500; margin-bottom: 6px; }
.crumb:hover { color: var(--ink); }
.crumb svg { width: 16px; height: 16px; }
.section-title { font-size: 16px; font-weight: 700; margin: 28px 0 12px; }

/* ── Buttons ───────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; height: 38px; padding: 0 16px; border-radius: 999px; font-weight: 600; font-size: 13.5px; white-space: nowrap; border: 1px solid transparent; transition: background .12s, border-color .12s, color .12s; }
.btn svg { width: 16px; height: 16px; }
.btn-primary { background: var(--black); color: #fff; }
.btn-primary:hover { background: #2A2A2A; }
.btn-gold { background: var(--gradient-gold); color: var(--black); }
.btn-outline { border-color: #D6D2C7; background: #fff; color: var(--ink); }
.btn-outline:hover { border-color: var(--ink); }
.btn-ghost { color: var(--ink-2); }
.btn-ghost:hover { background: var(--line-2); color: var(--ink); }
.btn-danger { background: #fff; border-color: #F1C7C2; color: var(--red); }
.btn-danger:hover { background: var(--red-bg); }
.btn-sm { height: 32px; padding: 0 12px; font-size: 12.5px; }
.btn-icon { width: 32px; height: 32px; padding: 0; border-radius: 8px; border: 1px solid var(--line); background: #fff; display: inline-grid; place-items: center; color: var(--ink-2); }
.btn-icon:hover { border-color: var(--ink-3); color: var(--ink); }
.btn-icon svg { width: 15px; height: 15px; }
.btn[disabled] { opacity: .55; pointer-events: none; }
.btn-block { width: 100%; }

/* ── Cards & stats ─────────────────────────────────── */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card-pad { padding: 20px; }
.card-head { display: flex; align-items: center; gap: 10px; padding: 16px 20px; border-bottom: 1px solid var(--line-2); }
.card-head h2 { font-size: 15px; font-weight: 700; }
.card-head .right { margin-left: auto; }
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; margin-bottom: 18px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; box-shadow: var(--shadow); text-align: left; }
.stat .label { font-size: 12.5px; color: var(--ink-3); font-weight: 500; }
.stat .num { font-size: 28px; font-weight: 800; letter-spacing: -.02em; line-height: 1.15; margin-top: 4px; }
.stat .hint { font-size: 12px; color: var(--ink-3); margin-top: 2px; }
button.stat { cursor: pointer; transition: border-color .12s, box-shadow .12s; }
button.stat:hover { border-color: #CFCABB; }
button.stat.active { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink), var(--shadow); }
.stat.c-blue .num { color: var(--blue); } .stat.c-amber .num { color: var(--amber); } .stat.c-green .num { color: var(--green); }
.stat.c-teal .num { color: var(--teal); } .stat.c-purple .num { color: var(--purple); } .stat.c-red .num { color: var(--red); } .stat.c-gray .num { color: var(--gray); } .stat.c-gold .num { color: var(--gold-ink); }

/* ── Filters ───────────────────────────────────────── */
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 14px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.chips .label { font-size: 11px; font-weight: 700; letter-spacing: 1px; color: var(--ink-3); text-transform: uppercase; margin-right: 4px; }
.chip { height: 30px; padding: 0 12px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.chip:hover { border-color: #CFCABB; color: var(--ink); }
.chip.active { background: var(--black); border-color: var(--black); color: #fff; }
.search { position: relative; flex: 1; min-width: 200px; max-width: 360px; }
.search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; color: var(--ink-3); }
.search input { width: 100%; height: 38px; border-radius: 999px; border: 1px solid var(--line); background: #fff; padding: 0 14px 0 36px; }
.select { height: 38px; border-radius: 999px; border: 1px solid var(--line); background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center; padding: 0 32px 0 14px; appearance: none; font-weight: 500; max-width: 240px; }
.result-count { color: var(--ink-3); font-size: 12.5px; margin-left: auto; }

/* ── Table ─────────────────────────────────────────── */
.table-wrap { overflow-x: auto; }
table.table { width: 100%; border-collapse: collapse; }
.table th { text-align: left; font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--ink-3); padding: 12px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; background: #FCFBF8; }
.table td { padding: 12px 14px; border-bottom: 1px solid var(--line-2); vertical-align: middle; }
.table tr:last-child td { border-bottom: 0; }
.table tbody tr { transition: background .1s; }
.table tbody tr.clickable { cursor: pointer; }
.table tbody tr:hover { background: #FCFBF7; }
.table tbody tr.selected { background: var(--gold-tint); }
.table .name { font-weight: 600; }
.table .muted, .muted { color: var(--ink-3); font-size: 12.5px; }
.table input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--black); }
.table .row-actions { display: flex; gap: 6px; justify-content: flex-end; }
.cell-stack { display: flex; flex-direction: column; gap: 1px; }

/* ── Badges ────────────────────────────────────────── */
.badge { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 9px; border-radius: 999px; font-size: 11.5px; font-weight: 600; white-space: nowrap; }
.badge::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: currentColor; opacity: .8; }
.badge.plain::before { display: none; }
.b-blue { background: var(--blue-bg); color: var(--blue); } .b-amber { background: var(--amber-bg); color: var(--amber); }
.b-green { background: var(--green-bg); color: var(--green); } .b-teal { background: var(--teal-bg); color: var(--teal); }
.b-red { background: var(--red-bg); color: var(--red); } .b-gray { background: var(--gray-bg); color: var(--gray); }
.b-gold { background: var(--gold-tint); color: var(--gold-ink); } .b-purple { background: var(--purple-bg); color: var(--purple); } .b-dark { background: var(--black); color: var(--gold-light); }

/* ── Bulk bar ──────────────────────────────────────── */
.bulkbar { position: sticky; bottom: 16px; z-index: 20; display: flex; align-items: center; gap: 10px; margin-top: 14px; padding: 10px 12px 10px 18px; border-radius: 999px; background: var(--black); color: #fff; box-shadow: 0 12px 30px rgba(0,0,0,.25); flex-wrap: wrap; }
.bulkbar .select { background-color: #1E1E1E; border-color: #333; color: #fff; }
.bulkbar .btn-outline { background: transparent; color: #fff; border-color: #444; }

/* ── Dropdown menu ─────────────────────────────────── */
.menu { position: absolute; z-index: 60; min-width: 200px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 14px 40px rgba(0,0,0,.14); padding: 6px; }
.menu button, .menu a { display: flex; width: 100%; align-items: center; gap: 9px; padding: 8px 10px; border-radius: 8px; text-align: left; color: var(--ink-2); font-weight: 500; }
.menu button:hover, .menu a:hover { background: var(--line-2); color: var(--ink); }
.menu .danger { color: var(--red); }
.menu hr { border: 0; border-top: 1px solid var(--line-2); margin: 5px 0; }
.menu svg { width: 15px; height: 15px; }

/* ── Drawer & modal ────────────────────────────────── */
.overlay { position: fixed; inset: 0; background: rgba(10,10,10,.35); z-index: 70; animation: fade .15s ease; }
@keyframes fade { from { opacity: 0; } }
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(560px, 100%); z-index: 71; background: var(--bg); box-shadow: -20px 0 50px rgba(0,0,0,.18); display: flex; flex-direction: column; animation: slide .2s ease; }
@keyframes slide { from { transform: translateX(30px); opacity: .6; } }
.drawer-head { display: flex; gap: 12px; align-items: flex-start; padding: 18px 20px; background: #fff; border-bottom: 1px solid var(--line); }
.drawer-head h2 { font-size: 19px; font-weight: 800; }
.drawer-head .close { margin-left: auto; }
.drawer-body { flex: 1; overflow-y: auto; padding: 18px 20px 24px; display: grid; gap: 14px; align-content: start; grid-auto-rows: max-content; }
.drawer-foot { display: flex; gap: 10px; padding: 14px 20px; background: #fff; border-top: 1px solid var(--line); }
.drawer-foot .btn { flex: 1; }
.modal { position: fixed; z-index: 71; top: 50%; left: 50%; transform: translate(-50%, -50%); width: min(var(--w, 520px), calc(100% - 24px)); max-height: calc(100vh - 40px); display: flex; flex-direction: column; background: #fff; border-radius: 18px; box-shadow: 0 30px 70px rgba(0,0,0,.25); animation: pop .15s ease; }
@keyframes pop { from { transform: translate(-50%, -48%); opacity: 0; } }
.modal-head { padding: 18px 22px 6px; }
.modal-head h2 { font-size: 18px; font-weight: 800; }
.modal-head p { color: var(--ink-3); margin-top: 4px; }
.modal-body { padding: 14px 22px; overflow-y: auto; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 14px 22px 18px; }

/* ── Collapsible form sections (GS style) ──────────── */
.acc { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.acc > summary { list-style: none; display: flex; align-items: center; gap: 10px; padding: 14px 16px; cursor: pointer; }
.acc > summary::-webkit-details-marker { display: none; }
.acc > summary strong { display: block; font-size: 14px; }
.acc > summary small { display: block; color: var(--ink-3); font-size: 12px; font-weight: 400; margin-top: 1px; }
.acc > summary .chev { margin-left: auto; width: 18px; height: 18px; color: var(--ink-3); transition: transform .15s; }
.acc[open] > summary .chev { transform: rotate(180deg); }
.acc .acc-body { padding: 4px 16px 16px; }

/* ── Forms ─────────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.field { display: grid; gap: 5px; }
.field.full { grid-column: 1 / -1; }
.field label { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.field .help { font-size: 12px; color: var(--ink-3); }
.input, .field input:not([type=checkbox]), .field select, .field textarea {
  width: 100%; height: 40px; padding: 0 12px; border-radius: 10px; border: 1px solid #DAD6CB; background: #fff;
}
.field textarea { height: auto; min-height: 84px; padding: 10px 12px; resize: vertical; }
.field select { appearance: none; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='3'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center; padding-right: 32px; }
.field input:focus, .field select:focus, .field textarea:focus, .input:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 3px rgba(212,168,67,.2); }
.check { display: flex; align-items: center; gap: 9px; font-weight: 500; }
.check input { width: 16px; height: 16px; accent-color: var(--black); }
.error-text { color: var(--red); font-size: 13px; }

/* ── Misc ──────────────────────────────────────────── */
.empty { text-align: center; padding: 48px 20px; color: var(--ink-3); }
.empty .icon { width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto 12px; background: var(--line-2); color: var(--ink-3); }
.empty .icon svg { width: 24px; height: 24px; }
.notice { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; border-color: #EBD9A6; background: var(--gold-tint); }
.notice svg { width: 20px; height: 20px; color: var(--gold-ink); flex-shrink: 0; }
.empty h3 { color: var(--ink); font-size: 15px; margin-bottom: 4px; }
.empty .btn { margin-top: 14px; }
.timeline { list-style: none; display: grid; gap: 0; }
.timeline li { position: relative; padding: 0 0 14px 22px; }
.timeline li::before { content: ''; position: absolute; left: 5px; top: 6px; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.timeline li::after { content: ''; position: absolute; left: 8.5px; top: 16px; bottom: 0; width: 1px; background: var(--line); }
.timeline li:last-child::after { display: none; }
.timeline .when { color: var(--ink-3); font-size: 12px; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 8px 12px; font-size: 13px; }
.kv dt { color: var(--ink-3); }
.kv dd { font-weight: 500; word-break: break-word; }
.funnel { display: grid; gap: 10px; }
.funnel-row { display: grid; grid-template-columns: 110px 1fr 44px; align-items: center; gap: 12px; font-size: 13px; }
.funnel-bar { height: 10px; border-radius: 999px; background: var(--line-2); overflow: hidden; }
.funnel-bar span { display: block; height: 100%; border-radius: 999px; }
.funnel-row strong { text-align: right; }
.quick { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.quick a, .quick button { display: flex; align-items: center; justify-content: center; gap: 8px; height: 46px; border-radius: 999px; background: #fff; border: 1px solid var(--line); font-weight: 600; color: var(--ink); box-shadow: var(--shadow); }
.quick a:hover, .quick button:hover { border-color: var(--ink); }
.quick svg { width: 16px; height: 16px; color: var(--gold-ink); }
.two-col { display: grid; grid-template-columns: 1.4fr 1fr; gap: 16px; align-items: start; }
.activity { list-style: none; }
.activity li { display: flex; gap: 10px; padding: 10px 20px; border-bottom: 1px solid var(--line-2); font-size: 13px; }
.activity li:last-child { border-bottom: 0; }
.activity .when { margin-left: auto; color: var(--ink-3); font-size: 12px; white-space: nowrap; }
.nom-card { padding: 18px 20px; border-bottom: 1px solid var(--line-2); display: grid; grid-template-columns: 1fr auto; gap: 8px 16px; }
.nom-card:last-child { border-bottom: 0; }
.nom-card .reason { grid-column: 1 / -1; background: #FCFBF8; border: 1px solid var(--line-2); border-radius: 10px; padding: 10px 12px; color: var(--ink-2); white-space: pre-wrap; }
.mvp-rows { display: grid; gap: 8px; }
.mvp-row { display: grid; grid-template-columns: 90px 1fr 1fr 1.2fr 34px; gap: 8px; align-items: center; }
.mvp-row .div-label { font-weight: 700; font-family: var(--display); font-size: 15px; letter-spacing: .5px; }
.copy-row { display: flex; gap: 8px; }
.copy-row input { flex: 1; height: 38px; border-radius: 10px; border: 1px solid var(--line); padding: 0 12px; background: #FCFBF8; color: var(--ink-2); font-size: 12.5px; }


/* ── Segmented control ─────────────────────────────── */
.segmented { display: inline-flex; padding: 4px; gap: 2px; background: #fff; border: 1px solid var(--line); border-radius: 999px; flex-wrap: wrap; }
.segmented button { height: 32px; padding: 0 16px; border-radius: 999px; font-weight: 600; font-size: 13px; color: var(--ink-2); }
.segmented button[aria-selected="true"] { background: var(--black); color: #fff; }

/* ── Edit forms ────────────────────────────────────── */
.edit-form { display: grid; gap: 14px; max-width: 980px; }
.save-bar { position: sticky; bottom: 0; z-index: 15; display: flex; gap: 10px; align-items: center; padding: 14px 16px; margin: 6px -16px 0; background: rgba(246,245,241,.94); backdrop-filter: blur(6px); border-top: 1px solid var(--line); }
.repeat { display: grid; gap: 8px; margin-bottom: 8px; }
.repeat-row { display: grid; grid-template-columns: 1fr 1.4fr auto auto; gap: 8px; align-items: center; }
#hotels .repeat-row { grid-template-columns: 1.4fr 1fr 1fr auto; }
.repeat-row .btn-icon[data-act="row-up"] svg { transform: rotate(180deg); }
.toggle-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.toggle-chips label { cursor: pointer; }
.toggle-chips input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-chips span { display: inline-flex; align-items: center; height: 32px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: #fff; font-weight: 600; font-size: 13px; color: var(--ink-2); }
.toggle-chips input:checked + span { background: var(--black); border-color: var(--black); color: var(--gold-light); }
.toggle-chips input:focus-visible + span { outline: 2px solid var(--gold); }
.person { display: grid; gap: 8px; padding: 14px; border: 1px solid var(--line-2); border-radius: 12px; background: #FCFBF8; }

/* ── Image fields & media ──────────────────────────── */
.image-row { display: flex; gap: 12px; align-items: stretch; }
.image-preview { width: 150px; height: 96px; border-radius: 10px; border: 1px solid var(--line); background: #FCFBF8; display: grid; place-items: center; overflow: hidden; flex-shrink: 0; }
.image-preview.dark { background: #000; border-color: #000; }
.image-preview img { width: 100%; height: 100%; object-fit: contain; }
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; max-height: 60vh; overflow-y: auto; padding: 2px; }
.media-tile { display: grid; gap: 6px; padding: 6px; border-radius: 12px; border: 1px solid var(--line); background: #fff; text-align: left; }
.media-tile:hover { border-color: var(--ink); }
.media-tile .thumb { aspect-ratio: 4 / 3; border-radius: 8px; background: #F1EFE8 center / 16px 16px; background-image: linear-gradient(45deg, #E9E6DD 25%, transparent 25%, transparent 75%, #E9E6DD 75%), linear-gradient(45deg, #E9E6DD 25%, transparent 25%, transparent 75%, #E9E6DD 75%); background-position: 0 0, 8px 8px; overflow: hidden; display: grid; place-items: center; }
.media-tile img { width: 100%; height: 100%; object-fit: contain; }
.media-tile .name { font-size: 11.5px; color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dropzone { display: flex; gap: 14px; align-items: center; padding: 18px 20px; margin-bottom: 16px; border: 2px dashed #D6D2C7; border-radius: var(--radius); background: #fff; color: var(--ink-2); }
.dropzone svg { width: 22px; height: 22px; color: var(--gold-ink); }
.dropzone.over { border-color: var(--gold); background: var(--gold-tint); }
.media-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.media-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.media-card .thumb { aspect-ratio: 16 / 10; background: #111; display: grid; place-items: center; }
.media-card .thumb img { width: 100%; height: 100%; object-fit: contain; }
.media-card .thumb svg { width: 32px; height: 32px; color: var(--gold); }
.media-card .meta { padding: 12px 14px 8px; display: grid; gap: 4px; }
.media-card .meta strong { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.media-card .meta .badge { justify-self: start; }
.media-card .actions { display: flex; gap: 8px; padding: 0 14px 14px; margin-top: auto; }
.thumb-sm { width: 44px; height: 44px; border-radius: 10px; background: var(--line-2); display: grid; place-items: center; overflow: hidden; flex-shrink: 0; font-size: 20px; }
.thumb-sm img { width: 100%; height: 100%; object-fit: cover; }

/* ── Event cards ───────────────────────────────────── */
.ev-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 16px; }
.ev-card { position: relative; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column; }
.ev-card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--gradient-gold); z-index: 1; }
.ev-logo { aspect-ratio: 4 / 3; background: #000; display: grid; place-items: center; color: var(--gold); font-family: var(--display); font-size: 18px; text-transform: uppercase; text-align: center; padding: 10px; }
.ev-logo img { width: 100%; height: 100%; object-fit: contain; padding: 4%; }
.ev-body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 2px; flex: 1; }
.ev-name { font-weight: 700; font-size: 15px; line-height: 1.3; }
.ev-name:hover { color: var(--gold-ink); }
.ev-body .muted { display: flex; gap: 6px; align-items: center; }
.ic { width: 13px; height: 13px; flex-shrink: 0; }
.ev-warn { margin-top: 8px; font-size: 12px; color: var(--amber); background: var(--amber-bg); border-radius: 8px; padding: 6px 9px; }
.ev-actions { display: flex; gap: 6px; margin-top: auto; padding-top: 14px; }
.ev-actions .btn-primary { flex: 1; }

/* ── Messages ──────────────────────────────────────── */
.msg { border-bottom: 1px solid var(--line-2); }
.msg:last-child { border-bottom: 0; }
.msg-head { width: 100%; display: grid; grid-template-columns: 10px 220px 1fr auto; gap: 14px; align-items: center; padding: 14px 20px; text-align: left; }
.msg-head:hover { background: #FCFBF7; }
.msg .dot { width: 8px; height: 8px; border-radius: 50%; background: transparent; }
.msg.unread .dot { background: var(--gold); }
.msg.unread .who strong, .msg.unread .subj { font-weight: 700; }
.msg .who { display: grid; overflow: hidden; }
.msg .who span, .msg .subj { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg .when { white-space: nowrap; }
.msg-body { padding: 4px 20px 20px 44px; color: var(--ink-2); }
.msg.open { background: #FCFBF7; }

/* ── Navigation editor ─────────────────────────────── */
.nav-row { display: grid; grid-template-columns: 34px 1fr 1.4fr 150px 34px; gap: 8px; align-items: center; margin-bottom: 8px; }
.nav-head { font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--ink-3); }
.nav-move .btn-icon svg { transform: rotate(180deg); }
.btn-icon[disabled] { opacity: .35; pointer-events: none; }
.avatar-sm { width: 32px; height: 32px; border-radius: 50%; background: var(--black); color: var(--gold-light); display: grid; place-items: center; font-size: 12px; font-weight: 700; flex-shrink: 0; }

@media (max-width: 700px) {
  .repeat-row, #hotels .repeat-row { grid-template-columns: 1fr auto; }
  .repeat-row input { grid-column: 1; }
  .msg-head { grid-template-columns: 10px 1fr auto; }
  .msg-head .subj { grid-column: 2 / -1; }
  .nav-row { grid-template-columns: 1fr 1fr 34px; }
  .nav-row .nav-move, .nav-head { display: none; }
  .image-row { flex-direction: column; }
  .image-preview { width: 100%; height: 140px; }
}

/* ── Pipeline board ────────────────────────────────── */
.board { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 1fr); gap: 12px; overflow-x: auto; padding-bottom: 8px; align-items: start; }
.board-col { background: #EFEDE6; border-radius: var(--radius); padding: 10px; min-height: 200px; transition: background .12s, box-shadow .12s; }
.board-col.over { background: var(--gold-tint); box-shadow: inset 0 0 0 2px var(--gold); }
.board-col header { display: flex; align-items: center; justify-content: space-between; padding: 2px 4px 10px; }
.board-cards { display: grid; gap: 8px; }
.board-card { background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 12px; box-shadow: var(--shadow); cursor: grab; display: grid; gap: 3px; }
.board-card:hover { border-color: #CFCABB; }
.board-card.dragging { opacity: .5; }
.board-card .bc-top { display: flex; justify-content: space-between; gap: 8px; align-items: center; }
.board-card .bc-earned { font-size: 12px; }
.board-card .badge { justify-self: start; margin-top: 4px; }
.board-empty { border: 2px dashed #D9D5CA; border-radius: 12px; padding: 18px; text-align: center; color: var(--ink-3); font-size: 12.5px; }
.segmented .ic { width: 14px; height: 14px; vertical-align: -2px; }

/* ── Stage editor ──────────────────────────────────── */
.stage-row { display: grid; grid-template-columns: 34px 1.6fr 120px 150px 110px 34px; gap: 10px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--line-2); }
.stage-head { font-size: 11px; font-weight: 700; letter-spacing: .8px; text-transform: uppercase; color: var(--ink-3); background: #FCFBF8; border-radius: var(--radius) var(--radius) 0 0; }
.stage-row .btn-icon[data-act="up"] svg { transform: rotate(180deg); }
.stage-row select:disabled { background: #F6F5F1; color: var(--ink-3); }
.swatch { width: 14px; height: 14px; border-radius: 50%; flex-shrink: 0; }
@media (max-width: 760px) {
  .stage-row { grid-template-columns: 34px 1fr 34px; }
  .stage-row > :nth-child(3), .stage-row > :nth-child(4), .stage-row > :nth-child(5) { grid-column: 2; }
  .stage-head { display: none; }
}

/* ── Toast ─────────────────────────────────────────── */
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); z-index: 90; display: grid; gap: 8px; }
.toast { background: var(--black); color: #fff; padding: 11px 16px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.25); font-weight: 500; display: flex; gap: 8px; align-items: center; animation: pop2 .2s ease; }
.toast.error { background: var(--red); }
.toast svg { width: 16px; height: 16px; color: var(--gold-light); }
@keyframes pop2 { from { transform: translateY(8px); opacity: 0; } }

/* ── Login ─────────────────────────────────────────── */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; background: radial-gradient(ellipse at top, #2B2210 0%, #0A0A0A 60%); }
.login-card { width: min(400px, 100%); background: #fff; border-radius: 20px; padding: 32px 28px; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.login-card .logo { width: 64px; height: 64px; margin: 0 auto 12px; display: block; object-fit: contain; }
.login-card h1 { text-align: center; font-size: 22px; font-weight: 800; }
.login-card p.sub { text-align: center; color: var(--ink-3); margin: 4px 0 22px; }
.login-card form { display: grid; gap: 14px; }

@media (max-width: 900px) {
  .two-col, .grid-3 { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .grid-2 { grid-template-columns: 1fr; }
  .page-head .actions { margin-left: 0; width: 100%; }
  .mvp-row { grid-template-columns: 1fr 1fr; }
  .mvp-row .div-label { grid-column: 1 / -1; }
  .stats { grid-template-columns: 1fr 1fr; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dd { margin-bottom: 8px; }
}
