.account-system-pending .dashboard-shell {
  visibility: hidden;
}

.account-page {
  padding-bottom: 52px;
}

.account-page .page-heading {
  align-items: center;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--primary);
  font-size: 10px;
  font-weight: 800;
}

.back-link svg {
  width: 14px;
}

.account-panel {
  min-width: 0;
  padding: 18px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 17px;
  box-shadow: 0 10px 30px rgba(15, 118, 110, 0.07);
}

.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 16px;
  padding-bottom: 14px;
  border-bottom: 1px solid #f1f5f9;
}

.panel-heading h2 {
  margin: 0;
  font-size: 18px;
  letter-spacing: -0.025em;
}

.panel-heading p {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
}

.primary-button,
.secondary-button,
.danger-button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 10px;
  font-weight: 800;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease;
}

.primary-button {
  color: #fff;
  background: var(--primary);
  border: 1px solid var(--primary);
  box-shadow: 0 8px 20px rgba(15, 118, 110, 0.16);
}

.primary-button:hover {
  background: var(--primary-dark);
}

.secondary-button {
  color: var(--primary);
  background: #fff;
  border: 1px solid #99f6e4;
}

.secondary-button:hover {
  background: #f0fdfa;
}

.danger-button {
  color: #b91c1c;
  background: #fff;
  border: 1px solid #fecaca;
}

.primary-button svg,
.secondary-button svg,
.danger-button svg {
  width: 16px;
}

.filter-tabs {
  display: flex;
  gap: 7px;
  margin-bottom: 15px;
  padding-bottom: 3px;
  overflow-x: auto;
  scrollbar-width: none;
}

.filter-tabs::-webkit-scrollbar {
  display: none;
}

.filter-tabs button {
  min-height: 38px;
  flex: 0 0 auto;
  padding: 0 14px;
  color: #475569;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
  font-size: 9px;
  font-weight: 800;
}

.filter-tabs button.is-active {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
}

.full-orders-list {
  display: grid;
  gap: 12px;
}

.full-order {
  display: grid;
  gap: 15px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.full-order:hover {
  border-color: #99f6e4;
  box-shadow: 0 10px 26px rgba(15, 118, 110, 0.08);
}

.full-order__head,
.full-order__meta,
.full-order__actions,
.summary-line,
.info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.full-order__identity {
  display: flex;
  align-items: center;
  gap: 11px;
}

.full-order__identity strong {
  display: block;
  font-size: 12px;
}

.full-order__identity small {
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
}

.full-order__meta {
  align-items: flex-start;
  padding: 13px 0;
  border-block: 1px solid #f1f5f9;
}

.meta-item {
  display: grid;
  gap: 3px;
}

.meta-item span {
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
}

.meta-item strong {
  font-size: 10px;
}

.full-order__actions {
  justify-content: flex-start;
}

.full-order__actions a {
  flex: 1;
}

.empty-state {
  display: none;
  justify-items: center;
  padding: 48px 20px;
  text-align: center;
}

.empty-state.is-visible {
  display: grid;
}

.empty-state__icon {
  width: 64px;
  height: 64px;
  display: grid;
  place-items: center;
  color: var(--primary);
  background: #f0fdfa;
  border: 1px solid #ccfbf1;
  border-radius: 20px;
}

.empty-state__icon svg {
  width: 30px;
}

.empty-state h3 {
  margin: 16px 0 6px;
  font-size: 18px;
}

.empty-state p {
  max-width: 360px;
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 600;
  line-height: 1.6;
}

.details-grid,
.settings-grid,
.tracking-grid {
  display: grid;
  gap: 14px;
}

.order-hero {
  display: grid;
  gap: 16px;
  padding: 20px;
  color: #fff;
  background: linear-gradient(135deg, #064e49, var(--primary) 65%, #0d9488);
  border-radius: 17px;
  box-shadow: 0 15px 36px rgba(15, 118, 110, 0.15);
}

.order-hero h2 {
  margin: 4px 0;
  font-size: 22px;
}

.order-hero p {
  margin: 0;
  color: #ccfbf1;
  font-size: 10px;
  font-weight: 600;
}

.order-hero__actions {
  display: grid;
  gap: 8px;
}

.order-hero .primary-button {
  color: var(--primary-dark);
  background: #fff;
  border-color: #fff;
}

.order-hero .secondary-button {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.35);
}

.info-list {
  display: grid;
  gap: 12px;
}

.info-row {
  align-items: flex-start;
  padding-bottom: 12px;
  border-bottom: 1px solid #f1f5f9;
}

.info-row:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.info-row span {
  color: var(--muted);
  font-size: 9px;
  font-weight: 700;
}

.info-row strong,
.info-row address {
  margin: 0;
  color: #334155;
  font-size: 10px;
  font-style: normal;
  font-weight: 800;
  line-height: 1.6;
  text-align: end;
}

.product-list {
  display: grid;
}

.order-product {
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  align-items: center;
  gap: 11px;
  padding: 13px 0;
  border-bottom: 1px solid #f1f5f9;
}

.order-product:last-child {
  border-bottom: 0;
}

.product-thumb {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  color: var(--primary);
  background: linear-gradient(145deg, #f0fdfa, #dcfaf5);
  border: 1px solid #ccfbf1;
  border-radius: 12px;
}

.product-thumb svg {
  width: 30px;
}

.order-product h3 {
  margin: 0 0 4px;
  font-size: 10px;
}

.order-product p {
  margin: 0;
  color: var(--muted);
  font-size: 8px;
  font-weight: 600;
}

.order-product > strong {
  font-size: 10px;
  white-space: nowrap;
}

.summary-lines {
  display: grid;
  gap: 11px;
}

.summary-line {
  color: #475569;
  font-size: 10px;
  font-weight: 600;
}

.summary-line strong {
  color: var(--ink);
}

.summary-line--total {
  margin-top: 2px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  font-weight: 800;
}

.track-search {
  display: grid;
  gap: 9px;
}

.track-search label,
.form-field {
  display: grid;
  gap: 7px;
  color: #475569;
  font-size: 10px;
  font-weight: 800;
}

.track-search__control {
  display: grid;
  gap: 8px;
}

.track-search input,
.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  min-height: 46px;
  padding: 0 13px;
  color: var(--ink);
  background: #f8fafc;
  border: 1px solid #dbe5e4;
  border-radius: 10px;
  outline: 0;
  font: inherit;
  font-size: 10px;
}

.form-field textarea {
  min-height: 90px;
  padding-block: 12px;
  resize: vertical;
}

.track-search input:focus,
.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  background: #fff;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(20, 184, 166, 0.1);
}

.tracking-result {
  display: grid;
  gap: 14px;
}

.delivery-summary {
  display: grid;
  gap: 12px;
  padding: 15px;
  color: #fff;
  background: linear-gradient(135deg, #064e49, var(--primary));
  border-radius: 13px;
}

.delivery-summary span {
  color: #99f6e4;
  font-size: 8px;
  font-weight: 800;
  text-transform: uppercase;
}

.delivery-summary strong {
  display: block;
  margin-top: 3px;
  font-size: 13px;
}

.timeline {
  display: grid;
  margin-top: 4px;
}

.timeline-step {
  position: relative;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 11px;
  min-height: 76px;
}

.timeline-step:not(:last-child)::after {
  content: "";
  position: absolute;
  width: 2px;
  inset: 34px auto 0 16px;
  background: #dbe5e4;
}

.timeline-step.is-complete:not(:last-child)::after {
  background: var(--accent);
}

.timeline-step__mark {
  position: relative;
  z-index: 1;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: #94a3b8;
  background: #fff;
  border: 2px solid #dbe5e4;
  border-radius: 50%;
}

.timeline-step.is-complete .timeline-step__mark {
  color: #fff;
  background: var(--primary);
  border-color: var(--primary);
}

.timeline-step.is-current .timeline-step__mark {
  color: var(--primary);
  background: #ccfbf1;
  border-color: var(--accent);
  box-shadow: 0 0 0 5px rgba(20, 184, 166, 0.1);
}

.timeline-step__mark svg {
  width: 15px;
}

.timeline-step h3 {
  margin: 2px 0 4px;
  font-size: 11px;
}

.timeline-step p {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
}

.address-grid {
  display: grid;
  gap: 12px;
}

.saved-address {
  display: grid;
  gap: 15px;
  padding: 17px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 15px;
  box-shadow: 0 8px 24px rgba(15, 118, 110, 0.06);
}

.saved-address.is-default {
  background: #f8fffd;
  border-color: #99f6e4;
}

.saved-address__head,
.profile-card__head {
  display: flex;
  align-items: center;
  gap: 11px;
}

.saved-address__head > span,
.profile-avatar {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--primary);
  border-radius: 11px;
  font-size: 17px;
  font-weight: 800;
}

.saved-address__head svg {
  width: 20px;
}

.saved-address__head h2 {
  margin: 0 0 3px;
  font-size: 13px;
}

.default-badge {
  width: fit-content;
  padding: 3px 7px;
  color: var(--primary);
  background: #ccfbf1;
  border-radius: 999px;
  font-size: 7px;
  font-weight: 800;
}

.saved-address p {
  margin: 0;
  color: #475569;
  font-size: 10px;
  font-weight: 600;
  line-height: 1.7;
}

.address-actions {
  display: flex;
  gap: 8px;
  padding-top: 13px;
  border-top: 1px solid #edf2f7;
}

.address-actions button {
  flex: 1;
}

.account-form {
  display: grid;
  gap: 14px;
}

.form-grid {
  display: grid;
  gap: 13px;
}

.form-note {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
  font-weight: 600;
  line-height: 1.6;
}

.profile-card {
  padding: 19px;
  color: #fff;
  background: linear-gradient(145deg, #064e49, var(--primary));
  border-radius: 17px;
  box-shadow: 0 15px 36px rgba(15, 118, 110, 0.15);
}

.profile-avatar {
  width: 54px;
  height: 54px;
  flex-basis: 54px;
  color: var(--primary-dark);
  background: #ccfbf1;
}

.profile-card h2 {
  margin: 0 0 3px;
  font-size: 17px;
}

.profile-card p {
  margin: 0;
  color: #ccfbf1;
  font-size: 9px;
  font-weight: 600;
}

.profile-facts {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.profile-fact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 11px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 9px;
}

.profile-fact span {
  color: #99f6e4;
}

.profile-fact strong {
  min-width: 0;
  overflow-wrap: anywhere;
  text-align: end;
}

.password-field {
  position: relative;
  display: block;
}

.password-field input {
  padding-inline-end: 46px;
}

.password-toggle-inline {
  position: absolute;
  inset: 0 7px 0 auto;
  width: 38px;
  display: grid;
  place-items: center;
  color: var(--muted);
  background: transparent;
  border: 0;
  cursor: pointer;
}

.password-toggle-inline svg {
  width: 17px;
}

.strength {
  display: grid;
  gap: 7px;
}

.strength__bars {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 5px;
}

.strength__bars span {
  height: 4px;
  background: #e2e8f0;
  border-radius: 999px;
}

.strength[data-level="1"] .strength__bars span:nth-child(1) {
  background: #ef4444;
}

.strength[data-level="2"] .strength__bars span:nth-child(-n+2) {
  background: #f59e0b;
}

.strength[data-level="3"] .strength__bars span:nth-child(-n+3) {
  background: #14b8a6;
}

.strength[data-level="4"] .strength__bars span {
  background: #0f766e;
}

.strength small {
  color: var(--muted);
  font-size: 8px;
  font-weight: 700;
}

.password-tips {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 15px;
  color: #475569;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 12px;
  list-style: none;
  font-size: 9px;
  font-weight: 600;
}

.password-tips li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.password-tips li::before {
  content: "";
  width: 6px;
  height: 6px;
  flex: 0 0 6px;
  background: var(--accent);
  border-radius: 50%;
}

.account-modal {
  position: fixed;
  z-index: 150;
  inset: 0;
  display: grid;
  place-items: end center;
  padding: 14px;
  visibility: hidden;
  pointer-events: none;
}

.account-modal.is-open {
  visibility: visible;
  pointer-events: auto;
}

.account-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.52);
  opacity: 0;
  backdrop-filter: blur(3px);
  transition: opacity 180ms ease;
}

.account-modal.is-open .account-modal__backdrop {
  opacity: 1;
}

.account-modal__dialog {
  position: relative;
  width: min(100%, 620px);
  max-height: calc(100vh - 28px);
  overflow-y: auto;
  padding: 19px;
  background: #fff;
  border-radius: 18px;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.2);
  transform: translateY(25px);
  transition: transform 200ms ease;
}

.account-modal.is-open .account-modal__dialog {
  transform: translateY(0);
}

.modal-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 17px;
}

.modal-heading h2 {
  margin: 0;
  font-size: 18px;
}

.modal-close {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  color: #475569;
  background: #f8fafc;
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}

.modal-close svg {
  width: 17px;
}

.modal-actions {
  display: grid;
  gap: 8px;
  margin-top: 4px;
}

body.account-modal-open {
  overflow: hidden;
}

@media (min-width: 620px) {
  .account-panel {
    padding: 22px;
  }

  .full-order {
    padding: 18px;
  }

  .full-order__actions {
    justify-content: flex-end;
  }

  .full-order__actions a {
    flex: 0 0 auto;
    min-width: 120px;
  }

  .order-hero {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    padding: 24px;
  }

  .order-hero__actions {
    grid-template-columns: auto auto;
  }

  .track-search__control {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .track-search__control button {
    min-width: 120px;
  }

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

  .address-grid,
  .form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .form-field--wide {
    grid-column: 1 / -1;
  }

  .modal-actions {
    grid-template-columns: 1fr 1fr;
  }

  .account-modal {
    place-items: center;
  }
}

@media (min-width: 900px) {
  .details-grid {
    grid-template-columns: minmax(0, 1.55fr) minmax(290px, 0.75fr);
    align-items: start;
  }

  .details-main,
  .details-sidebar {
    display: grid;
    gap: 14px;
  }

  .tracking-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(280px, 0.7fr);
    align-items: start;
  }

  .settings-grid {
    grid-template-columns: minmax(260px, 0.68fr) minmax(0, 1.5fr);
    align-items: start;
  }
}

@media (max-width: 480px) {
  .account-panel {
    padding: 15px;
  }

  .panel-heading {
    align-items: flex-end;
  }

  .full-order__head,
  .full-order__meta {
    align-items: flex-start;
  }

  .full-order__meta {
    flex-wrap: wrap;
  }

  .full-order__actions,
  .address-actions {
    display: grid;
  }

  .primary-button,
  .secondary-button,
  .danger-button {
    width: 100%;
  }

  .order-product {
    grid-template-columns: 52px minmax(0, 1fr);
  }

  .order-product > strong {
    grid-column: 2;
  }

  .page-heading .back-link {
    display: none;
  }
}
