*{box-sizing:border-box}body{margin:0;background:#f4f6fa;color:#182230;font:14px/1.5 Arial,sans-serif}.layout{min-height:100vh;display:flex}.sidebar{width:245px;background:#142238;color:#fff;padding:25px 16px;display:flex;flex-direction:column;flex-shrink:0}.brand{display:flex;align-items:center;gap:11px;padding:0 10px 34px}.brand-mark{width:38px;height:38px;border-radius:12px;background:#1c9b83;display:grid;place-items:center;font-weight:bold;font-size:22px}.brand b{display:block;letter-spacing:1.3px}.brand small{color:#9eafc4}.sidebar nav{display:grid;gap:7px}.nav{border:0;background:transparent;color:#c5d0df;text-align:left;padding:12px 14px;border-radius:9px;cursor:pointer;font-size:14px}.nav span{margin-left:8px}.nav.active,.nav:hover{background:#213b59;color:#fff}.sidebar-foot{margin-top:auto;color:#8092aa;font-size:10px;padding:20px 9px}.main{flex:1;min-width:0;padding:28px 34px;max-width:1600px;margin:auto;width:100%}.topbar{display:flex;align-items:center;justify-content:space-between;margin-bottom:24px}.eyebrow{font-size:10px;letter-spacing:1.7px;color:#718096;font-weight:bold}.topbar h1{font-size:26px;margin:3px 0 0}.top-actions{display:flex;align-items:center;gap:14px}select,input{font:inherit;border:1px solid #dbe2ea;border-radius:8px;padding:10px;background:#fff;color:#243247;min-width:0}.avatar{width:36px;height:36px;border-radius:50%;background:#d8f0e9;color:#147c69;display:grid;place-items:center;font-weight:bold}.page{display:none}.page.active{display:block}.welcome{background:linear-gradient(115deg,#15334c,#176c68);color:white;border-radius:16px;padding:27px 32px;display:flex;justify-content:space-between;align-items:center;min-height:170px}.welcome h2{font-size:25px;margin:8px 0}.welcome p{color:#d2e5e4;margin:0}.light{color:#a6dcd1}.welcome-icon{font-size:70px;opacity:.35;margin-right:20px}.stats{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:20px 0}.stat,.panel{background:#fff;border:1px solid #e6ebf1;border-radius:13px;box-shadow:0 3px 12px #23354a08}.stat{padding:19px}.stat span,.stat small{display:block;color:#738196}.stat b{font-size:29px;display:block;margin:7px 0}.stat small{font-size:11px}.panel{padding:22px;margin-bottom:18px}.panel-head{display:flex;justify-content:space-between;align-items:center;gap:16px;margin-bottom:18px}.panel h3{margin:0;font-size:17px}.panel-head p{margin:4px 0 0;color:#7b8797;font-size:12px}.primary,.secondary{border:0;border-radius:8px;padding:10px 15px;cursor:pointer;font-weight:bold}.primary{background:#168875;color:white}.primary:hover{background:#116f61}.secondary{background:#edf1f5;color:#344256}.toolbar{display:flex;gap:10px;margin:15px 0}.toolbar input{flex:1}.table-wrap{overflow:auto}table{border-collapse:collapse;width:100%;min-width:650px}th,td{text-align:left;padding:12px 13px;border-bottom:1px solid #edf0f4}th{font-size:11px;text-transform:uppercase;letter-spacing:.5px;color:#78869a;background:#fafbfd}td{font-size:13px}.empty{padding:28px;text-align:center;color:#8793a3}.notice{background:#fff8e8;color:#88651a;padding:12px 15px;border-radius:9px;font-size:12px}.cards{display:grid;grid-template-columns:repeat(auto-fill,minmax(220px,1fr));gap:13px}.warehouse-card{border:1px solid #e4eaf0;border-radius:10px;padding:17px}.warehouse-card b{display:block;font-size:15px}.warehouse-card small{color:#8491a1}.form-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin:18px 0 25px}.form-grid label,#dialog-label{display:grid;gap:6px;color:#58677a;font-size:12px;font-weight:bold}.form-grid .wide{grid-column:1/-1}.form-actions{display:flex;align-items:center;gap:12px}.form-actions span{color:#168875;font-size:12px}.dialog-actions{display:flex;justify-content:flex-end;gap:9px;margin-top:20px}dialog{border:0;border-radius:14px;padding:24px;width:min(420px,calc(100% - 30px));box-shadow:0 20px 70px #0003}dialog::backdrop{background:#10203380}dialog h3{margin:0 0 18px}#dialog-label input{width:100%}@media(max-width:900px){.sidebar{width:190px}.main{padding:20px}.stats{grid-template-columns:repeat(2,1fr)}.form-grid{grid-template-columns:repeat(2,1fr)}}@media(max-width:620px){.layout{display:block}.sidebar{width:100%;padding:13px}.brand{padding-bottom:12px}.sidebar nav{grid-template-columns:repeat(3,1fr)}.nav{padding:9px 5px;font-size:12px}.sidebar-foot{display:none}.main{padding:16px}.topbar h1{font-size:21px}.welcome{padding:20px}.welcome h2{font-size:20px}.stats{gap:9px}.stat{padding:13px}.stat b{font-size:23px}.form-grid{grid-template-columns:1fr}.form-grid .wide{grid-column:auto}.panel{padding:15px}.panel-head{align-items:flex-start;flex-direction:column}}/* Login vaqtida asosiy dasturni yashirish */
.layout {
  display: none;
}

.login-screen {
  display: flex;
}

.login-screen[style*="display: none"] {
  display: none !important;
}

/* SALOMATLIK ONLINE - YANGI LOGIN DIZAYNI */

.login-screen {
  min-height: 100vh;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 25px;
  box-sizing: border-box;
  background: linear-gradient(135deg, #102b3f, #174b60, #102b3f);
  font-family: Arial, sans-serif;
}

.login-screen[style*="display: none"] {
  display: none !important;
}

.login-box {
  width: 100%;
  max-width: 430px;
  padding: 42px 38px;
  box-sizing: border-box;
  background: #ffffff;
  border-radius: 22px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
  text-align: center;
}

.brand-mark {
  width: 65px;
  height: 65px;
  margin: 0 auto 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  background: #176b59;
  color: #ffffff;
  font-size: 36px;
  font-weight: 800;
}

.login-box h2 {
  margin: 0;
  color: #18364a;
  font-size: 25px;
  font-weight: 800;
  letter-spacing: 1px;
}

.brand-subtitle {
  margin-top: 9px;
  color: #8294a0;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
}

.login-divider {
  height: 1px;
  background: #e8edf0;
  margin: 25px 0;
}

.login-box h3 {
  margin: 0 0 9px;
  color: #18364a;
  font-size: 23px;
}

.login-box p {
  margin: 0 0 27px;
  color: #718391;
  font-size: 13px;
  line-height: 1.6;
}

.login-box form {
  text-align: left;
}

.login-box label {
  display: block;
  margin-bottom: 18px;
  color: #294457;
  font-size: 13px;
  font-weight: 600;
}

.login-box input {
  width: 100%;
  margin-top: 8px;
  padding: 14px;
  box-sizing: border-box;
  border: 1px solid #dce5eb;
  border-radius: 10px;
  background: #ffffff;
  color: #18364a;
  font-size: 14px;
  outline: none;
}

.login-box input:focus {
  border-color: #176b59;
  box-shadow: 0 0 0 3px rgba(23, 107, 89, 0.10);
}

.login-box button.primary {
  width: 100%;
  min-height: 48px;
  margin-top: 8px;
  border: none;
  border-radius: 10px;
  background: #176b59;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.8px;
  cursor: pointer;
transition: background 0.2s ease, transform 0.2s ease;
}

.login-box button.primary:hover {
  background: #125443;
  transform: translateY(-1px);
}

.login-footer {
  margin-top: 28px;
  color: #9aa8b1;
  font-size: 10px;
  letter-spacing: 0.5px;
}

.login-error {
  margin-top: 12px;
}

@media (max-width: 480px) {
  .login-box {
    padding: 32px 23px;
  }

  .login-box h2 {
    font-size: 21px;
  }
}
/* Mahsulot tahrirlash tugmasi — yashil */
button.success {
  background: #198754 !important;
  background-color: #198754 !important;
  color: white !important;
  border: none;
  border-radius: 6px;
  padding: 8px 12px;
  cursor: pointer;
}

button.success:hover {
  background: #146c43 !important;
}

/* Mahsulot o‘chirish tugmasi — qizil */
button.danger {
  background: #dc3545 !important;
  background-color: #dc3545 !important;
  color: white !important;
  border: none;
  border-radius: 6px;
  padding: 8px 12px;
  cursor: pointer;
}

button.danger:hover {
  background: #b02a37 !important;
}
#materials-table button.success {
  background: #198754 !important;
  background-color: #198754 !important;
  color: #ffffff !important;
  border: 1px solid #198754 !important;
}
/* Yashil tugma hover effekti */
#materials-table button.success:hover {
  background: #146c43 !important;
  transition: background 0.2s ease;
}

/* Qizil tugma hover effekti */
#materials-table button.danger:hover {
  background: #b02a37 !important;
  transition: background 0.2s ease;
}#materials-table button.danger {
  transition: background-color 0.2s ease;
}

#materials-table button.danger:hover {
  background-color: #b02a37 !important;
  background: #b02a37 !important;
}
/* SALOMATLIK ONLINE — tasdiqlash oynasi */
.confirm-dialog {
  border: none;
  border-radius: 16px;
  padding: 0;
  width: min(420px, calc(100% - 32px));
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
  background: #ffffff;
  color: #222222;
}

.confirm-dialog::backdrop {
  background: rgba(15, 23, 42, 0.6);
}

.confirm-dialog-content {
  padding: 28px;
  text-align: center;
}

.confirm-dialog-icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: #e8f3ed;
  color: #198754;
  font-size: 30px;
  font-weight: bold;
  line-height: 48px;
}

.confirm-dialog-content h3 {
  margin: 0 0 12px;
  font-size: 20px;
  color: #222222;
}

.confirm-dialog-content p {
  margin: 0 0 24px;
  color: #555555;
  line-height: 1.5;
}

.confirm-dialog-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
}

.confirm-dialog-actions button {
  border: none !important;
  border-radius: 7px !important;
  padding: 10px 18px !important;
  color: #ffffff !important;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
}

.confirm-dialog-actions .confirm-cancel {
  background: #dc3545 !important;
}

.confirm-dialog-actions .confirm-cancel:hover {
  background: #b02a37 !important;
}

.confirm-dialog-actions .confirm-ok {
  background: #198754 !important;
}

.confirm-dialog-actions .confirm-ok:hover {
  background: #146c43 !important;
}