.driver-center {
  padding: 14px;
  border: 1px solid #e6e5e1;
  border-radius: 22px;
  background: #fff;
  box-shadow: 0 14px 34px rgba(20, 23, 28, .08);
}

.driver-center-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 11px;
}

.driver-center-head span {
  color: #ff6508;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
}

.driver-center-head h2 {
  margin: 1px 0 0;
  color: #17191d;
  font-size: 19px;
  letter-spacing: -.04em;
}

.driver-center-head > button {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 1px solid #e2e2de;
  border-radius: 12px;
  color: #17191d;
  background: #fff;
}

.driver-center-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.driver-center-metrics article {
  position: relative;
  display: grid;
  min-height: 76px;
  align-content: end;
  padding: 10px;
  overflow: hidden;
  border: 1px solid #e7e6e2;
  border-radius: 14px;
  background: #fafaf8;
}

.driver-center-metrics article::before {
  position: absolute;
  inset: 0 auto 0 0;
  width: 3px;
  background: #ff6508;
  content: "";
}

.driver-center-metrics span,
.driver-center-metrics small {
  overflow: hidden;
  color: #777e87;
  font-size: 8px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.driver-center-metrics strong {
  overflow: hidden;
  margin: 3px 0 1px;
  color: #17191d;
  font-size: clamp(14px, 4vw, 18px);
  letter-spacing: -.04em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.driver-center-metrics strong i {
  color: #ff6508;
  font-size: 12px;
}

.driver-center-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
  margin: 10px 0;
  padding: 4px;
  border-radius: 13px;
  background: #f1f1ee;
}

.driver-center-tabs button {
  position: relative;
  min-height: 38px;
  border: 0;
  border-radius: 10px;
  color: #747b84;
  background: transparent;
  font-size: 9px;
  font-weight: 800;
}

.driver-center-tabs button.active {
  color: #fff;
  background: #17191d;
}

.driver-admin-unread {
  position: absolute;
  top: 2px;
  right: 3px;
  display: grid;
  min-width: 16px;
  height: 16px;
  place-items: center;
  border-radius: 999px;
  color: #fff;
  background: #ff6508;
  font-size: 8px;
}

.driver-center-content {
  min-height: 110px;
}

.driver-center-loading,
.driver-center-empty {
  display: grid;
  min-height: 120px;
  place-items: center;
  align-content: center;
  gap: 5px;
  color: #7c828a;
  text-align: center;
  font-size: 11px;
}

.driver-center-empty.compact {
  min-height: 130px;
}

.driver-center-empty i {
  color: #ff6508;
  font-size: 24px;
}

.driver-center-empty p {
  max-width: 280px;
  margin: 0;
  font-size: 9px;
}

.driver-center-empty.is-error i {
  color: #dc3545;
}

.driver-center-summary {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(135px, .75fr);
  gap: 8px;
}

.driver-center-summary-copy,
.driver-center-summary > button {
  border: 1px solid #e7e6e2;
  border-radius: 14px;
  padding: 12px;
  text-align: left;
  background: #fafaf8;
}

.driver-center-summary-copy span,
.driver-center-summary > button span {
  display: block;
  color: #ff6508;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.driver-center-summary-copy strong,
.driver-center-summary > button strong {
  display: block;
  margin-top: 3px;
  color: #17191d;
  font-size: 12px;
}

.driver-center-summary-copy p {
  margin: 4px 0 0;
  color: #777e87;
  font-size: 9px;
  line-height: 1.45;
}

.driver-center-summary > button {
  border-color: #292c31;
  color: #fff;
  background: #17191d;
}

.driver-center-summary > button i {
  color: #ff6508;
}

.driver-center-summary > button strong {
  color: #fff;
}

.driver-history-list,
.driver-rating-list {
  display: grid;
  gap: 7px;
  max-height: 260px;
  overflow-y: auto;
}

.driver-history-list article {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  padding: 10px;
  border: 1px solid #e8e7e3;
  border-radius: 13px;
  background: #fafaf8;
}

.driver-history-icon {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  color: #fff;
  background: #17191d;
}

.driver-history-list article > div strong,
.driver-history-list article > div small {
  display: block;
}

.driver-history-list article > div strong {
  overflow: hidden;
  color: #202328;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.driver-history-list article > div small {
  color: #858b92;
  font-size: 8px;
}

.driver-history-earning {
  text-align: right;
}

.driver-history-earning span {
  display: inline-block;
  margin-top: 3px;
  border-radius: 999px;
  padding: 3px 6px;
  color: #70767e;
  background: #ececea;
  font-size: 7px;
  font-weight: 800;
}

.driver-history-earning .status-delivered {
  color: #15734f;
  background: #e3f7ee;
}

.driver-rating-list article {
  padding: 11px;
  border: 1px solid #e7e6e2;
  border-left: 3px solid #ff6508;
  border-radius: 13px;
  background: #fafaf8;
}

.driver-rating-list header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.driver-rating-list header strong {
  font-size: 10px;
}

.driver-rating-list header span {
  color: #ff6508;
  font-size: 9px;
}

.driver-rating-list p {
  margin: 6px 0;
  color: #3e444c;
  font-size: 10px;
  line-height: 1.45;
}

.driver-rating-list p.is-empty {
  color: #92979d;
  font-style: italic;
}

.driver-rating-list small {
  color: #27835f;
  font-size: 8px;
}

.driver-admin-inbox-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px 11px;
  border-radius: 13px;
  color: #fff;
  background: #17191d;
}

.driver-admin-inbox-head span,
.driver-admin-inbox-head strong {
  display: block;
}

.driver-admin-inbox-head span {
  color: #ff8a45;
  font-size: 7px;
  font-weight: 800;
  text-transform: uppercase;
}

.driver-admin-inbox-head strong {
  font-size: 10px;
}

.driver-admin-inbox-head small {
  color: #b5bac1;
  font-size: 8px;
}

.driver-admin-message-list {
  display: flex;
  min-height: 145px;
  max-height: 235px;
  flex-direction: column;
  gap: 7px;
  overflow-y: auto;
  padding: 9px 2px;
}

.driver-admin-message-list article {
  width: fit-content;
  max-width: 82%;
  padding: 8px 10px;
  border-radius: 12px;
}

.driver-admin-message-list article.mine {
  align-self: flex-end;
  color: #fff;
  border-bottom-right-radius: 3px;
  background: #17191d;
}

.driver-admin-message-list article.theirs {
  align-self: flex-start;
  color: #17191d;
  border: 1px solid #d7d9dc;
  border-bottom-left-radius: 3px;
  background: #f1f2f3;
  box-shadow: 0 3px 10px rgba(23,25,29,.06);
}

.driver-admin-message-list strong,
.driver-admin-message-list small {
  display: block;
  font-size: 7px;
}

.driver-admin-message-list p {
  margin: 2px 0;
  color: inherit;
  font-size: 10px;
  font-weight: 750;
  line-height: 1.4;
}

.driver-admin-message-list small {
  opacity: .64;
  text-align: right;
}

.driver-admin-message-list article.theirs strong {
  color: #353a41;
}

.driver-admin-message-list article.theirs p {
  color: #111318 !important;
}

.driver-admin-message-list article.theirs small {
  color: #626973;
  opacity: 1;
}

.driver-admin-message-list article.mine strong,
.driver-admin-message-list article.mine p,
.driver-admin-message-list article.mine small {
  color: #fff !important;
}

.driver-admin-compose {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 42px;
  gap: 7px;
}

.driver-admin-compose input {
  min-width: 0;
  min-height: 42px;
  border: 1px solid #dededa;
  border-radius: 12px;
  padding: 9px 11px;
  outline: 0;
  font-size: 10px;
}

.driver-admin-compose input:focus {
  border-color: #ff6508;
}

.driver-admin-compose button {
  border: 0;
  border-radius: 12px;
  color: #fff;
  background: #ff6508;
}

@media (max-width: 390px) {
  .driver-center {
    padding: 11px;
  }

  .driver-center-tabs button {
    font-size: 8px;
  }

  .driver-center-summary {
    grid-template-columns: 1fr;
  }
}

.driver-rating-feedback {
  position: fixed;
  z-index: 140;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(7, 10, 15, .72);
  backdrop-filter: blur(9px);
}

.driver-rating-feedback.hidden {
  display: none;
}

.driver-rating-feedback-card {
  position: relative;
  display: grid;
  justify-items: center;
  width: min(390px, 100%);
  padding: 30px 24px 22px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .82);
  border-radius: 30px;
  color: #17191d;
  background:
    radial-gradient(circle at 50% 0, rgba(255, 180, 68, .28), transparent 34%),
    #fff;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .34);
  text-align: center;
}

.driver-rating-feedback.needs-improvement .driver-rating-feedback-card {
  background:
    radial-gradient(circle at 50% 0, rgba(255, 101, 8, .22), transparent 34%),
    #fff;
}

.driver-rating-feedback-close {
  position: absolute;
  top: 13px;
  right: 13px;
  display: grid;
  width: 36px;
  height: 36px;
  place-items: center;
  border: 1px solid #e6e8eb;
  border-radius: 12px;
  color: #34383e;
  background: rgba(255, 255, 255, .9);
}

.driver-rating-feedback-icon {
  display: grid;
  width: 74px;
  height: 74px;
  place-items: center;
  margin-bottom: 12px;
  border-radius: 25px;
  color: #fff;
  background: linear-gradient(145deg, #ff9b21, #ff5800);
  box-shadow: 0 17px 32px rgba(255, 101, 8, .28);
  font-size: 31px;
  animation: driverRatingCelebrate .9s ease-in-out infinite alternate;
}

.driver-rating-feedback.needs-improvement .driver-rating-feedback-icon {
  background: linear-gradient(145deg, #ff7c1a, #d73b00);
}

.driver-rating-feedback-kicker {
  color: #ff6508;
  font-size: 9px;
  font-weight: 950;
  letter-spacing: .11em;
}

.driver-rating-feedback h2 {
  margin: 5px 0 7px;
  font-size: 31px;
  font-weight: 950;
  letter-spacing: -.04em;
}

.driver-rating-feedback-stars {
  display: flex;
  gap: 5px;
  margin: 5px 0 7px;
  color: #f6a400;
  font-size: 24px;
}

.driver-rating-feedback-card > strong {
  font-size: 14px;
}

.driver-rating-feedback-card > p {
  margin: 9px 0 0;
  color: #68707c;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}

.driver-rating-feedback blockquote {
  width: 100%;
  margin: 14px 0 0;
  padding: 12px;
  border-left: 4px solid #ff6508;
  border-radius: 12px;
  color: #4b5058;
  background: #fff3e9;
  font-size: 12px;
  font-weight: 800;
  text-align: left;
}

.driver-rating-feedback blockquote.hidden {
  display: none;
}

.driver-rating-feedback-ok {
  width: 100%;
  min-height: 48px;
  margin-top: 17px;
  border: 0;
  border-radius: 15px;
  color: #fff;
  background: #17191d;
  font-weight: 950;
}

@keyframes driverRatingCelebrate {
  from { transform: translateY(0) rotate(-3deg); }
  to { transform: translateY(-5px) rotate(3deg); }
}

body.driver-cash-paid-modal-open {
  overflow: hidden;
}

.driver-cash-paid-feedback {
  z-index: 26000;
  overflow: hidden;
  box-sizing: border-box;
  padding:
    max(20px, env(safe-area-inset-top, 0px))
    max(16px, env(safe-area-inset-right, 0px))
    max(20px, env(safe-area-inset-bottom, 0px))
    max(16px, env(safe-area-inset-left, 0px));
}

.driver-cash-paid-feedback-card {
  z-index: 2;
  max-height: calc(100vh - 40px);
  max-height: calc(100dvh - 40px);
  overflow-y: auto;
  box-sizing: border-box;
  animation: driverCashPaidCardPop .48s cubic-bezier(.2, .9, .25, 1.25) both;
}

.driver-cash-paid-icon {
  background: linear-gradient(145deg, #23b26d, #078348);
  box-shadow: 0 17px 32px rgba(8, 131, 72, .28);
}

.driver-cash-paid-feedback-card > .driver-cash-paid-amount {
  margin-top: 7px;
  color: #078348;
  font-size: clamp(30px, 9vw, 42px);
  font-weight: 950;
  line-height: 1;
  letter-spacing: -.04em;
}

.driver-cash-paid-folio {
  width: 100%;
  margin-top: 14px;
  padding: 10px 12px;
  border: 1px solid #bdebd1;
  border-radius: 13px;
  color: #08653b;
  background: #effcf5;
  font-size: 12px;
  font-weight: 900;
}

.driver-cash-paid-folio.hidden {
  display: none;
}

.driver-cash-paid-confetti {
  position: absolute;
  z-index: 1;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
}

.driver-cash-paid-confetti-piece {
  position: absolute;
  top: -28px;
  left: var(--confetti-x);
  width: 10px;
  height: 18px;
  border-radius: 3px;
  box-shadow: 0 2px 4px rgba(15, 23, 42, .1);
  animation: driverCashPaidConfettiFall var(--confetti-duration) cubic-bezier(.12, .7, .28, 1) var(--confetti-delay) both;
}

.driver-cash-paid-confetti-piece.shape-1 {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.driver-cash-paid-confetti-piece.shape-2 {
  width: 15px;
  height: 8px;
  border-radius: 8px;
}

@keyframes driverCashPaidConfettiFall {
  from {
    transform: translate3d(0, -8vh, 0) rotate(0deg);
    opacity: 0;
  }
  10% { opacity: 1; }
  to {
    transform: translate3d(var(--confetti-drift), 112vh, 0) rotate(var(--confetti-rotation));
    opacity: .96;
  }
}

@keyframes driverCashPaidCardPop {
  from {
    transform: translateY(18px) scale(.84);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}

@media (prefers-reduced-motion: reduce) {
  .driver-cash-paid-confetti-piece {
    display: none;
  }

  .driver-cash-paid-feedback-card,
  .driver-cash-paid-feedback .driver-rating-feedback-icon {
    animation: none;
  }
}

.driver-center-metrics {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.driver-center-metrics .driver-center-cash::before { background: #16a36a; }
.driver-center-metrics .driver-center-cash.is-warning::before { background: #e89a00; }
.driver-center-metrics .driver-center-cash.is-blocked::before { background: #d92d20; }
.driver-center-metrics .driver-center-cash.is-warning strong { color: #9a6200; }
.driver-center-metrics .driver-center-cash.is-blocked strong { color: #b42318; }

.driver-center-cash-blocked {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  margin-bottom: 9px;
  padding: 11px;
  border: 1px solid #f2b8b5;
  border-radius: 14px;
  color: #7a271a;
  background: #fff1f0;
}

.driver-center-cash-blocked > i {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 12px;
  color: #fff;
  background: #d92d20;
}

.driver-center-cash-blocked span,
.driver-center-cash-blocked strong,
.driver-center-cash-blocked p { display: block; }
.driver-center-cash-blocked span { font-size: 7px; font-weight: 950; letter-spacing: .08em; }
.driver-center-cash-blocked strong { margin-top: 2px; font-size: 10px; }
.driver-center-cash-blocked p { margin: 2px 0 0; font-size: 8px; }
.driver-center-cash-blocked button {
  min-height: 40px;
  border: 0;
  border-radius: 11px;
  padding: 0 11px;
  color: #fff;
  background: #17191d;
  font-size: 9px;
  font-weight: 900;
}

@media (max-width: 520px) {
  .driver-center-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .driver-center-cash-blocked { grid-template-columns: 34px minmax(0, 1fr); }
  .driver-center-cash-blocked > i { width: 34px; height: 34px; }
  .driver-center-cash-blocked button { grid-column: 1 / -1; width: 100%; }
}
