html,
body,
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(148, 163, 184, 0.48) rgba(15, 18, 24, 0.92);
}

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

*::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

*::-webkit-scrollbar-track {
  background: rgba(15, 18, 24, 0.92);
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.42);
  border-radius: 999px;
}

*::-webkit-scrollbar-thumb:hover {
  background: rgba(255, 111, 125, 0.68);
}

.admin-title-actions,
.admin-checkbox-inline {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.admin-checkbox-inline {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(15, 18, 24, 0.72);
  color: rgba(255, 255, 255, 0.74);
  font-size: 13px;
}

.compact-grid {
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
}

.support-fab {
  position: fixed;
  right: 18px;
  bottom: 22px;
  z-index: 70;
  min-width: 112px;
  height: 46px;
  border: 0;
  border-radius: 999px;
  background: #ff6f7d;
  color: #10131a;
  font-weight: 900;
  box-shadow: 0 16px 40px rgba(255, 111, 125, 0.28);
  cursor: pointer;
}

.support-widget {
  position: fixed;
  right: 18px;
  bottom: 82px;
  z-index: 80;
  width: min(390px, calc(100% - 36px));
  max-height: min(680px, calc(100vh - 110px));
  display: grid;
  grid-template-rows: auto minmax(260px, 1fr) auto;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: #151922;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.5);
}

.support-header {
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(16, 19, 26, 0.96);
}

.support-header strong,
.support-header span {
  display: block;
}

.support-header span {
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
}

.support-header button,
.modal-close {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.82);
  cursor: pointer;
}

.support-body {
  min-height: 0;
  overflow-y: auto;
  padding: 14px;
}

.support-connect-state {
  min-height: 260px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 10px;
  padding: 24px;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
}

.support-connect-state strong {
  color: rgba(255, 255, 255, 0.92);
  font-size: 18px;
}

.support-connect-state span {
  max-width: 260px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
  line-height: 1.55;
}

.support-connect-state.error {
  color: rgba(255, 255, 255, 0.64);
}

.support-connect-state .primary-btn {
  min-height: 40px;
  margin-top: 8px;
  border-radius: 10px;
}

.support-intro,
.report-form,
.settings-form {
  display: grid;
  gap: 12px;
}

.support-intro p {
  margin: 0 0 4px;
  color: rgba(255, 255, 255, 0.68);
  line-height: 1.6;
}

.support-intro input,
.support-intro select,
.support-intro textarea,
.report-form input,
.report-form select,
.report-form textarea,
.settings-form input,
.settings-form select,
.settings-form textarea,
.support-composer textarea,
.support-admin-reply textarea,
.support-admin-note input {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  background: #0f1218;
  color: rgba(255, 255, 255, 0.92);
  padding: 10px 12px;
  outline: none;
  box-sizing: border-box;
}

.support-intro textarea,
.report-form textarea,
.settings-form textarea {
  min-height: 96px;
  resize: vertical;
}

.support-composer {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 8px;
  padding: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(16, 19, 26, 0.96);
}

.support-upload-preview {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.04);
}

.support-upload-preview img {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  object-fit: cover;
  border-radius: 10px;
}

.support-upload-preview span {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.68);
  font-size: 12px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-upload-preview button {
  width: 30px;
  height: 30px;
  flex: 0 0 30px;
  border: 0;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.09);
  color: rgba(255, 255, 255, 0.82);
  cursor: pointer;
}

.support-composer textarea {
  min-height: 42px;
  max-height: 120px;
  resize: vertical;
}

.support-message-list {
  display: grid;
  gap: 10px;
}

.support-message {
  max-width: 82%;
  display: grid;
  gap: 5px;
}

.support-message.mine {
  justify-self: end;
}

.support-message.staff {
  justify-self: start;
}

.support-message > span {
  color: rgba(255, 255, 255, 0.42);
  font-size: 11px;
}

.support-message > div {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.07);
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.55;
}

.support-message.mine > div {
  background: rgba(255, 111, 125, 0.92);
  color: #11131a;
}

.support-message p {
  margin: 0;
  white-space: pre-wrap;
}

.support-message img {
  display: block;
  width: min(220px, 100%);
  max-height: 260px;
  object-fit: cover;
  border-radius: 10px;
}

.report-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.62);
}

.report-modal {
  position: relative;
  width: min(480px, 100%);
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  background: #151922;
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.48);
}

.modal-close {
  position: absolute;
  right: 14px;
  top: 14px;
}

.report-modal h2 {
  margin: 4px 0 8px;
  color: rgba(255, 255, 255, 0.94);
}

.report-target,
.report-upload,
.report-description p,
.report-evidence p {
  color: rgba(255, 255, 255, 0.58);
}

.report-upload {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px dashed rgba(255, 255, 255, 0.18);
  border-radius: 12px;
}

.report-form-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.support-admin-layout {
  display: grid;
  grid-template-columns: minmax(320px, 0.92fr) minmax(0, 2fr);
  gap: 18px;
  align-items: stretch;
}

.support-admin-list-card,
.support-admin-chat-card,
.settings-card,
.admin-table-card {
  min-width: 0;
}

.support-admin-list-card,
.support-admin-chat-card {
  min-height: 620px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: #151922;
}

.support-tools {
  padding: 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.support-conversation-list {
  max-height: 520px;
  overflow-y: auto;
  padding: 8px;
}

.support-conversation-item {
  width: 100%;
  display: grid;
  gap: 6px;
  padding: 12px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.support-conversation-item:hover,
.support-conversation-item.active {
  background: rgba(255, 255, 255, 0.055);
}

.support-conversation-item.active {
  box-shadow: inset 3px 0 0 #ff6f7d;
}

.support-conversation-item span,
.support-admin-chat-head,
.support-admin-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.support-conversation-item strong,
.support-conversation-item p {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-conversation-item p,
.support-conversation-item small,
.support-conversation-item i,
.support-admin-chat-head p,
.support-admin-notes,
.report-log-list small {
  color: rgba(255, 255, 255, 0.52);
  font-size: 12px;
  font-style: normal;
}

.support-chat-empty {
  height: 100%;
  min-height: 420px;
  display: grid;
  place-content: center;
  gap: 8px;
  text-align: center;
}

.support-admin-chat {
  height: 100%;
  display: grid;
  grid-template-rows: auto minmax(260px, 1fr) auto auto auto;
  min-height: 620px;
}

.support-admin-chat-head {
  padding: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
}

.support-admin-chat-head h2 {
  margin: 0;
  font-size: 20px;
}

.support-admin-actions {
  flex-wrap: wrap;
  justify-content: flex-end;
}

.support-admin-messages {
  min-height: 0;
  overflow-y: auto;
  padding: 16px;
}

.support-admin-reply,
.support-admin-note {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 12px 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.support-admin-notes {
  max-height: 120px;
  overflow-y: auto;
  padding: 0 16px 14px;
}

.support-admin-notes p,
.report-log-list p {
  margin: 8px 0 0;
}

.admin-report-table td,
.admin-report-table th {
  vertical-align: middle;
}

.report-target-cell {
  min-width: 220px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.report-target-cell img,
.report-target-placeholder {
  width: 48px;
  height: 48px;
  flex: 0 0 auto;
  border-radius: 10px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.06);
}

.report-target-placeholder {
  display: inline-grid;
  place-items: center;
  color: #ff8a96;
  font-weight: 900;
}

.report-target-cell strong,
.report-target-cell small {
  display: block;
  overflow: hidden;
  max-width: 240px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.priority-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.78);
  font-size: 12px;
  font-weight: 800;
}

.priority-high,
.priority-urgent {
  background: rgba(255, 111, 125, 0.15);
  color: #ff8a96;
}

.report-status-pending,
.report-status-processing {
  background: rgba(245, 158, 11, 0.13);
  color: #fbbf24;
}

.report-status-resolved {
  background: rgba(34, 197, 94, 0.13);
  color: #4ade80;
}

.report-status-rejected {
  background: rgba(148, 163, 184, 0.16);
  color: rgba(255, 255, 255, 0.72);
}

.report-drawer-panel {
  max-width: 720px;
}

.report-drawer-head {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.report-drawer-head p,
.report-drawer-head h2 {
  margin: 0;
}

.report-drawer-head p {
  color: #ff8a96;
  font-size: 12px;
  font-weight: 900;
  text-transform: uppercase;
}

.report-preview-image {
  width: 100%;
  max-height: 280px;
  margin-bottom: 16px;
  border-radius: 12px;
  object-fit: cover;
}

.report-description,
.report-evidence,
.report-admin-controls,
.report-log-list {
  margin-top: 16px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.report-description h3,
.report-evidence h3,
.report-log-list h3 {
  margin: 0 0 10px;
  font-size: 16px;
}

.report-evidence > div {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(96px, 1fr));
  gap: 10px;
}

.report-evidence button {
  padding: 0;
  border: 0;
  border-radius: 10px;
  background: transparent;
  cursor: pointer;
}

.report-evidence img {
  display: block;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 10px;
  object-fit: cover;
}

.report-admin-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.report-admin-controls select {
  min-width: 140px;
}

.report-log-list {
  display: grid;
  gap: 10px;
}

.report-log-list > div {
  padding: 10px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.settings-form label {
  display: grid;
  gap: 8px;
}

.settings-form label span {
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
}

.settings-form {
  max-width: 760px;
}

@media (min-width: 1280px) {
  body[data-page="admin"] .admin-workspace {
    max-width: 1440px;
  }
}

@media (max-width: 1199px) {
  .support-admin-layout {
    grid-template-columns: 1fr;
  }

  .support-admin-list-card,
  .support-admin-chat,
  .support-admin-chat-card {
    min-height: auto;
  }
}

@media (max-width: 768px) {
  .support-fab {
    right: 12px;
    bottom: 14px;
  }

  .support-widget {
    left: max(12px, env(safe-area-inset-left));
    right: max(12px, env(safe-area-inset-right));
    bottom: 70px;
    width: auto;
    max-height: calc(100vh - 90px);
  }

  .support-composer,
  .support-admin-reply,
  .support-admin-note,
  .report-form-actions {
    grid-template-columns: 1fr;
  }

  .report-modal {
    padding: 18px;
  }

  .admin-title-actions {
    width: 100%;
    flex-wrap: wrap;
  }

  .support-admin-chat-head {
    align-items: flex-start;
    flex-direction: column;
  }

  .support-admin-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .support-admin-actions > * {
    width: 100%;
  }

  .report-admin-controls > *,
  .settings-form .primary-btn {
    width: 100%;
  }
}

/* XOO mobile overflow and profile polish */
*,
*::before,
*::after {
  box-sizing: border-box;
  min-width: 0;
}

html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  overscroll-behavior-x: none;
}

body {
  position: relative;
}

img,
picture,
video,
canvas,
svg,
iframe {
  max-width: 100%;
}

img,
picture,
video,
canvas {
  height: auto;
}

input,
select,
textarea,
button {
  max-width: 100%;
}

.site-header {
  padding-left: max(18px, env(safe-area-inset-left));
  padding-right: max(18px, env(safe-area-inset-right));
}

@media (min-width: 1280px) {
  .site-header {
    padding-left: calc((100% - 1250px) / 2);
    padding-right: calc((100% - 1250px) / 2);
  }
}

.page-shell,
.home-shell,
.detail-shell,
.profile-shell,
.auth-shell,
.admin-shell,
.search-panel,
.feed,
.post-card,
.card-media,
.card-actions,
.detail-layout,
.detail-carousel,
.info-panel,
.comments,
.recommend-section,
.auth-card,
.profile-modern-card,
.profile-menu-card,
.support-widget,
.report-modal,
.location-consent-card,
.admin-panel,
.admin-workspace,
.admin-table-card,
.admin-table-wrap,
.admin-session-table,
.support-admin-layout,
.support-admin-list-card,
.support-admin-chat-card {
  max-width: 100%;
}

.main-nav a,
.logo,
.card-location,
.card-distance,
.card-overlay h3,
.compact-card span,
.admin-data-table td,
.admin-data-table th,
.support-conversation-item strong,
.support-conversation-item p,
.session-page-cell,
.report-target-cell strong,
.report-target-cell small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-message,
.support-message > div,
.support-message p,
.support-intro textarea,
.report-form textarea,
.profile-info-body,
.profile-mini-list,
.comment-item p {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.support-fab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.support-widget {
  width: min(390px, calc(100% - 36px));
}

.report-modal-backdrop,
.location-consent,
.profile-drawer {
  padding-left: max(12px, env(safe-area-inset-left));
  padding-right: max(12px, env(safe-area-inset-right));
}

.auth-form,
.password-field,
.captcha-row,
.auth-agreement,
.profile-drawer-form,
.profile-drawer-form label {
  min-width: 0;
}

.password-field {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
}

.password-toggle {
  min-height: 40px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--muted);
}

.password-strength {
  min-height: 24px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.password-strength[data-level="weak"] {
  color: #ff8a96;
}

.password-strength[data-level="medium"] {
  color: #fbbf24;
}

.password-strength[data-level="strong"] {
  color: #4ade80;
}

.captcha-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 132px;
  gap: 10px;
  align-items: stretch;
}

.captcha-image {
  min-height: 48px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #0f1218;
}

.captcha-image img {
  display: block;
  width: 100%;
  height: 48px;
  object-fit: contain;
}

.captcha-image img.loading {
  opacity: 0.45;
}

.auth-agreement {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

.auth-agreement input {
  width: 16px;
  height: 16px;
  flex: 0 0 auto;
  margin-top: 2px;
}

.profile-shell {
  width: min(520px, calc(100% - 28px));
  gap: 14px;
}

.profile-modern-card,
.profile-menu-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(31, 32, 37, 0.96), rgba(22, 23, 27, 0.94));
  box-shadow: var(--shadow-soft);
}

.profile-modern-card {
  display: grid;
  gap: 10px;
  justify-items: center;
  padding: 24px 18px;
  text-align: center;
}

.profile-main-avatar {
  width: 96px;
  height: 96px;
}

.profile-modern-card .avatar,
.profile-avatar-edit .avatar {
  border-radius: 50%;
}

.profile-modern-card h1,
.profile-modern-card p,
.profile-modern-card small {
  max-width: 100%;
  margin: 0;
}

.profile-modern-card h1 {
  font-size: 26px;
}

.profile-modern-card p {
  color: var(--muted);
}

.profile-modern-card small {
  color: rgba(255, 255, 255, 0.62);
  line-height: 1.6;
}

.profile-modern-card .primary-btn {
  width: min(220px, 100%);
  margin-top: 4px;
}

.profile-menu-card {
  display: grid;
  overflow: hidden;
}

.profile-menu-item {
  width: 100%;
  min-height: 58px;
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: transparent;
  color: var(--text);
  text-align: left;
}

.profile-menu-item:last-child {
  border-bottom: 0;
}

.profile-menu-item:hover {
  background: rgba(255, 111, 125, 0.08);
}

.profile-menu-item > span {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  background: rgba(255, 255, 255, 0.06);
  color: #ff8a96;
  font-weight: 900;
}

.profile-menu-item strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.profile-menu-item em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  white-space: nowrap;
}

.profile-menu-item.danger {
  color: #ff8a96;
}

.profile-drawer {
  position: fixed;
  inset: 0;
  z-index: 95;
  display: grid;
  justify-items: end;
  align-items: stretch;
  background: rgba(0, 0, 0, 0.54);
}

.profile-drawer.hidden {
  display: none !important;
}

.profile-drawer-panel {
  width: min(420px, 100%);
  max-width: 100%;
  min-height: 100%;
  overflow-y: auto;
  padding: 18px;
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  background: #151922;
  box-shadow: -18px 0 54px rgba(0, 0, 0, 0.42);
}

.profile-drawer-panel header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.profile-drawer-panel h2 {
  margin: 0;
  font-size: 22px;
}

.profile-drawer-panel header button {
  width: 38px;
  height: 38px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.055);
  color: var(--text);
}

.profile-drawer-form {
  box-shadow: none;
}

.profile-drawer-form label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
}

.profile-avatar-edit {
  justify-items: center;
  text-align: center;
  cursor: pointer;
}

.profile-avatar-preview,
.profile-avatar-preview-image {
  width: 92px;
  height: 92px;
}

.profile-avatar-edit em {
  color: #ff8a96;
  font-size: 13px;
  font-style: normal;
}

.profile-info-body p {
  margin: 0;
  line-height: 1.7;
}

.profile-login-copy {
  max-width: 280px !important;
  white-space: normal !important;
  overflow: visible !important;
  overflow-wrap: anywhere !important;
  line-height: 1.7 !important;
}

.profile-mini-list {
  display: grid;
  gap: 10px;
}

.profile-mini-list > div,
.profile-mini-loading {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.045);
}

.profile-mini-list strong,
.profile-mini-list span {
  display: block;
}

.profile-mini-list span {
  color: var(--muted);
  font-size: 12px;
}

@media (min-width: 768px) {
  .profile-auth-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(150px, 1fr));
    justify-content: center;
    width: min(330px, 100%);
  }

  .profile-auth-actions .primary-btn,
  .profile-auth-actions .plain-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
  }
}

@media (max-width: 767px) {
  .site-header {
    min-height: 60px;
    grid-template-columns: 68px minmax(0, 1fr) 38px;
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .site-header::after {
    width: 34px;
    height: 34px;
    border-radius: 12px;
  }

  .page-shell,
  .home-shell,
  .profile-shell,
  .auth-shell,
  .detail-shell {
    width: 100%;
    max-width: 100%;
    margin: 12px 0 42px;
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  .auth-shell {
    min-height: calc(100dvh - 84px);
    place-items: start center;
  }

  .auth-card,
  .logged-out-card {
    width: 100%;
    max-width: 420px;
  }

  .search-panel {
    width: 100%;
    margin: 12px 0 18px;
    padding: 12px;
  }

  .search-box {
    grid-template-columns: 35fr 65fr;
  }

  .search-box input {
    grid-column: 1 / -1;
  }

  .search-box #clearSearch {
    grid-column: 1;
  }

  .search-box button[type="submit"] {
    grid-column: 2;
  }

  .feed-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
  }

  .feed-tab {
    width: 100%;
    min-width: 0;
    padding: 0 4px;
    white-space: nowrap;
  }

  .filter-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto;
    gap: 8px;
  }

  .filter-row select,
  .mobile-filter-toggle {
    height: 44px;
    min-height: 44px;
    width: 100%;
  }

  .mobile-filter-toggle {
    padding-inline: 10px;
    white-space: nowrap;
  }

  .advanced-filter {
    display: none;
    grid-column: 1 / -1;
  }

  body.filters-expanded .advanced-filter {
    display: block;
  }

  .feed {
    grid-template-columns: 1fr !important;
    gap: 14px;
    width: 100%;
  }

  .post-card {
    width: 100%;
  }

  .card-media {
    aspect-ratio: 4 / 3;
  }

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

  .action-btn {
    min-height: 40px;
    padding: 0 4px;
    gap: 4px;
    white-space: nowrap;
  }

  .detail-carousel {
    min-height: 260px;
  }

  .detail-carousel img {
    max-height: 360px;
  }

  .info-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .info-value,
  .service-tags {
    justify-content: flex-start;
    text-align: left;
  }

  .comment-form,
  .captcha-row,
  .support-composer,
  .support-admin-reply,
  .support-admin-note {
    grid-template-columns: 1fr;
  }

  .profile-modern-card {
    width: 100%;
    padding: 22px 16px;
  }

  .profile-menu-card {
    width: 100%;
  }

  .profile-menu-item {
    grid-template-columns: 40px minmax(0, 1fr) minmax(72px, auto);
    padding: 0 12px;
  }

  .profile-menu-item em {
    max-width: 116px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .profile-auth-actions {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .profile-auth-actions .primary-btn,
  .profile-auth-actions .plain-btn {
    width: 100%;
    min-height: 48px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
  }

  .profile-auth-actions .plain-btn {
    border-color: rgba(255, 111, 125, 0.48);
    background: transparent;
    color: #fff;
  }

  .support-fab {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
    width: 48px;
    min-width: 48px;
    height: 48px;
    padding: 0;
    overflow: hidden;
    color: transparent;
  }

  .support-fab::before {
    content: "客服";
    color: #10131a;
    font-size: 12px;
  }

  .support-widget {
    left: max(12px, env(safe-area-inset-left));
    right: max(12px, env(safe-area-inset-right));
    bottom: calc(max(68px, env(safe-area-inset-bottom)) + 8px);
    width: auto;
    max-width: none;
    max-height: calc(100dvh - 92px);
    border-radius: 16px;
  }

  .support-message {
    max-width: 92%;
  }

  .report-modal {
    width: 100%;
    max-width: 480px;
    max-height: calc(100dvh - 32px);
  }

  body[data-page="admin"] .admin-shell {
    width: 100%;
    max-width: 100%;
    padding-left: 0;
    padding-right: 0;
  }

  body[data-page="admin"] .admin-sidebar {
    width: min(320px, calc(100% - 48px));
    max-width: calc(100% - 48px);
  }

  body[data-page="admin"] .admin-workspace {
    max-width: 100%;
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  body[data-page="home"] .search-box > *,
  body[data-page="home"] .filter-row > *,
  body[data-page="profile"] .profile-auth-actions > *,
  body[data-page="profile"] .logged-out-card > *,
  body[data-page="profile"] .profile-modern-card > *,
  body[data-page="profile"] .profile-menu-card > * {
    min-width: 0;
    max-width: 100%;
  }

  body[data-page="home"] .search-box .primary-btn,
  body[data-page="home"] .search-box .plain-btn {
    padding-inline: 8px;
  }

  body[data-page="profile"] .profile-shell {
    display: grid;
    justify-items: center;
    overflow: hidden;
  }

  body[data-page="profile"] .logged-out-card,
  body[data-page="profile"] .profile-modern-card,
  body[data-page="profile"] .profile-menu-card,
  .location-consent-card {
    width: min(420px, calc(100% - 72px)) !important;
    max-width: calc(100% - 72px) !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    justify-self: center;
  }

  body[data-page="profile"] .logged-out-card p,
  body[data-page="profile"] .profile-modern-card p,
  body[data-page="profile"] .profile-modern-card small,
  .location-consent-card p {
    width: 100%;
    overflow: visible;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  body[data-page="profile"] .profile-auth-actions .primary-btn,
  body[data-page="profile"] .profile-auth-actions .plain-btn {
    padding-inline: 12px;
  }
}

@media (max-width: 430px) {
  .profile-menu-item {
    grid-template-columns: 36px minmax(0, 1fr) minmax(58px, auto);
  }

  .profile-menu-item em {
    max-width: 92px;
  }
}

@media (max-width: 360px) {
  .main-nav a {
    min-width: 50px;
    padding-inline: 6px;
  }

  .profile-menu-item em {
    display: none;
  }
}

/* XOO support desk redesign and dark form polish */
body[data-page="admin"] .admin-workspace {
  width: 100%;
  max-width: min(1600px, 100%);
  margin: 0 auto;
}

body[data-page="admin"] .admin-page-title {
  align-items: center;
}

.support-admin-layout {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(320px, 360px) minmax(0, 1fr);
  gap: 20px;
  align-items: stretch;
}

.support-admin-list-card,
.support-admin-chat-card {
  min-width: 0;
  min-height: calc(100vh - 290px);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: #151922;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.support-tools {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  padding: 14px;
}

.support-tools input,
.support-tools select,
.report-admin-controls select,
.report-admin-controls input {
  min-height: 42px;
  border-radius: 10px;
  background: #17181d !important;
  color: rgba(255, 255, 255, 0.92) !important;
}

.support-conversation-list {
  max-height: calc(100vh - 430px);
  min-height: 360px;
  padding: 8px;
}

.support-conversation-item {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 10px;
  align-items: start;
  padding: 12px;
  border-radius: 12px;
  border: 1px solid transparent;
}

.support-conversation-item:hover {
  background: rgba(255, 255, 255, 0.045);
}

.support-conversation-item.active {
  border-color: rgba(255, 111, 125, 0.2);
  background: rgba(255, 111, 125, 0.08);
  box-shadow: inset 3px 0 0 #ff6f7d;
}

.support-list-avatar,
.support-customer-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
}

.support-list-main,
.support-list-top,
.support-list-meta {
  min-width: 0;
  display: flex;
  gap: 8px;
}

.support-list-main {
  flex-direction: column;
  gap: 4px;
}

.support-list-top,
.support-list-meta {
  align-items: center;
  justify-content: space-between;
}

.support-list-top strong,
.support-list-main p,
.support-list-main small,
.support-list-meta i {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-list-top strong {
  color: rgba(255, 255, 255, 0.92);
  font-size: 14px;
}

.support-list-main p {
  margin: 0;
  color: rgba(255, 255, 255, 0.7);
  font-size: 13px;
}

.support-list-main small,
.support-list-meta i {
  color: rgba(255, 255, 255, 0.48);
  font-size: 12px;
  font-style: normal;
}

.support-list-meta b {
  min-width: 22px;
  height: 22px;
  display: inline-grid;
  place-items: center;
  border-radius: 999px;
  background: #ff6f7d;
  color: #121318;
  font-size: 12px;
}

.support-status-unread,
.support-status-waiting,
.support-status-pending {
  background: rgba(246, 176, 77, 0.15);
  color: #f6b04d;
}

.support-status-processing,
.support-status-open {
  background: rgba(255, 111, 125, 0.15);
  color: #ff8b98;
}

.support-status-completed {
  background: rgba(54, 217, 141, 0.14);
  color: #36d98d;
}

.support-status-closed,
.support-status-spam,
.support-status-blocked {
  background: rgba(148, 163, 184, 0.14);
  color: rgba(255, 255, 255, 0.64);
}

.support-admin-chat {
  grid-template-rows: auto auto minmax(320px, 1fr) auto auto;
  min-height: calc(100vh - 290px);
}

.support-admin-chat-head {
  gap: 16px;
  padding: 16px 18px;
}

.support-admin-chat-head > div:first-child {
  min-width: 220px;
}

.support-admin-chat-head h2 {
  font-size: 21px;
}

.support-admin-actions {
  gap: 8px;
}

.support-admin-actions .plain-btn,
.support-admin-actions select {
  min-height: 38px;
  border-radius: 9px;
  padding-inline: 12px;
}

.support-customer-panel {
  display: grid;
  grid-template-columns: 48px minmax(180px, 0.8fr) minmax(0, 2fr);
  gap: 12px;
  align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.025);
}

.support-customer-panel strong,
.support-customer-panel span {
  display: block;
}

.support-customer-panel span,
.support-customer-panel dt {
  color: rgba(255, 255, 255, 0.5);
  font-size: 12px;
}

.support-customer-panel dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 0;
}

.support-customer-panel div,
.support-customer-panel dd {
  min-width: 0;
}

.support-customer-panel dd {
  margin: 3px 0 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.86);
  font-size: 13px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-admin-messages {
  padding: 18px;
  background:
    linear-gradient(rgba(12, 14, 19, 0.74), rgba(12, 14, 19, 0.74)),
    radial-gradient(circle at 20% 0, rgba(255, 111, 125, 0.07), transparent 30%);
}

.support-message {
  max-width: min(74%, 680px);
}

.support-message.mine {
  justify-self: end;
  text-align: right;
}

.support-message.staff {
  justify-self: start;
}

.support-message.system {
  justify-self: center;
  max-width: min(90%, 520px);
  text-align: center;
}

.support-message.system > div {
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.055);
  color: rgba(255, 255, 255, 0.62);
}

.support-message > div {
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.07);
  overflow-wrap: anywhere;
}

.support-message.mine > div {
  border-color: rgba(255, 111, 125, 0.28);
  background: linear-gradient(135deg, #ff7585, #e83f69);
  color: #11131a;
}

.support-image-preview {
  cursor: zoom-in;
}

.support-admin-reply,
.support-admin-note {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 14px 18px;
}

.support-admin-reply textarea,
.support-admin-note input {
  min-height: 44px;
  border-radius: 12px;
  background: #17181d !important;
}

.support-admin-notes {
  padding: 0 18px 16px;
}

.support-delete-dialog {
  max-width: min(460px, calc(100vw - 24px));
}

.support-delete-reason {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.support-delete-reason span {
  color: rgba(255, 255, 255, 0.62);
  font-size: 13px;
}

.danger-confirm,
.danger-action {
  border-color: rgba(255, 91, 111, 0.4) !important;
}

@media (min-width: 1440px) {
  .support-admin-layout {
    grid-template-columns: 380px minmax(0, 1fr);
  }
}

@media (max-width: 1199px) {
  .support-admin-layout {
    grid-template-columns: 1fr;
  }

  .support-conversation-list {
    max-height: 420px;
  }
}

@media (max-width: 768px) {
  .support-admin-layout {
    gap: 14px;
  }

  .support-admin-list-card,
  .support-admin-chat-card,
  .support-admin-chat {
    min-height: auto;
  }

  .support-customer-panel {
    grid-template-columns: 42px minmax(0, 1fr);
  }

  .support-customer-panel dl {
    grid-column: 1 / -1;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .support-admin-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .support-admin-actions select,
  .support-admin-actions .plain-btn {
    width: 100%;
  }

  .support-message {
    max-width: 92%;
  }
}

@media (max-width: 430px) {
  .support-conversation-item {
    grid-template-columns: 38px minmax(0, 1fr);
    padding: 10px;
  }

  .support-list-avatar,
  .support-customer-avatar {
    width: 38px;
    height: 38px;
  }

  .support-customer-panel dl,
  .support-admin-actions,
  .support-admin-reply,
  .support-admin-note {
    grid-template-columns: 1fr;
  }
}

/* XOO 20260722 auth, video, mobile and admin scale polish */
html,
body {
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

img,
video,
canvas,
svg,
iframe {
  max-width: 100%;
}

input,
select,
textarea,
button,
.post-card,
.card-media,
.card-overlay,
.card-actions,
.detail-carousel,
.detail-video-panel,
.admin-card,
.admin-table-card,
.admin-workspace,
.support-widget,
.support-admin-layout {
  min-width: 0;
}

.primary-btn.is-disabled {
  opacity: 0.54;
  filter: saturate(0.72);
}

.auth-agreement {
  align-items: center;
  cursor: pointer;
  user-select: none;
}

.auth-agreement input {
  appearance: none;
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 6px;
  background: #11131a;
  cursor: pointer;
}

.auth-agreement input:checked {
  border-color: rgba(255, 111, 125, 0.9);
  background: #ff6f7d;
}

.auth-agreement input:checked::after {
  content: "";
  width: 8px;
  height: 5px;
  transform: rotate(-45deg) translateY(-1px);
  border-left: 2px solid #11131a;
  border-bottom: 2px solid #11131a;
}

.password-strength {
  letter-spacing: 0;
}

.video-preview-card video,
.detail-video-panel video {
  width: 100%;
  max-height: 70dvh;
  border-radius: 14px;
  background: #05060a;
  object-fit: contain;
}

.detail-video-panel {
  overflow: hidden;
  border-radius: 14px;
  background: #05060a;
}

body[data-page="admin"] .admin-shell {
  width: 100%;
  max-width: none;
  margin: 0;
}

body[data-page="admin"] .admin-panel {
  grid-template-columns: 220px minmax(0, 1fr);
}

body[data-page="admin"] .admin-workspace {
  width: 100%;
  max-width: none;
  min-width: 0;
  padding-left: clamp(20px, 2vw, 32px);
  padding-right: clamp(20px, 2vw, 32px);
}

body[data-page="admin"] .admin-table-card,
body[data-page="admin"] .admin-table-wrap {
  width: 100%;
  max-width: 100%;
  min-width: 0;
}

body[data-page="admin"] .admin-table-wrap {
  overflow-x: auto;
}

body[data-page="admin"] .admin-metric-grid {
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
}

@media (min-width: 1440px) {
  body[data-page="admin"] .admin-workspace {
    padding-left: 32px;
    padding-right: 32px;
  }
}

@media (max-width: 767px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
    overscroll-behavior-x: none;
  }

  .site-header {
    min-height: calc(58px + env(safe-area-inset-top));
    grid-template-columns: 72px minmax(0, 1fr) 38px;
    padding: env(safe-area-inset-top) max(12px, env(safe-area-inset-right)) 0 max(12px, env(safe-area-inset-left));
  }

  .site-header::after {
    width: 36px;
    height: 36px;
    border-radius: 13px;
  }

  .logo {
    min-width: 0;
    padding: 4px 8px;
    font-size: 21px;
  }

  .main-nav {
    min-width: 0;
    justify-self: center;
    gap: 6px;
  }

  .main-nav a,
  .main-nav span {
    min-width: 50px;
    min-height: 36px;
    padding: 0 9px;
    border-radius: 11px;
    white-space: nowrap;
  }

  .page-shell,
  .home-shell,
  .profile-shell,
  .auth-shell,
  .detail-shell {
    width: 100%;
    max-width: 100%;
    margin: 12px 0 36px;
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  body[data-page="home"] .search-panel {
    gap: 10px;
    margin: 10px 0 14px;
    padding: 12px;
    border-radius: 16px;
  }

  body[data-page="home"] .search-box {
    display: grid;
    grid-template-columns: 35fr 65fr;
    gap: 8px;
    align-items: center;
  }

  body[data-page="home"] .search-box input {
    grid-column: 1 / -1;
    width: 100%;
  }

  body[data-page="home"] .search-box #clearSearch,
  body[data-page="home"] .search-box button[type="submit"] {
    width: 100%;
    min-height: 42px;
  }

  body[data-page="home"] .search-box #clearSearch {
    grid-column: 1;
  }

  body[data-page="home"] .search-box button[type="submit"] {
    grid-column: 2;
  }

  body[data-page="home"] .feed-tabs {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 7px;
  }

  body[data-page="home"] .feed-tab {
    min-height: 36px;
    padding: 0 6px;
    font-size: 12px;
  }

  body[data-page="home"] .filter-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  body[data-page="home"] .filter-row select,
  body[data-page="home"] .mobile-filter-toggle {
    width: 100%;
    min-height: 40px;
    border-radius: 12px;
  }

  body[data-page="home"] .mobile-filter-toggle {
    display: inline-flex;
    grid-column: 1 / -1;
    align-items: center;
    justify-content: center;
  }

  body[data-page="home"] .advanced-filter {
    display: none;
  }

  body.filters-expanded[data-page="home"] .advanced-filter {
    display: block;
  }

  body[data-page="home"] .feed {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body[data-page="home"] .post-card {
    width: 100%;
    border-radius: 12px;
  }

  body[data-page="home"] .card-media {
    aspect-ratio: 3 / 4;
    border-radius: 12px 12px 0 0;
  }

  body[data-page="home"] .image-placeholder {
    min-height: 160px;
    font-size: 22px;
  }

  body[data-page="home"] .card-overlay {
    bottom: 36px;
    gap: 3px;
    padding: 42px 8px 8px;
  }

  body[data-page="home"] .card-overlay h3 {
    display: -webkit-box;
    overflow: hidden;
    font-size: 13px;
    line-height: 1.25;
    white-space: normal;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  body[data-page="home"] .card-location,
  body[data-page="home"] .card-distance,
  body[data-page="home"] .card-meta {
    font-size: 11px;
  }

  body[data-page="home"] .card-actions {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 3px;
    padding: 4px;
  }

  body[data-page="home"] .action-btn {
    min-height: 30px;
    padding: 0 2px;
    gap: 2px;
    border-radius: 8px;
    font-size: 11px;
    white-space: nowrap;
  }

  body[data-page="home"] .action-btn span:last-child {
    max-width: 42px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .detail-carousel {
    min-height: 0;
    max-height: 65dvh;
    border-radius: 14px;
  }

  .detail-carousel img {
    width: 100%;
    max-height: 65dvh;
    object-fit: contain;
  }

  .detail-video-panel video {
    max-height: 62dvh;
  }

  .comment-form textarea {
    min-height: 104px;
  }

  .support-fab {
    right: max(12px, env(safe-area-inset-right));
    bottom: max(14px, env(safe-area-inset-bottom));
    width: 52px;
    height: 52px;
    min-width: 52px;
    padding: 0;
    overflow: hidden;
    border-radius: 50%;
    font-size: 0;
  }

  .support-fab::before {
    margin: 0;
    font-size: 20px;
  }

  body[data-page="admin"] .admin-shell {
    width: 100%;
    max-width: 100%;
    padding-top: 64px;
  }

  body[data-page="admin"] .admin-panel {
    display: block;
  }

  body[data-page="admin"] .admin-sidebar {
    width: min(300px, calc(100% - 48px));
    max-width: calc(100% - 48px);
  }

  body[data-page="admin"] .admin-workspace {
    padding-left: max(12px, env(safe-area-inset-left));
    padding-right: max(12px, env(safe-area-inset-right));
  }

  body[data-page="admin"] .admin-metric-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 360px) {
  body[data-page="home"] .feed {
    gap: 8px !important;
  }

  body[data-page="home"] .card-overlay h3 {
    font-size: 12px;
  }

  body[data-page="home"] .action-btn {
    font-size: 10px;
  }
}

.admin-address-field .admin-field-heading {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.internal-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-height: 22px;
  padding: 0 8px;
  border: 1px solid rgba(255, 111, 125, 0.28);
  border-radius: 999px;
  background: rgba(255, 111, 125, 0.12);
  color: var(--brand);
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.internal-badge::before {
  content: "🔒";
  font-size: 12px;
}

.admin-service-field,
.admin-address-field {
  grid-column: 1 / -1;
}

.admin-geo-action {
  align-self: end;
  width: 100%;
  min-height: 40px;
}

.register-agreement {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  width: 100%;
  min-width: 0;
  color: var(--muted);
  line-height: 1.5;
  user-select: none;
  pointer-events: auto;
}

.register-agreement__checkbox {
  appearance: auto !important;
  -webkit-appearance: checkbox !important;
  position: relative;
  z-index: 3;
  flex: 0 0 auto;
  width: 20px;
  height: 20px;
  margin: 2px 0 0;
  accent-color: var(--brand);
  cursor: pointer;
  opacity: 1;
  pointer-events: auto;
}

.register-agreement__label {
  flex: 1 1 auto;
  min-width: 0;
  cursor: pointer;
  pointer-events: auto;
}

.register-agreement-row {
  display: flex !important;
  align-items: flex-start !important;
  gap: 10px !important;
  width: 100% !important;
  min-width: 0 !important;
  max-width: 100% !important;
  min-height: 24px !important;
  margin: 12px 0 16px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
  writing-mode: horizontal-tb !important;
}

.register-agreement-row #registerAgreement {
  appearance: auto !important;
  -webkit-appearance: checkbox !important;
  display: inline-block !important;
  width: 18px !important;
  height: 18px !important;
  min-width: 18px !important;
  max-width: 18px !important;
  min-height: 18px !important;
  max-height: 18px !important;
  flex: 0 0 18px !important;
  margin: 2px 0 0 !important;
  padding: 0 !important;
  border: initial !important;
  border-radius: 3px !important;
  background: initial !important;
  box-shadow: none !important;
  cursor: pointer !important;
  pointer-events: auto !important;
  accent-color: #ec5f78;
}

.register-agreement-row #registerAgreement:focus,
.register-agreement-row #registerAgreement:focus-visible {
  outline: 2px solid rgba(236, 95, 120, 0.38) !important;
  outline-offset: 2px !important;
  box-shadow: none !important;
}

.register-agreement-row label {
  display: block !important;
  flex: 1 1 auto !important;
  min-width: 0 !important;
  width: auto !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #aeb2bd !important;
  font-size: 13px !important;
  line-height: 1.5 !important;
  text-align: left !important;
  white-space: normal !important;
  word-break: normal !important;
  overflow-wrap: break-word !important;
  writing-mode: horizontal-tb !important;
  cursor: pointer !important;
  pointer-events: auto !important;
}

@media (max-width: 768px) {
  .admin-geo-action {
    grid-column: 1 / -1;
  }
}

/* Keep the floating support entry away from post detail content and iPhone safe areas. */
.support-fab {
  right: max(18px, env(safe-area-inset-right, 0px));
  bottom: calc(18px + env(safe-area-inset-bottom, 0px));
}

.support-widget {
  max-width: calc(100vw - 24px);
  max-height: calc(100vh - 24px - env(safe-area-inset-bottom, 0px));
}

@media (max-width: 768px) {
  .support-fab {
    right: max(12px, env(safe-area-inset-right, 0px));
    bottom: calc(14px + env(safe-area-inset-bottom, 0px));
  }
}

/* 20260727 frontend support widget final alignment. */
body:not([data-page="admin"]) .support-fab {
  right: max(18px, env(safe-area-inset-right, 0px));
  bottom: calc(18px + env(safe-area-inset-bottom, 0px));
  min-width: 118px;
  width: auto;
  min-height: 48px;
  height: 48px;
  padding: 0 18px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #ff7184, #ef426a);
  color: #fff;
  font-size: 14px;
  font-weight: 900;
  box-shadow: 0 12px 28px rgba(239, 66, 106, 0.3);
}

body:not([data-page="admin"]) .support-widget {
  max-width: min(390px, calc(100vw - 24px));
  max-height: calc(100vh - 24px - env(safe-area-inset-bottom, 0px));
  border-color: rgba(255, 255, 255, 0.1);
  background: #11141b;
}

body:not([data-page="admin"]) .support-widget textarea,
body:not([data-page="admin"]) .support-widget input {
  background: #171b23;
  color: rgba(255, 255, 255, 0.94);
}

@media (max-width: 767px) {
  body:not([data-page="admin"]) .support-fab {
    right: max(14px, env(safe-area-inset-right, 0px));
    bottom: calc(14px + env(safe-area-inset-bottom, 0px));
    min-width: 54px;
    width: 54px;
    height: 54px;
    padding: 0;
    font-size: 0;
  }

  body:not([data-page="admin"]) .support-fab::before {
    content: "客服";
    font-size: 13px;
    font-weight: 900;
  }
}
