:root {
  --ink: #102025;
  --muted: #66757a;
  --paper: #fbfaf7;
  --line: #e3ded6;
  --green: #2f8f5b;
  --teal: #12343b;
  --coral: #e85d3f;
  --yellow: #f7c948;
  --blue: #2f6f9f;
  --white: #ffffff;
  --shadow: 0 18px 48px rgba(16, 32, 37, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--paper);
}

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

button,
input,
select {
  font: inherit;
}

main {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 20px;
  align-items: center;
  padding: 14px max(16px, calc((100vw - 1180px) / 2));
  background: rgba(251, 250, 247, 0.92);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 180px;
}

.brand-mark,
.panel-icon,
.avatar {
  display: inline-grid;
  place-items: center;
  color: var(--white);
  background: var(--teal);
  font-weight: 800;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
}

.brand small,
.site-footer span,
.catalog-title p,
.vehicle-card p,
.job-card span,
.queue-box span,
.feature-strip span {
  display: block;
  color: var(--muted);
}

.main-nav {
  display: flex;
  justify-content: center;
  gap: 6px;
  flex-wrap: wrap;
}

.main-nav a,
.cart-pill,
.chip {
  border: 1px solid var(--line);
  background: var(--white);
  border-radius: 8px;
  padding: 9px 12px;
  font-weight: 700;
  color: #334044;
}

.main-nav a.active,
.chip.active {
  border-color: var(--teal);
  background: var(--teal);
  color: var(--white);
}

.cart-pill span {
  display: inline-grid;
  place-items: center;
  min-width: 24px;
  height: 24px;
  margin-left: 6px;
  border-radius: 999px;
  background: var(--coral);
  color: var(--white);
}

.hero-shell {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(360px, 1.05fr);
  gap: 36px;
  align-items: center;
  padding: 46px 0 38px;
}

.hero-copy h1,
.page-heading h1 {
  margin: 0;
  line-height: 1.02;
  letter-spacing: 0;
}

.hero-copy h1 {
  font-size: clamp(42px, 7vw, 78px);
}

.hero-copy p {
  color: #46565b;
  font-size: 18px;
  line-height: 1.55;
  max-width: 640px;
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--coral);
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0;
}

.hero-actions,
.inline-actions,
.job-actions,
.footer-links,
.filter-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.button,
.wallet-card button,
.menu-list button {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  min-height: 44px;
  border: 0;
  border-radius: 8px;
  padding: 0 16px;
  font-weight: 850;
  cursor: pointer;
}

.button.primary {
  color: var(--white);
  background: var(--green);
}

.button.secondary {
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--line);
}

.button.dark {
  color: var(--white);
  background: var(--teal);
}

.button.danger {
  color: var(--white);
  background: var(--coral);
}

.button.full {
  width: 100%;
}

.button:disabled {
  opacity: 0.48;
  cursor: not-allowed;
}

.live-map {
  position: relative;
  min-height: 380px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:
    radial-gradient(circle at 18% 28%, rgba(247, 201, 72, 0.28), transparent 20%),
    radial-gradient(circle at 78% 68%, rgba(232, 93, 63, 0.25), transparent 22%),
    linear-gradient(135deg, #eef4ec, #f8efe6 50%, #e9f0f5);
  box-shadow: var(--shadow);
}

.live-map.tall {
  min-height: 520px;
}

.map-grid {
  position: absolute;
  inset: 0;
  opacity: 0.45;
  background-image:
    linear-gradient(rgba(18, 52, 59, 0.12) 1px, transparent 1px),
    linear-gradient(90deg, rgba(18, 52, 59, 0.12) 1px, transparent 1px);
  background-size: 46px 46px;
}

.pin,
.heat {
  position: absolute;
  z-index: 2;
  border-radius: 999px;
  padding: 8px 11px;
  color: var(--white);
  font-weight: 850;
  box-shadow: 0 10px 24px rgba(16, 32, 37, 0.2);
}

.pin-a {
  left: 13%;
  top: 22%;
  background: var(--blue);
}

.pin-b {
  left: 52%;
  top: 48%;
  background: var(--coral);
}

.pin-c {
  right: 12%;
  bottom: 20%;
  background: var(--green);
}

.route-line {
  position: absolute;
  left: 18%;
  top: 32%;
  width: 62%;
  height: 38%;
  border-right: 7px solid rgba(18, 52, 59, 0.72);
  border-bottom: 7px solid rgba(18, 52, 59, 0.72);
  transform: skew(-18deg);
  border-radius: 0 0 80px 0;
}

.service-grid,
.vehicle-grid,
.catalog-grid,
.admin-grid,
.support-grid,
.feature-strip {
  display: grid;
  gap: 18px;
}

.service-grid {
  grid-template-columns: repeat(3, 1fr);
  margin: 34px 0;
}

.service-panel,
.booking-card,
.vehicle-card,
.catalog-card,
.compact-band,
.table-card {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 10px 28px rgba(16, 32, 37, 0.06);
}

.service-panel {
  padding: 22px;
}

.panel-icon {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  margin-bottom: 18px;
  background: var(--green);
}

.service-panel:nth-child(2) .panel-icon {
  background: var(--coral);
}

.service-panel:nth-child(3) .panel-icon {
  background: var(--blue);
}

.service-panel h2,
.booking-card h2,
.vehicle-card h2,
.catalog-card h2,
.compact-band h2,
.feature-strip strong {
  margin: 0 0 8px;
}

.service-panel p,
.compact-band p,
.support-grid p {
  color: var(--muted);
  line-height: 1.55;
}

.service-panel a {
  font-weight: 850;
  color: var(--green);
}

.compact-band {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin: 34px 0;
  padding: 24px;
  background: #edf3ef;
}

.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: end;
  margin: 34px 0 22px;
}

.page-heading h1 {
  max-width: 850px;
  font-size: clamp(32px, 5vw, 58px);
}

.split-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.85fr) minmax(0, 1.15fr);
  gap: 20px;
  align-items: start;
}

.booking-card {
  padding: 22px;
}

.booking-card label,
.document-list label,
.driver-sidebar label {
  display: grid;
  gap: 7px;
  margin-bottom: 14px;
  font-weight: 800;
}

input,
select {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
  background: var(--white);
  color: var(--ink);
}

.two-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.estimate-box,
.pin-code,
.receipt {
  display: grid;
  gap: 6px;
  margin: 16px 0;
  padding: 16px;
  border-radius: 8px;
  background: #f5f0e7;
}

.estimate-box strong,
.pin-code strong {
  font-size: 34px;
}

.estimate-box small,
.pin-code span {
  color: var(--muted);
}

.map-panel {
  display: grid;
  gap: 14px;
}

.safety-row,
.receipt div,
.cart-list li,
.download-list li,
.table-heading,
.driver-card {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.safety-row {
  grid-template-columns: repeat(3, 1fr);
}

.safety-row div {
  flex: 1;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.safety-row span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.vehicle-grid {
  grid-template-columns: repeat(5, 1fr);
  margin: 20px 0 40px;
}

.vehicle-card {
  padding: 18px;
}

.vehicle-card dl {
  display: grid;
  gap: 8px;
  margin: 16px 0 0;
}

.vehicle-card dl div {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.vehicle-card dt {
  color: var(--muted);
}

.vehicle-card dd {
  margin: 0;
  font-weight: 850;
}

.filter-row {
  margin-bottom: 18px;
}

.link-chip {
  margin-left: auto;
}

.catalog-grid {
  grid-template-columns: repeat(3, 1fr);
}

.catalog-card {
  overflow: hidden;
}

.store-visual {
  display: grid;
  place-items: center;
  min-height: 150px;
  color: var(--white);
  font-size: 42px;
  font-weight: 900;
}

.restaurant-visual {
  background:
    linear-gradient(45deg, rgba(16, 32, 37, 0.22), transparent),
    repeating-linear-gradient(135deg, #e85d3f 0 18px, #f7c948 18px 36px, #2f8f5b 36px 54px);
}

.grocery-visual {
  background:
    linear-gradient(45deg, rgba(16, 32, 37, 0.22), transparent),
    repeating-linear-gradient(135deg, #2f8f5b 0 18px, #2f6f9f 18px 36px, #f7c948 36px 54px);
}

.catalog-body {
  padding: 18px;
}

.catalog-title {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 14px;
}

.menu-list,
.cart-list,
.download-list {
  list-style: none;
  display: grid;
  gap: 10px;
  margin: 0;
  padding: 0;
}

.menu-list li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.menu-list button {
  background: #edf3ef;
  color: var(--green);
}

.cart-list li,
.download-list li {
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.cart-list span {
  display: block;
  color: var(--muted);
}

.empty-state {
  color: var(--muted);
}

.timeline {
  counter-reset: step;
  display: grid;
  gap: 12px;
  margin: 0 0 18px;
  padding: 0;
  list-style: none;
}

.timeline li {
  position: relative;
  padding: 13px 14px 13px 46px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--muted);
}

.timeline li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 12px;
  top: 10px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: #e9e5dc;
  color: var(--ink);
  font-size: 12px;
  font-weight: 850;
}

.timeline li.done {
  color: var(--ink);
  border-color: rgba(47, 143, 91, 0.45);
  background: #edf7f0;
}

.timeline li.done::before {
  content: "OK";
  background: var(--green);
  color: var(--white);
}

.avatar {
  width: 56px;
  height: 56px;
  border-radius: 8px;
  font-size: 26px;
}

.driver-card {
  justify-content: start;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.driver-dashboard {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr) 280px;
  gap: 18px;
  align-items: start;
}

.driver-sidebar,
.job-stack {
  display: grid;
  gap: 14px;
}

.driver-sidebar {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.driver-sidebar label {
  grid-template-columns: 20px 1fr;
  align-items: center;
  font-weight: 750;
}

.driver-sidebar input {
  min-height: auto;
}

.online-toggle {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--teal);
  color: var(--white);
  font-weight: 850;
}

.online-toggle input {
  width: 18px;
  min-height: 18px;
}

.wallet-card,
.queue-box {
  display: grid;
  gap: 8px;
  padding: 16px;
  border-radius: 8px;
  background: #f5f0e7;
}

.wallet-card strong {
  font-size: 28px;
}

.wallet-card button {
  background: var(--teal);
  color: var(--white);
}

.job-card {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.job-card h3 {
  margin: 0 0 6px;
}

.surge-map {
  position: relative;
  min-height: 220px;
  border-radius: 8px;
  overflow: hidden;
  background:
    radial-gradient(circle at 22% 25%, rgba(247, 201, 72, 0.72), transparent 26%),
    radial-gradient(circle at 70% 40%, rgba(232, 93, 63, 0.72), transparent 25%),
    linear-gradient(135deg, #e7ede9, #f5ece3);
}

.heat-a {
  top: 20%;
  left: 18%;
  background: var(--yellow);
  color: var(--ink);
}

.heat-b {
  top: 42%;
  right: 18%;
  background: var(--coral);
}

.heat-c {
  bottom: 18%;
  left: 34%;
  background: var(--blue);
}

.feature-strip {
  grid-template-columns: repeat(4, 1fr);
  margin: 22px 0 40px;
}

.feature-strip article {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--white);
}

.admin-grid,
.support-grid {
  grid-template-columns: repeat(2, 1fr);
  margin-bottom: 20px;
}

.support-grid {
  grid-template-columns: repeat(3, 1fr);
}

.document-list input[type="file"] {
  padding-top: 10px;
}

.table-card {
  margin-bottom: 42px;
}

.responsive-table {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 14px;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--muted);
  font-size: 13px;
}

.chat-box {
  display: grid;
  gap: 10px;
  max-height: 240px;
  overflow: auto;
  margin-bottom: 14px;
  padding: 14px;
  border-radius: 8px;
  background: #f5f0e7;
}

.chat-box p {
  margin: 0;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-top: 34px;
  padding: 24px max(16px, calc((100vw - 1180px) / 2));
  border-top: 1px solid var(--line);
}

@media (max-width: 980px) {
  .topbar {
    grid-template-columns: 1fr;
  }

  .main-nav {
    justify-content: start;
    overflow-x: auto;
    flex-wrap: nowrap;
  }

  .hero-shell,
  .split-layout,
  .driver-dashboard,
  .admin-grid,
  .support-grid {
    grid-template-columns: 1fr;
  }

  .service-grid,
  .vehicle-grid,
  .catalog-grid,
  .feature-strip {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  main {
    width: min(100% - 22px, 1180px);
  }

  .hero-shell {
    min-height: auto;
    padding-top: 24px;
  }

  .hero-copy h1,
  .page-heading h1 {
    font-size: 34px;
  }

  .page-heading,
  .compact-band,
  .site-footer,
  .job-card,
  .safety-row {
    display: grid;
    align-items: stretch;
  }

  .service-grid,
  .vehicle-grid,
  .catalog-grid,
  .feature-strip,
  .two-cols {
    grid-template-columns: 1fr;
  }

  .live-map,
  .live-map.tall {
    min-height: 340px;
  }
}
