/* Kalaghoda Spirits — account pages (/account, /account/login, …).
   Loaded after global.css and checkout.css: the account pages reuse the checkout page layout
   (.co, .co__title, .co__back) and its form system (.co-form, .field, .co-btn) for their forms. */

.account { padding-bottom: calc(160 * var(--u)); }

.account__note {
  margin-top: calc(40 * var(--u));
  font-size: max(15px, calc(19 * var(--u)));
  line-height: 1.5;
  letter-spacing: 0.02em;
  color: #9a9a9a;             /* lighter than --muted for readable contrast on the dark background */
}
.account__note:empty { display: none; }
.account__note + .account__note { margin-top: calc(12 * var(--u)); }

/* sign-in / sign-up forms and the sign-out button: the width of the checkout form column */
.account__form, .account__actions { width: calc(540 * var(--u)); min-width: 360px; }
.account__actions { margin-top: calc(8 * var(--u)); }
.account__form-error { margin-top: calc(24 * var(--u)); }
.account__form-error + .co-btn { margin-top: calc(24 * var(--u)); }
.account__actions .account__form-error { margin-top: 16px; }

.account__switch {
  margin-top: calc(32 * var(--u));
  font-size: max(14px, calc(17 * var(--u)));
  line-height: 1.5;
  letter-spacing: 0.03em;
  color: #9a9a9a;
}
.account__switch a { color: #fff; text-decoration: underline; text-underline-offset: 4px; transition: color .3s ease; }
.account__switch a:hover, .account__switch a:focus-visible { color: var(--accent); }

/* "Continue with Google" below the sign-in / sign-up form: a hairline "or" divider, then a dark Google button (Google's
   dark-theme colours, the official four-colour "G") the width of the form. Hidden until the API says it is configured. */
.oauth[hidden] { display: none; }
.oauth__or {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-top: calc(36 * var(--u));
  font-size: max(11px, calc(13 * var(--u)));
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: #8a8a8a;
}
.oauth__or::before, .oauth__or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.oauth-btn {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
  height: calc(70 * var(--u));
  min-height: 54px;
  margin-top: calc(28 * var(--u));
  padding: 0 20px;
  background: #131314;
  box-shadow: inset 0 0 0 1px #8e918f;
  color: #e3e3e3;
  font-size: max(14px, calc(17 * var(--u)));
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: box-shadow .3s ease, background-color .3s ease, translate .45s var(--ease-out);
}
.oauth-btn:hover { background: #1b1b1c; box-shadow: inset 0 0 0 1px #e3e3e3; translate: 0 -2px; }
.oauth-btn:active { scale: .985; }
.oauth-btn:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.oauth-btn[hidden] { display: none; }
.oauth-btn__logo { flex: none; width: 20px; height: 20px; }
.oauth__note { margin-top: 14px; font-size: max(13px, calc(15 * var(--u))); line-height: 1.5; letter-spacing: 0.02em; color: #9a9a9a; }
.settings__google .account__buttons { margin-top: calc(24 * var(--u)); }
.settings__google .oauth-btn { margin-top: 0; }
@media (max-width: 900px) {
  .oauth__or { margin-top: 28px; }
  .oauth-btn { margin-top: 20px; }
}
@media (prefers-reduced-motion: reduce) { .oauth-btn { transition: none; } .oauth-btn:hover { translate: none; } }

/* profile: viewing state shows the saved values as plain read-only lines; Edit turns them into the usual fields */
.account__form.is-viewing .field__control,
.account__form.is-viewing .field__control:focus-within { background: transparent; box-shadow: inset 0 -1px 0 var(--line); }
.account__form.is-viewing .field input { cursor: default; padding-left: 0; }
.account__form.is-viewing .field__control--phone .cc { width: auto; min-width: 0; border-right: 0; }
.account__form.is-viewing .field__control--phone .cc select { width: auto; padding: calc(3 * var(--u)) calc(10 * var(--u)) 0 0; color: #fff; opacity: 1; cursor: default; }
.account__form.is-viewing .field__caret { display: none; }
.account__form.is-viewing .field:focus-within label { color: var(--muted); }

.account__form-success {
  margin-top: calc(24 * var(--u));
  font-size: max(13px, calc(16 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.03em;
  color: #fff;
}
.account__form-success:empty { display: none; }

.account__buttons { margin-top: calc(40 * var(--u)); display: flex; flex-direction: column; gap: calc(16 * var(--u)); }
.account__buttons .co-btn { margin-top: 0; }
.account__buttons [hidden] { display: none; }
/* secondary action — the outline button used for "Continue shopping" in the cart */
.co-btn.account__btn-secondary {
  background: transparent;
  color: #fff;
  box-shadow: inset 0 0 0 max(1px, calc(1.5 * var(--u))) #fff;
  transition: background-color .45s ease, box-shadow .45s ease, translate .45s var(--ease-out);
}
.co-btn.account__btn-secondary:hover { background: rgba(255, 255, 255, .07); box-shadow: inset 0 0 0 max(1px, calc(1.5 * var(--u))) var(--accent); }

/* saved addresses: cards in the account column(s), the default one outlined and badged */
.addresses__status, .addresses__error { margin-top: calc(32 * var(--u)); }
.addresses__error:empty { display: none; }
.addresses {
  margin-top: calc(40 * var(--u));
  display: grid;
  grid-template-columns: repeat(2, calc(540 * var(--u)));
  gap: calc(30 * var(--u)) calc(40 * var(--u));
  list-style: none;
  outline: none;
}
.addresses:empty, .addresses[hidden] { display: none; }
.addresses.is-busy .address-card { opacity: .7; transition: opacity .3s ease; }
.address-card {
  display: flex;
  flex-direction: column;
  padding: calc(28 * var(--u)) calc(30 * var(--u));
  background: var(--tile);
  box-shadow: inset 0 0 0 1px transparent;
  transition: box-shadow .35s ease;
}
.address-card.is-default { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35); }
.address-card__head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.address-card__label,
.address-card__badge {
  font-size: max(12px, calc(15.2 * var(--u)));
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.035em;
  text-transform: uppercase;
  color: var(--muted);
}
.address-card__badge { margin: -6px 0 -4px; padding: 6px 10px 4px; color: var(--gold-line); box-shadow: inset 0 0 0 1px currentColor; }   /* no extra row height */
.address-card__lines {
  margin-top: calc(20 * var(--u));
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: max(15px, calc(19 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.02em;
  color: #9a9a9a;
  overflow-wrap: anywhere;
}
.address-card__name { color: #fff; text-transform: uppercase; }
.address-card__actions { margin-top: auto; padding-top: calc(24 * var(--u)); display: flex; flex-wrap: wrap; gap: 10px calc(28 * var(--u)); }
.address-card__actions[hidden] { display: none; }
.address-card__confirm { margin-top: auto; padding-top: calc(24 * var(--u)); }
.address-card__confirm[hidden] { display: none; }
.address-card__confirm .address-card__actions { margin-top: 0; padding-top: 14px; }
.address-card__confirm-text { font-size: max(14px, calc(17 * var(--u))); letter-spacing: 0.03em; color: #fff; }
.addresses__action {
  position: relative;
  padding: 6px 0 4px;
  border: 0;
  background: none;
  color: #fff;
  font: inherit;
  font-size: max(12px, calc(14.5 * var(--u)));
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color .3s ease;
}
.addresses__action::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .45s var(--ease-out);
}
.addresses__action:hover::after, .addresses__action:focus-visible::after { transform: scaleX(1); }
.addresses__action:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.addresses__action.is-danger { color: var(--accent); }
.addresses__action:disabled { cursor: default; opacity: .5; }
.addresses__action.is-busy { opacity: 1; animation: kg-pulse 1s ease-in-out infinite alternate; }
@keyframes kg-pulse { to { opacity: .35; } }
.addresses__add { margin-top: calc(8 * var(--u)); }
.addresses__add .co-btn[hidden] { display: none; }
.addresses__editor { margin-top: calc(48 * var(--u)); }
.addresses__editor[hidden] { display: none; }
.addresses__form-title {
  font-size: max(16px, calc(22 * var(--u)));
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.045em;
  text-transform: uppercase;
}
.addresses__editor .co-form { margin-top: calc(28 * var(--u)); }
.addresses__editor .check { margin-top: calc(28 * var(--u)); }

/* order history: the address card layout, with the order number, a status badge and the total */
.order-card__number {
  font-size: max(14px, calc(17.5 * var(--u)));
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #fff;
}
.order-card__ref { white-space: nowrap; }
.order-card__status.is-cancelled { color: var(--muted); }
.order-card__items { color: #fff; }
.order-card__total {
  margin-top: calc(20 * var(--u));
  padding-top: calc(16 * var(--u));
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  font-size: max(15px, calc(19 * var(--u)));
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #9a9a9a;
}
.order-card__total strong { font-weight: 500; color: #fff; }
.orders__loading[hidden], .orders__empty[hidden], .orders__pager[hidden] { display: none; }
.orders__pager {
  margin-top: calc(40 * var(--u));
  display: flex;
  align-items: center;
  gap: calc(32 * var(--u));
}
.orders__page { font-size: max(13px, calc(16 * var(--u))); letter-spacing: 0.04em; color: #9a9a9a; }

/* order details: header (number + status), then the cards — items with amounts, delivery, address, payment */
.order-detail { margin-top: calc(40 * var(--u)); }
.order-detail[hidden], .order-detail__back[hidden] { display: none; }
.order-detail__head { display: flex; align-items: center; flex-wrap: wrap; gap: 12px calc(20 * var(--u)); }
.order-detail__placed { margin-top: calc(12 * var(--u)); }
.order-detail__grid { margin-top: calc(32 * var(--u)); align-items: start; }
.order-detail__items { grid-row: span 3; }
.order-lines { margin-top: calc(20 * var(--u)); list-style: none; }
.order-line {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: calc(14 * var(--u)) 0;
  border-bottom: 1px solid var(--line);
  font-size: max(15px, calc(19 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.02em;
}
.order-line:first-child { padding-top: 0; }
.order-line__info { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.order-line__name { color: #fff; text-transform: uppercase; overflow-wrap: anywhere; }
.order-line__qty { color: #9a9a9a; }
.order-line__total { color: #fff; white-space: nowrap; }
.order-sums {
  margin-top: calc(16 * var(--u));
  display: grid;
  grid-template-columns: 1fr auto;
  row-gap: calc(10 * var(--u));          /* no column gap, so the line above the total runs unbroken */
  font-size: max(15px, calc(19 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.02em;
  color: #9a9a9a;
}
.order-sums dd { padding-left: 16px; text-align: right; color: #fff; white-space: nowrap; }
.order-sums .order-sums__total {
  margin-top: calc(6 * var(--u));
  padding-top: calc(14 * var(--u));
  border-top: 1px solid var(--line);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #fff;
  font-weight: 500;
}
.order-detail__section .address-card__lines { margin-top: calc(16 * var(--u)); }

/* order status: summary sentence, then a vertical timeline. Every step says its state in words (date /
   "Current status" / "Not yet" / "Cancelled") and has its own marker shape, so colour is never the only cue. */
.order-status__summary {
  margin-top: calc(16 * var(--u));
  font-size: max(15px, calc(19 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.02em;
  color: #fff;
}
.order-timeline { margin-top: calc(22 * var(--u)); list-style: none; }
.order-step {
  position: relative;
  display: grid;
  grid-template-columns: 22px 1fr;
  column-gap: 16px;
  padding-bottom: calc(20 * var(--u));
  min-height: 42px;
}
.order-step:last-child { padding-bottom: 0; min-height: 0; }
.order-step::before {                                   /* line to the next step */
  content: "";
  position: absolute;
  left: 10.5px;
  top: 26px;
  bottom: 4px;
  width: 1px;
  background: var(--line);
}
.order-step:last-child::before { display: none; }
.order-step.is-complete::before { background: rgba(255, 255, 255, .5); }
.order-step__marker {
  width: 22px;
  height: 22px;
  margin-top: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1.5px solid #555;
}
.order-step__marker svg { width: 11px; height: auto; display: block; }
.order-step.is-complete .order-step__marker { border-color: #fff; background: #fff; color: var(--bg); }
.order-step.is-current .order-step__marker { border-color: var(--gold-line); }
.order-step.is-current .order-step__marker::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--gold-line); }
.order-step.is-complete.is-current .order-step__marker::after { display: none; }
.order-step.is-upcoming .order-step__marker { border-style: dashed; }
.order-step.is-cancelled .order-step__marker { border-color: var(--accent); color: var(--accent); }
.order-step__text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.order-step__label {
  font-size: max(14px, calc(17 * var(--u)));
  line-height: 1.35;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: #fff;
  overflow-wrap: anywhere;
}
.order-step__meta { font-size: max(13px, calc(16 * var(--u))); line-height: 1.35; letter-spacing: 0.02em; color: #9a9a9a; }
.order-step.is-upcoming .order-step__label { color: #9a9a9a; }
.order-step.is-current .order-step__meta { color: var(--gold-line); }
.order-step.is-cancelled .order-step__label, .order-step.is-cancelled .order-step__meta { color: #d86a92; }
.order-status__tracking {
  margin-top: calc(20 * var(--u));
  padding-top: calc(16 * var(--u));
  border-top: 1px solid var(--line);
  font-size: max(14px, calc(17 * var(--u)));
  line-height: 1.4;
  letter-spacing: 0.03em;
  color: #fff;
}
.order-status__tracking:empty { display: none; }
.order-status__track { color: #fff; text-decoration: underline; text-underline-offset: 3px; overflow-wrap: anywhere; }
.order-status__track:hover { color: var(--gold-line); }
.order-status__track:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.order-detail__back { margin-top: calc(40 * var(--u)); }
/* reorder feedback sits above the buttons */
.order-reorder__status, .order-reorder__error { margin: 0 0 calc(16 * var(--u)); line-height: 1.45; }
.order-reorder__error:empty { display: none; }
.order-detail__back .account__buttons { margin-top: calc(8 * var(--u)); }

/* saved payment methods: the address card layout — brand, •••• last 4, expiry, Default */
.pm-card__brand { color: #fff; }
.pm-card__number { color: #fff; font-size: max(17px, calc(22 * var(--u))); letter-spacing: 0.12em; }
.pm-card__expiry.is-expired { color: #d86a92; }
.pm-test-note { margin-top: 0; font-size: max(14px, calc(17 * var(--u))); }
.pm-test-note[hidden] { display: none; }
.pm-choices { margin-top: calc(24 * var(--u)); border: 0; padding: 0; min-width: 0; }
.pm-choices__list { margin-top: calc(14 * var(--u)); display: flex; flex-direction: column; gap: 10px; }
.pm-choice {
  position: relative;
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 50px;
  padding: 12px 16px;
  background: var(--field);
  box-shadow: inset 0 0 0 1px transparent;
  cursor: pointer;
  transition: box-shadow .3s ease, background-color .3s ease;
}
.pm-choice:hover { background: #1f1f1f; }
.pm-choice input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pm-choice__mark { flex: none; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid #6f6f6f; display: flex; align-items: center; justify-content: center; }
.pm-choice input:checked + .pm-choice__mark { border-color: #fff; }
.pm-choice input:checked + .pm-choice__mark::after { content: ""; width: 8px; height: 8px; border-radius: 50%; background: #fff; }
.pm-choice:has(input:checked) { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .35); }
.pm-choice input:focus-visible + .pm-choice__mark { outline: 2px solid #fff; outline-offset: 3px; }
.pm-choice__text { font-size: max(15px, calc(19 * var(--u))); letter-spacing: 0.02em; color: #fff; overflow-wrap: anywhere; }
.addresses__editor .pm-choices + .check { margin-top: calc(24 * var(--u)); }

/* signed-in pages stay hidden until the session is confirmed, so signed-out visitors never see them */
body[data-auth="required"]:not(.is-authed) .account { visibility: hidden; }

@media (max-width: 900px) {
  .account { padding-bottom: 96px; }
  .account__note { margin-top: 28px; }
  .account__form, .account__actions { width: 100%; min-width: 0; }
  .account__form-error { margin-top: 20px; }
  .account__form-error + .co-btn { margin-top: 20px; }
  .account__switch { margin-top: 28px; text-align: center; }
  .account__buttons { margin-top: 32px; gap: 12px; }
  .addresses { grid-template-columns: 1fr; gap: 16px; margin-top: 28px; }
  .address-card { padding: 22px 20px; }
  .address-card__lines { margin-top: 16px; }
  .address-card__actions { padding-top: 20px; gap: 10px 24px; }
  .addresses__editor { margin-top: 36px; }
  .addresses__status, .addresses__error { margin-top: 24px; }
  .order-card__total { margin-top: 16px; padding-top: 14px; }
  .orders__pager { margin-top: 28px; justify-content: space-between; gap: 16px; }
  .order-detail { margin-top: 28px; }
  .order-detail__grid { margin-top: 24px; }
  .order-detail__items { grid-row: auto; }
  .order-line { padding: 12px 0; }
  .order-detail__back { margin-top: 32px; }
  .account__form-success { margin-top: 20px; }
}

html.motion .account__note { animation: kg-rise .8s var(--ease-out) .25s backwards; --rise: 10px; }
html.motion .account__actions,
html.motion .account__switch { animation: kg-rise .8s var(--ease-out) .4s backwards; --rise: 10px; }
html.motion .address-card { animation: kg-rise .7s var(--ease-out) .2s backwards; --rise: 10px; }
@media (prefers-reduced-motion: reduce) { .addresses__action.is-busy { animation: none; opacity: .5; } }

/* promo codes: the address card layout — code, "10% off" badge, conditions */
.cp-card__code { letter-spacing: 0.1em; overflow-wrap: anywhere; }
.cp-card__description { color: #fff; }
#cp-empty[hidden], #cp-howto[hidden] { display: none; }

/* account settings: Account / Login & security / Privacy sections in the account column */
.settings[hidden], .settings__deleted[hidden], .settings__delete[hidden], #del-open-wrap[hidden] { display: none; }
.settings__section { margin-top: calc(48 * var(--u)); max-width: calc(760 * var(--u)); }
.settings__section:first-child { margin-top: calc(40 * var(--u)); }
.settings__section + .settings__section { padding-top: calc(40 * var(--u)); border-top: 1px solid var(--line); }
.settings__section > .account__note:first-of-type { margin-top: calc(18 * var(--u)); }
.settings__subtitle { display: block; margin-top: calc(32 * var(--u)); color: #fff; }
.settings__form { margin-top: calc(18 * var(--u)); }
.settings__switch { margin-top: calc(14 * var(--u)); }
.settings__hint { margin-top: calc(18 * var(--u)); font-size: max(13px, calc(16 * var(--u))); line-height: 1.45; letter-spacing: 0.02em; color: #9a9a9a; }
.settings__status { margin-top: calc(14 * var(--u)); }
.settings__status:empty { display: none; }
.settings__actions { width: calc(540 * var(--u)); min-width: 360px; margin-top: calc(22 * var(--u)); }
.settings__facts { margin-top: calc(18 * var(--u)); padding-left: 1.1em; display: flex; flex-direction: column; gap: 10px; }
.settings__facts li { font-size: max(15px, calc(18 * var(--u))); line-height: 1.5; letter-spacing: 0.02em; color: #9a9a9a; }
/* destructive actions: the brand pink, outline until confirmed */
.co-btn.settings__danger-outline { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 max(1px, calc(1.5 * var(--u))) var(--accent); }
.co-btn.settings__danger-outline:hover { background: rgba(233, 30, 99, .08); }
.co-btn.settings__danger { background: var(--accent); color: #fff; }
.co-btn.settings__danger:hover { background: #d81b5b; }
.co-btn.settings__danger.is-busy::after { background: #fff; }
.settings__deleted { margin-top: calc(40 * var(--u)); }
/* "Sign out of all other sessions" is the longest button label on the site: at the desktop button tracking (0.54em) it
   runs past both sides of the button, so this one button gets just enough less tracking to sit inside it.
   ≤1100px it already fits at the tablet tracking; ≤480px it gets a little less again, and on the narrowest phones it
   may break onto two centred lines rather than overflow. */
@media (min-width: 1101px) {
  #st-signout-others { letter-spacing: 0.3em; text-indent: 0.3em; }
}
@media (max-width: 480px) {
  #st-signout-others { letter-spacing: 0.24em; text-indent: 0.24em; white-space: normal; line-height: 1.5; text-align: center; text-wrap: balance; }
}
@media (max-width: 900px) {
  .settings__section { margin-top: 36px; max-width: none; }
  .settings__section + .settings__section { padding-top: 32px; }
  .settings__actions { width: 100%; min-width: 0; }
}

/* ═════════════════════════ ACCOUNT DASHBOARD (/account) ═════════════════════════
   The greeting; the latest order as a panel (its bottles over the flavour's botanical etching, and the delivery
   rail filling Jamun pink → Mango gold — the two flavours); then each section as a hairline-ruled row of links
   showing the customer's own details. js/dashboard.js fills it. */
.dash {
  --jamun: #e91e63;
  --mango: #f6c24d;
  --flavours: linear-gradient(90deg, var(--jamun), var(--mango));
  --line: #2a2a2a;
  --soft: #9a9a9a;
}
.dash__label { font-size: max(12px, calc(13.5 * var(--u))); font-weight: 500; line-height: 1; letter-spacing: 0.24em; text-transform: uppercase; color: var(--soft); }

/* greeting */
.dash__head { display: grid; grid-template-columns: 1fr auto; column-gap: 32px; align-items: end; }
.dash__eyebrow { grid-column: 1 / -1; font-size: max(12px, calc(14 * var(--u))); letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold-line); }
.dash__greeting {
  grid-column: 1 / -1;
  margin-top: calc(22 * var(--u));
  font-size: clamp(38px, calc(88 * var(--u)), 104px);
  font-weight: 600;
  line-height: 0.95;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  overflow-wrap: break-word;
}
.dash__stop { color: var(--jamun); }
.dash__meta { grid-column: 1; margin-top: calc(20 * var(--u)); min-height: 1.5em; font-size: max(15px, calc(18 * var(--u))); line-height: 1.5; letter-spacing: 0.02em; color: var(--soft); overflow-wrap: anywhere; }
.dash__signout {
  grid-column: 2;
  grid-row: 3;
  align-self: end;
  padding: 14px 28px 12px;
  border: 1px solid rgba(255, 255, 255, .35);
  background: none;
  color: #fff;
  font: inherit;
  font-size: max(12px, calc(14 * var(--u)));
  letter-spacing: 0.22em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color .3s ease, background-color .3s ease, color .3s ease;
}
.dash__signout:hover { border-color: #fff; background: #fff; color: #121212; }
.dash__signout:focus-visible { outline: 2px solid var(--mango); outline-offset: 4px; }
.dash__signout.is-busy { opacity: .6; cursor: progress; }
.dash__error { grid-column: 1 / -1; }
.dash__error:empty { display: none; }

/* latest order / no orders yet */
.dash-panel {
  position: relative;
  isolation: isolate;
  margin-top: calc(64 * var(--u));
  display: grid;
  grid-template-columns: minmax(200px, 32%) 1fr;
  background: var(--band);
  overflow: hidden;
}
.dash-panel[hidden] { display: none; }
.dash-panel__art { position: relative; display: flex; align-items: flex-end; justify-content: center; min-height: calc(420 * var(--u)); padding-top: calc(48 * var(--u)); }
.dash-panel__botanical { position: absolute; z-index: -1; top: -8%; left: -12%; width: 115%; height: auto; opacity: .13; pointer-events: none; }
.dash-panel__bottles { display: flex; align-items: flex-end; }
.dash-panel__bottles img { display: block; width: auto; height: clamp(210px, calc(380 * var(--u)), 420px); filter: drop-shadow(0 24px 30px rgba(0, 0, 0, .55)); }
.dash-panel__bottles img + img { margin-left: -14%; height: clamp(190px, calc(344 * var(--u)), 380px); }
.dash-panel__body { display: flex; flex-direction: column; justify-content: center; padding: calc(56 * var(--u)) calc(72 * var(--u)) calc(56 * var(--u)) calc(24 * var(--u)); min-width: 0; }
.dash-order__number { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 16px; margin-top: calc(22 * var(--u)); font-size: max(22px, calc(34 * var(--u))); font-weight: 600; line-height: 1.1; letter-spacing: 0.05em; font-variant-numeric: tabular-nums; }
.dash-order__date { font-size: max(14px, calc(17 * var(--u))); font-weight: 400; letter-spacing: 0.04em; color: var(--soft); white-space: nowrap; }
.dash-order__items { margin-top: 10px; font-size: max(15px, calc(18 * var(--u))); line-height: 1.5; letter-spacing: 0.02em; color: #d9d9d9; font-variant-numeric: tabular-nums; }
.dash-empty__title { margin-top: calc(22 * var(--u)); font-size: max(24px, calc(40 * var(--u))); font-weight: 600; line-height: 1.05; letter-spacing: 0.02em; text-transform: uppercase; }
.dash-order__status { margin-top: calc(18 * var(--u)); font-size: max(15px, calc(17 * var(--u))); line-height: 1.5; letter-spacing: 0.02em; color: #fff; }
.dash-panel__links { display: flex; flex-wrap: wrap; gap: 12px 32px; margin-top: calc(30 * var(--u)); }
.dash__link {
  position: relative;
  padding-bottom: 6px;
  font-size: max(13px, calc(15 * var(--u)));
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #fff;
}
.dash__link::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--flavours); transform-origin: left center; transition: transform .45s var(--ease-out); }
.dash__link:hover::after { transform: scaleY(2); }
.dash__link:focus-visible { outline: 2px solid var(--mango); outline-offset: 4px; }
.dash__link[hidden] { display: none; }

/* the delivery rail: Confirmed → Processing → Shipped → Delivered; --fill (0–1) is how far the order has got */
.rail { --fill: 0; position: relative; display: grid; grid-template-columns: repeat(4, 1fr); margin-top: calc(40 * var(--u)); padding-top: 26px; list-style: none; }
.rail::before, .rail::after { content: ""; position: absolute; top: 5px; left: 6px; width: 75%; height: 2px; }
.rail::before { background: var(--line); }
.rail::after { background: var(--flavours); transform: scaleX(0); transform-origin: left center; transition: transform 1.4s var(--ease-editorial) .3s; }
.rail.is-drawn::after { transform: scaleX(var(--fill)); }
.rail__step { position: relative; padding-right: 8px; font-size: max(11px, calc(13 * var(--u))); letter-spacing: 0.16em; text-transform: uppercase; color: #5f5f5f; }
.rail__step::before { content: ""; position: absolute; top: -26px; left: 0; width: 12px; height: 12px; border-radius: 50%; background: var(--band); box-shadow: inset 0 0 0 2px var(--line); transition: background-color .4s ease .9s, box-shadow .4s ease .9s; }
.rail__step.is-done { color: #fff; }
.rail__step.is-done::before { background: #fff; box-shadow: none; }
.rail__step[aria-current="step"] { font-weight: 600; }
.rail__step[aria-current="step"]::before { background: var(--mango); box-shadow: 0 0 0 5px rgba(246, 194, 77, .18); }
.rail.is-cancelled::after { display: none; }
.rail.is-cancelled .rail__step { color: #4a4a4a; text-decoration: line-through; text-decoration-color: rgba(255, 255, 255, .25); }

/* each section, with the customer's own details on it */
.dash-ledger { display: grid; grid-template-columns: repeat(auto-fit, minmax(0, 1fr)); margin-top: calc(56 * var(--u)); border-top: 1px solid var(--line); }
.dash-ledger__item { position: relative; display: flex; flex-direction: column; gap: 14px; min-width: 0; padding: calc(30 * var(--u)) calc(28 * var(--u)) calc(34 * var(--u)); border-left: 1px solid var(--line); }
.dash-ledger__item:first-child { padding-left: 0; border-left: 0; }
.dash-ledger__item[hidden] { display: none; }
.dash-ledger__item::before { content: ""; position: absolute; top: -1px; left: 0; right: 0; height: 2px; background: var(--flavours); transform: scaleX(0); transform-origin: left center; transition: transform .5s var(--ease-out); }
.dash-ledger__item:hover::before, .dash-ledger__item:focus-visible::before { transform: scaleX(1); }
.dash-ledger__item:focus-visible { outline: 2px solid var(--mango); outline-offset: 4px; }
.dash-ledger__value { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; font-size: max(16px, calc(20 * var(--u))); line-height: 1.35; letter-spacing: 0.02em; color: #fff; overflow-wrap: anywhere; }
.dash-ledger__value::after { content: "→"; flex: none; color: var(--soft); transition: translate .45s var(--ease-out), color .3s ease; }
.dash-ledger__item:hover .dash-ledger__value::after, .dash-ledger__item:focus-visible .dash-ledger__value::after { translate: 6px 0; color: var(--mango); }

html.motion .dash__head > * { animation: kg-rise .8s var(--ease-out) backwards; --rise: 14px; }
html.motion .dash__greeting { animation-delay: .08s; }
html.motion .dash__meta, html.motion .dash__signout { animation-delay: .16s; }
html.motion .dash-panel:not([hidden]) { animation: kg-rise .9s var(--ease-out) .1s backwards; --rise: 18px; }
html.motion .dash-ledger { animation: kg-rise .8s var(--ease-out) .3s backwards; --rise: 10px; }

@media (max-width: 1100px) {
  .dash-panel { grid-template-columns: 1fr; }
  .dash-panel__art { min-height: 0; padding-top: 36px; }
  .dash-panel__body { padding: 32px 40px 40px; }
  .dash-ledger { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  /* counted among the visible sections only (the Coupons link is hidden while promo codes are off) */
  .dash-ledger__item:nth-child(odd of :not([hidden])) { padding-left: 0; border-left: 0; }
  .dash-ledger__item:nth-child(n + 3 of :not([hidden])) { border-top: 1px solid var(--line); }
}
@media (max-width: 900px) {
  .dash__head { grid-template-columns: 1fr; }
  .dash__greeting { margin-top: 14px; font-size: clamp(34px, 10.5vw, 64px); }
  .dash__meta { margin-top: 14px; }
  .dash__signout { grid-column: 1; grid-row: auto; justify-self: start; margin-top: 22px; }
  .dash-panel { grid-template-columns: 1fr; margin-top: 36px; }
  .dash-panel__art { min-height: 0; padding-top: 28px; }
  .dash-panel__body { padding: 26px 22px 30px; }
  .dash-order__number, .dash-empty__title, .dash-order__status, .rail, .dash-panel__links { margin-top: 18px; }
  .dash-panel__bottles img { height: clamp(190px, 58vw, 300px); }
  .dash-panel__bottles img + img { height: clamp(170px, 52vw, 270px); }
  .dash__link { letter-spacing: 0.12em; line-height: 1.5; }
  .dash-ledger { grid-template-columns: 1fr; margin-top: 36px; }
  .dash-ledger__item, .dash-ledger__item:nth-child(odd of :not([hidden])) { padding: 22px 0 24px; border-left: 0; }
  .dash-ledger__item + .dash-ledger__item { border-top: 1px solid var(--line); }
}
/* narrow phones: the rail stands upright, so each step keeps its full name */
@media (max-width: 560px) {
  .rail { grid-template-columns: 1fr; row-gap: 18px; padding-top: 0; padding-left: 28px; }
  .rail::before, .rail::after { top: 6px; left: 5px; width: 2px; height: calc(100% - 22px); }
  .rail::after { background: linear-gradient(180deg, var(--jamun), var(--mango)); transform: scaleY(0); transform-origin: center top; }
  .rail.is-drawn::after { transform: scaleY(var(--fill)); }
  .rail__step::before { top: 1px; left: -28px; }
}
@media (prefers-reduced-motion: reduce) {
  .rail::after, .rail__step::before { transition: none; }
  .dash-ledger__value::after { transition: none; }
}

/* account sections: a slim row of links under each section's title (the current one underlined) */
.account-nav {
  margin-top: calc(28 * var(--u));
  display: flex;
  flex-wrap: wrap;
  gap: 12px calc(30 * var(--u));
}
.account-nav a {
  position: relative;
  padding: 6px 0 4px;
  font-size: max(12px, calc(14.5 * var(--u)));
  line-height: 1;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9a9a9a;
  transition: color .3s ease;
}
.account-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 1px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left center;
  transition: transform .45s var(--ease-out);
}
.account-nav a:hover, .account-nav a:focus-visible, .account-nav a[aria-current="page"] { color: #fff; }
.account-nav a:hover::after, .account-nav a:focus-visible::after, .account-nav a[aria-current="page"]::after { transform: scaleX(1); }
.account-nav a:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
html.motion .account-nav { animation: kg-rise .8s var(--ease-out) .2s backwards; --rise: 10px; }

@media (max-width: 900px) {
  .account-nav { margin-top: 20px; gap: 10px 22px; }
}
