:root {
  --brand: #df3f25;
  --brand-light: rgba(223,63,37,0.08);
  --ink: #1a1d24;
  --muted: #8b93a3;
  --line: #e8eaed;
  --page: #f5f6f8;
  --surface: #ffffff;
  --text: var(--ink);
  --panel: var(--surface);
  --accent: var(--brand);
  --admin-table-head: #f5f6f8;
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 12px;
  --space-lg: 16px;
  --space-xl: 24px;
  --space-2xl: 32px;
  --text-xs: 11px;
  --text-sm: 12px;
  --text-md: 14px;
  --text-lg: 16px;
  --text-xl: 18px;
  --text-2xl: 22px;
  --font-normal: 400;
  --font-medium: 500;
  --font-semibold: 600;
  --line-height: 1.5;
  --line-height-tight: 1.25;
  --icon-sm: 16px;
  --icon-md: 20px;
  --icon-lg: 24px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 999px;
  --topbar-h: 56px;
  --bottombar-h: 64px;
  --page-x: 16px;
  --page-top: calc(var(--topbar-h) + env(safe-area-inset-top, 0px) + var(--space-sm));
  --page-bottom: calc(var(--bottombar-h) + env(safe-area-inset-bottom, 0px) + var(--space-sm));
  --page-bottom-compact: calc(var(--space-xl) + env(safe-area-inset-bottom, 0px));
  --tap-target: 44px;
  --tap-target-lg: 56px;
  --feed-title-line: 24px;
  --detail-title-line: 28px;
  --ratio-square: 1 / 1;
  --ratio-wide: 16 / 9;
  --ratio-xhs-card: var(--ratio-square);
  --ratio-xhs-detail: var(--ratio-square);
  --gallery-feed-gap: calc(var(--space-md) / 2);
  --gallery-feed-x: calc(var(--page-x) / 2);
  --ratio-news-carousel: var(--ratio-wide);
  --ratio-local-ad: 16 / 9;
  --ratio-job-card-media: var(--ratio-square);
  --local-news-card-width: 70%;
  --job-cover-width: 22%;
  --local-ad-thumb-width: 96px;
  --local-ad-demo-min-height: 177px;
  --admin-logo-width: 132px;
  --admin-logo-height: 42px;
  --admin-menu-width: min(50vw, 240px);
  --admin-menu-scrim: rgba(26, 29, 36, 0.36);
  --admin-menu-shadow: rgba(26, 29, 36, 0.18);
  --admin-menu-line-h: 2px;
  --admin-shell-title-gap: calc(var(--space-xs) / 2);
  --admin-shell-h: var(--topbar-h);
  --job-cover-offset: 0;
  --z-popover: 60;
  --contact-row-compact-h: var(--space-2xl);
  --brand-red: var(--brand);
  --brand-blue: #4aa3df;
  --brand-yellow: #f5c542;
  --brand-green: #a6c64f;
  --brand-purple: #bd247d;
  --soft-red: var(--brand-light);
  --category-chip-bg: #eef1f5;
  --category-chip-fg: #4d5664;
  --image-placeholder: #eef1f5;
  --radius: var(--radius-md);
}

* {
  box-sizing: border-box;
}

html,
body {
  overflow-x: hidden;
}

html.search-no-scroll,
body.search-no-scroll {
  height: 100vh;
  overflow: hidden;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: var(--page);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
  letter-spacing: 0;
}

button,
input,
select,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.app-shell {
  width: 100%;
  min-height: 100vh;
  display: flex;
  justify-content: center;
}

.app {
  width: min(100%, 480px);
  min-height: 100vh;
  background: var(--surface);
  position: relative;
  padding-top: 43px;
  padding-bottom: calc(72px + env(safe-area-inset-bottom));
  box-shadow: none;
  overflow-x: hidden;
}

.app.no-topbar {
  padding-top: 0;
}

.app.search-no-scroll {
  height: 100vh;
  min-height: 100vh;
  overflow: hidden;
}

.desktop-sidebar,
.desktop-right-rail {
  display: none;
}

.topbar {
  position: fixed;
  top: 0;
  left: 50%;
  z-index: calc(var(--z-popover) + 7);
  width: min(100%, 480px);
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  padding: 5px 10px;
  background: rgba(255, 255, 255, 0.82);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  transition: transform 0.24s ease, opacity 0.24s ease;
}

.topbar.topbar-hidden {
  transform: translate(-50%, -110%);
  opacity: 0;
  pointer-events: none;
}

.top-region-button {
  flex: 0 0 86px;
  width: 86px;
  max-width: 96px;
  min-width: 0;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 7px;
  background: #fff;
  color: var(--ink);
  font-size: 13px;
  font-weight: 800;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand {
  min-width: 0;
  min-height: 0;
  justify-self: start;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  width: auto;
  max-width: 150px;
  gap: 6px;
  padding: 0;
  overflow: hidden;
}

.topbar-actions {
  justify-self: end;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.brand picture {
  display: flex;
  flex: 0 0 auto;
}

.brand img {
  flex: 0 0 auto;
  width: 84px;
  height: auto;
  max-height: 27px;
  object-fit: contain;
}

.brand-name {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  color: var(--ink);
  font-weight: 800;
  font-size: 17px;
  line-height: 1.1;
}

.brand-subtitle {
  color: var(--muted);
  display: block;
  font-size: 12.5px;
  margin: 0 0 1px;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  max-width: 100%;
  text-align: center;
  text-overflow: ellipsis;
}

.brand.quiet-button {
  min-height: 0;
}

.admin-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: var(--admin-logo-height);
  margin-top: 0;
  margin-bottom: var(--space-md);
}

.admin-logo picture {
  display: flex;
  align-items: center;
  justify-content: center;
}

.admin-logo img {
  width: min(var(--admin-logo-width), calc(100vw - var(--page-x) * 2));
  max-height: var(--admin-logo-height);
  height: auto;
  object-fit: contain;
}

.admin-main {
  position: relative;
}

.admin-content {
  min-width: 0;
}

.crawler-source-label,
.detail-source-footer {
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height);
}

.detail-source-footer {
  border-top: 1px solid var(--line);
  margin-top: var(--space-lg);
  padding-top: var(--space-md);
}

.detail-source-footer a {
  color: var(--ink);
  text-decoration: none;
}

.crawler-source-form,
.crawler-source-list,
.crawler-review-list,
.crawler-run-list,
.admin-keyword-list {
  display: grid;
  gap: var(--space-md);
}

.crawler-source-row,
.crawler-review-row,
.crawler-run-row {
  border-bottom: 1px solid var(--line);
  display: flex;
  gap: var(--space-md);
  justify-content: space-between;
  padding: var(--space-md) 0;
}

.crawler-row-main {
  display: grid;
  gap: var(--space-xs);
  min-width: 0;
}

.crawler-row-main p,
.crawler-row-url,
.crawler-error {
  color: var(--muted);
  font-size: var(--text-sm);
  margin: 0;
  overflow-wrap: anywhere;
}

.crawler-error {
  color: var(--brand-red);
}

.admin-keyword-row {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: grid;
  gap: var(--space-sm);
  grid-template-columns: minmax(0, 1fr) auto auto;
  padding: var(--space-sm) 0;
}

.admin-keyword-row strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.crawler-row-actions {
  align-items: center;
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  justify-content: flex-end;
}

.main.admin-main {
  padding-top: 0;
}

.admin-shell-header {
  position: sticky;
  top: 0;
  z-index: calc(var(--z-popover) - 1);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: center;
  gap: var(--space-sm);
  min-height: var(--admin-shell-h);
  margin: calc(var(--space-sm) * -1) calc(var(--page-x) * -1) var(--space-md);
  padding: env(safe-area-inset-top, 0px) var(--page-x) 0;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  backdrop-filter: blur(14px);
}

.admin-menu-button,
.admin-shell-placeholder {
  width: var(--tap-target);
  min-width: var(--tap-target);
  height: var(--tap-target);
}

.admin-menu-button {
  display: flex;
  align-items: center;
  justify-content: center;
  justify-self: start;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
}

.admin-shell-center {
  display: grid;
  justify-items: center;
  gap: 2px;
}

.admin-shell-actions {
  justify-self: end;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-sm);
  min-width: 0;
}

.admin-language-picker {
  flex: 0 0 76px;
  width: 76px;
  height: 38px;
  min-height: 38px;
}

.admin-shell-actions .secondary-btn {
  height: 38px;
  min-height: 38px;
}

.admin-shell-logo {
  justify-self: center;
  min-height: var(--admin-shell-h);
  margin: 0;
}

.admin-shell-logo img {
  max-height: calc(var(--admin-shell-h) - var(--space-md));
}

.admin-shell-scope {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}

.admin-inline-actions {
  display: inline-flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
  margin-left: var(--space-sm);
  vertical-align: middle;
}

.admin-menu-icon {
  display: grid;
  gap: var(--space-xs);
  width: var(--icon-md);
}

.admin-menu-icon span {
  display: block;
  height: var(--admin-menu-line-h);
  border-radius: var(--radius-full);
  background: currentColor;
}

.admin-shell-title {
  display: grid;
  gap: var(--admin-shell-title-gap);
  min-width: 0;
}

.admin-shell-title strong {
  color: var(--ink);
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
}

.admin-shell-title span,
.admin-scope-badge {
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height-tight);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-menu-scrim {
  position: fixed;
  inset: 0;
  z-index: var(--z-popover);
  background: var(--admin-menu-scrim);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.admin-menu-scrim.open {
  opacity: 1;
  pointer-events: auto;
}

.admin-menu-drawer {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: calc(var(--z-popover) + 1);
  width: var(--admin-menu-width);
  max-width: calc(100vw - var(--tap-target));
  padding: calc(env(safe-area-inset-top, 0px) + var(--space-lg)) var(--space-md) var(--space-lg);
  border-right: 1px solid var(--line);
  background: var(--surface);
  box-shadow: 0 var(--space-lg) var(--space-2xl) var(--admin-menu-shadow);
  transform: translateX(-100%);
  transition: transform 180ms ease;
}

.admin-menu-drawer.open {
  transform: translateX(0);
}

.admin-menu-head {
  display: grid;
  gap: var(--space-xs);
  padding-bottom: var(--space-md);
  border-bottom: 1px solid var(--line);
}

.admin-menu-head strong {
  color: var(--ink);
  font-size: var(--text-lg);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
}

.admin-menu-head span {
  color: var(--muted);
  font-size: var(--text-sm);
}

.admin-menu-list {
  display: grid;
  gap: var(--space-xs);
  padding-top: var(--space-md);
}

.admin-menu-item {
  display: flex;
  align-items: center;
  min-height: var(--tap-target);
  width: 100%;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--ink);
  padding: 0 var(--space-md);
  font-size: var(--text-md);
  font-weight: var(--font-medium);
  text-align: left;
}

.admin-menu-item.active {
  border-color: var(--line);
  background: var(--brand-light);
  color: var(--brand);
}

.admin-page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
  padding: var(--space-md) 0;
  border-bottom: 1px solid var(--line);
}

.admin-page-title {
  display: grid;
  gap: var(--space-xs);
  min-width: 0;
}

.admin-page-title h2 {
  margin: 0;
  color: var(--ink);
  font-size: var(--text-xl);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
}

.admin-page-title span {
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height-tight);
}

.admin-page-actions {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex: 0 0 auto;
}

.admin-placeholder-panel {
  display: grid;
  gap: var(--space-sm);
  padding: var(--space-lg);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.admin-placeholder-panel p {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-md);
  line-height: var(--line-height);
}

.language-select,
.compact-select {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  min-height: 34px;
  padding: 0 8px;
  color: var(--ink);
  line-height: var(--line-height);
}

.language-select option {
  font-size: var(--text-md);
  line-height: var(--line-height);
  padding: var(--space-sm) var(--space-md);
}

.language-picker {
  position: relative;
  flex: 0 0 50px;
  justify-self: end;
  align-self: center;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 32px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  overflow: hidden;
  appearance: none;
  -webkit-appearance: none;
  font-size: 13px;
  font-weight: 800;
}

.language-picker-wrap {
  position: relative;
  flex: 0 0 50px;
  width: 50px;
  height: 32px;
}

.language-picker-wrap .language-picker {
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.language-picker-desktop {
  display: none;
}

@media (hover: hover) and (pointer: fine) {
  .language-picker-mobile {
    display: none;
  }

  .language-picker-desktop {
    display: flex;
  }
}

.language-menu-backdrop {
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-popover) + 5);
  border: 0;
  background: rgba(0, 0, 0, 0.24);
  appearance: none;
  -webkit-appearance: none;
}

.language-menu-panel {
  position: fixed;
  right: max(12px, calc((100vw - 480px) / 2 + 12px));
  bottom: calc(12px + env(safe-area-inset-bottom));
  left: max(12px, calc((100vw - 480px) / 2 + 12px));
  z-index: calc(var(--z-popover) + 6);
  display: grid;
  gap: var(--space-sm);
  max-height: min(72vh, 560px);
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface) 96%, transparent);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.34);
  overflow: hidden;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.language-menu-grip {
  justify-self: center;
  width: 42px;
  height: 4px;
  border-radius: var(--radius-full);
  background: var(--line);
}

.language-menu-list {
  display: grid;
  gap: 8px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  padding: 2px;
}

.language-menu-option {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr) 24px;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 48px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  text-align: left;
  font: inherit;
  font-weight: 800;
}

.language-menu-option.active {
  border-color: color-mix(in srgb, var(--brand-red) 70%, var(--line));
  background: var(--brand-light);
  color: var(--brand-red);
}

.language-menu-flag {
  font-size: 22px;
  line-height: 1;
}

.language-menu-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.language-menu-check {
  justify-self: end;
  font-size: 18px;
  line-height: 1;
}

.language-picker.admin-language-picker {
  flex-basis: 76px;
  width: 76px;
  height: 38px;
  min-height: 38px;
}

.admin-language-picker .language-flag {
  display: none;
}

.admin-language-picker .language-select {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 100%;
  min-height: 100%;
  padding: 0 10px;
  border: 0;
  border-radius: inherit;
  background: transparent;
  background-image: none;
  color: inherit;
  font-weight: 800;
  text-align: center;
  text-align-last: center;
}

.admin-language-picker .language-select option {
  min-height: 34px;
  padding: var(--space-sm) var(--space-md);
  background: var(--surface);
  color: var(--ink);
  line-height: 1.6;
  font-weight: 600;
}

.language-flag {
  font-size: inherit;
  line-height: 1;
}

.topbar .language-select {
  position: absolute;
  inset: 0;
  width: 100%;
  max-width: none;
  min-height: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  cursor: pointer;
}

.main {
  padding: 14px 0 24px;
}

.main > .section-title,
.main > .admin-page-header,
.main > .admin-logo,
.main > .admin-toolbar,
.main > .admin-panel,
.main > .form,
.main > .permission-list,
.main > .admin-post-list,
.main > .metric-grid,
.main > .segmented,
.main > .empty-state,
.search-view > .search-panel,
.my-main > .my-tabs {
  margin-left: 16px;
  margin-right: 16px;
}

.hero {
  padding: 12px 16px;
  background: linear-gradient(135deg, #fff8f6 0%, #f8fbff 100%);
  border-bottom: 1px solid var(--line);
}

.hero h1 {
  margin: 0;
  font-size: 25px;
  line-height: 1.18;
}

.hero p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.5;
}

.region-row {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-top: 0;
}

.search-panel {
  flex: 1;
  min-width: 0;
}

.search-page-panel {
  position: fixed;
  top: 48px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 24;
  width: min(100%, 480px);
  margin: 0;
  padding: 8px 16px 10px;
  box-sizing: border-box;
  background: var(--surface);
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.search-view > .search-page-panel {
  margin: 0;
}

.search-page-panel.search-panel-hidden {
  transform: translate(-50%, -140%);
  opacity: 0;
  pointer-events: none;
}

.search-view {
  padding-top: 112px;
}

.region-chip,
.ghost-button,
.primary-button,
.danger-button,
.quiet-button {
  border: 0;
  border-radius: var(--radius);
  min-height: 40px;
  padding: 0 12px;
  font-weight: 700;
  white-space: nowrap;
}

.region-chip {
  flex: 1;
  min-width: 0;
  background: #ffffff;
  color: var(--ink);
  border: 1px solid var(--line);
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
}

.primary-button {
  background: var(--brand-red);
  color: #fff;
  box-shadow: 0 8px 18px rgba(223, 63, 37, 0.22);
  transition: opacity 0.15s, background 0.15s;
}

.primary-button.publishing {
  opacity: 0.72;
  cursor: not-allowed;
  box-shadow: none;
}

.primary-button.publishing::after {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-left: 8px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: #fff;
  border-radius: 50%;
  animation: btn-spin 0.7s linear infinite;
  vertical-align: middle;
}

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

.ghost-button {
  background: #f0f3f7;
  color: var(--ink);
}

.danger-button {
  background: #fff0f0;
  color: #b12a2a;
}

.quiet-button {
  background: transparent;
  color: var(--muted);
  padding: 0 6px;
}

.search-box {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 12px;
  background: #fff;
}

.search-history {
  display: none;
  gap: 6px;
  overflow-x: auto;
  padding: 8px 0 2px;
  scrollbar-width: none;
}

.search-panel:focus-within .search-history:not(:empty) {
  display: flex;
}

.search-page-panel .search-history:not(:empty) {
  display: flex;
}

.search-page-panel.has-query .search-history {
  display: none;
}

.search-history::-webkit-scrollbar {
  display: none;
}

.search-history-chip {
  flex: 0 0 auto;
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  max-width: 180px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 24px 0 12px;
  background: #fff;
  color: #4a4f58;
}

.search-history-label {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.search-history-remove {
  position: absolute;
  top: -6px;
  right: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--surface);
  color: var(--brand-red);
  font-size: 13px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 1px 4px rgba(15, 23, 42, 0.18);
}

.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 18px 0 10px;
}

.section-title h2 {
  margin: 0;
  font-size: 17px;
}

.section-title span {
  color: var(--muted);
  font-size: 12px;
}

.category-grid {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  overflow-y: hidden;
  margin: 0 0 10px;
  padding: 0 16px 2px;
  scrollbar-width: none;
  cursor: grab;
  overscroll-behavior-inline: contain;
}

.category-grid.dragging {
  cursor: grabbing;
}

.category-grid::-webkit-scrollbar {
  display: none;
}

.category-button {
  position: relative;
  flex: 0 0 auto;
  width: auto;
  min-width: 64px;
  min-height: 38px;
  padding: 5px 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  text-align: left;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
}

.category-button strong {
  position: relative;
  z-index: 1;
  display: block;
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
}

.category-button.active {
  background: var(--category-chip-bg);
  color: var(--brand-red);
  box-shadow: inset 0 0 0 1px rgba(223, 63, 37, 0.42);
}

.category-mark {
  display: inline-block;
  width: 3px;
  height: 14px;
  border-radius: var(--radius);
  margin: 0;
  flex: 0 0 3px;
}

.category-icon {
  display: none;
  width: 22px;
  height: 22px;
  margin-bottom: 5px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.feed {
  display: grid;
  gap: 0;
}

.post-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px;
  background: #fff;
}

.post-card.pinned-card {
  border-color: rgba(223, 63, 37, 0.35);
  background: #fffaf9;
}

.feed .feed-post-card {
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  padding: 14px 16px;
  background: var(--surface);
}

.feed .feed-post-card.pinned-card {
  border-left: 4px solid var(--brand-red);
  border-bottom: 0;
  padding-left: 12px;
  background: var(--soft-red);
}

.feed-home-mixed .feed-post-card.pinned-card {
  border-left: 0;
  padding-left: 0;
  background: linear-gradient(180deg, rgba(245, 197, 66, 0.14), var(--surface) 66%);
}

.local-news-section {
  padding: 0 var(--page-x) var(--space-md);
}

.local-news-title {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  min-height: var(--space-2xl);
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
}

.local-news-strip {
  display: flex;
  align-items: stretch;
  gap: var(--space-md);
  overflow-x: auto;
  padding-bottom: var(--space-xs);
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.local-news-strip::-webkit-scrollbar {
  display: none;
}

.local-news-card {
  flex: 0 0 var(--local-news-card-width);
  scroll-snap-align: start;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--ink);
  padding: 0;
  display: grid;
  gap: var(--space-sm);
  text-align: left;
  overflow: hidden;
}

.local-news-media {
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: var(--ratio-news-carousel);
  border: 0;
  border-radius: var(--radius-sm);
  padding: 0;
  overflow: hidden;
  background: var(--category-chip-bg);
}

.local-news-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.local-news-placeholder {
  color: var(--muted);
  font-size: var(--text-sm);
}

.local-news-caption {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
  line-height: var(--line-height);
}

.local-news-meta {
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height);
}

.feed-gallery {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gallery-feed-gap);
  padding: 0 var(--gallery-feed-x) var(--space-md);
}

.feed-home-mixed {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--gallery-feed-gap);
  padding: 0 var(--gallery-feed-x) var(--space-md);
}

.feed-gallery .feed-post-card {
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  overflow: hidden;
}

.feed-home-mixed .feed-post-card {
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  overflow: hidden;
}

.feed-home-gallery .feed-post-card {
  border-bottom: 0;
}

.gallery-card-content {
  padding: calc(var(--space-xs) / 2) var(--gallery-feed-x) 0;
  display: grid;
  gap: 0;
}

.gallery-post-card .post-top,
.news-post-card .post-top {
  align-items: flex-start;
  gap: var(--space-sm);
}

.gallery-post-card .post-title-button {
  -webkit-line-clamp: 2;
}

.gallery-post-card .post-title {
  font-size: var(--text-md);
  line-height: var(--line-height-tight);
}

.gallery-post-card .feed-title-meta {
  gap: var(--space-xs);
  margin-top: 0;
  font-size: var(--text-xs);
  line-height: var(--line-height-tight);
}

.feed-home-gallery .gallery-post-card .feed-title-meta {
  margin-top: calc(-1 * var(--space-xs) / 2);
}

.gallery-post-card .feed-title-meta .post-address {
  font-size: var(--text-xs);
}

.gallery-post-card .post-stats.feed-footer {
  margin-top: var(--space-xs);
}

.gallery-post-card .image-grid,
.news-post-card .image-grid {
  margin-top: 0;
  grid-template-columns: 1fr;
  gap: 0;
}

.gallery-post-card .post-image,
.gallery-cover,
.cover-placeholder.gallery-cover {
  aspect-ratio: var(--ratio-xhs-card);
}

.feed-news-large .feed-post-card {
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  padding: var(--space-lg) 0;
}

.news-post-card {
  min-width: 0;
  overflow: hidden;
}

.news-card-summary {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-width: 0;
  width: calc(100% - (var(--page-x) * 2));
  box-sizing: border-box;
  overflow-wrap: anywhere;
  margin: var(--space-xs) var(--page-x) 0;
  color: var(--ink);
}

.news-post-card .post-title,
.news-post-card .post-title-button,
.news-post-card .feed-title-meta {
  min-width: 0;
  overflow-wrap: anywhere;
}

.news-post-card .post-title-button {
  -webkit-line-clamp: 2;
}

.feed-news-large .news-post-card .post-top {
  justify-content: space-between;
}

.news-post-card .image-grid,
.news-post-card .cover-placeholder {
  width: calc(100% - (var(--page-x) * 2));
  margin: var(--space-xs) var(--page-x) 0;
}

.news-card-media {
  position: relative;
  width: calc(100% - (var(--page-x) * 2));
  margin: var(--space-xs) var(--page-x) 0;
}

.news-card-media .image-grid,
.news-card-media .cover-placeholder {
  width: 100%;
  margin: 0;
}

.news-media-actions {
  position: static;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  margin-top: var(--space-xs);
}

.news-post-card .post-image,
.news-cover,
.cover-placeholder.news-cover {
  aspect-ratio: var(--ratio-wide);
}

.cover-placeholder {
  width: 100%;
  min-height: var(--tap-target);
  border: 0;
  border-radius: var(--radius-sm);
  background: var(--category-chip-bg);
  color: var(--muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feed-news-large .news-post-card .post-top,
.feed-news-large .news-post-card .feed-title-meta,
.feed-news-large .news-post-card .post-meta,
.feed-news-large .news-post-card .feed-footer {
  margin-right: var(--page-x);
  margin-left: var(--page-x);
}

.feed-job .feed-post-card {
  position: relative;
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  padding: var(--space-lg) var(--page-x);
}

.job-card-main {
  width: 100%;
  min-width: 0;
}

.job-card-row {
  display: flex;
  align-items: flex-start;
  gap: var(--space-md);
  width: 100%;
  min-width: 0;
}

.job-card-content {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.job-post-card .post-top {
  align-items: flex-start;
  gap: var(--space-sm);
}

.job-post-card .post-title {
  font-size: var(--text-lg);
  line-height: var(--line-height-tight);
  overflow-wrap: anywhere;
}

.job-post-card .post-title-button {
  overflow-wrap: anywhere;
}

.job-post-card .image-grid,
.job-post-card .cover-placeholder {
  width: 100%;
  margin-top: var(--job-cover-offset);
}

.job-post-card .image-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0;
}

.job-post-card .post-image,
.job-cover,
.cover-placeholder.job-cover {
  aspect-ratio: var(--ratio-job-card-media);
}

.job-card-media {
  position: relative;
  flex: 0 0 var(--job-cover-width);
  width: var(--job-cover-width);
  min-width: 0;
  align-self: flex-start;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.job-card-media .image-grid,
.job-card-media .cover-placeholder {
  flex: none;
}

.job-media-actions {
  position: absolute;
  left: var(--space-xs);
  bottom: var(--space-xs);
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}

.news-media-actions .favorite-button,
.job-media-actions .favorite-button {
  height: var(--space-xl);
  min-height: var(--space-xl);
  color: var(--brand-red);
  gap: var(--space-xs);
}

.news-media-actions .favorite-icon,
.job-media-actions .favorite-icon {
  width: var(--icon-md);
  height: var(--icon-md);
}

.home-job-section {
  padding: 0 0 var(--space-md);
}

.home-job-strip {
  display: flex;
  gap: var(--space-md);
  overflow-x: auto;
  padding: 0 var(--page-x) var(--space-xs);
  scroll-padding-inline: var(--page-x);
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.home-job-strip::-webkit-scrollbar {
  display: none;
}

.home-job-strip .job-post-card {
  flex: 0 0 100%;
  scroll-snap-align: start;
  border: 0;
  border-bottom: 0;
  border-radius: 0;
  background: transparent;
  padding: var(--space-lg) 0 var(--space-lg);
}

.job-post-card .post-stats.feed-footer {
  margin-top: auto;
}

.post-top {
  display: flex;
  justify-content: space-between;
  gap: var(--space-sm);
  align-items: flex-start;
}

.post-title {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  font-size: var(--text-xl);
  line-height: var(--line-height-tight);
}

.post-title-button {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: 800;
  text-align: left;
  line-height: inherit;
}

.post-card:not(.detail-card) .post-title-button {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.post-title-button:active {
  color: var(--brand-red);
}

.feed-category-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  max-width: none;
  margin: 0;
  min-height: 24px;
  padding: 3px 7px;
  border: 0;
  border-radius: var(--radius);
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.1;
  text-transform: none;
  vertical-align: 2px;
  white-space: nowrap;
  overflow: hidden;
}

.feed-category-pill::before {
  content: "";
  width: 3px;
  height: 14px;
  border-radius: var(--radius);
  background: var(--category-color, var(--brand-red));
  flex: 0 0 3px;
}

.feed-category-pill > span {
  font-weight: 700;
}

.feed-category-pill .category-icon {
  display: none;
}

.post-body {
  margin: 8px 0 0;
  color: #4a4f58;
  font-size: 15px;
  line-height: 1.65;
}

.post-body-button {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  text-align: left;
}

.post-card:not(.detail-card) .post-body-button {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  max-height: calc(1.65em * 3);
}

.news-post-card .post-body-button.news-card-summary {
  width: calc(100% - (var(--page-x) * 2));
  margin: var(--space-xs) var(--page-x) 0;
  -webkit-line-clamp: 2;
  max-height: calc(1.65em * 2);
}

.post-actions {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
  align-items: center;
}

.icon-action {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 26px;
  min-height: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  -webkit-tap-highlight-color: transparent;
}

.favorite-button {
  min-width: auto;
  min-height: 20px;
  height: 20px;
  padding: 0;
  gap: 4px;
  border: 0;
  background: transparent;
  box-shadow: none;
  color: var(--muted);
}

.favorite-icon {
  display: block;
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

.favorite-button.active {
  color: var(--brand-red);
  border: 0;
  background: transparent;
  box-shadow: none;
}

.favorite-button.active .favorite-icon {
  fill: currentColor;
}

.favorite-button:not(.active) .favorite-icon {
  fill: none;
}

.feed-post-card .favorite-button,
.detail-card .favorite-button {
  min-height: 26px;
  height: 26px;
}

.feed-post-card .favorite-icon,
.detail-card .favorite-icon {
  width: 20px;
  height: 20px;
}

.favorite-button:hover,
.favorite-button:focus,
.favorite-button:active {
  background: transparent;
  box-shadow: none;
}

.share-button,
.more-button {
  width: var(--tap-target);
  min-width: var(--tap-target);
  height: var(--tap-target);
  min-height: var(--tap-target);
  padding: 0;
}

.more-button {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.more-button:hover,
.more-button:focus,
.more-button:active {
  background: transparent;
  box-shadow: none;
}

.post-action-menu {
  position: relative;
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0;
  align-self: flex-start;
  transform: translateY(calc((var(--feed-title-line) - var(--tap-target)) / 2));
}

.more-icon {
  width: var(--icon-md);
  height: var(--icon-md);
  fill: currentColor;
}

.post-action-popover {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: var(--z-popover);
  min-width: 112px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 14px 30px rgba(15, 23, 42, 0.16);
}

.post-action-menu:not(.open) .post-action-popover {
  display: none;
}

.post-action-popover button {
  width: 100%;
  min-height: 36px;
  border: 0;
  border-radius: var(--radius);
  padding: 0 10px;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  text-align: left;
}

.post-action-popover button:active {
  background: var(--soft-red);
  color: var(--brand-red);
}

.post-action-popover .report-menu-item {
  color: var(--brand-red);
}

.stat-item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 26px;
  white-space: nowrap;
}

.stat-icon {
  display: block;
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

.feed-post-card .stat-icon,
.detail-card .stat-icon {
  width: 20px;
  height: 20px;
}

.stat-count {
  min-width: 0.8em;
  font-size: 12px;
  font-weight: 500;
  line-height: 1;
}

.post-body-button:active {
  color: var(--brand-red);
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 10px;
}

.image-grid.single-image {
  grid-template-columns: 1fr;
}

.post-image {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: var(--radius);
  object-fit: cover;
  background: var(--image-placeholder);
}

.image-button {
  position: relative;
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: var(--image-placeholder);
}

.image-category-badge {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--icon-lg);
  max-width: 100%;
  padding: 0 var(--space-md);
  border-radius: var(--radius) 0 var(--radius-sm) 0;
  background: var(--category-color, var(--brand-red));
  color: var(--surface);
  font-size: var(--text-xs);
  font-weight: var(--font-semibold);
  line-height: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.home-pinned-overlay {
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: 3;
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  min-width: 38px;
  pointer-events: none;
}

.home-pin-mark {
  display: block;
  width: 30px;
  height: 18px;
  position: relative;
  transform: translateX(4px);
}

.home-pin-mark::before {
  content: "";
  position: absolute;
  inset: 0;
  border-left: 4px solid var(--brand-blue);
  border-top: 4px solid var(--brand-blue);
  transform: translateY(5px) rotate(45deg);
  transform-origin: center;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.24));
}

.home-pin-label {
  color: var(--brand-blue);
  font-size: var(--text-xs);
  font-weight: 900;
  line-height: 1;
  transform: translate(-5%, -30%);
}

.image-button:active .post-image {
  transform: scale(0.98);
}

.single-image .post-image,
.detail-card .single-image .post-image {
  aspect-ratio: 4 / 3;
}

.post-card:not(.detail-card) .image-grid.single-image {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.post-card:not(.detail-card) .single-image .post-image {
  aspect-ratio: 1 / 1;
}

.post-card.gallery-post-card .image-grid.single-image,
.post-card.news-post-card .image-grid.single-image,
.post-card.job-post-card .image-grid.single-image {
  grid-template-columns: 1fr;
}

.post-card.gallery-post-card .single-image .post-image {
  aspect-ratio: var(--ratio-xhs-card);
}

.post-card.news-post-card .single-image .post-image {
  aspect-ratio: var(--ratio-wide);
}

.post-card.job-post-card .single-image .post-image {
  aspect-ratio: var(--ratio-job-card-media);
}

.detail-card .image-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.detail-image-carousel {
  position: relative;
  margin: 0 calc(-1 * var(--page-x)) var(--space-lg);
}

.detail-image-strip {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  border-radius: 0;
  cursor: grab;
  user-select: none;
}

.detail-image-strip.dragging {
  cursor: grabbing;
  scroll-snap-type: none;
}

.detail-image-strip::-webkit-scrollbar {
  display: none;
}

.detail-image-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
}

.detail-image-slide .post-image {
  aspect-ratio: 4 / 3;
  border-radius: 0;
  background: var(--image-placeholder);
}

.detail-image-housing .detail-image-slide .post-image,
.detail-image-secondhand .detail-image-slide .post-image,
.detail-image-business .detail-image-slide .post-image {
  aspect-ratio: var(--ratio-xhs-detail);
}

.detail-carousel-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 52px;
  border: 0;
  border-radius: var(--radius);
  color: #fff;
  background: rgba(0, 0, 0, 0.28);
  transform: translateY(-50%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.detail-carousel-nav-prev {
  left: 10px;
}

.detail-carousel-nav-next {
  right: 10px;
}

.detail-carousel-nav svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (hover: hover) and (pointer: fine) {
  .detail-carousel-nav {
    display: flex;
  }
}

.detail-image-back {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 2;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: rgba(34, 37, 42, 0.46);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.detail-image-counter {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  min-width: 48px;
  padding: 5px 10px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}


.feed-image-carousel {
  position: relative;
  margin: 0 -16px 12px;
  overflow: hidden;
}

.feed-image-strip {
  display: flex;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}

.feed-image-strip::-webkit-scrollbar {
  display: none;
}

.feed-image-slide {
  flex: 0 0 100%;
  scroll-snap-align: center;
  display: block;
  border: 0;
  padding: 0;
  background: transparent;
  cursor: pointer;
}

.feed-image-slide .post-image {
  aspect-ratio: 4 / 3;
  border-radius: 0;
  background: #111;
  width: 100%;
  display: block;
  object-fit: cover;
}

.feed-image-counter {
  position: absolute;
  left: 50%;
  bottom: 10px;
  transform: translateX(-50%);
  min-width: 44px;
  padding: 4px 10px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  pointer-events: none;
}

.form-image-preview {
  margin: 0 0 4px;
}

.sortable-image-list {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 7px;
  margin-top: 8px;
}

.sortable-image-list.sorting {
  position: relative;
}

.sortable-image-list.empty {
  display: none;
}

.sortable-image-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  cursor: grab;
  touch-action: none;
  user-select: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
  will-change: transform;
}

.sortable-image-card.dragging {
  opacity: 0.9;
  transform: scale(1.05);
  cursor: grabbing;
  box-shadow: 0 18px 36px rgba(24, 28, 36, 0.34);
  pointer-events: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.sortable-image-card img {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  background: var(--image-placeholder);
  pointer-events: none;
  user-select: none;
}

.sortable-image-placeholder {
  border: 1px dashed rgba(223, 63, 37, 0.45);
  border-radius: var(--radius);
  background: rgba(223, 63, 37, 0.08);
  aspect-ratio: 1 / 1;
  transition: transform 0.18s ease, opacity 0.18s ease;
}

.sortable-image-card.drop-settle {
  animation: imageDropSettle 0.34s cubic-bezier(0.22, 1.35, 0.36, 1);
}

@keyframes imageDropSettle {
  0% {
    transform: scale(0.96);
  }
  55% {
    transform: scale(1.04);
  }
  100% {
    transform: scale(1);
  }
}

.image-remove-button {
  position: absolute;
  top: 2px;
  right: 2px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  padding: 0;
  border: 0;
  border-radius: var(--radius);
  color: #fff;
  background: rgba(34, 37, 42, 0.62);
  font-size: 14px;
  line-height: 1;
}

.image-order-badge {
  position: absolute;
  left: 50%;
  bottom: 3px;
  min-width: 20px;
  height: 20px;
  padding: 0 5px;
  transform: translateX(-50%);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: rgba(34, 37, 42, 0.58);
  font-size: 11px;
  font-weight: 800;
}

.detail-card .post-title {
  font-size: 22px;
  line-height: 1.28;
}

.detail-card .post-action-menu {
  transform: translateY(calc((var(--detail-title-line) - var(--tap-target)) / 2));
}

.detail-main {
  padding-top: 0;
}

.detail-card {
  border: 0;
  border-radius: 0;
  padding: 0 16px 18px;
  background: var(--surface);
}

.detail-card.no-detail-image {
  padding-top: 16px;
}

.image-lightbox {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  padding: 0;
  touch-action: none;
}

.lightbox-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(12, 15, 20, 0.86);
}

.lightbox-content {
  position: relative;
  z-index: 1;
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  overflow: hidden;
}

.lightbox-image-strip {
  display: flex;
  width: 100vw;
  height: 100vh;
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  cursor: grab;
  user-select: none;
  -webkit-overflow-scrolling: touch;
}

.lightbox-image-strip.dragging {
  cursor: grabbing;
  scroll-snap-type: none;
}

.lightbox-image-strip::-webkit-scrollbar {
  display: none;
}

.lightbox-slide {
  flex: 0 0 100%;
  width: 100vw;
  height: 100vh;
  border: 0;
  padding: 0;
  margin: 0;
  scroll-snap-align: center;
  background: transparent;
}

.lightbox-slide img {
  display: block;
  width: 100vw;
  height: 100vh;
  max-width: 100vw;
  max-height: 100vh;
  border-radius: 0;
  object-fit: contain;
  background: #111;
  user-select: none;
  touch-action: none;
  transform-origin: center center;
  transition: none;
  will-change: transform;
  backface-visibility: hidden;
}

.lightbox-counter {
  position: absolute;
  z-index: 3;
  left: 50%;
  bottom: 14px;
  transform: translateX(-50%);
  min-width: 48px;
  padding: 5px 10px;
  border-radius: var(--radius);
  background: rgba(0, 0, 0, 0.42);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  text-align: center;
  animation: lightboxCounterIn 0.24s ease both;
}

@media (max-width: 640px) {
  .lightbox-counter {
    bottom: calc(86px + env(safe-area-inset-bottom));
  }
}

.lightbox-counter.counter-bump {
  animation: lightboxCounterIn 0.24s ease both;
}

.lightbox-nav {
  position: absolute;
  top: 50%;
  z-index: 2;
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 58px;
  border: 0;
  border-radius: var(--radius);
  color: #fff;
  background: rgba(0, 0, 0, 0.28);
  transform: translateY(-50%);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.lightbox-nav-prev {
  left: 10px;
}

.lightbox-nav-next {
  right: 10px;
}

.lightbox-nav svg {
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (hover: hover) and (pointer: fine) {
  .lightbox-nav {
    display: flex;
  }
}

@keyframes lightboxImageIn {
  0% {
    opacity: 0.72;
  }
  100% {
    opacity: 1;
  }
}

@keyframes lightboxCounterIn {
  0% {
    opacity: 0;
    transform: translate(-50%, 8px);
  }
  100% {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

.detail-card .post-body {
  margin-top: 14px;
  margin-bottom: 14px;
  font-size: 17px;
  line-height: 1.75;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.post-address {
  margin: 8px 0 10px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.45;
}

.post-card-left-meta {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  min-width: 0;
  color: var(--muted);
  line-height: var(--line-height);
}

.meta-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  opacity: 0.72;
  font-size: var(--text-sm);
  line-height: 1;
}

.post-card-left-meta .post-address {
  max-width: 190px;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.feed-title-meta {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-xs);
  min-width: 0;
  margin-top: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height-tight);
}

.feed-title-meta > span,
.post-card-left-meta > span {
  display: inline-flex;
  align-items: center;
}

.feed-title-meta .post-address {
  max-width: 240px;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: var(--text-sm);
}

.feed-post-card .post-stats {
  justify-content: space-between;
  gap: var(--space-sm);
}

.feed-post-card .feed-footer {
  width: 100%;
  flex-wrap: nowrap;
  margin-top: var(--space-sm);
}

.feed-card-actions {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: var(--space-sm);
}

.feed-post-card .price {
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
}

.detail-address {
  margin: 0;
  font-size: 15px;
}

.detail-info-row {
  margin: 8px 0 10px;
}

.detail-card .post-stats {
  font-size: 16px;
  font-weight: 400;
  line-height: normal;
}

.contact-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
}

.contact-action {
  width: var(--tap-target);
  height: var(--tap-target);
  min-height: var(--tap-target);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  padding: 0;
  box-sizing: border-box;
  line-height: 1;
  text-align: center;
  vertical-align: middle;
}

.contact-action.disabled {
  color: var(--muted);
  background: #f6f7f9;
  pointer-events: none;
}

.contact-icon {
  display: block;
  width: var(--icon-lg);
  height: var(--icon-lg);
  flex: 0 0 auto;
  fill: none;
  margin: 0;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-icon text {
  dominant-baseline: middle;
  text-anchor: middle;
}

.contact-action .contact-icon {
  width: var(--icon-lg);
  height: var(--icon-lg);
}

.contact-action[data-contact-type="email"] .contact-icon,
.permission-contact-row .contact-action[data-contact-type="email"] .contact-icon,
.detail-contact-side .contact-action[data-contact-type="email"] .contact-icon {
  display: flex;
  align-items: center;
  justify-content: center;
}

.phone-contact-layer {
  position: fixed;
  inset: 0;
  z-index: 70;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px calc(150px + env(safe-area-inset-bottom));
}

.phone-contact-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(12, 15, 20, 0.22);
}

.phone-contact-sheet {
  position: relative;
  z-index: 1;
  width: min(100%, 448px);
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  padding: 10px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius);
  background: #0f5132;
  box-shadow: 0 18px 42px rgba(9, 45, 29, 0.34);
  animation: phoneSheetIn 0.18s ease both;
}

.phone-contact-option {
  min-height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  color: #fff;
  background: rgba(255, 255, 255, 0.12);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  font-size: 14px;
  font-weight: 400;
}

.phone-contact-option .contact-icon {
  width: 20px;
  height: 20px;
}

@keyframes phoneSheetIn {
  0% {
    opacity: 0;
    transform: translateY(12px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.post-meta,
.post-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 10px;
  color: var(--muted);
  font-size: 12px;
}

.post-stat-actions {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.inline-action {
  height: 26px;
  min-height: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 9px;
  background: #fff;
  color: #b12a2a;
  font-size: 12px;
  font-weight: 800;
}

.report-button {
  min-width: 64px;
  padding: 0 8px;
}

.pill,
.status-pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: var(--radius);
  background: #f1f3f6;
  color: #4d5664;
  font-size: 12px;
  white-space: nowrap;
}

.status-published {
  background: #ecf8ef;
  color: #24733c;
}

.status-pending {
  background: #fff6df;
  color: #8b6100;
}

.status-rejected,
.status-removed {
  background: #fff0f0;
  color: #a92c2c;
}

.status-ended {
  background: #eef1f5;
  color: #6b7280;
  font-weight: 800;
}

.vip-pill {
  display: inline-flex;
  gap: 3px;
  align-items: center;
  color: var(--brand-blue);
  background: rgba(74, 163, 223, 0.12);
  border-color: rgba(74, 163, 223, 0.35);
  font-weight: 500;
}

.vip-mark {
  color: var(--brand-blue);
  font-weight: 900;
}

.vip-text {
  font-weight: 500;
}

.price {
  color: var(--brand-red);
  font-size: 14px;
  font-weight: 900;
}

.stat-item[data-stat="views"] .stat-count {
  font-size: inherit;
  font-weight: inherit;
  line-height: inherit;
  color: inherit;
}

.end-hint {
  padding: 14px 0 4px;
  color: var(--muted);
  font-size: 12px;
  text-align: center;
}

.feed-pagination-footer {
  min-height: 1px;
}

.feed-loading-indicator {
  min-height: 28px;
  padding: 10px 0 2px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
}

.feed-loading-indicator:not(.is-active) {
  padding: 0;
}

.feed-load-sentinel {
  height: 72px;
  pointer-events: none;
}

.empty-state {
  padding: 30px 18px;
  border: 1px dashed #cbd1da;
  border-radius: var(--radius);
  text-align: center;
  color: var(--muted);
  background: #fafbfc;
}

.form {
  display: grid;
  gap: 12px;
}

.form-main {
  padding-bottom: calc(156px + env(safe-area-inset-bottom));
}

.publish-main {
  padding-bottom: var(--page-bottom-compact);
}

form[data-form="publish"] > .primary-button {
  margin-bottom: 0;
  scroll-margin-bottom: var(--page-bottom-compact);
}

.ai-fill-row {
  display: none;
  justify-content: flex-end;
  margin: -2px 0 10px;
}

.ai-fill-row.has-images.is-ai-enabled {
  display: flex;
}

.ai-fill-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 34px;
  padding: 0 12px;
  font-size: 13px;
  font-weight: 800;
  color: var(--brand-red);
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  cursor: pointer;
  transition: opacity 0.15s, color 0.15s, border-color 0.15s, background 0.15s;
}

.ai-fill-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.is-hidden {
  display: none !important;
}

.field {
  display: grid;
  gap: 6px;
}

.field label {
  color: #3b4048;
  font-size: 14px;
  font-weight: 700;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 10px 11px;
  background: #fff;
  color: var(--ink);
}

.field select {
  appearance: none;
  -webkit-appearance: none;
  padding-right: 34px;
  background-image:
    linear-gradient(45deg, transparent 50%, currentColor 50%),
    linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position:
    calc(100% - 18px) 50%,
    calc(100% - 12px) 50%;
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.field textarea {
  min-height: 116px;
  resize: vertical;
  line-height: 1.45;
}

.field-hint {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.4;
}

.char-counter {
  justify-self: end;
}

.price-input-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(58px, auto);
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.price-input-row input {
  min-width: 0;
}

.price-input-wrap {
  position: relative;
  display: block;
  min-width: 0;
}

.price-input-wrap input {
  width: 100%;
  padding-left: 48px;
}

.currency-prefix {
  position: absolute;
  left: 12px;
  top: 50%;
  z-index: 1;
  min-width: 24px;
  min-height: 0;
  border: 0;
  border-radius: 0;
  transform: translateY(-50%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--muted);
  background: transparent;
  font-weight: 800;
  pointer-events: none;
}

.negotiable-button.active {
  color: #fff;
  background: var(--brand-red);
}

.period-toggle {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

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

.period-option span {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  min-width: 54px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--muted);
  background: #fff;
  font-weight: 800;
}

.period-option input:checked + span {
  color: #fff;
  border-color: var(--brand-red);
  background: var(--brand-red);
}

.period-option-wanted input:checked + span {
  border-color: #16a34a;
  background: #16a34a;
}

.contact-rows {
  display: grid;
  gap: 8px;
}

.contact-row {
  display: grid;
  grid-template-columns: 112px minmax(0, 1fr) 36px;
  gap: 8px;
  align-items: center;
  min-width: 0;
}

.contact-row select,
.contact-row input {
  min-width: 0;
}

.contact-type-select {
  position: static;
  width: 100%;
  height: 36px;
  min-height: 36px;
  padding: 0 28px 0 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: var(--ink);
  opacity: 1;
  pointer-events: auto;
}

.contact-type-wheel {
  display: none;
}

.contact-wheel-option {
  width: 100%;
  min-width: 0;
  min-height: 0;
  border: 0;
  border-radius: 0;
  padding: 0;
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  line-height: 1;
  opacity: 0.45;
  transform: scale(0.82);
  overflow: hidden;
  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-wheel-option.is-active {
  color: var(--ink);
  font-size: 13px;
  opacity: 1;
  transform: scale(1);
}

.icon-remove-button {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--brand-red);
  font-size: 22px;
  line-height: 1;
}

.contact-row-action {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: #fff;
  color: var(--brand-red);
  font-size: 23px;
  font-weight: 700;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.contact-row-spacer {
  width: 36px;
  height: 36px;
}

.add-contact-button {
  justify-self: start;
}

.compact-form .field > label:not(.image-upload-button) {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.compact-form .add-contact-button {
  display: none;
}

.category-wheel-field {
  margin: 2px -16px 4px;
}

.category-native-select {
  position: absolute;
  width: 1px !important;
  height: 1px;
  min-height: 1px !important;
  padding: 0 !important;
  border: 0 !important;
  opacity: 0;
  pointer-events: none;
}

.category-wheel-shell {
  position: relative;
  overflow: hidden;
  padding: 4px 0 7px;
}

.category-wheel-shell::before,
.category-wheel-shell::after {
  content: none;
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 56px;
  pointer-events: none;
}

.category-wheel-shell::before {
  left: 0;
  background: linear-gradient(90deg, var(--surface), rgba(255, 255, 255, 0));
}

.category-wheel-shell::after {
  right: 0;
  background: linear-gradient(270deg, var(--surface), rgba(255, 255, 255, 0));
}

.category-wheel-track {
  display: flex;
  align-items: center;
  gap: 6px;
  overflow-x: auto;
  overflow-y: hidden;
  min-height: 48px;
  padding: 3px 0;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-inline: contain;
}

.category-wheel-track::-webkit-scrollbar {
  display: none;
}

.category-wheel-spacer {
  flex: 0 0 calc(50% - 37px);
  min-width: calc(50% - 37px);
}

.category-wheel-item {
  position: relative;
  flex: 0 0 68px;
  width: 68px;
  height: 34px;
  border: 0;
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 0 10px;
  scroll-snap-align: center;
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  opacity: 0.82;
  filter: none;
  transform: none;
  overflow: hidden;
  transition: opacity 0.18s ease, color 0.18s ease, background 0.18s ease, border-color 0.18s ease;
}

.category-wheel-item::before {
  content: none;
}

.category-wheel-item.is-active {
  z-index: 3;
  opacity: 1;
  filter: none;
  transform: scale(1);
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  box-shadow: inset 0 0 0 1px rgba(223, 63, 37, 0.42), 0 6px 14px rgba(223, 63, 37, 0.12);
}

.category-wheel-label {
  position: relative;
  z-index: 1;
  display: block;
  max-width: 58px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  font-weight: 800;
  line-height: 1.1;
}

.image-upload-field {
  gap: 8px;
}

.image-upload-button {
  width: 56px;
  height: 56px;
  border: 1px dashed #cbd1da;
  border-radius: var(--radius);
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-red);
}

.image-upload-button span {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.image-upload-input {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.camera-icon {
  width: 27px;
  height: 27px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.check-row {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #4a4f58;
  font-size: 13px;
}

.check-row input {
  width: auto;
  min-height: auto;
}

.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.region-list {
  display: grid;
  gap: 12px;
}

.region-block {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.region-block h3 {
  margin: 0 0 10px;
  font-size: 15px;
}

.city-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.city-button {
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
  background: #fff;
  color: var(--ink);
}

.city-button.active {
  border-color: var(--brand-red);
  background: var(--soft-red);
  color: var(--brand-red);
}

.admin-toolbar {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fafbfc;
}

.admin-panel {
  display: grid;
  gap: var(--space-sm);
}

.admin-toolbar > .segmented {
  flex-wrap: wrap;
  overflow-x: visible;
  padding-bottom: 0;
}

.admin-toolbar > .segmented .segment {
  flex: 1 1 72px;
  min-width: 0;
}

.segmented {
  display: flex;
  gap: 6px;
  overflow-x: auto;
  padding-bottom: 2px;
}

.segment {
  flex: 0 0 auto;
  min-height: 34px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 10px;
  background: var(--surface);
  color: var(--ink);
}

.segment.active {
  background: var(--brand-red);
  color: #fff;
  border-color: var(--brand-red);
}

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

.metric {
  position: relative;
  display: block;
  padding: 10px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
}

.metric strong {
  display: block;
  font-size: 18px;
}

.metric span {
  color: var(--muted);
  font-size: 11px;
}

.metric small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.2;
}

.metric-date {
  cursor: pointer;
}

.metric-date-input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
  opacity: 0;
  cursor: pointer;
}

.admin-region-account-card summary {
  cursor: pointer;
  list-style: none;
}

.admin-region-account-card summary::-webkit-details-marker {
  display: none;
}

.admin-region-account-card summary::after {
  content: "展开";
  color: var(--muted);
  font-size: var(--text-xs);
  font-weight: var(--font-medium);
}

.admin-region-account-card[open] summary::after {
  content: "收起";
}

.admin-country-region-card {
  display: grid;
  gap: var(--space-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-md);
  background: var(--surface);
}

.admin-country-region-head {
  align-items: flex-start;
}

.admin-country-region-head strong {
  color: var(--brand-purple);
}

.admin-country-city-list {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.admin-country-city-row {
  border: 0;
  border-radius: 0;
  padding: var(--space-sm) 0;
  background: transparent;
}

.admin-country-city-row:last-child {
  border-bottom: 0;
}

.admin-region-edit-actions {
  margin-top: var(--space-xs);
}

.admin-inline-edit-form {
  margin-top: var(--space-sm);
  padding-top: var(--space-sm);
  border-top: 1px solid var(--line);
}

.admin-account-row {
  display: grid;
  gap: var(--space-xs);
}

.admin-permission-editor {
  display: grid;
  gap: var(--space-sm);
}

.admin-permission-grid {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-xs);
}

.admin-permission-chip {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  cursor: pointer;
}

.admin-permission-chip input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.admin-permission-chip span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 5px 10px;
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  font-size: var(--text-sm);
  font-weight: 700;
  line-height: 1.1;
  white-space: nowrap;
}

.admin-permission-chip span::before {
  content: "";
  width: 14px;
  height: 14px;
  border: 1px solid currentColor;
  border-radius: 3px;
  margin-right: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
}

.admin-permission-chip input:checked + span {
  border-color: rgba(223, 63, 37, 0.48);
  background: var(--brand-light);
  color: var(--brand);
}

.admin-permission-chip input:checked + span::before {
  content: "✓";
}

.admin-category-row-meta {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}

.admin-category-drag-handle {
  cursor: grab;
  width: 38px;
  padding-inline: 0;
  font-size: 18px;
}

.admin-category-drag-handle:active {
  cursor: grabbing;
}

.admin-category-card {
  position: relative;
}

.admin-category-card.is-dragging {
  opacity: 0.58;
}

.admin-category-card.drag-over-before,
.admin-category-card.drag-over-after {
  border-color: rgba(223, 63, 37, 0.58);
}

.admin-category-card.drag-over-before::before,
.admin-category-card.drag-over-after::after {
  content: "";
  position: absolute;
  left: var(--space-sm);
  right: var(--space-sm);
  height: 3px;
  border-radius: 999px;
  background: var(--brand-red);
}

.admin-category-card.drag-over-before::before {
  top: -2px;
}

.admin-category-card.drag-over-after::after {
  bottom: -2px;
}

.admin-main button,
.admin-main .primary-button,
.admin-main .primary-btn,
.admin-main .secondary-btn,
.admin-main .quiet-button,
.admin-main .segment,
.admin-main .admin-menu-item {
  min-height: 38px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 5px 10px;
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
  box-shadow: none;
  font-size: var(--text-sm);
  font-weight: 700;
  line-height: 1.1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  white-space: nowrap;
}

.admin-main .primary-button,
.admin-main .primary-btn {
  background: var(--brand-red);
  border-color: var(--brand-red);
  color: #fff;
}

.admin-main .secondary-btn,
.admin-main .quiet-button,
.admin-main .segment,
.admin-main .admin-menu-item {
  background: var(--category-chip-bg);
  color: var(--category-chip-fg);
}

.admin-main .segment.active,
.admin-main .admin-menu-item.active {
  background: var(--category-chip-bg);
  color: var(--brand-red);
  border-color: rgba(223, 63, 37, 0.42);
  box-shadow: inset 0 0 0 1px rgba(223, 63, 37, 0.42);
}

.admin-main .admin-menu-list {
  display: grid;
  gap: var(--space-xs);
}

.admin-main .admin-menu-item {
  width: 100%;
  min-height: var(--tap-target);
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  padding: 0 var(--space-md);
  background: transparent;
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--font-medium);
  justify-content: flex-start;
  text-align: left;
}

.admin-main .admin-menu-item.active {
  border-color: var(--line);
  background: var(--brand-light);
  color: var(--brand);
  box-shadow: none;
}

.admin-main .secondary-btn.danger,
.admin-main .danger {
  color: #df3f25;
  border-color: rgba(223, 63, 37, 0.48);
}

.admin-main button:disabled,
.admin-main .secondary-btn:disabled,
.admin-main .primary-button:disabled,
.admin-main .primary-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.admin-main button.is-loading,
.admin-main .primary-button.is-loading,
.admin-main .primary-btn.is-loading,
.admin-main .secondary-btn.is-loading {
  opacity: 0.72;
  cursor: progress;
}

.admin-main form.is-dirty button[type="submit"]:not(.is-loading):not(.is-saved),
.admin-main button.is-dirty:not(.is-loading):not(.is-saved) {
  background: var(--brand-red);
  border-color: var(--brand-red);
  color: #fff;
}

.admin-main button.is-saved {
  background: #168a4a;
  border-color: #168a4a;
  color: #fff;
}

.admin-main button.is-submit-error {
  background: var(--brand-red);
  border-color: var(--brand-red);
  color: #fff;
}

.admin-main .btn-spinner {
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  display: inline-block;
  flex: 0 0 auto;
  animation: btn-spin 0.7s linear infinite;
}

.admin-empty-admins {
  color: var(--muted);
}

.admin-table-actions-menu {
  align-self: center;
  justify-content: flex-start;
  transform: none;
  overflow: visible;
}

.admin-table-action-popover {
  min-width: 132px;
}

.admin-main .admin-table-action-popover button {
  width: 100%;
  min-height: 36px;
  border: 0;
  padding: 0 10px;
  background: transparent;
  color: var(--ink);
  justify-content: flex-start;
  text-align: left;
}

.admin-main .admin-table-action-popover button.danger {
  color: var(--brand-red);
}

.admin-main .admin-table-action-popover button:active {
  background: var(--soft-red);
  color: var(--brand-red);
}


.admin-post-list {
  display: grid;
  gap: var(--space-sm);
}

.admin-post-row {
  display: grid;
  gap: var(--space-sm);
  padding: var(--space-md);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.admin-post-summary {
  display: grid;
  gap: var(--space-xs);
  min-width: 0;
}

.admin-post-title {
  margin: 0;
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
  line-height: var(--line-height);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-post-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-sm);
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height);
}

.admin-post-meta span {
  display: inline-flex;
  align-items: center;
  min-width: 0;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.admin-actions button {
  min-height: 34px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: var(--surface);
  padding: 0 10px;
  color: var(--ink);
}

.admin-filter-toolbar {
  align-items: stretch;
}

.admin-bulk-actions,
.admin-row-actions,
.admin-row-head,
.admin-color-preview {
  display: flex;
  align-items: center;
  gap: 8px;
}

.admin-bulk-actions,
.admin-row-head {
  justify-content: space-between;
  flex-wrap: wrap;
}

.admin-color-preview {
  min-height: 34px;
  color: var(--muted);
  font-size: var(--text-sm);
}

.admin-category-language-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: var(--space-md);
}

@media (max-width: 640px) {
  .admin-category-language-grid {
    grid-template-columns: 1fr;
  }
}

.admin-table {
  display: grid;
  gap: 6px;
  overflow-x: auto;
}

.admin-table-row {
  display: grid;
  grid-template-columns: minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(170px, 1fr);
  gap: 8px;
  min-width: 920px;
  align-items: center;
  padding: 10px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  color: var(--ink);
  font-size: var(--text-sm);
}

.admin-table-row > span {
  min-width: 0;
}

.admin-table-row:has(input[type="checkbox"]) {
  grid-template-columns: 44px minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(170px, 1fr);
}

.admin-table-row.admin-table-row-selectable {
  grid-template-columns: minmax(76px, .5fr) minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(170px, 1fr);
}

.admin-table-row.admin-table-row-selectable:has(input[type="checkbox"]) {
  grid-template-columns: minmax(76px, .5fr) minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(170px, 1fr);
}

.admin-table-row.admin-table-row-hot {
  grid-template-columns: minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 980px;
}

.admin-table-row-hot.admin-table-row-no-actions {
  grid-template-columns: minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr);
  min-width: 840px;
}

.admin-table-row-hot .admin-row-actions {
  justify-self: end;
  flex-wrap: nowrap;
}

.admin-table-row-no-region {
  grid-template-columns: minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 760px;
}

.admin-table-row-no-region.admin-table-row-hot {
  grid-template-columns: minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 820px;
}

.admin-table-row-no-region.admin-table-row-hot.admin-table-row-no-actions {
  grid-template-columns: minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr);
  min-width: 700px;
}

.admin-table-row-no-region:has(input[type="checkbox"]) {
  grid-template-columns: 44px minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 800px;
}

.admin-table-row-no-region.admin-table-row-selectable {
  grid-template-columns: minmax(76px, .5fr) minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 832px;
}

.admin-table-row-no-region.admin-table-row-selectable:has(input[type="checkbox"]) {
  grid-template-columns: minmax(76px, .5fr) minmax(180px, 1.6fr) minmax(88px, .8fr) minmax(96px, .8fr) minmax(58px, .5fr) minmax(58px, .5fr) minmax(72px, .6fr) minmax(132px, .8fr);
  min-width: 832px;
}

.admin-select-all-btn.is-selected {
  color: var(--brand-red);
  border-color: rgba(223, 63, 37, 0.42);
  box-shadow: inset 0 0 0 1px rgba(223, 63, 37, 0.42);
}

.admin-table-head {
  background: var(--admin-table-head);
  color: var(--muted);
  font-weight: 700;
}

.admin-table-title {
  display: block;
  width: 100%;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-align: left;
}

.admin-table-title small {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-table-title-link {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-weight: inherit;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.admin-main .admin-table-title-link {
  display: block;
  width: 100%;
  min-width: 0;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: inherit;
  text-align: left;
  justify-content: flex-start;
}

.admin-table-title-link:hover {
  color: var(--brand-red);
}

.admin-ads-table .admin-table-row {
  grid-template-columns: minmax(110px, 1fr) minmax(160px, 1.5fr) minmax(96px, .8fr) minmax(96px, .8fr) minmax(64px, .6fr) minmax(140px, 1fr);
  min-width: 760px;
}

.admin-traffic-table .admin-table-row {
  grid-template-columns: minmax(150px, 1.3fr) repeat(5, minmax(70px, .7fr));
  min-width: 560px;
}

@media (min-width: 900px) {
  .app.admin-app {
    width: min(calc(100% - 48px), 1180px);
    max-width: 1180px;
    padding-bottom: var(--space-2xl);
    overflow-x: visible;
  }

  .app.admin-app .admin-main {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-lg) var(--space-xl);
    align-items: flex-start;
  }

  .app.admin-app .admin-shell-header {
    flex: 0 0 100%;
    margin: 0 0 var(--space-lg);
    padding: env(safe-area-inset-top, 0px) var(--space-lg) 0;
    border: 1px solid var(--line);
    border-top: 0;
    border-radius: 0 0 var(--radius-md) var(--radius-md);
  }

  .app.admin-app .admin-menu-button {
    visibility: hidden;
    pointer-events: none;
  }

  .app.admin-app .admin-menu-scrim {
    display: none;
  }

  .app.admin-app .admin-menu-drawer {
    position: sticky;
    top: calc(var(--admin-shell-h) + var(--space-lg));
    flex: 0 0 260px;
    width: 260px;
    max-width: none;
    height: calc(100vh - var(--admin-shell-h) - var(--space-2xl));
    overflow-y: auto;
    padding: var(--space-lg) var(--space-md);
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    box-shadow: none;
    transform: none;
    transition: none;
  }

  .app.admin-app .admin-content {
    flex: 1 1 0;
    min-width: 0;
  }

  .app.admin-app .admin-page-header {
    padding-top: 0;
  }

  .app.admin-app .admin-table-row,
  .app.admin-app .admin-ads-table .admin-table-row,
  .app.admin-app .admin-traffic-table .admin-table-row {
    min-width: 0;
  }

  .app.admin-app .admin-table-row.admin-table-row-hot {
    min-width: 980px;
  }

  .app.admin-app .admin-table-row.admin-table-row-hot.admin-table-row-no-actions {
    min-width: 0;
  }

  .app.admin-app .admin-table {
    overflow-x: visible;
  }

  .app.admin-app .admin-table:has(.admin-table-row-hot) {
    overflow-x: auto;
  }
}

@media (min-width: 900px) {
  .app:not(.admin-app) {
    width: 100%;
    max-width: none;
    padding: 64px 320px 40px 232px;
    background: var(--page);
    overflow-x: visible;
  }

  .app:not(.admin-app).no-topbar {
    padding-top: 0;
  }

  .app:not(.admin-app) .topbar {
    left: 232px;
    right: 320px;
    width: auto;
    transform: none;
    grid-template-columns: minmax(0, 1fr) auto;
    padding: 9px 24px;
    border-left: 1px solid var(--line);
    border-right: 1px solid var(--line);
  }

  .app:not(.admin-app) .topbar.topbar-hidden {
    transform: translateY(-110%);
  }

  .app:not(.admin-app) .topbar .brand {
    visibility: hidden;
  }

  .app:not(.admin-app) .main {
    width: min(100%, 820px);
    margin: 0 auto;
    padding: 20px 0 56px;
  }

  .app:not(.admin-app) .bottom-nav {
    display: none;
  }

  .desktop-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: calc(var(--z-popover) + 8);
    width: 216px;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 18px 14px 24px;
    border-right: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
  }

  .desktop-sidebar-brand {
    width: 100%;
    min-height: 42px;
    justify-content: flex-start;
    padding: 0 8px;
  }

  .desktop-sidebar-brand picture {
    display: flex;
  }

  .desktop-sidebar-brand img {
    width: 122px;
    max-height: 38px;
    object-fit: contain;
  }

  .desktop-nav {
    display: grid;
    gap: 8px;
  }

  .desktop-sidebar-account {
    margin-top: auto;
    display: grid;
    gap: 10px;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
  }

  .desktop-sidebar-account-head {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 10px;
  }

  .desktop-sidebar-account-text {
    min-width: 0;
    display: grid;
    gap: 2px;
  }

  .desktop-sidebar-avatar {
    width: 40px;
    height: 40px;
    flex-basis: 40px;
    border: 1px solid var(--line);
  }

  .desktop-sidebar-account strong {
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 15px;
  }

  .desktop-nav-button {
    position: relative;
    width: 100%;
    min-height: 46px;
    border: 0;
    border-radius: var(--radius);
    padding: 0 12px;
    background: transparent;
    color: var(--muted);
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    text-align: left;
    font-size: 15px;
    font-weight: 800;
  }

  .desktop-nav-button.active {
    color: var(--brand-red);
    background: rgba(223, 63, 37, 0.08);
  }

  .desktop-nav-button.primary {
    margin: 8px 0;
    min-height: 52px;
    color: #fff;
    background: var(--brand-red);
    box-shadow: 0 8px 18px rgba(223, 63, 37, 0.24);
  }

  .desktop-nav-button.primary.active {
    color: #fff;
    background: var(--brand-red);
  }

  .desktop-nav-button .nav-icon {
    width: 23px;
    height: 23px;
  }

  .desktop-nav-badge {
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--brand-red);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    line-height: 1;
  }

  .desktop-right-rail {
    position: fixed;
    inset: 0 0 0 auto;
    z-index: calc(var(--z-popover) + 6);
    width: 304px;
    display: grid;
    align-content: start;
    gap: 14px;
    padding: 72px 18px 24px;
    border-left: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.86);
    overflow-y: auto;
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
  }

  .desktop-rail-card {
    display: grid;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
  }

  .desktop-rail-kicker,
  .desktop-rail-head {
    color: var(--muted);
    font-size: 12px;
    font-weight: 800;
  }

  .desktop-rail-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }

  .desktop-region-current {
    width: 100%;
    border: 0;
    padding: 0;
    background: transparent;
    color: var(--ink);
    text-align: left;
    font-size: 17px;
    font-weight: 900;
  }

  .desktop-category-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
  }

  .desktop-category-chip {
    min-height: 34px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 0 10px;
    background: var(--category-chip-bg);
    color: var(--category-chip-fg);
    display: inline-flex;
    align-items: center;
    gap: 7px;
    font-weight: 800;
  }

  .desktop-category-chip.active {
    color: var(--brand-red);
    box-shadow: inset 0 0 0 1px rgba(223, 63, 37, 0.42);
  }

  .desktop-latest-list {
    display: grid;
    gap: 4px;
  }

  .desktop-latest-item {
    width: 100%;
    border: 0;
    border-radius: var(--radius-sm);
    padding: 9px 8px;
    background: transparent;
    color: var(--ink);
    display: grid;
    gap: 3px;
    text-align: left;
  }

  .desktop-latest-item:hover,
  .desktop-latest-item:focus-visible {
    background: var(--category-chip-bg);
  }

  .desktop-latest-title {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    font-weight: 850;
  }

  .desktop-latest-meta,
  .desktop-rail-empty {
    color: var(--muted);
    font-size: 12px;
    line-height: 1.45;
  }

  .desktop-account-card strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 16px;
  }

  .desktop-account-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
  }

  .desktop-primary-action,
  .desktop-secondary-action {
    min-height: 34px;
    border-radius: var(--radius);
    padding: 0 12px;
    font-weight: 850;
  }

  .desktop-primary-action {
    border: 0;
    background: var(--brand-red);
    color: #fff;
  }

  .desktop-secondary-action {
    border: 1px solid var(--line);
    background: var(--category-chip-bg);
    color: var(--ink);
  }

  .app:not(.admin-app) .search-page-panel {
    top: 64px;
    left: calc(232px + ((100vw - 552px) / 2));
    width: min(820px, calc(100vw - 600px));
  }

  .app:not(.admin-app) .floating-back {
    right: 340px;
    bottom: 32px;
  }

  .app:not(.admin-app) .toast {
    left: calc(232px + ((100vw - 552px) / 2));
    transform: translateX(-50%);
  }
}

@media (min-width: 1240px) {
  .app:not(.admin-app) {
    padding-left: 260px;
    padding-right: 344px;
  }

  .app:not(.admin-app) .topbar {
    left: 260px;
    right: 344px;
  }

  .desktop-sidebar {
    width: 240px;
    padding-left: 18px;
    padding-right: 18px;
  }

  .desktop-right-rail {
    width: 328px;
  }

  .app:not(.admin-app) .search-page-panel,
  .app:not(.admin-app) .toast {
    left: calc(260px + ((100vw - 604px) / 2));
  }

  .app:not(.admin-app) .floating-back {
    right: 368px;
  }
}

.secondary-btn.danger,
.admin-actions .danger {
  color: var(--brand-red);
  border-color: rgba(223, 63, 37, 0.35);
}

.edit-panel {
  border: 1px solid rgba(223, 63, 37, 0.28);
  background: #fffaf9;
  border-radius: var(--radius);
  padding: 12px;
  margin-bottom: 12px;
}

.permission-list {
  display: grid;
  gap: 8px;
}

.my-main .my-tabs + .permission-list {
  margin-top: 18px;
}

.my-main .permission-list {
  gap: 16px;
}

.permission-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: var(--space-md);
  background: #fff;
}

.admin-category-card {
  display: grid;
  gap: var(--space-xs);
}

.admin-category-card strong {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
}

.admin-category-card p,
.admin-category-card span {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-sm);
}

.admin-user-list {
  display: grid;
  gap: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: visible;
  background: var(--surface);
}

.admin-user-table-head {
  display: grid;
  grid-template-columns: minmax(220px, 1.35fr) minmax(120px, 0.75fr) minmax(120px, 0.8fr) minmax(84px, auto);
  align-items: center;
  gap: var(--space-md);
  padding: var(--space-sm) var(--space-md);
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  border-bottom: 1px solid var(--line);
  background: var(--chip-bg);
}

.admin-user-table-head.has-region {
  grid-template-columns: minmax(220px, 1.25fr) minmax(150px, 0.85fr) minmax(120px, 0.7fr) minmax(120px, 0.75fr) minmax(84px, auto);
}

.admin-user-table-head span:last-child {
  justify-self: end;
}

.admin-user-row {
  display: grid;
  grid-template-columns: minmax(220px, 1.35fr) minmax(120px, 0.75fr) minmax(120px, 0.8fr) minmax(84px, auto);
  align-items: center;
  gap: var(--space-md);
  min-height: 50px;
  padding: 8px var(--space-md);
  border-bottom: 1px solid var(--line);
}

.admin-user-row.has-region {
  grid-template-columns: minmax(220px, 1.25fr) minmax(150px, 0.85fr) minmax(120px, 0.7fr) minmax(120px, 0.75fr) minmax(84px, auto);
}

.admin-user-row:last-child {
  border-bottom: 0;
}

.admin-user-main,
.admin-user-main strong {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  min-width: 0;
}

.admin-user-main {
  flex-wrap: wrap;
}

.admin-user-main strong,
.admin-user-main span,
.admin-user-region,
.admin-user-joined,
.admin-user-status span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.admin-user-region,
.admin-user-joined {
  color: var(--muted);
}

.admin-user-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  min-width: 0;
  margin: 0;
  color: var(--muted);
}

.admin-user-normal-status {
  color: var(--muted);
}

.admin-user-avatar {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  object-fit: cover;
  background: var(--chip-bg);
  color: var(--ink);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

.admin-user-action-menu {
  justify-self: end;
  align-self: center;
  transform: translateY(2px);
}

.admin-user-action-menu.open {
  position: relative;
  z-index: 110;
}

.admin-user-action-menu .post-action-popover {
  z-index: 111;
}

@media (max-width: 760px) {
  .admin-user-table-head {
    display: none;
  }

  .admin-user-row {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .admin-user-action-menu {
    justify-self: start;
  }
}

.admin-category-swatch {
  width: 12px;
  height: 12px;
  border-radius: var(--radius-sm);
  flex: 0 0 12px;
}

.permission-card-title {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

.permission-card-title.with-red-bar::before {
  content: "";
  width: 3px;
  height: 14px;
  border-radius: var(--radius);
  background: var(--brand-red);
  flex: 0 0 3px;
}

.permission-contact-actions {
  margin-top: 0;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-xs);
}

.permission-contact-row {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  min-height: var(--contact-row-compact-h);
  min-width: 0;
  color: var(--ink);
}

.permission-contact-row .contact-action {
  width: var(--icon-lg);
  height: var(--icon-lg);
  min-height: var(--icon-lg);
  border: 0;
  border-radius: 0;
  background: transparent;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 var(--icon-lg);
  padding: 0;
}

.permission-contact-row .contact-action .contact-icon {
  width: var(--icon-md);
  height: var(--icon-md);
  margin: 0;
}

.permission-contact-value {
  min-width: 0;
  overflow-wrap: anywhere;
  display: flex;
  align-items: center;
  min-height: var(--contact-row-compact-h);
  font-size: var(--text-md);
  line-height: var(--line-height-tight);
}

.my-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 6px;
  margin: 12px 0 6px;
}

.my-tab {
  min-height: 70px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #fff;
  color: #4a4f58;
  font-size: 13px;
  font-weight: 800;
  padding: 7px 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.my-tab.active {
  color: #fff;
  border-color: var(--brand-red);
  background: var(--brand-red);
}

.my-tab-icon {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.my-intro-panel .post-body {
  white-space: pre-wrap;
  margin: 0;
}

.my-intro-panel {
  margin-bottom: 12px;
}

.my-owned-row .feed-category-pill,
.my-owned-row .region-pill {
  min-height: 22px;
  padding: 0 7px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  align-items: center;
}

.my-feed {
  gap: 0;
}

.my-owned-row {
  display: grid;
  gap: var(--space-sm);
  padding: var(--space-md) var(--page-x);
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
}

.my-owned-row-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-sm);
}

.my-owned-status {
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
}

.my-owned-status.ended {
  color: var(--muted);
}

.my-owned-menu {
  transform: none;
  margin-top: calc(-1 * var(--space-sm));
  margin-right: 0;
}

.my-owned-menu .post-action-popover {
  min-width: 132px;
}

.my-owned-delete-action {
  color: var(--brand-red) !important;
}

.my-owned-row-main {
  display: grid;
  grid-template-columns: 96px minmax(0, 1fr);
  gap: var(--space-md);
  align-items: stretch;
}

.my-owned-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 96px;
  aspect-ratio: var(--ratio-square);
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--category-chip-bg);
  color: var(--muted);
  font-size: var(--text-sm);
}

.my-owned-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.my-owned-content {
  min-width: 0;
  display: grid;
  grid-template-rows: auto auto 1fr;
  gap: var(--space-xs);
}

.my-owned-title {
  display: block;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: clip;
  font-size: var(--text-xl);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
}

.my-owned-meta {
  justify-content: flex-start;
  flex-wrap: nowrap;
  gap: var(--space-xs);
  min-width: 0;
  margin-top: 0;
  overflow: hidden;
}

.my-owned-meta .post-time {
  flex: 0 0 auto;
}

.my-owned-bottom-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--space-sm);
  align-self: end;
  min-width: 0;
}

.my-owned-info-row {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex: 1 1 auto;
  flex-wrap: nowrap;
  gap: var(--space-xs);
  min-width: 0;
  margin-top: 0;
}

.my-owned-price {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: var(--text-lg);
}

.my-owned-price-spacer {
  flex: 0 1 auto;
  min-width: 0;
}

.my-owned-favorites {
  color: var(--muted);
}

.my-owned-favorites .favorite-icon {
  width: 16px;
  height: 16px;
}

.bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 30;
  width: min(100%, 480px);
  transform: translateX(-50%);
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2px;
  padding: 4px 8px max(4px, env(safe-area-inset-bottom));
  background: rgba(255, 255, 255, 0.88);
  border-top: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.nav-button {
  position: relative;
  min-height: 48px;
  border: 0;
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  padding: 3px 2px;
  line-height: 1.1;
}

.nav-button.active {
  color: var(--brand-red);
  background: rgba(223, 63, 37, 0.08);
}

.nav-button-primary {
  min-height: 58px;
  margin-top: -12px;
  border-radius: var(--radius);
  background: var(--brand-red);
  color: #fff;
  box-shadow: 0 8px 18px rgba(223, 63, 37, 0.28);
}

.nav-button-primary.active {
  background: var(--brand-red);
  color: #fff;
}

.nav-icon {
  display: block;
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.1;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

.nav-profile-avatar {
  width: 24px;
  height: 24px;
  flex-basis: 24px;
  border: 1px solid var(--line);
  font-size: 11px;
  font-weight: 900;
}

.nav-profile-avatar.active {
  border-color: var(--brand-red);
  box-shadow: 0 0 0 2px rgba(223, 63, 37, 0.16);
}

.nav-icon-solid {
  fill: currentColor;
  stroke: none;
}

.nav-icon-cutout {
  fill: none;
  stroke: #fff;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.nav-label {
  display: block;
  font-size: 11px;
}

.nav-unread-badge {
  position: absolute;
  top: 4px;
  right: 22%;
  min-width: 17px;
  height: 17px;
  padding: 0 5px;
  border-radius: 999px;
  background: var(--brand-red);
  color: #fff;
  border: 2px solid var(--surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 10px;
  font-weight: 900;
  line-height: 1;
}

.nav-button-primary .nav-icon {
  width: 28px;
  height: 28px;
}

.floating-back {
  position: fixed;
  right: max(16px, calc((100vw - 480px) / 2 + 16px));
  bottom: calc(156px + env(safe-area-inset-bottom));
  z-index: calc(var(--z-popover) + 4);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #fff;
  background: rgba(223, 63, 37, 0.52);
  appearance: none;
  -webkit-appearance: none;
  box-shadow: none;
}

.floating-back-icon {
  display: block;
  width: 28px;
  height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.image-lightbox + .floating-back,
.admin-view ~ .floating-back {
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 60;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 76px;
  z-index: 40;
  width: min(calc(100% - 32px), 448px);
  transform: translateX(-50%);
  border-radius: var(--radius);
  padding: 12px 14px;
  color: #fff;
  background: #22252a;
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

.announcement-popup {
  position: fixed;
  inset: 0;
  z-index: 45;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 18, 24, 0.42);
}

.announcement-card {
  width: min(420px, 100%);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 16px;
  background: var(--surface);
  color: var(--ink);
  box-shadow: 0 18px 50px rgba(15, 18, 24, 0.24);
}

.announcement-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.announcement-head strong {
  font-size: var(--text-md);
}

.announcement-card p {
  margin: 0;
  color: var(--muted);
  line-height: var(--line-height);
  white-space: pre-wrap;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #f2f4f7;
    --muted: #a9b0bb;
    --line: #303640;
    --page: #0f1115;
    --surface: #171b21;
    --admin-table-head: #252b34;
    --soft-red: rgba(223, 63, 37, 0.16);
    --category-chip-bg: #252b34;
    --category-chip-fg: #c7ccd5;
    --image-placeholder: #252b34;
  }

  body {
    color: var(--ink);
    background: var(--page);
  }

  .app {
    background: var(--surface);
  }

  .topbar {
    background: rgba(23, 27, 33, 0.82);
  }

  .bottom-nav {
    background: rgba(23, 27, 33, 0.84);
  }

  .desktop-sidebar,
  .desktop-right-rail {
    background: rgba(23, 27, 33, 0.88);
  }

  .top-region-button,
  .language-picker,
  .language-select,
  .compact-select,
  .period-option span,
  .ai-fill-button,
  .contact-type-wheel,
  .search-box,
  .search-history-chip,
  .post-card,
  .sortable-image-card,
  .image-upload-button,
  .admin-menu-button,
  .admin-menu-drawer,
  .admin-placeholder-panel,
  .icon-action,
  .inline-action,
  .contact-action,
  .region-chip,
  .city-button,
  .segment,
  .metric,
  .admin-shell-header,
  .admin-actions button,
  .icon-remove-button,
  .my-tab,
  .permission-card,
  .field input,
  .field select,
  .field textarea {
    background-color: #1d222a;
    color: var(--ink);
    border-color: var(--line);
    color-scheme: dark;
  }

  .post-card.pinned-card,
  .feed .feed-post-card.pinned-card,
  .edit-panel,
  .admin-toolbar,
  .empty-state,
  .danger-button {
    background: #211d1d;
  }

  .post-body,
  .post-body-button,
  .check-row,
  .field label {
    color: #d3d7df;
  }

  .pill,
  .status-pill,
  .ghost-button,
  .contact-action.disabled {
    background: #252b34;
    color: #c7ccd5;
  }

  .city-button.active {
    background: rgba(223, 63, 37, 0.18);
  }

  .share-button,
  .favorite-button,
  .inline-action {
    color: #c7ccd5;
  }

  .favorite-button.active {
    color: var(--brand-red);
    border-color: transparent;
    background: transparent;
  }

  .inline-action[data-action="report-post"] {
    color: #f08a79;
    border-color: rgba(240, 138, 121, 0.38);
  }

  .translate-button,
  .feed-translate-button {
    color: var(--brand-blue);
    border-color: rgba(74, 163, 223, 0.42);
  }

  .contact-row-action {
    background-color: #1d222a;
    color: var(--brand-red);
    border-color: var(--line);
  }

  .category-wheel-shell::before {
    background: linear-gradient(90deg, var(--surface), rgba(23, 27, 33, 0));
  }

  .category-wheel-shell::after {
    background: linear-gradient(270deg, var(--surface), rgba(23, 27, 33, 0));
  }

}

.translate-row,
.feed-translate-row {
  display: flex;
  justify-content: flex-start;
  margin: 6px 0 10px;
}

.feed-translate-row {
  margin: 4px 0 0;
}

.feed-title-meta .feed-translate-row {
  display: inline-flex;
  align-items: center;
  margin: 0;
  line-height: inherit;
  vertical-align: baseline;
}

.feed-title-meta .feed-translate-button {
  font-size: inherit;
  line-height: inherit;
}

.translate-button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--brand-blue);
  background: transparent;
  border: 0;
  border-radius: var(--radius);
  cursor: pointer;
  transition: opacity 0.15s;
}

.translate-button:hover {
  opacity: 0.72;
}

.translate-button--dim {
  color: var(--muted);
}

.translate-button:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.region-search-panel {
  padding: 0 16px 12px;
}

.region-search-title {
  margin-bottom: 8px;
}

.region-block-flat {
  padding: 12px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
}

.region-block-flat:first-child {
  border-top: 1px solid var(--line);
}

.region-block-flat h3 {
  padding: 0 16px;
  margin-bottom: 6px;
  color: var(--muted);
}

.city-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 0 16px;
}

.city-row,
body.dark .city-row {
  width: auto;
  min-height: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 12px;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.city-row[hidden],
.region-block-flat[hidden] {
  display: none !important;
}

.city-row small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.city-row.active,
body.dark .city-row.active {
  background: transparent;
  color: var(--brand-red);
}

.category-wheel-shell {
  padding-top: 13px;
}

.category-wheel-marker {
  position: absolute;
  top: 2px;
  left: 50%;
  z-index: 3;
  width: 0;
  height: 0;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 7px solid var(--brand-red);
  opacity: 0.96;
  pointer-events: none;
}

.body-field textarea {
  min-height: 174px;
}

.detail-price-row {
  margin: 2px 0 0;
  gap: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.detail-price {
  font-size: 20px;
  font-weight: 900;
  line-height: 1.25;
}

.detail-body {
  margin-top: 10px !important;
}

.detail-card .detail-body {
  white-space: normal;
}

.detail-body-paragraph {
  margin: 0 0 14px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.detail-body-paragraph:last-child {
  margin-bottom: 0;
}

.detail-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
}

.detail-contact-side {
  min-width: 0;
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: var(--space-sm);
}

.detail-contact-side .contact-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  gap: var(--space-sm);
  margin-top: 0;
}

.detail-contact-side .contact-action {
  flex: 0 0 var(--tap-target);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.detail-contact-side .contact-action .contact-icon {
  width: var(--icon-lg);
  height: var(--icon-lg);
  margin: 0;
}

.detail-local-time {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap-target);
  color: var(--muted);
  font-size: var(--text-sm);
  font-weight: var(--font-semibold);
  line-height: var(--line-height-tight);
  white-space: nowrap;
}

.detail-section-label {
  display: none;
}

.detail-stat-side {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

.detail-stat-side .post-actions {
  display: inline-flex;
}

.detail-stat-side .stat-item,
.detail-stat-side .stat-count {
  font-size: 13px;
  font-weight: 400;
  line-height: 1.35;
}

.detail-edit-actions {
  margin-top: 14px;
}

.my-main,
.owner-edit-main {
  padding-bottom: var(--page-bottom-compact);
}

.my-footer-links {
  margin: 20px 16px 0;
  text-align: center;
  color: var(--muted);
  font-size: var(--text-xs);
  line-height: 1.4;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.my-footer-links a {
  color: var(--muted);
  text-decoration: none;
}

.my-footer-links a:active {
  color: var(--accent);
}

.privacy-main {
  padding: 16px;
  padding-bottom: calc(var(--page-bottom-compact) + 18px);
}

.privacy-panel {
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  padding: 18px 16px;
}

.privacy-panel h1 {
  margin: 0 0 14px;
  font-size: var(--text-xl);
  line-height: 1.25;
}

.privacy-policy-text {
  margin: 0;
  color: var(--ink);
  user-select: none;
  -webkit-user-select: none;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-family: inherit;
  font-size: var(--text-sm);
  line-height: 1.72;
}

.cookie-consent {
  position: fixed;
  right: 16px;
  bottom: calc(86px + env(safe-area-inset-bottom));
  left: 16px;
  z-index: calc(var(--z-popover) + 3);
  max-width: 560px;
  margin: 0 auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.28);
  padding: 14px;
  backdrop-filter: blur(12px);
  pointer-events: none;
}

.cookie-consent-copy h2 {
  margin: 0 0 8px;
  font-size: var(--text-md);
  line-height: 1.3;
}

.cookie-consent-copy p {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: 1.5;
}

.cookie-consent-copy a {
  color: var(--accent);
  font-size: var(--text-sm);
  font-weight: 800;
  text-decoration: none;
  pointer-events: auto;
}

.cookie-consent-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.cookie-consent-actions button {
  min-height: 44px;
  padding-right: 10px;
  padding-left: 10px;
  pointer-events: auto;
}

.owner-edit-main > .admin-actions {
  margin-right: 16px;
  margin-left: 16px;
}

.related-posts {
  padding-bottom: 16px;
}

.related-posts > .section-title {
  margin-right: var(--page-x);
  margin-left: var(--page-x);
}

.detail-ad-slot {
  width: min(100%, 720px);
  box-sizing: border-box;
  margin: 14px auto 0;
  padding: 0 var(--page-x);
  background: transparent;
}

.detail-ad-slot .adsbygoogle {
  display: block;
  width: 100%;
  min-height: 120px;
  background: transparent !important;
}

.detail-ad-slot iframe {
  background: transparent !important;
}

ins.adsbygoogle[data-ad-status="unfilled"],
ins.adsbygoogle[data-ad-status="unfill-optimized"] {
  display: none !important;
  min-height: 0 !important;
  height: 0 !important;
}

.detail-ad-slot-inline {
  width: 100%;
  margin: 12px 0;
  padding: 0;
  max-height: 40px;
  overflow: hidden;
}

.detail-ad-slot-inline .adsbygoogle {
  min-height: 40px;
  height: 40px !important;
  max-height: 40px !important;
  overflow: hidden;
}

.detail-ad-slot-inline iframe {
  min-height: 0 !important;
  height: 40px !important;
  max-height: 40px !important;
}

.detail-ad-slot-bottom {
  padding-bottom: calc(108px + env(safe-area-inset-bottom));
}

.related-feed {
  margin-top: 0;
}

.detail-card .post-top {
  align-items: flex-start;
  margin: 6px 0;
}

.detail-info-row {
  margin: 2px 0 2px;
  font-size: 13px;
  align-items: center;
}

.detail-info-row .post-time,
.detail-info-row .detail-address {
  font-size: 13px;
  line-height: 1.35;
}

.detail-category-pill {
  min-height: 24px;
  padding: 3px 7px;
  border: 0;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
}

.detail-inline-translate {
  font-size: 13px;
  line-height: 1.35;
}

.detail-price-main {
  min-width: 0;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}

.detail-owner-edit {
  flex: 0 0 auto;
}

.contact-action[data-contact-type="phone"],
.contact-action[data-contact-type="whatsapp"] {
  color: #25d366;
}

.contact-action[data-contact-type="wechat"] {
  color: #07c160;
}

.contact-action[data-contact-type="telegram"] {
  color: #229ed9;
}

.contact-action[data-contact-type="email"] {
  color: #ea4335;
}

.permission-contact-row .contact-action[data-contact-type] {
  color: var(--muted);
}

.permission-contact-row .contact-action[data-contact-type="phone"],
.permission-contact-row .contact-action[data-contact-type="whatsapp"] {
  color: #25d366;
}

.permission-contact-row .contact-action[data-contact-type="wechat"] {
  color: #07c160;
}

.permission-contact-row .contact-action[data-contact-type="telegram"] {
  color: #229ed9;
}

.permission-contact-row .contact-action[data-contact-type="email"] {
  color: #ea4335;
}

.permission-contact-row .contact-action:active {
  color: var(--brand-red);
}

.related-title {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  color: var(--muted);
}

.related-title::before {
  content: "";
  width: 3px;
  height: 18px;
  border-radius: var(--radius);
  background: var(--brand-red);
  flex: 0 0 3px;
}

.compact-form > .primary-button {
  margin-top: 12px;
}

.owner-action-button.publishing,
.ghost-button.publishing,
.danger-button.publishing {
  opacity: 0.72;
  cursor: not-allowed;
}

.owner-action-button.publishing::after,
.ghost-button.publishing::after,
.danger-button.publishing::after {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  margin-left: 8px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: btn-spin 0.7s linear infinite;
  vertical-align: middle;
}

.owner-password-layer {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.owner-password-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(12, 15, 20, 0.38);
}

.owner-password-dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 360px);
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 18px 48px rgba(10, 14, 20, 0.28);
}

.owner-password-input {
  width: 100%;
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0 12px;
  color: var(--ink);
  background: var(--surface);
}

.owner-password-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.owner-password-actions .primary-button,
.owner-password-actions .quiet-button {
  min-height: 38px;
}

@media (max-width: 640px) {
  .lightbox-counter {
    bottom: calc(118px + env(safe-area-inset-bottom));
  }
}

.more-button,
.more-button:hover,
.more-button:focus,
.more-button:active {
  border: 0;
  background: transparent;
  box-shadow: none;
}

.price,
.detail-price,
.detail-price-main {
  font-weight: 800 !important;
}

.local-ad-section {
  padding: 0 var(--page-x) var(--space-md);
}

.local-ad-strip {
  display: flex;
  gap: var(--space-md);
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.local-ad-strip::-webkit-scrollbar {
  display: none;
}

.local-ad-card {
  flex: 0 0 100%;
  min-height: var(--tap-target);
  border: 0;
  border-radius: var(--radius-md);
  padding: 0;
  overflow: hidden;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  scroll-snap-align: start;
  aspect-ratio: var(--ratio-local-ad);
}

.local-ad-card img {
  width: 100%;
  aspect-ratio: var(--ratio-local-ad);
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: center;
}

.detail-related-ad-section {
  padding: 0 var(--page-x) var(--space-md);
}

.detail-ad-strip {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.detail-ad-strip::-webkit-scrollbar {
  display: none;
}

.detail-ad-list {
  display: grid;
  gap: 10px;
}

.detail-ad-list-carousel {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.detail-ad-list-carousel::-webkit-scrollbar {
  display: none;
}

.detail-ad-list-item {
  width: 100%;
  flex: 0 0 100%;
  border: 0;
  border-bottom: 1px solid var(--line);
  padding: 0 0 12px;
  background: transparent;
  color: var(--ink);
  display: grid;
  grid-template-columns: minmax(96px, 30%) 1fr;
  align-items: center;
  gap: 12px;
  text-align: left;
  scroll-snap-align: start;
}

.detail-ad-list-image {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 8px;
  background: var(--surface);
}

.detail-ad-list-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.detail-ad-list-content {
  min-width: 0;
  display: grid;
  align-content: center;
  gap: 5px;
  padding-top: 2px;
}

.detail-ad-list-title {
  color: var(--ink);
  font-size: clamp(15px, 4.1vw, 19px);
  font-weight: 700;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-ad-list-meta {
  min-width: 0;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.35;
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.detail-ad-list-category {
  color: var(--category-color, var(--brand-blue));
  font-weight: 700;
}

.detail-ad-list-price {
  color: var(--ink);
  font-size: 15.5px;
  font-weight: 900;
  line-height: 1.2;
}

.detail-ad-card {
  flex: 0 0 31%;
  min-width: 102px;
  max-width: 150px;
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--ink);
  text-align: left;
  display: grid;
  gap: 6px;
  scroll-snap-align: start;
}

.detail-ad-image {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: 8px;
  background: var(--surface);
}

.detail-ad-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.detail-ad-badge {
  position: absolute;
  right: 4px;
  bottom: 4px;
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(18, 20, 26, 0.72);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 1.2;
}

.detail-ad-title {
  min-height: 2.7em;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.detail-ad-price {
  color: var(--ink);
  font-size: 13px;
  font-weight: 900;
  line-height: 1.2;
}

.local-ad-demo-card {
  min-height: var(--local-ad-demo-min-height);
  justify-content: space-between;
  padding: var(--space-md);
  background:
    linear-gradient(135deg, rgba(223, 63, 37, 0.14), rgba(74, 163, 223, 0.16)),
    var(--surface);
}

.local-ad-demo-visual {
  display: grid;
  gap: var(--space-xs);
  min-width: 0;
  flex: 1 1 auto;
}

.local-ad-demo-dot {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  background: var(--brand-red);
}

.local-ad-demo-line {
  display: block;
  width: 44%;
  height: 9px;
  border-radius: 999px;
  background: rgba(74, 163, 223, 0.35);
}

.local-ad-demo-line.wide {
  width: 72%;
  background: rgba(223, 63, 37, 0.28);
}

.local-ad-demo-text {
  flex: 0 0 auto;
  color: var(--ink);
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
}

.local-ad-admin-list {
  display: grid;
  gap: var(--space-sm);
}

.local-ad-row {
  display: grid;
  grid-template-columns: var(--local-ad-thumb-width) minmax(0, 1fr);
  gap: var(--space-md);
  align-items: center;
  padding: var(--space-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.local-ad-thumb {
  width: 100%;
  aspect-ratio: var(--ratio-local-ad);
  border-radius: var(--radius-sm);
  object-fit: cover;
  object-position: center;
  background: var(--page);
}

.local-ad-thumb-empty {
  display: grid;
  place-items: center;
  padding: var(--space-xs);
  color: var(--muted);
  border: 1px dashed var(--line-strong);
  text-align: center;
  font-size: var(--text-sm);
}

.local-ad-post-preview {
  display: grid;
  gap: var(--space-xs);
  padding: var(--space-sm);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
}

.local-ad-post-preview.empty {
  color: var(--muted);
}

.local-ad-post-preview span,
.local-ad-post-preview p,
.local-ad-post-preview a {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height);
}

.local-ad-post-preview a {
  color: var(--accent);
  overflow-wrap: anywhere;
}

.local-ad-info {
  display: grid;
  gap: var(--space-xs);
  min-width: 0;
}

.local-ad-title {
  margin: 0;
  font-size: var(--text-md);
  font-weight: var(--font-semibold);
  line-height: var(--line-height);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.local-ad-meta {
  margin: 0;
  color: var(--muted);
  font-size: var(--text-sm);
  line-height: var(--line-height);
}

.local-ad-actions,
.local-ad-form-actions,
.checkbox-line {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.checkbox-line {
  min-height: var(--tap-target);
}

.local-ad-actions button,
.local-ad-form-actions button {
  min-height: var(--tap-target);
}

.detail-main {
  padding-bottom: calc(var(--tap-target) + var(--space-lg) + env(safe-area-inset-bottom));
}

.detail-chat-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 8;
  display: grid;
  grid-template-columns: var(--tap-target) minmax(0, 1fr);
  gap: var(--space-sm);
  align-items: center;
  padding: 6px var(--page-x) calc(6px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: color-mix(in srgb, var(--surface) 94%, transparent);
  backdrop-filter: blur(18px);
}

.detail-follow-button {
  width: var(--tap-target);
  height: var(--tap-target);
  border: 0;
  background: transparent;
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.detail-follow-button .favorite-icon {
  width: 28px;
  height: 28px;
}

.detail-chat-button {
  min-height: var(--tap-target);
  border: 0;
  border-radius: var(--radius-md);
  background: var(--brand-red);
  color: #fff;
  font-weight: 800;
  font-size: var(--text-md);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.detail-chat-button:disabled {
  opacity: 0.55;
}

.chat-main {
  padding-bottom: calc(var(--bottombar-h) + var(--space-lg) + env(safe-area-inset-bottom));
}

.chat-shell {
  padding: var(--space-md) var(--page-x) var(--space-lg);
}

.chat-header,
.chat-thread-header {
  display: flex;
  align-items: center;
  gap: var(--space-md);
  margin-bottom: var(--space-lg);
}

.chat-header {
  justify-content: space-between;
}

.chat-header-status {
  display: inline-flex;
  align-items: center;
  gap: var(--space-xs);
}

.chat-header h1,
.chat-thread-heading h1 {
  margin: 0;
  font-size: var(--text-xl);
  line-height: 1.2;
}

.chat-header span,
.chat-thread-heading span,
.chat-thread-preview,
.chat-thread-time,
.chat-message-time {
  color: var(--muted);
}

.chat-thread-list {
  display: grid;
  gap: var(--space-md);
}

.chat-thread-row-wrap {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--tap-target);
  gap: var(--space-sm);
  align-items: center;
}

.chat-thread-row {
  width: 100%;
  border: 0;
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr) auto;
  gap: var(--space-md);
  align-items: center;
  padding: var(--space-md);
  text-align: left;
}

.chat-thread-delete {
  width: var(--tap-target);
  min-width: var(--tap-target);
  height: var(--tap-target);
  min-height: var(--tap-target);
  border: 0;
  border-radius: var(--radius-full);
  background: transparent;
  color: var(--brand-red);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  font-size: 12px;
  line-height: 1;
  font-weight: 900;
}

.chat-thread-delete .more-icon {
  width: var(--icon-md);
  height: var(--icon-md);
}

.chat-thread-menu-wrap {
  position: relative;
  display: inline-flex;
  justify-content: center;
}

.chat-thread-menu {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 12;
  min-width: 92px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
  overflow: hidden;
}

.chat-thread-menu button {
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--text);
  display: block;
  padding: 10px 12px;
  text-align: left;
  white-space: nowrap;
}

.chat-thread-menu button[data-action="block-chat-thread"],
.chat-thread-menu button[data-action="unblock-chat-thread"] {
  color: var(--brand-red);
  font-weight: 800;
}

.chat-confirm-layer {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  padding: var(--page-x);
}

.chat-confirm-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.42);
}

.chat-confirm-box {
  position: relative;
  z-index: 1;
  width: min(100%, 320px);
  border-radius: var(--radius-lg);
  background: var(--surface);
  color: var(--text);
  padding: var(--space-lg);
  box-shadow: 0 18px 48px rgba(10, 14, 20, 0.28);
}

.chat-confirm-box p {
  margin: 0 0 var(--space-lg);
  font-size: var(--text-lg);
  font-weight: 800;
  line-height: 1.35;
}

.chat-confirm-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm);
}

.chat-confirm-actions button {
  min-height: var(--tap-target);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  font-weight: 800;
}

.chat-confirm-actions .danger {
  border-color: var(--brand-red);
  background: var(--brand-red);
  color: #fff;
}

.chat-thumb {
  width: 58px;
  height: 58px;
  border-radius: var(--radius-sm);
  object-fit: cover;
  background: var(--category-chip-bg);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
}

.chat-thumb-wrap {
  position: relative;
  width: 58px;
  height: 58px;
  display: inline-flex;
}

.chat-thread-content,
.chat-thread-side,
.chat-thread-heading {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.chat-thread-title,
.chat-thread-preview {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.chat-thread-title {
  font-weight: 800;
}

.chat-thread-side {
  justify-items: end;
}

.chat-thread-time {
  font-size: 10px;
}

.chat-unread {
  min-width: 20px;
  height: 20px;
  border-radius: 999px;
  background: var(--brand-red);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: var(--text-xs);
  font-weight: 800;
}

.chat-header-unread {
  min-width: 18px;
  height: 18px;
  font-size: 10px;
}

.chat-thumb-unread {
  position: absolute;
  top: -6px;
  left: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  font-size: 10px;
  box-shadow: 0 0 0 2px var(--surface);
}

.chat-thread-shell {
  min-height: calc(100dvh - 43px);
  height: calc(100dvh - 43px);
  display: grid;
  grid-template-rows: auto minmax(0, 1fr);
  overflow: hidden;
}

.chat-thread-main {
  padding-top: 0;
  padding-bottom: 0;
  overflow: hidden;
}

.chat-post-card {
  width: 100%;
  border: 0;
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--text);
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: var(--space-md);
  align-items: center;
  padding: var(--space-md);
  margin-bottom: var(--space-lg);
  text-align: left;
}

.chat-post-card-with-actions {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
}

.chat-post-open {
  min-width: 0;
  border: 0;
  background: transparent;
  color: inherit;
  display: grid;
  grid-template-columns: 58px minmax(0, 1fr);
  gap: var(--space-md);
  align-items: center;
  padding: 0;
  text-align: left;
}

.chat-post-contact {
  justify-self: end;
  align-self: start;
}

.chat-post-contact .contact-actions {
  margin-top: 0;
  gap: var(--space-xs);
}

.chat-post-contact .contact-action {
  width: 36px;
  height: 36px;
  min-height: 36px;
  border-radius: var(--radius-md);
}

.chat-post-contact .contact-action .contact-icon {
  width: 18px;
  height: 18px;
}

.chat-post-info {
  min-width: 0;
  display: grid;
  gap: 4px;
}

.chat-post-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-weight: 800;
}

.chat-post-meta {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: var(--muted);
}

.chat-post-price {
  color: var(--brand-red);
  font-weight: 900;
}

.chat-message-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  min-height: 0;
  overflow-y: auto;
  padding-bottom: calc(var(--tap-target) + var(--space-xl) + 24px + env(safe-area-inset-bottom));
  overscroll-behavior: contain;
}

.chat-message {
  display: grid;
  gap: 3px;
  max-width: 80%;
}

.chat-message.own {
  align-self: end;
  justify-items: end;
}

.chat-message.other {
  align-self: start;
}

.chat-message-avatar {
  width: 26px;
  height: 26px;
}

.chat-message.own .chat-message-avatar {
  display: none;
}

.chat-message-time {
  font-size: 9px;
  line-height: 1.1;
}

.chat-translate-button {
  justify-self: start;
  padding: 0;
  color: var(--brand-blue);
  background: transparent;
  border: 0;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
}

.chat-message.own .chat-translate-button {
  justify-self: end;
}

.chat-translate-button:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.chat-message-bubble {
  min-height: var(--tap-target);
  max-width: min(72vw, 260px);
  border-radius: var(--radius-md);
  padding: 0 14px;
  background: var(--surface);
  color: var(--text);
  display: inline-flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 4px;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  text-align: left;
  line-height: 20px;
}

.chat-message-bubble.has-image {
  display: grid;
  gap: var(--space-xs);
  padding: var(--space-xs);
  max-width: 220px;
  min-height: 0;
}

.chat-message-image {
  display: block;
  width: 100%;
  max-height: 240px;
  border-radius: var(--radius-sm);
  object-fit: cover;
}

.chat-message-text {
  display: inline-block;
  padding: 0;
}

.chat-message-original {
  display: block;
  width: 100%;
  margin-top: 2px;
  padding-top: 6px;
  border-top: 1px solid rgba(148, 163, 184, 0.28);
  color: color-mix(in srgb, currentColor 72%, transparent);
  font-size: 12px;
  line-height: 18px;
}

.chat-message.own .chat-message-bubble {
  background: var(--brand-red);
  color: #fff;
}

.chat-compose {
  position: sticky;
  bottom: calc(var(--bottombar-h) + env(safe-area-inset-bottom));
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: var(--space-sm);
  align-items: end;
  padding: var(--space-sm) 0;
  background: var(--page);
}

.chat-thread-main .chat-compose {
  position: fixed;
  left: var(--page-x);
  right: var(--page-x);
  bottom: calc(24px + env(safe-area-inset-bottom));
  z-index: 8;
  padding: 0;
  border-top: 0;
  background: transparent;
  align-items: stretch;
}

.chat-attach-button {
  width: var(--tap-target);
  height: var(--tap-target);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  line-height: 1;
  font-weight: 400;
}

.chat-compose textarea {
  resize: none;
  min-height: var(--tap-target);
  max-height: 120px;
  border-radius: var(--radius-md);
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--text);
  line-height: 20px;
  padding: 11px 12px;
}

.chat-compose button {
  min-height: var(--tap-target);
  padding: 0 var(--space-lg);
  border: 0;
  border-radius: var(--radius-md);
  background: var(--brand-red);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.chat-compose button.is-loading {
  opacity: 0.78;
  cursor: progress;
}

.chat-thread-main .chat-compose .chat-attach-button,
.chat-thread-main .chat-compose textarea,
.chat-thread-main .chat-compose button {
  height: var(--tap-target);
  min-height: var(--tap-target);
}
/* Account auth */
.account-panel {
  display: grid;
  gap: 12px;
  margin: 0 16px 16px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.035);
}

.my-intro-copy {
  display: grid;
  grid-template-columns: auto 1fr;
  column-gap: 0;
  row-gap: 4px;
  white-space: pre-wrap;
}

.my-intro-label {
  white-space: nowrap;
}

.account-label {
  display: block;
  margin-bottom: 4px;
  color: var(--muted);
  font-size: 13px;
}

.account-summary-row,
.profile-edit-row,
.post-author-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.account-summary-main {
  min-width: 0;
  flex: 1 1 auto;
}

.account-manage-button {
  min-height: 36px;
  flex: 0 0 auto;
  padding: 0 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  font-weight: 800;
}

.profile-avatar {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--brand-light);
  color: var(--brand);
  flex: 0 0 auto;
}

.profile-avatar-empty {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
}

.profile-form {
  display: grid;
  gap: 10px;
  padding-top: 4px;
}

.account-profile-panel {
  gap: 10px;
}

.profile-page-head {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
}

.profile-page-title {
  min-width: 0;
  flex: 1 1 auto;
}

.account-profile-menu {
  position: relative;
  margin-left: auto;
  flex: 0 0 auto;
  align-self: flex-start;
}

.account-profile-menu-button {
  width: var(--tap-target);
  min-width: var(--tap-target);
  height: var(--tap-target);
  min-height: var(--tap-target);
  padding: 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  box-shadow: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.account-profile-menu-button[aria-expanded="true"] {
  color: var(--ink);
  background: transparent;
  box-shadow: none;
}

.account-profile-menu-list {
  position: absolute;
  right: 0;
  top: calc(100% + 6px);
  z-index: 20;
  min-width: 132px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong, var(--surface));
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.28);
}

.account-profile-menu:not(.open) .account-profile-menu-list {
  display: none;
}

.account-profile-menu-item {
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  border: 0;
  border-radius: 8px;
  color: var(--ink);
  background: transparent;
  text-align: left;
  font-weight: 800;
}

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

.profile-form h3 {
  margin: 0;
  font-size: var(--text-lg);
}

.profile-avatar-picker {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--surface);
  font-weight: 800;
}

.post-author-row {
  margin-top: 6px;
  color: var(--muted);
  font-size: var(--text-sm);
}

.detail-card .post-author-row {
  margin: 10px 0 8px;
}

.post-author-avatar {
  width: 28px;
  height: 28px;
}

.account-actions,
.auth-actions-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.profile-actions-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  align-items: center;
}

.profile-actions-row .account-secondary-button {
  min-width: 88px;
}

.account-primary-button,
.account-secondary-button,
.account-danger-button {
  min-height: 42px;
  padding: 0 14px;
  border-radius: 8px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.account-primary-button {
  border: 0;
  color: #fff;
  background: var(--accent);
}

.google-login-button {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--ink);
  background: var(--surface);
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 0 14px;
}

.google-logo {
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
}

.account-secondary-button {
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.account-danger-button {
  border: 1px solid rgba(239, 59, 38, 0.42);
  color: #ff756a;
  background: rgba(239, 59, 38, 0.08);
}

.btn-spinner {
  width: 13px;
  height: 13px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  display: inline-block;
  flex: 0 0 auto;
  animation: btn-spin 0.7s linear infinite;
}

.account-recover-link {
  justify-self: start;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: 13px;
}

.account-recover-text {
  margin: 0;
  white-space: pre-wrap;
  color: var(--muted);
  font: inherit;
  line-height: 1.55;
}

.account-publish-hint {
  margin: 0 0 14px;
  padding: 12px 14px;
  border-radius: 8px;
  color: #d7f5df;
  background: rgba(42, 184, 92, 0.14);
}

.auth-modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, 0.58);
}

.auth-modal {
  width: min(100%, 440px);
  display: grid;
  gap: 14px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.35);
}

.auth-modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.auth-modal-head h2 {
  margin: 0;
  font-size: 20px;
}

.auth-close {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.07);
  font-size: 24px;
  line-height: 1;
}

.auth-password-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.auth-password-row button {
  min-width: 64px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

.auth-device-status.ok {
  color: #53d178;
}

.auth-device-status.bad,
.auth-error {
  color: #ff6b5a;
}

.auth-error {
  font-weight: 700;
}

@media (min-width: 700px) {
  .auth-modal-backdrop {
    align-items: center;
  }
}

.property-map-card {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.property-map-home-card {
  margin: 0 0 14px;
}

.property-map-detail-card {
  margin-top: 12px;
}

.property-map-card-header {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  pointer-events: none;
}

.property-map-card-header > div {
  display: inline-flex;
  flex-direction: column;
  min-width: 0;
  max-width: calc(100% - 96px);
  padding: 7px 9px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: var(--text);
  box-shadow: 0 4px 14px rgba(15, 23, 42, 0.12);
}

body.dark .property-map-card-header > div {
  background: rgba(24, 24, 27, 0.9);
}

.property-map-card-header strong {
  font-size: 14px;
  line-height: 1.2;
}

.property-map-card-header span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.property-map-expand-button,
.property-map-close-button {
  pointer-events: auto;
  border: 0;
  border-radius: 8px;
  background: var(--brand-red);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.property-map-expand-button {
  min-height: 36px;
  padding: 0 12px;
  font-size: 13px;
  white-space: nowrap;
}

.property-map-canvas {
  position: relative;
  display: flex;
  width: 100%;
  min-height: 120px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  background: #eef3f0;
  color: var(--muted);
  font-size: 13px;
  font-weight: 700;
}

body.dark .property-map-canvas {
  background: #1f2421;
}

.property-map-home {
  aspect-ratio: 16 / 9;
  min-height: 190px;
}

.property-map-detail {
  aspect-ratio: 16 / 3.9;
  min-height: 94px;
}

.property-map-message {
  padding: 8px 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
}

body.dark .property-map-message {
  background: rgba(24, 24, 27, 0.86);
}

.property-map-detail-cover {
  position: absolute;
  inset: 0;
  z-index: 3;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.property-map-overlay {
  position: fixed;
  inset: 0;
  z-index: 1200;
  display: flex;
  align-items: stretch;
  justify-content: center;
  padding: max(16px, env(safe-area-inset-top)) 12px max(16px, env(safe-area-inset-bottom));
}

.property-map-overlay-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(0, 0, 0, 0.52);
}

.property-map-overlay-panel {
  position: relative;
  z-index: 1;
  display: flex;
  width: min(980px, 100%);
  min-height: 72vh;
  max-height: 92vh;
  flex-direction: column;
  overflow: hidden;
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.28);
}

.property-map-overlay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}

.property-map-overlay-header div {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.property-map-overlay-header strong {
  font-size: 15px;
  line-height: 1.25;
}

.property-map-overlay-header span {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.25;
}

.property-map-close-button {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  font-size: 24px;
  line-height: 1;
}

.property-map-overlay-canvas {
  flex: 1 1 auto;
  min-height: 0;
}

.property-map-info-card {
  display: flex;
  max-width: 210px;
  min-width: 160px;
  flex-direction: column;
  gap: 3px;
  border: 0;
  background: transparent;
  color: #111827;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.property-map-info-card strong,
.property-map-info-card span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.property-map-info-card strong {
  font-size: 13px;
  line-height: 1.25;
}

.property-map-info-card span {
  color: #4b5563;
  font-size: 12px;
  line-height: 1.25;
}

@media (max-width: 640px) {
  .property-map-home {
    min-height: 178px;
  }

  .property-map-card-header {
    top: 8px;
    left: 8px;
    right: 8px;
  }

  .property-map-card-header > div {
    max-width: calc(100% - 86px);
  }

  .property-map-expand-button {
    min-height: 34px;
    padding: 0 10px;
    font-size: 12px;
  }

  .property-map-overlay {
    padding: env(safe-area-inset-top) 0 env(safe-area-inset-bottom);
  }

  .property-map-overlay-panel {
    width: 100%;
    min-height: 100%;
    max-height: 100%;
    border-radius: 0;
  }
}

.price-wanted {
  color: #16a34a !important;
}

.housing-location-field.is-hidden {
  display: none;
}

.property-map-home {
  cursor: pointer;
}

.property-map-publish {
  aspect-ratio: 16 / 5;
  min-height: 88px;
  border-radius: 8px;
}

.property-map-overlay-close {
  position: absolute;
  top: max(12px, env(safe-area-inset-top));
  right: 12px;
  z-index: 5;
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.28);
}

.property-map-price-marker {
  position: absolute;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 48px;
  min-height: 28px;
  padding: 5px 9px;
  border: 0;
  border-radius: 8px;
  background: #b91c1c;
  color: #fff;
  box-shadow: 0 4px 10px rgba(15, 23, 42, 0.28);
  cursor: pointer;
  font: 800 13px/1 var(--font-main);
  text-align: center;
  transition: min-width 0.18s ease, min-height 0.18s ease, padding 0.18s ease, border-radius 0.18s ease, transform 0.18s ease;
  white-space: nowrap;
  transform: translate(-50%, -100%);
}

.property-map-marker-price-text {
  display: inline-block;
}

.property-map-marker-dot {
  display: none;
}

.property-map-marker-pin {
  position: absolute;
  top: -9px;
  right: -7px;
  width: 14px;
  height: 14px;
  border: 2px solid #fff;
  border-radius: 50% 50% 50% 0;
  background: #fbbf24;
  box-shadow: 0 3px 8px rgba(15, 23, 42, 0.24);
  transform: rotate(-45deg);
}

.property-map-marker-pin::after {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 4px;
  height: 4px;
  border-radius: 999px;
  background: rgba(120, 53, 15, 0.72);
  content: "";
}

.property-map-price-marker.is-price .property-map-marker-dot {
  display: none;
}

.property-map-price-marker::after {
  position: absolute;
  left: 50%;
  bottom: -5px;
  width: 10px;
  height: 10px;
  background: inherit;
  content: "";
  transform: translateX(-50%) rotate(45deg);
}

.property-map-price-marker.is-wanted {
  background: #16a34a;
}

.property-map-price-marker.is-dot {
  width: 18px;
  min-width: 18px;
  height: 18px;
  min-height: 18px;
  overflow: hidden;
  padding: 0;
  border: 2px solid rgba(255, 255, 255, 0.94);
  border-radius: 50%;
  color: transparent;
  font-size: 0;
  line-height: 0;
  box-shadow: 0 2px 7px rgba(15, 23, 42, 0.3);
  transform: translate(-50%, -50%);
}

.property-map-price-marker.is-dot .property-map-marker-price-text {
  display: none;
}

.property-map-price-marker.is-dot .property-map-marker-dot {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: inherit;
}

.property-map-price-marker.is-dot .property-map-marker-pin {
  top: -7px;
  right: -7px;
  width: 10px;
  height: 10px;
  border-width: 1px;
}

.property-map-price-marker.is-dot .property-map-marker-pin::after {
  top: 2px;
  left: 2px;
  width: 3px;
  height: 3px;
}

.property-map-price-marker.is-dot::after {
  display: none;
}

.property-map-result-popover {
  position: absolute;
  left: 50%;
  bottom: max(56px, env(safe-area-inset-bottom));
  z-index: 4;
  width: min(390px, calc(100% - 20px));
  pointer-events: auto;
  transform: translateX(-50%);
}

.property-map-result-popover .property-map-result-card {
  width: 100%;
  box-shadow: 0 18px 46px rgba(0, 0, 0, 0.34);
}

.property-map-result-card {
  position: relative;
  display: block;
  width: min(390px, 90vw);
  overflow: hidden;
  border: 0;
  border-radius: 10px;
  background: #171821;
  color: #fff;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.property-map-result-open {
  display: block;
  min-width: 0;
  color: inherit;
  text-decoration: none;
}

.property-map-result-follow {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  min-width: 42px;
  height: 42px;
  min-height: 42px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  color: #fff;
  backdrop-filter: blur(12px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.24);
}

.property-map-result-follow .favorite-icon {
  width: 24px;
  height: 24px;
}

.property-map-result-follow.active {
  color: #fff;
  background: var(--brand-red);
}

.property-map-result-follow:hover,
.property-map-result-follow:focus,
.property-map-result-follow:active {
  background: rgba(15, 23, 42, 0.74);
}

.property-map-result-follow.active:hover,
.property-map-result-follow.active:focus,
.property-map-result-follow.active:active {
  background: var(--brand-red);
}

.property-map-result-carousel {
  display: flex;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  touch-action: pan-x;
}

.property-map-result-carousel::-webkit-scrollbar {
  display: none;
}

.property-map-result-slide {
  display: block;
  min-width: 100%;
  aspect-ratio: 16 / 9;
  scroll-snap-align: start;
}

.property-map-result-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.property-map-result-placeholder {
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #2f333d, #171821);
}

.property-map-result-dots {
  position: absolute;
  left: 50%;
  top: calc(56.25% - 24px);
  display: inline-flex;
  gap: 8px;
  padding: 7px 10px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.42);
  transform: translateX(-50%);
}

.property-map-result-dots i {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.58);
}

.property-map-result-dots i.active {
  background: #fff;
}

.property-map-result-content {
  display: grid;
  min-width: 0;
  gap: 7px;
  padding: 13px 14px 15px;
}

.property-map-result-title,
.property-map-result-content span,
.property-map-result-price {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.property-map-result-content span {
  color: rgba(255, 255, 255, 0.78);
  font-size: 13px;
  line-height: 1.3;
}

.property-map-result-meta {
  color: rgba(255, 255, 255, 0.78);
}

.property-map-result-title {
  color: #fff;
  font-size: 15px;
  font-weight: 800;
}

.property-map-result-price {
  color: #fff;
  font-size: 28px;
  font-weight: 900;
  line-height: 1.25;
}

@media (max-width: 640px) {
  .property-map-publish {
    min-height: 82px;
  }

  .property-map-price-marker {
    min-width: 44px;
    min-height: 26px;
    padding: 4px 8px;
    font-size: 12px;
  }

  .property-map-result-card {
    width: min(360px, 90vw);
  }

  .property-map-result-popover {
    bottom: max(52px, env(safe-area-inset-bottom));
    width: min(360px, calc(100% - 18px));
  }

  .property-map-result-price {
    font-size: 25px;
  }
}
