/* PIM — PT Sholeh Kreatif Marketing
   Clean theme · Poppins · basis Nordic Yellow (biru utama, kuning aksen) */

@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-400.woff') format('woff'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 500 600; font-display: swap; src: url('fonts/poppins-500.woff') format('woff'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/poppins-700.woff') format('woff'); }

:root {
  --primary: #003399;
  --primary-hover: #002B80;
  --primary-10: #EEF2FB;
  --primary-25: rgba(0, 51, 153, .22);
  --secondary: #FFDA1A;
  --brand: #D71418;            /* merah logo SKM */
  --neutral: #8A8F98;
  --bg: #F6F7F9;
  --surface: #FFFFFF;
  --subtle: #F3F4F6;
  --text: #111111;
  --text-2: #5B616B;
  --border: #E6E8EC;
  --border-strong: #D5D8DE;
  --success: #0A8A00;
  --success-bg: #EAF6E9;
  --warning: #C76400;
  --warning-bg: #FFF3E5;
  --error: #CC0008;
  --error-bg: #FDECEC;
  --e1: 0 1px 2px rgba(17, 17, 17, .04);
  --e2: 0 6px 20px rgba(17, 17, 17, .08);
  --e3: 0 16px 40px rgba(17, 17, 17, .14);
  --r-sm: 6px; --r: 8px; --r-lg: 12px; --r-xl: 16px;
  --font: 'Poppins', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font: 400 14px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { margin: 0; line-height: 1.3; font-weight: 600; letter-spacing: -.01em; }
h1 { font-size: 24px; } h2 { font-size: 20px; } h3 { font-size: 16px; } h4 { font-size: 14px; }
b, strong { font-weight: 600; }
.mono { font-family: var(--mono); font-size: 13px; }
.muted { color: var(--text-2); }
.small { font-size: 13px; } .caption { font-size: 12px; color: var(--neutral); }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.center { text-align: center; }
.hidden { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---------- Header ---------- */
.topbar { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid var(--border); }
.topbar-inner { max-width: 1400px; margin: 0 auto; height: 64px; padding: 0 24px; display: flex; align-items: center; gap: 24px; }
.logo { display: flex; align-items: center; gap: 12px; color: var(--text); white-space: nowrap; }
.logo:hover { text-decoration: none; }
.logo img { height: 40px; width: auto; display: block; }
.logo .logo-text { display: flex; flex-direction: column; line-height: 1.2; padding-left: 12px; border-left: 1px solid var(--border); }
.logo .logo-text b { font-size: 14px; font-weight: 600; }
.logo .logo-text small { font-size: 11px; color: var(--neutral); }
.gsearch { flex: 1; max-width: 520px; position: relative; }
.gsearch input { width: 100%; height: 40px; border-radius: var(--r); border: 1px solid transparent; padding: 0 14px 0 40px; font: 400 14px var(--font); color: var(--text); background: var(--subtle); outline: none; transition: background .15s, border-color .15s; }
.gsearch input:focus { background: #fff; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-10); }
.gsearch .ico { position: absolute; left: 12px; top: 10px; color: var(--neutral); pointer-events: none; }
.gsearch-results { position: absolute; top: 46px; left: 0; right: 0; background: #fff; color: var(--text); border-radius: var(--r-lg); border: 1px solid var(--border); box-shadow: var(--e2); overflow: hidden; max-height: 420px; overflow-y: auto; }
.gsearch-results a { display: flex; gap: 12px; align-items: center; padding: 10px 14px; color: var(--text); border-bottom: 1px solid var(--border); }
.gsearch-results a:last-child { border-bottom: 0; }
.gsearch-results a:hover, .gsearch-results a.active { background: var(--subtle); text-decoration: none; }
.top-actions { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.icon-btn { width: 40px; height: 40px; border-radius: 9999px; border: 0; background: transparent; color: var(--text-2); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; position: relative; }
.icon-btn:hover { background: var(--subtle); color: var(--text); }
.icon-btn .dot { position: absolute; top: 3px; left: 22px; min-width: 16px; height: 16px; border-radius: 9999px; background: var(--brand); color: #fff; font-size: 10px; font-weight: 600; line-height: 16px; padding: 0 4px; text-align: center; border: 2px solid #fff; box-sizing: content-box; }
.user-chip { display: flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 9999px; cursor: pointer; color: var(--text); background: transparent; border: 1px solid var(--border); font: 500 13px var(--font); }
.user-chip:hover { background: var(--subtle); }
.avatar { width: 30px; height: 30px; border-radius: 9999px; background: var(--primary-10); color: var(--primary); display: inline-flex; align-items: center; justify-content: center; font-weight: 600; font-size: 12px; flex: none; }

.subnav { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 64px; z-index: 40; }
.subnav-inner { max-width: 1400px; margin: 0 auto; padding: 0 24px; display: flex; gap: 2px; height: 48px; overflow-x: auto; scrollbar-width: none; }
.subnav a { display: flex; align-items: center; gap: 8px; padding: 0 12px; color: var(--text-2); font-weight: 500; font-size: 13px; border-bottom: 2px solid transparent; white-space: nowrap; }
.subnav a:hover { text-decoration: none; color: var(--text); }
.subnav a.active { color: var(--primary); border-bottom-color: var(--primary); }
.subnav a svg { opacity: .75; }

/* ---------- Layout ---------- */
.container { max-width: 1400px; margin: 0 auto; padding: 32px 24px 72px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 24px; flex-wrap: wrap; }
.page-head p { margin: 4px 0 0; color: var(--text-2); font-size: 13px; }
.page-head .actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.breadcrumb { font-size: 13px; color: var(--neutral); margin-bottom: 8px; }
.grid { display: grid; gap: 16px; grid-template-columns: minmax(0, 1fr); }
.grid > * { min-width: 0; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g-2-1 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.g-1-2 { grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); }
.section { margin-top: 32px; }
.row { display: flex; gap: 12px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.spacer { flex: 1; }
@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g-2-1, .g-1-2, .g3 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 680px) {
  .g2, .g4 { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .topbar-inner { gap: 10px; padding: 0 12px; height: 60px; } .logo .logo-text, .user-chip span { display: none; } .logo img { height: 32px; }
  .subnav { top: 60px; } .subnav-inner { padding: 0 8px; }
  .container { padding: 20px 12px 48px; } h1 { font-size: 20px; }
}

/* ---------- Panels / cards ---------- */
.panel { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.panel-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 18px 20px 0; }
.panel-head h3 { font-size: 15px; font-weight: 600; }
.panel-head a { font-size: 13px; font-weight: 500; }
.panel-body { padding: 20px; }
.panel-body.flush { padding: 0; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); overflow: hidden; transition: box-shadow .15s, border-color .15s; }
.card:hover { box-shadow: var(--e2); border-color: var(--border-strong); }

.kpi { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); padding: 18px 20px; position: relative; }
.kpi .label { font-size: 12px; font-weight: 500; color: var(--text-2); display: flex; gap: 6px; align-items: center; }
.kpi .value { font-size: 22px; font-weight: 600; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; letter-spacing: -.01em; }
.kpi .sub { font-size: 12px; color: var(--neutral); margin-top: 4px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.kpi.accent { }
.kpi.blue { background: var(--primary); border-color: var(--primary); color: #fff; }
.kpi.blue .label, .kpi.blue .sub { color: rgba(255, 255, 255, .78); }
.delta { font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 9999px; }
.delta.up { color: var(--success); background: var(--success-bg); }
.delta.down { color: var(--error); background: var(--error-bg); }
.kpi.blue .delta.up, .kpi.blue .delta.down { color: #fff; background: rgba(255, 255, 255, .16); }

/* ---------- Buttons ---------- */
.btn { height: 40px; padding: 0 16px; border-radius: var(--r); border: 1px solid transparent; font: 500 14px var(--font); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; white-space: nowrap; background: var(--primary); color: #fff; transition: background .15s, border-color .15s, box-shadow .15s; }
.btn:hover { background: var(--primary-hover); text-decoration: none; }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px var(--primary-25); }
.btn.secondary { background: #fff; color: var(--text); border-color: var(--border-strong); }
.btn.secondary:hover { background: var(--subtle); }
.btn.yellow { background: var(--primary); color: #fff; }
.btn.yellow:hover { background: var(--primary-hover); }
.btn.ghost { background: transparent; color: var(--primary); padding: 0 10px; }
.btn.ghost:hover { background: var(--primary-10); }
.btn.danger { background: #fff; color: var(--error); border-color: #F3C2C3; }
.btn.danger:hover { background: var(--error-bg); }
.btn.sm { height: 34px; padding: 0 12px; font-size: 13px; }
.btn.xs { height: 28px; padding: 0 10px; font-size: 12px; border-radius: var(--r-sm); }
.btn:disabled, .btn.disabled { background: var(--subtle); color: var(--neutral); border-color: var(--border); cursor: not-allowed; }
.btn.round { width: 36px; height: 36px; padding: 0; border-radius: 9999px; justify-content: center; }
.btn-group { display: inline-flex; padding: 3px; background: var(--subtle); border-radius: var(--r); gap: 2px; }
.btn-group button { border: 0; background: transparent; padding: 0 12px; height: 30px; font: 500 12px var(--font); cursor: pointer; color: var(--text-2); border-radius: var(--r-sm); }
.btn-group button:hover { color: var(--text); }
.btn-group button.active { background: #fff; color: var(--text); box-shadow: 0 1px 2px rgba(17, 17, 17, .08); }

/* ---------- Forms ---------- */
label.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 500; }
label.field .hint { font-weight: 400; font-size: 12px; color: var(--neutral); }
.input, select.input, textarea.input { height: 40px; padding: 0 12px; border: 1px solid var(--border-strong); border-radius: var(--r); font: 400 14px var(--font); color: var(--text); background: #fff; width: 100%; outline: none; transition: border-color .15s, box-shadow .15s; }
textarea.input { height: auto; min-height: 90px; padding: 10px 12px; resize: vertical; }
.input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-10); }
.input.error { border-color: var(--error); }
.input:disabled, select.input:disabled, textarea.input:disabled { background: var(--subtle); color: var(--text-2); border-color: var(--border); cursor: not-allowed; }
.checkbox input:disabled { opacity: .45; cursor: not-allowed; }
.input-wrap .input:disabled + .prefix, .input-wrap:has(.input:disabled) .prefix { opacity: .6; }
.input.sm { height: 34px; font-size: 13px; }
.input-wrap { position: relative; }
.input-wrap .prefix { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--neutral); font-size: 13px; pointer-events: none; }
.input-wrap .input { padding-left: 38px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 680px) { .form-grid, .form-grid.three { grid-template-columns: minmax(0, 1fr); } }
.form-section { font-size: 12px; font-weight: 600; color: var(--text); padding-top: 12px; margin-top: 4px; border-top: 1px solid var(--border); }
.checkbox { display: inline-flex; gap: 8px; align-items: center; cursor: pointer; font-size: 13px; }
.checkbox input { appearance: none; width: 18px; height: 18px; border: 1.5px solid var(--border-strong); border-radius: 4px; margin: 0; display: grid; place-content: center; cursor: pointer; background: #fff; flex: none; }
.checkbox input:checked { background: var(--primary); border-color: var(--primary); }
.checkbox input:checked::after { content: ''; width: 9px; height: 5px; border: 2px solid #fff; border-top: 0; border-right: 0; transform: rotate(-45deg) translate(1px, -1px); }
.checkbox input:focus-visible { outline: 2px solid var(--primary-25); outline-offset: 2px; }

/* ---------- Toolbar ---------- */
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 16px; }
.toolbar .input, .toolbar select { height: 38px; width: auto; min-width: 160px; font-size: 13px; }
.toolbar .search { flex: 1; min-width: 220px; max-width: 420px; }

/* ---------- Chips / badges ---------- */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 9999px; font: 500 12px var(--font); background: #fff; color: var(--text-2); border: 1px solid var(--border); cursor: pointer; white-space: nowrap; }
.chip:hover { color: var(--text); border-color: var(--border-strong); }
.chip.active { background: var(--text); border-color: var(--text); color: #fff; }
.chip.new { background: var(--secondary); border-color: var(--secondary); color: var(--text); }
.chip.success { background: var(--success-bg); border-color: transparent; color: var(--success); }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.badge { display: inline-flex; align-items: center; gap: 4px; height: 22px; padding: 0 8px; border-radius: 9999px; font-size: 11px; font-weight: 500; white-space: nowrap; background: var(--subtle); color: var(--text-2); }
.badge.ok { background: var(--success-bg); color: var(--success); }
.badge.warn { background: var(--warning-bg); color: var(--warning); }
.badge.err { background: var(--error-bg); color: var(--error); }
.badge.info { background: var(--primary-10); color: var(--primary); }
.badge.yellow { background: #FFF6C2; color: #6B5A00; }
.badge.solid-ok { background: var(--success); color: #fff; }
.badge.solid-err { background: var(--error); color: #fff; }
.badge.dark { background: var(--text); color: #fff; }
.mp-dot { width: 8px; height: 8px; border-radius: 9999px; display: inline-block; flex: none; }

/* ---------- Tables ---------- */
.table-wrap { overflow-x: auto; background: #fff; border: 1px solid var(--border); border-radius: var(--r-lg); }
table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
.t th { text-align: left; font-size: 11px; font-weight: 500; color: var(--neutral); padding: 12px 14px; border-bottom: 1px solid var(--border); background: #fff; white-space: nowrap; position: sticky; top: 0; z-index: 1; letter-spacing: .02em; text-transform: uppercase; }
.t th.sortable { cursor: pointer; user-select: none; }
.t th.sortable:hover { color: var(--primary); }
.t td { padding: 12px 14px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.t tbody tr { transition: background .1s; }
.t tbody tr:hover { background: #FAFBFC; }
.t tbody tr.clickable { cursor: pointer; }
.t tr:last-child td { border-bottom: 0; }
.t td.num, .t th.num { text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
.t tfoot td { font-weight: 600; background: #FAFBFC; border-top: 1px solid var(--border); }
.thumb { width: 44px; height: 44px; border-radius: var(--r); object-fit: cover; background: var(--subtle); border: 1px solid var(--border); flex: none; display: inline-flex; align-items: center; justify-content: center; color: var(--neutral); font-size: 11px; font-weight: 600; overflow: hidden; }
.thumb.lg { width: 64px; height: 64px; }
.thumb.sm { width: 36px; height: 36px; }
.prod-cell { display: flex; gap: 12px; align-items: center; min-width: 240px; }
.prod-cell .name { font-weight: 500; font-size: 13px; line-height: 1.35; }
.prod-cell .code { font-family: var(--mono); font-size: 11px; color: var(--neutral); }
.empty { padding: 48px 16px; text-align: center; color: var(--text-2); }
.empty svg { color: var(--border-strong); margin-bottom: 8px; }
.pager { display: flex; align-items: center; justify-content: space-between; padding: 12px 16px; font-size: 13px; color: var(--text-2); border-top: 1px solid var(--border); }

/* ---------- Progress ---------- */
.progress { height: 6px; border-radius: 9999px; background: var(--subtle); overflow: hidden; min-width: 60px; }
.progress > span { display: block; height: 100%; background: var(--primary); border-radius: 9999px; }
.progress.ok > span { background: var(--success); }
.progress.warn > span { background: #E87400; }
.progress.err > span { background: var(--error); }
.progress.yellow > span { background: var(--secondary); }

/* ---------- Tabs ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--border); margin-bottom: 20px; overflow-x: auto; }
.tabs button { background: none; border: 0; border-bottom: 2px solid transparent; padding: 10px 12px; font: 500 13px var(--font); color: var(--text-2); cursor: pointer; white-space: nowrap; margin-bottom: -1px; }
.tabs button:hover { color: var(--text); }
.tabs button.active { color: var(--primary); border-bottom-color: var(--primary); }
.tabs .count { background: var(--subtle); padding: 1px 7px; border-radius: 9999px; font-size: 11px; margin-left: 6px; color: var(--text-2); }

/* ---------- Modal ---------- */
.modal-back { position: fixed; inset: 0; background: rgba(17, 17, 17, .4); z-index: 100; display: flex; align-items: flex-start; justify-content: center; padding: 48px 16px; overflow-y: auto; animation: fade .12s; }
.modal { background: #fff; border-radius: var(--r-xl); box-shadow: var(--e3); width: 100%; max-width: 640px; animation: pop .16s; }
.modal.wide { max-width: 920px; }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 20px 24px 16px; }
.modal-head h3 { font-size: 17px; }
.modal-body { padding: 4px 24px 24px; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; padding: 16px 24px; border-top: 1px solid var(--border); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: translateY(8px); opacity: 0; } }

/* ---------- Toast & tooltip ---------- */
.toasts { position: fixed; bottom: 20px; right: 20px; z-index: 200; display: flex; flex-direction: column; gap: 8px; }
.toast { background: var(--text); color: #fff; padding: 12px 16px; border-radius: var(--r-lg); font-size: 13px; box-shadow: var(--e2); max-width: 380px; display: flex; gap: 10px; align-items: flex-start; animation: pop .16s; }
.toast.err svg { color: #FF8A8D; } .toast.ok svg { color: #7FD77A; }
.tip { position: fixed; z-index: 300; background: var(--text); color: #fff; font-size: 12px; padding: 8px 10px; border-radius: var(--r); pointer-events: none; max-width: 280px; line-height: 1.45; box-shadow: var(--e2); }

/* ---------- Dropdown ---------- */
.dropdown { position: absolute; background: #fff; border-radius: var(--r-lg); box-shadow: var(--e2); border: 1px solid var(--border); min-width: 220px; z-index: 120; overflow: hidden; color: var(--text); padding: 4px; }
.dropdown a, .dropdown button { display: flex; width: 100%; gap: 10px; padding: 9px 12px; color: var(--text); background: none; border: 0; text-align: left; font: 400 13px var(--font); cursor: pointer; border-radius: var(--r-sm); align-items: center; }
.dropdown a:hover, .dropdown button:hover { background: var(--subtle); text-decoration: none; }
.dropdown .dd-head { padding: 10px 12px; border-bottom: 1px solid var(--border); font-weight: 600; font-size: 13px; margin: -4px -4px 4px; }

/* ---------- Charts ---------- */
.chart { width: 100%; position: relative; }
.chart svg { display: block; width: 100%; overflow: visible; }
.chart .axis text { font-size: 11px; fill: var(--neutral); font-family: var(--font); }
.chart .grid line { stroke: #EEF0F3; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); }
.legend span { display: inline-flex; gap: 6px; align-items: center; }

/* ---------- Listing matrix ---------- */
.matrix th.store { text-align: center; min-width: 96px; white-space: normal; line-height: 1.3; text-transform: none; letter-spacing: 0; color: var(--text-2); }
.matrix td.cell { text-align: center; padding: 6px; }
.lcell { width: 28px; height: 28px; border-radius: var(--r-sm); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; border: 1px solid transparent; font-size: 11px; font-weight: 600; transition: box-shadow .1s; }
.lcell.live { background: var(--success-bg); color: var(--success); }
.lcell.draft { background: var(--warning-bg); color: var(--warning); }
.lcell.ditolak { background: var(--error-bg); color: var(--error); }
.lcell.nonaktif { background: var(--subtle); color: var(--neutral); }
.lcell.belum { background: #fff; color: var(--border); border: 1px dashed var(--border-strong); }
.lcell:hover { box-shadow: 0 0 0 2px var(--primary-25); }
.lcell.mismatch { box-shadow: inset 0 -3px 0 var(--secondary); }

.lstate { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; min-width: 76px; }
.lstate .badge { width: 100%; justify-content: center; }

/* ---------- Product detail ---------- */
.gallery { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.gallery .main { aspect-ratio: 1 / 1; background: var(--subtle); border-radius: var(--r-lg); overflow: hidden; display: flex; align-items: center; justify-content: center; }
.gallery .main img { width: 100%; height: 100%; object-fit: cover; }
.gallery .thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; }
.gallery .thumbs .t-item { aspect-ratio: 1 / 1; border-radius: var(--r); border: 1px solid var(--border); overflow: hidden; cursor: pointer; position: relative; background: var(--subtle); }
.gallery .thumbs .t-item.active { border: 2px solid var(--primary); }
.gallery .thumbs img { width: 100%; height: 100%; object-fit: cover; }
.gallery .thumbs .t-item .x { position: absolute; top: 3px; right: 3px; width: 20px; height: 20px; border-radius: 9999px; background: rgba(17, 17, 17, .7); color: #fff; border: 0; font-size: 12px; cursor: pointer; display: none; }
.gallery .thumbs .t-item:hover .x { display: block; }
.photo-edit { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.pe-item, .pe-add { aspect-ratio: 1 / 1; border-radius: var(--r); position: relative; overflow: hidden; }
.pe-item { border: 1px solid var(--border); cursor: pointer; background: var(--subtle); }
.pe-item img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pe-item.main { border: 2px solid var(--primary); }
.pe-tag, .pe-new { position: absolute; left: 4px; bottom: 4px; font-size: 10px; font-weight: 600; padding: 1px 6px; border-radius: 9999px; background: var(--primary); color: #fff; }
.pe-new { left: auto; right: 4px; top: 4px; bottom: auto; background: var(--secondary); color: var(--text); }
.pe-x { position: absolute; top: 4px; left: 4px; width: 22px; height: 22px; border-radius: 9999px; border: 0; background: rgba(17,17,17,.7); color: #fff; font-size: 14px; line-height: 22px; cursor: pointer; opacity: 0; transition: opacity .12s; }
.pe-item:hover .pe-x, .pe-item:focus-within .pe-x { opacity: 1; }
@media (hover: none) { .pe-x { opacity: 1; } }
.pe-add { border: 1.5px dashed var(--border-strong); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; color: var(--text-2); font-size: 12px; cursor: pointer; }
.pe-add:hover, .pe-add.over { border-color: var(--primary); color: var(--primary); background: var(--primary-10); }
.dropzone { border: 1.5px dashed var(--border-strong); border-radius: var(--r); display: flex; align-items: center; justify-content: center; text-align: center; color: var(--text-2); font-size: 12px; cursor: pointer; aspect-ratio: 1/1; transition: all .15s; }
.dropzone:hover, .dropzone.over { border-color: var(--primary); color: var(--primary); background: var(--primary-10); }
.price-big { font-size: 28px; font-weight: 600; letter-spacing: -.02em; }
.price-strike { text-decoration: line-through; color: var(--neutral); font-size: 13px; }
.kv { display: grid; grid-template-columns: 160px 1fr; gap: 10px 16px; font-size: 13px; }
.kv dt { color: var(--text-2); } .kv dd { margin: 0; font-weight: 500; }
.barcode-box { background: #fff; border: 1px solid var(--border); border-radius: var(--r); padding: 12px; display: inline-flex; flex-direction: column; align-items: center; }
.econ-card { border: 1px solid var(--border); border-radius: var(--r-lg); padding: 16px; background: #fff; }
.econ-card .mp { display: flex; align-items: center; gap: 8px; font-weight: 600; margin-bottom: 12px; }
.econ-card dl { display: grid; grid-template-columns: 1fr auto; gap: 6px 12px; margin: 0; font-size: 13px; }
.econ-card dt { color: var(--text-2); } .econ-card dd { margin: 0; text-align: right; font-weight: 500; font-variant-numeric: tabular-nums; }
.econ-card .roas-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin-top: 14px; }
.econ-card .roas-row div { background: var(--subtle); border-radius: var(--r); padding: 8px 6px; text-align: center; }
.econ-card .roas-row b { display: block; font-size: 15px; }
.econ-card .roas-row small { font-size: 11px; color: var(--text-2); }

/* ---------- Login ---------- */
.login-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; background: #fff; }
.login-art { background: var(--bg); padding: 48px 56px; display: flex; flex-direction: column; justify-content: space-between; border-right: 1px solid var(--border); }
.login-art .brand img { height: 104px; width: auto; }
.login-art h1 { font-size: 34px; font-weight: 600; max-width: 520px; letter-spacing: -.02em; line-height: 1.25; }
.login-art h1 span { color: var(--primary); }
.login-art ul { list-style: none; padding: 0; margin: 28px 0 0; display: grid; gap: 12px; font-size: 14px; color: var(--text-2); }
.login-art li { display: flex; gap: 10px; align-items: center; }
.login-art li svg { color: var(--primary); flex: none; }
.login-form { display: flex; align-items: center; justify-content: center; padding: 32px; }
.login-form form { width: 100%; max-width: 360px; display: grid; gap: 16px; }
.login-form .mobile-logo { display: none; height: 56px; width: auto; }
@media (max-width: 860px) { .login-wrap { grid-template-columns: 1fr; } .login-art { display: none; } .login-form .mobile-logo { display: block; margin: 0 auto 8px; } }

/* ---------- Misc ---------- */
.notice { padding: 12px 16px; border-radius: var(--r); font-size: 13px; display: flex; gap: 10px; align-items: flex-start; }
.notice > svg { flex: none; margin-top: 1px; }
.notice.info { background: var(--primary-10); color: #1F3F87; }
.notice.warn { background: var(--warning-bg); color: #8A4500; }
.notice.err { background: var(--error-bg); color: var(--error); }
.notice.yellow { background: #FFFBEA; color: var(--text); border: 1px solid #F6E7A6; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 20px; border-bottom: 1px solid var(--border); font-size: 13px; }
.list-item:last-child { border-bottom: 0; }
.list-item:hover { background: #FAFBFC; }
.days { font-family: var(--mono); font-weight: 600; font-size: 12px; }
.loading-page { padding: 64px; text-align: center; color: var(--text-2); }
code, pre { font-family: var(--mono); font-size: 12px; }
pre { background: var(--subtle); padding: 12px; border-radius: var(--r); overflow-x: auto; }
hr { border: 0; border-top: 1px solid var(--border); margin: 16px 0; }
.formula { font-family: var(--mono); font-size: 12px; background: var(--subtle); padding: 10px 12px; border-radius: var(--r); }
@media print { .topbar, .subnav, .page-head .actions, .toolbar { display: none !important; } body { background: #fff; } }
