/* Trang đã đăng nhập: vỏ, tổng quan, đơn, rút tiền, hỗ trợ, tôi. Chỉ dùng token của tokens.css. */

/* Ô dán link trong topbar, kiểu ô tìm của prototype/shop.css. */
.search {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  padding: 0.6rem var(--sp-3);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--surface);
}

.search:focus-within {
  border-color: var(--brand);
}

.search svg {
  width: 18px;
  height: 18px;
  fill: var(--ink-3);
  flex-shrink: 0;
}

.search input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  font: inherit;
  font-size: var(--text-sm);
  color: var(--ink);
  outline: none;
}

.search__paste {
  flex-shrink: 0;
  padding: 0.3rem 0.7rem;
  border: none;
  border-radius: var(--radius-inner);
  background: var(--brand-soft);
  color: var(--brand);
  font: inherit;
  font-size: var(--text-sm);
  font-weight: 600;
  cursor: pointer;
}

/* Nút nằm trong ô tìm nên không cao thêm được: nới vùng chạm ra ngoài bằng pseudo-element. */
@media (pointer: coarse) {
  .search__paste {
    position: relative;
  }

  .search__paste::after {
    content: "";
    position: absolute;
    inset: calc((var(--touch) - 100%) / -2) 0;
  }
}

.search__paste:hover:not(:disabled) {
  background: var(--brand);
  color: var(--surface);
}

/* ---- Khối dùng chung ---- */
#paste-result {
  margin-bottom: var(--sp-5);
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-4);
  margin-bottom: var(--sp-3);
}

.section-head h2,
.section-title {
  font-size: var(--text-xl);
  margin-bottom: var(--sp-3);
}

.section-head a {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

/* Thẻ hạng: tên hạng là tiêu đề, câu còn bao nhiêu đơn ngay dưới, chân thẻ là cách giữ hạng. */
.tierbar__head {
  display: grid;
  gap: var(--sp-1);
}

.tierbar__name {
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: -0.022em;
  line-height: 1.15;
}

/* Huy hiệu hạng, cùng ảnh với landing (/images/tier-*.webp). */
.tierbar__medal {
  width: 1.5rem;
  height: 1.5rem;
  flex-shrink: 0;
  background: var(--medal, url("/images/tier-dong.webp")) center / contain no-repeat;
  mix-blend-mode: multiply;
}

.tierbar__name[data-tier="1"] { --medal: url("/images/tier-vang.webp"); }
.tierbar__name[data-tier="2"] { --medal: url("/images/tier-kimcuong.webp"); }

.tierbar__title {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.tierbar__foot {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-1) var(--sp-4);
  margin-top: auto;
  padding-top: var(--sp-2);
  border-top: 1px solid var(--line);
}

.tierbar__keep {
  font-size: var(--text-micro);
  color: var(--ink-3);
}

tr[aria-current="true"] td {
  background: var(--brand-soft);
}

.avatar {
  background: var(--brand);
  color: var(--surface);
}

.table-wrap + .note {
  margin-top: var(--sp-4);
}

th.num {
  text-align: right;
}

#telegram .btn {
  justify-self: start;
}

/* Tên sản phẩm đứng trên dòng phụ trong một ô bảng. Chỉ áp cho span: trang chính sách dùng lớp
   này trên chính ô <td>, và ô bảng thì không được thành block. */
span.cell-name {
  display: block;
  max-width: 42ch;
}

.empty {
  display: grid;
  gap: var(--sp-3);
  justify-items: start;
  padding: var(--sp-6);
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

.empty p {
  max-width: 52ch;
  color: var(--ink-2);
}

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

.payout__bank {
  margin-top: var(--sp-2);
  font-size: var(--text-lg);
  font-weight: 600;
}

.payout__ref {
  margin-top: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.note {
  margin-top: var(--sp-4);
  max-width: 70ch;
}

.back-link {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.order-title {
  margin-top: var(--sp-2);
}

.order-money {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--sp-3);
}

.order-money .money {
  display: block;
  font-size: var(--text-money-hero);
  line-height: 1.1;
}

.order-side {
  display: grid;
  gap: var(--sp-4);
}

/* ---- Danh sách đơn. Mẫu "All purchases" của Klarna: tên sản phẩm là tiêu đề, mã đơn và ngày ở
   dòng nhỏ, tiền hoàn và trạng thái canh phải. Cả dòng bấm được qua link tên. ---- */
.order-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.order-row {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5);
  transition: background-color var(--duration-fast) linear;
}

.order-row + .order-row {
  border-top: 1px solid var(--line);
}

.order-row:hover {
  background: var(--paper);
}

.order-row:active {
  background: var(--paper-2);
}

.order-row__name {
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
}

.order-row__name::after {
  content: "";
  position: absolute;
  inset: 0;
}

.order-row__name:focus-visible {
  outline: none;
}

.order-row:has(.order-row__name:focus-visible) {
  outline: 2px solid var(--brand);
  outline-offset: -2px;
}

.order-row__meta,
.order-row__note {
  font-size: var(--text-sm);
  color: var(--ink-3);
}

.order-row__meta .mono {
  color: var(--ink-2);
}

.order-row__side {
  display: grid;
  justify-items: end;
  align-content: start;
  gap: var(--sp-2);
  text-align: right;
}

.order-row__side .money {
  font-weight: 600;
}

.order-groups {
  display: grid;
  gap: var(--sp-6);
}

.order-group__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: var(--sp-3);
  font-size: var(--text-base);
  font-weight: 600;
}

.order-group__head span {
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--ink-3);
}

.order-filters {
  margin-bottom: var(--sp-5);
}

.topbar__sub a {
  color: var(--brand);
  white-space: nowrap;
}

.order-row--empty {
  display: block;
  padding-block: var(--sp-5);
  color: var(--ink-3);
  text-align: center;
}

.order-row--empty:hover {
  background: none;
}

@media (max-width: 560px) {
  .order-row {
    padding: var(--sp-4);
  }

  /* Bốn chip lọc trên một hàng cuộn ngang, không rớt dòng. */
  .order-filters {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    margin-inline: calc(var(--sp-4) * -1);
    padding-inline: var(--sp-4);
  }
}

/* ---- Rút tiền ---- */
.withdraw {
  display: grid;
  gap: var(--sp-4);
}

.withdraw__amount {
  display: grid;
  gap: var(--sp-1);
  padding-bottom: var(--sp-4);
  border-bottom: 1px solid var(--line);
}

.withdraw__amount .money {
  font-size: var(--text-money-hero);
  line-height: 1.1;
}

.withdraw__amount .results-meta {
  max-width: 46ch;
}

.withdraw__fee {
  color: var(--confirmed);
}

.withdraw__holder {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.withdraw__window {
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--radius);
  background: var(--paper-2);
  font-size: var(--text-sm);
}

.withdraw__cta {
  display: grid;
  gap: var(--sp-2);
  justify-items: start;
}

.withdraw__cta p {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.bank-form__pair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(14rem, 1fr));
  gap: var(--sp-4);
  align-items: start;
}

.link-button {
  justify-self: start;
  padding: 0;
  border: none;
  background: none;
  font: inherit;
  font-size: var(--text-sm);
  color: var(--brand);
  text-decoration: underline;
  cursor: pointer;
}

.notice {
  display: grid;
  gap: var(--sp-1);
  padding: var(--sp-4) var(--sp-5);
  border-left: 3px solid var(--line-strong);
  border-radius: var(--radius-inner);
  background: var(--surface);
}

.notice p {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

/* Chỉ tô màu khi tiền thật sự kẹt lại (luật 2 của tokens.css). */
.notice--open { border-left-color: var(--confirmed); }
.notice--held { border-left-color: var(--pending); background: var(--pending-soft); }
.notice--void { border-left-color: var(--void); background: var(--void-soft); }

.bank-form h2 {
  font-size: var(--text-xl);
}

.bank-form__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--sp-3);
}

.field {
  display: grid;
  gap: var(--sp-1);
}

.field__label {
  font-size: var(--text-sm);
  font-weight: 600;
}

.field input,
.field select,
.field textarea {
  min-height: var(--touch);
  padding: 0.55rem 0.8rem;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-inner);
  background: var(--surface);
  font: inherit;
  color: var(--ink);
}

.field input:focus-visible,
.field select:focus-visible,
.field textarea:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
  border-color: var(--brand);
}

.field__hint {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.field__error {
  font-size: var(--text-sm);
  color: var(--void);
}


.order-pick {
  display: flex;
  justify-content: space-between;
  gap: var(--sp-3);
  padding: var(--sp-3) 0;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
}

.order-pick__side {
  display: grid;
  justify-items: end;
  gap: var(--sp-1);
}

.order-pick input {
  width: 18px;
  height: 18px;
  accent-color: var(--brand);
}

.field__optional {
  font-weight: 400;
  color: var(--ink-3);
}


/* Hộp thư thông báo. Ô biểu tượng mang màu tiền, vì tin nào cũng nói về tiền của một đơn. */
.inbox {
  max-width: 52rem;
  margin: 0;
  padding: 0;
  list-style: none;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-raise);
}

.inbox__item {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) auto;
  gap: var(--sp-1) var(--sp-3);
  padding: var(--sp-4) var(--sp-5);
}

.inbox__item + .inbox__item {
  border-top: 1px solid var(--line);
}

.inbox__item[data-unread] {
  background: linear-gradient(90deg, var(--brand-soft), transparent 60%);
}

.inbox__icon {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius);
  background: var(--paper-2);
  color: var(--ink-2);
}

.inbox__icon svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

[data-s="confirmed"] > .inbox__icon { background: var(--confirmed-soft); color: var(--confirmed); }
[data-s="pending"] > .inbox__icon { background: var(--pending-soft); color: var(--pending); }
[data-s="void"] > .inbox__icon { background: var(--void-soft); color: var(--void); }

.inbox__body {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.inbox__title {
  font-weight: 500;
}

[data-unread] .inbox__title {
  font-weight: 700;
}

[data-unread] .inbox__title::after {
  content: "";
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-left: var(--sp-2);
  vertical-align: middle;
  border-radius: 50%;
  background: var(--brand);
}

.inbox__text {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.inbox__meta {
  font-size: var(--text-micro);
  color: var(--ink-3);
}

.inbox__time {
  font-size: var(--text-micro);
  color: var(--ink-3);
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

@media (max-width: 560px) {
  .inbox__item {
    grid-template-columns: 36px minmax(0, 1fr);
    padding: var(--sp-3) var(--sp-4);
  }

  .inbox__time {
    grid-column: 2;
    grid-row: 2;
  }
}


/* ---- Hạng: thẻ tiến độ trái, bảng so ba hạng phải. Cột hạng hiện tại tô nền thương hiệu nhạt. ---- */
.tier-layout {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: var(--sp-4);
  align-items: start;
  margin-block: var(--sp-5) var(--sp-6);
}

.tier-compare table {
  table-layout: fixed;
}

.tier-compare tbody th,
.tier-compare thead td {
  width: 26%;
}

@media (max-width: 900px) {
  .tier-layout {
    grid-template-columns: minmax(0, 1fr);
  }
}

.tier-layout .tierbar {
  display: flex;
  flex-direction: column;
  margin: 0;
  padding: var(--sp-4) var(--sp-5);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raise);
}

.tier-compare {
  display: grid;
  align-content: start;
  gap: var(--sp-3);
  padding: var(--sp-4) var(--sp-5);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-raise);
}

.tier-compare caption {
  padding-bottom: var(--sp-3);
  text-align: left;
  font-size: var(--text-lg);
  font-weight: 700;
}

.tier-compare thead th {
  padding: var(--sp-3);
  text-transform: none;
  letter-spacing: 0;
  vertical-align: top;
  color: var(--ink);
}

.tier-compare .tierbar__name {
  font-size: var(--text-base);
}

.tier-compare__here {
  display: block;
  margin-top: 2px;
  font-size: var(--text-micro);
  font-weight: 600;
  color: var(--brand);
}

.tier-compare tbody th {
  padding: var(--sp-3) var(--sp-3) var(--sp-3) 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-size: var(--text-sm);
  font-weight: 500;
  color: var(--ink-2);
}

.tier-compare tbody th,
.tier-compare tbody td {
  vertical-align: top;
}

.tier-compare tbody td {
  padding: var(--sp-3);
  font-size: var(--text-sm);
}

.tier-compare tbody tr:last-child th {
  border-bottom: none;
}

.tier-compare tbody tr:hover {
  background: none;
}

.tier-compare [data-current] {
  background: var(--brand-soft);
}

.tier-compare thead [data-current] {
  border-radius: var(--radius) var(--radius) 0 0;
}

.tier-compare tbody tr:last-child [data-current] {
  border-radius: 0 0 var(--radius) var(--radius);
}

.tier-compare__note {
  font-size: var(--text-micro);
  color: var(--ink-3);
}

/* ---- Tôi: hồ sơ ở đầu, rồi các nhóm có tiêu đề, một cột giữa trang như GitBook. ---- */
.account {
  display: grid;
  gap: var(--sp-6);
  max-width: 44rem;
  margin: var(--sp-5) auto 0;
}

.profile {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
}

.profile__avatar {
  width: 64px;
  height: 64px;
  font-size: var(--text-2xl);
}

.profile__who {
  min-width: 0;
}

.profile__name {
  font-size: var(--text-2xl);
  line-height: 1.2;
}

.profile__email {
  margin-top: var(--sp-1);
  color: var(--ink-2);
  font-size: var(--text-sm);
  overflow-wrap: anywhere;
}

.settings-group {
  display: grid;
  gap: var(--sp-2);
}

.settings-group__title {
  color: var(--ink-2);
  font-size: var(--text-sm);
  font-weight: 600;
}

.card.settings-group__body {
  display: grid;
  padding: 0 var(--sp-5);
}

@media (max-width: 560px) {
  .card.settings-group__body {
    padding-inline: var(--sp-4);
  }
}

.setting {
  display: flex;
  align-items: center;
  gap: var(--sp-4);
  padding-block: var(--sp-4);
}

.setting + .setting,
.settings-link + .settings-link {
  border-top: 1px solid var(--line);
}

.setting__text {
  display: grid;
  gap: 2px;
  min-width: 0;
  margin-right: auto;
}

.setting__title {
  font-weight: 600;
}

.setting__hint {
  color: var(--ink-2);
  font-size: var(--text-sm);
}

.setting__hint:empty {
  display: none;
}

.setting__side {
  flex-shrink: 0;
}

.account__foot {
  display: flex;
  justify-content: center;
}

/* Dòng danh sách của mục Tôi, lấy từ khối style cuối prototype/dashboard.html. */
.rows {
  display: grid;
}

.row {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  min-height: var(--touch);
  padding: var(--sp-3) 0;
  border: none;
  border-top: 1px solid var(--line);
  background: none;
  font: inherit;
  text-align: left;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}

.row:first-child {
  border-top: none;
}

.row__label {
  font-weight: 500;
}

.row__label--muted {
  color: var(--ink-2);
}

.row__value {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: var(--sp-2);
  font-size: var(--text-sm);
  color: var(--ink-3);
}

.row--static {
  cursor: default;
}

a.row:hover .row__label,
button.row:hover .row__label {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.bank-form > .btn {
  justify-self: start;
}


/* Cột của dash-split không được nở theo nội dung dài trên màn hẹp. */
.dash-split > * {
  min-width: 0;
}

.order-pick__text {
  min-width: 0;
}

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

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

/* Chọn ngân hàng: ô tìm, rồi lưới ô có logo. Ô đang chọn viền đậm. Logo VietQR là ảnh chữ 831×311. */
.bank-picker {
  border: 0;
  margin: 0;
  padding: 0;
  gap: var(--sp-2);
}

.bank-picker__search {
  font: inherit;
  font-size: var(--text-sm);
  padding: var(--sp-2) var(--sp-3);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
}

.bank-picker__list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: var(--sp-2);
  max-height: 272px;
  overflow-y: auto;
  padding: 2px;
  overscroll-behavior: contain;
}

.bank-option {
  display: grid;
  justify-items: center;
  gap: var(--sp-1);
  padding: var(--sp-2);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  cursor: pointer;
  transition: border-color var(--duration-fast) var(--ease-out-expo), box-shadow var(--duration-fast) var(--ease-out-expo);
}

.bank-option[hidden] {
  display: none;
}

.bank-option:hover {
  border-color: var(--ink-3);
}

.bank-option:has(input:checked) {
  border-color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--ink);
}

.bank-option:has(input:focus-visible) {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.bank-option__name {
  font-size: var(--text-micro);
  color: var(--ink-2);
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.bank-logo {
  display: block;
  width: 80px;
  height: 30px;
  object-fit: contain;
}

.bank-logo--inline {
  display: inline-block;
  width: 48px;
  height: 18px;
  margin-right: var(--sp-2);
  vertical-align: middle;
}

.withdraw__to {
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

/* Ngân hàng, tên chủ tài khoản và nút Đổi xếp dọc, canh phải trong cột giá trị. */
.withdraw__bank {
  display: grid;
  justify-items: end;
  gap: 2px;
}

.withdraw__bank .link-button {
  justify-self: end;
}

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

.withdraw__kv dt {
  white-space: nowrap;
}

.withdraw__kv dd {
  overflow-wrap: anywhere;
}

/* Màn hẹp: nhãn trên, giá trị dưới, vì hai cột chỉ còn chỗ cho mười ký tự. */
@media (max-width: 560px) {
  .withdraw__kv {
    grid-template-columns: minmax(0, 1fr);
    row-gap: 0;
  }

  .withdraw__kv dt {
    font-size: var(--text-sm);
  }

  .withdraw__kv dt:not(:first-child) {
    margin-top: var(--sp-3);
  }

  .withdraw__kv dd,
  .withdraw__kv .withdraw__to {
    text-align: left;
    justify-content: flex-start;
  }

  .withdraw__kv .withdraw__bank,
  .withdraw__bank .link-button {
    justify-items: start;
    justify-self: start;
  }
}

.withdraw__add {
  gap: var(--sp-3);
}

.tier-layout .tierbar__track {
  margin-block: var(--sp-4) var(--sp-2);
}

@media (max-width: 560px) {
  .tier-compare {
    padding-inline: var(--sp-4);
  }

  .tier-compare thead th,
  .tier-compare tbody td {
    padding-inline: var(--sp-2);
  }

  .tier-compare .tierbar__medal {
    display: none;
  }
}

/* Hỗ trợ: các lối vào là dòng hai tầng, tiêu đề và một câu khi nào dùng. */
.help-doors {
  padding-block: var(--sp-2);
}

.help-door {
  align-items: center;
}

.help-door__text {
  display: grid;
  gap: 2px;
}

.help-door__hint {
  color: var(--ink-2);
  font-size: var(--text-sm);
}

/* ---- Trang liên kết bot (#53): khung hẹp, mã trong sáu ô, mẫu Bonsai và Coinbase trên Mobbin ---- */
.link-page {
  max-width: 28rem;
  margin: var(--sp-6) auto;
  display: grid;
  justify-items: start;
  gap: var(--sp-4);
}

.link-page h1 {
  margin: 0;
  font-size: var(--text-2xl);
}

.link-page__lede,
.link-page__expiry {
  margin: 0;
  color: var(--ink-2);
}

.link-page__error {
  margin: 0;
  color: var(--void);
}

.pin {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 3rem));
  width: 100%;
  gap: var(--sp-2);
  margin: var(--sp-2) 0 0;
}

.pin span[aria-hidden] {
  display: grid;
  place-items: center;
  height: 3.5rem;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  font-family: var(--font-mono);
  font-size: var(--text-2xl);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

/* ---- Mời bạn (#191, #192): màn /invite theo prototype/web-app/moi-ban.html, và lối vào ở trang Tôi ---- */

.mb {
  width: 100%;
  max-width: 640px;
  margin-inline: auto;
  display: grid;
  gap: var(--sp-6);
}

.mb-ic {
  width: 20px;
  height: 20px;
  fill: currentColor;
  flex: none;
}

.mb-title {
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink);
  max-width: 18ch;
}

.mb-lead {
  max-width: 46ch;
  margin-top: calc(-1 * var(--sp-3));
  font-size: var(--text-base);
  line-height: 1.55;
  color: var(--ink-2);
}

.mb-fine {
  margin-top: calc(-1 * var(--sp-3));
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.mb-fine--center {
  margin-top: var(--sp-2);
  text-align: center;
}

.mb-duo {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--sp-3);
  margin: 0;
  padding: 0;
  list-style: none;
}

.mb-duo li {
  display: grid;
  gap: var(--sp-3);
  padding: var(--sp-4);
  border-radius: var(--radius-lg);
  background: var(--surface);
  box-shadow: var(--shadow-lift);
}

.mb-duo li span:last-child {
  display: grid;
  gap: 2px;
  font-size: var(--text-sm);
  line-height: 1.4;
  color: var(--ink-2);
}

.mb-duo strong {
  font-size: var(--text-lg);
  color: var(--ink);
}

.mb-duo__ic {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-pill);
  background: var(--brand);
  color: var(--on-brand);
}

.mb-duo li + li .mb-duo__ic {
  background: var(--brand-soft);
  color: var(--brand);
}

.mb-dock {
  display: grid;
  gap: var(--sp-2);
  padding: var(--sp-4);
  border-radius: var(--radius-lg);
  background: var(--surface);
  border: 1px solid var(--line);
}

.mb-dock__code {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: 56px;
  border: 2px dashed var(--line-strong);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  cursor: pointer;
}

.mb-dock__code .mono {
  font-size: var(--text-2xl);
  font-weight: 700;
  letter-spacing: 0.1em;
}

.mb-dock__code small {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

/* ---- Nút: một nút chính, hai lối phụ dạng chữ ---- */
.mb-actions {
  display: grid;
  gap: var(--sp-1);
}

.mb-send {
  width: 100%;
  min-height: 52px;
  gap: var(--sp-2);
  font-size: var(--text-lg);
}

.mb-send:active {
  transform: scale(0.98);
}

.mb-actions__more {
  display: flex;
  justify-content: center;
  gap: var(--sp-2);
}

.mb-link {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: var(--touch);
  padding: 0 var(--sp-3);
  border: 0;
  border-radius: var(--radius-pill);
  background: none;
  color: var(--brand);
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.mb-link:hover {
  background: var(--brand-soft);
}

.mb-link:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.mb-link .mb-ic {
  width: 18px;
  height: 18px;
}

.mb-status {
  text-align: center;
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.mb-status:empty {
  display: none;
}

/* ---- Phần của bạn: còn bao nhiêu ngày được hoàn thêm ---- */
.mb-mine {
  display: grid;
  gap: var(--sp-2);
  padding: var(--sp-4) var(--sp-5);
  border-radius: var(--radius-lg);
  background: var(--brand-soft);
}

.mb-mine__row {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--sp-3);
}

.mb-mine__title {
  max-width: none;
  white-space: nowrap;
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--ink);
}

.mb-mine__left {
  font-weight: 700;
  color: var(--brand);
  white-space: nowrap;
}

.mb-mine__bar {
  height: 6px;
  border-radius: var(--radius-pill);
  background: color-mix(in oklch, var(--brand) 16%, transparent);
  overflow: hidden;
}

.mb-mine__bar span {
  display: block;
  width: var(--p);
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.mb-mine__note {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

.mb-ic--sm {
  width: 16px;
  height: 16px;
}

.mb-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-3);
  margin-top: var(--sp-2);
  padding: var(--sp-3) var(--sp-3) var(--sp-3) var(--sp-4);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
}

.mb-code__label {
  font-size: var(--text-sm);
  color: var(--ink-2);
}

/* Bấm vào mã là chép mã: mã to nhất trong khối, có icon chép ngay cạnh. */
.mb-code__value {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: var(--touch);
  padding: 0 var(--sp-3);
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--paper-2);
  color: var(--ink);
  font-size: var(--text-xl);
  font-weight: 700;
  letter-spacing: 0.06em;
  cursor: pointer;
}

.mb-code__value:hover {
  background: var(--line);
}

.mb-code__value:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

/* ---- Mục dưới ---- */
.mb-section {
  display: grid;
  gap: var(--sp-3);
}

.mb-section__title {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 700;
  color: var(--ink);
}

.mb-count {
  margin-left: var(--sp-1);
  color: var(--ink-2);
  font-weight: 600;
}

.mb-card {
  padding: var(--sp-4) var(--sp-5);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
}

/* Danh sách người đã mời */
.mb-people {
  list-style: none;
  margin: 0;
  padding-block: var(--sp-1);
}

.mb-person {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  padding-block: var(--sp-3);
}

.mb-person + .mb-person {
  border-top: 1px solid var(--line);
}

.mb-person__avatar {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: var(--radius-pill);
  background: var(--paper-2);
  font-weight: 700;
  color: var(--ink);
}

.mb-person__name {
  display: grid;
  flex: 1;
  font-weight: 600;
  color: var(--ink);
}

.mb-person__name small {
  font-size: var(--text-sm);
  font-weight: 400;
  color: var(--ink-2);
}

.mb-foot {
  text-align: center;
  font-size: var(--text-sm);
}

.mb-foot a {
  color: var(--ink-2);
}

/* Trạng thái rỗng và không có chiến dịch */
.mb-empty {
  display: grid;
  gap: var(--sp-1);
  padding-block: var(--sp-5);
  text-align: center;
}

.mb-empty__title {
  font-weight: 700;
  color: var(--ink);
}

.mb-empty__text {
  font-size: var(--text-sm);
  line-height: 1.5;
  color: var(--ink-2);
}

.mb-off {
  display: grid;
  gap: var(--sp-3);
}

.mb-code--plain {
  margin-top: 0;
  border: 1px solid var(--line);
}

@media (min-width: 720px) {
  .mb-title {
    font-size: var(--text-3xl);
  }
}

.mb-badge {
  background: var(--paper-2);
  color: var(--ink);
}

.mb-badge--muted {
  color: var(--ink-2);
}

/* Lối vào ở trang Tôi. */
.invite-entry {
  color: inherit;
  text-decoration: none;
}

.invite-entry__icon {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex: none;
  border-radius: var(--radius-pill);
  background: var(--brand-soft);
  color: var(--brand);
}

.invite-entry__icon svg {
  width: 22px;
  height: 22px;
  fill: currentColor;
}

.invite-entry .row__value {
  font-size: var(--text-xl);
}

.invite-entry:hover .setting__title {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.invite-qr {
  text-align: center;
}

.invite-qr__code {
  justify-self: center;
  width: min(100%, 240px);
  height: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
