/* Các trang ứng dụng của site: mọi trang trò chơi và trang Admin. Mobile-first (Android và iPhone, từ 320px
   trở lên), cùng bảng màu với site Geborgenheit: token, thanh ứng dụng, view, thẻ, nút, trường nhập, menu của
   người chơi, phòng, sảnh chờ, lịch sử, hộp thoại, toast và dòng kết nối. Stylesheet của mỗi module
   (modules/<name>/css/) tải sau file này. */

:root {
  /* Bảng màu Geborgenheit, cùng giá trị với shared/js/tailwind-theme.js */
  --ink: #2b231e;
  --muted: #65584e;
  --accent: #9c4728;
  --accent-dark: #7a361d;
  --cream: #faf6f0;
  --sand: #f3ece2;
  --blush: #f6e6da;
  --line: #e8ded2;
  --clay: #efe2d3;
  --white: #fff;
  --green: #3f8f5a;
  --green-soft: #e3f1e7;
  --green-text: #245c38;
  --red: #d64545;
  --hint: #e0a526;
  --hint-soft: #fdf5e1;

  /* Khi xoay ngang, lề hai bên rộng ra quá phần tai thỏ / Dynamic Island. */
  --pad-left: max(16px, env(safe-area-inset-left));
  --pad-right: max(16px, env(safe-area-inset-right));
  --safe-bottom: env(safe-area-inset-bottom);
  --radius: 16px;

  font-family: "DM Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--cream);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html, body { margin: 0; background: var(--cream); }
body { line-height: 1.45; -webkit-tap-highlight-color: transparent; }
h1, h2, p { margin: 0; }
h2 { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; font-size: 17px; }
button, input, select { font: inherit; color: inherit; }
/* Không zoom khi chạm hai lần / không trễ 300ms khi chạm. */
button, a, input, select, label, summary { touch-action: manipulation; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.muted { color: var(--muted); }

.app {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
}

/* Một điện thoại ở chế độ "desktop site", được shared/js/fit-phone.js thu lại về chiều rộng của điện thoại:
   đơn vị viewport cũng sẽ bị thu theo, nên chiều cao lấy từ --app-height đã đo. */
.phone-fit .app { min-height: var(--app-height); }

/* --- Thanh ứng dụng --- */

.appbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: calc(env(safe-area-inset-top) + 8px) var(--pad-right) 8px var(--pad-left);
  border-bottom: 1px solid var(--line);
  background: rgb(250 246 240 / 0.92);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  backdrop-filter: saturate(1.4) blur(12px);
}
.appbar-back {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  margin-left: -8px;
  border-radius: 50%;
  color: var(--muted);
  font-size: 22px;
  text-decoration: none;
}
.brand { flex: none; font-family: "Playfair Display", Georgia, serif; font-size: 20px; white-space: nowrap; }
.brand-note { margin-left: 4px; color: var(--muted); font-family: "DM Sans", sans-serif; font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.brand b { color: var(--accent); font-weight: inherit; }
.appbar-user { display: flex; align-items: center; gap: 8px; min-width: 0; margin-left: auto; color: var(--muted); font-size: 14px; }
.appbar-user span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Dưới 400px, "Thoát" nhường chiều rộng cho tên tài khoản: chỉ còn biểu tượng thoát. Chữ vẫn là nhãn của
   nút (trình đọc màn hình, báo lỗi). */
@media (max-width: 399px) {
  .appbar-user #logout {
    --i-exit: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4M16 17l5-5-5-5M21 12H9'/%3E%3C/svg%3E");
    display: inline-grid;
    flex: none;
    place-items: center;
    width: 36px;
    padding: 0;
    font-size: 0;
  }
  .appbar-user #logout::before { content: ""; width: 18px; height: 18px; background: currentColor; -webkit-mask: var(--i-exit) center / contain no-repeat; mask: var(--i-exit) center / contain no-repeat; }
}

/* --- Các view --- */

.view {
  flex: 1;
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 16px var(--pad-right) calc(16px + var(--safe-bottom)) var(--pad-left);
}
/* Nội dung một màn hình nằm ở đầu trang, căn giữa theo chiều ngang: căn giữa cả theo chiều dọc thì trên điện
   thoại để lại một dải trống phía trên. Vòng xoay đang tải vẫn ở giữa. */
.view-center { display: grid; place-items: start center; }
.view-center[data-view="loading"] { place-items: center; }
@media (min-width: 640px) {
  .view-center { padding-top: 32px; }
}

.card {
  min-width: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
}
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.card-head h2 { margin: 0; }

/* --- Nút --- */

.btn {
  min-height: 48px;
  padding: 0 22px;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.15s, opacity 0.15s, transform 0.1s;
}
a.btn { display: inline-flex; align-items: center; justify-content: center; color: var(--ink); text-decoration: none; }
.btn:disabled { cursor: not-allowed; opacity: 0.45; }
.btn:active:not(:disabled) { transform: scale(0.97); }
.btn-primary { background: var(--accent); color: var(--white); }
.btn-ghost { border: 1px solid var(--line); background: var(--white); color: var(--ink); }
.btn-small { min-height: 36px; padding: 0 14px; font-size: 14px; font-weight: 600; }
.btn-block { width: 100%; }
.btn-danger { background: var(--red); color: var(--white); }
.btn-danger-text { color: var(--red); }
.link-button { padding: 4px 2px; border: 0; background: none; color: var(--accent-dark); font-size: 14px; font-weight: 700; text-decoration: underline; cursor: pointer; }
@media (hover: hover) {
  .btn-primary:hover:not(:disabled) { background: var(--accent-dark); }
  .btn-ghost:hover:not(:disabled) { background: var(--sand); }
  .btn-danger:hover:not(:disabled) { background: #b83434; }
}

.badge, .status-pill, .chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 28px;
  height: 26px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--clay);
  color: var(--accent-dark);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}
.status-pill[data-status="PLAYING"] { background: var(--hint-soft); color: #8a6212; }
.status-pill[data-status="FINISHED"] { background: var(--green-soft); color: var(--green-text); }
.status-pill[data-status="PAUSED"] { background: var(--sand); color: var(--muted); }

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--clay);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

/* --- Đăng nhập --- */

.field { display: grid; gap: 6px; font-size: 14px; font-weight: 700; }
.field input, .field select {
  width: 100%;
  height: 50px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--cream);
  font-size: 17px; /* ≥16px để iOS Safari không zoom vào trường nhập */
  font-weight: 400;
  -webkit-appearance: none;
  appearance: none;
}
.field input:focus, .field select:focus, .input:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px rgb(156 71 40 / 0.15); }
.field input[readonly] { color: var(--muted); }
/* Select có mũi tên tự vẽ, vì appearance: none bỏ mũi tên gốc. */
.field select, select.input {
  padding-right: 36px;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px;
  background-repeat: no-repeat;
}
.form-error { color: var(--red); font-size: 14px; font-weight: 600; }
/* Khi rỗng, nó không chiếm chỗ (cũng không chiếm một khoảng gap của grid trong form) phía trên các nút. */
.form-error:empty { display: none; }
.hint { color: var(--muted); font-size: 13px; }

/* --- Menu ngang của người chơi (index.html của mỗi trò) --- */

.player-nav {
  display: flex;
  justify-content: center;
  gap: 4px;
  padding: 6px var(--pad-right) 6px var(--pad-left);
  border-bottom: 1px solid var(--line);
  background: var(--white);
}
.nav-item {
  display: flex;
  flex: 0 1 auto;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-width: 0;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}
.nav-item .icon { width: 18px; height: 18px; }
/* "Trò khác" là một nút (shared/js/game/switcher.js), vẽ giống các link. */
button.nav-item { border: 0; background: none; font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.nav-item[aria-current="page"] { background: var(--blush); color: var(--accent-dark); }
@media (hover: hover) {
  .nav-item:hover:not([aria-current="page"]) { background: var(--sand); color: var(--ink); }
}
/* Điện thoại nhỏ: các mục bằng nhau, biểu tượng nằm trên một nhãn ngắn, nên thanh không bao giờ cuộn. Nhãn quá
   dài so với mục của nó (năm mục trên điện thoại 360px) xuống hai dòng thay vì tràn ra ngoài. */
@media (max-width: 479px) {
  .nav-item, button.nav-item { flex: 1 1 0; flex-direction: column; gap: 2px; min-height: 50px; padding: 4px; border-radius: 12px; font-size: 12px; }
  .nav-item span { line-height: 1.15; text-align: center; white-space: normal; }
}

.page-title { margin-bottom: 6px; font-size: 22px; }
.mine-card { display: grid; gap: 10px; width: min(100%, 520px); }
.mine-card .game-history { margin-top: 4px; }
.lobby-next { font-size: 15px; }
.lobby-next mark { padding: 0 4px; border-radius: 4px; background: var(--blush); color: var(--accent-dark); font-weight: 700; }
.lobby-next a, .rooms > .muted a, .lobby-guide a { color: var(--accent-dark); font-weight: 700; }

/* --- Danh sách phòng (người chơi) --- */

.rooms { display: grid; gap: 12px; width: min(100%, 520px); }
.rooms-title { font-family: "Playfair Display", Georgia, serif; font-size: 28px; font-weight: 500; text-align: center; }
.rooms > .muted { font-size: 15px; text-align: center; }
.room-list { display: grid; gap: 10px; margin: 4px 0 0; padding: 0; list-style: none; }
.room-list li.empty { text-align: center; }
.room-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 2px 12px;
  width: 100%;
  min-height: 68px;
  padding: 12px 16px;
  border: 2px solid var(--line);
  border-radius: var(--radius);
  background: var(--white);
  text-align: left;
  cursor: pointer;
}
.room-item strong { font-size: 18px; overflow-wrap: anywhere; }
.room-item small { grid-column: 1; color: var(--muted); font-size: 13px; }
.room-item small.room-elsewhere { color: var(--accent-dark); font-weight: 700; }
.room-item .status-pill { grid-row: 1 / span 2; grid-column: 2; }
.room-item:active { transform: scale(0.99); }
@media (hover: hover) {
  .room-item:hover { border-color: var(--accent); }
}

/* --- Thông báo: tài khoản Inactive hoặc đã bị xoá --- */

.notice-card { display: grid; gap: 8px; width: min(100%, 520px); text-align: left; }
.notice-card h2 { margin: 0; }
.notice-title { font-size: 22px; line-height: 1.3; }
.notice-link { display: inline-grid; place-items: center; margin-top: 6px; text-decoration: none; }

/* --- Sảnh chờ --- */

.lobby { display: grid; justify-items: center; gap: 10px; text-align: center; }
.lobby-room { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px 12px; margin-bottom: 6px; font-size: 15px; }
.lobby-room strong { overflow-wrap: anywhere; }
.lobby .spinner { margin-bottom: 8px; }
.lobby-message { font-size: 20px; font-weight: 700; }
.lobby-names {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  max-width: 520px;
  margin: 6px 0 0;
  padding: 0;
  list-style: none;
  font-size: 14px;
}
.lobby-names li { padding: 6px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--white); }
.lobby-names li.is-me { border-color: var(--accent); color: var(--accent-dark); font-weight: 700; }
/* Cách chơi: các cụm từ chính trong <mark>, mỗi cụm giữ trên một dòng (một khung tách ra hai dòng đọc như hai
   khung), màu của trò là các ô mẫu nhỏ (giống các ô của bảng). */
.lobby-guide { width: 100%; max-width: 520px; margin-top: 4px; text-align: left; }
.lobby-guide h2 { margin-bottom: 6px; }
.guide-steps { display: grid; gap: 8px; margin: 0; padding-left: 22px; font-size: 15px; }
.guide-steps li::marker { color: var(--accent); font-weight: 700; }
.lobby-guide mark {
  padding: 0 4px;
  border-radius: 4px;
  background: var(--blush);
  color: var(--accent-dark);
  font-weight: 700;
  white-space: nowrap;
}
.key { display: inline-block; padding: 0 6px; border: 1px solid; border-radius: 6px; font-weight: 700; line-height: 1.5; white-space: nowrap; }
/* Hai lựa chọn cạnh nhau (chế độ chơi của một trò, chế độ thời gian của nó). */
.segmented { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 0 16px; padding: 0; border: 0; }
.segmented legend { margin-bottom: 8px; padding: 0; font-size: 14px; font-weight: 700; }
.segmented label { position: relative; display: block; cursor: pointer; }
.segmented input { position: absolute; inset: 0; margin: 0; opacity: 0; cursor: inherit; }
.segmented span {
  display: grid;
  gap: 2px;
  height: 100%;
  padding: 12px 14px;
  border: 2px solid var(--line);
  border-radius: 14px;
  background: var(--white);
}
.segmented small { color: var(--muted); font-size: 13px; }
.segmented input:checked + span { border-color: var(--accent); background: var(--blush); }
.segmented input:disabled { cursor: not-allowed; }
.segmented input:disabled:not(:checked) + span { opacity: 0.5; }
.segmented input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.card-note { margin: -4px 0 12px; color: var(--muted); font-size: 13px; }

/* Cao khoảng năm ván (mỗi ván 60px + gap 6px); các ván cũ hơn cuộn bên trong thẻ. */
.game-history {
  display: grid;
  gap: 6px;
  max-height: calc(5 * 60px + 4 * 6px);
  margin: 0;
  padding: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  list-style: none;
  font-size: 14px;
  scrollbar-width: thin;
}
.history-item {
  display: grid;
  gap: 2px;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 10px;
  background: var(--cream);
  text-align: left;
  cursor: pointer;
}
/* Tiêu đề dài hay dòng bên dưới nó xuống dòng thứ hai trước khi bị cắt. */
.history-item > strong, .history-item > span { display: -webkit-box; overflow: hidden; overflow-wrap: anywhere; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.history-item strong { line-height: 20px; }
.history-item span { color: var(--muted); font-size: 13px; line-height: 18px; }
@media (hover: hover) {
  .history-item:hover { background: var(--sand); }
}

/* Một ván từ lịch sử, trong hộp thoại: nhãn, tiêu đề, dòng meta và các tiêu đề phụ; mỗi trò tự điền phần còn lại. */
.game-detail {
  width: min(calc(100% - 32px), 460px);
  max-width: none;
  padding: 0;
  border: 0;
  border-radius: 24px;
  color: var(--ink);
  box-shadow: 0 20px 60px rgb(0 0 0 / 0.25);
}
.game-detail::backdrop { background: rgb(43 35 30 / 0.55); }
.detail-body { position: relative; padding: 22px 20px 20px; }
.detail-label { color: var(--muted); font-size: 13px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; }
.detail-title { margin: 4px 48px 4px 0; font-size: 20px; overflow-wrap: anywhere; }
.detail-title:focus { outline: none; }
.detail-meta { color: var(--muted); font-size: 14px; }
.detail-heading { margin: 18px 0 10px; font-size: 15px; }

/* Dòng rỗng của một danh sách ("Chưa có …"). Danh sách có mục mang khung riêng thì bỏ nó trong rule li.empty
   của riêng mình, vì file này tải trước. */
li.empty {
  width: auto;
  height: auto;
  padding: 0;
  border-radius: 0;
  background: none;
  color: var(--muted);
  font-size: 14px;
  font-weight: 400;
}

.icon { flex: none; width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* Lịch sử ván ở dạng trang riêng: cao hơn thẻ năm ván. */
.game-history.history-full { max-height: none; }
/* Một nhãn nhỏ sau tên. */
.tag {
  flex: none;
  margin-left: auto;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--hint-soft);
  color: #8a6212;
  font-size: 12px;
  font-weight: 700;
}
/* Một trường nhập không nằm trong label .field: bộ lọc, ô tìm kiếm, ghi chú. */
.input {
  width: 100%;
  height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--cream);
  font-size: 16px; /* ≥16px để iOS Safari không zoom vào trường nhập */
  -webkit-appearance: none;
  appearance: none;
}
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
@media (max-width: 380px) {
  .field-row { grid-template-columns: 1fr; }
}

/* --- Toast, dòng kết nối, nút đóng của hộp thoại --- */

.toast {
  position: fixed;
  top: calc(env(safe-area-inset-top) + 68px);
  left: 50%;
  z-index: 50;
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--ink);
  color: var(--white);
  font-size: 15px;
  text-align: center;
  box-shadow: 0 10px 30px rgb(0 0 0 / 0.18);
  transform: translateX(-50%);
}
.toast.is-error { background: var(--red); }

/* "Mất kết nối, đang thử lại…" khi trang bị mất kết nối với database (shared/js/game/connection.js). */
.connection-line {
  position: fixed;
  top: calc(env(safe-area-inset-top) + 8px);
  left: 50%;
  z-index: 60;
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--hint-soft);
  color: var(--ink);
  border: 1px solid var(--hint);
  font-size: 14px;
  font-weight: 600;
  text-align: center;
  box-shadow: 0 6px 20px rgb(0 0 0 / 0.12);
  transform: translateX(-50%);
  pointer-events: none;
}

/* Nút "✕" của hộp thoại (người thắng, một ván, một báo lỗi). */
.winner-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: var(--sand);
  cursor: pointer;
  font-size: 16px;
}
/* --- Phòng của người chơi (shared/js/game/host-panel.js, room-picker.js): "＋ Tạo phòng", "Phòng của …",
   dòng "Chủ phòng: …" với "Quản lý phòng", và các hộp thoại của chủ phòng --- */
.room-create { justify-self: center; margin: 4px 0; }
.room-item small.room-host { color: var(--accent-dark); }
.room-item small.room-host.is-mine { font-weight: 700; }
.host-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px; margin: 0; font-size: 14px; }
.host-bar[hidden] { display: none; }
.host-bar-text { color: var(--muted); font-weight: 600; }
.host-dialog {
  width: min(calc(100% - 24px), 520px);
  max-width: none;
  max-height: calc(100% - 24px);
  padding: 0;
  border: 0;
  border-radius: 24px;
  color: var(--ink);
  box-shadow: 0 20px 60px rgb(0 0 0 / 0.25);
}
.host-dialog::backdrop { background: rgb(43 35 30 / 0.55); }
.host-body { position: relative; display: grid; gap: 10px; padding: 22px 18px 18px; }
.host-body .form-title { margin: 0 44px 0 0; font-size: 20px; overflow-wrap: anywhere; }
.host-body form { display: grid; gap: 12px; }
.host-room-name { margin: 0; font-weight: 700; overflow-wrap: anywhere; }
.host-note, .host-status { margin: 0; font-size: 14px; }
.host-playing { margin: 0; padding: 8px 12px; border: 1px solid var(--hint); border-radius: 10px; background: var(--hint-soft); font-size: 14px; }
.host-controls { display: grid; gap: 10px; }
.host-buttons, .host-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.host-actions { justify-content: space-between; padding-top: 6px; border-top: 1px solid var(--line); }
.host-section { margin: 6px 0 0; font-size: 15px; }
.host-list { display: grid; gap: 6px; margin: 0; padding: 0; list-style: none; }
.host-list li { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 6px 10px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 12px; background: var(--white); }
.host-list li.empty { justify-content: center; color: var(--muted); }
.host-person { min-width: 0; overflow-wrap: anywhere; font-weight: 600; }
.host-tools { display: flex; flex-wrap: wrap; gap: 6px; }
/* --- "Trò khác" (shared/js/game/switcher.js): các trò chơi và các tiện ích, hai mục một hàng. Mọi ô cao bằng nhau
   (đủ chỗ cho tên 2 dòng, hay tên và dòng "Đang mở"; ô cùng hàng kéo dài theo ô cao nhất), chữ nằm giữa ô theo chiều dọc --- */
.switch-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 0; padding: 0; list-style: none; }
.switch-list li { display: flex; }
.switch-item { display: grid; align-content: center; gap: 2px; width: 100%; min-height: 70px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 14px; background: var(--white); color: var(--ink); font: inherit; font-weight: 700; text-align: left; cursor: pointer; }
.switch-name { overflow-wrap: anywhere; }
.switch-item small { color: var(--accent-dark); font-size: 12px; font-weight: 700; }
.switch-item.is-current { border-color: var(--blush); background: var(--blush); cursor: default; }
@media (hover: hover) {
  .switch-item:hover:not(:disabled) { border-color: var(--accent); background: var(--sand); }
}
.switch-home { justify-self: start; margin-top: 4px; }

@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  .spinner { animation: none; }
}
