/* ═══════════════════════════════════════════════════
   RADIKAL Product Admin — Industrial Utility Aesthetic
   ═══════════════════════════════════════════════════ */

:root {
  --bg-deep: #0a0b0d;
  --bg-surface: #111215;
  --bg-card: #16181c;
  --bg-elevated: #1c1e23;
  --bg-hover: #22252b;
  --border: #2a2d35;
  --border-subtle: #1e2028;
  --text-primary: #e8e9ec;
  --text-secondary: #8b8f9a;
  --text-muted: #555963;
  --accent: #c45c3c;
  --accent-dim: #a04830;
  --accent-glow: rgba(196, 92, 60, 0.15);
  --accent-green: #3a9e6e;
  --accent-yellow: #c9a227;
  --accent-red: #c44040;
  --radius-sm: 4px;
  --radius: 8px;
  --radius-lg: 12px;
  --font-body: 'DM Sans', -apple-system, sans-serif;
  --font-mono: 'Space Mono', monospace;
  --sidebar-w: 280px;
  --topbar-h: 60px;
  --drawer-w: 720px;
  --transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 14px; }

body {
  font-family: var(--font-body);
  background: var(--bg-deep);
  color: var(--text-primary);
  overflow: hidden;
  height: 100vh;
}

.hidden { display: none !important; }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--text-muted); }

/* ── AUTH GATE ── */
#auth-gate {
  position: fixed; inset: 0; z-index: 9999;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-deep);
  background-image:
    radial-gradient(ellipse at 20% 50%, rgba(196, 92, 60, 0.06) 0%, transparent 60%),
    radial-gradient(ellipse at 80% 50%, rgba(196, 92, 60, 0.03) 0%, transparent 60%);
}
.auth-box {
  width: 360px; padding: 48px 40px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-align: center;
  animation: fadeUp 0.5s ease-out;
}
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.auth-logo, .logo {
  font-family: var(--font-mono); font-weight: 700;
  letter-spacing: 0.15em; user-select: none;
}
.auth-logo { font-size: 28px; margin-bottom: 4px; }
.auth-logo-r, .logo-r { color: var(--accent); }
.auth-logo-text, .logo-text { color: var(--text-primary); }
.auth-subtitle { color: var(--text-muted); font-size: 12px; text-transform: uppercase; letter-spacing: 0.12em; margin-bottom: 32px; }
.auth-field { text-align: left; margin-bottom: 20px; }
.auth-field label { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-secondary); margin-bottom: 8px; }
.auth-field input {
  width: 100%; padding: 12px 14px;
  background: var(--bg-deep); border: 1px solid var(--border); border-radius: var(--radius);
  color: var(--text-primary); font-family: var(--font-mono); font-size: 14px;
  transition: border-color var(--transition);
}
.auth-field input:focus { outline: none; border-color: var(--accent); }
#auth-btn {
  width: 100%; padding: 12px;
  background: var(--accent); border: none; border-radius: var(--radius);
  color: white; font-family: var(--font-body); font-weight: 600; font-size: 14px;
  cursor: pointer; transition: background var(--transition);
}
#auth-btn:hover { background: var(--accent-dim); }
.auth-error { color: var(--accent-red); font-size: 12px; margin-top: 12px; min-height: 18px; }

/* ── LAYOUT ── */
#app {
  display: grid;
  grid-template-columns: var(--sidebar-w) 1fr;
  grid-template-rows: 1fr;
  height: 100vh;
  overflow: hidden;
}
#app.sidebar-collapsed { grid-template-columns: 0 1fr; }
#app.sidebar-collapsed #sidebar { transform: translateX(-100%); }

/* ── SIDEBAR ── */
#sidebar {
  background: var(--bg-surface);
  border-right: 1px solid var(--border);
  display: flex; flex-direction: column;
  overflow: hidden;
  transition: transform var(--transition);
}
.sidebar-header {
  padding: 20px 20px 16px;
  display: flex; align-items: center; gap: 12px;
  border-bottom: 1px solid var(--border-subtle);
}
.logo { font-size: 18px; letter-spacing: 0.12em; }
.logo-badge {
  font-family: var(--font-mono); font-size: 9px; font-weight: 700;
  padding: 3px 8px; border-radius: 3px;
  background: var(--accent-glow); color: var(--accent);
  letter-spacing: 0.15em;
}

.sidebar-stats {
  display: flex; gap: 8px; padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}
.stat-pill {
  flex: 1; text-align: center;
  padding: 10px 4px; border-radius: var(--radius);
  background: var(--bg-card);
}
.stat-num { display: block; font-family: var(--font-mono); font-weight: 700; font-size: 18px; color: var(--text-primary); }
.stat-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-muted); }

.sidebar-section { padding: 16px 20px 8px; }
.sidebar-title {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--text-muted); margin-bottom: 10px; font-weight: 600;
}

.filter-search {
  width: 100%; padding: 8px 12px; margin-bottom: 8px;
  background: var(--bg-card); border: 1px solid var(--border-subtle); border-radius: var(--radius-sm);
  color: var(--text-primary); font-size: 12px;
}
.filter-search:focus { outline: none; border-color: var(--accent); }

.filter-list { display: flex; flex-wrap: wrap; gap: 5px; }
.filter-list.scrollable { max-height: 240px; overflow-y: auto; padding-right: 4px; }

.filter-chip {
  padding: 5px 10px; border-radius: 3px;
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); font-size: 11px; cursor: pointer;
  transition: all var(--transition); user-select: none;
  white-space: nowrap;
}
.filter-chip:hover { border-color: var(--border); color: var(--text-primary); }
.filter-chip.active {
  background: var(--accent-glow); border-color: var(--accent);
  color: var(--accent); font-weight: 500;
}
.filter-chip .chip-count {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--text-muted); margin-left: 4px;
}
.filter-chip.active .chip-count { color: var(--accent-dim); }

.sidebar-bottom {
  margin-top: auto; padding: 16px 20px;
  border-top: 1px solid var(--border-subtle);
}
.toggle-row {
  display: flex; align-items: center; gap: 10px;
  font-size: 12px; color: var(--text-secondary); cursor: pointer;
}
.toggle-row input { display: none; }
.toggle-slider {
  width: 36px; height: 20px; border-radius: 10px;
  background: var(--bg-card); border: 1px solid var(--border);
  position: relative; transition: all var(--transition);
  flex-shrink: 0;
}
.toggle-slider::after {
  content: ''; position: absolute; top: 3px; left: 3px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--text-muted); transition: all var(--transition);
}
.toggle-row input:checked + .toggle-slider { background: var(--accent-glow); border-color: var(--accent); }
.toggle-row input:checked + .toggle-slider::after { left: 19px; background: var(--accent); }

/* ── TOPBAR ── */
#topbar {
  height: var(--topbar-h);
  padding: 0 24px;
  display: flex; align-items: center; justify-content: space-between;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface);
}
.topbar-left { display: flex; align-items: center; gap: 12px; }
.topbar-right { display: flex; align-items: center; gap: 16px; }

.icon-btn {
  display: flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: var(--radius);
  background: none; border: 1px solid transparent;
  color: var(--text-secondary); cursor: pointer;
  transition: all var(--transition);
}
.icon-btn:hover { background: var(--bg-hover); border-color: var(--border); color: var(--text-primary); }

.search-box {
  display: flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: var(--radius);
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  width: 320px; transition: border-color var(--transition);
}
.search-box:focus-within { border-color: var(--accent); }
.search-box svg { flex-shrink: 0; color: var(--text-muted); }
.search-box input {
  flex: 1; background: none; border: none; color: var(--text-primary);
  font-size: 13px;
}
.search-box input:focus { outline: none; }
.search-box input::placeholder { color: var(--text-muted); }

.view-toggle { display: flex; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.vt-btn {
  padding: 7px 10px; background: var(--bg-card); border: none;
  color: var(--text-muted); cursor: pointer; display: flex; align-items: center;
  transition: all var(--transition);
}
.vt-btn:first-child { border-right: 1px solid var(--border); }
.vt-btn:hover { color: var(--text-secondary); }
.vt-btn.active { background: var(--bg-hover); color: var(--accent); }

.sort-dropdown select {
  padding: 7px 12px; border-radius: var(--radius);
  background: var(--bg-card); border: 1px solid var(--border-subtle);
  color: var(--text-secondary); font-size: 12px;
  cursor: pointer;
}
.sort-dropdown select:focus { outline: none; border-color: var(--accent); }

.product-count {
  font-family: var(--font-mono); font-size: 12px;
  color: var(--text-muted); white-space: nowrap;
}

/* ── MAIN CONTENT ── */
#main {
  display: grid;
  grid-template-rows: var(--topbar-h) 1fr auto;
  overflow: hidden;
  height: 100%;
}

/* ── PRODUCT GRID ── */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  grid-auto-rows: min-content;
  gap: 16px; padding: 24px;
  overflow-y: auto;
}

.product-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition);
  animation: cardIn 0.3s ease-out both;
}
@keyframes cardIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}
.product-card:hover {
  border-color: var(--border);
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}

.card-img {
  width: 100%; aspect-ratio: 4/3;
  min-height: 180px;
  background: var(--bg-elevated);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; position: relative;
}
.card-img img {
  width: 100%; height: 100%; object-fit: contain;
  transition: transform 0.4s ease;
}
.product-card:hover .card-img img { transform: scale(1.05); }
.card-img .no-img {
  font-size: 11px; color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.1em;
}
.card-img .review-badge {
  position: absolute; top: 8px; right: 8px;
  padding: 3px 8px; border-radius: 3px;
  background: var(--accent-yellow); color: #000;
  font-size: 9px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em;
}

.card-body { padding: 14px 16px; }
.card-brand {
  font-family: var(--font-mono); font-size: 10px;
  color: var(--accent); text-transform: uppercase;
  letter-spacing: 0.1em; margin-bottom: 4px;
}
.card-name {
  font-size: 14px; font-weight: 600;
  color: var(--text-primary); margin-bottom: 6px;
  line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-meta {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.card-tag {
  font-size: 10px; padding: 2px 7px; border-radius: 3px;
  background: var(--bg-elevated); color: var(--text-muted);
}

/* ── TABLE VIEW ── */
.product-table-wrap {
  overflow: auto; padding: 0;
}
#product-table {
  width: 100%; border-collapse: collapse;
  font-size: 13px;
}
#product-table thead { position: sticky; top: 0; z-index: 5; }
#product-table th {
  padding: 12px 16px; text-align: left;
  background: var(--bg-elevated); border-bottom: 1px solid var(--border);
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--text-muted); font-weight: 600; white-space: nowrap;
}
#product-table td {
  padding: 10px 16px; border-bottom: 1px solid var(--border-subtle);
  vertical-align: middle;
}
#product-table tr { cursor: pointer; transition: background var(--transition); }
#product-table tbody tr:hover { background: var(--bg-hover); }
.table-img {
  width: 40px; height: 40px; border-radius: var(--radius-sm);
  object-fit: contain; background: var(--bg-elevated);
}
.table-brand { font-family: var(--font-mono); font-size: 11px; color: var(--accent); }
.table-badge {
  display: inline-block; padding: 2px 6px; border-radius: 3px;
  font-size: 10px; font-weight: 600;
}
.badge-green { background: rgba(58,158,110,0.15); color: var(--accent-green); }
.badge-yellow { background: rgba(201,162,39,0.15); color: var(--accent-yellow); }
.badge-red { background: rgba(196,64,64,0.15); color: var(--accent-red); }
.badge-muted { background: var(--bg-elevated); color: var(--text-muted); }

/* ── PAGINATION ── */
.pagination {
  display: flex; align-items: center; justify-content: center;
  gap: 4px; padding: 16px 24px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  flex-shrink: 0;
}
.page-btn {
  min-width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); border: 1px solid var(--border-subtle);
  background: var(--bg-card); color: var(--text-secondary);
  font-family: var(--font-mono); font-size: 12px;
  cursor: pointer; transition: all var(--transition);
}
.page-btn:hover { border-color: var(--border); color: var(--text-primary); }
.page-btn.active { background: var(--accent); border-color: var(--accent); color: white; }
.page-btn:disabled { opacity: 0.3; cursor: not-allowed; }
.page-dots { color: var(--text-muted); font-size: 14px; padding: 0 4px; }

/* ── LOADING ── */
.loading {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: 12px; padding: 60px;
  color: var(--text-muted); font-size: 13px;
}
.spinner {
  width: 28px; height: 28px;
  border: 2px solid var(--border); border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ── DRAWER ── */
.drawer-overlay {
  position: fixed; inset: 0; z-index: 100;
  background: rgba(0,0,0,0.6);
  backdrop-filter: blur(4px);
  animation: fadeIn 0.2s ease-out;
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

.drawer {
  position: fixed; top: 0; right: 0; bottom: 0;
  width: var(--drawer-w); max-width: 90vw;
  z-index: 101; background: var(--bg-surface);
  border-left: 1px solid var(--border);
  display: flex; flex-direction: column;
  transform: translateX(0);
  animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
}
@keyframes slideIn { from { transform: translateX(100%); } to { transform: translateX(0); } }

.drawer-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.drawer-header h2 { font-size: 18px; font-weight: 600; }

.drawer-body {
  flex: 1; overflow-y: auto; padding: 24px;
}

/* Drawer sections */
.drawer-section { margin-bottom: 28px; }
.drawer-section-title {
  font-size: 10px; text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--text-muted); font-weight: 600; margin-bottom: 12px;
  padding-bottom: 8px; border-bottom: 1px solid var(--border-subtle);
}

.drawer-hero-img {
  width: 100%; max-height: 320px; object-fit: contain;
  background: var(--bg-card); border-radius: var(--radius);
  margin-bottom: 8px;
}

.drawer-image-showcase { display: flex; flex-direction: column; gap: 10px; }
.drawer-main-img {
  width: 100%; max-height: 380px; object-fit: contain;
  background: var(--bg-card); border-radius: var(--radius);
  cursor: zoom-in;
}
.drawer-thumbstrip {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px;
}
.thumbstrip-item {
  width: 64px; height: 64px; flex-shrink: 0;
  object-fit: contain; background: var(--bg-card);
  border: 2px solid var(--border-subtle); border-radius: var(--radius-sm);
  cursor: pointer; transition: all var(--transition);
  opacity: 0.6;
}
.thumbstrip-item:hover { opacity: 0.9; border-color: var(--border); }
.thumbstrip-item.active { opacity: 1; border-color: var(--accent); }

.drawer-meta-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
}
.meta-item { padding: 12px; background: var(--bg-card); border-radius: var(--radius); }
.meta-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.1em; color: var(--text-muted); margin-bottom: 4px; }
.meta-value { font-size: 13px; color: var(--text-primary); word-break: break-word; }

.desc-tabs { display: flex; gap: 0; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
.desc-tab {
  padding: 10px 20px; background: none; border: none;
  border-bottom: 2px solid transparent;
  color: var(--text-muted); font-size: 12px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.08em;
  cursor: pointer; transition: all var(--transition);
}
.desc-tab:hover { color: var(--text-secondary); }
.desc-tab.active { color: var(--accent); border-bottom-color: var(--accent); }
.desc-content {
  font-size: 13px; line-height: 1.7; color: var(--text-secondary);
  white-space: pre-wrap;
}

.spec-table { width: 100%; border-collapse: collapse; }
.spec-table td {
  padding: 8px 12px; border-bottom: 1px solid var(--border-subtle);
  font-size: 12px;
}
.spec-table td:first-child {
  color: var(--text-muted); font-weight: 500; width: 40%;
  font-family: var(--font-mono); font-size: 11px;
}
.spec-table td:last-child { color: var(--text-primary); }

.gallery-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
}
.gallery-thumb {
  aspect-ratio: 1; border-radius: var(--radius-sm);
  object-fit: contain; background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  cursor: pointer; transition: all var(--transition);
  width: 100%;
}
.gallery-thumb:hover { border-color: var(--accent); transform: scale(1.03); }

.doc-list { display: flex; flex-direction: column; gap: 6px; }
.doc-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 14px; background: var(--bg-card);
  border-radius: var(--radius); border: 1px solid var(--border-subtle);
  text-decoration: none; color: var(--text-primary);
  font-size: 13px; transition: all var(--transition);
}
.doc-item:hover { border-color: var(--accent); background: var(--bg-hover); }
.doc-icon { color: var(--accent); flex-shrink: 0; }
.doc-type {
  font-family: var(--font-mono); font-size: 9px;
  text-transform: uppercase; color: var(--text-muted);
  margin-left: auto;
}

.drawer-actions {
  display: flex; gap: 8px; padding: 16px 24px;
  border-top: 1px solid var(--border);
  flex-shrink: 0;
}

/* ── BUTTONS ── */
.btn {
  padding: 10px 20px; border-radius: var(--radius);
  font-family: var(--font-body); font-size: 13px; font-weight: 600;
  cursor: pointer; transition: all var(--transition);
  border: 1px solid transparent;
  display: inline-flex; align-items: center; gap: 6px;
}
.btn-primary { background: var(--accent); color: white; }
.btn-primary:hover { background: var(--accent-dim); }
.btn-ghost { background: var(--bg-card); border-color: var(--border); color: var(--text-secondary); }
.btn-ghost:hover { border-color: var(--text-muted); color: var(--text-primary); }
.btn-sm { padding: 6px 14px; font-size: 12px; }
.btn-danger { background: rgba(196,64,64,0.15); color: var(--accent-red); border-color: rgba(196,64,64,0.3); }
.btn-danger:hover { background: rgba(196,64,64,0.25); }

/* ── EDIT MODAL ── */
.modal-overlay {
  position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(6px);
  animation: fadeIn 0.2s ease-out;
}
.edit-modal {
  position: fixed; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 780px; max-width: 92vw; max-height: 88vh;
  z-index: 201;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  display: flex; flex-direction: column;
  animation: modalIn 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}
@keyframes modalIn {
  from { opacity: 0; transform: translate(-50%, -48%); }
  to { opacity: 1; transform: translate(-50%, -50%); }
}
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 20px 24px; border-bottom: 1px solid var(--border);
}
.modal-header h2 { font-size: 16px; font-weight: 600; }
.modal-body { flex: 1; overflow-y: auto; padding: 24px; }
.modal-footer {
  display: flex; justify-content: flex-end; gap: 8px;
  padding: 16px 24px; border-top: 1px solid var(--border);
}

.form-group { margin-bottom: 20px; }
.form-label {
  display: block; font-size: 11px; text-transform: uppercase;
  letter-spacing: 0.1em; color: var(--text-muted);
  margin-bottom: 6px; font-weight: 600;
}
.form-input, .form-textarea, .form-select {
  width: 100%; padding: 10px 14px;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); color: var(--text-primary);
  font-family: var(--font-body); font-size: 13px;
  transition: border-color var(--transition);
}
.form-textarea { min-height: 120px; resize: vertical; line-height: 1.6; }
.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none; border-color: var(--accent);
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ── TOAST ── */
#toast-container {
  position: fixed; bottom: 24px; right: 24px; z-index: 9999;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  padding: 14px 20px; border-radius: var(--radius);
  background: var(--bg-elevated); border: 1px solid var(--border);
  color: var(--text-primary); font-size: 13px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
  animation: toastIn 0.3s ease-out;
  display: flex; align-items: center; gap: 10px;
}
@keyframes toastIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.toast-success { border-left: 3px solid var(--accent-green); }
.toast-error { border-left: 3px solid var(--accent-red); }
.toast-info { border-left: 3px solid var(--accent); }

/* ── LIGHTBOX ── */
.lightbox-overlay {
  position: fixed; inset: 0; z-index: 300;
  background: rgba(0,0,0,0.9);
  display: flex; align-items: center; justify-content: center;
  cursor: zoom-out;
  animation: fadeIn 0.2s ease-out;
}
.lightbox-img {
  max-width: 90vw; max-height: 90vh;
  object-fit: contain; border-radius: var(--radius);
}

/* ── RESPONSIVE ── */
@media (max-width: 900px) {
  #app { grid-template-columns: 0 1fr; }
  #sidebar { position: fixed; left: 0; top: 0; bottom: 0; z-index: 50; transform: translateX(-100%); }
  #app.sidebar-open #sidebar { transform: translateX(0); }
  .search-box { width: 200px; }
  .drawer { width: 100vw; }
}
