/* =========================================================
   PRINTS CORE — admin panel (layers on top of style.css tokens)
   ========================================================= */

.admin-body { padding-top: 0; }

/* ---------- Top bar ---------- */
.admin-bar {
  position: sticky;
  top: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 26px;
  background: rgba(12, 12, 13, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.admin-bar .brand .brand-mark { height: 24px; width: auto; }
.admin-bar .tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mini-btn {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 9px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--surface);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-dim);
  transition: border-color 0.2s var(--ease), color 0.2s var(--ease), transform 0.2s var(--ease);
}
.mini-btn[hidden] { display: none; }
.mini-btn svg { width: 15px; height: 15px; }
.mini-btn:hover { color: var(--text); border-color: var(--border-strong); transform: translateY(-1px); }
.mini-btn.danger:hover { border-color: var(--accent-3); color: var(--accent-3); }
.mini-btn.solid { background: linear-gradient(120deg, var(--accent), var(--accent-2)); color: #04120f; border: 0; }

/* ---------- Layout ---------- */
.admin-wrap { max-width: 1240px; margin: 0 auto; padding: 34px 26px 80px; }
.admin-wrap h1 { font-size: 1.9rem; margin-bottom: 6px; }
.admin-wrap .sub { color: var(--text-mute); font-size: 0.9rem; margin-bottom: 30px; }

.kpi-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 30px;
}
.kpi {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 18px 20px;
  background: var(--bg-elev);
}
.kpi .k-label { font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-mute); margin-bottom: 8px; }
.kpi .k-value { font-size: 1.7rem; font-weight: 700; letter-spacing: -0.02em; }
.kpi .k-value .cur { font-size: 0.9rem; color: var(--text-mute); margin-right: 2px; }

/* ---------- Toolbar ---------- */
.admin-toolbar {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 18px;
}
.admin-toolbar .search {
  flex: 1;
  min-width: 200px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
}
.admin-toolbar .search:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.status-filter { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Table ---------- */
.orders-table {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-elev);
}
.otr {
  display: grid;
  grid-template-columns: 1.1fr 1fr 1.6fr 0.7fr 0.9fr 1.1fr;
  gap: 14px;
  align-items: center;
  padding: 15px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem;
}
.otr:last-child { border-bottom: 0; }
.otr.head {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-mute);
  background: var(--surface);
}
.otr.row { cursor: pointer; transition: background 0.18s var(--ease); }
.otr.row:hover { background: var(--surface); }
.otr .oid { font-weight: 700; letter-spacing: 0.03em; }
.otr .ocust { color: var(--text-dim); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.otr .ototal { font-weight: 700; }
.orders-empty { padding: 60px 20px; text-align: center; color: var(--text-mute); }
.otr.row.dim { opacity: 0.5; }

.pay-tag {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 2px 6px;
  border: 1px solid currentColor;
  vertical-align: middle;
}
.pay-tag.unpaid   { color: hsl(40, 80%, 60%); }
.pay-tag.refunded { color: hsl(0, 70%, 62%); }
.pay-tag.paid     { color: hsl(140, 55%, 58%); }
.pay-box { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 6px; }
.pay-box .pay-tag { font-size: 0.72rem; padding: 5px 10px; }

/* ---------- Detail drawer ---------- */
.admin-scrim {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(3px);
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s var(--ease);
  z-index: 200;
}
.admin-scrim.open { opacity: 1; pointer-events: auto; }
.admin-drawer {
  position: fixed; top: 0; right: 0;
  height: 100%;
  width: min(560px, 100vw);
  background: var(--bg-elev);
  border-left: 1px solid var(--border);
  transform: translateX(100%);
  transition: transform 0.38s var(--ease);
  z-index: 201;
  display: flex; flex-direction: column;
}
.admin-drawer.open { transform: translateX(0); }
.ad-head {
  display: flex; align-items: flex-start; justify-content: space-between;
  padding: 22px 26px;
  border-bottom: 1px solid var(--border);
}
.ad-head .oid-lg { font-size: 1.3rem; font-weight: 700; letter-spacing: 0.03em; }
.ad-head .when { color: var(--text-mute); font-size: 0.82rem; margin-top: 4px; }
.ad-body { flex: 1; overflow-y: auto; padding: 24px 26px; }
.ad-body h4 {
  font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--text-mute); margin: 26px 0 12px;
}
.ad-body h4:first-child { margin-top: 0; }

.status-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.status-opt {
  padding: 10px;
  border-radius: 9px;
  border: 1px solid var(--border);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-dim);
  text-align: center;
  transition: all 0.18s var(--ease);
}
.status-opt:hover { border-color: var(--border-strong); color: var(--text); }
.status-opt.active {
  border-color: hsl(var(--h), 80%, 55%);
  background: hsla(var(--h), 80%, 55%, 0.14);
  color: hsl(var(--h), 80%, 75%);
}

.ad-field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 12px; }
.ad-field.two { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ad-field label { font-size: 0.78rem; color: var(--text-mute); }
.ad-field input, .ad-field textarea, .ad-field select {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 9px;
  padding: 10px 12px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.88rem;
}
.ad-field input:focus, .ad-field textarea:focus, .ad-field select:focus {
  outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft);
}
.ad-grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.ad-items { border: 1px solid var(--border); border-radius: 10px; overflow: hidden; }
.ad-items .li {
  display: flex; justify-content: space-between; gap: 10px;
  padding: 11px 14px; font-size: 0.86rem;
  border-bottom: 1px solid var(--border);
}
.ad-items .li:last-child { border-bottom: 0; }
.ad-items .li.tot { font-weight: 700; background: var(--surface); }

.timeline { border-left: 2px solid var(--border); padding-left: 16px; }
.timeline .tl { position: relative; padding-bottom: 14px; font-size: 0.84rem; color: var(--text-dim); }
.timeline .tl::before {
  content: ""; position: absolute; left: -21px; top: 5px;
  width: 8px; height: 8px; border-radius: 50%; background: var(--accent);
}
.timeline .tl .t { color: var(--text-mute); font-size: 0.76rem; }

.ad-foot {
  display: flex; gap: 10px;
  padding: 18px 26px;
  border-top: 1px solid var(--border);
}
.ad-foot .btn { flex: 1; justify-content: center; }

/* ---------- Lock screen ---------- */
.lock {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}
.lock-card {
  width: min(400px, 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-elev);
  padding: 40px 34px;
  text-align: center;
  box-shadow: var(--shadow);
}
.lock-card .mark {
  width: 48px; height: 48px; margin: 0 auto 20px;
  display: grid; place-items: center;
  border: 1px solid var(--acid);
  color: var(--acid);
}
.lock-card .mark svg { width: 24px; height: 24px; }
.lock-card h1 { font-size: 1.4rem; margin-bottom: 8px; }
.lock-card p { color: var(--text-mute); font-size: 0.88rem; margin-bottom: 22px; }
.lock-card input {
  width: 100%;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 12px 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 0.95rem;
  text-align: center;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
}
.lock-card input:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.lock-card .btn { width: 100%; justify-content: center; }
.lock-card .err { color: var(--accent-3); font-size: 0.82rem; margin-bottom: 12px; min-height: 1em; }
.lock-card .hint { margin-top: 16px; font-size: 0.76rem; color: var(--text-mute); }

/* =========================================================
   SHELL · SIDEBAR · VIEWS
   ========================================================= */
.mini-btn { border-radius: var(--radius); font-family: var(--font-mono); font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; }
.mini-btn.solid { background: var(--acid); color: #0c0c0d; }
.admin-tag { color: var(--text-mute); font-weight: 500; font-family: var(--font-mono); font-size: 0.8rem; }
.admin-nav-toggle { display: none; }

.admin-shell { display: flex; align-items: flex-start; max-width: 1340px; margin: 0 auto; }

.admin-side {
  position: sticky;
  top: 57px;
  width: 210px;
  flex: 0 0 210px;
  padding: 22px 14px;
  border-right: 1px solid var(--border);
  min-height: calc(100vh - 57px);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.side-link {
  display: flex; align-items: center; gap: 11px;
  width: 100%;
  padding: 11px 12px;
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: 0.76rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
  transition: background 0.18s var(--ease), color 0.18s var(--ease);
}
.side-link svg { width: 16px; height: 16px; flex: none; }
.side-link:hover { color: var(--text); background: var(--surface); }
.side-link.active { color: #0c0c0d; background: var(--acid); }
.side-badge {
  margin-left: auto;
  font-size: 0.66rem;
  background: rgba(0,0,0,0.18);
  padding: 1px 6px;
  border-radius: 999px;
}
.side-link:not(.active) .side-badge { background: var(--surface-2); color: var(--text-mute); }
.side-foot { margin-top: auto; padding: 14px 12px 0; }
.side-foot p { font-size: 0.68rem; color: var(--text-mute); line-height: 1.5; }

.admin-main { flex: 1; min-width: 0; padding: 26px 30px 100px; }
.admin-view { display: none; }
.admin-view.active { display: block; }

.view-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.view-head h1 { font-family: var(--font-display); font-size: 2rem; font-weight: 800; text-transform: uppercase; letter-spacing: -0.02em; }
.view-head .sub { color: var(--text-mute); font-size: 0.86rem; margin-top: 4px; }
.admin-main > .admin-view > .sub { color: var(--text-mute); font-size: 0.84rem; margin: -14px 0 22px; }
.view-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ---------- Dashboard ---------- */
.dash-cols { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }
.panel { border: 1px solid var(--border); background: var(--bg-elev); padding: 20px; }
.panel h3 { font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.1em; margin-bottom: 16px; }
.panel .muted { color: var(--text-mute); font-weight: 400; }
.empty-hint { color: var(--text-mute); font-size: 0.84rem; padding: 8px 0; }

.sbar { display: grid; grid-template-columns: 74px 1fr 28px; gap: 10px; align-items: center; margin-bottom: 9px; font-size: 0.78rem; }
.sbar-label { color: var(--text-dim); }
.sbar-track { height: 7px; background: var(--surface-2); overflow: hidden; }
.sbar-fill { display: block; height: 100%; background: hsl(var(--h), 65%, 55%); min-width: 2px; transition: width 0.5s var(--ease); }
.sbar-count { text-align: right; font-family: var(--font-mono); color: var(--text-mute); }

.mini-list { display: flex; flex-direction: column; }
.mrow { display: flex; align-items: center; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--border); text-align: left; width: 100%; }
.mrow:last-child { border-bottom: 0; }
.mrow.static { cursor: default; }
.mrow:not(.static):hover .mrow-main strong { color: var(--acid); }
.mrow-main { display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0; font-size: 0.84rem; }
.mrow-main .muted, .mini-list .muted { color: var(--text-mute); font-size: 0.76rem; }
.mrow-main strong { font-weight: 600; transition: color 0.15s var(--ease); }
.mrow-val { font-family: var(--font-mono); font-size: 0.8rem; color: var(--text-dim); }
.mrow .dot { width: 8px; height: 8px; border-radius: 50%; flex: none; }

/* ---------- Products table ---------- */
.products-table { border: 1px solid var(--border); background: var(--bg-elev); }
.ptr {
  display: grid;
  grid-template-columns: 56px 1fr 130px 90px 80px;
  gap: 14px;
  align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 0.86rem;
}
.ptr:last-child { border-bottom: 0; }
.ptr.head { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--text-mute); background: var(--surface); }
.ptr.row { cursor: pointer; transition: background 0.16s var(--ease); }
.ptr.row:hover { background: var(--surface); }
.pthumb {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  background: linear-gradient(150deg, hsla(var(--hue), 22%, 20%, 1), hsla(var(--hue), 14%, 11%, 1));
}
.pthumb svg { width: 60%; color: var(--text-dim); }
.pname { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pname strong { font-weight: 600; }
.pname .muted { color: var(--text-mute); font-size: 0.76rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pcat { color: var(--text-dim); font-family: var(--font-mono); font-size: 0.74rem; }
.pprice { font-family: var(--font-display); font-weight: 800; }
.prow-actions { display: flex; gap: 6px; justify-content: flex-end; }
.icon-btn {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-dim);
  transition: border-color 0.16s var(--ease), color 0.16s var(--ease);
}
.icon-btn svg { width: 14px; height: 14px; }
.icon-btn:hover { border-color: var(--acid); color: var(--text); }
.icon-btn.danger:hover { border-color: var(--accent-3); color: var(--accent-3); }

/* ---------- Product editor ---------- */
.prod-preview {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 7;
  border: 1px solid var(--border);
  margin-bottom: 14px;
  background: linear-gradient(150deg, hsla(var(--hue), 22%, 18%, 1), hsla(var(--hue), 14%, 10%, 1));
  overflow: hidden;
}
.prod-preview-img { width: 100%; height: 100%; display: grid; place-items: center; }
.prod-preview-img img, .prod-preview-img video { width: 100%; height: 100%; object-fit: contain; display: block; }
.prod-preview-img svg { width: 90px; color: var(--text-dim); }
.video-trim { border: 1px solid var(--border); padding: 12px; margin: 10px 0 18px; display: grid; gap: 10px; }
.video-trim[hidden] { display: none; }
.video-trim > strong { font-size: 0.82rem; }
.video-trim .input-row input { min-width: 0; }

.preview-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 38px; height: 38px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: rgba(0, 0, 0, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  transition: background 0.2s, border-color 0.2s;
}
.preview-nav svg { width: 18px; height: 18px; }
.preview-nav:hover { background: var(--acid); border-color: transparent; color: #0c0c0d; }
.preview-nav.prev { left: 10px; }
.preview-nav.next { right: 10px; }
.preview-nav[hidden] { display: none; }

.photo-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 4px; }
.photo-toolbar .muted { font-family: var(--font-mono); font-size: 0.74rem; }
.photo-toolbar-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.photo-add {
  aspect-ratio: 1;
  display: flex; align-items: center; justify-content: center;
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius);
  color: var(--text-mute);
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.photo-add svg { width: 22px; height: 22px; }
.photo-add:hover { border-color: var(--acid); color: var(--acid); }

.icon-picker { display: grid; grid-template-columns: repeat(6, 1fr); gap: 6px; }
.icon-opt {
  aspect-ratio: 1;
  display: grid; place-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-mute);
  transition: border-color 0.14s var(--ease), color 0.14s var(--ease);
}
.icon-opt svg { width: 62%; }
.icon-opt:hover { color: var(--text-dim); border-color: var(--border-strong); }
.icon-opt.active { border-color: var(--acid); color: var(--acid); background: var(--accent-soft); }

.hue-slider { -webkit-appearance: none; appearance: none; width: 100%; height: 10px; border-radius: 999px; outline: none;
  background: linear-gradient(90deg, hsl(0 70% 55%), hsl(60 70% 55%), hsl(120 70% 55%), hsl(180 70% 55%), hsl(240 70% 55%), hsl(300 70% 55%), hsl(360 70% 55%)); }
.hue-slider::-webkit-slider-thumb { -webkit-appearance: none; width: 18px; height: 18px; border-radius: 50%; background: #fff; border: 2px solid #0c0c0d; cursor: pointer; }
.hue-slider::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 2px solid #0c0c0d; cursor: pointer; }

.spec-row { display: grid; grid-template-columns: 1fr 1.2fr 30px; gap: 8px; margin-bottom: 8px; }
.spec-row input {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 9px 11px; color: var(--text); font-family: inherit; font-size: 0.85rem;
}
.spec-row input:focus { outline: none; border-color: var(--acid); }

/* ---------- Settings ---------- */
.settings-form { max-width: 560px; }
.settings-form h3 { font-family: var(--font-mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-mute); margin: 26px 0 12px; }
.settings-form h3:first-child { margin-top: 0; }
.settings-form .muted { color: var(--text-mute); text-transform: none; letter-spacing: 0; }
.settings-form textarea {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 11px 13px; color: var(--text); font-family: var(--font-mono); font-size: 0.85rem; width: 100%; resize: vertical;
}
.settings-form textarea:focus { outline: none; border-color: var(--acid); }
.settings-foot { display: flex; gap: 10px; align-items: center; margin-top: 22px; flex-wrap: wrap; }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 1080px) {
  .dash-cols { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .kpi-row { grid-template-columns: 1fr 1fr; }
  .otr { grid-template-columns: 1fr 1fr; row-gap: 6px; }
  .otr.head { display: none; }
  .otr .odate, .otr .oitems { display: none; }

  .admin-nav-toggle { display: grid; place-items: center; }
  .admin-side {
    position: fixed;
    top: 0; left: 0; bottom: 0;
    z-index: 120;
    width: 260px; flex-basis: 260px;
    background: var(--bg-elev);
    transform: translateX(-100%);
    transition: transform 0.32s var(--ease);
    padding-top: 26px;
  }
  body.side-open .admin-side { transform: translateX(0); }
  body.side-open::after {
    content: ""; position: fixed; inset: 0; z-index: 110; background: rgba(0,0,0,0.55);
  }
  .admin-main { padding: 22px 18px 90px; }
  .ptr { grid-template-columns: 44px 1fr 74px; }
  .ptr.head, .ptr .pcat { display: none; }
  .ptr .prow-actions { grid-column: 1 / -1; justify-content: flex-start; }
  .icon-picker { grid-template-columns: repeat(4, 1fr); }
}

/* =========================================================
   ADMIN v2 — components for the full administration system
   ========================================================= */
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--font-mono); }
.upper { text-transform: uppercase; }
.bad-text { color: #ff8f7a; }
.ok-text { color: hsl(140, 55%, 62%); }
.warn-text { color: hsl(40, 85%, 62%); }
.admin-main a:not(.btn):not(.mini-btn):not(.mrow):not(.sbar):not(.kpi):not(.side-link) { color: var(--text); text-decoration: underline; text-decoration-color: var(--border-strong); text-underline-offset: 3px; }
.admin-main a:not(.btn):not(.mini-btn):not(.mrow):not(.sbar):not(.kpi):hover { text-decoration-color: var(--acid); }
:focus-visible { outline: 2px solid var(--acid); outline-offset: 2px; }

/* ---------- top bar ---------- */
.admin-bar { gap: 14px; padding: 10px 20px; }
.bar-left { display: flex; align-items: center; gap: 10px; min-width: 0; }
.bar-left .brand span { white-space: nowrap; }
.whoami { display: flex; flex-direction: column; line-height: 1.15; text-align: right; padding: 0 4px; }
.who-name { font-size: 0.8rem; font-weight: 600; }
.who-role { font-family: var(--font-mono); font-size: 0.64rem; color: var(--acid); text-transform: uppercase; letter-spacing: 0.06em; }
.gsearch { position: relative; flex: 1; max-width: 520px; display: flex; align-items: center; }
.gsearch > svg { position: absolute; left: 12px; width: 15px; height: 15px; color: var(--text-mute); pointer-events: none; }
.gsearch input {
  width: 100%; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 9px 12px 9px 34px; color: var(--text); font-family: inherit; font-size: 0.86rem;
}
.gsearch input:focus { outline: none; border-color: var(--acid); background: var(--bg-elev); }
.gsearch-results {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 60; max-height: 60vh; overflow-y: auto;
  background: var(--bg-elev); border: 1px solid var(--border-strong); box-shadow: var(--shadow);
}
.gs-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-bottom: 1px solid var(--border); }
.gs-row:last-child { border-bottom: 0; }
.gs-row.sel, .gs-row:hover { background: var(--surface-2); }
.gs-type { flex: none; width: 66px; font-family: var(--font-mono); font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--acid); }
.gs-main { display: flex; flex-direction: column; min-width: 0; font-size: 0.84rem; }
.gs-main .muted { font-size: 0.74rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gs-empty { padding: 14px; color: var(--text-mute); font-size: 0.84rem; }

/* ---------- sidebar ---------- */
.admin-side { top: 59px; min-height: calc(100vh - 59px); gap: 2px; width: 220px; flex-basis: 220px; overflow-y: auto; max-height: calc(100vh - 59px); }
.side-group { margin-bottom: 12px; }
.side-group-label { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--text-mute); padding: 6px 12px 4px; }
.side-link { text-decoration: none; }
.side-badge.hot { background: var(--accent-3) !important; color: #fff !important; }
.side-foot p strong { color: var(--text-dim); font-weight: 600; }

/* ---------- views ---------- */
.admin-main { outline: none; }
.view-head h1 { font-size: clamp(1.5rem, 3vw, 2rem); }
.sub-head { margin: 30px 0 14px; align-items: center; }
.dash-h { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--text-mute); margin: 28px 0 12px; font-weight: 700; }
.hint-line { font-size: 0.78rem; color: var(--text-mute); margin: 8px 0 12px; line-height: 1.5; }
.hint { font-size: 0.72rem; color: var(--text-mute); line-height: 1.45; }
.empty-state { border: 1px dashed var(--border-strong); padding: 38px 20px; text-align: center; color: var(--text-mute); font-size: 0.88rem; display: grid; gap: 12px; justify-items: center; }
.loading { display: flex; align-items: center; gap: 10px; color: var(--text-mute); padding: 26px 4px; font-size: 0.86rem; }
.spinner { width: 16px; height: 16px; border: 2px solid var(--border-strong); border-top-color: var(--acid); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.refreshing { opacity: 0.55; transition: opacity 0.2s; pointer-events: none; }

/* ---------- buttons ---------- */
.mini-btn:disabled, .btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }
.mini-btn.warn:hover { border-color: hsl(40, 85%, 55%); color: hsl(40, 85%, 62%); }
.mini-btn.solid:hover { color: var(--accent-ink); filter: brightness(1.08); }
.btn-danger { background: var(--accent-3); color: #fff; border-color: var(--accent-3); }
.btn-danger:hover { filter: brightness(1.1); }
.btn-row { display: flex; gap: 8px; margin: 12px 0; }
.btn-row.flow { flex-wrap: wrap; }
.input-row { display: flex; gap: 8px; align-items: center; }
.input-row input { flex: 1; min-width: 0; }

/* ---------- filters ---------- */
.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 12px; }
.filters .search { flex: 1 1 240px; min-width: 200px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 10px 14px; color: var(--text); font-family: inherit; font-size: 0.88rem; }
.filters select, .f-date input {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 9px 10px; color: var(--text); font-family: inherit; font-size: 0.84rem;
}
.filters select option, .ad-field select option { background: var(--bg-elev); color: var(--text); }
.f-date { display: inline-flex; align-items: center; gap: 6px; font-family: var(--font-mono); font-size: 0.68rem; color: var(--text-mute); text-transform: uppercase; letter-spacing: 0.06em; }
.filters .search:focus, .filters select:focus, .f-date input:focus { outline: none; border-color: var(--acid); }
.status-filter { margin-bottom: 14px; }
input[type="date"], input[type="datetime-local"] { color-scheme: dark; }

/* ---------- data tables ---------- */
.table-wrap { width: 100%; overflow-x: auto; border: 1px solid var(--border); background: var(--bg-elev); -webkit-overflow-scrolling: touch; }
.dt { width: 100%; border-collapse: collapse; font-size: 0.86rem; }
.dt th {
  text-align: left; font-family: var(--font-mono); font-size: 0.64rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--text-mute); background: var(--surface); padding: 11px 14px; border-bottom: 1px solid var(--border); white-space: nowrap;
}
.dt td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.dt tbody tr:last-child td { border-bottom: 0; }
.dt .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dt.clickable tbody tr { cursor: pointer; transition: background 0.14s var(--ease); }
.dt.clickable tbody tr:hover, .dt.clickable tbody tr:focus-visible { background: var(--surface); }
.dt .cell-main { display: block; font-weight: 600; }
.dt .cell-sub { display: block; font-size: 0.74rem; color: var(--text-mute); margin-top: 2px; }
.dt td.pills { white-space: nowrap; }
.dt td.pills .pill, .pills-row .pill { margin: 1px 2px 1px 0; }
.dt .row-actions { text-align: right; white-space: nowrap; }
.dt .row-actions > * + * { margin-left: 6px; }
.dt tr.row-bad td:first-child { box-shadow: inset 3px 0 0 var(--accent-3); }
.dt tr.detail-row td { background: var(--surface); }
.dt.audit td:first-child { white-space: nowrap; color: var(--text-dim); font-size: 0.8rem; }
.th-sort { display: inline-flex; align-items: center; gap: 4px; font: inherit; color: inherit; letter-spacing: inherit; text-transform: inherit; }
.th-sort:hover { color: var(--text); }
.th-sort .arr { color: var(--acid); min-width: 8px; }
.diff { width: 100%; border-collapse: collapse; font-size: 0.8rem; margin-bottom: 6px; }
.diff th, .diff td { border: 1px solid var(--border); padding: 7px 10px; text-align: left; vertical-align: top; word-break: break-word; }
.diff th { font-family: var(--font-mono); font-size: 0.62rem; text-transform: uppercase; color: var(--text-mute); }
.diff td:nth-child(2) { color: #ffb0a3; }
.diff td:nth-child(3) { color: hsl(90, 60%, 70%); }
.code-tag { display: inline-block; font-family: var(--font-mono); font-size: 0.76rem; font-weight: 700; letter-spacing: 0.04em; padding: 2px 7px; border: 1px dashed var(--border-strong); color: var(--text); }
.pay-tag { color: hsl(var(--h, 200), 70%, 66%); }

/* ---------- pager ---------- */
.pager { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 12px; font-family: var(--font-mono); font-size: 0.72rem; color: var(--text-mute); }
.pager-btns { display: flex; gap: 6px; align-items: center; }
.pager-cur { padding: 0 6px; }

/* ---------- toasts ---------- */
.toasts { position: fixed; right: 18px; bottom: 18px; z-index: 500; display: flex; flex-direction: column; gap: 8px; max-width: min(420px, calc(100vw - 36px)); }
.toast2 {
  display: flex; align-items: flex-start; gap: 10px; padding: 12px 12px 12px 14px;
  background: var(--bg-elev); border: 1px solid var(--border-strong); border-left: 3px solid var(--acid);
  box-shadow: var(--shadow); font-size: 0.86rem; line-height: 1.45;
  transform: translateY(12px); opacity: 0; transition: transform 0.25s var(--ease), opacity 0.25s var(--ease);
}
.toast2.in { transform: none; opacity: 1; }
.toast2 > svg { flex: none; width: 17px; height: 17px; margin-top: 1px; color: var(--acid); }
.toast2.error { border-left-color: var(--accent-3); }
.toast2.error > svg { color: var(--accent-3); }
.toast2.info > svg { color: var(--text-dim); }
.toast2 span { flex: 1; }
.toast2 button { flex: none; width: 22px; height: 22px; display: grid; place-items: center; color: var(--text-mute); }
.toast2 button svg { width: 13px; height: 13px; }

/* ---------- modal dialogs ---------- */
.modal-root { position: fixed; inset: 0; z-index: 400; display: none; place-items: center; padding: 16px; }
.modal-root.open { display: grid; }
.modal-scrim { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.65); backdrop-filter: blur(3px); }
.modal {
  position: relative; width: min(480px, 100%); max-height: calc(100vh - 32px); overflow-y: auto;
  background: var(--bg-elev); border: 1px solid var(--border-strong); border-top: 3px solid var(--acid);
  padding: 24px; box-shadow: var(--shadow); animation: modal-in 0.2s var(--ease);
}
.modal.danger { border-top-color: var(--accent-3); }
@keyframes modal-in { from { transform: translateY(10px); opacity: 0; } }
.modal h2 { font-family: var(--font-display); font-size: 1.25rem; text-transform: none; letter-spacing: -0.01em; line-height: 1.2; margin-bottom: 12px; }
.modal-body { font-size: 0.9rem; color: var(--text-dim); line-height: 1.55; margin-bottom: 14px; }
.modal-body p + p { margin-top: 8px; }
.modal-body strong { color: var(--text); }
.modal-err { color: #ff8f7a; font-size: 0.8rem; min-height: 1em; margin: 4px 0; }
.modal-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 10px; }
.modal-actions .btn { padding: 11px 18px; }
.check-row { display: flex; gap: 9px; align-items: flex-start; font-size: 0.86rem; color: var(--text-dim); margin: 8px 0; cursor: pointer; line-height: 1.4; }
.check-row input { margin-top: 3px; accent-color: var(--acid); flex: none; }
.check-row .hint { display: block; margin-top: 2px; }
.ad-field .hint { margin-top: 2px; }
.ad-field input[readonly], .ad-field textarea[readonly] { opacity: 0.75; }
.ad-grid3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.ad-field.inline { flex-direction: row; align-items: center; gap: 10px; margin-top: 14px; }
.ad-field.inline label { white-space: nowrap; }

/* ---------- drawer extras ---------- */
.admin-drawer { width: min(640px, 100vw); }
.ad-head .when a { color: var(--text-dim); }
.kv { border: 1px solid var(--border); display: grid; }
.kv > div { display: grid; grid-template-columns: 150px 1fr; gap: 10px; padding: 9px 12px; border-bottom: 1px solid var(--border); font-size: 0.84rem; }
.kv > div:last-child { border-bottom: 0; }
.kv > div > span:first-child { color: var(--text-mute); font-size: 0.78rem; }
.kv > div > span:last-child { min-width: 0; overflow-wrap: anywhere; }
.kv svg { width: 12px; height: 12px; vertical-align: -1px; }
.pills-row { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 10px; }
.ad-items .li.sub { color: var(--text-dim); }
.ad-items .li.disc span:last-child { color: var(--acid); }
.quote-box { border-left: 2px solid var(--acid); padding: 8px 12px; margin: 10px 0; background: var(--surface); font-size: 0.86rem; }
.quote-box p { margin-top: 4px; white-space: pre-wrap; }
.notes { display: grid; gap: 8px; margin-bottom: 10px; }
.note { border: 1px solid var(--border); padding: 10px 12px; background: var(--surface); font-size: 0.86rem; }
.note p { white-space: pre-wrap; margin-bottom: 4px; }
.note .muted { font-size: 0.72rem; }
.note-add { display: flex; gap: 8px; align-items: flex-end; }
.note-add textarea { flex: 1; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 9px 11px; color: var(--text); font-family: inherit; font-size: 0.86rem; resize: vertical; }
.note-add textarea:focus { outline: none; border-color: var(--acid); }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--border); margin: 20px 0 16px; overflow-x: auto; }
.tab { padding: 9px 12px; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-mute); border-bottom: 2px solid transparent; white-space: nowrap; }
.tab:hover { color: var(--text); }
.tab.active { color: var(--text); border-bottom-color: var(--acid); }
.timeline .tl strong { color: var(--text); font-weight: 600; }
.status-opt:disabled { cursor: default; opacity: 0.7; }
.pthumb img { width: 100%; height: 100%; object-fit: cover; }

/* toggle switch */
.switch { position: relative; display: inline-block; width: 34px; height: 19px; cursor: pointer; }
.switch input { position: absolute; opacity: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.switch span { position: absolute; inset: 0; background: var(--surface-2); border: 1px solid var(--border-strong); border-radius: 999px; transition: background 0.2s; }
.switch span::after { content: ""; position: absolute; top: 2px; left: 2px; width: 13px; height: 13px; border-radius: 50%; background: var(--text-dim); transition: transform 0.2s var(--ease), background 0.2s; }
.switch input:checked + span { background: var(--acid); border-color: var(--acid); }
.switch input:checked + span::after { transform: translateX(15px); background: #0c0c0d; }
.switch input:focus-visible + span { outline: 2px solid var(--acid); outline-offset: 2px; }

/* discount pickers */
.pick-cols { display: grid; grid-template-columns: 1fr 1.4fr; gap: 12px; }
.pick-label { font-family: var(--font-mono); font-size: 0.62rem; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-mute); margin-bottom: 4px; }
.pick-list { border: 1px solid var(--border); padding: 4px 10px; max-height: 190px; overflow-y: auto; background: var(--surface); }
.pick-list .check-row { margin: 6px 0; font-size: 0.82rem; }

/* ---------- dashboard ---------- */
.kpi { display: block; }
.kpi.link { transition: border-color 0.16s var(--ease), background 0.16s var(--ease); }
.kpi.link:hover { border-color: var(--border-strong); background: var(--surface); }
.kpi .k-value { font-family: var(--font); font-weight: 600; font-size: 1.7rem; line-height: 1.15; overflow-wrap: anywhere; }
.k-unit { font-size: 0.8rem; color: var(--text-mute); font-weight: 400; }
.k-sub { font-size: 0.74rem; color: var(--text-mute); margin-top: 6px; line-height: 1.4; }
.kpi-row { margin-bottom: 14px; }
.alerts { margin-bottom: 8px; padding: 14px 18px; }
.alerts h3 { margin-bottom: 8px; }
.alert-row { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--border); font-size: 0.86rem; }
.alert-row:last-child { border-bottom: 0; }
.alert-row svg { flex: none; width: 16px; height: 16px; }
.alert-row span { flex: 1; }
.alert-row a { font-family: var(--font-mono); font-size: 0.7rem; text-transform: uppercase; }
.alert-row.bad svg { color: var(--accent-3); }
.alert-row.warn svg { color: hsl(40, 85%, 58%); }
.alert-row.info svg { color: var(--text-dim); }
.alert-row.good svg { color: var(--acid); }
.dash-cols { margin-top: 18px; }
a.mrow, a.sbar { text-decoration: none !important; color: inherit; }
.sbar { padding: 3px 0; }
.sbar:hover .sbar-label { color: var(--text); }
.chart-panel { margin-bottom: 8px; }
.chart-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 10px; }
.chart-head h3 { margin-bottom: 2px; }
.chart-sub { font-size: 0.76rem; color: var(--text-mute); }
.chart { position: relative; width: 100%; }
.chart svg { display: block; width: 100%; height: auto; overflow: visible; }
.c-grid { stroke: var(--border); stroke-width: 1; shape-rendering: crispEdges; }
.c-axis { stroke: var(--border-strong); stroke-width: 1; shape-rendering: crispEdges; }
.c-tick { fill: var(--text-mute); font-family: var(--font-mono); font-size: 10px; font-variant-numeric: tabular-nums; }
.c-label { fill: var(--text); font-family: var(--font); font-size: 11px; font-weight: 600; }
.c-bar { fill: #7a9a08; transition: fill 0.12s; }
.c-bar.on { fill: var(--acid); }
.c-hit { fill: transparent; cursor: default; outline: none; }
.c-hit:focus-visible { fill: rgba(242, 241, 236, 0.04); }
.c-tip {
  position: absolute; pointer-events: none; z-index: 5; display: grid; gap: 1px; padding: 8px 10px;
  background: var(--bg); border: 1px solid var(--border-strong); box-shadow: var(--shadow); white-space: nowrap;
}
.c-tip strong { font-size: 0.95rem; }
.c-tip span { font-size: 0.72rem; color: var(--text-dim); }

/* ---------- themes ---------- */
.live-panel { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: 22px; align-items: start; }
.live-info h2 { font-size: clamp(1.4rem, 3vw, 2rem); text-transform: none; margin: 4px 0 8px; }
.live-info p { color: var(--text-dim); font-size: 0.9rem; }
.live-info .eyebrow { margin-bottom: 4px; }
.upcoming { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; font-size: 0.8rem; }
.up-item { border: 1px solid var(--border); padding: 3px 8px; font-family: var(--font-mono); font-size: 0.7rem; }
.theme-grid, .role-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(270px, 1fr)); gap: 14px; }
.theme-card, .role-card { border: 1px solid var(--border); background: var(--bg-elev); display: flex; flex-direction: column; }
.theme-card.live { border-color: var(--acid); box-shadow: 0 0 0 1px var(--acid); }
.tc-body, .role-card { padding: 14px; }
.tc-body { flex: 1; display: flex; flex-direction: column; }
.tc-body .btn-row { margin: auto 0 0; padding-top: 10px; }
.tc-title { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.tc-title strong { font-size: 0.98rem; margin-right: 2px; }
.tc-title .muted { font-size: 0.74rem; margin-left: auto; }
.tc-desc { font-size: 0.8rem; margin: 6px 0 0; line-height: 1.45; }
.perm-count { font-family: var(--font-mono); font-size: 0.7rem; color: var(--text-dim); margin: 10px 0 0; }
.role-card .btn-row { margin-bottom: 0; }
.check-row.perm code { font-size: 0.66rem; color: var(--text-mute); margin-left: 4px; }

/* theme mockup — a tiny storefront drawn in the theme's colours */
.tmock { position: relative; overflow: hidden; background: var(--m-bg); color: var(--m-text); aspect-ratio: 16 / 10; border-bottom: 1px solid var(--border); font-family: var(--font); }
.live-panel .tmock { border: 1px solid var(--border); }
.tmock.pat-grid { background-image: linear-gradient(color-mix(in srgb, var(--m-text) 6%, transparent) 1px, transparent 1px), linear-gradient(90deg, color-mix(in srgb, var(--m-text) 6%, transparent) 1px, transparent 1px); background-size: 14px 14px; }
.tmock.pat-dots { background-image: radial-gradient(color-mix(in srgb, var(--m-text) 14%, transparent) 1px, transparent 1.4px); background-size: 9px 9px; }
.tmock.pat-diagonal { background-image: repeating-linear-gradient(135deg, color-mix(in srgb, var(--m-text) 5%, transparent) 0 6px, transparent 6px 12px); }
.tmock.pat-glow, .tmock.pat-stars { background-image: radial-gradient(90% 70% at 100% 100%, color-mix(in srgb, var(--m-accent) 16%, transparent), transparent 60%); }
.tm-banner { background: var(--m-accent); color: var(--m-ink); font-size: 8px; font-family: var(--font-mono); font-weight: 700; padding: 3px 6px; text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tm-nav { display: flex; align-items: center; gap: 4px; padding: 6% 7% 0; }
.tm-logo { width: 22%; height: 7px; background: var(--m-text); border-radius: 1px; }
.tm-emb { width: 8px; height: 8px; border-radius: 50%; background: var(--m-accent); }
.tm-links { margin-left: auto; display: flex; gap: 4px; }
.tm-links i { width: 12px; height: 3px; background: var(--m-dim); opacity: 0.8; }
.tm-hero { padding: 7% 7% 0; display: grid; gap: 5px; justify-items: start; }
.tm-eye { width: 18%; height: 3px; background: var(--m-accent); }
.tm-h { width: 62%; height: 9px; background: var(--m-text); }
.tm-h.short { width: 40%; }
.tm-p { width: 55%; height: 3px; background: var(--m-mute); }
.tm-btns { display: flex; gap: 5px; margin-top: 3px; }
.tm-btn { font-size: 7px; font-family: var(--font-mono); font-weight: 700; padding: 3px 7px; background: var(--m-text); color: var(--m-bg); border-radius: var(--m-r); letter-spacing: 0.04em; }
.tm-btn.up { text-transform: uppercase; }
.tm-btn.ghost { background: transparent; border: 1px solid color-mix(in srgb, var(--m-text) 40%, transparent); width: 24px; }
.tm-cards { position: absolute; left: 7%; right: 7%; bottom: 7%; display: grid; grid-template-columns: repeat(3, 1fr); gap: 5px; }
.tm-cards span { height: 18px; background: var(--m-surface); border: 1px solid color-mix(in srgb, var(--m-text) 12%, transparent); border-radius: calc(var(--m-r) / 2); }
.tm-cards span.sale { box-shadow: inset 0 -3px 0 var(--m-warm); }
.tm-decor { position: absolute; bottom: calc(7% + 24px); right: 7%; font-family: var(--font-mono); font-size: 7px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--m-accent); background: color-mix(in srgb, var(--m-bg) 70%, transparent); padding: 2px 4px; }
.tmock:not(.small) .tm-btn { font-size: 9px; }
.color-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.color-field { display: flex; align-items: center; gap: 10px; border: 1px solid var(--border); padding: 6px 8px; cursor: pointer; font-size: 0.8rem; }
.color-field input[type="color"] { width: 34px; height: 26px; padding: 0; border: 1px solid var(--border-strong); background: none; cursor: pointer; flex: none; }
.color-field span { display: flex; flex-direction: column; line-height: 1.25; }
.color-field code { font-size: 0.68rem; color: var(--text-mute); }
input[type="range"]:not(.hue-slider) { accent-color: var(--acid); width: 100%; }
[data-mock] .tmock { margin-bottom: 16px; }

/* ---------- settings ---------- */
.settings-form { max-width: 640px; }
.settings-form h3 { margin: 22px 0 10px; }
.setting-bool { margin: 12px 0; font-size: 0.9rem; color: var(--text); }
.img-setting { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.img-prev { width: 52px; height: 52px; border: 1px solid var(--border); display: grid; place-items: center; background: var(--surface); padding: 6px; }
.img-prev img { max-width: 100%; max-height: 100%; }
.social-grid { display: grid; gap: 6px; }
.social-row { display: grid; grid-template-columns: 110px 1fr; align-items: center; gap: 10px; font-size: 0.82rem; color: var(--text-dim); }
.social-row input { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 8px 10px; color: var(--text); font-family: inherit; font-size: 0.84rem; }
.social-row input:focus { outline: none; border-color: var(--acid); }
.test-mail { margin-top: 12px; }

/* ---------- sign-in ---------- */
.lock-card .hint a { color: var(--text-dim); text-decoration: underline; }
.lock-card input { text-align: left; letter-spacing: normal; }

/* ---------- responsive ---------- */
@media (max-width: 1080px) {
  .gsearch { max-width: none; }
  .whoami { display: none; }
}
@media (max-width: 860px) {
  .admin-side { top: 0; max-height: none; min-height: 100vh; }
  .live-panel { grid-template-columns: 1fr; }
  .kv > div { grid-template-columns: 120px 1fr; }
  .pick-cols, .ad-grid3, .color-grid { grid-template-columns: 1fr; }
  .hide-sm { display: none; }
  .admin-bar { flex-wrap: wrap; }
  .gsearch { order: 3; flex-basis: 100%; }
  .bar-left .admin-tag { display: none; }
}
@media (max-width: 560px) {
  .kpi-row { grid-template-columns: 1fr 1fr; gap: 10px; }
  .kpi { padding: 14px; }
  .kpi .k-value { font-size: 1.3rem; }
  .ad-grid2 { grid-template-columns: 1fr; }
  .admin-main { padding: 16px 14px 90px; }
  .ad-body, .ad-head, .ad-foot { padding-left: 16px; padding-right: 16px; }
  .modal { padding: 18px; }
  .theme-grid, .role-grid { grid-template-columns: 1fr; }
}
