@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800;900&display=swap');

:root{
  /* === Neon Landing Theme === */
  --bg: #07070b;
  --bg2: #050507;

  --card: rgba(255,255,255,.06);
  --cardSolid: rgba(16,16,24,.92);
  --text: #ffffff;
  --muted: rgba(255,255,255,.70);
  --border: rgba(255,255,255,.12);

  --sidebar: rgba(255,255,255,.05);
  --sidebarText: rgba(255,255,255,.86);
  --sidebarTextMuted: rgba(255,255,255,.55);

  --accent: linear-gradient(135deg, rgba(79,70,229,1), rgba(236,72,153,1));
  --accentFlat: rgba(79,70,229,1);
  --accentText: #0b0b0f;

  --radius: 16px;

  --shadow: 0 18px 60px rgba(0,0,0,.55);
  --shadowSoft: 0 10px 28px rgba(0,0,0,.35);
}

* { box-sizing: border-box; }

body{
  margin: 0;
  background:
    radial-gradient(900px 600px at 15% 10%, rgba(79,70,229,.30), transparent 60%),
    radial-gradient(900px 600px at 85% 20%, rgba(236,72,153,.22), transparent 55%),
    radial-gradient(900px 700px at 65% 85%, rgba(34,197,94,.16), transparent 55%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg2) 100%);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  overflow-x: hidden;
}
.robot-pill{display:flex;align-items:center;gap:10px;padding:10px 13px;border:1px solid var(--border);border-radius:12px;background:rgba(255,255,255,.05);font-size:12px;font-weight:800}.robot-pill small{display:block;font-size:9px;font-weight:500;color:var(--muted);margin-top:2px}.robot-dot{width:9px;height:9px;border-radius:50%;background:#f59e0b}.robot-pill.online .robot-dot{background:#22c55e;box-shadow:0 0 0 5px rgba(34,197,94,.13)}

a { text-decoration: none; color: inherit; }

ul,li{ margin:0; padding:0; list-style:none; }

/* LAYOUT */
.app-layout{
  display: flex;
  min-height: 100vh;
}

.app-sidebar{
  width: 260px;
  background: var(--sidebar);
  color: var(--sidebarText);
  padding: 18px 14px;
  position: sticky;
  top: 0;
  height: 100vh;
  border-right: 1px solid var(--border);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.app-main{
  flex: 1;
  display: flex;
  flex-direction: column;
}

.main-container{
  width: 100%;
  /* max-width: 1180px; */
  margin: 0 auto;
  padding: 22px 22px 10px 22px;
}

/* SIDEBAR LOGO */
.sidebar-logo{
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 10px;
  border-radius: 14px;
  color: var(--sidebarText);
  border: 1px solid transparent;
  transition: all .15s ease;
}

.sidebar-logo:hover{
  background: rgba(255,255,255,.06);
  border-color: var(--border);
}

.sidebar-logo img{
  max-width: 100%;
  border-radius: 12px;
}

.sidebar-logo-text .title{
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -.2px;
}

.sidebar-logo-text .subtitle{
  font-size: 12px;
  color: var(--sidebarTextMuted);
  margin-top: 2px;
}

/* SIDEBAR NAV */
.sidebar-nav{
  margin-top: 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.sidebar-link{
  display: flex;
  align-items: center;
  gap: 10px;
  border-radius: 12px;
  color: var(--sidebarText);
  transition: all .15s ease;
  font-size: 14px;
  padding: 20px;
  border: 1px solid transparent;
  background: transparent;
}

.sidebar-link i{
  width: 18px;
  text-align: center;
  color: var(--sidebarTextMuted);
}

.sidebar-link:hover{
  background: rgba(255,255,255,.06);
  border-color: var(--border);
  transform: translateY(-1px);
}

.sidebar-link.active{
  background: var(--accent);
  color: var(--accentText);
  border: none;
  box-shadow: 0 18px 40px rgba(79,70,229,.18);
}

.sidebar-link.active i{
  color: var(--accentText);
}

.sidebar-link.danger{
  color: rgba(255,255,255,.92);
}

.sidebar-divider{
  height: 1px;
  background: rgba(255,255,255,.10);
  margin: 10px 6px;
}

/* FOOTER */
.app-footer{
  max-width: 1180px;
  width: 100%;
  margin: 0 auto;
  padding: 14px 22px 20px 22px;
  color: var(--muted);
  font-size: 13px;
}

.app-footer a{
  color: var(--text);
  font-weight: 700;
  border-bottom: 1px dashed rgba(255,255,255,.30);
}
.app-footer a:hover{ border-bottom-color: rgba(255,255,255,.70); }

/* COMMON CARDS */
.products,
.up-price,
.analyze,
#pills-tabContent{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 40px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* Section spacing */
section { margin: 0; }

/* Existing helper classes */
.padding-inside { padding: 22px; }

.flex { display: flex; align-items: center; gap: 12px; }

.product-image { max-height: 60px; }

input.input-100 { width: 100%; min-width: 100%; }

/* Pills (города) — neon */
.main-info .nav-item{
  background: rgba(255,255,255,.06);
  border: 1px solid var(--border);
  border-radius: 999px;
  margin-right: 8px;
  margin-bottom: 8px;
}

.main-info .nav-item a{
  padding: 6px 14px;
  color: rgba(255,255,255,.92) !important;
  border-radius: 999px;
  opacity: .88;
}

.main-info .nav-item a.active{
  background: var(--accent) !important;
  color: #0b0b0f !important;
  opacity: 1;
}

/* Tables */
.table{
  color: var(--text);
}
.table thead th{
  vertical-align: top !important;
  border-top: 0 !important;
  border-bottom: 1px solid rgba(255,255,255,.10) !important;
  font-weight: 700;
  font-size: 13px;
  color: rgba(255,255,255,.58);
}

.table td,
.table th{
  border-bottom: 1px solid rgba(255,255,255,.08) !important;
}
.table tbody tr {
    background: rgba(0,0,0,.01);
}
.table tbody tr:hover{
  border:1px solid var(--accent);
}

/* Inputs inside products */
.products input{
  max-width: 110px;
  font-size: 12px;
  border-radius: 10px;
  padding: 6px 10px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.06);
  color: var(--text);
}

/* ===== Settings page (new) ===== */
.page-head{
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  margin-bottom: 14px;
}

.page-title{
  font-size: 22px;
  font-weight: 900;
  margin: 0;
  color: var(--text);
  letter-spacing: -.2px;
}

.page-subtitle{
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px;
}

.settings-shell{
  display: block;
}

.card-soft{
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.settings-card{
  padding: 18px;
}

.settings-tabs{
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,.10);
  margin-bottom: 14px;
}

.settings-tabs .nav-pills .nav-link{
  border-radius: 999px;
  padding: 8px 14px;
  color: rgba(255,255,255,.90);
  border: 1px solid rgba(255,255,255,.14);
  margin-right: 8px;
  background: rgba(255,255,255,.05);
  transition: all .15s ease;
}

.settings-tabs .nav-pills .nav-link:hover{
  background: rgba(255,255,255,.08);
  transform: translateY(-1px);
}

.settings-tabs .nav-pills .nav-link.active{
  background: var(--accent);
  color: #0b0b0f;
  border-color: transparent;
}

.settings-content{
  padding-top: 6px;
}

.section-title-row{
  margin-bottom: 12px;
}

.section-title{
  font-size: 16px;
  font-weight: 900;
  margin: 0;
}

.section-hint{
  color: var(--muted);
  font-size: 13px;
  margin-top: 6px;
}

.form-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 14px;
  background: rgba(255,255,255,.05);
}
.form-normal{  
  padding: 14px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 14px;
  background: rgba(255,255,255,.05);

}
.form-normal .hint {
  padding: 30px 0;
  color: var(--muted);
}
.form-normal form {
  width: 100%;
  align-content: center;
  align-items: center;
}
.form-normal form input {
  width: 100%;
}
.form-group{
  margin: 0;
}

.form-label{
  font-size: 12px;
  font-weight: 800;
  color: rgba(255,255,255,.70);
  margin-bottom: 6px;
}

.form-help{
  font-size: 14px;
  color: var(--muted);
  margin: 6px 0;
}

.form-actions{
  grid-column: 1 / -1;
  display: flex;
  justify-content: flex-end;
  padding-top: 4px;
}

.btn-save{
  border-radius: 12px;
  padding: 10px 14px;
  font-weight: 800;
}

.divider{
  height: 1px;
  background: rgba(255,255,255,.10);
  margin: 16px 0;
}

.city-list{
  display:flex;
  flex-wrap:wrap;
  gap: 10px;
  margin: 40px auto;
}

.city-chip{
  display:flex;
  align-items:center;
  gap: 10px;
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  padding: 10px 12px;
  border-radius: 999px;
}

.city-name{
  font-weight: 900;
}

.city-id{
  font-size: 12px;
  color: var(--muted);
}

/* Responsive */
@media (max-width: 900px){
  .form-grid{ grid-template-columns: 1fr; }
}

/* ===== Action bar for /kaspi ===== */
.action-bar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:12px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  border-radius:14px;
  box-shadow: var(--shadowSoft);
  margin-bottom: 12px;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.action-left, .action-right{
  display:flex;
  align-items:center;
  gap:10px;
  flex-wrap:wrap;
}

.inline-form{ margin:0; }

.btnx{
  display:inline-flex;
  align-items:center;
  gap:8px;
  padding:10px 12px;
  border-radius:12px;
  border:1px solid rgba(255,255,255,.12);
  text-decoration:none !important;
  font-weight:800;
  font-size:14px;
  cursor:pointer;
  transition: all .15s ease;
  user-select:none;
  background: rgba(255,255,255,.06);
  color: var(--text);
}

.btnx:hover{
  transform: translateY(-1px);
  box-shadow: 0 18px 40px rgba(0,0,0,.35);
  background: rgba(255,255,255,.09);
  border-color: rgba(255,255,255,.18);
}

.btnx-dark{
  background: var(--accent);
  color: #0b0b0f;
  border-color: transparent;
  box-shadow: 0 18px 40px rgba(79,70,229,.18);
}

.btnx-light{
  background: rgba(255,255,255,.08);
  color: var(--text);
}

.btnx-ghost{
  background: rgba(255,255,255,.03);
  color: var(--text);
}

/* mobile */
@media (max-width: 900px){
  .action-bar{ align-items:flex-start; flex-direction:column; }
  .action-left, .action-right{ width:100%; justify-content:flex-start; }
}

.selectx{
  height: 40px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.06);
  font-weight: 800;
  color: var(--text);
}
.selectx option {
  color: #000;
}
.bulk-bar{
  display:flex;
  justify-content:space-between;
  align-items:center;
  gap:12px;
  padding:12px;
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  border-radius:14px;
  box-shadow: var(--shadowSoft);
  margin: 12px 0;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.bulk-title{ font-size:14px; font-weight:900; }
.bulk-sub{ font-size:12px; opacity:.70; color: var(--muted); }

.price-input{
  width: 160px;
  max-width: 100%;
  padding: 10px 10px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  font-weight: 900;
  background: rgba(255,255,255,.06);
  color: var(--text);
}

.muted{
  font-size: 12px;
  opacity: .70;
  margin-top: 6px;
  color: var(--muted);
}

.prod-title{
  font-weight: 500;
  font-size: 12px;
  color: rgba(255,255,255,.86);
}
.prod-sku{
  display:inline-block;
  margin-top:6px;
  font-size: 13px;
  color: rgba(255,255,255,.82);
  border-bottom: 1px dashed rgba(255,255,255,.25);
}
.prod-sku:hover{
  border-bottom-color: rgba(255,255,255,.75);
}

.inputx{
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255,255,255,.12);
  font-weight: 900;
  width: 100%;
  max-width: 180px;
  background: rgba(255,255,255,.06);
  color: var(--text);
}

.selectx-small{
  height: 40px;
  border-radius: 12px;
  font-size: 12px;
  padding: 0 10px;
  background: rgba(255,255,255,.06);
  color: var(--text);
  border: 1px solid rgba(255,255,255,.12);
}

.checkx{
  width: 18px;
  height: 18px;
  transform: translateY(2px);
  accent-color: var(--accentFlat);
}

.w-price{ max-width: 160px; }
.w-min{ max-width: 160px; }
.w-step{ max-width: 110px; }

.flash-container{
  margin: 10px 0;
}
.flash{
  padding: 12px 16px;
  border-radius: 12px;
  margin-bottom: 8px;
  font-weight: 800;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  box-shadow: var(--shadowSoft);
}
.flash-success{
  background: rgba(34,197,94,.12);
  border-color: rgba(34,197,94,.30);
  color: rgba(255,255,255,.92);
}
.flash-error{
  background: rgba(239,68,68,.12);
  border-color: rgba(239,68,68,.30);
  color: rgba(255,255,255,.92);
}

/* Цена: сделать шире */
.inputx.w-price{
  width: 120px;
  min-width: 120px;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 500;
}

/* Остальные числовые поля */
.inputx.w-min{
  width: 120px;
  min-width: 120px;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 500;
}

.inputx.w-step{
  width: 70px;
  min-width: 70px;
  padding: 8px 10px;
  font-size: 13px;
  font-weight: 500;
}

/* На всякий случай: если bold давит на input/select */
.table td.bold input,
.table td.bold select{
  font-weight: 500 !important;
}

/* ===== Orders / UI blocks ===== */
.page-head{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:16px; margin:16px 0 14px;
}
.h1{ font-size:22px; font-weight:900; letter-spacing:-.2px; }
.small{ font-size:12px; }
.head-actions{ display:flex; gap:10px; align-items:center; }

.notice{
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  border-radius:14px;
  padding:14px 16px;
  display:flex; justify-content:space-between; align-items:center;
  gap:12px;
  box-shadow: var(--shadowSoft);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.tabs{ display:flex; gap:8px; margin:12px 0 14px; flex-wrap:wrap; }
.tab{
  padding:8px 10px; border-radius:12px;
  border:1px solid rgba(255,255,255,.12);
  text-decoration:none;
  opacity:.85;
  color: rgba(255,255,255,.80);
  background: rgba(255,255,255,.04);
  transition: all .15s ease;
}
.tab:hover{ opacity:1; background: rgba(255,255,255,.07); transform: translateY(-1px); }
.tab.active{
  opacity:1;
  background: var(--accent);
  color: #0b0b0f;
  border-color: transparent;
}

.orders-grid{
  display:grid;
  grid-template-columns: repeat(3, minmax(260px, 1fr));
  gap:12px;
}
@media (max-width:1200px){ .orders-grid{ grid-template-columns: repeat(2, 1fr);} }
@media (max-width:760px){ .orders-grid{ grid-template-columns: 1fr;} }

.order-card{
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  border-radius:16px;
  padding:12px 12px;
  display:flex; flex-direction:column; gap:10px;
  box-shadow: var(--shadowSoft);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.order-top{ display:flex; justify-content:space-between; align-items:flex-start; gap:10px; }
.order-code{ font-weight:900; font-size:16px; letter-spacing:-.2px; }
.badges{ display:flex; gap:6px; flex-wrap:wrap; justify-content:flex-end; }
.badge{
  font-size:11px; padding:4px 8px; border-radius:999px;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.88);
  opacity:.95;
}
.badge-2{ opacity:.75; }

.order-mid .row{ display:flex; justify-content:space-between; gap:10px; color: var(--muted); }
.order-bot{ display:flex; justify-content:space-between; align-items:center; gap:10px; }

.ellipsis{
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
  max-width: 320px;
}

.cards{
  display:grid; gap:12px;
  grid-template-columns: repeat(4, minmax(180px, 1fr));
  margin: 12px 0 14px;
}
@media (max-width:1100px){ .cards{ grid-template-columns: repeat(2, 1fr);} }
@media (max-width:560px){ .cards{ grid-template-columns: 1fr;} }

.stat-card{
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  border-radius:16px; padding:14px 14px;
  box-shadow: var(--shadowSoft);
}
.stat{ font-size:24px; font-weight:900; margin-top:6px; }

.grid-2{
  display:grid; grid-template-columns: 1fr 1fr; gap:12px;
}
@media (max-width:980px){ .grid-2{ grid-template-columns: 1fr;} }

.panel{
  border:1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  border-radius:16px; padding:12px 12px;
  box-shadow: var(--shadowSoft);
}
.panel-title{ font-weight:900; margin-bottom:10px; }

.table-compact th, .table-compact td{ padding:10px; }

/* ===== Pages ===== */
.page-head{
  display:flex; align-items:flex-end; justify-content:space-between;
  gap:16px; margin: 6px 0 18px;
}
.page-title{ font-size:22px; font-weight:900; color: var(--text); letter-spacing:-.2px; }
.page-sub{ font-size:13px; color: var(--muted); margin-top:4px; }
.page-actions{ display:flex; gap:10px; align-items:center; flex-wrap:wrap; }

.cards-row{
  display:grid; grid-template-columns: repeat(3, minmax(0,1fr));
  gap:12px; margin-bottom:14px;
}
.stat-card{
  border:1px solid rgba(255,255,255,.12);
  border-radius:14px;
  background: rgba(255,255,255,.04);
  padding:14px 14px;
}
.stat-label{ font-size:12px; color: var(--muted); }
.stat-value{ font-size:22px; font-weight:900; margin-top:6px; color: var(--text); }

.empty-card{
  border:1px dashed rgba(255,255,255,.22);
  border-radius:16px;
  padding:18px;
  background: rgba(255,255,255,.04);
  margin-top:12px;
}
.empty-title{ font-size:16px; font-weight:900; color: var(--text); }
.empty-sub{ font-size:13px; color: var(--muted); margin:6px 0 12px; }

.tablex thead th{
  font-size:12px; color: var(--muted); font-weight:800;
  border-top:none !important;
}
.tablex tbody td{
  vertical-align:top;
}

.badge{
  display:inline-flex; align-items:center;
  border-radius:999px; padding:6px 10px;
  font-size:12px; border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.04);
  color: rgba(255,255,255,.90);
}
.badge-status.ok{ background: rgba(34,197,94,.12); border-color: rgba(34,197,94,.28); color: rgba(255,255,255,.92); }
.badge-status.warn{ background: rgba(245,158,11,.12); border-color: rgba(245,158,11,.28); color: rgba(255,255,255,.92); }

.order-code{ font-weight:900; color: var(--text); }
.order-sub{ font-size:12px; color: var(--muted); margin-top:2px; }
.order-town{ font-weight:800; }

.order-items{
  display:flex; flex-direction:column; gap:10px;
  padding:10px 0;
}
.order-item{
  border:1px solid rgba(255,255,255,.10);
  border-radius:12px; padding:10px 12px;
  background: rgba(255,255,255,.04);
}
.oi-title{ font-size:13px; font-weight:900; color: rgba(255,255,255,.94); }
.oi-sub{ font-size:12px; color: var(--muted); margin-top:3px; }

.mono{ font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace; }

.split{
  display:grid; grid-template-columns: 1fr 1fr; gap:12px;
}
.panel{
  border:1px solid rgba(255,255,255,.12); border-radius:16px;
  background: rgba(255,255,255,.04); padding:12px;
}
.panel-title{ font-size:14px; font-weight:900; margin-bottom:10px; color: var(--text); }

@media (max-width: 1100px){
  .cards-row{ grid-template-columns: 1fr; }
  .split{ grid-template-columns: 1fr; }
}

/* ===== Kaspi inputs fix (как просил) ===== */
.inputx.w-price{
  width: 160px;
  padding: 10px 12px;
  font-size: 12px;
  font-weight: 500;
}

/* ===== Kaspi token form (nice) ===== */
.token-form{
  background: rgba(255,255,255,.05);
  border:1px solid rgba(255,255,255,.12);
  border-radius:16px;
  padding:14px;
  box-shadow: var(--shadowSoft);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.token-row{
  display:flex;
  gap:12px;
  align-items:flex-end;
}

.token-field{ flex:1; min-width: 260px; }

.token-label{
  font-size:12px;
  font-weight:900;
  color: rgba(255,255,255,.70);
  margin-bottom:6px;
}

.token-input{
  width:100%;
  max-width: 100% !important;
}

.token-hint{
  font-size:12px;
  color: var(--muted);
  margin-top:6px;
}

.token-actions{
  display:flex;
  justify-content:flex-end;
}

.token-btn{
  height:40px;
  white-space:nowrap;
}

/* Toggle switch */
.switchx{
  margin-top:12px;
  display:flex;
  align-items:center;
  gap:10px;
  user-select:none;
  cursor:pointer;
}

.switchx input{
  position:absolute;
  opacity:0;
  pointer-events:none;
}

.switchx-ui{
  width:44px;
  height:26px;
  border-radius:999px;
  border:1px solid rgba(255,255,255,.18);
  background: rgba(255,255,255,.06);
  position:relative;
  transition: all .18s ease;
  flex: 0 0 auto;
}

.switchx-ui::after{
  content:"";
  position:absolute;
  top:3px;
  left:3px;
  width:20px;
  height:20px;
  border-radius:999px;
  background: rgba(255,255,255,.90);
  border:1px solid rgba(0,0,0,.20);
  box-shadow: 0 10px 22px rgba(0,0,0,.25);
  transition: all .18s ease;
}

.switchx-text{
  font-weight:800;
  font-size:13px;
  color: rgba(255,255,255,.92);
}

/* checked */
.switchx input:checked + .switchx-ui{
  background: var(--accent);
  border-color: transparent;
}
.switchx input:checked + .switchx-ui::after{
  transform: translateX(18px);
}

/* responsive */
@media (max-width: 900px){
  .token-row{ flex-direction:column; align-items:stretch; }
  .token-actions{ justify-content:flex-start; }
  .token-btn{ width: 100%; justify-content:center; }
}

label {
  margin-bottom: 0 !important;
}
.search-form {
    margin: 20px 0;
    padding: 10px 0;
}
.form-control {
    background-color: rgba(0, 0, 0, 0.1);
    color: #fff;
}
.btnx-dark {
    color: #fff;
}

.compare-row{display:flex;gap:14px;align-items:flex-start;flex-wrap:wrap;margin-top:16px}
.city-card{flex: 1;
    min-width: 320px;
    background: rgba(0, 0, 0, .1);
    border: 1px solid rgba(0, 0, 0, .12);
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 14px;
    background: rgba(255, 255, 255, .04);
    padding: 14px 14px;}
.city-card-head{padding:12px 14px;border-bottom:1px solid rgba(0,0,0,.08);display:flex;gap:10px;align-items:center;justify-content:space-between}
.city-title{font-weight:700}
.city-select{width:220px;max-width:100%;padding:8px 10px;border-radius:10px;color:#fff;border:1px solid #fff;background:rgba(0,0,0,.1)}
.city-body{padding:12px 14px}
.city-items{display:flex;flex-direction:column;gap:10px;max-height:520px;overflow:auto;padding-right:4px}
.item-row{display:flex;gap:10px;align-items:flex-start;justify-content:space-between;border:1px solid rgba(0,0,0,.08);border-radius:12px;padding:10px 12px}
.item-name{font-size:14px;line-height:1.25;max-width:72%}
.item-metrics{text-align:right;white-space:nowrap}
.badge{display:inline-flex;align-items:center;padding:4px 8px;border-radius:999px;border:1px solid rgba(0,0,0,.15);font-size:12px;opacity:.85}
.mono{font-variant-numeric:tabular-nums;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,"Liberation Mono","Courier New",monospace}

.city-footer{margin-top:12px;padding-top:12px;border-top:1px dashed rgba(0,0,0,.18);display:flex;justify-content:space-between;align-items:center}
.sum-big{font-weight:800;font-size:16px}
.muted{opacity:.75}

.tabs-row{display:flex;gap:8px;flex-wrap:wrap}
.tabx{display:inline-flex;align-items:center;gap:6px;padding:8px 12px;border:1px solid rgba(0,0,0,.12);border-radius:10px;text-decoration:none}
.tabx.active{background:var(--accent);color:#fff;border-color: transparent;box-shadow: 0 18px 40px rgba(79, 70, 229, .18);}
/* чтобы таблица не вылазила */
  .table-wrap{
    width:100%;
    overflow-x:auto;
    border-radius:14px;
    border:1px solid rgba(16,16,16,.10);
  }

  .products-table{
    min-width: 1200px; /* чтобы колонки не сжимались в кашу */
    width:100%;
    border-collapse:collapse;
  }

  .products-table th, .products-table td{
    white-space:nowrap;
    vertical-align:middle;
  }

  /* ширины полей */
  .w-price{ width:120px; }
  .w-min{ width:130px; }
  .w-max{ width:130px; }
  .w-step{ width:90px; }

  /* чтобы товар занимал место и переносился */
  .products-table td:first-child{
    white-space:normal;
    min-width: 360px;
  }

  .prod-title{
    font-weight:700;
    line-height:1.25;
  }
  .prod-sku{
    display:inline-block;
    margin-top:4px;
    font-size:12px;
    opacity:.8;
  }
.lang-btn{ padding:6px 10px; border:1px solid rgba(0,0,0,.15); border-radius:10px; }
.lang-btn.active{ background:#101010; color:#fff; }
.lang-switch{
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px;
  border-radius: 12px;
  background: rgba(0,0,0,0.04);
}

.lang-switch .btnx{
  padding: 6px 10px;
  line-height: 1;
  font-weight: 600;
  border-radius: 10px;
}

/* если хочешь подсветку активного языка */
.lang-switch .is-active{
  background: #101010;
  color: #ffffff;
  border-color: #101010;
}
.form-control:disabled, .form-control[readonly] {
  background:
        radial-gradient(1000px 600px at 15% 10%, rgba(79,70,229,.35), transparent 60%),
        radial-gradient(1000px 600px at 85% 20%, rgba(236,72,153,.25), transparent 55%),
        radial-gradient(1000px 700px at 65% 85%, rgba(34,197,94,.18), transparent 55%),
        linear-gradient(180deg, #07070b 0%, #07070b 60%, #050507 100%);
}
/* =========================================
   Laptop / smaller desktop responsive fixes
   ========================================= */

/* 1600 -> 1281 : чуть компактнее */
@media (max-width: 1600px){
  .main-container{
    padding: 18px 18px 10px 18px;
  }

  .products,
  .up-price,
  .analyze,
  #pills-tabContent{
    padding: 24px;
  }

  .sidebar-link{
    padding: 16px;
    font-size: 13px;
  }
}

/* Основной ноутбучный диапазон */
@media (max-width: 1440px){
  .app-sidebar{
    width: 224px;
    padding: 14px 10px;
  }

  .main-container{
    padding: 16px 16px 10px 16px;
  }

  .app-footer{
    padding: 12px 16px 18px 16px;
  }

  .products,
  .up-price,
  .analyze,
  #pills-tabContent,
  .settings-card,
  .panel,
  .stat-card,
  .token-form{
    padding: 18px;
  }

  .page-title,
  .h1{
    font-size: 20px;
  }

  .cards{
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .cards-row{
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .orders-grid{
    grid-template-columns: repeat(2, minmax(0,1fr));
  }

  .city-card{
    min-width: 280px;
  }

  .token-field{
    min-width: 220px;
  }
}

/* Маленькие ноутбуки: 1366x768, 1280x800 и подобные */
@media (max-width: 1366px){
  .app-sidebar{
    width: 208px;
    padding: 12px 8px;
  }

  .sidebar-logo{
    padding: 8px;
  }

  .sidebar-link{
    padding: 14px 12px;
    font-size: 13px;
    gap: 8px;
  }

  .sidebar-link span{
    line-height: 1.2;
  }

  .main-container{
    padding: 14px;
  }

  .products,
  .up-price,
  .analyze,
  #pills-tabContent{
    padding: 16px;
  }

  .page-head{
    gap: 12px;
    margin: 6px 0 14px;
  }

  .page-actions,
  .head-actions,
  .action-left,
  .action-right{
    gap: 8px;
  }

  .btnx{
    padding: 9px 10px;
    font-size: 13px;
  }

  .inputx,
  .selectx,
  .selectx-small,
  .price-input{
    font-size: 13px;
  }

  .cards,
  .cards-row,
  .orders-grid,
  .grid-2,
  .split{
    gap: 10px;
  }

  .compare-row{
    gap: 10px;
  }

  .city-card{
    min-width: 0;
    width: 100%;
  }

  .item-name{
    max-width: 65%;
  }

  /* Таблицы */
  .table-wrap{
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .products-table{
    min-width: 1040px;
  }

  .products-table td:first-child{
    min-width: 280px;
  }

  .w-price{ width: 100px; }
  .w-min{ width: 110px; }
  .w-max{ width: 110px; }
  .w-step{ width: 80px; }

  .inputx.w-price,
  .inputx.w-min{
    width: 100px;
    min-width: 100px;
  }

  .inputx.w-step{
    width: 72px;
    min-width: 72px;
  }
}

/* Планшет / очень узкий ноутбук */
@media (max-width: 1200px){
  .app-layout{
    flex-direction: column;
  }

  .app-sidebar{
    width: 100%;
    height: auto;
    position: relative;
    border-right: none;
    border-bottom: 1px solid var(--border);
    padding: 12px;
  }

  .sidebar-nav{
    display: grid;
    grid-template-columns: repeat(2, minmax(0,1fr));
    gap: 8px;
  }

  .sidebar-link{
    padding: 12px;
  }

  .main-container{
    padding: 12px;
  }

  .page-head{
    flex-direction: column;
    align-items: flex-start;
  }

  .page-actions,
  .head-actions{
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .cards,
  .cards-row,
  .orders-grid,
  .grid-2,
  .split{
    grid-template-columns: 1fr;
  }

  .form-grid{
    grid-template-columns: 1fr;
  }

  .token-row{
    flex-direction: column;
    align-items: stretch;
  }

  .token-field{
    min-width: 0;
  }

  .token-actions{
    justify-content: stretch;
  }

  .token-btn{
    width: 100%;
  }

  .bulk-bar,
  .action-bar,
  .notice{
    flex-direction: column;
    align-items: flex-start;
  }

  .bulk-bar > *,
  .action-bar > *,
  .notice > *{
    width: 100%;
  }
}

/* Телефоны */
@media (max-width: 768px){
  .sidebar-nav{
    grid-template-columns: 1fr;
  }

  .main-container{
    padding: 10px;
  }

  .products,
  .up-price,
  .analyze,
  #pills-tabContent,
  .settings-card,
  .panel,
  .stat-card,
  .token-form{
    padding: 14px;
    border-radius: 14px;
  }

  .page-title,
  .h1{
    font-size: 18px;
  }

  .btnx,
  .selectx,
  .price-input,
  .inputx{
    width: 100%;
    max-width: 100%;
  }

  .products-table{
    min-width: 960px;
  }

  .products-table td:first-child{
    min-width: 240px;
  }

  .ellipsis{
    max-width: 180px;
  }
}
