:root {
  --orange: #ff6500;
  --orange-dark: #d94f00;
  --orange-soft: #fff0e6;
  --navy: #15263a;
  --muted: #6e7c8f;
  --line: #e6e9ed;
  --surface: #ffffff;
  --background: #f5f7fa;
  --green: #13a875;
  --red: #d84a4a;
  --yellow: #d78c00;
  --blue: #2878d0;
  --shadow: 0 16px 40px rgba(21, 38, 58, .10);
}

* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; background: var(--background); color: var(--navy); font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
button, input { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }

.login-shell { min-height: 100vh; display: grid; grid-template-columns: 1.1fr .9fr; }
.login-brand { position: relative; overflow: hidden; padding: 72px; color: white; background: linear-gradient(145deg, #ff7a00, #ef4d00); display: flex; flex-direction: column; justify-content: space-between; }
.login-brand::before, .login-brand::after { content: ""; position: absolute; border-radius: 999px; background: rgba(255,255,255,.10); }
.login-brand::before { width: 480px; height: 480px; right: -180px; top: -160px; }
.login-brand::after { width: 300px; height: 300px; left: -110px; bottom: -120px; }
.logo { display: flex; align-items: center; gap: 12px; font-weight: 900; font-size: 24px; letter-spacing: -.7px; position: relative; z-index: 1; }
.logo-mark { width: 44px; height: 44px; border-radius: 15px; display: grid; place-items: center; background: white; color: var(--orange); font-size: 24px; box-shadow: 0 10px 24px rgba(140,50,0,.20); }
.hero-copy { max-width: 590px; position: relative; z-index: 1; }
.hero-copy h1 { margin: 0 0 18px; font-size: clamp(42px, 5vw, 72px); line-height: .98; letter-spacing: -3px; }
.hero-copy p { font-size: 20px; line-height: 1.55; margin: 0; color: rgba(255,255,255,.82); }
.brand-foot { position: relative; z-index: 1; color: rgba(255,255,255,.68); font-size: 14px; }
.login-panel { padding: 56px clamp(28px, 7vw, 96px); display: flex; align-items: center; background: white; }
.login-card { width: 100%; max-width: 520px; margin: auto; }
.eyebrow { color: var(--orange); font-size: 13px; font-weight: 900; letter-spacing: 1.2px; text-transform: uppercase; }
.login-card h2 { margin: 10px 0 8px; font-size: 38px; letter-spacing: -1.5px; }
.login-card > p { margin: 0 0 28px; color: var(--muted); }
.quick-profiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 26px; }
.profile-button { text-align: left; border: 1px solid var(--line); border-radius: 18px; padding: 18px; background: white; transition: .2s ease; color: var(--navy); }
.profile-button:hover { transform: translateY(-2px); border-color: var(--orange); box-shadow: 0 12px 24px rgba(255,101,0,.10); }
.profile-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 13px; margin-bottom: 13px; background: var(--orange-soft); font-size: 20px; }
.profile-button strong, .profile-button span { display: block; }
.profile-button span { color: var(--muted); font-size: 13px; margin-top: 4px; }
.divider { display: flex; align-items: center; gap: 12px; color: #99a2ad; font-size: 12px; margin: 22px 0; }
.divider::before, .divider::after { content: ""; height: 1px; flex: 1; background: var(--line); }
.field { margin-bottom: 14px; }
.field label { display: block; font-size: 13px; font-weight: 800; margin-bottom: 7px; }
.field input { width: 100%; padding: 14px 15px; border: 1px solid var(--line); border-radius: 12px; outline: none; color: var(--navy); }
.field input:focus { border-color: var(--orange); box-shadow: 0 0 0 4px var(--orange-soft); }
.primary { width: 100%; border: 0; border-radius: 13px; padding: 15px 20px; background: var(--orange); color: white; font-weight: 900; box-shadow: 0 12px 20px rgba(255,101,0,.20); }
.primary:hover { background: var(--orange-dark); }

.shell { min-height: 100vh; }
.topbar { height: 78px; padding: 0 32px; display: flex; align-items: center; justify-content: space-between; background: white; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar .logo { color: var(--navy); font-size: 21px; }
.topbar .logo-mark { background: var(--orange); color: white; width: 40px; height: 40px; }
.top-actions { display: flex; align-items: center; gap: 10px; }
.role-chip { border-radius: 999px; padding: 8px 12px; background: var(--orange-soft); color: var(--orange-dark); font-size: 12px; font-weight: 900; text-transform: uppercase; }
.ghost { border: 1px solid var(--line); background: white; color: var(--navy); border-radius: 11px; padding: 10px 13px; font-weight: 800; }
.ghost:hover { border-color: var(--orange); color: var(--orange); }
.workspace { width: min(1240px, calc(100% - 40px)); margin: 0 auto; padding: 42px 0 80px; }
.page-head { display: flex; justify-content: space-between; gap: 24px; align-items: flex-end; margin-bottom: 28px; }
.page-head h1 { margin: 5px 0 5px; font-size: clamp(31px, 4vw, 46px); letter-spacing: -2px; }
.page-head p { margin: 0; color: var(--muted); }
.head-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.action { border: 0; border-radius: 12px; padding: 12px 16px; font-weight: 900; background: var(--orange); color: white; }
.action.secondary { background: white; border: 1px solid var(--line); color: var(--navy); }
.action.danger { background: #fff0f0; color: var(--red); }
.action:disabled { opacity: .45; cursor: wait; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 28px; }
.metric { background: white; border: 1px solid var(--line); border-radius: 18px; padding: 20px; }
.metric span { color: var(--muted); font-size: 13px; font-weight: 700; }
.metric strong { display: block; font-size: 31px; margin-top: 8px; letter-spacing: -1.2px; }
.section { background: white; border: 1px solid var(--line); border-radius: 22px; box-shadow: 0 8px 28px rgba(21,38,58,.05); margin-bottom: 20px; overflow: hidden; }
.section-head { padding: 20px 22px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); }
.section-head h2 { font-size: 18px; margin: 0; }
.count { min-width: 28px; height: 28px; display: grid; place-items: center; padding: 0 9px; border-radius: 999px; background: var(--orange-soft); color: var(--orange-dark); font-weight: 900; font-size: 12px; }
.orders { display: grid; }
.order { padding: 20px 22px; display: grid; grid-template-columns: 1.25fr .9fr .8fr auto; align-items: center; gap: 18px; border-bottom: 1px solid var(--line); }
.order:last-child { border-bottom: 0; }
.order-title { font-weight: 900; font-size: 16px; }
.order-sub { color: var(--muted); font-size: 13px; margin-top: 5px; line-height: 1.4; }
.amount { font-size: 17px; font-weight: 900; }
.status { display: inline-flex; width: fit-content; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 999px; background: #edf2f7; font-size: 11px; font-weight: 900; white-space: nowrap; }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.status.orange { color: var(--orange-dark); background: var(--orange-soft); }
.status.green { color: #087c56; background: #e6f8f1; }
.status.blue { color: #1f63a7; background: #e8f2ff; }
.status.red { color: #ad3434; background: #ffeded; }
.order-actions { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }
.small-action { border: 0; padding: 10px 12px; border-radius: 10px; background: var(--navy); color: white; font-weight: 850; font-size: 12px; white-space: nowrap; }
.small-action.orange { background: var(--orange); }
.small-action.light { background: var(--orange-soft); color: var(--orange-dark); }
.small-action.red { background: #ffeded; color: var(--red); }
.empty { padding: 54px 24px; text-align: center; color: var(--muted); }
.empty-icon { width: 58px; height: 58px; display: grid; place-items: center; border-radius: 18px; margin: 0 auto 14px; background: var(--orange-soft); font-size: 26px; }
.notice { margin-bottom: 20px; border: 1px solid #ffd5b9; background: #fff7f1; color: #914316; padding: 14px 17px; border-radius: 14px; font-size: 13px; line-height: 1.45; }
.toast { position: fixed; right: 24px; bottom: 24px; max-width: 390px; padding: 15px 18px; border-radius: 14px; background: var(--navy); color: white; box-shadow: var(--shadow); transform: translateY(120px); opacity: 0; transition: .25s ease; z-index: 100; }
.toast.show { transform: translateY(0); opacity: 1; }
.toast.error { background: var(--red); }
.spinner { width: 18px; height: 18px; display: inline-block; border: 2px solid rgba(255,255,255,.45); border-top-color: white; border-radius: 50%; animation: spin .75s linear infinite; vertical-align: middle; }
@keyframes spin { to { transform: rotate(360deg); } }

@media (max-width: 900px) {
  .login-shell { grid-template-columns: 1fr; }
  .login-brand { min-height: 290px; padding: 36px; }
  .hero-copy h1 { font-size: 46px; margin-top: 54px; }
  .hero-copy p { font-size: 16px; }
  .brand-foot { display: none; }
  .login-panel { padding: 38px 24px; }
  .metrics { grid-template-columns: 1fr 1fr; }
  .order { grid-template-columns: 1fr 1fr; }
  .order-actions { justify-content: flex-start; grid-column: 1 / -1; }
}

@media (max-width: 600px) {
  .login-brand { min-height: 245px; padding: 24px; }
  .hero-copy h1 { font-size: 38px; letter-spacing: -2px; }
  .hero-copy p { display: none; }
  .quick-profiles, .metrics { grid-template-columns: 1fr; }
  .topbar { height: auto; padding: 14px 18px; }
  .topbar .logo span:last-child { display: none; }
  .role-chip { display: none; }
  .workspace { width: min(100% - 24px, 1240px); padding-top: 26px; }
  .page-head { align-items: flex-start; flex-direction: column; }
  .page-head h1 { font-size: 34px; }
  .head-actions { width: 100%; }
  .head-actions .action { flex: 1; }
  .order { grid-template-columns: 1fr; }
  .order-actions { grid-column: auto; }
}

/* =========================================================
   V10.4.2 - TIMELINE DO PEDIDO
   ========================================================= */

.order-timeline {
  display: block;
  padding: 28px;
  background: #ffffff;
}

.timeline-item {
  position: relative;
  display: grid !important;
  grid-template-columns: 44px minmax(0, 1fr) 130px;
  column-gap: 16px;
  min-height: 94px;
}

.timeline-marker {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: flex-start;
}

.timeline-marker::after {
  content: "";
  position: absolute;
  z-index: 0;
  top: 27px;
  bottom: -2px;
  left: 50%;
  width: 2px;
  transform: translateX(-50%);
  background: #dfe4ea;
}

.timeline-item:last-child .timeline-marker::after {
  display: none;
}

.timeline-dot {
  position: relative;
  z-index: 2;
  display: flex !important;
  align-items: center;
  justify-content: center;
  width: 28px !important;
  height: 28px !important;
  min-width: 28px;
  border: 2px solid #13a875;
  border-radius: 50% !important;
  background: #e8f8f2;
  color: #087c56;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.timeline-item.refused .timeline-dot {
  border-color: #d84a4a;
  background: #ffeded;
  color: #ad3434;
}

.timeline-item.current .timeline-dot {
  border-color: #ff6500;
  background: #fff0e6;
  color: #d94f00;
}

.timeline-content {
  padding: 2px 0 28px;
}

.timeline-content strong {
  display: block;
  margin-bottom: 6px;
  color: #15263a;
  font-size: 16px;
  font-weight: 800;
}

.timeline-content p {
  margin: 0;
  color: #6e7c8f;
  font-size: 14px;
  line-height: 1.5;
}

.timeline-time {
  padding-top: 4px;
  color: #6e7c8f;
  font-size: 12px;
  text-align: right !important;
  white-space: nowrap;
}

@media (max-width: 640px) {
  .order-timeline {
    padding: 22px 16px;
  }

  .timeline-item {
    grid-template-columns: 38px minmax(0, 1fr);
    column-gap: 10px;
    min-height: 105px;
  }

  .timeline-time {
    grid-column: 2;
    text-align: left !important;
    margin-top: -24px;
    padding-bottom: 22px;
  }

  .timeline-content {
    padding-bottom: 18px;
  }
}


/* =========================================================
   V10.5.1 - ALERTAS OPERACIONAIS
   ========================================================= */

.metric-alert {
  position: relative;
  border-color: #ffb37f !important;
  background: #fff8f3 !important;
}

.metric-alert::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  width: 5px;
  border-radius: 12px 0 0 12px;
  background: #ff6500;
}

.metric-alert strong {
  color: #d94f00;
}

.metric-alert small {
  display: block;
  margin-top: 8px;
  color: #d94f00;
  font-size: 12px;
  font-weight: 700;
}

.operation-alerts {
  display: grid;
  gap: 12px;
  padding: 22px 28px 28px;
}

.operation-alert {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 18px;
  border: 1px solid #e6e9ed;
  border-radius: 14px;
  background: #ffffff;
}

.operation-alert-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #fff0e6;
  color: #d94f00;
  font-weight: 900;
}

.operation-alert-content strong {
  display: block;
  margin-bottom: 3px;
  color: #15263a;
}

.operation-alert-content span {
  color: #d94f00;
  font-size: 14px;
  font-weight: 800;
}

.operation-alert-content p {
  margin: 5px 0 0;
  color: #6e7c8f;
  font-size: 13px;
}

.operation-alert-time {
  color: #6e7c8f;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.operation-alert.attention {
  border-color: #f2c36b;
  background: #fffaf0;
}

.operation-alert.critical {
  border-color: #e79a9a;
  background: #fff5f5;
}

.operation-alert.critical .operation-alert-icon {
  background: #ffeded;
  color: #d84a4a;
}

.operation-alert.critical .operation-alert-content span,
.operation-alert.critical .operation-alert-time {
  color: #d84a4a;
}

.operation-alert-empty {
  padding: 18px;
  border: 1px dashed #d8dde5;
  border-radius: 14px;
  color: #6e7c8f;
  text-align: center;
}

@media (max-width: 640px) {
  .operation-alerts {
    padding: 18px 16px;
  }

  .operation-alert {
    grid-template-columns: 36px minmax(0, 1fr);
  }

  .operation-alert-time {
    grid-column: 2;
  }
}

/* =========================================================
   V10.6 - DETALHE OPERACIONAL DO PEDIDO
   ========================================================= */

.admin-order-card {
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease;
}

.admin-order-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(21, 38, 58, .08);
}

.admin-order-current {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
  padding: 22px 26px;
  border: 1px solid #e6e9ed;
  border-radius: 14px;
  background: #ffffff;
}

.admin-order-current div {
  display: grid;
  gap: 5px;
}

.admin-order-current div span {
  color: #6e7c8f;
  font-size: 13px;
}

.admin-order-current div strong {
  color: #15263a;
  font-size: 20px;
}

.admin-current-driver {
  display: grid;
  gap: 5px;
  padding: 24px 28px 28px;
}

.admin-current-driver strong {
  color: #15263a;
  font-size: 18px;
}

.admin-current-driver span {
  color: #6e7c8f;
  font-size: 14px;
}

.admin-offers {
  display: grid;
  gap: 12px;
  padding: 22px 28px 28px;
}

.admin-offer-card {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
  padding: 17px;
  border: 1px solid #e6e9ed;
  border-radius: 14px;
  background: #ffffff;
}

.admin-offer-number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #f1f4f7;
  color: #15263a;
  font-weight: 800;
}

.admin-offer-main strong {
  display: inline-block;
  margin-right: 10px;
  color: #15263a;
}

.admin-offer-main p {
  margin: 6px 0 0;
  color: #6e7c8f;
  font-size: 13px;
}

.admin-offer-status {
  display: inline-flex;
  padding: 5px 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
}

.admin-offer-status.PENDING {
  background: #fff0e6;
  color: #d94f00;
}

.admin-offer-status.ACCEPTED {
  background: #e8f8f2;
  color: #087c56;
}

.admin-offer-status.REFUSED {
  background: #ffeded;
  color: #ad3434;
}

.admin-offer-status.EXPIRED {
  background: #f1f4f7;
  color: #6e7c8f;
}

@media (max-width: 640px) {
  .admin-order-current {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-offers {
    padding: 18px 16px;
  }
}

/* =========================================================
   V10.8 - Ciclo de busca de entregador
   ========================================================= */

.admin-search-cycle {
  margin: 18px 0;
  padding: 18px 20px;
  border: 1px solid #e5e7eb;
  border-radius: 16px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.admin-search-cycle-info {
  min-width: 220px;
}

.admin-search-cycle-info strong {
  display: block;
  margin-top: 4px;
  font-size: 18px;
}

.admin-search-cycle-info p {
  margin: 6px 0 0;
  font-size: 14px;
  opacity: 0.75;
}

.admin-search-running {
  padding: 12px 16px;
  border-radius: 12px;
  background: #f3f4f6;
  font-size: 14px;
  font-weight: 600;
}

.admin-search-cycle.limit-reached {
  border-color: #f59e0b;
  background: #fffbeb;
}

.admin-search-intervention {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #fff7ed;
}

.admin-search-intervention strong {
  display: block;
  font-size: 15px;
}

.admin-search-intervention p {
  margin: 5px 0 0;
  font-size: 13px;
  line-height: 1.4;
  opacity: 0.8;
}

.admin-search-intervention .action {
  flex-shrink: 0;
}

.admin-search-intervention .action:disabled {
  opacity: 0.6;
  cursor: wait;
}

@media (max-width: 720px) {

  .admin-search-cycle {
    align-items: stretch;
    flex-direction: column;
    padding: 16px;
  }

  .admin-search-intervention {
    align-items: stretch;
    flex-direction: column;
  }

  .admin-search-intervention .action {
    width: 100%;
  }

  .admin-search-running {
    width: 100%;
    box-sizing: border-box;
  }
}

/* V10.8 - Detalhe completo do pedido ADMIN */

.admin-order-details {
  display: grid;
  gap: 16px;
  margin: 18px 0;
}

.admin-order-detail-card {
  background: var(--surface, #fff);
  border: 1px solid rgba(0, 0, 0, .08);
  border-radius: 16px;
  padding: 20px;
}

.admin-order-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 14px;
}

.admin-order-detail-grid > div,
.admin-order-address {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.admin-order-detail-grid span,
.admin-order-address span,
.admin-order-values span,
.admin-order-item span {
  font-size: 13px;
  opacity: .65;
}

.admin-order-address {
  margin-top: 14px;
}

.admin-order-address strong {
  line-height: 1.5;
}

.admin-order-items {
  margin-top: 14px;
}

.admin-order-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
  border-bottom: 1px solid rgba(0, 0, 0, .07);
}

.admin-order-item-product {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.admin-order-item-total {
  white-space: nowrap;
}

.admin-order-values {
  width: min(100%, 360px);
  margin: 18px 0 0 auto;
}

.admin-order-values > div {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  padding: 7px 0;
}

.admin-order-grand-total {
  margin-top: 7px;
  padding-top: 14px !important;
  border-top: 1px solid rgba(0, 0, 0, .12);
  font-size: 18px;
}

.admin-order-grand-total strong {
  font-size: 21px;
}

@media (max-width: 720px) {
  .admin-order-detail-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .admin-order-detail-card {
    padding: 16px;
  }

  .admin-order-item {
    align-items: flex-start;
  }

  .admin-order-values {
    width: 100%;
  }
}

/* V10.8 - Alertas operacionais clicáveis */
.admin-operation-alert-clickable {
  cursor: pointer;
  transition: transform .15s ease, box-shadow .15s ease, filter .15s ease;
}

.admin-operation-alert-clickable:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, .10);
  filter: brightness(.99);
}

.admin-operation-alert-clickable:focus-visible {
  outline: 3px solid rgba(255, 122, 0, .35);
  outline-offset: 3px;
}

/* V10.9 - Painel do Entregador */

.driver-offer-countdown {
  margin-top: 8px;
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

.driver-offer-countdown-warning {
  font-weight: 800;
}


/* ===== V10.9 - Rastreamento público ===== */

.public-tracking-shell {
  min-height: 100vh;
  background: #f6f7f9;
}

.public-tracking-header {
  background: #ffffff;
  border-bottom: 1px solid #e8e8e8;
  padding: 18px 24px;
  display: flex;
  align-items: center;
}

.public-tracking-main {
  width: min(760px, calc(100% - 32px));
  margin: 0 auto;
  padding: 48px 0;
}

.tracking-card {
  background: #ffffff;
  border-radius: 22px;
  padding: 32px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, .08);
}

.tracking-card h1 {
  margin: 8px 0 10px;
  font-size: clamp(28px, 5vw, 42px);
  line-height: 1.08;
}

.tracking-order {
  margin-top: 18px;
  font-size: 16px;
}

.tracking-status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin: 22px 0;
}

.tracking-live {
  font-size: 14px;
  color: #737373;
}

.tracking-live.active {
  color: #16803c;
  font-weight: 700;
}

.tracking-map-placeholder {
  min-height: 330px;
  border-radius: 20px;
  background:
    radial-gradient(circle at 25% 30%, rgba(255,255,255,.9), transparent 25%),
    linear-gradient(135deg, #eef1f4, #e4e8ec);
  border: 1px solid #dde1e5;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 30px;
  gap: 8px;
}

.tracking-map-placeholder span {
  color: #6b7280;
}

.tracking-scooter {
  font-size: 52px;
  margin-bottom: 8px;
}

.tracking-footer {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin-top: 18px;
  color: #6b7280;
  font-size: 14px;
}

@media (max-width: 600px) {
  .public-tracking-header {
    padding: 16px;
  }

  .public-tracking-main {
    width: calc(100% - 20px);
    padding: 18px 0;
  }

  .tracking-card {
    padding: 22px 18px;
    border-radius: 18px;
  }

  .tracking-map-placeholder {
    min-height: 280px;
  }

  .tracking-footer {
    flex-direction: column;
    gap: 5px;
  }
}

/* ===== V10.9 - Mapa público ===== */

.tracking-map {
  width: 100%;
  height: 430px;
  border-radius: 20px;
  border: 1px solid #dde1e5;
  overflow: hidden;
  z-index: 1;
}

.tracking-driver-icon {
  background: transparent;
  border: none;
}

.tracking-driver-marker {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #ffffff;
  border-radius: 50%;
  font-size: 28px;
  box-shadow: 0 5px 18px rgba(0,0,0,.25);
  border: 3px solid #ff6500;
}

@media (max-width: 600px) {
  .tracking-map {
    height: 350px;
    border-radius: 16px;
  }
}

.tracking-share-area {
  margin-top: 18px;
  display: flex;
  justify-content: center;
}

.tracking-share-button {
  width: 100%;
  min-height: 48px;
  border: 0;
  border-radius: 14px;
  padding: 12px 18px;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  background: #ff6b00;
  color: #fff;
  transition:
    transform 0.15s ease,
    opacity 0.15s ease;
}

.tracking-share-button:hover {
  opacity: 0.92;
}

.tracking-share-button:active {
  transform: scale(0.99);
}

@media (max-width: 640px) {
  .tracking-share-button {
    min-height: 52px;
  }
}

/* V10.10 - Rastreamento no detalhe administrativo */

.admin-tracking-card {
  margin: 20px 0;
  padding: 22px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 18px;
  background: var(--surface, #fff);
}

.admin-tracking-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.admin-tracking-title {
  display: block;
  margin-top: 5px;
  font-size: 18px;
}

.admin-tracking-state {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 7px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.admin-tracking-state.active {
  background: #e8f7ee;
  color: #16733c;
}

.admin-tracking-state.finished {
  background: #eef1f4;
  color: #59636e;
}

.admin-tracking-state.waiting {
  background: #fff4df;
  color: #986200;
}

.admin-tracking-info {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-top: 20px;
}

.admin-tracking-info > div {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.admin-tracking-info span {
  font-size: 12px;
  opacity: 0.65;
}

.admin-tracking-actions {
  display: flex;
  gap: 10px;
  margin-top: 20px;
  flex-wrap: wrap;
}

.admin-tracking-empty {
  margin: 16px 0 0;
  opacity: 0.7;
}

@media (max-width: 700px) {
  .admin-tracking-header {
    flex-direction: column;
  }

  .admin-tracking-info {
    grid-template-columns: 1fr;
  }

  .admin-tracking-actions {
    flex-direction: column;
  }

  .admin-tracking-actions .action {
    width: 100%;
  }
}

/* V10.10 Etapa 2 - Tracking na Central de Operacoes */

.admin-order-tracking {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
}

.admin-order-tracking-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
}

.admin-order-tracking.active {
  background: #e8f7ee;
  color: #16733c;
}

.admin-order-tracking.stale {
  background: #fff1e5;
  color: #b45309;
}

.admin-order-tracking.not-started {
  background: #eef1f4;
  color: #68727d;
}

.tracking-intelligence {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.tracking-intelligence-item {
  padding: 16px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 14px;
  background: rgba(0, 0, 0, 0.025);
}

.tracking-intelligence-item span {
  display: block;
  margin-bottom: 6px;
  font-size: 0.82rem;
  opacity: 0.7;
}

.tracking-intelligence-item strong {
  display: block;
  font-size: 1.15rem;
  line-height: 1.25;
}

@media (max-width: 600px) {
  .tracking-intelligence {
    grid-template-columns: 1fr;
  }
}

.customer-address-location {
  margin-top: 18px;
}

.customer-address-map-status {
  margin-top: 10px;
  font-size: 0.9rem;
  opacity: 0.75;
}

.customer-address-map {
  width: 100%;
  height: 320px;
  margin-top: 14px;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.customer-address-map.leaflet-container {
  display: block;
}

@media (max-width: 600px) {
  .customer-address-map {
    height: 260px;
  }
}
