/* ============================================================
   Components — Liquid Expressive
   Glass: chrome only. Content: opaque, bold containment, 2.5D.
   ============================================================ */

/* ---------- Glass layer ---------- */

.topbar,
.bottom-nav,
.task-bar,
dialog.modal,
.toast {
  background: var(--glass);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(180%);
  backdrop-filter: blur(var(--glass-blur)) saturate(180%);
  border-color: var(--glass-line);
  box-shadow: var(--glass-shadow);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .topbar,
  .bottom-nav,
  .task-bar,
  dialog.modal,
  .toast {
    background: var(--glass-strong);
    box-shadow: var(--shadow-pop);
  }
}

@media (prefers-reduced-transparency: reduce) {
  .topbar,
  .bottom-nav,
  .task-bar,
  dialog.modal,
  .toast {
    background: var(--glass-strong);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
  }
}

/* Specular sheen: the light band that makes the layer read as glass. */
.topbar::before,
.bottom-nav::before,
.task-bar::before,
dialog.modal::before,
.toast::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: inherit;
  pointer-events: none;
  background: linear-gradient(
    125deg,
    rgba(255, 255, 255, 0.55),
    rgba(255, 255, 255, 0) 34%,
    rgba(255, 255, 255, 0.24) 58%,
    rgba(255, 255, 255, 0) 74%
  );
}

.topbar__inner,
.bottom-nav__link,
.task-bar__inner,
.modal__head,
.modal__body,
.modal__foot {
  position: relative;
  z-index: 1;
}

/* ---------- Chrome ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  transition: border-color var(--dur-2) var(--ease-out),
    background var(--dur-3) var(--ease-out);
}

.topbar.is-scrolled {
  border-bottom-color: rgba(23, 19, 13, 0.1);
  background: var(--glass-strong);
}

.topbar__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  height: 100%;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--s-3);
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 900;
  letter-spacing: -0.03em;
  text-decoration: none;
  white-space: nowrap;
}

.brand img {
  width: 40px;
  height: 40px;
  border-radius: 13px;
  box-shadow: 0 4px 12px -4px rgba(23, 19, 13, 0.35);
}

.brand__tag {
  display: none !important;
}

.nav {
  display: none;
  align-items: center;
  gap: var(--s-1);
}

@media (min-width: 900px) {
  .nav {
    display: flex;
  }
}

.nav__link {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 0 16px;
  border-radius: var(--r-full);
  color: var(--muted);
  font-size: var(--t-small);
  font-weight: 700;
  text-decoration: none;
  transition: color var(--dur-1) var(--ease-out),
    background var(--dur-2) var(--ease-out),
    transform var(--dur-2) var(--spring);
}

.nav__link:hover {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.6);
  transform: translateY(-2px);
}

.nav__link[aria-current="page"] {
  color: var(--gold-ink);
  background: var(--gold-bright);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7),
    0 4px 12px -6px rgba(90, 53, 0, 0.5);
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: var(--s-2);
}

.topbar__actions .btn {
  height: 44px;
  padding-inline: 16px;
  font-size: var(--t-small);
}

@media (max-width: 899px) {
  .topbar__actions {
    display: none;
  }
}

/* Mobile bottom navigation — REMOVED per user request */
.bottom-nav {
  display: none !important;
}

/* Topbar shared navigation — REMOVED per user request */
.topbar[data-topbar],
[data-chrome="header"] {
  display: none !important;
}

/* Footer */
.footer {
  display: none !important;
}

@media (min-width: 900px) {
  .footer {
    padding-bottom: var(--s-7);
  }
}

.footer__inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: var(--s-5);
}

.footer__note {
  max-width: 44ch;
  color: var(--muted);
  font-size: var(--t-small);
}

.footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: var(--s-3) var(--s-4);
  font-size: var(--t-small);
  font-weight: 600;
}

.footer__links a {
  text-decoration: none;
  color: var(--ink-2);
}

.footer__links a:hover {
  color: var(--gold);
}

/* ---------- Buttons ---------- */

.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--surface);
  --btn-shadow: 0 4px 0 rgba(23, 19, 13, 0.28),
    0 12px 24px -14px rgba(23, 19, 13, 0.5);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 56px;
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: var(--r-3);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: -0.015em;
  text-decoration: none;
  white-space: nowrap;
  corner-shape: squircle;
  box-shadow: var(--btn-shadow);
  transition: transform var(--dur-2) var(--spring),
    background var(--dur-2) var(--ease-out),
    border-color var(--dur-2) var(--ease-out),
    color var(--dur-2) var(--ease-out),
    box-shadow var(--dur-2) var(--ease-out);
}

.btn:hover {
  --btn-bg: #000;
  transform: translateY(-3px);
  box-shadow: 0 7px 0 rgba(23, 19, 13, 0.28),
    0 18px 30px -14px rgba(23, 19, 13, 0.5);
}

.btn:active {
  transform: translateY(3px) scale(0.98);
  box-shadow: 0 1px 0 rgba(23, 19, 13, 0.28);
}

.btn:disabled,
.btn[aria-disabled="true"] {
  opacity: 0.48;
  pointer-events: none;
  box-shadow: none;
}

.btn svg {
  width: 20px;
  height: 20px;
  flex: none;
  stroke-width: 2;
}

.btn--gold {
  --btn-bg: var(--gold-bright);
  --btn-fg: var(--gold-ink);
  --btn-shadow: var(--shadow-lip);
}

.btn--gold:hover {
  --btn-bg: #ffce55;
  box-shadow: 0 9px 0 #bd7500, 0 22px 34px -16px rgba(90, 53, 0, 0.55);
}

.btn--gold:active {
  box-shadow: 0 2px 0 #bd7500;
}

.btn--ghost {
  --btn-bg: var(--surface-2);
  --btn-fg: var(--ink);
  --btn-shadow: 0 3px 0 var(--surface-sunken),
    0 12px 26px -16px rgba(23, 19, 13, 0.3);
  border-color: var(--line);
}

.btn--ghost:hover {
  --btn-bg: var(--surface-3);
}

.btn--quiet {
  --btn-bg: transparent;
  --btn-fg: var(--ink-2);
  --btn-shadow: none;
  border-color: transparent;
  padding-inline: 14px;
}

.btn--quiet:hover {
  --btn-bg: var(--surface-3);
  box-shadow: none;
  transform: none;
}

.btn--danger {
  --btn-bg: var(--red-soft);
  --btn-fg: var(--red);
  --btn-shadow: 0 3px 0 #f0b9b4;
}

.btn--sm {
  min-height: 44px;
  padding-inline: 16px;
  border-radius: var(--r-2);
  font-size: var(--t-small);
}

.btn--lg {
  min-height: 64px;
  padding-inline: 30px;
  border-radius: 24px;
  font-size: 1.0625rem;
}

.btn--block {
  width: 100%;
}

/* ---------- Cards: opaque, concentric, 2.5D ---------- */

.card,
.hero__panel,
.install-card,
.guide-step,
.form-step,
.summary-card,
.action,
.cta,
.band {
  position: relative;
  isolation: isolate;
}

.card,
.hero__panel,
.install-card,
.guide-step,
.form-step,
.summary-card {
  border: 1px solid rgba(23, 19, 13, 0.07);
  border-radius: var(--r-card);
  background: var(--surface-2);
  box-shadow: var(--shadow-card);
  corner-shape: squircle;
}

.card::before,
.hero__panel::before,
.install-card::before,
.guide-step::before,
.form-step::before,
.summary-card::before {
  content: "";
  position: absolute;
  inset: 6px;
  z-index: 0;
  border: 1px solid rgba(23, 19, 13, 0.06);
  border-radius: var(--r-card-inner);
  pointer-events: none;
}

.card {
  padding: var(--s-5);
}

.card--tint {
  background: var(--surface);
}

.card--sunken {
  background: var(--surface-3);
}

.card--gold {
  background: var(--gold-soft);
  border-color: rgba(143, 76, 0, 0.16);
}

.card--ink {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--surface);
}

.card--ink::before {
  border-color: rgba(255, 255, 255, 0.12);
}

.card--ink .muted,
.card--ink .card__sub {
  color: #c2b9a8;
}

.card--flush {
  padding: 0;
  overflow: hidden;
}

.card--interactive {
  display: block;
  text-decoration: none;
  transition: border-color var(--dur-2) var(--ease-out),
    transform var(--dur-3) var(--spring-soft),
    box-shadow var(--dur-3) var(--ease-out);
}

.card--interactive:hover {
  border-color: var(--line-strong);
  transform: translateY(-5px);
  box-shadow: var(--shadow-pop);
}

.card--interactive:active {
  transform: scale(0.99);
}

.card__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-4);
  margin-bottom: var(--s-4);
}

.card__title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: -0.025em;
  line-height: 1.2;
}

.card__sub {
  margin-top: 4px;
  color: var(--muted);
  font-size: var(--t-small);
}

.card__num {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  flex: none;
  border-radius: 16px;
  background: var(--surface-3);
  color: var(--ink);
  font-family: var(--font-display);
  font-size: var(--t-small);
  font-weight: 900;
}

.card--gold .card__num {
  background: var(--gold-bright);
  color: var(--gold-ink);
}

.card__arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: var(--s-4);
  color: var(--gold);
  font-size: var(--t-small);
  font-weight: 700;
}

/* ---------- Chips / badges ---------- */

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 40px;
  padding: 6px 16px;
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  background: var(--surface-2);
  color: var(--ink-2);
  font-size: var(--t-small);
  font-weight: 700;
  white-space: nowrap;
  transition: transform var(--dur-2) var(--spring),
    background var(--dur-2) var(--ease-out);
}

.chip:hover {
  transform: translateY(-2px);
  border-color: var(--line-strong);
}

.chip--active {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--surface);
}

.chip--gold {
  background: var(--gold-soft);
  border-color: rgba(143, 76, 0, 0.18);
  color: var(--gold);
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 30px;
  padding: 4px 12px;
  border-radius: var(--r-full);
  background: var(--surface-3);
  color: var(--ink-2);
  font-size: var(--t-micro);
  font-weight: 700;
  white-space: nowrap;
}

.badge::before {
  content: "";
  width: 7px;
  height: 7px;
  flex: none;
  border-radius: 50%;
  background: currentColor;
}

.badge--green {
  background: var(--green-soft);
  color: var(--green);
}

.badge--red {
  background: var(--red-soft);
  color: var(--red);
}

.badge--gold {
  background: var(--gold-soft);
  color: var(--gold);
}

.badge--blue {
  background: var(--blue-soft);
  color: var(--blue);
}

.badge--plain::before {
  display: none;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 0 5px var(--green-soft);
}

/* ---------- Forms ---------- */

.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.field__label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--t-small);
  font-weight: 700;
  color: var(--ink-2);
}

.field__label .req {
  color: var(--red);
}

.input,
.textarea,
.select {
  width: 100%;
  min-height: 56px;
  padding: 14px 18px;
  border: 1px solid var(--line);
  border-radius: var(--r-3);
  background: var(--surface-2);
  color: var(--ink);
  font-size: 1.0625rem;
  font-weight: 500;
  corner-shape: squircle;
  box-shadow: inset 0 1px 2px rgba(23, 19, 13, 0.03);
  transition: border-color var(--dur-2) var(--ease-out),
    box-shadow var(--dur-2) var(--ease-out);
}

.textarea {
  min-height: 120px;
  resize: vertical;
  line-height: 1.55;
}

.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='18' height='18' fill='none' stroke='%236d6455' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m4 7 5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 18px center;
  padding-right: 46px;
}

.input::placeholder,
.textarea::placeholder {
  color: var(--muted-2);
}

.input:focus,
.textarea:focus,
.select:focus {
  outline: none;
  border-color: var(--gold-2);
  box-shadow: 0 0 0 4px var(--gold-soft);
}

.input--code {
  font-family: var(--font-mono);
  font-size: 1.125rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.field__hint {
  color: var(--muted);
  font-size: var(--t-small);
  line-height: 1.5;
}

.field__error {
  display: none;
  color: var(--red);
  font-size: var(--t-small);
  font-weight: 600;
}

.field.is-invalid .input {
  border-color: var(--red);
  box-shadow: 0 0 0 4px var(--red-soft);
}

.field.is-invalid .field__error {
  display: block;
}

.input-row {
  display: flex;
  gap: var(--s-2);
}

.input-row .input {
  flex: 1;
  min-width: 0;
}

.input-row .btn {
  flex: none;
}

@media (max-width: 480px) {
  .input-row {
    flex-direction: column;
  }
}

/* ---------- Stats ---------- */

.stat {
  padding: var(--s-5);
  border: 1px solid var(--line);
  border-radius: var(--r-4);
  background: var(--surface-2);
  corner-shape: squircle;
  box-shadow: var(--shadow-card);
}

.stat__value {
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 4.4vw, 2.8rem);
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1;
}

.stat__label {
  margin-top: 6px;
  color: var(--muted);
  font-size: var(--t-small);
  font-weight: 600;
}

/* ---------- Notices ---------- */

.notice {
  display: flex;
  gap: 14px;
  padding: 18px 20px;
  border: 1px solid rgba(143, 76, 0, 0.16);
  border-left: 5px solid var(--gold-2);
  border-radius: var(--r-3);
  background: var(--gold-wash);
  font-size: var(--t-small);
  line-height: 1.55;
}

.notice--green {
  border-left-color: var(--green);
  background: var(--green-soft);
}

.notice--red {
  border-left-color: var(--red);
  background: var(--red-soft);
}

.notice--plain {
  border-left-color: var(--line-strong);
  background: var(--surface-3);
}

.notice__icon {
  flex: none;
  font-size: 1.25rem;
  line-height: 1.4;
}

/* ---------- Steps ---------- */

.steps {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.step {
  position: relative;
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: var(--s-4);
  padding-bottom: var(--s-6);
}

.step:last-child {
  padding-bottom: 0;
}

.step::before {
  content: "";
  position: absolute;
  left: 25px;
  top: 52px;
  bottom: 0;
  width: 3px;
  border-radius: var(--r-full);
  background: var(--line);
}

.step:last-child::before {
  display: none;
}

.step__num {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid var(--line);
  border-radius: 17px;
  background: var(--surface-2);
  font-family: var(--font-display);
  font-weight: 900;
  font-size: var(--t-small);
}

.step.is-done .step__num {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--surface);
}

.step.is-done::before {
  background: var(--ink);
}

.step__title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 900;
  line-height: 1.25;
}

.step__body {
  margin-top: 6px;
  color: var(--muted);
  font-size: var(--t-small);
  line-height: 1.6;
}

/* ---------- Progress ---------- */

.progress {
  height: 12px;
  border-radius: var(--r-full);
  background: var(--surface-sunken);
  overflow: hidden;
  box-shadow: inset 0 1px 2px rgba(23, 19, 13, 0.08);
}

.progress__fill {
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: var(--ink);
  transition: width var(--dur-4) var(--spring-soft);
}

.progress--gold .progress__fill {
  background: var(--gold-bright);
}

/* ---------- Tabs ---------- */

.tabs {
  display: flex;
  gap: var(--s-1);
  overflow-x: auto;
  padding: var(--s-1);
  border: 1px solid var(--line);
  border-radius: var(--r-4);
  background: var(--surface-3);
  scrollbar-width: none;
}

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

.tab {
  flex: none;
  min-height: 46px;
  padding: 0 18px;
  border-radius: var(--r-3);
  color: var(--muted);
  font-size: var(--t-small);
  font-weight: 700;
  white-space: nowrap;
  transition: background var(--dur-2) var(--ease-out),
    color var(--dur-2) var(--ease-out),
    transform var(--dur-2) var(--spring);
}

.tab:hover {
  color: var(--ink);
}

.tab[aria-selected="true"],
.tab.is-active {
  background: var(--surface-2);
  color: var(--ink);
  box-shadow: 0 3px 0 var(--surface-sunken),
    0 8px 20px -12px rgba(23, 19, 13, 0.34);
  transform: translateY(-1px);
}

/* ---------- Tables ---------- */

.table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(23, 19, 13, 0.07);
  border-radius: var(--r-4);
  background: var(--surface-2);
  box-shadow: var(--shadow-card);
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--t-small);
  white-space: nowrap;
}

.table th {
  padding: 14px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--surface-3);
  color: var(--muted);
  font-size: var(--t-micro);
  font-weight: 700;
  letter-spacing: 0.06em;
  text-align: left;
  text-transform: uppercase;
}

.table td {
  padding: 16px 20px;
  border-bottom: 1px solid var(--line);
  vertical-align: middle;
}

.table tr:last-child td {
  border-bottom: 0;
}

.table tbody tr {
  transition: background var(--dur-1) var(--ease-out);
}

.table tbody tr:hover {
  background: var(--surface-3);
}

.table tbody tr[data-clickable] {
  cursor: pointer;
}

.table--mobile {
  display: none;
}

@media (min-width: 720px) {
  .table--mobile {
    display: table;
  }
}

.data-list {
  display: grid;
  gap: var(--s-3);
}

@media (min-width: 720px) {
  .data-list {
    display: none;
  }
}

/* ---------- Dialog ---------- */

dialog.modal {
  width: min(94vw, 540px);
  max-height: min(88vh, 780px);
  margin: auto;
  padding: 0;
  border: 1px solid var(--glass-line);
  border-radius: var(--r-panel);
  background: var(--glass);
  color: var(--ink);
  box-shadow: var(--shadow-float), var(--glass-shadow);
  overflow: auto;
  corner-shape: squircle;
}

dialog.modal::backdrop {
  background: rgba(23, 19, 13, 0.55);
  -webkit-backdrop-filter: blur(4px);
  backdrop-filter: blur(4px);
}

dialog.modal[open] {
  animation: modal-in var(--dur-4) var(--spring) both;
}

@keyframes modal-in {
  from {
    opacity: 0;
    transform: translateY(28px) scale(0.94);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.modal__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-6) var(--s-6) 0;
}

.modal__title {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.modal__body {
  padding: var(--s-4) var(--s-6);
  color: var(--ink-2);
  font-size: var(--t-body);
  line-height: 1.6;
}

.modal__foot {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: var(--s-3);
  padding: var(--s-4) var(--s-6) var(--s-6);
}

.modal__close {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  flex: none;
  border-radius: 50%;
  background: var(--surface-2);
  color: var(--muted);
  font-size: 1.15rem;
  transition: transform var(--dur-2) var(--spring),
    color var(--dur-2) var(--ease-out);
}

.modal__close:hover {
  color: var(--ink);
  transform: rotate(90deg);
}

/* ---------- Toast (Floating pill notification) ---------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 32px;
  top: auto;
  z-index: 100;
  width: max-content;
  max-width: min(92vw, 420px);
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 22px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: var(--r-full);
  background: rgba(23, 19, 13, 0.94);
  color: #ffffff;
  font-size: var(--t-small);
  font-weight: 700;
  text-align: center;
  box-shadow: 0 12px 32px rgba(23, 19, 13, 0.35),
    0 2px 8px rgba(0, 0, 0, 0.14),
    inset 0 1px 0 rgba(255, 255, 255, 0.2);
  transform: translate(-50%, 16px) scale(0.96);
  opacity: 0;
  pointer-events: none;
  transition: transform var(--dur-3) var(--spring),
    opacity var(--dur-2) var(--ease-out);
}

.toast.is-show {
  transform: translate(-50%, 0) scale(1);
  opacity: 1;
  pointer-events: auto;
}

@media (max-width: 899px) {
  .toast {
    bottom: calc(76px + env(safe-area-inset-bottom, 0px));
    top: auto;
  }
}

/* ---------- Misc ---------- */

.divider {
  height: 1px;
  background: var(--line);
  border: 0;
}

.code {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 9px;
  background: var(--gold-soft);
  color: var(--gold);
  font-family: var(--font-mono);
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.kbd {
  display: inline-block;
  padding: 2px 8px;
  border: 1px solid var(--line-strong);
  border-bottom-width: 3px;
  border-radius: 8px;
  background: var(--surface-2);
  font-family: var(--font-mono);
  font-size: 0.84em;
}

.empty {
  display: grid;
  place-items: center;
  gap: var(--s-3);
  padding: var(--s-8) var(--s-4);
  border: 2px dashed var(--line-strong);
  border-radius: var(--r-4);
  color: var(--muted);
  text-align: center;
  font-size: var(--t-small);
}

.empty__icon {
  font-size: 2rem;
}

.segmented {
  display: inline-flex;
  gap: var(--s-1);
  padding: var(--s-1);
  border: 1px solid var(--line);
  border-radius: var(--r-full);
  background: var(--surface-3);
}

.segmented__btn {
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--r-full);
  color: var(--muted);
  font-size: var(--t-small);
  font-weight: 700;
}

.segmented__btn.is-active {
  background: var(--surface-2);
  color: var(--ink);
  box-shadow: 0 2px 0 var(--surface-sunken);
}

.switch {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  cursor: pointer;
  font-size: var(--t-small);
  font-weight: 600;
}

.switch input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.switch__track {
  position: relative;
  width: 52px;
  height: 30px;
  flex: none;
  border-radius: var(--r-full);
  background: var(--surface-sunken);
  transition: background var(--dur-2) var(--ease-out);
}

.switch__track::after {
  content: "";
  position: absolute;
  top: 3px;
  left: 3px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--surface-2);
  box-shadow: 0 2px 6px rgba(23, 19, 13, 0.24);
  transition: transform var(--dur-3) var(--spring);
}

.switch input:checked + .switch__track {
  background: var(--ink);
}

.switch input:checked + .switch__track::after {
  transform: translateX(22px);
}

.switch input:focus-visible + .switch__track {
  box-shadow: var(--ring);
}

/* ---------- Utility ---------- */

.hide {
  display: none !important;
}

@media (max-width: 719px) {
  .hide-mobile {
    display: none !important;
  }
}

@media (min-width: 720px) {
  .hide-desktop {
    display: none !important;
  }
}

.mt-2 {
  margin-top: var(--s-2);
}
.mt-3 {
  margin-top: var(--s-3);
}
.mt-4 {
  margin-top: var(--s-4);
}
.mt-5 {
  margin-top: var(--s-5);
}
.mt-6 {
  margin-top: var(--s-6);
}


/* ---------- Web Dialog System (Unified In-Web Confirm/Alert/Prompt) ---------- */

dialog.modal.web-dialog {
  width: min(92vw, 440px) !important;
  max-width: 440px !important;
  margin: auto !important;
  padding: 0 !important;
  border: 1.5px solid var(--line) !important;
  border-radius: 24px !important;
  background: var(--surface-2) !important;
  color: var(--ink) !important;
  box-shadow: 0 24px 64px rgba(23, 19, 13, 0.18), 0 4px 16px rgba(0, 0, 0, 0.06) !important;
  overflow: hidden !important;
  position: fixed !important;
  inset: 0 !important;
  z-index: 999999 !important;
}

dialog.modal.web-dialog::backdrop {
  background: rgba(15, 10, 30, 0.65) !important;
  -webkit-backdrop-filter: blur(8px) !important;
  backdrop-filter: blur(8px) !important;
}

dialog.modal.web-dialog[open] {
  animation: web-dialog-pop 0.28s cubic-bezier(0.34, 1.56, 0.64, 1) both !important;
}

@keyframes web-dialog-pop {
  from {
    opacity: 0;
    transform: translateY(22px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.web-dialog__card {
  display: flex !important;
  flex-direction: column !important;
  padding: 24px !important;
  box-sizing: border-box !important;
}

.web-dialog__head {
  display: flex !important;
  align-items: flex-start !important;
  gap: 14px !important;
  margin-bottom: 14px !important;
}

.web-dialog__icon-wrap {
  width: 44px !important;
  height: 44px !important;
  border-radius: 14px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 1.4rem !important;
  flex-shrink: 0 !important;
  background: var(--gold-wash) !important;
  color: var(--gold-2) !important;
}

.web-dialog__icon-wrap.is-danger {
  background: rgba(239, 68, 68, 0.12) !important;
  color: #ef4444 !important;
}

.web-dialog__icon-wrap.is-warning {
  background: rgba(245, 158, 11, 0.14) !important;
  color: #d97706 !important;
}

.web-dialog__icon-wrap.is-success {
  background: rgba(16, 185, 129, 0.12) !important;
  color: #059669 !important;
}

.web-dialog__header-text {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  padding-top: 2px !important;
}

.web-dialog__title {
  font-family: 'Nunito', -apple-system, sans-serif !important;
  font-size: 1.2rem !important;
  font-weight: 900 !important;
  color: var(--ink) !important;
  margin: 0 !important;
  line-height: 1.3 !important;
  letter-spacing: -0.01em !important;
}

.web-dialog__close {
  width: 32px !important;
  height: 32px !important;
  border-radius: 50% !important;
  border: none !important;
  background: var(--line) !important;
  color: var(--muted) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  font-size: 0.95rem !important;
  cursor: pointer !important;
  transition: all 0.18s ease !important;
  flex-shrink: 0 !important;
}

.web-dialog__close:hover {
  background: var(--line-strong) !important;
  color: var(--ink) !important;
}

.web-dialog__body {
  margin-bottom: 20px !important;
  max-height: 60vh !important;
  overflow-y: auto !important;
}

.web-dialog__message {
  font-family: 'Be Vietnam Pro', -apple-system, sans-serif !important;
  font-size: 0.95rem !important;
  line-height: 1.6 !important;
  color: var(--ink-2) !important;
  white-space: pre-line !important;
  word-break: break-word !important;
}

.web-dialog__input-wrap {
  margin-top: 14px !important;
}

.web-dialog__input {
  width: 100% !important;
  box-sizing: border-box !important;
  height: 44px !important;
  padding: 0 14px !important;
  border: 1.5px solid var(--line-strong) !important;
  border-radius: 12px !important;
  font-family: 'Be Vietnam Pro', sans-serif !important;
  font-size: 0.95rem !important;
  color: var(--ink) !important;
  background: var(--surface) !important;
  outline: none !important;
  transition: border-color 0.2s, box-shadow 0.2s !important;
}

.web-dialog__input:focus {
  border-color: var(--gold-2) !important;
  background: var(--surface-2) !important;
  box-shadow: 0 0 0 3px rgba(201, 122, 0, 0.18) !important;
}

.web-dialog__foot {
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 10px !important;
}

.web-dialog__foot button {
  min-height: 42px !important;
  padding: 0 20px !important;
  font-family: 'Nunito', -apple-system, sans-serif !important;
  font-size: 0.95rem !important;
  font-weight: 800 !important;
  border-radius: 12px !important;
  cursor: pointer !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  transition: transform 0.12s, box-shadow 0.12s !important;
}

.web-dialog__btn-cancel {
  background: var(--surface-3) !important;
  border: 1px solid var(--line) !important;
  color: var(--ink-2) !important;
}

.web-dialog__btn-cancel:hover {
  background: var(--surface-sunken) !important;
}

.web-dialog__btn-cancel:active {
  transform: translateY(2px) !important;
}

.web-dialog__btn-ok.btn--gold {
  background: linear-gradient(135deg, var(--gold-bright), var(--gold-2)) !important;
  color: var(--gold-ink) !important;
  border: none !important;
  box-shadow: 0 4px 0 #bd7500 !important;
}

.web-dialog__btn-ok.btn--gold:active {
  transform: translateY(2px) !important;
  box-shadow: 0 2px 0 #bd7500 !important;
}

.web-dialog__btn-ok.is-danger {
  background: linear-gradient(135deg, #ef4444, #dc2626) !important;
  color: #ffffff !important;
  box-shadow: 0 4px 0 #b91c1c !important;
  border: none !important;
}

.web-dialog__btn-ok.is-danger:active {
  transform: translateY(2px) !important;
  box-shadow: 0 2px 0 #b91c1c !important;
}
