/* ═══════════════════════════════════════════════
   KOUNTER POS — Version 3 Stylesheet
   ═══════════════════════════════════════════════ */

/* ─── THEME VARIABLES ─────────────────────── */

:root, [data-theme="dark"] {
  --bg:      #0f0f13;
  --bg2:     #16161d;
  --bg3:     #1e1e28;
  --border:  #2a2a38;
  --text:    #e8e8f0;
  --text2:   #8888a8;
  --shadow:  rgba(0,0,0,0.5);
  --accent:  #f59e0b;
  --accent2: #fbbf24;
  --green:   #10b981;
  --blue:    #6366f1;
  --red:     #ef4444;
  --glow1:   rgba(245,158,11,0.08);
  --glow2:   rgba(99,102,241,0.06);
  --grid:    rgba(255,255,255,0.015);
}

[data-theme="ash"] {
  --bg:      #f0ede8;
  --bg2:     #e8e4de;
  --bg3:     #ddd9d2;
  --border:  #c8c3bb;
  --text:    #2c2820;
  --text2:   #7a7268;
  --shadow:  rgba(0,0,0,0.12);
  --accent:  #c2410c;
  --accent2: #ea580c;
  --green:   #166534;
  --blue:    #3730a3;
  --red:     #b91c1c;
  --glow1:   rgba(194,65,12,0.06);
  --glow2:   rgba(55,48,163,0.05);
  --grid:    rgba(0,0,0,0.04);
}

[data-theme="light"] {
  --bg:      #f8f9fc;
  --bg2:     #ffffff;
  --bg3:     #f0f2f7;
  --border:  #dde1eb;
  --text:    #111827;
  --text2:   #6b7280;
  --shadow:  rgba(0,0,0,0.08);
  --accent:  #d97706;
  --accent2: #f59e0b;
  --green:   #059669;
  --blue:    #4f46e5;
  --red:     #dc2626;
  --glow1:   rgba(217,119,6,0.06);
  --glow2:   rgba(79,70,229,0.05);
  --grid:    rgba(0,0,0,0.025);
}

:root {
  --font-head: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --font-mono: 'DM Mono', monospace;
  --radius:    12px;
  --radius-sm: 8px;
  --sidebar-w: 220px;
}

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

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow: hidden;
  transition: background-color 0.25s, color 0.2s;
}

body * { transition: background-color 0.25s, border-color 0.25s, color 0.18s; }

/* ─── VIEWS ───────────────────────────────── */
.view        { display: none; width: 100vw; height: 100vh; }
.view.active { display: flex; }

/* ─── SECTIONS ────────────────────────────── */
/* Sections are shown/hidden by JS with inline display:block / display:none.
   The .section class ONLY provides shared layout — no visibility logic here. */
.section {
  display: none;            /* default — JS overrides with inline style */
  height: 100vh;
  overflow-y: auto;
  padding: 32px;
}

.pos-section {
  padding: 0 !important;
  overflow: hidden !important;
}

/* ═══════════════ LOGIN ═══════════════ */
#view-login {
  align-items: center;
  justify-content: center;
  position: relative;
}

.login-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 50% at 30% 50%, var(--glow1) 0%, transparent 70%),
    radial-gradient(ellipse 50% 60% at 70% 50%, var(--glow2) 0%, transparent 70%);
}
.login-bg::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px);
  background-size: 40px 40px;
}

.login-card {
  position: relative;
  width: 420px;
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 48px 40px;
  box-shadow: 0 40px 80px var(--shadow);
}

.login-logo {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 36px;
}

.logo-icon    { font-size: 32px; color: var(--accent); line-height: 1; }
.logo-main    { display: block; font-family: var(--font-head); font-size: 22px; font-weight: 800; letter-spacing: 0.1em; }
.logo-sub     { display: block; font-size: 11px; color: var(--text2); letter-spacing: 0.12em; text-transform: uppercase; }

.field-group        { margin-bottom: 20px; }
.field-group label  { display: block; font-size: 10px; letter-spacing: 0.15em; color: var(--text2); margin-bottom: 8px; font-family: var(--font-head); font-weight: 600; }

.field-group input,
.field-group select {
  width: 100%;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 16px;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}
.field-group input:focus,
.field-group select:focus { border-color: var(--accent); }

.login-error {
  color: var(--red);
  font-size: 13px;
  min-height: 20px;
  margin-bottom: 8px;
}

.login-hint {
  margin-top: 20px;
  text-align: center;
  font-size: 11px;
  color: var(--text2);
  font-family: var(--font-mono);
}

/* ─── BUTTONS ─────────────────────────────── */
.btn-primary {
  width: 100%;
  background: var(--accent);
  color: #000;
  border: none;
  border-radius: var(--radius-sm);
  padding: 14px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: opacity 0.15s, transform 0.1s;
}
.btn-primary:hover  { opacity: 0.9; }
.btn-primary:active { transform: scale(0.98); }
.btn-primary.sm     { width: auto; padding: 9px 18px; font-size: 12px; }

.btn-success        { background: var(--green); color: #fff; }
.btn-success.sm     { width: auto; padding: 9px 18px; font-size: 12px; border: none; border-radius: var(--radius-sm); font-family: var(--font-head); font-weight: 700; font-size: 12px; letter-spacing: 0.06em; cursor: pointer; }
.btn-success:hover  { opacity: 0.9; }

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 9px 18px;
  font-family: var(--font-body);
  font-size: 13px;
  cursor: pointer;
  transition: border-color 0.2s, color 0.2s;
}
.btn-outline:hover { border-color: var(--accent); color: var(--accent); }
.btn-outline.sm    { padding: 7px 14px; font-size: 12px; }

/* ═══════════════ DASHBOARD SHELL ═══════════════ */
#view-dashboard { flex-direction: row; }
#view-dashboard.active { display: flex; }

/* ─── SIDEBAR ─────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 24px 0;
  flex-shrink: 0;
  overflow-y: auto;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0 20px 24px;
  border-bottom: 1px solid var(--border);
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 16px;
  letter-spacing: 0.1em;
}
.logo-icon-sm { color: var(--accent); font-size: 18px; }

.nav-section  { padding: 16px 12px; flex: 1; }
.nav-label    { font-size: 9px; letter-spacing: 0.18em; color: var(--text2); padding: 0 8px; margin-bottom: 8px; font-family: var(--font-head); }

.nav-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  background: none;
  border: none;
  color: var(--text2);
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 20px;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s, color 0.15s;
  margin-bottom: 2px;
}
.nav-btn:hover  { background: var(--bg3); color: var(--text); }
.nav-btn.active { background: rgba(245,158,11,0.12); color: var(--accent); }
.nav-icon       { font-size: 14px; width: 18px; text-align: center; flex-shrink: 0; }

.sidebar-bottom {
  padding: 16px 12px 0;
  border-top: 1px solid var(--border);
}

.user-badge {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 8px 14px;
}
.user-avatar {
  width: 32px; height: 32px;
  background: var(--accent);
  color: #000;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-weight: 700; font-size: 14px;
  flex-shrink: 0;
}
#userNameDisplay { font-size: 13px; font-weight: 500; }
.user-role       { font-size: 10px; color: var(--text2); }

.logout-btn       { color: var(--red) !important; }
.logout-btn:hover { background: rgba(239,68,68,0.1) !important; }

/* ─── THEME SWITCHER ──────────────────────── */
.theme-switcher {
  padding: 12px 6px 10px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: 8px;
}
.theme-label {
  display: block;
  font-size: 9px; letter-spacing: 0.18em; color: var(--text2);
  font-family: var(--font-head); font-weight: 600;
  margin-bottom: 8px; padding: 0 2px;
}
.theme-pills {
  display: flex; gap: 3px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 3px;
}
.theme-pill {
  flex: 1;
  display: flex; align-items: center; justify-content: center; gap: 5px;
  padding: 6px 3px;
  border: none; border-radius: 7px;
  background: transparent;
  color: var(--text2);
  font-family: var(--font-head); font-size: 10px; font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}
.theme-pill:hover  { color: var(--text); background: var(--bg2); }
.theme-pill.active { background: var(--bg2); color: var(--accent); box-shadow: 0 1px 4px var(--shadow); }

.pill-dot       { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; border: 1.5px solid transparent; }
.dark-dot       { background: #0f0f13; border-color: #555; }
.ash-dot        { background: #c2a880; border-color: #a08060; }
.light-dot      { background: #f8f9fc; border-color: #ccc; }

/* ─── MAIN CONTENT ────────────────────────── */
.main-content { flex: 1; overflow: hidden; position: relative; }

/* ─── PAGE HEADER ─────────────────────────── */
.page-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 28px;
}
.page-header h1      { font-family: var(--font-head); font-size: 26px; font-weight: 800; }
.header-date         { font-family: var(--font-mono); font-size: 12px; color: var(--text2); }
.header-actions      { display: flex; align-items: center; gap: 10px; }
.header-actions select {
  background: var(--bg3); border: 1px solid var(--border); color: var(--text);
  padding: 8px 12px; border-radius: var(--radius-sm); font-size: 13px; cursor: pointer; outline: none;
}

/* ═══════════════ DASHBOARD ═══════════════ */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 24px;
}

.stat-card {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-left: 3px solid var(--card-accent, var(--accent));
  border-radius: var(--radius);
  padding: 20px;
  transition: transform 0.2s;
}
.stat-card:hover { transform: translateY(-2px); }

.stat-label {
  font-size: 9px; letter-spacing: 0.18em; color: var(--text2);
  font-family: var(--font-head); margin-bottom: 10px;
}
.stat-value {
  font-family: var(--font-mono);
  font-size: 26px;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--text);
  margin-bottom: 4px;
}
.stat-sub { font-size: 12px; color: var(--text2); }

.dash-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.dash-card           { background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; }
.dash-card-title     { padding: 14px 20px; font-family: var(--font-head); font-size: 11px; font-weight: 700; letter-spacing: 0.12em; border-bottom: 1px solid var(--border); color: var(--text2); }
.recent-list         { padding: 4px 0; }
.recent-row          { display: flex; align-items: center; padding: 10px 20px; border-bottom: 1px solid var(--border); gap: 12px; font-size: 13px; }
.recent-row:last-child { border-bottom: none; }
.recent-shop         { background: rgba(245,158,11,0.15); color: var(--accent); border-radius: 4px; padding: 2px 7px; font-size: 10px; font-family: var(--font-head); font-weight: 700; flex-shrink: 0; }
.recent-amount       { margin-left: auto; font-family: var(--font-mono); font-weight: 500; }
.recent-time         { color: var(--text2); font-size: 11px; }
.recent-method       { color: var(--text2); font-size: 11px; }
.top-items-list      { padding: 4px 0; }
.top-item-row        { display: flex; align-items: center; padding: 9px 20px; border-bottom: 1px solid var(--border); gap: 12px; font-size: 13px; }
.top-item-row:last-child { border-bottom: none; }
.top-item-rank       { width: 22px; height: 22px; border-radius: 50%; background: var(--bg3); display: flex; align-items: center; justify-content: center; font-size: 10px; font-family: var(--font-head); font-weight: 700; color: var(--text2); flex-shrink: 0; }
.top-item-name       { flex: 1; }
.top-item-qty        { font-family: var(--font-mono); font-size: 12px; color: var(--text2); }
.top-item-rev        { font-family: var(--font-mono); font-size: 12px; color: var(--green); }

/* ═══════════════ SHOP SELECT ═══════════════ */
.shop-cards { display: flex; gap: 24px; margin-top: 40px; }
.shop-card {
  background: var(--bg2); border: 1px solid var(--border); border-radius: 20px;
  padding: 48px 40px; cursor: pointer; text-align: center;
  transition: all 0.2s; flex: 1; max-width: 380px;
}
.shop-card:hover      { border-color: var(--accent); transform: translateY(-4px); box-shadow: 0 20px 40px var(--shadow); }
.shop-card-icon       { font-size: 56px; margin-bottom: 20px; }
.shop-card-name       { font-family: var(--font-head); font-size: 22px; font-weight: 800; margin-bottom: 6px; }
.shop-card-sub        { font-size: 13px; color: var(--text2); }

/* ═══════════════ POS TERMINAL ═══════════════ */
.pos-header {
  display: flex; align-items: center; gap: 16px;
  padding: 14px 20px;
  background: var(--bg2); border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}
.pos-back {
  background: var(--bg3); border: 1px solid var(--border); color: var(--text2);
  padding: 7px 14px; border-radius: 6px; cursor: pointer; font-size: 13px; transition: all 0.15s;
}
.pos-back:hover { color: var(--text); border-color: var(--text2); }
.pos-shop-name  { font-family: var(--font-head); font-size: 18px; font-weight: 800; flex: 1; }
.pos-order-num  { font-family: var(--font-mono); font-size: 12px; color: var(--text2); }

.pos-layout {
  display: flex;
  height: calc(100vh - 57px);
  overflow: hidden;
}

/* ── Category Sidebar (vertical, always visible) ── */
.cat-sidebar {
  width: 150px;
  flex-shrink: 0;
  background: var(--bg2);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 10px 8px;
  gap: 3px;
}
.cat-sidebar::-webkit-scrollbar { width: 3px; }
.cat-sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 2px; }

.cat-tab {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text2);
  padding: 9px 10px;
  border-radius: 8px;
  font-size: 15px;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-head);
  font-weight: 600;
  transition: all 0.15s;
  line-height: 1.3;
  width: 100%;
  word-break: break-word;
}
.cat-tab:hover  { background: var(--bg3); border-color: var(--border); color: var(--text); }
.cat-tab.active { background: var(--accent); color: #000; border-color: var(--accent); }

/* ── Products Grid ── */
.pos-products {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-width: 0;
}
.products-grid {
  flex: 1;
  overflow-y: auto;
  padding: 12px 14px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
  align-content: start;
}

.product-tile {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 14px 25px;
  cursor: pointer; transition: all 0.15s;
  display: flex; flex-direction: column; gap: 6px;
}
.product-tile:hover  { border-color: var(--accent); background: rgba(245,158,11,0.05); transform: scale(1.02); }
.product-tile:active { transform: scale(0.98); }
.product-name        { font-size: 19px; font-weight: 500; line-height: 1.3; color: var(--text); }
.product-price       { font-family: var(--font-mono); font-size: 13px; color: var(--accent); font-weight: 500; }

/* ── Cart ── */
.pos-cart {
  width: 310px; flex-shrink: 0;
  background: var(--bg2); border-left: 1px solid var(--border);
  display: flex; flex-direction: column;
}
.cart-header {
  padding: 14px 18px; font-family: var(--font-head); font-size: 13px; font-weight: 700;
  letter-spacing: 0.1em; border-bottom: 1px solid var(--border); color: var(--text2);
}
.cart-body   { flex: 1; overflow-y: auto; padding: 6px 0; }
.cart-item {
  display: flex; align-items: center; padding: 9px 14px;
  border-bottom: 1px solid var(--border); gap: 7px;
}
.cart-item-name  { flex: 1; font-size: 15px; line-height: 1.3; }
.qty-ctrl        { display: flex; align-items: center; gap: 3px; flex-shrink: 0; }
.qty-btn {
  width: 22px; height: 22px;
  background: var(--bg3); border: 1px solid var(--border);
  border-radius: 4px; cursor: pointer; color: var(--text); font-size: 13px;
  display: flex; align-items: center; justify-content: center; transition: all 0.15s;
}
.qty-btn:hover   { border-color: var(--accent); color: var(--accent); }
.qty-num         { font-family: var(--font-mono); font-size: 15px; width: 20px; text-align: center; }
.cart-item-price { font-family: var(--font-mono); font-size: 15px; color: var(--accent); min-width: 48px; text-align: right; }
.del-btn         { background: none; border: none; color: var(--text2); cursor: pointer; font-size: 13px; padding: 2px; transition: color 0.15s; }
.del-btn:hover   { color: var(--red); }

.cart-footer       { border-top: 1px solid var(--border); padding: 14px 16px; }
.cart-total-row    { display: flex; justify-content: space-between; margin-bottom: 7px; font-size: 12px; color: var(--text2); }
.total-big         { font-family: sans-serif; font-size: 20px; font-weight: 800; color: var(--text); margin-bottom: 14px; }

.pay-buttons { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 8px; }
.pay-btn {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 14px 8px; border: none; border-radius: var(--radius-sm);
  font-family: var(--font-head); font-size: 11px; font-weight: 700;
  letter-spacing: 0.08em; cursor: pointer; transition: opacity 0.15s, transform 0.1s;
}
.pay-btn:active { transform: scale(0.97); }
.pay-btn.cash   { background: var(--green); color: #fff; }
.pay-btn.card   { background: var(--blue);  color: #fff; }
.pay-btn:hover  { opacity: 0.88; }
.pay-icon       { font-size: 20px; }

.clear-cart-btn {
  width: 100%; background: none; border: 1px solid var(--border); color: var(--text2);
  border-radius: var(--radius-sm); padding: 8px; font-size: 12px; cursor: pointer; transition: all 0.15s;
}
.clear-cart-btn:hover { border-color: var(--red); color: var(--red); }

/* ═══════════════ REPORTS ═══════════════ */
.report-filters select {
  background: var(--bg2); border: 1px solid var(--border); color: var(--text);
  padding: 8px 12px; border-radius: var(--radius-sm); font-size: 13px; cursor: pointer; outline: none;
  margin-left: 8px;
}
.report-summary {
  display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; margin-bottom: 20px;
}
.report-stat {
  background: var(--bg2); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 20px;
}
.report-orders-list  { padding: 4px 0; max-height: 380px; overflow-y: auto; }
.report-order-row    { display: flex; align-items: center; gap: 10px; padding: 9px 20px; border-bottom: 1px solid var(--border); font-size: 12px; }
.report-order-row:last-child { border-bottom: none; }
.mono-accent         { font-family: var(--font-mono); color: var(--accent); }

/* ═══════════════ MENU EDITOR ═══════════════ */
.menu-category-block {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); margin-bottom: 14px; overflow: hidden;
}
.menu-cat-header {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 16px; border-bottom: 1px solid var(--border); background: var(--bg3);
}
.menu-cat-name {
  flex: 1;
  background: transparent; border: 1px solid transparent; color: var(--text);
  font-family: var(--font-head); font-size: 14px; font-weight: 700;
  padding: 4px 8px; border-radius: 4px; outline: none; transition: border-color 0.15s;
}
.menu-cat-name:hover, .menu-cat-name:focus { border-color: var(--accent); background: var(--bg); }
.menu-items     { padding: 8px 16px 4px; }
.menu-item-row  { display: flex; align-items: center; gap: 8px; padding: 5px 0; border-bottom: 1px solid rgba(42,42,56,0.4); }
.menu-item-row:last-child { border-bottom: none; }
.menu-item-name, .menu-item-price {
  background: var(--bg3); border: 1px solid var(--border); color: var(--text);
  padding: 7px 10px; border-radius: 6px; font-size: 13px; outline: none; transition: border-color 0.15s;
}
.menu-item-name:focus, .menu-item-price:focus { border-color: var(--accent); }
.menu-item-name  { flex: 1; }
.menu-item-price { width: 85px; font-family: var(--font-mono); color: var(--accent); }
.menu-add-item-btn {
  width: 100%; background: none; border: 1px dashed var(--border); color: var(--text2);
  padding: 8px; border-radius: 6px; cursor: pointer; font-size: 12px;
  margin: 8px 16px; width: calc(100% - 32px); transition: all 0.15s;
}
.menu-add-item-btn:hover { border-color: var(--green); color: var(--green); }

.icon-btn {
  display: flex; align-items: center; gap: 5px;
  background: none; border: 1px solid var(--border); color: var(--text2);
  padding: 5px 10px; border-radius: 6px; cursor: pointer; font-size: 12px; white-space: nowrap;
  transition: all 0.15s;
}
.icon-btn.danger:hover { border-color: var(--red); color: var(--red); }

/* ═══════════════ SETTINGS ═══════════════ */
.settings-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px;
}
.settings-card {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 24px;
}
.settings-card-title {
  font-family: var(--font-head); font-size: 14px; font-weight: 700;
  margin-bottom: 8px; color: var(--text);
}
.settings-desc {
  font-size: 12px; color: var(--text2); line-height: 1.6;
  margin-bottom: 20px;
}
.settings-actions { display: flex; gap: 10px; margin-top: 4px; flex-wrap: wrap; }

.printer-status {
  margin-top: 12px; font-size: 13px; padding: 10px 14px;
  border-radius: 8px; display: none;
}
.printer-status.ok  { display: block; background: rgba(16,185,129,0.1); color: var(--green); border: 1px solid rgba(16,185,129,0.2); }
.printer-status.err { display: block; background: rgba(239,68,68,0.1);  color: var(--red);   border: 1px solid rgba(239,68,68,0.2); }

.printer-help {
  margin-top: 20px;
  background: var(--bg3);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 16px;
}
.printer-help-title {
  font-family: var(--font-head); font-size: 11px; font-weight: 700;
  letter-spacing: 0.1em; color: var(--text2); margin-bottom: 12px;
}
.printer-help-row { display: flex; align-items: flex-start; gap: 10px; font-size: 12px; color: var(--text2); margin-bottom: 8px; line-height: 1.5; }
.printer-help-row:last-child { margin-bottom: 0; }
.ph-step {
  width: 20px; height: 20px; border-radius: 50%;
  background: var(--accent); color: #000;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-head); font-weight: 700; font-size: 10px;
  flex-shrink: 0; margin-top: 1px;
}

.info-row {
  display: flex; justify-content: space-between;
  padding: 10px 0; border-bottom: 1px solid var(--border); font-size: 13px;
}
.info-row:last-child { border-bottom: none; }
.info-row span:first-child { color: var(--text2); }

/* ═══════════════ OVERLAY ═══════════════ */
.overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.7);
  display: flex; align-items: center; justify-content: center;
  z-index: 100; backdrop-filter: blur(8px);
}
.overlay.hidden { display: none; }
.overlay-card {
  background: var(--bg2); border: 1px solid var(--border);
  border-radius: 20px; padding: 48px 40px; text-align: center; min-width: 320px;
}
.overlay-icon {
  width: 64px; height: 64px;
  background: rgba(16,185,129,0.15); border: 2px solid var(--green);
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 28px; color: var(--green); margin: 0 auto 20px;
}
.overlay-title { font-family: var(--font-head); font-size: 22px; font-weight: 800; margin-bottom: 8px; }
.overlay-sub   { font-size: 13px; color: var(--text2); margin-bottom: 28px; }

/* ═══════════════ TOAST ═══════════════ */
.toast {
  position: fixed; bottom: 28px; left: 50%;
  transform: translateX(-50%) translateY(16px);
  background: var(--bg2); border: 1px solid var(--border);
  color: var(--text); padding: 12px 24px; border-radius: 8px;
  font-size: 13px; opacity: 0; transition: all 0.3s; z-index: 200;
  white-space: nowrap; box-shadow: 0 8px 24px var(--shadow);
}
.toast.toast-show  { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast.toast-ok    { border-color: var(--green); color: var(--green); }
.toast.toast-err   { border-color: var(--red);   color: var(--red); }

/* ═══════════════ MISC ═══════════════ */
.empty-state { padding: 32px 20px; text-align: center; color: var(--text2); font-size: 13px; }

::-webkit-scrollbar       { width: 5px; height: 5px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
