/* ============================================================
   ERA Group — storefront, cart, checkout & payment styles
   Loaded after style.css on every page.
   ============================================================ */

/* ---------- Header cart button ---------- */
.cart-toggle {
  position: relative;
  width: 42px;
  height: 42px;
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--dark);
  cursor: pointer;
  transition: all 0.25s ease;
}
.cart-toggle:hover { border-color: var(--primary); color: var(--primary); box-shadow: var(--shadow-sm); }
.cart-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 19px;
  height: 19px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  line-height: 19px;
  text-align: center;
  border: 2px solid #fff;
}
.cart-badge[hidden] { display: none; }

/* ---------- Header account + currency controls ---------- */
.account-toggle {
  width: 42px;
  height: 42px;
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--dark);
  transition: all 0.25s ease;
}
.account-toggle:hover { border-color: var(--primary); color: var(--primary); box-shadow: var(--shadow-sm); }
.currency-toggle {
  height: 38px;
  padding: 0 12px;
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--dark);
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.25s ease;
}
.currency-toggle:hover { border-color: var(--primary); color: var(--primary); box-shadow: var(--shadow-sm); }
.currency-toggle.is-usd { background: var(--primary-tint); border-color: var(--primary-soft); color: var(--primary); }
.currency-code { font-size: 10px; color: var(--muted); }
.currency-toggle.is-usd .currency-code { color: var(--primary); }
.price-alt { display: block; margin-top: 2px; font-size: 10.5px; color: var(--muted); font-weight: 500; letter-spacing: 0; }

/* ---------- Cart drawer ---------- */
.cart-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1390;
  background: rgba(17, 24, 39, 0.58);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}
.cart-backdrop.is-open { opacity: 1; visibility: visible; }
.cart-backdrop[hidden] { display: none; }

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  z-index: 1400;
  width: min(440px, 100vw);
  background: #fff;
  display: flex;
  flex-direction: column;
  transform: translateX(104%);
  transition: transform 0.38s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: -18px 0 60px rgba(17, 24, 39, 0.18);
}
.cart-drawer.is-open { transform: none; }
.cart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 26px 26px 18px;
  border-bottom: 1px solid var(--line);
}
.cart-head .eyebrow { display: block; margin-bottom: 2px; }
.cart-head h2 { font-size: 24px; line-height: 1.2; }
.cart-close {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--dark);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  flex: none;
  transition: all 0.2s ease;
}
.cart-close:hover { background: var(--primary); border-color: var(--primary); color: #fff; }
.cart-body { flex: 1; overflow-y: auto; padding: 8px 26px; }
.cart-empty { padding: 56px 0; text-align: center; font-size: 13.5px; color: var(--muted); }

.cart-item {
  display: grid;
  grid-template-columns: 70px 1fr;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.cart-item img {
  width: 70px;
  height: 88px;
  object-fit: cover;
  border-radius: 8px;
  background: var(--cream);
}
.cart-item-main { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.cart-item-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 8px; }
.cart-item-top strong { font-size: 13.5px; line-height: 1.35; }
.cart-remove {
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 11px;
  text-decoration: underline;
  cursor: pointer;
  flex: none;
  padding: 0;
}
.cart-remove:hover { color: #B42318; }
.cart-item-meta { font-size: 11.5px; color: var(--muted); }
.cart-item-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.cart-item-price { font-size: 12px; color: var(--ink); }
.cart-item-total { font-size: 13.5px; font-weight: 700; color: var(--dark); }

.cart-foot { padding: 18px 26px 26px; border-top: 1px solid var(--line); background: #fff; }
.cart-foot[hidden] { display: none; }
.cart-line { display: flex; justify-content: space-between; align-items: baseline; font-size: 14px; margin-bottom: 4px; }
.cart-line strong { font-size: 22px; color: var(--dark); }
.cart-hint { font-size: 11px; color: var(--muted); margin-bottom: 14px; }
.cart-clear {
  display: block;
  width: 100%;
  margin-top: 10px;
  background: none;
  border: 0;
  color: var(--muted);
  font-size: 11.5px;
  text-decoration: underline;
  cursor: pointer;
  padding: 4px;
}
.cart-clear:hover { color: #B42318; }

/* ---------- Quantity stepper ---------- */
.qty-stepper {
  display: inline-flex;
  align-items: stretch;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
}
.qty-stepper button {
  width: 36px;
  min-height: 38px;
  border: 0;
  background: #fff;
  color: var(--dark);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.qty-stepper button:hover { background: var(--primary-tint); color: var(--primary); }
.qty-stepper input {
  width: 66px;
  min-height: 38px;
  border: 0;
  border-left: 1px solid var(--line);
  border-right: 1px solid var(--line);
  text-align: center;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  color: var(--dark);
  background: #fff;
  -moz-appearance: textfield;
  appearance: textfield;
}
.qty-stepper input::-webkit-outer-spin-button,
.qty-stepper input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.qty-stepper input:focus { outline: none; }
.qty-stepper-sm button { width: 28px; min-height: 30px; font-size: 15px; }
.qty-stepper-sm input { width: 54px; min-height: 30px; font-size: 12px; }

/* ---------- Product cards ---------- */
.item-price {
  display: flex;
  align-items: baseline;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.item-price strong { font-size: 18px; line-height: 1.1; color: var(--dark); }
.item-price small { font-size: 10.5px; color: var(--muted); }
.item-price em {
  margin-left: auto;
  font-style: normal;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--primary);
  background: var(--primary-tint);
  border-radius: 999px;
  padding: 3px 8px;
  white-space: nowrap;
}
.item-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 13px;
}
.item-actions .btn {
  padding: 9px 6px;
  font-size: 11.5px;
  line-height: 1.2;
  border-radius: 6px;
  justify-content: center;
  white-space: nowrap;
}
.btn-dark { background: var(--dark); color: #fff; border-color: var(--dark); }
.btn-dark:hover { background: var(--dark-2); border-color: var(--dark-2); color: #fff; transform: translateY(-2px); }
.shop-loading { grid-column: 1 / -1; padding: 42px 0; text-align: center; color: var(--muted); font-size: 13px; letter-spacing: 0.04em; text-transform: uppercase; }

/* ---------- Product modal purchase panel ---------- */
.pm-price {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
  margin: 6px 0 14px;
}
.pm-price strong { font-size: 26px; line-height: 1; color: var(--primary); }
.pm-price span { font-size: 12px; color: var(--muted); }
.pm-price em {
  margin-left: auto;
  font-style: normal;
  font-size: 10.5px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-tint);
  padding: 4px 9px;
  border-radius: 999px;
}
.pm-purchase { border-top: 1px solid var(--line); margin-top: 20px; padding-top: 18px; }
.pm-options { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.pm-options label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--ink);
}
.pm-options select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  font: inherit;
  font-size: 13px;
  color: var(--dark);
}
.pm-options select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-tint); }
.pm-qty-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
  flex-wrap: wrap;
}
.pm-qty-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--ink); }
.pm-total { font-size: 13px; color: var(--muted); margin-top: 12px; }
.pm-total strong { color: var(--dark); font-size: 16px; margin-left: 4px; }
.pm-note { font-size: 11.5px; color: var(--muted); margin-top: 4px; min-height: 17px; }
.pm-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 14px; }
.pm-quote-link { display: inline-block; margin-top: 14px; font-size: 12px; font-weight: 600; color: var(--primary); text-decoration: underline; }
.pm-quote-link:hover { color: var(--primary-dark); }

/* ---------- Toast ---------- */
.shop-toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  z-index: 1500;
  transform: translate(-50%, 18px);
  max-width: calc(100vw - 32px);
  background: var(--dark);
  color: #fff;
  padding: 12px 20px;
  border-radius: 8px;
  box-shadow: var(--shadow-lg);
  font-size: 13px;
  line-height: 1.4;
  text-align: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s ease;
}
.shop-toast.is-visible { opacity: 1; transform: translate(-50%, 0); visibility: visible; }
.shop-toast.is-error { background: #B42318; }
body.cart-open { overflow: hidden; }

/* ============================================================
   Checkout
   ============================================================ */
.checkout-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(320px, 0.85fr);
  gap: 38px;
  align-items: start;
}
.checkout-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.checkout-card + .checkout-card { margin-top: 22px; }
.checkout-card h2 { font-size: 19px; line-height: 1.25; }
.checkout-card > p.checkout-sub { font-size: 12.5px; color: var(--muted); margin: 3px 0 20px; }
.checkout-account-note {
  margin: -6px 0 18px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  background: var(--cream);
  border-radius: 7px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
}
.checkout-account-note strong { color: var(--dark); }
.checkout-account-note a { color: var(--primary); font-weight: 700; text-decoration: underline; }
.checkout-currency { margin-bottom: 16px; padding-bottom: 16px; border-bottom: 1px dashed var(--line); }
.checkout-currency .field { max-width: 280px; }
.checkout-currency p { font-size: 10.5px; color: var(--muted); margin-top: 5px; line-height: 1.45; }
.summary-base { font-size: 10.5px; color: var(--muted); text-align: right; margin-top: 3px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px 16px; }
.form-grid .full { grid-column: 1 / -1; }
.field label { display: block; font-size: 12px; font-weight: 600; color: var(--ink); margin-bottom: 5px; }
.field label span { color: #B42318; }
.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 11px 13px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  font: inherit;
  font-size: 13.5px;
  color: var(--dark);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.field textarea { min-height: 86px; resize: vertical; }
.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-tint);
}
.field .hint { display: block; font-size: 11px; color: var(--muted); margin-top: 4px; }
.pay-options { display: flex; flex-direction: column; gap: 10px; margin-top: 4px; }
.pay-option {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 14px;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease;
}
.pay-option:hover { border-color: var(--primary-soft); }
.pay-option.is-selected { border-color: var(--primary); background: var(--primary-tint); }
.pay-option input { margin-top: 3px; accent-color: var(--primary); flex: none; }
.pay-option strong { display: block; font-size: 13.5px; line-height: 1.3; }
.pay-option span { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.pay-badges { display: flex; gap: 5px; margin-top: 7px; flex-wrap: wrap; }
.pay-badge {
  font-size: 9.5px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 2px 6px;
}
.checkout-actions { margin-top: 22px; }
.checkout-actions .btn { width: 100%; justify-content: center; }
.checkout-actions .btn[disabled] { opacity: 0.65; cursor: wait; transform: none; }
.checkout-note { font-size: 11px; color: var(--muted); text-align: center; margin-top: 10px; }
.checkout-terms {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  margin-top: 14px;
  font-size: 11.5px;
  line-height: 1.5;
  color: var(--muted);
  text-align: left;
  cursor: pointer;
}
.checkout-terms input { margin-top: 3px; accent-color: var(--primary); flex: none; }
.checkout-terms a { color: var(--primary); font-weight: 600; text-decoration: underline; }
.checkout-error {
  display: none;
  margin-top: 14px;
  padding: 11px 14px;
  border: 1px solid #F5C2C0;
  background: #FEF3F2;
  color: #B42318;
  border-radius: 7px;
  font-size: 12.5px;
  line-height: 1.45;
}
.checkout-error.is-visible { display: block; }
.order-summary { position: sticky; top: 92px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 24px; }
.order-summary h2 { font-size: 17px; margin-bottom: 12px; }
.summary-items { max-height: 330px; overflow-y: auto; }
.summary-item { display: flex; gap: 12px; padding: 11px 0; border-bottom: 1px dashed var(--line); }
.summary-item img { width: 52px; height: 64px; object-fit: cover; border-radius: 6px; background: var(--cream); flex: none; }
.si-main { flex: 1; min-width: 0; }
.si-main strong { display: block; font-size: 12.5px; line-height: 1.35; }
.si-main span { display: block; font-size: 11px; color: var(--muted); }
.si-price { font-size: 12.5px; font-weight: 700; white-space: nowrap; }
.summary-lines { margin-top: 12px; font-size: 12.5px; }
.summary-line { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; color: var(--ink); }
.summary-line span:last-child { font-weight: 600; color: var(--dark); }
.summary-total {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-top: 10px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
  font-size: 14px;
  font-weight: 600;
}
.summary-total strong { font-size: 21px; color: var(--dark); }
.summary-note { font-size: 10.5px; color: var(--muted); line-height: 1.5; margin-top: 10px; }
.checkout-empty { text-align: center; padding: 60px 20px; }
.checkout-empty svg { color: var(--primary-soft); margin-bottom: 14px; }
.checkout-empty h2 { font-size: 24px; margin-bottom: 6px; }
.checkout-empty p { font-size: 13.5px; color: var(--muted); margin-bottom: 20px; }

/* ============================================================
   Order confirmation
   ============================================================ */
.order-wrap { max-width: 860px; margin: 0 auto; }
.order-hero { text-align: center; margin-bottom: 26px; }
.order-hero .order-icon {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--primary-tint);
  color: var(--primary);
  margin-bottom: 14px;
}
.order-hero h1 { font-size: clamp(28px, 4vw, 38px); line-height: 1.15; }
.order-hero p { font-size: 13.5px; color: var(--muted); margin-top: 7px; }
.order-panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 26px; margin-top: 20px; }
.order-panel h2 { font-size: 16px; margin-bottom: 14px; }
.order-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }
.order-meta h3 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); margin-bottom: 6px; }
.order-meta p { font-size: 13px; line-height: 1.6; color: var(--ink); }
.order-lines { width: 100%; border-collapse: collapse; }
.order-lines th, .order-lines td { text-align: left; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 12.5px; vertical-align: top; }
.order-lines th { font-size: 10px; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); font-weight: 600; }
.order-lines td:last-child, .order-lines th:last-child { text-align: right; }
.order-totals { margin-left: auto; max-width: 320px; margin-top: 14px; font-size: 13px; }
.order-totals div { display: flex; justify-content: space-between; padding: 4px 0; }
.order-totals .grand { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 10px; font-size: 16px; font-weight: 700; }
.timeline { list-style: none; margin: 6px 0 0 5px; padding-left: 18px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding-bottom: 15px; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: -25px; top: 5px; width: 10px; height: 10px; border-radius: 50%; background: var(--primary); border: 2px solid #fff; box-shadow: 0 0 0 2px var(--primary-soft); }
.timeline strong { display: block; font-size: 12.5px; text-transform: capitalize; }
.timeline span { display: block; font-size: 11px; color: var(--muted); }
.timeline em { display: block; font-style: normal; font-size: 11.5px; color: var(--ink); margin-top: 2px; }
.order-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; justify-content: center; }
.order-actions .btn { justify-content: center; }

.status-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--cream-deep);
  color: var(--ink);
  white-space: nowrap;
}
.status-chip--pending { background: #FEF3C7; color: #92400E; }
.status-chip--confirmed { background: #D1FAE5; color: #065F46; }
.status-chip--shipped { background: #DBEAFE; color: #1E40AF; }
.status-chip--delivered { background: #D1FAE5; color: #065F46; }
.status-chip--rejected { background: #FEE2E2; color: #991B1B; }
.status-chip--cancelled { background: #E5E7EB; color: #374151; }
.status-chip--paid { background: #D1FAE5; color: #065F46; }
.status-chip--unpaid { background: #FEF3C7; color: #92400E; }
.status-chip--failed { background: #FEE2E2; color: #991B1B; }
.status-chip--refunded { background: #E5E7EB; color: #374151; }

/* ============================================================
   Sandbox payment page
   ============================================================ */
.demo-wrap { max-width: 520px; margin: 0 auto; }
.demo-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 30px; box-shadow: var(--shadow-md); }
.demo-card h1 { font-size: 24px; line-height: 1.2; margin-bottom: 4px; }
.demo-card .demo-sub { font-size: 12.5px; color: var(--muted); margin-bottom: 20px; }
.demo-warning {
  background: #FFFBEB;
  border: 1px solid #FCD34D;
  color: #92400E;
  border-radius: 8px;
  padding: 11px 13px;
  font-size: 11.5px;
  line-height: 1.5;
  margin-bottom: 20px;
}
.demo-row { display: flex; justify-content: space-between; gap: 12px; padding: 7px 0; border-bottom: 1px dashed var(--line); font-size: 12.5px; }
.demo-row:last-of-type { border-bottom: 0; }
.demo-row strong { color: var(--dark); }
.demo-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; }
.demo-total strong { font-size: 22px; }
.demo-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
.demo-actions .btn { justify-content: center; }

/* ============================================================
   Customer account + order tracking
   ============================================================ */
.account-shell[hidden], .account-dashboard[hidden], .account-auth-inner[hidden], .checkout-currency[hidden], .currency-toggle[hidden] { display: none; }
.account-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 26px;
  max-width: 1040px;
  margin: 0 auto;
  align-items: start;
}
.account-intro {
  position: sticky;
  top: 92px;
  background: var(--dark);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 30px;
  overflow: hidden;
}
.account-intro::after {
  content: "";
  position: absolute;
  width: 180px;
  height: 180px;
  right: -70px;
  bottom: -80px;
  border-radius: 50%;
  background: rgba(15, 110, 104, 0.35);
}
.account-intro .eyebrow { color: #9ED8D2; }
.account-intro h2 { font-size: 25px; line-height: 1.2; margin: 8px 0 10px; color: #fff; }
.account-intro p { font-size: 12.5px; line-height: 1.65; color: rgba(255, 255, 255, 0.78); }
.account-benefits { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 12px; }
.account-benefits li { display: flex; gap: 9px; align-items: flex-start; font-size: 12px; line-height: 1.45; color: rgba(255, 255, 255, 0.86); }
.account-benefits svg { flex: none; margin-top: 1px; color: #9ED8D2; }
.account-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 28px;
}
.account-card h1, .account-card h2 { font-size: 21px; line-height: 1.25; }
.account-card .account-sub { font-size: 12.5px; color: var(--muted); margin: 4px 0 20px; }
.account-tabs { display: flex; gap: 6px; padding: 4px; background: var(--cream); border-radius: 9px; margin-bottom: 20px; }
.account-tab {
  flex: 1;
  border: 0;
  background: transparent;
  border-radius: 7px;
  padding: 9px 12px;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  cursor: pointer;
}
.account-tab.is-active { background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }
.account-form[hidden] { display: none; }
.account-error {
  display: none;
  margin-top: 14px;
  padding: 10px 12px;
  border: 1px solid #F5C2C0;
  background: #FEF3F2;
  color: #B42318;
  border-radius: 7px;
  font-size: 12px;
  line-height: 1.45;
}
.account-error.is-visible { display: block; }
.account-form .btn { width: 100%; justify-content: center; margin-top: 18px; }
.account-switch { font-size: 11.5px; color: var(--muted); text-align: center; margin-top: 16px; line-height: 1.5; }
.account-switch a { color: var(--primary); font-weight: 700; text-decoration: underline; }
.account-dashboard { max-width: 1100px; margin: 0 auto; }
.account-welcome {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px 26px;
  margin-bottom: 22px;
}
.account-welcome-main { display: flex; align-items: center; gap: 14px; min-width: 0; }
.account-avatar {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: none;
  background: var(--primary-tint);
  color: var(--primary);
  font-weight: 800;
  font-size: 18px;
}
.account-welcome h2 { font-size: 19px; line-height: 1.2; }
.account-welcome p { font-size: 12px; color: var(--muted); margin-top: 2px; }
.account-welcome-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.account-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 0.75fr); gap: 22px; align-items: start; }
.account-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
}
.account-panel + .account-panel { margin-top: 22px; }
.account-panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 15px; }
.account-panel h2 { font-size: 17px; }
.account-panel-sub { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.account-order {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 15px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.account-order + .account-order { margin-top: 11px; }
.account-order:hover { border-color: var(--primary-soft); box-shadow: var(--shadow-sm); }
.account-order-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.account-order-head strong { display: block; font-size: 13px; color: var(--dark); }
.account-order-head span { display: block; font-size: 10.5px; color: var(--muted); margin-top: 2px; }
.account-order-chips { display: flex; gap: 5px; flex-wrap: wrap; }
.account-order-meta { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-top: 11px; padding-top: 11px; border-top: 1px dashed var(--line); }
.account-order-meta span { font-size: 11.5px; color: var(--muted); }
.account-order-meta strong { font-size: 14px; color: var(--dark); }
.account-order-link { display: inline-block; margin-top: 10px; font-size: 11.5px; font-weight: 700; color: var(--primary); text-decoration: underline; }
.account-empty { text-align: center; padding: 30px 12px; }
.account-empty p { font-size: 12.5px; color: var(--muted); margin-bottom: 14px; }
.account-profile-form .form-grid { gap: 12px 14px; }
.account-profile-form .btn { width: 100%; justify-content: center; margin-top: 16px; }
.account-readonly { opacity: 0.72; }
.account-track-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 16px;
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
}
.account-track-link:hover { color: var(--primary-dark); }
.track-wrap { max-width: 760px; margin: 0 auto; }
.track-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 28px; }
.track-card h2 { font-size: 19px; }
.track-card .track-sub { font-size: 12.5px; color: var(--muted); margin: 4px 0 20px; }
.track-form .form-grid { grid-template-columns: 1fr 1fr; }
.track-form .btn { margin-top: 18px; }
.track-result { margin-top: 22px; }
.track-order-head { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; flex-wrap: wrap; }
.track-order-head strong { display: block; font-size: 16px; }
.track-order-head span { display: block; font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.track-chips { display: flex; gap: 5px; flex-wrap: wrap; }
.track-total { display: flex; justify-content: space-between; align-items: baseline; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 13px; }
.track-total strong { font-size: 21px; }
.track-items { margin-top: 14px; }
.track-note { font-size: 11.5px; color: var(--muted); line-height: 1.5; margin-top: 13px; }
.track-note a { color: var(--primary); font-weight: 700; text-decoration: underline; }
.track-result:not(:empty) { border-top: 1px dashed var(--line); padding-top: 22px; }
.track-timeline { list-style: none; margin: 12px 0 0; padding: 0; }
.track-timeline li { position: relative; margin-left: 4px; padding: 0 0 15px 20px; border-left: 2px solid var(--line); }
.track-timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.track-timeline li::before {
  content: "";
  position: absolute;
  left: -6px;
  top: 3px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid #fff;
  box-shadow: 0 0 0 1px var(--primary-soft);
}
.track-timeline strong { display: block; font-size: 12px; color: var(--dark); }
.track-timeline span { display: block; font-size: 10.5px; color: var(--muted); margin-top: 1px; }
.track-timeline p { font-size: 11.5px; color: var(--muted); margin-top: 4px; line-height: 1.45; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 900px) {
  .checkout-layout { grid-template-columns: 1fr; gap: 24px; }
  .order-summary { position: static; }
  .cart-drawer { width: min(420px, 100vw); }
  .account-shell { grid-template-columns: 1fr; }
  .account-intro { position: static; }
  .account-grid { grid-template-columns: 1fr; }
  .account-panel + .account-panel { margin-top: 0; }
}
@media (max-width: 640px) {
  .form-grid { grid-template-columns: 1fr; }
  .form-grid .full { grid-column: auto; }
  .checkout-card { padding: 22px 18px; }
  .order-summary { padding: 20px 18px; }
  .order-meta { grid-template-columns: 1fr; gap: 16px; }
  .pm-actions { grid-template-columns: 1fr; }
  .demo-card { padding: 24px 20px; }
  .demo-actions { grid-template-columns: 1fr; }
  .cart-head { padding: 22px 20px 15px; }
  .cart-body { padding: 6px 20px; }
  .cart-foot { padding: 16px 20px 22px; }
  .order-panel { padding: 20px 18px; }
  .order-hero .order-icon { width: 58px; height: 58px; }
  .header-actions { gap: 8px; }
  .header-actions > .btn { display: none; }
  .cart-toggle, .account-toggle { width: 38px; height: 38px; }
  .currency-toggle { padding: 0 8px; height: 36px; }
  .currency-code { display: none; }
  .account-card, .track-card { padding: 22px 18px; }
  .account-welcome { padding: 20px 18px; }
  .account-welcome-actions { width: 100%; }
  .account-welcome-actions .btn { flex: 1; justify-content: center; }
  .track-form .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 380px) {
  .item-actions { grid-template-columns: 1fr; }
  .account-welcome-actions { flex-direction: column; }
  .account-welcome-actions .btn { width: 100%; }
}
