/* Sign-in pop-up + account pages (black + chrome). Page shell (black grid, chrome title, LED kicker) comes from
   ml-buy.css via [data-gk-cart-page]; tokens (--ml-*) from ml-up.css. */

/* ---------- sign-in pop-up: dark glass over the blurred page ---------- */
.gk-login-modal.ml-login-modal.modal {
  background: rgba(0, 0, 0, .62) !important;
  background-image: radial-gradient(ellipse 60% 50% at 50% 0%, rgba(255, 255, 255, .08), transparent 70%) !important;
  -webkit-backdrop-filter: blur(14px) saturate(.8);
  backdrop-filter: blur(14px) saturate(.8);
}
.ml-login-modal .modal-dialog { max-width: 430px; width: min(430px, calc(100% - 1.5rem)); }
.gk-login.ml-login {
  position: relative;
  display: grid;
  gap: 18px;
  padding: 26px 26px 20px !important;
  border: 0 !important;
  border-radius: 26px !important;
  background: linear-gradient(180deg, rgba(22, 22, 27, .98), rgba(7, 7, 9, .99)) !important;
  box-shadow: 0 40px 90px rgba(0, 0, 0, .75), inset 0 1px 0 rgba(255, 255, 255, .06) !important;
  color: #f2f2f5 !important;
  text-align: center;
  animation: mlb-up .5s var(--ml-ease) both;
}
.ml-login > :not(.ml-rim) { position: relative; z-index: 1; }
.ml-login .ml-rim { z-index: 0; }
.ml-login__close {
  position: absolute !important; top: 14px; right: 14px; z-index: 2 !important;
  display: grid; place-items: center; width: 34px; height: 34px; padding: 0;
  border: 0; border-radius: 50%; background: #0c0c10; color: #a8a8b5; cursor: pointer;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
  transition: color .2s, box-shadow .2s;
}
.ml-login__close:hover { color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .5); }
.ml-login__brand { display: flex; justify-content: center; padding-top: 4px; }
.ml-login__brand img { width: 150px; height: auto; filter: drop-shadow(0 0 18px rgba(255, 255, 255, .12)); }

.ml-login__steps { display: inline-flex; justify-self: center; align-items: center; margin: 0; padding: 5px; list-style: none; border-radius: 999px; background: rgba(10, 10, 13, .8); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); }
.ml-login__steps li { display: flex; align-items: center; color: #6f6f7d; font: 600 10.5px/1 var(--ml-mono); letter-spacing: .14em; text-transform: uppercase; }
.ml-login__steps li + li::before { content: ""; width: 26px; height: 1px; margin: 0 8px; background: linear-gradient(90deg, rgba(255, 255, 255, .08), rgba(255, 255, 255, .3), rgba(255, 255, 255, .08)); }
.ml-login__steps i { display: grid; place-items: center; width: 20px; height: 20px; margin-right: 7px; border-radius: 50%; font-style: normal; font-size: 10px; letter-spacing: 0; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.ml-login__steps .is-on { color: #fff; }
.ml-login__steps .is-on i { color: #0b0b0e; background: var(--ml-tex); box-shadow: 0 0 0 1px #000, 0 0 14px rgba(255, 255, 255, .35); }
.ml-login__steps .is-done { color: #b8f5d2; }
.ml-login__steps .is-done i { color: #0b0b0e; background: #3ddc84; box-shadow: 0 0 12px rgba(61, 220, 132, .5); }

.ml-login__head { display: grid; gap: 10px; }
.ml-login__title {
  margin: 0; font: 700 clamp(30px, 7vw, 38px)/1 var(--ml-display); letter-spacing: .04em; text-transform: uppercase;
  background: var(--ml-chrome-text); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 0 18px rgba(255, 255, 255, .12));
}
.ml-login__sub { margin: 0 auto; max-width: 40ch; color: #a8a8b5; font: 500 13px/1.55 var(--ml-mono); text-wrap: balance; }
.ml-login__sub strong { display: block; margin-top: 4px; color: #fff; font-weight: 600; overflow-wrap: anywhere; }

.ml-login__form { display: grid; gap: 12px; text-align: left; }
.ml-login__label { color: #8a8a96; font: 600 10.5px/1 var(--ml-mono); letter-spacing: .2em; text-transform: uppercase; }
.ml-login__field { display: flex; align-items: center; gap: 10px; padding: 0 16px; height: 54px; border-radius: 14px; background: #060608; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14); color: #77778a; transition: box-shadow .2s; }
.ml-login__field:focus-within { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .55), 0 0 0 4px rgba(255, 255, 255, .06); color: #fff; }
.ml-login__field input { flex: 1; min-width: 0; height: 100%; padding: 0; border: 0; outline: 0; background: transparent; color: #fff; font: 500 16px/1 var(--gk-font-body, sans-serif); }
.ml-login__field input::placeholder { color: #55555f; }
.ml-login__hint { margin: -2px 0 0; color: #6f6f7d; font: 500 11.5px/1.45 var(--ml-mono); }
.ml-login__error { margin: 0; padding: 10px 12px; border-radius: 12px; background: rgba(255, 92, 103, .08); box-shadow: inset 0 0 0 1px rgba(255, 92, 103, .35); color: #ffb3b9; font: 500 12.5px/1.4 var(--ml-mono); }
.ml-login__ok { margin: 0; color: #b8f5d2; font: 500 12px/1.4 var(--ml-mono); }

/* code: one input stretched invisibly over 6 drawn boxes */
.ml-login__otp { position: relative; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.ml-login__otp-input {
  position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%;
  border: 0; outline: 0; background: transparent; color: transparent; caret-color: transparent;
  font-size: 16px; letter-spacing: 2em; cursor: text; opacity: .01;
}
.ml-login__cell {
  display: grid; place-items: center; height: 60px; border-radius: 14px;
  background: #060608; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14);
  color: #fff; font: 700 26px/1 var(--ml-display);
  transition: box-shadow .2s, transform .2s var(--ml-ease);
}
.ml-login__cell.is-filled { box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .4); }
.ml-login__otp:focus-within .ml-login__cell.is-cur { box-shadow: inset 0 0 0 1.5px #fff, 0 0 0 4px rgba(255, 255, 255, .07); }
.ml-login__otp:focus-within .ml-login__cell.is-cur::after { content: ""; width: 2px; height: 26px; background: #fff; animation: ml-caret 1s steps(1) infinite; }
.ml-login__otp.is-bad .ml-login__cell { box-shadow: inset 0 0 0 1px rgba(255, 92, 103, .6); animation: ml-shake .35s; }
@keyframes ml-caret { 50% { opacity: 0; } }
@keyframes ml-shake { 25% { transform: translateX(-4px); } 75% { transform: translateX(4px); } }

.ml-login__go { display: flex; margin-top: 4px; }
.ml-login__go .ml-mb { flex: 1; padding: 17px 20px; }
.ml-login__go .ml-mb:disabled { cursor: progress; opacity: .8; }
.ml-login__links { display: flex; justify-content: space-between; gap: 10px; }
.ml-login__links button { padding: 6px 0; border: 0; background: none; color: #a8a8b5; font: 600 12px/1 var(--ml-mono); letter-spacing: .04em; cursor: pointer; }
.ml-login__links button:hover:not(:disabled) { color: #fff; }
.ml-login__links button:disabled { color: #55555f; cursor: default; }
.ml-login__links b { color: #c9c9d2; }

.ml-login__done { display: grid; place-items: center; padding: 6px 0 14px; }
.ml-login__check { display: grid; place-items: center; width: 74px; height: 74px; border-radius: 50%; color: #0b0b0e; background: var(--ml-tex); box-shadow: 0 0 0 4px #000, 0 0 0 5px rgba(255, 255, 255, .3), 0 0 40px rgba(255, 255, 255, .25); animation: mlb-up .45s var(--ml-ease) both; }

.ml-login__foot { display: flex; align-items: center; justify-content: center; gap: 7px; margin: 2px 0 0; padding-top: 14px; border-top: 1px solid rgba(255, 255, 255, .08); color: #6f6f7d; font: 500 11px/1.4 var(--ml-mono); }

/* delete-account dialog buttons */
.ml-login__row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ml-login__ghost, .ml-login__danger { height: 48px; border: 0; border-radius: 999px; cursor: pointer; font: 700 12px/1 var(--ml-display); letter-spacing: .12em; text-transform: uppercase; }
.ml-login__ghost { background: #0c0c10; color: #e8e8ee; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.ml-login__ghost:hover { box-shadow: inset 0 0 0 1px #fff; }
.ml-login__danger { background: rgba(255, 92, 103, .12); color: #ffb3b9; box-shadow: inset 0 0 0 1px rgba(255, 92, 103, .5); }
.ml-login__danger:hover { background: rgba(255, 92, 103, .22); color: #fff; }

/* ---------- account pages ---------- */
.ml-acct__inner { max-width: 880px !important; }
html.grok-theme body:has([data-gk-cart-page]) .ml-acct__head { margin-bottom: 22px !important; }
.ml-acct__email { max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.ml-acct__tabs { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; width: fit-content; max-width: 100%; margin: 0 auto 30px; padding: 6px; border-radius: 999px; background: rgba(10, 10, 13, .85); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); }
.ml-acct__tabs a, .ml-acct__tabs button { display: inline-flex; align-items: center; gap: 8px; padding: 11px 16px; border: 0; border-radius: 999px; background: none; color: #a8a8b5; font: 600 12px/1 var(--ml-mono); letter-spacing: .1em; text-transform: uppercase; text-decoration: none; cursor: pointer; transition: color .2s, background .2s; }
.ml-acct__tabs svg { width: 16px; height: 16px; flex: none; }
.ml-acct__tabs a:hover, .ml-acct__tabs button:hover { color: #fff; background: rgba(255, 255, 255, .06); }
.ml-acct__tabs a.is-on { color: #0b0b0e; background: var(--ml-tex); box-shadow: 0 0 0 1px #000, 0 0 18px rgba(255, 255, 255, .18); }
.ml-acct__tabs .ml-acct__out:hover { color: #ffb3b9; background: rgba(255, 92, 103, .08); }

.ml-acct__stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 34px; }
.ml-acct__stat { position: relative; display: grid; gap: 10px; justify-items: center; padding: 18px 12px; border-radius: 18px; background: linear-gradient(180deg, rgba(20, 20, 25, .96), rgba(8, 8, 10, .98)); box-shadow: 0 20px 44px rgba(0, 0, 0, .55); text-align: center; animation: mlb-up .55s var(--ml-ease) both; }
.ml-acct__stat > span:not(.ml-rim) { color: #8a8a96; font: 600 10.5px/1 var(--ml-mono); letter-spacing: .2em; text-transform: uppercase; }
.ml-acct__stat strong { color: #fff; font: 700 clamp(18px, 3.4vw, 26px)/1 var(--ml-display); letter-spacing: .04em; white-space: nowrap; }
.ml-acct__stat .ml-rim, .ml-acct__item .ml-rim, .ml-acct__order .ml-rim, .ml-acct__help .ml-rim, .ml-acct__empty .ml-rim { opacity: .5; }
.ml-rimhost:hover > .ml-rim { opacity: 1; }

.ml-acct__sec { margin-bottom: 26px; }
.ml-acct__h { margin: 0 0 14px; text-align: center; color: #c9c9d2; font: 600 11px/1 var(--ml-mono); letter-spacing: .24em; text-transform: uppercase; }

.ml-acct__owned, .ml-acct__orders, .ml-acct__order-items { margin: 0; padding: 0; list-style: none; }
.ml-acct__owned { display: grid; gap: 12px; }
.ml-acct__item {
  position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 16px;
  padding: 14px 14px 14px 14px; border-radius: 20px;
  background: linear-gradient(180deg, rgba(20, 20, 25, .96), rgba(8, 8, 10, .98));
  box-shadow: 0 24px 50px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 255, 255, .05);
  animation: mlb-up .6s var(--ml-ease) both; animation-delay: calc(var(--ml-i, 0) * 70ms);
  transition: transform .3s var(--ml-ease);
}
.ml-acct__item:hover { transform: translateY(-2px); }
.ml-acct__item > :not(.ml-rim), .ml-acct__order > :not(.ml-rim), .ml-acct__help > :not(.ml-rim), .ml-acct__empty > :not(.ml-rim), .ml-acct__stat > :not(.ml-rim) { position: relative; z-index: 1; }
.ml-acct__thumb { display: grid; place-items: center; width: 64px; height: 64px; flex: none; overflow: hidden; border-radius: 14px; background: #050506; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16), 0 10px 22px rgba(0, 0, 0, .5); }
.ml-acct__thumb img { width: 100%; height: 100%; object-fit: cover; }
.ml-acct__thumb b { color: #55555f; font: 700 14px/1 var(--ml-display); }
.ml-acct__thumb--sm { width: 42px; height: 42px; border-radius: 11px; }
.ml-acct__info { display: grid; gap: 6px; min-width: 0; justify-items: start; }
.ml-acct__name { max-width: 100%; overflow: hidden; color: #fff; font: 700 15px/1.2 var(--ml-display); letter-spacing: .05em; text-overflow: ellipsis; white-space: nowrap; }
.ml-acct__meta { max-width: 100%; overflow: hidden; color: #8a8a96; font: 500 12px/1.3 var(--ml-mono); text-overflow: ellipsis; white-space: nowrap; }
.ml-acct__pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border-radius: 999px; color: #c9c9d2; font: 600 10px/1 var(--ml-mono); letter-spacing: .14em; text-transform: uppercase; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16); }
.ml-acct__pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #8a8a96; }
.ml-acct__pill--ok { color: #b8f5d2; box-shadow: inset 0 0 0 1px rgba(61, 220, 132, .35); }
.ml-acct__pill--ok::before { background: #3ddc84; box-shadow: 0 0 8px #3ddc84; }
.ml-acct__pill--wait { color: #f5e3b8; box-shadow: inset 0 0 0 1px rgba(240, 198, 116, .35); }
.ml-acct__pill--wait::before { background: #f0c674; box-shadow: 0 0 8px #f0c674; animation: mlb-led 1.6s ease-in-out infinite; }
.ml-acct__pill--bad { color: #ffb3b9; box-shadow: inset 0 0 0 1px rgba(255, 92, 103, .35); }
.ml-acct__pill--bad::before { background: #ff5c67; }
.ml-acct__note { margin: 12px auto 0; max-width: 60ch; color: #77778a; font: 500 12px/1.5 var(--ml-mono); text-align: center; }
.ml-acct__note a { color: #d8d8e0; }

/* orders list */
.ml-acct__orders { display: grid; gap: 14px; }
.ml-acct__order { position: relative; display: grid; gap: 14px; padding: 18px; border-radius: 20px; background: linear-gradient(180deg, rgba(20, 20, 25, .96), rgba(8, 8, 10, .98)); box-shadow: 0 24px 50px rgba(0, 0, 0, .6), inset 0 1px 0 rgba(255, 255, 255, .05); animation: mlb-up .6s var(--ml-ease) both; animation-delay: calc(min(var(--ml-i, 0), 8) * 60ms); }
.ml-acct__order-top { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; padding-bottom: 14px; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.ml-acct__order-no { color: #fff; font: 600 13px/1 var(--ml-mono); letter-spacing: .06em; }
.ml-acct__order-date { color: #77778a; font: 500 12px/1 var(--ml-mono); }
.ml-acct__order-price { margin-left: auto; color: #fff; font: 700 17px/1 var(--gk-font-body, sans-serif); }
.ml-acct__order-items { display: grid; gap: 10px; }
.ml-acct__order-items li { display: flex; align-items: center; gap: 12px; min-width: 0; }
.ml-acct__order-items .ml-acct__name { font-size: 13.5px; }
.ml-acct__order-act { display: flex; justify-content: flex-end; }
.ml-acct__order-act .ml-acct__note { margin: 0; text-align: right; }
.ml-acct__pages { display: flex; justify-content: center; margin-top: 22px; }

/* empty, help, delete */
.ml-acct__empty, .ml-acct__help { position: relative; border-radius: 20px; background: linear-gradient(180deg, rgba(20, 20, 25, .96), rgba(8, 8, 10, .98)); box-shadow: 0 24px 50px rgba(0, 0, 0, .6); color: #a8a8b5; font: 500 13px/1.5 var(--ml-mono); }
.ml-acct__empty { display: grid; justify-items: center; gap: 10px; padding: 34px 20px; text-align: center; }
.ml-acct__empty p { margin: 0; }
.ml-acct__empty .ml-ring { margin-top: 10px; }
.ml-acct__empty-title, .ml-acct__help-title { color: #fff !important; font: 700 18px/1.2 var(--ml-display) !important; letter-spacing: .05em; text-transform: uppercase; }
.ml-acct__help { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 20px 22px; }
.ml-acct__help p { margin: 0; }
.ml-acct__help-title { margin-bottom: 4px !important; font-size: 15px !important; }
.ml-acct__danger { margin: 28px 0 0; text-align: center; }
.ml-acct__danger button { padding: 8px 12px; border: 0; background: none; color: #55555f; font: 500 12px/1 var(--ml-mono); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.ml-acct__danger button:hover { color: #ffb3b9; }
.ml-acct__danger .ml-acct__quiet:hover { color: #c8c8d0; }

/* ---------- phone ---------- */
@media (max-width: 600px) {
  .gk-login.ml-login { padding: 22px 18px 16px !important; gap: 16px; }
  .ml-login__cell { height: 54px; font-size: 22px; }
  .ml-login__otp { gap: 6px; }
  .ml-acct__tabs { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); width: 100%; gap: 2px; padding: 4px; margin-bottom: 22px; border-radius: 20px; box-sizing: border-box; }
  .ml-acct__tabs a, .ml-acct__tabs button { flex-direction: column; justify-content: center; gap: 6px; padding: 10px 4px; border-radius: 16px; font-size: 9.5px; letter-spacing: .08em; }
  .ml-acct__tabs svg { width: 17px; height: 17px; }
  .ml-acct__stats { gap: 8px; margin-bottom: 26px; }
  .ml-acct__stat { padding: 14px 6px; gap: 8px; }
  .ml-acct__stat > span:not(.ml-rim) { font-size: 9px; letter-spacing: .14em; }
  .ml-acct__stat strong { font-size: 15px; }
  .ml-acct__item { grid-template-columns: auto minmax(0, 1fr); gap: 12px; }
  .ml-acct__item > .ml-ring { grid-column: 1 / -1; }
  .ml-acct__item > .ml-ring .ml-mb { flex: 1; }
  .ml-acct__thumb { width: 56px; height: 56px; }
  .ml-acct__order { padding: 16px 14px; }
  .ml-acct__order-act .ml-ring { flex: 1; display: flex; }
  .ml-acct__order-act .ml-ring .ml-mb { flex: 1; }
  .ml-acct__order-act .ml-acct__note { text-align: left; }
  .ml-acct__help { flex-direction: column; align-items: stretch; text-align: center; }
  .ml-acct__help .ml-ring { display: flex; }
  .ml-acct__help .ml-ring .ml-mb { flex: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .ml-login__cell, .ml-acct__item { transition: none; }
}
