@font-face {
  font-family: Vazirmatn;
  src: url("/Vazirmatn.woff2") format("woff2");
  font-display: swap;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: #f2f5f9;
  color: #152c42;
  font:
    16px Vazirmatn,
    Tahoma,
    Arial,
    sans-serif;
}
button,
input,
select {
  font: inherit;
}
button {
  cursor: pointer;
  transition: background 0.15s;
}
button:disabled {
  cursor: wait;
  opacity: 0.6;
}
button,
input,
select {
  min-height: 44px;
  border-radius: 8px;
}
button {
  border: 0;
  padding: 9px 18px;
}
input,
select {
  background: #fff;
  border: 1px solid #ccd5df;
  color: #152c42;
  padding: 9px 12px;
  width: 100%;
  margin-top: 7px;
}
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='m1 1 5 5 5-5' stroke='%23334860' fill='none' stroke-width='1.5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: 12px center;
  padding-left: 32px;
}
label {
  font-size: 14px;
  color: #42566c;
}
button:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid #d99528;
  outline-offset: 3px;
}
.primary {
  background: #0b645f;
  color: #fff;
  font-weight: 700;
}
.primary:hover {
  background: #084f4b;
}
.quiet {
  background: #edf2f6;
  color: #25445b;
  border: 1px solid #dce4eb;
}
.quiet:hover {
  background: #dfe9ee;
}
.muted {
  color: #5a6c7f;
}
.error {
  color: #a32c25;
}
.error:empty {
  display: none;
}
.eyebrow {
  font:
    11px Arial,
    sans-serif;
  letter-spacing: 2.2px;
  color: #526f81;
  font-weight: 700;
}
.wordmark {
  font-size: 30px;
  font-weight: bold;
  letter-spacing: -1px;
}
.wordmark span {
  font: 16px Arial;
  letter-spacing: 1px;
  color: #70c7be;
  margin-right: 8px;
}
.login-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  background: #fff;
}
.login-story {
  background: #112f41;
  color: #fff;
  padding: 10vh 10%;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.login-story h1 {
  font-size: clamp(32px, 4vw, 58px);
  line-height: 1.6;
  margin: 32px 0 12px;
}
.login-story p {
  line-height: 2;
  color: #c0d2db;
}
.login-story .eyebrow {
  color: #94c3ca;
}
.login-story small {
  margin-top: 65px;
  color: #c0d2db;
}
.road-art {
  position: absolute;
  left: -160px;
  bottom: 30px;
  width: 400px;
  height: 600px;
  transform: rotate(35deg);
  opacity: 0.14;
}
.road-art span {
  position: absolute;
  inset: 0;
  border: 1px solid #79d1c6;
  border-radius: 180px;
}
.road-art span:nth-child(2) {
  inset: 40px;
}
.road-art span:nth-child(3) {
  inset: 80px;
}
.login-box {
  width: min(430px, 85%);
  margin: auto;
  padding: 60px 0;
}
.login-box h2 {
  font-size: 24px;
  margin-top: 48px;
}
.login-box p {
  line-height: 1.9;
}
.login-box label {
  display: block;
  margin: 24px 0;
}
.login-box form button {
  width: 100%;
  margin-bottom: 24px;
}
.login-box small {
  line-height: 2;
  display: block;
}
#dashboard {
  display: grid;
  grid-template-columns: 236px minmax(0, 1fr);
}
[hidden] {
  display: none !important;
}
.sidebar {
  background: #112f41;
  color: #fff;
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 32px 22px;
  display: flex;
  flex-direction: column;
}
.brand-caption {
  font-size: 13px;
  color: #c2d0da;
  margin-top: 6px;
}
.nav-label {
  font-size: 12px;
  color: #a0b7c5;
  margin: 52px 12px 12px;
}
nav {
  display: grid;
  gap: 8px;
}
nav button {
  text-align: right;
  background: transparent;
  color: #bfd0da;
  padding: 13px 14px;
  font-size: 15px;
}
nav button.active {
  background: #26505e;
  color: white;
}
nav button:hover {
  background: #204656;
}
.nav-icon {
  display: inline-block;
  width: 27px;
  font: 22px Arial;
  vertical-align: middle;
}
.sidebar-bottom {
  margin-top: auto;
  border-top: 1px solid #325061;
  padding-top: 24px;
}
.sidebar-bottom .eyebrow {
  color: #8ebbbf;
}
.sidebar-bottom p {
  line-height: 1.9;
  font-size: 14px;
}
.sidebar-bottom small {
  color: #a6bdca;
  font-size: 12px;
}
main {
  padding: 32px 36px;
  min-width: 0;
  max-width: 1900px;
  width: 100%;
  margin: auto;
}
header {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 24px;
}
header h1 {
  font-size: 28px;
  margin: 9px 0;
}
header p {
  font-size: 14px;
  margin: 0;
}
.header-actions {
  display: flex;
  gap: 15px;
  align-items: center;
  font-size: 14px;
}
.source-banner {
  background: #fff5dd;
  color: #765018;
  border: 1px solid #e7d4a6;
  padding: 12px 16px;
  border-radius: 9px;
  font-size: 14px;
  line-height: 1.8;
  margin-bottom: 20px;
}
.source-banner.live {
  background: #e7f4ef;
  color: #17584c;
  border-color: #b8d7cd;
}
.filter-panel {
  display: grid;
  grid-template-columns: 1fr 1fr 1.25fr 1fr auto;
  gap: 16px;
  background: #fff;
  border: 1px solid #dfe6ec;
  padding: 20px;
  border-radius: 12px;
  align-items: end;
}
.filter-panel input {
  direction: ltr;
  text-align: center;
}
.report-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 20px 0;
  color: #5a6c7f;
  font-size: 12px;
  gap: 12px;
}
.report-toolbar > div {
  display: flex;
  align-items: center;
  gap: 15px;
}
.report-toolbar button {
  font-size: 13px;
  min-height: 36px;
}
.switch {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}
.switch input {
  width: 16px;
  min-height: 16px;
  margin: 0;
  accent-color: #0b645f;
}
.kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 22px;
}
.kpi {
  background: white;
  border: 1px solid #dfe6ec;
  border-radius: 12px;
  padding: 19px 22px;
  position: relative;
}
.kpi .label {
  font-size: 14px;
  color: #546a7e;
}
.kpi strong {
  font-size: 27px;
  font-weight: 700;
  display: block;
  margin: 15px 0 8px;
  font-variant-numeric: tabular-nums;
  direction: ltr;
  text-align: right;
  letter-spacing: -0.5px;
}
.kpi small {
  color: #697b8c;
  font-size: 12px;
}
.kpi.accent {
  background: #0f5d59;
  color: #fff;
  border-color: #0f5d59;
}
.kpi.accent .label,
.kpi.accent small {
  color: #d1e9e4;
}
.card {
  background: white;
  border: 1px solid #dfe6ec;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 22px;
  min-width: 0;
}
.card-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
  margin-bottom: 20px;
}
.card h2 {
  font-size: 17px;
  margin: 0 0 5px;
}
.card p {
  font-size: 12px;
  color: #60758a;
  margin: 0;
  line-height: 1.9;
}
.chart-grid {
  display: grid;
  grid-template-columns: 1.65fr 1fr;
  gap: 20px;
}
.legend {
  font-size: 12px;
  white-space: nowrap;
  color: #5a6c7f;
}
.legend i {
  display: inline-block;
  width: 8px;
  height: 8px;
  background: #17776d;
  border-radius: 50%;
  margin-left: 6px;
}
.chart {
  height: 230px;
  width: 100%;
}
.chart svg {
  width: 100%;
  height: 100%;
  overflow: visible;
}
.bars {
  display: grid;
  gap: 22px;
  padding-top: 10px;
}
.bar-label {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 9px;
  gap: 10px;
}
.bar-track {
  height: 9px;
  background: #edf3f5;
  border-radius: 3px;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  background: #217b73;
  border-radius: 3px;
  transform-origin: right;
}
.bar-row:nth-child(2n) .bar-fill {
  background: #d09b44;
}
.table-wrap {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  white-space: nowrap;
  font-size: 14px;
}
th {
  text-align: right;
  background: #f5f8fa;
  color: #566e81;
  font-weight: 500;
  padding: 13px 14px;
  font-size: 12px;
}
td {
  padding: 16px 14px;
  border-bottom: 1px solid #edf1f4;
  font-variant-numeric: tabular-nums;
}
tbody tr:hover {
  background: #f5faf9;
}
tbody tr:last-child td {
  border-bottom: 0;
}
.driver-link {
  background: none;
  padding: 0;
  min-height: 30px;
  color: #0b645f;
  text-decoration: underline;
  text-underline-offset: 4px;
  font-weight: 700;
}
.number {
  direction: ltr;
  text-align: right;
}
.pill {
  background: #e8f4ef;
  color: #1d6959;
  padding: 4px 10px;
  border-radius: 5px;
  font-size: 12px;
}
.driver-filters {
  display: grid;
  grid-template-columns: 1.4fr 1.2fr 1fr 1fr 1.2fr;
  gap: 14px;
  margin: 24px 0;
}
.detail {
  border-top: 3px solid #16766c;
}
.note {
  margin-top: 20px !important;
}
.fleet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 20px;
}
.fleet-grid .card {
  border-top: 3px solid #0b645f;
}
.fleet-grid h3 {
  margin-top: 0;
}
.fleet-grid strong {
  font-size: 28px;
  display: block;
  margin: 20px 0 4px;
}
.fleet-grid dl {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px;
  font-size: 14px;
  border-top: 1px solid #e7edf1;
  padding-top: 20px;
}
.fleet-grid dd {
  margin: 0;
  direction: ltr;
}
footer {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  font-size: 12px;
  color: #60758a;
  line-height: 2;
  padding: 8px;
}
.empty {
  padding: 36px;
  color: #60758a;
  text-align: center;
}
.metric-note {
  color: #9a561b;
}
@media (min-width: 1500px) {
  main {
    padding: 40px 48px;
  }
  .kpi strong {
    font-size: 32px;
  }
  .chart {
    height: 280px;
  }
}
@media (max-width: 1150px) {
  #dashboard {
    grid-template-columns: 190px minmax(0, 1fr);
  }
  main {
    padding: 24px;
  }
  .sidebar {
    padding: 28px 14px;
  }
  .filter-panel {
    grid-template-columns: 1fr 1fr;
  }
  .filter-panel button {
    grid-column: 1/-1;
  }
  .chart-grid {
    grid-template-columns: 1fr;
  }
  .driver-filters {
    grid-template-columns: 1fr 1fr;
  }
  .kpi strong {
    font-size: 22px;
  }
  .kpi {
    padding: 16px;
  }
  .fleet-grid {
    grid-template-columns: 1fr 1fr;
  }
  .report-toolbar {
    align-items: start;
    flex-direction: column;
  }
}
@media (max-width: 720px) {
  .login-screen {
    grid-template-columns: 1fr;
  }
  .login-story {
    display: none;
  }
  #dashboard {
    display: block;
  }
  .sidebar {
    position: relative;
    height: auto;
    padding: 16px 20px;
  }
  .sidebar .wordmark {
    font-size: 24px;
  }
  .sidebar nav {
    display: flex;
    overflow: auto;
    margin-top: 12px;
    gap: 5px;
  }
  .sidebar nav button {
    font-size: 12px;
    white-space: nowrap;
    padding: 10px;
  }
  .nav-label,
  .brand-caption,
  .sidebar-bottom,
  .nav-icon {
    display: none;
  }
  .sidebar .wordmark span {
    font-size: 14px;
  }
  main {
    padding: 22px 16px;
  }
  header h1 {
    font-size: 24px;
  }
  header .eyebrow {
    font-size: 9px;
  }
  header p {
    display: none;
  }
  .header-actions {
    gap: 8px;
  }
  .header-actions > span {
    display: none;
  }
  .filter-panel {
    padding: 16px;
    gap: 12px;
  }
  .kpis {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  .kpi {
    padding: 16px 12px;
  }
  .kpi strong {
    font-size: 22px;
  }
  .kpi .label {
    font-size: 12px;
  }
  .card {
    padding: 18px;
  }
  .card-heading {
    align-items: flex-start;
  }
  .legend {
    display: none;
  }
  .report-toolbar > div {
    flex-wrap: wrap;
    gap: 10px;
  }
  .driver-filters {
    grid-template-columns: 1fr 1fr;
  }
  .fleet-grid {
    grid-template-columns: 1fr;
  }
  footer {
    display: block;
  }
  footer span {
    display: block;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.company-logo {
  display: block;
  background: white;
  border-radius: 6px;
  object-fit: contain;
  width: 112px;
  height: 58px;
  padding: 4px;
  margin-bottom: 18px;
}
.login-logo {
  float: left;
  width: 94px;
  height: 52px;
  margin: 0;
}
.nav-icon {
  width: 20px;
  height: 20px;
  margin-left: 10px;
}
.sidebar-bottom .company-logo {
  width: 105px;
}
.kpi {
  min-width: 0;
}
@media (max-width: 720px) {
  .kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .kpi strong {
    font-size: clamp(15px, 4vw, 22px);
    letter-spacing: -0.7px;
    white-space: nowrap;
  }
  .filter-panel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .filter-panel input,
  .filter-panel select {
    min-width: 0;
  }
  .fleet-grid strong {
    font-size: 24px;
  }
}
