/* ==========================================================================
   UpSpace Logistics — design system
   Navy / signal-orange courier palette, 8px spacing scale, system font stack.
   ========================================================================== */

:root {
  --navy-900: #06111d;
  --navy-800: #0b1b2b;
  --navy-700: #12293e;
  --navy-600: #1b3a55;
  --navy-500: #2b5273;

  --orange-600: #e0561d;
  --orange-500: #ff6b2c;
  --orange-400: #ff8a55;
  --orange-050: #fff2eb;

  --ink-900: #0f1b26;
  --ink-700: #33465a;
  --ink-500: #5f7387;
  --ink-400: #8496a8;
  --ink-200: #d7dfe7;
  --ink-100: #e9eef3;
  --ink-050: #f5f8fa;
  --white: #ffffff;

  --green-600: #0f7a4d;
  --green-050: #e6f6ee;
  --amber-600: #a56800;
  --amber-050: #fdf3e0;
  --blue-600: #1259a8;
  --blue-050: #e8f1fc;
  --red-600: #b3261e;
  --red-050: #fdecea;
  --teal-600: #0e6b78;
  --teal-050: #e3f3f5;
  --slate-600: #55677a;
  --slate-050: #eef2f6;

  --radius-sm: 6px;
  --radius: 10px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(11, 27, 43, .08), 0 1px 3px rgba(11, 27, 43, .06);
  --shadow: 0 4px 12px rgba(11, 27, 43, .08), 0 2px 4px rgba(11, 27, 43, .04);
  --shadow-lg: 0 24px 48px -12px rgba(11, 27, 43, .28);

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "SFMono-Regular", ui-monospace, "Cascadia Mono", Consolas, "Liberation Mono", monospace;
}

*, *::before, *::after { box-sizing: border-box; }

/* The [hidden] attribute must win over any component's own `display`
   (e.g. `.field { display: grid }`) — author rules otherwise beat the
   browser's default [hidden] styling even at equal specificity. */
[hidden] { display: none !important; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-900);
  background: var(--ink-050);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { margin: 0; line-height: 1.2; font-weight: 650; letter-spacing: -.01em; }
p { margin: 0; }
a { color: var(--orange-600); text-decoration: none; }
a:hover { text-decoration: underline; }
img, svg { max-width: 100%; }

.container { width: min(1280px, 100% - 48px); margin-inline: auto; }
.container-narrow { width: min(880px, 100% - 48px); margin-inline: auto; }

/* --------------------------------------------------------------------------
   Brand mark
   -------------------------------------------------------------------------- */

.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: -.02em; }
.brand__mark {
  width: 34px; height: 34px; border-radius: 9px; flex: none;
  background: linear-gradient(135deg, var(--orange-500), var(--orange-600));
  display: grid; place-items: center; color: #fff;
  box-shadow: 0 2px 8px rgba(255, 107, 44, .35);
}
.brand__mark svg { width: 19px; height: 19px; display: block; }
.brand__name { font-size: 1.02rem; line-height: 1.1; }
.brand__name small { display: block; font-size: .62rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; opacity: .62; }

/* --------------------------------------------------------------------------
   Public site
   -------------------------------------------------------------------------- */

.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(6, 17, 29, .92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, .09);
  color: #fff;
}
.site-header .brand { color: #fff; }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 14px 0; }
.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav a { color: rgba(255, 255, 255, .8); font-size: .9rem; font-weight: 500; }
.site-nav a:hover { color: #fff; text-decoration: none; }

.hero {
  background:
    radial-gradient(1100px 520px at 78% -8%, rgba(255, 107, 44, .22), transparent 62%),
    linear-gradient(180deg, var(--navy-800), var(--navy-900));
  color: #fff; padding: 84px 0 96px; position: relative; overflow: hidden;
}
.hero::after {
  content: ""; position: absolute; inset: auto 0 -1px 0; height: 90px;
  background: linear-gradient(180deg, transparent, var(--ink-050));
}
.hero__grid { display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.hero__eyebrow {
  display: inline-flex; align-items: center; gap: 8px; font-size: .74rem; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; color: var(--orange-400);
  border: 1px solid rgba(255, 138, 85, .32); border-radius: 999px; padding: 5px 13px; margin-bottom: 20px;
}
.hero h1 { font-size: clamp(2.1rem, 4.4vw, 3.35rem); letter-spacing: -.03em; margin-bottom: 18px; }
.hero p.lede { font-size: 1.08rem; color: rgba(232, 238, 245, .78); max-width: 52ch; }
.hero__actions { margin-top: 28px; }
.hero__stats { display: flex; gap: 40px; margin-top: 38px; flex-wrap: wrap; }
.hero__stat strong { display: block; font-size: 1.65rem; letter-spacing: -.02em; }
.hero__stat span { font-size: .78rem; color: rgba(232, 238, 245, .58); text-transform: uppercase; letter-spacing: .08em; }

.track-card {
  background: #fff; border-radius: var(--radius-lg); padding: 30px;
  box-shadow: var(--shadow-lg); color: var(--ink-900);
}
.track-card h2 { font-size: 1.22rem; margin-bottom: 6px; }
.track-card .muted { color: var(--ink-500); font-size: .9rem; margin-bottom: 20px; }

.code-input {
  width: 100%; font-family: var(--mono); font-size: 1.7rem; font-weight: 700;
  letter-spacing: .42em; text-align: center; text-transform: uppercase;
  padding: 16px 12px; border: 2px solid var(--ink-200); border-radius: var(--radius);
  background: var(--ink-050); color: var(--navy-800);
}
.code-input:focus { outline: none; border-color: var(--orange-500); background: #fff; box-shadow: 0 0 0 4px rgba(255, 107, 44, .14); }
.code-input::placeholder { color: var(--ink-400); letter-spacing: .3em; font-weight: 500; }

.section { padding: 76px 0; }
.section--tint { background: #fff; }
.section__head { max-width: 620px; margin-bottom: 44px; }
.section__head .eyebrow { color: var(--orange-600); font-size: .74rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.section__head h2 { font-size: clamp(1.6rem, 2.8vw, 2.15rem); margin: 10px 0 12px; }
.section__head p { color: var(--ink-500); font-size: 1.02rem; }

/**
 * A horizontal route map — one continuous rail with a stop at each step,
 * captions alternating above and below the rail so the eye zig-zags along
 * it rather than reading a flat row of identical chips. Scrolls
 * horizontally past the fold instead of wrapping, so the rail never breaks.
 */
.flow-map {
  position: relative; display: flex; gap: 4px; overflow-x: auto; overflow-y: hidden;
  padding: 6px 26px 2px; scrollbar-width: thin; scrollbar-color: var(--ink-200) transparent;
}
.flow-map::before {
  content: ""; position: absolute; top: 50%; left: 10px; right: 10px; height: 2px;
  background: var(--ink-200); z-index: 0;
}
.flow-node { position: relative; flex: 0 0 164px; height: 296px; z-index: 1; }
.flow-node__icon {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center;
  color: #fff; box-shadow: 0 8px 18px -8px rgba(11, 27, 43, .45); border: 3px solid var(--ink-050);
}
.flow-node--up .flow-node__icon { background: var(--navy-800); }
.flow-node--down .flow-node__icon { background: var(--orange-500); }
.flow-node__body { position: absolute; left: -18px; right: -18px; text-align: center; }
.flow-node--up .flow-node__body { bottom: calc(50% + 34px); }
.flow-node--down .flow-node__body { top: calc(50% + 34px); }
.flow-node__num {
  display: block; font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 5px;
}
.flow-node--up .flow-node__num { color: var(--navy-800); }
.flow-node--down .flow-node__num { color: var(--orange-500); }
.flow-node h3 { font-size: .9rem; line-height: 1.3; margin-bottom: 4px; }
.flow-node p { color: var(--ink-500); font-size: .78rem; line-height: 1.5; }

/** A bold banner under the flow diagram calling out end-to-end tracking — the one capability that spans every step above rather than belonging to just one of them. */
.tracking-banner {
  display: flex; align-items: center; gap: 22px; margin-top: 46px;
  background: linear-gradient(135deg, var(--navy-800), var(--navy-900));
  color: #fff; border-radius: var(--radius-lg); padding: 28px 34px; box-shadow: var(--shadow);
}
.tracking-banner__icon {
  position: relative; flex: none; width: 58px; height: 58px; border-radius: 50%;
  background: rgba(255, 255, 255, .1); color: var(--orange-400);
  display: grid; place-items: center;
}
/** Two rings pulse outward on a stagger — a live "GPS ping" read, not a static badge. */
.tracking-banner__icon::before,
.tracking-banner__icon::after {
  content: ""; position: absolute; inset: -3px; border-radius: 50%;
  border: 2px solid var(--orange-400); opacity: 0;
  animation: tracking-pulse 2.4s cubic-bezier(.2, .6, .4, 1) infinite;
}
.tracking-banner__icon::after { animation-delay: 1.2s; }
.tracking-banner__icon svg { position: relative; z-index: 1; }
@keyframes tracking-pulse {
  0% { transform: scale(.8); opacity: .85; }
  100% { transform: scale(1.9); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .tracking-banner__icon::before, .tracking-banner__icon::after { animation: none; opacity: 0; }
}
.tracking-banner h3 { font-size: 1.16rem; letter-spacing: -.01em; margin-bottom: 5px; color: #fff; }
.tracking-banner p { color: rgba(232, 238, 245, .78); font-size: .92rem; line-height: 1.5; margin: 0; }
@media (max-width: 640px) {
  .tracking-banner { flex-direction: column; text-align: center; padding: 26px 22px; }
}

/** An animated trial-offer badge above the pricing toggle — a shifting gradient plus a light sweep, so the free-trial message reads as a live, energetic callout rather than static fine print. */
.trial-badge-wrap { display: flex; justify-content: center; margin: 0 0 28px; }
.trial-badge {
  position: relative; overflow: hidden; display: inline-block; max-width: 92%;
  padding: 11px 26px; border-radius: 999px; text-align: center;
  background: linear-gradient(90deg, var(--orange-600), var(--orange-500), var(--red-600), var(--orange-500), var(--orange-600));
  background-size: 300% 100%;
  color: #fff; font-size: .86rem; font-weight: 700; letter-spacing: .01em;
  box-shadow: 0 10px 24px -10px rgba(224, 86, 29, .55);
  animation: trial-badge-shift 5s ease-in-out infinite, trial-badge-pop .5s ease;
}
.trial-badge::after {
  content: ""; position: absolute; top: 0; left: -60%; width: 35%; height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255, 255, 255, .55), transparent);
  transform: skewX(-20deg); animation: trial-badge-sweep 3.2s ease-in-out infinite;
}
@keyframes trial-badge-shift { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes trial-badge-sweep { 0% { left: -60%; } 55% { left: 130%; } 100% { left: 130%; } }
@keyframes trial-badge-pop { from { transform: scale(.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  .trial-badge, .trial-badge::after { animation: none; }
}

.pricing-toggle-wrap { display: flex; justify-content: center; margin-bottom: 36px; }
.pricing-toggle {
  display: inline-flex; gap: 4px; padding: 5px; background: var(--ink-050, #f1f2f4);
  border-radius: 999px; border: 1px solid var(--ink-100);
}
.pricing-toggle__option {
  appearance: none; border: none; background: transparent; cursor: pointer;
  padding: 10px 26px; border-radius: 999px; font-size: .88rem; font-weight: 600;
  color: var(--ink-500); transition: background .15s ease, color .15s ease, box-shadow .15s ease;
}
.pricing-toggle__option:hover { color: var(--ink-700); }
.pricing-toggle__option.is-active { background: #fff; color: var(--red-600); box-shadow: var(--shadow-sm); }

.pricing-plan-wrap { display: flex; justify-content: center; }
.pricing-plan-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px;
  align-items: start; width: 100%;
}
.pricing-plan-grid--single { grid-template-columns: minmax(0, 380px); justify-content: center; }
.pricing-plan-card {
  position: relative; text-align: center;
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  padding: 36px 32px; box-shadow: var(--shadow-sm);
}
.pricing-plan-card--featured { border: 2px solid var(--red-600); box-shadow: var(--shadow); }
.pricing-plan-grid--single .pricing-plan-card { border: 2px solid var(--red-600); box-shadow: var(--shadow); }
.pricing-plan-card__badge {
  position: absolute; top: -13px; left: 50%; transform: translateX(-50%);
  background: var(--red-600); color: #fff; font-size: .68rem; font-weight: 700;
  letter-spacing: .08em; text-transform: uppercase; padding: 5px 14px; border-radius: 999px;
  white-space: nowrap;
}
.pricing-plan-card__label { font-size: .74rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-500); }
.pricing-plan-card__rate { margin: 10px 0 6px; font-size: 2.6rem; font-weight: 800; letter-spacing: -.02em; color: var(--ink-900); }
.pricing-plan-card--featured .pricing-plan-card__rate,
.pricing-plan-grid--single .pricing-plan-card__rate { color: var(--red-600); font-size: 3rem; }
.pricing-plan-card__rate small { font-size: 1.05rem; font-weight: 500; color: var(--ink-500); }
.pricing-plan-card__tagline { color: var(--ink-700); font-size: .95rem; }
.pricing-plan-card__included {
  margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--ink-100);
  font-size: .84rem; color: var(--ink-500); line-height: 1.7; text-align: left;
}
.pricing-plan-card__included strong { display: block; color: var(--ink-700); margin-bottom: 2px; }
.pricing-plan-card .btn { width: 100%; margin-top: 22px; }

.portal-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(268px, 1fr)); gap: 24px; }
.portal-card {
  --portal-accent: var(--orange-500); --portal-accent-dark: var(--orange-600);
  position: relative; overflow: hidden;
  border: 1px solid var(--ink-100); border-radius: var(--radius-lg); padding: 34px 28px 28px; background: #fff;
  display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.portal-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 4px;
  background: linear-gradient(90deg, var(--portal-accent), var(--portal-accent-dark));
}
.portal-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lg); border-color: var(--portal-accent); }
.portal-card--driver { --portal-accent: var(--teal-600); --portal-accent-dark: #0a4d57; }
.portal-card--admin { --portal-accent: var(--navy-600); --portal-accent-dark: var(--navy-800); }
.portal-card__kicker {
  font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--portal-accent);
}
.portal-card__icon {
  width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 4px;
  background: linear-gradient(135deg, var(--portal-accent), var(--portal-accent-dark)); color: #fff;
  box-shadow: 0 10px 18px -10px rgba(11, 27, 43, .5);
}
.portal-card h3 { font-size: 1.1rem; }
.portal-card p { color: var(--ink-500); font-size: .92rem; line-height: 1.55; flex: 1; }
.portal-card .btn { margin-top: 8px; }
.portal-card__request {
  appearance: none; border: none; background: none; padding: 4px 0 0; margin-top: 2px;
  font-size: .82rem; font-weight: 600; color: var(--portal-accent); cursor: pointer; text-align: left;
}
.portal-card__request:hover { text-decoration: underline; }

.site-footer { background: var(--navy-900); color: rgba(232, 238, 245, .62); padding: 52px 0 30px; font-size: .88rem; }
.site-footer .brand { color: #fff; margin-bottom: 12px; }
.site-footer__grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1fr; gap: 32px; }
.site-footer h4 { color: #fff; font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; margin-bottom: 12px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.site-footer a { color: rgba(232, 238, 245, .62); }
.site-footer a:hover { color: #fff; }
.site-footer__bottom { border-top: 1px solid rgba(255, 255, 255, .1); margin-top: 36px; padding-top: 20px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: .82rem; }

/* --------------------------------------------------------------------------
   Buttons & forms
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font: inherit; font-weight: 600; font-size: .92rem; line-height: 1;
  padding: 11px 18px; border-radius: var(--radius); border: 1px solid transparent;
  cursor: pointer; transition: background .15s ease, border-color .15s ease, color .15s ease, transform .05s ease;
  white-space: nowrap; text-decoration: none;
}
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn:hover { text-decoration: none; }
.btn--primary { background: var(--orange-500); color: #fff; }
.btn--primary:hover:not(:disabled) { background: var(--orange-600); }
.btn--dark { background: var(--navy-800); color: #fff; }
.btn--dark:hover:not(:disabled) { background: var(--navy-700); }
.btn--ghost { background: #fff; color: var(--ink-700); border-color: var(--ink-200); }
.btn--ghost:hover:not(:disabled) { border-color: var(--ink-400); color: var(--ink-900); }
.btn--outline-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .34); }
.btn--outline-light:hover:not(:disabled) { background: rgba(255, 255, 255, .1); }
.btn--danger { background: var(--red-600); color: #fff; }
.btn--danger:hover:not(:disabled) { background: #931f18; }
.btn--success { background: var(--green-600); color: #fff; }
.btn--success:hover:not(:disabled) { background: #0b5f3c; }
.btn--block { width: 100%; }
.btn--sm { padding: 7px 12px; font-size: .82rem; }
.btn--lg { padding: 14px 24px; font-size: 1rem; }

.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field label { font-size: .82rem; font-weight: 600; color: var(--ink-700); }
.field label .req { color: var(--red-600); }
.field .hint { font-size: .78rem; color: var(--ink-500); }
.product-field-row { display: flex; gap: 8px; align-items: stretch; }
.product-field-row input { flex: 1; min-width: 0; }
.product-field-row .btn { flex: none; white-space: nowrap; }
.product-chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--ink-050); border: 1px solid var(--ink-100); border-radius: 999px;
  padding: 6px 8px 6px 14px; font-size: .84rem;
}
.product-chip button {
  background: none; border: none; cursor: pointer; color: var(--ink-500);
  width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font: inherit;
}
.product-chip button:hover { background: var(--red-600); color: #fff; }
.product-chip-list { display: flex; flex-wrap: wrap; gap: 8px; }
.autocomplete__menu {
  position: fixed; z-index: 300; background: #fff; border: 1px solid var(--ink-200);
  border-radius: var(--radius-sm); box-shadow: var(--shadow-lg);
  max-height: 220px; overflow-y: auto; padding: 4px;
}
.autocomplete__item { padding: 8px 10px; border-radius: 4px; cursor: pointer; font-size: .88rem; color: var(--ink-900); }
.autocomplete__item:hover, .autocomplete__item.is-active { background: var(--orange-050); color: var(--orange-600); }
.autocomplete__empty { padding: 8px 10px; font-size: .82rem; color: var(--ink-500); }
.field input, .field select, .field textarea {
  font: inherit; font-size: .93rem; padding: 10px 12px; border: 1px solid var(--ink-200);
  border-radius: var(--radius-sm); background: #fff; color: var(--ink-900); width: 100%;
}
.field textarea { resize: vertical; min-height: 76px; }
.field input:focus, .field select:focus, .field textarea:focus {
  outline: none; border-color: var(--orange-500); box-shadow: 0 0 0 3px rgba(255, 107, 44, .13);
}
.field input:disabled, .field select:disabled { background: var(--ink-050); color: var(--ink-500); }
.field input[type="checkbox"] { width: auto; padding: 0; border: none; }
.field--error input, .field--error select, .field--error textarea { border-color: var(--red-600); }
.field .error-text { font-size: .78rem; color: var(--red-600); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; }
.form-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-grid .span-2 { grid-column: 1 / -1; }
.fieldset-title {
  grid-column: 1 / -1; font-size: .74rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-400); padding-bottom: 8px; margin: 10px 0 14px; border-bottom: 1px solid var(--ink-100);
}
.checkbox-row { display: flex; align-items: flex-start; gap: 10px; font-size: .9rem; color: var(--ink-700); }
.checkbox-row input { width: auto; margin-top: 3px; }

/* Long, section-by-section editor forms (e.g. the home page content editor):
   a jump-nav column on the left, one section visible at a time on the right. */
.content-editor { display: grid; grid-template-columns: 220px 1fr; gap: 24px; align-items: start; }
.content-editor__nav {
  position: sticky; top: 88px; display: flex; flex-direction: column; gap: 2px;
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  padding: 10px; box-shadow: var(--shadow-sm);
}
.content-editor__nav button {
  display: block; width: 100%; text-align: left; padding: 10px 12px; border-radius: var(--radius-sm);
  border: none; background: none; font: inherit; font-size: .87rem; font-weight: 600;
  color: var(--ink-700); cursor: pointer;
}
.content-editor__nav button:hover { background: var(--ink-050); }
.content-editor__nav button.is-active { background: var(--navy-800); color: #fff; }
.content-editor__panels { min-width: 0; }
.content-editor__actions {
  position: sticky; bottom: 0; background: #fff; border-top: 1px solid var(--ink-100);
  padding: 16px 0; margin-top: 8px; display: flex; gap: 12px; justify-content: flex-end; flex-wrap: wrap;
}
@media (max-width: 1100px) {
  .content-editor { grid-template-columns: 1fr; }
  .content-editor__nav { position: static; flex-direction: row; overflow-x: auto; }
  .content-editor__nav button { white-space: nowrap; }
}

/* --------------------------------------------------------------------------
   Sign-in
   -------------------------------------------------------------------------- */

.auth-shell { min-height: 100vh; display: grid; grid-template-columns: 1.05fr 1fr; }
.auth-aside {
  background:
    radial-gradient(760px 460px at 20% 8%, rgba(255, 107, 44, .2), transparent 60%),
    linear-gradient(160deg, var(--navy-800), var(--navy-900));
  color: #fff; padding: 48px; display: flex; flex-direction: column; justify-content: space-between;
}
.auth-aside .brand { color: #fff; }
.auth-aside h2 { font-size: 2rem; letter-spacing: -.025em; margin-bottom: 14px; }
.auth-aside p { color: rgba(232, 238, 245, .7); max-width: 44ch; }
.auth-points { list-style: none; padding: 0; margin: 30px 0 0; display: grid; gap: 14px; }
.auth-points li { display: flex; gap: 12px; align-items: flex-start; color: rgba(232, 238, 245, .82); font-size: .93rem; }
.auth-points svg { flex: none; margin-top: 2px; color: var(--orange-400); }
.auth-main { display: grid; place-items: center; padding: 48px 24px; background: #fff; }
.auth-form { width: min(400px, 100%); }
.auth-form h1 { font-size: 1.6rem; margin-bottom: 8px; }
.auth-form .muted { color: var(--ink-500); margin-bottom: 26px; font-size: .93rem; }

/* --------------------------------------------------------------------------
   App shell (dashboards)
   -------------------------------------------------------------------------- */

.app { display: grid; grid-template-columns: 254px 1fr; min-height: 100vh; }
.sidebar {
  background: var(--navy-900); color: rgba(232, 238, 245, .72);
  padding: 20px 16px; display: flex; flex-direction: column; gap: 6px;
  position: sticky; top: 0; height: 100vh; overflow-y: auto;
}
.sidebar-backdrop { position: fixed; inset: 0; background: rgba(15, 23, 32, .45); z-index: 55; opacity: 0; pointer-events: none; transition: opacity .2s ease; }
.sidebar-backdrop.is-open { opacity: 1; pointer-events: auto; }
.sidebar .brand { color: #fff; padding: 6px 8px 20px; }
.sidebar__label {
  font-size: .66rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase;
  color: rgba(232, 238, 245, .38); padding: 16px 10px 6px;
}
.nav-item {
  display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: var(--radius-sm);
  color: rgba(232, 238, 245, .74); font-size: .9rem; font-weight: 500; cursor: pointer; border: none;
  background: none; width: 100%; text-align: left; font-family: inherit;
}
.nav-item:hover { background: rgba(255, 255, 255, .07); color: #fff; text-decoration: none; }
.nav-item.is-active { background: var(--orange-500); color: #fff; font-weight: 600; }
.nav-item svg { flex: none; }
.nav-item .count {
  margin-left: auto; background: rgba(255, 255, 255, .14); border-radius: 999px;
  padding: 1px 8px; font-size: .74rem; font-weight: 700;
}
.nav-item.is-active .count { background: rgba(0, 0, 0, .22); }
.sidebar__foot { margin-top: auto; padding-top: 16px; border-top: 1px solid rgba(255, 255, 255, .1); }
.sidebar__user { display: flex; align-items: center; gap: 10px; padding: 10px 8px; }
.avatar {
  width: 34px; height: 34px; border-radius: 50%; background: var(--navy-600); color: #fff;
  display: grid; place-items: center; font-weight: 700; font-size: .78rem; flex: none;
}
.sidebar__user .who { min-width: 0; }
.sidebar__user .who strong { display: block; color: #fff; font-size: .86rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.sidebar__user .who span { font-size: .74rem; color: rgba(232, 238, 245, .5); }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar {
  background: #fff; border-bottom: 1px solid var(--ink-100); padding: 16px 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 20px;
  position: sticky; top: 0; z-index: 20;
}
.topbar h1 { font-size: 1.28rem; }
.topbar .sub { color: var(--ink-500); font-size: .86rem; margin-top: 2px; }
.topbar__title { display: flex; align-items: center; gap: 12px; min-width: 0; }
.topbar__actions { display: flex; align-items: center; gap: 10px; }
.content { padding: 28px 32px 60px; flex: 1; }
.view[hidden] { display: none !important; }

.menu-toggle { display: none; }

/* --------------------------------------------------------------------------
   Cards, stats, tables
   -------------------------------------------------------------------------- */

.card { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg); box-shadow: var(--shadow-sm); }
.card__head {
  padding: 18px 22px; border-bottom: 1px solid var(--ink-100);
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
}
.card__head h2 { font-size: 1.02rem; }
.card__head .sub { color: var(--ink-500); font-size: .84rem; margin-top: 2px; }
.card__body { padding: 22px; }
.card__body--flush { padding: 0; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(184px, 1fr)); gap: 16px; margin-bottom: 26px; }
.stat {
  background: #fff; border: 1px solid var(--ink-100); border-radius: var(--radius-lg);
  padding: 18px 20px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden;
}
.stat::before { content: ""; position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--ink-200); }
.stat--amber::before { background: #e0a11a; }
.stat--blue::before { background: var(--blue-600); }
.stat--orange::before { background: var(--orange-500); }
.stat--green::before { background: var(--green-600); }
.stat--red::before { background: var(--red-600); }
.stat--teal::before { background: var(--teal-600); }
.stat__label { font-size: .76rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-500); }
.stat__value { font-size: 2rem; font-weight: 700; letter-spacing: -.03em; margin-top: 4px; line-height: 1.1; }
.stat__meta { font-size: .8rem; color: var(--ink-500); margin-top: 2px; }

.split-columns { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 1180px) { .split-columns { grid-template-columns: 1fr; } }

.table-wrap { overflow-x: auto; }
table.data { width: 100%; border-collapse: collapse; font-size: .89rem; }
table.data th {
  text-align: left; font-size: .7rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase;
  color: var(--ink-500); padding: 11px 16px; border-bottom: 1px solid var(--ink-100);
  background: var(--ink-050); white-space: nowrap; position: sticky; top: 0;
}
table.data td { padding: 13px 16px; border-bottom: 1px solid var(--ink-100); vertical-align: middle; }
table.data tbody tr:hover { background: var(--ink-050); }
table.data tbody tr:last-child td { border-bottom: none; }
table.data .nowrap { white-space: nowrap; }
table.data .actions { display: flex; gap: 6px; justify-content: flex-end; }
.cell-title { font-weight: 600; color: var(--ink-900); }
.cell-sub { color: var(--ink-500); font-size: .82rem; }

/* Bulk delivery — dense spreadsheet-style entry table */
table.bulk-table th { padding: 9px 6px; }
table.bulk-table td { padding: 6px; border-bottom: 1px solid var(--ink-100); vertical-align: top; }
table.bulk-table input, table.bulk-table select {
  width: 100%; min-width: 92px; padding: 7px 8px; font: inherit; font-size: .84rem;
  border: 1px solid var(--ink-200); border-radius: 6px; background: #fff; color: var(--ink-900);
}
table.bulk-table input:focus, table.bulk-table select:focus {
  outline: none; border-color: var(--orange-500); box-shadow: 0 0 0 2px rgba(255, 107, 44, .13);
}
table.bulk-table input.is-invalid { border-color: var(--red-600); background: var(--red-050); }
.bulk-row-num { color: var(--ink-400); font-size: .8rem; text-align: center; padding-top: 12px !important; }
.pay-toggle { display: flex; border: 1px solid var(--ink-200); border-radius: 6px; overflow: hidden; min-width: 130px; }
.pay-toggle button {
  flex: 1; padding: 7px 8px; font-size: .76rem; font-weight: 700; border: none; background: #fff;
  color: var(--ink-500); cursor: pointer; white-space: nowrap;
}
.pay-toggle button + button { border-left: 1px solid var(--ink-200); }
.pay-toggle button.is-active[data-pay="Cash on delivery"] { background: var(--red-600); color: #fff; }
.pay-toggle button.is-active[data-pay="Prepaid"] { background: var(--navy-800); color: #fff; }
.bulk-remove-btn { background: none; border: none; color: var(--ink-400); cursor: pointer; padding: 7px; border-radius: 6px; margin-top: 2px; }
.bulk-remove-btn:hover { background: var(--red-050); color: var(--red-600); }
.bulk-add-row-btn {
  width: 100%; padding: 12px; margin-top: 10px; border: 1px dashed var(--ink-200); border-radius: var(--radius-sm);
  background: #fff; color: var(--ink-700); font-weight: 600; font-size: .88rem; cursor: pointer;
}
.bulk-add-row-btn:hover { border-color: var(--orange-500); color: var(--orange-600); background: var(--orange-050); }
.mode-toggle { display: flex; border: 1px solid var(--ink-200); border-radius: var(--radius-sm); overflow: hidden; }
.mode-toggle button {
  padding: 9px 16px; font-size: .84rem; font-weight: 600; border: none; background: #fff;
  color: var(--ink-500); cursor: pointer;
}
.mode-toggle button + button { border-left: 1px solid var(--ink-200); }
.mode-toggle button.is-active { background: var(--navy-800); color: #fff; }

.mono { font-family: var(--mono); font-size: .86em; letter-spacing: .01em; }
.muted { color: var(--ink-500); }
.tiny { font-size: .78rem; }
.right { text-align: right; }
.strong { font-weight: 650; }

/* --------------------------------------------------------------------------
   Badges & pills
   -------------------------------------------------------------------------- */

.badge {
  display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: 999px;
  font-size: .74rem; font-weight: 650; letter-spacing: .01em; white-space: nowrap;
  background: var(--slate-050); color: var(--slate-600);
}
.badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.badge--draft { background: var(--slate-050); color: var(--slate-600); }
.badge--submitted { background: var(--amber-050); color: var(--amber-600); }
.badge--collected { background: var(--teal-050); color: var(--teal-600); }
.badge--assigned { background: var(--blue-050); color: var(--blue-600); }
.badge--picked_up { background: var(--orange-050); color: var(--orange-600); }
.badge--in_transit { background: var(--orange-050); color: var(--orange-600); }
.badge--delivered { background: var(--green-050); color: var(--green-600); }
.badge--failed { background: var(--red-050); color: var(--red-600); }
.badge--cancelled { background: var(--slate-050); color: var(--slate-600); }
.badge--active { background: var(--green-050); color: var(--green-600); }
.badge--suspended { background: var(--red-050); color: var(--red-600); }
.badge--deleted { background: var(--slate-600); color: #fff; }
.badge--scheduled { background: var(--blue-050); color: var(--blue-600); }
.badge--in_progress { background: var(--orange-050); color: var(--orange-600); }
.badge--completed { background: var(--green-050); color: var(--green-600); }
.badge--plain::before { display: none; }
.badge--service { background: var(--navy-800); color: #fff; }
.badge--service::before { display: none; }

.pill-row { display: flex; gap: 8px; flex-wrap: wrap; }
.filter-pill {
  border: 1px solid var(--ink-200); background: #fff; color: var(--ink-700); border-radius: 999px;
  padding: 6px 14px; font: inherit; font-size: .84rem; font-weight: 550; cursor: pointer;
}
.filter-pill:hover { border-color: var(--ink-400); }
.filter-pill.is-active { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }

/* --------------------------------------------------------------------------
   Verification code display
   -------------------------------------------------------------------------- */

.code-display {
  display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap;
  background: linear-gradient(135deg, var(--navy-800), var(--navy-700)); color: #fff;
  border-radius: var(--radius-lg); padding: 20px 24px;
}
.code-display__label { font-size: .72rem; letter-spacing: .14em; text-transform: uppercase; color: rgba(232, 238, 245, .6); }
.code-display__value { font-family: var(--mono); font-size: 2.3rem; font-weight: 700; letter-spacing: .3em; line-height: 1.1; }
.code-display__hint { font-size: .84rem; color: rgba(232, 238, 245, .7); max-width: 40ch; }
.code-chip {
  display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-weight: 700;
  font-size: .95rem; letter-spacing: .2em; background: var(--navy-800); color: #fff;
  padding: 4px 12px; border-radius: var(--radius-sm);
}
.code-pending { color: var(--ink-400); font-style: italic; font-size: .84rem; }

.code-entry {
  width: 100%; font-family: var(--mono); font-size: 2.1rem; font-weight: 700; letter-spacing: .55em;
  text-indent: .55em; text-align: center; padding: 14px; border-radius: var(--radius);
  border: 2px solid var(--ink-200); background: var(--ink-050);
}
.code-entry:focus { outline: none; border-color: var(--orange-500); background: #fff; box-shadow: 0 0 0 4px rgba(255, 107, 44, .14); }

/* --------------------------------------------------------------------------
   Timeline
   -------------------------------------------------------------------------- */

.timeline { list-style: none; padding: 0; margin: 0; position: relative; }
.timeline::before { content: ""; position: absolute; left: 9px; top: 12px; bottom: 12px; width: 2px; background: var(--ink-100); }
.timeline li { position: relative; padding: 0 0 22px 34px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: ""; position: absolute; left: 3px; top: 5px; width: 14px; height: 14px; border-radius: 50%;
  background: #fff; border: 3px solid var(--ink-200);
}
.timeline li.is-done::before { border-color: var(--green-600); background: var(--green-600); }
.timeline li.is-current::before { border-color: var(--orange-500); background: #fff; box-shadow: 0 0 0 4px rgba(255, 107, 44, .16); }
.timeline li.is-alert::before { border-color: var(--red-600); background: var(--red-600); }
.timeline__title { font-weight: 620; font-size: .93rem; }
.timeline__meta { font-size: .8rem; color: var(--ink-500); }
.timeline__note { font-size: .86rem; color: var(--ink-700); margin-top: 3px; }

/* --------------------------------------------------------------------------
   Detail lists
   -------------------------------------------------------------------------- */

.detail-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 18px 24px; }
.detail dt { font-size: .72rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--ink-500); }
.detail dd { margin: 3px 0 0; font-size: .93rem; color: var(--ink-900); }
.panel { background: var(--ink-050); border: 1px solid var(--ink-100); border-radius: var(--radius); padding: 16px 18px; }
.panel + .panel { margin-top: 14px; }
.panel h4 { font-size: .78rem; letter-spacing: .09em; text-transform: uppercase; color: var(--ink-500); margin-bottom: 10px; }

.callout {
  display: flex; gap: 12px; align-items: flex-start; border-radius: var(--radius);
  padding: 13px 16px; font-size: .88rem; border: 1px solid transparent;
}
.callout svg { flex: none; margin-top: 2px; }
.callout--info { background: var(--blue-050); color: #0d3f77; border-color: #cbe0f7; }
.callout--warn { background: var(--amber-050); color: #7a4d00; border-color: #f2dcb4; }
.callout--success { background: var(--green-050); color: #0a5537; border-color: #c2e6d4; }
.callout--danger { background: var(--red-050); color: #8c1d17; border-color: #f5cbc7; }
.callout--neutral { background: var(--ink-050); color: var(--ink-700); border-color: var(--ink-100); }

/* --------------------------------------------------------------------------
   Modal
   -------------------------------------------------------------------------- */

.modal-backdrop {
  position: fixed; inset: 0; background: rgba(6, 17, 29, .58); backdrop-filter: blur(3px);
  display: grid; place-items: center; padding: 24px; z-index: 100; overflow-y: auto;
}
.modal-backdrop[hidden] { display: none; }
.modal {
  background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
  width: min(720px, 100%); max-height: calc(100vh - 48px); display: flex; flex-direction: column;
}
.modal--wide { width: min(940px, 100%); }
.modal--narrow { width: min(480px, 100%); }
.modal__head {
  padding: 20px 24px; border-bottom: 1px solid var(--ink-100);
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
}
.modal__head h2 { font-size: 1.12rem; }
.modal__head .sub { color: var(--ink-500); font-size: .86rem; margin-top: 3px; }
.modal__body { padding: 24px; overflow-y: auto; }
.modal__foot {
  padding: 16px 24px; border-top: 1px solid var(--ink-100); display: flex; justify-content: flex-end;
  gap: 10px; flex-wrap: wrap; background: var(--ink-050); border-radius: 0 0 var(--radius-lg) var(--radius-lg);
}
.icon-btn {
  background: none; border: none; cursor: pointer; color: var(--ink-500); padding: 6px;
  border-radius: var(--radius-sm); display: grid; place-items: center; font: inherit;
}
.icon-btn:hover { background: var(--ink-100); color: var(--ink-900); }

/* --------------------------------------------------------------------------
   Toasts
   -------------------------------------------------------------------------- */

.toast-stack { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: grid; gap: 10px; width: min(380px, calc(100vw - 40px)); }
.toast {
  background: var(--navy-800); color: #fff; border-radius: var(--radius); padding: 13px 16px;
  box-shadow: var(--shadow-lg); font-size: .89rem; display: flex; gap: 10px; align-items: flex-start;
  animation: toast-in .18s ease-out;
}
.toast--success { background: #0d6b46; }
.toast--error { background: #9c2019; }
.toast strong { display: block; margin-bottom: 2px; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* --------------------------------------------------------------------------
   Empty / loading states
   -------------------------------------------------------------------------- */

.empty { text-align: center; padding: 54px 24px; color: var(--ink-500); }
.empty svg { color: var(--ink-200); margin-bottom: 14px; }
.empty h3 { font-size: 1rem; color: var(--ink-700); margin-bottom: 6px; }
.empty p { font-size: .9rem; max-width: 42ch; margin-inline: auto; }

.skeleton { background: linear-gradient(90deg, var(--ink-100), var(--ink-050), var(--ink-100)); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: var(--radius-sm); height: 14px; }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }

.spinner {
  width: 15px; height: 15px; border: 2px solid rgba(255, 255, 255, .35); border-top-color: #fff;
  border-radius: 50%; animation: spin .7s linear infinite; flex: none;
}
.spinner--dark { border-color: rgba(15, 27, 38, .2); border-top-color: var(--navy-800); }
@keyframes spin { to { transform: rotate(360deg); } }

/* --------------------------------------------------------------------------
   Driver job cards
   -------------------------------------------------------------------------- */

.job-list { display: grid; gap: 16px; }
.job {
  background: #fff; border: 1px solid var(--ink-100); border-left: 4px solid var(--blue-600);
  border-radius: var(--radius-lg); padding: 20px 22px; box-shadow: var(--shadow-sm);
}
.job.is-today { border-left-color: var(--orange-500); }
.job.is-overdue { border-left-color: var(--red-600); }
.job.is-transit { border-left-color: var(--orange-500); }
.job__head { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: flex-start; }
.job__title { font-size: 1.02rem; font-weight: 650; }
.job__meta { display: flex; gap: 14px; flex-wrap: wrap; color: var(--ink-500); font-size: .84rem; margin-top: 4px; }
.job__body { margin-top: 16px; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.job__actions { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--ink-100); display: flex; gap: 10px; flex-wrap: wrap; }

.wa-link { display: inline-flex; align-items: center; gap: 6px; color: #128c7e; font-weight: 600; font-size: .86rem; }
.wa-link:hover { text-decoration: underline; }

/* --------------------------------------------------------------------------
   Collection pick list

   Built for a driver holding a phone in one hand and a parcel in the other:
   the whole row is the tap target, ticks are oversized, and the running count
   stays on screen while the list scrolls.
   -------------------------------------------------------------------------- */

.job.is-collection { border-left-color: var(--teal-600); }

.pick-toolbar {
  position: sticky; top: 0; z-index: 2;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 12px 14px; margin-bottom: 12px;
  background: var(--navy-800); color: #fff; border-radius: var(--radius);
}
.pick-toolbar__count { font-size: 1.05rem; font-weight: 700; }
.pick-toolbar__count small { display: block; font-size: .72rem; font-weight: 500; opacity: .7; letter-spacing: .04em; }

.pick-list { display: grid; gap: 10px; }

.pick-item {
  display: flex; align-items: flex-start; gap: 14px; cursor: pointer;
  padding: 14px 16px; border: 2px solid var(--ink-100); border-radius: var(--radius);
  background: #fff; transition: border-color .12s ease, background .12s ease;
}
.pick-item:hover { border-color: var(--ink-200); }
.pick-item.is-picked { border-color: var(--green-600); background: var(--green-050); }
.pick-item input[type="checkbox"] {
  width: 26px; height: 26px; margin: 2px 0 0; flex: none; accent-color: var(--green-600); cursor: pointer;
}
.pick-item__main { flex: 1; min-width: 0; }
.pick-item__top { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: baseline; }
.pick-item__ref { font-family: var(--mono); font-weight: 700; font-size: .95rem; letter-spacing: .03em; }
.pick-item__desc { margin-top: 3px; font-weight: 600; }
.pick-item__meta { margin-top: 4px; font-size: .82rem; color: var(--ink-500); display: flex; gap: 12px; flex-wrap: wrap; }
.pick-item__tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }

.receipt {
  border: 1px solid var(--ink-100); border-radius: var(--radius);
  background: var(--ink-050); padding: 18px 20px; text-align: center;
}
.receipt__count { font-size: 2.4rem; font-weight: 750; line-height: 1.1; color: var(--green-600); }
.receipt__ref { font-family: var(--mono); font-size: 1.05rem; font-weight: 700; letter-spacing: .06em; margin-top: 4px; }
.receipt__list {
  margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--ink-200);
  display: flex; gap: 8px; flex-wrap: wrap; justify-content: center;
}
.receipt__list span { font-family: var(--mono); font-size: .8rem; background: #fff; border: 1px solid var(--ink-100); border-radius: 999px; padding: 3px 10px; }

@media (max-width: 640px) {
  .pick-item { padding: 12px; gap: 12px; }
  .pick-toolbar { padding: 10px 12px; }
}

/* --------------------------------------------------------------------------
   Public tracking result
   -------------------------------------------------------------------------- */

.track-result { background: #fff; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); overflow: hidden; margin-top: 26px; }
.track-result__head { background: linear-gradient(135deg, var(--navy-800), var(--navy-700)); color: #fff; padding: 26px 28px; }
.track-result__head .num { font-family: var(--mono); font-size: 1.35rem; font-weight: 700; letter-spacing: .06em; }
.track-result__head .status { display: inline-flex; margin-top: 10px; }
.track-progress { display: flex; padding: 22px 28px 0; gap: 6px; }
.track-progress__step { flex: 1; text-align: center; font-size: .74rem; color: var(--ink-500); }
.track-progress__bar { height: 5px; border-radius: 999px; background: var(--ink-100); margin-bottom: 8px; }
.track-progress__step.is-done .track-progress__bar { background: var(--green-600); }
.track-progress__step.is-current .track-progress__bar { background: var(--orange-500); }
.track-progress__step.is-done, .track-progress__step.is-current { color: var(--ink-900); font-weight: 600; }
.track-eta {
  margin: 22px 28px 0; padding: 16px 18px; border-radius: var(--radius);
  background: var(--orange-050); border: 1px solid #ffd8c4; color: #8a3a12;
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; align-items: center;
}
.track-eta strong { font-size: 1.05rem; }

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 1100px) {
  .hero__grid { grid-template-columns: 1fr; gap: 40px; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-aside { display: none; }
  .site-footer__grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; inset: 0 auto 0 0; width: 260px; z-index: 60; height: 100vh;
    transform: translateX(-100%); transition: transform .2s ease;
  }
  .sidebar.is-open { transform: none; box-shadow: var(--shadow-lg); }
  .menu-toggle { display: grid; flex: none; width: 40px; height: 40px; }
  .topbar { padding: 14px 18px; flex-wrap: wrap; row-gap: 10px; }
  .topbar__title { flex: 1 1 auto; }
  .topbar h1 { font-size: 1.1rem; }
  .topbar__actions { width: 100%; flex-wrap: wrap; }
  .topbar__actions .btn { flex: 1 1 auto; justify-content: center; }
  .content { padding: 20px 18px 48px; }
  .form-grid, .form-grid--3 { grid-template-columns: 1fr; }
  .container, .container-narrow { width: min(100%, 100% - 32px); }
  .job__actions .btn, .pick-toolbar .btn { min-height: 44px; padding-top: 10px; padding-bottom: 10px; flex: 1 1 auto; justify-content: center; }
}

@media (max-width: 640px) {
  .site-nav { display: none; }
  .hero { padding: 56px 0 68px; }
  .site-footer__grid { grid-template-columns: 1fr; }
  .code-display__value { font-size: 1.8rem; }
  .modal__foot { flex-direction: column-reverse; }
  .modal__foot .btn { width: 100%; }
}

/* --------------------------------------------------------------------------
   Installable app prompt and offline screen
   -------------------------------------------------------------------------- */

.pwa-install {
  position: fixed; left: 50%; bottom: max(18px, env(safe-area-inset-bottom)); z-index: 90;
  width: min(560px, calc(100vw - 28px)); transform: translateX(-50%);
  display: grid; grid-template-columns: auto 1fr auto auto; align-items: center; gap: 12px;
  padding: 12px 12px 12px 14px; border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 16px; background: rgba(11, 27, 43, .97); color: #fff;
  box-shadow: 0 18px 50px rgba(3, 12, 22, .32); backdrop-filter: blur(14px);
  animation: pwa-install-in .22s ease-out;
}
.pwa-install img { border-radius: 12px; box-shadow: 0 4px 14px rgba(0, 0, 0, .22); }
.pwa-install__copy { display: grid; gap: 2px; min-width: 0; }
.pwa-install__copy strong { font-size: .9rem; }
.pwa-install__copy span { color: rgba(255, 255, 255, .7); font-size: .78rem; line-height: 1.35; }
.pwa-install__close {
  width: 36px; height: 36px; display: grid; place-items: center; padding: 0;
  border: 0; border-radius: 9px; background: transparent; color: rgba(255, 255, 255, .65); cursor: pointer;
}
.pwa-install__close:hover { color: #fff; background: rgba(255, 255, 255, .1); }
.pwa-help ol { display: grid; gap: 14px; padding-left: 22px; }
.pwa-help li { padding-left: 4px; color: var(--ink-700); }
.pwa-help p { margin-top: 18px; }
@keyframes pwa-install-in { from { opacity: 0; transform: translate(-50%, 14px); } }

.offline-page {
  min-height: 100vh; display: grid; place-items: center; padding: 24px;
  background: radial-gradient(circle at 50% 25%, #1d3d58 0, var(--navy-900) 56%); color: #fff;
}
.offline-card { width: min(440px, 100%); text-align: center; }
.offline-card img { border-radius: 22px; margin-bottom: 22px; box-shadow: var(--shadow-lg); }
.offline-card h1 { margin: 8px 0 12px; font-size: clamp(2rem, 8vw, 3.2rem); }
.offline-card p:not(.eyebrow) { color: rgba(255, 255, 255, .7); margin: 0 auto 24px; max-width: 38ch; }
.offline-card .eyebrow { color: var(--orange-400); }

@media (max-width: 560px) {
  .pwa-install { grid-template-columns: auto 1fr auto; }
  .pwa-install .btn { grid-column: 1 / 3; width: 100%; justify-content: center; }
  .pwa-install__close { grid-column: 3; grid-row: 1; }
}

@media print {
  .sidebar, .topbar, .modal__foot, .btn, .pwa-install { display: none !important; }
  body { background: #fff; }
  .card { box-shadow: none; border: 1px solid #ccc; }
}
