:root,
html.dark-style {
  --frontend-content-max-width: 90rem;
  --frontend-surface: #1a1b2b;
  --frontend-surface-card: #1e1f32;
  --frontend-surface-header: #151624;
  --frontend-surface-alt: #25273d;
  --frontend-background: #13141f;
  --frontend-text: #e2e8f0;
  --frontend-text-dark: #f8fafc;
  --frontend-text-emphasis: #ffffff;
  --frontend-muted: #94a3b8;
  --frontend-border: rgba(255, 255, 255, 0.12);
  --frontend-border-subtle: rgba(255, 255, 255, 0.06);
  --frontend-primary: #7e82ff;
  --frontend-primary-dark: #9396ff;
  --frontend-radius: 0.75rem;
  --frontend-card-shadow: 0 8px 24px rgba(0, 0, 0, 0.45);
  --frontend-quick-answer-bg: linear-gradient(135deg, rgba(126, 130, 255, 0.18) 0%, rgba(30, 31, 50, 0.95) 100%);
  --frontend-quick-answer-border: #7e82ff;
  --frontend-quick-answer-text: #f8fafc;
}

/* 全域文字清晰度與高對比覆寫 */
body {
  background: var(--frontend-background) !important;
  color: var(--frontend-text) !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  letter-spacing: 0.01em;
}

h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6 {
  color: #ffffff !important;
  font-weight: 700;
  letter-spacing: -0.01em;
}

p, span, li, td, th {
  color: var(--frontend-text);
}

/* 強制覆寫 Bootstrap 昏暗的 text-muted */
.text-muted,
.table .text-muted,
.card .text-muted,
p.text-muted,
span.text-muted,
small.text-muted,
div.text-muted {
  color: #94a3b8 !important;
}

/* 麵包屑導航清晰高對比度 */
.breadcrumb {
  background: transparent;
  padding: 0;
  margin-bottom: 0.75rem;
}
.breadcrumb-item,
.breadcrumb-item a {
  color: #94a3b8 !important;
  font-weight: 500;
  text-decoration: none;
}
.breadcrumb-item a:hover {
  color: #ffffff !important;
  text-decoration: underline;
}
.breadcrumb-item.active {
  color: #ffffff !important;
  font-weight: 600;
}
.breadcrumb-item + .breadcrumb-item::before {
  color: #64748b !important;
}

/* 連結色彩 */
a {
  color: #8b8eff;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.16em;
  transition: color 0.15s ease-in-out;
}
a:hover {
  color: #b4b7ff;
}

/* 頂部導航列 */
.frontend-site-header {
  background: #151624 !important;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}
.frontend-brand {
  color: #ffffff !important;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  text-decoration: none;
}
.frontend-brand:hover {
  color: #a8aaff !important;
}
.frontend-nav-link {
  color: #cbd5e1 !important;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s ease;
}
.frontend-nav-link:hover,
.frontend-nav-link:focus,
.frontend-nav-link.active {
  color: #ffffff !important;
}

/* 頁尾樣式 */
.frontend-footer {
  background: #0e0f17 !important;
  border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
  color: #94a3b8 !important;
}
.frontend-footer span,
.frontend-footer div,
.frontend-footer p {
  color: #94a3b8 !important;
}
.frontend-footer strong,
.frontend-footer .fw-semibold {
  color: #e2e8f0 !important;
}

/* 全站卡片統一樣式 */
.card {
  background-color: #1e1f32 !important;
  border: 1px solid rgba(255, 255, 255, 0.08) !important;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35) !important;
  color: #e2e8f0 !important;
}
.card-body {
  color: #e2e8f0;
}

/* 全域 DataTables 與表格樣式提升 */
.table {
  color: #e2e8f0 !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}
.table > :not(caption) > * > * {
  background-color: transparent;
  color: inherit;
  border-bottom-color: rgba(255, 255, 255, 0.07);
}
.table thead th {
  background-color: #25273d !important;
  color: #ffffff !important;
  font-weight: 700 !important;
  border-bottom: 2px solid rgba(126, 130, 255, 0.4) !important;
}
.table-hover > tbody > tr:hover > * {
  background-color: rgba(255, 255, 255, 0.05) !important;
  color: #ffffff !important;
}

/* DataTables 控制項文字亮色高對比 */
.dataTables_wrapper {
  color: #cbd5e1 !important;
}
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_paginate {
  color: #cbd5e1 !important;
  margin-top: 0.5rem;
}
.dataTables_wrapper .dataTables_filter input,
.dataTables_wrapper .dataTables_length select {
  background-color: #151624 !important;
  color: #ffffff !important;
  border: 1px solid rgba(255, 255, 255, 0.2) !important;
  border-radius: 0.375rem;
  padding: 0.35rem 0.65rem;
}
.dataTables_wrapper .dataTables_filter input:focus,
.dataTables_wrapper .dataTables_length select:focus {
  border-color: #7e82ff !important;
  outline: none;
  box-shadow: 0 0 0 2px rgba(126, 130, 255, 0.3) !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button {
  color: #cbd5e1 !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  background: #7e82ff !important;
  border-color: #7e82ff !important;
  color: #ffffff !important;
  border-radius: 0.35rem;
}
.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
  background: rgba(255, 255, 255, 0.1) !important;
  border-color: transparent !important;
  color: #ffffff !important;
}

/* 搜尋捷徑與下拉選單 */
.dropdown-menu {
  background-color: #1e1f32 !important;
  border: 1px solid rgba(255, 255, 255, 0.15) !important;
}
.dropdown-item {
  color: #cbd5e1 !important;
}
.dropdown-item:hover,
.dropdown-item:focus {
  background-color: rgba(255, 255, 255, 0.08) !important;
  color: #ffffff !important;
}
.global-search-trigger {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #e2e8f0;
}
.global-search-trigger:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(126, 130, 255, 0.5);
  color: #ffffff;
}
.global-search-trigger .text-muted {
  color: #94a3b8 !important;
}
.global-search-kbd {
  background: rgba(0, 0, 0, 0.4);
  color: #a8aaff;
  border: 1px solid rgba(255, 255, 255, 0.15);
}


@media (min-width: 1200px) {
  .frontend-site-header .frontend-content {
    gap: 0.875rem;
    flex-wrap: nowrap;
  }

  .frontend-site-header .frontend-content > .d-flex {
    min-width: 0;
  }

  .frontend-site-header .frontend-content > .d-flex:first-child {
    flex: 0 1 auto;
  }

  .global-search-trigger {
    max-width: 13rem;
  }

  .global-search-trigger .small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .frontend-navigation-list {
    gap: clamp(0.65rem, 1.1vw, 1rem) !important;
  }

  .frontend-navigation-list > .nav-item,
  .frontend-navigation-list .btn,
  .frontend-nav-link {
    flex: 0 0 auto;
    white-space: nowrap;
  }

  .frontend-nav-link {
    font-size: 0.875rem;
  }
}

@media (min-width: 1200px) and (max-width: 1279.98px) {
  .frontend-site-header .d-xl-block {
    display: none !important;
  }

  .frontend-site-header .navbar-toggler.d-xl-none {
    display: block !important;
  }
}

.frontend-page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.frontend-page-eyebrow {
  color: var(--frontend-muted);
  font-size: 0.8125rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  margin-bottom: 0.5rem;
  text-transform: uppercase;
}

.frontend-page-title {
  color: var(--frontend-text);
  font-size: clamp(1.75rem, 3vw, 2.5rem);
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.2;
  margin: 0;
}

.frontend-page-summary {
  color: var(--frontend-muted);
  font-size: 1rem;
  margin: 0.75rem 0 0;
  max-width: 44rem;
}

.frontend-panel {
  background: var(--frontend-surface);
  border: 1px solid var(--frontend-border);
  border-radius: var(--frontend-radius);
}

.frontend-content .card {
  border: 1px solid var(--frontend-border);
  border-radius: var(--frontend-radius);
  box-shadow: none;
}

.frontend-content .card .card-body {
  padding: 1.5rem;
}

.frontend-panel > .card-body {
  padding: 1.5rem;
}

.frontend-list {
  background: var(--frontend-surface);
  border: 1px solid var(--frontend-border);
  border-radius: var(--frontend-radius);
  overflow: hidden;
}

.frontend-list .table {
  margin-bottom: 0;
}

.frontend-list .table > :not(caption) > * > * {
  border-bottom-color: var(--frontend-border);
  padding: 1rem;
}

.frontend-filter {
  background: var(--frontend-surface);
  border-bottom: 1px solid var(--frontend-border);
  padding: 1.5rem;
}

.frontend-filter .form-label {
  color: var(--frontend-text);
  font-size: 0.875rem;
  font-weight: 600;
}

.frontend-filter .form-control,
.frontend-filter .form-select {
  border-color: #cbd5e1;
}

.frontend-category-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.frontend-category-nav .btn {
  border-color: var(--frontend-border);
  color: var(--frontend-text);
}

.frontend-category-nav .btn:hover,
.frontend-category-nav .btn.active {
  background: #eef1ff;
  border-color: #c7d0ff;
  color: var(--frontend-primary-dark);
}

.frontend-mobile-list {
  display: grid;
  gap: 0.75rem;
}

.frontend-mobile-list-item {
  background: var(--frontend-surface);
  border: 1px solid var(--frontend-border);
  border-radius: var(--frontend-radius);
  padding: 1rem;
}

.frontend-detail-nav {
  border-bottom: 1px solid var(--frontend-border);
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}

.frontend-detail-nav .nav-link {
  color: var(--frontend-muted);
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.25rem 0;
  white-space: nowrap;
}

.frontend-detail-nav .nav-link:hover {
  color: var(--frontend-primary-dark);
}

.frontend-definition-list dt {
  color: var(--frontend-muted);
  font-size: 0.875rem;
  font-weight: 500;
}

.frontend-definition-list dd {
  font-weight: 500;
}

.frontend-empty-state {
  background: var(--frontend-surface);
  border: 1px dashed #cbd5e1;
  border-radius: var(--frontend-radius);
  color: var(--frontend-muted);
  padding: 3rem 1.5rem;
  text-align: center;
}

.frontend-section {
  margin-top: 2rem;
}

.frontend-section-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.frontend-hero {
  max-width: 52rem;
  padding-block: 3rem 2rem;
}

.frontend-content > .row.justify-content-center {
  padding-block: 2rem;
}

.frontend-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.frontend-entry-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.frontend-entry {
  background: var(--frontend-surface);
  border: 1px solid var(--frontend-border);
  border-radius: var(--frontend-radius);
  color: var(--frontend-text);
  display: block;
  padding: 1.5rem;
  text-decoration: none;
  transition: border-color 180ms ease, transform 180ms ease;
}

.frontend-entry:hover {
  border-color: var(--frontend-primary);
  color: var(--frontend-text);
  transform: translateY(-1px);
}

.frontend-entry-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.frontend-entry-description {
  color: var(--frontend-muted);
  font-size: 0.9375rem;
  margin: 0;
}

.frontend-map-page .frontend-content {
  max-width: none;
  padding: 0;
  width: 100%;
}

.frontend-map-page .content-wrapper {
  background: #101923;
}

.frontend-map-experience {
  min-height: calc(100dvh - 4.5rem);
  padding: 1rem clamp(1rem, 2vw, 2rem) 1.5rem;
}

.frontend-map-header {
  align-items: baseline;
  display: flex;
  justify-content: space-between;
  margin: 0 auto 0.75rem;
  max-width: 70rem;
}

.frontend-map-switcher {
  display: flex;
  gap: 0.5rem;
  margin: 0 auto 0.75rem;
  max-width: 70rem;
}

.frontend-map-switcher a {
  border: 1px solid #3b4d62;
  border-radius: 999px;
  color: #cbd5e1;
  font-size: 0.8125rem;
  padding: 0.375rem 0.75rem;
  text-decoration: none;
}

.frontend-map-switcher a:hover,
.frontend-map-switcher a.active {
  background: #334155;
  border-color: #60a5fa;
  color: #f8fafc;
}

.frontend-map-tools,
.frontend-map-meta {
  align-items: center;
  display: flex;
  gap: 0.75rem;
  justify-content: space-between;
  margin: 0 auto 0.75rem;
  max-width: 70rem;
}

.frontend-map-search {
  max-width: 32rem;
  position: relative;
  width: 100%;
}

.frontend-map-search input {
  background: #172230;
  border: 1px solid #3b4d62;
  border-radius: 0.5rem;
  color: #f8fafc;
  padding: 0.5rem 0.75rem;
  width: 100%;
}

.frontend-map-search input::placeholder {
  color: #aab7c7;
}

.frontend-map-search-results {
  background: #172230;
  border: 1px solid #3b4d62;
  border-radius: 0.5rem;
  box-shadow: 0 0.75rem 1.5rem rgba(0, 0, 0, 0.28);
  left: 0;
  margin-top: 0.375rem;
  overflow: hidden;
  position: absolute;
  right: 0;
  z-index: 1000;
}

.frontend-map-search-results p {
  color: #cbd5e1;
  font-size: 0.875rem;
  margin: 0;
  padding: 0.75rem;
}

.frontend-map-search-result {
  background: transparent;
  border: 0;
  border-bottom: 1px solid #2a3a4d;
  color: #f8fafc;
  display: grid;
  padding: 0.625rem 0.75rem;
  text-align: left;
  width: 100%;
}

.frontend-map-search-result:last-child {
  border-bottom: 0;
}

.frontend-map-search-result:hover {
  background: #26364a;
}

.frontend-map-search-result small {
  color: #aab7c7;
  margin-top: 0.125rem;
}

.frontend-map-actions {
  display: flex;
  flex-shrink: 0;
  gap: 0.5rem;
}

.frontend-map-action,
.frontend-map-layer-panel button {
  background: #1e293b;
  border: 1px solid #3b4d62;
  border-radius: 0.5rem;
  color: #e2e8f0;
  font-size: 0.8125rem;
  padding: 0.5rem 0.75rem;
}

.frontend-map-action:hover,
.frontend-map-layer-panel button:hover {
  background: #334155;
  border-color: #60a5fa;
}

.frontend-map-layer-panel {
  background: #172230;
  border: 1px solid #3b4d62;
  border-radius: 0.5rem;
  color: #e2e8f0;
  margin: 0 auto 0.75rem;
  max-width: 70rem;
  padding: 0.75rem;
}

.frontend-map-layer-panel__header {
  align-items: center;
  border-bottom: 1px solid #28374a;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: space-between;
  margin-bottom: 0.75rem;
  padding-bottom: 0.5rem;
}

.frontend-map-layer-panel__heading {
  align-items: center;
  display: flex;
  gap: 0.5rem;
}

.frontend-map-layer-panel h2 {
  color: #f8fafc;
  font-size: 0.9375rem;
  font-weight: 700;
  margin: 0;
}

.frontend-map-layer-badge {
  background: #1e293b;
  border: 1px solid #3b4d62;
  border-radius: 9999px;
  color: #94a3b8;
  font-size: 0.6875rem;
  padding: 0.125rem 0.5rem;
}

.frontend-map-layer-panel__actions {
  display: flex;
  gap: 0.375rem;
}

.frontend-map-layer-groups {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
}

.frontend-map-layer-group {
  background: #0f172a;
  border: 1px solid #2a394c;
  border-radius: 0.375rem;
  overflow: hidden;
}

.frontend-map-layer-group__header {
  align-items: center;
  background: #1e293b;
  border-bottom: 1px solid #2a394c;
  display: flex;
  justify-content: space-between;
  padding: 0.375rem 0.625rem;
}

.frontend-map-layer-group__toggle {
  align-items: center;
  background: none;
  border: none;
  color: #f1f5f9;
  cursor: pointer;
  display: flex;
  font-size: 0.8125rem;
  font-weight: 600;
  gap: 0.375rem;
  padding: 0;
}

.frontend-map-layer-group__toggle:hover {
  color: #60a5fa;
}

.frontend-map-layer-group__toggle .group-arrow {
  display: inline-block;
  font-size: 0.6875rem;
  transition: transform 0.15s ease;
}

.frontend-map-layer-group__toggle[aria-expanded="false"] .group-arrow {
  transform: rotate(-90deg);
}

.frontend-map-layer-group__toggle .group-count {
  color: #94a3b8;
  font-size: 0.75rem;
  font-weight: 400;
}

.frontend-map-layer-group__quick-actions {
  display: flex;
  gap: 0.25rem;
}

.btn-group-toggle {
  background: #334155;
  border: 1px solid #475569;
  border-radius: 0.25rem;
  color: #cbd5e1;
  cursor: pointer;
  font-size: 0.6875rem;
  line-height: 1.2;
  padding: 0.125rem 0.375rem;
}

.btn-group-toggle:hover {
  background: #475569;
  color: #f8fafc;
}

.frontend-map-layer-group__content {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  padding: 0.5rem 0.625rem;
}

.frontend-map-layer-group__content[hidden] {
  display: none !important;
}

.frontend-map-layer-item {
  align-items: center;
  cursor: pointer;
  display: inline-flex;
  font-size: 0.8125rem;
  gap: 0.375rem;
  user-select: none;
}

.frontend-map-layer-item input {
  accent-color: #3b82f6;
  cursor: pointer;
  margin: 0;
}

.frontend-map-layer-item__icon {
  height: 1.25rem;
  object-fit: contain;
  width: 1.25rem;
}

.frontend-map-layer-item__name {
  color: #e2e8f0;
}

.frontend-map-layer-item__count {
  color: #94a3b8;
  font-size: 0.75rem;
}

.frontend-map-layer-group--placeholder {
  opacity: 0.75;
}

.badge-upcoming {
  background: #334155;
  border-radius: 0.25rem;
  color: #cbd5e1;
  font-size: 0.625rem;
  padding: 0.125rem 0.375rem;
}

.layer-placeholder-hint {
  color: #94a3b8;
  font-size: 0.75rem;
  line-height: 1.4;
  padding: 0.25rem 0;
}

/* BOSS 標記頭像與角標樣式 */
.frontend-map-boss-div-icon {
  background: transparent;
  border: none;
}

.frontend-map-boss-marker {
  cursor: pointer;
  height: 36px;
  position: relative;
  transition: transform 0.15s ease;
  width: 36px;
}

.frontend-map-boss-marker:hover {
  transform: scale(1.15);
  z-index: 1000 !important;
}

.frontend-map-boss-avatar {
  background: #0f172a;
  border: 2px solid #f59e0b;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.6);
  display: block;
  height: 36px;
  object-fit: cover;
  width: 36px;
}

.frontend-map-boss-level {
  background: #0f172a;
  border: 1px solid #78350f;
  border-radius: 3px;
  bottom: -3px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.8);
  color: #fbbf24;
  font-size: 9px;
  font-weight: 700;
  line-height: 1.2;
  padding: 0 3px;
  position: absolute;
  right: -3px;
  white-space: nowrap;
}

/* BOSS Popup 卡片樣式 */
.frontend-map-boss-popup .leaflet-popup-content-wrapper {
  background: #0f172a;
  border: 1px solid #334155;
  border-radius: 0.5rem;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
  color: #e2e8f0;
}

.frontend-map-boss-popup .leaflet-popup-content {
  font-size: 0.8125rem;
  line-height: 1.5;
  margin: 10px 12px;
}

.frontend-map-boss-popup .leaflet-popup-tip {
  background: #0f172a;
}

.frontend-map-popup-card__header {
  align-items: center;
  border-bottom: 1px solid #2a394c;
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
  padding-bottom: 0.5rem;
}

.frontend-map-popup-card__avatar {
  background: #1e293b;
  border: 1px solid #f59e0b;
  border-radius: 50%;
  height: 36px;
  object-fit: cover;
  width: 36px;
}

.frontend-map-popup-card__title {
  color: #f8fafc;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.2;
  margin: 0;
}

.frontend-map-popup-card__badges {
  display: flex;
  gap: 0.25rem;
  margin-top: 0.125rem;
}

.frontend-map-badge {
  border-radius: 0.25rem;
  font-size: 0.6875rem;
  font-weight: 600;
  padding: 0.125rem 0.375rem;
}

.frontend-map-badge--level {
  background: #78350f;
  color: #fde68a;
}

.frontend-map-badge--type {
  background: #1e293b;
  border: 1px solid #3b4d62;
  color: #94a3b8;
}

.frontend-map-popup-card__meta {
  color: #94a3b8;
  font-size: 0.75rem;
  line-height: 1.4;
}

.frontend-map-popup-card__btn {
  align-items: center;
  background: #2563eb;
  border: 1px solid #3b82f6;
  border-radius: 0.375rem;
  color: #ffffff;
  display: flex;
  font-size: 0.75rem;
  font-weight: 600;
  justify-content: center;
  margin-top: 0.5rem;
  padding: 0.375rem 0.5rem;
  text-decoration: none;
  transition: background 0.15s ease;
}

.frontend-map-popup-card__btn:hover {
  background: #1d4ed8;
  color: #ffffff;
}

.frontend-map-legend {
  color: #cbd5e1;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.75rem;
  gap: 0.75rem;
}

.frontend-map-legend span {
  align-items: center;
  display: inline-flex;
  gap: 0.375rem;
}

.frontend-map-legend__icon {
  height: 1.5rem;
  object-fit: contain;
  width: 1.5rem;
}

.frontend-map-legend__dot,
.frontend-map-legend__travel {
  border: 1px solid #ffffff;
  display: inline-block;
  height: 0.75rem;
  width: 0.75rem;
}

.frontend-map-legend__dot {
  border-radius: 50%;
}

.frontend-map-legend__dot--pal {
  background: #f59e0b;
}

.frontend-map-legend__dot--other {
  background: #60a5fa;
}

.frontend-map-legend__travel {
  background: #22d3ee;
  box-shadow: 0 0 0.375rem rgba(34, 211, 238, 0.85);
  transform: rotate(45deg);
}

.frontend-map-coordinates {
  color: #aab7c7;
  font-size: 0.75rem;
  margin: 0;
  text-align: right;
}

.frontend-map-experience:fullscreen {
  background: #101923;
  overflow: auto;
}

.frontend-map-experience:fullscreen .frontend-map-canvas {
  height: calc(100dvh - 12rem);
  max-width: none;
}

.frontend-map-kicker,
.frontend-map-help {
  color: #aab7c7;
  font-size: 0.8125rem;
  margin: 0;
}

.frontend-map-kicker {
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.frontend-map-title {
  color: #f8fafc;
  font-size: clamp(1.25rem, 2vw, 1.75rem);
  font-weight: 600;
  letter-spacing: -0.02em;
  margin: 0.25rem 0 0;
}

.frontend-map-canvas {
  background: #101923;
  border: 1px solid #2a3a4d;
  height: calc(100dvh - 9rem);
  margin: 0 auto;
  max-width: 70rem;
  min-height: 36rem;
  width: 100%;
}

.frontend-map-canvas.leaflet-container {
  background: #101923;
}

.frontend-map-status {
  color: #aab7c7;
  font-size: 0.8125rem;
  margin: 0.75rem auto 0;
  max-width: 70rem;
}

.boss-map-marker {
  background: transparent;
}

.boss-map-marker__dot {
  border: 2px solid #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 0 1px rgba(15, 23, 42, 0.75);
  display: block;
  height: 0.875rem;
  width: 0.875rem;
}

.boss-map-marker__dot--pal {
  background: #f59e0b;
}

.boss-map-marker__dot--other {
  background: #60a5fa;
}

.fast-travel-map-marker {
  background: transparent;
}

.fast-travel-map-marker__diamond {
  background: #22d3ee;
  border: 2px solid #ecfeff;
  box-shadow: 0 0 0 1px rgba(8, 47, 73, 0.85), 0 0 0.75rem rgba(34, 211, 238, 0.85);
  display: block;
  height: 0.75rem;
  margin: 0.1875rem;
  transform: rotate(45deg);
  width: 0.75rem;
}

.frontend-footer {
  background: var(--frontend-surface);
  border-top: 1px solid var(--frontend-border);
  color: var(--frontend-muted);
  font-size: 0.8125rem;
}

.frontend-footer-content {
  padding: 1.5rem clamp(1rem, 2vw, 2rem);
  text-align: center;
}

.offcanvas .nav-link {
  color: var(--frontend-text);
  font-weight: 500;
  padding-block: 0.75rem;
}

@media (max-width: 767.98px) {
  .frontend-content {
    padding-top: 1.5rem;
  }

  .frontend-page-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 1rem;
  }

  .frontend-page-header .btn,
  .frontend-page-header .btn-group {
    width: 100%;
  }

  .frontend-entry-grid {
    grid-template-columns: 1fr;
  }

  .frontend-map-experience {
    padding: 1rem;
  }

  .frontend-map-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.25rem;
  }

  .frontend-map-tools,
  .frontend-map-meta {
    align-items: stretch;
    flex-direction: column;
  }

  .frontend-map-actions {
    width: 100%;
  }

  .frontend-map-action {
    flex: 1;
  }

  .frontend-map-layer-panel {
    max-height: 65vh;
    overflow-y: auto;
  }

  .frontend-map-layer-panel__header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.5rem;
  }

  .frontend-map-layer-group__content {
    flex-direction: column;
    gap: 0.375rem;
  }

  .frontend-map-coordinates {
    text-align: left;
  }

  .frontend-map-canvas {
    height: calc(100dvh - 9rem);
    min-height: 26rem;
    width: 100%;
  }
}

/* ==========================================================================
   前台互動地圖：個人化探索進度追蹤系統樣式
   ========================================================================== */

.frontend-map-progress-card {
  background: var(--frontend-card-bg, #1e293b);
  border: 1px solid var(--frontend-border, #334155);
  border-radius: 0.5rem;
  padding: 0.875rem;
  margin-bottom: 1rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.2);
}

.frontend-map-progress-card__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.frontend-map-progress-card__title {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--frontend-text, #f8fafc);
  margin: 0;
}

.frontend-map-progress-card__percent {
  font-size: 0.95rem;
  font-weight: 700;
  color: #10b981;
}

.frontend-map-progress-bar-wrap {
  width: 100%;
  height: 0.5rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 9999px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.frontend-map-progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #10b981 0%, #34d399 100%);
  border-radius: 9999px;
  transition: width 0.35s ease;
}

.frontend-map-progress-card__meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.8rem;
  color: var(--frontend-muted, #94a3b8);
  margin-bottom: 0.5rem;
}

.btn-map-reset-progress {
  background: transparent;
  border: none;
  color: #ef4444;
  padding: 0;
  font-size: 0.75rem;
  cursor: pointer;
  text-decoration: underline;
  transition: color 0.2s;
}

.btn-map-reset-progress:hover {
  color: #f87171;
}

.frontend-map-progress-card__filter {
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.frontend-map-filter-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.825rem;
  color: var(--frontend-text, #f8fafc);
  cursor: pointer;
  margin: 0;
  user-select: none;
}

.frontend-map-filter-toggle input[type="checkbox"] {
  cursor: pointer;
  accent-color: #10b981;
}

/* 標記完成狀態樣式（半透明＋平滑過渡） */
.frontend-map-marker--completed {
  opacity: 0.42 !important;
  filter: grayscale(35%) contrast(85%);
  transition: opacity 0.25s ease, filter 0.25s ease;
}

.frontend-map-marker--completed:hover {
  opacity: 0.85 !important;
  filter: none;
}

/* 標記彈窗內的打勾按鈕 */
.frontend-map-popup-actions {
  margin-top: 0.75rem;
  padding-top: 0.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
}

.btn-progress-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 0.4rem 0.75rem;
  font-size: 0.825rem;
  font-weight: 600;
  border-radius: 0.375rem;
  cursor: pointer;
  border: 1px solid #10b981;
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  transition: all 0.2s ease;
}

.btn-progress-toggle:hover {
  background: #10b981;
  color: #ffffff;
}

.btn-progress-toggle--active {
  background: rgba(100, 116, 139, 0.2);
  border-color: #64748b;
  color: #94a3b8;
}

.btn-progress-toggle--active:hover {
  background: rgba(239, 68, 68, 0.15);
  border-color: #ef4444;
  color: #ef4444;
}

/* ==========================================================================
   BOSS 標記頭像與等級角標樣式（比照 PalDB 精緻小巧設計）
   ========================================================================== */

.frontend-map-boss-div-icon {
  background: transparent !important;
  border: none !important;
}

.frontend-map-boss-marker {
  position: relative;
  width: 34px !important;
  height: 34px !important;
  border-radius: 50% !important;
  background: #1e293b;
  border: 2px solid #ffffff;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.45);
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  cursor: pointer;
  box-sizing: border-box;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.frontend-map-boss-marker:hover {
  transform: scale(1.2);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.6);
  z-index: 1000 !important;
}

.frontend-map-boss-avatar {
  width: 30px !important;
  height: 30px !important;
  max-width: 30px !important;
  max-height: 30px !important;
  border-radius: 50% !important;
  object-fit: cover !important;
  display: block !important;
  pointer-events: none;
}

.frontend-map-boss-level {
  position: absolute !important;
  bottom: -4px !important;
  right: -5px !important;
  background: rgba(15, 23, 42, 0.92) !important;
  color: #facc15 !important;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif !important;
  font-size: 9px !important;
  font-weight: 800 !important;
  padding: 1px 3px !important;
  border-radius: 3px !important;
  border: 1px solid rgba(250, 204, 21, 0.6) !important;
  line-height: 1 !important;
  letter-spacing: -0.2px;
  pointer-events: none;
  white-space: nowrap !important;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.7) !important;
  z-index: 2;
}

/* BOSS 彈窗卡片樣式 */
.frontend-map-boss-popup .leaflet-popup-content-wrapper {
  background: #1e293b;
  color: #f8fafc;
  border-radius: 0.5rem;
  border: 1px solid #334155;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
  padding: 0;
}

.frontend-map-boss-popup .leaflet-popup-content {
  margin: 0.75rem;
  line-height: 1.4;
}

.frontend-map-popup-card__header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.625rem;
}

.frontend-map-popup-card__avatar {
  width: 48px !important;
  height: 48px !important;
  max-width: 48px !important;
  max-height: 48px !important;
  border-radius: 50% !important;
  background: #0f172a;
  border: 2px solid rgba(255, 255, 255, 0.2);
  object-fit: cover !important;
  flex-shrink: 0;
}

.frontend-map-popup-card__title {
  font-size: 1rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0 0 0.25rem 0;
}

.frontend-map-popup-card__badges {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.frontend-map-badge {
  font-size: 0.7rem;
  padding: 0.15rem 0.4rem;
  border-radius: 0.25rem;
  font-weight: 600;
}

.frontend-map-badge--level {
  background: rgba(250, 204, 21, 0.15);
  color: #facc15;
  border: 1px solid rgba(250, 204, 21, 0.4);
}

.frontend-map-badge--type {
  background: rgba(99, 102, 241, 0.15);
  color: #a5b4fc;
  border: 1px solid rgba(99, 102, 241, 0.4);
}

.frontend-map-popup-card__meta {
  font-size: 0.75rem;
  color: #94a3b8;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 0.375rem;
  padding: 0.5rem;
  margin-bottom: 0.625rem;
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.frontend-map-popup-card__btn {
  display: block;
  text-align: center;
  background: #3b82f6;
  color: #ffffff !important;
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.35rem 0.5rem;
  border-radius: 0.375rem;
  text-decoration: none;
  transition: background 0.2s;
  margin-bottom: 0.5rem;
}

.frontend-map-popup-card__btn:hover {
  background: #2563eb;
  color: #ffffff !important;
}

/* ==========================================================================
   道具圖鑑專屬設計系統 (Item Cards & Grid)
   ========================================================================== */
.item-category-scroll {
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  margin-bottom: 1.25rem;
  scrollbar-width: thin;
}
.item-category-pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.85rem;
  border-radius: 2rem;
  font-size: 0.8125rem;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  color: #475569;
  transition: all 0.2s ease;
}
.item-category-pill:hover {
  background: #f1f5f9;
  color: #2563eb;
  border-color: #cbd5e1;
  transform: translateY(-1px);
}
.item-category-pill.active {
  background: #3b82f6;
  border-color: #3b82f6;
  color: #ffffff;
  box-shadow: 0 2px 6px rgba(59, 130, 246, 0.3);
}

/* 道具卡片網格 */
.item-grid {
  margin-bottom: 1.5rem;
}
.item-card {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 0.75rem;
  overflow: hidden;
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
.item-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
}
.item-card-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  padding: 0.875rem;
  text-decoration: none;
  color: inherit;
}
.item-card-inner:hover {
  color: inherit;
}

/* 稀有度邊框與微光色彩 */
.item-card.rarity-common { border-top: 3px solid #94a3b8; }
.item-card.rarity-uncommon { border-top: 3px solid #22c55e; }
.item-card.rarity-rare { border-top: 3px solid #3b82f6; }
.item-card.rarity-epic { border-top: 3px solid #a855f7; }
.item-card.rarity-legendary { border-top: 3px solid #f59e0b; box-shadow: 0 2px 8px rgba(245, 158, 11, 0.12); }
.item-card.rarity-mythic { border-top: 3px solid #ef4444; box-shadow: 0 2px 8px rgba(239, 68, 68, 0.15); }

/* 道具頭像容器 */
.item-icon-wrapper {
  position: relative;
  width: 72px;
  height: 72px;
  margin: 0.25rem auto 0.625rem auto;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 0.5rem;
  background: #f8fafc;
  border: 1px solid #f1f5f9;
}
.item-icon-img {
  width: 58px;
  height: 58px;
  object-fit: contain;
  transition: transform 0.25s ease;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.15));
}
.item-card:hover .item-icon-img {
  transform: scale(1.08);
}

/* 道具標題與標籤 */
.item-title {
  font-size: 0.875rem;
  font-weight: 700;
  color: #1e293b;
  text-align: center;
  margin-bottom: 0.35rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.item-badge-row {
  display: flex;
  justify-content: center;
  gap: 0.25rem;
  margin-bottom: 0.5rem;
  flex-wrap: wrap;
}
.item-badge {
  font-size: 0.6875rem;
  padding: 0.15rem 0.4rem;
  border-radius: 0.25rem;
  font-weight: 600;
  line-height: 1.2;
}
.item-badge-category {
  background: #f1f5f9;
  color: #475569;
}
.item-badge-rarity {
  color: #ffffff;
}
.item-badge-rarity.rarity-common { background: #64748b; }
.item-badge-rarity.rarity-uncommon { background: #16a34a; }
.item-badge-rarity.rarity-rare { background: #2563eb; }
.item-badge-rarity.rarity-epic { background: #9333ea; }
.item-badge-rarity.rarity-legendary { background: #d97706; }
.item-badge-rarity.rarity-mythic { background: #dc2626; }

/* 道具底端資訊 */
.item-info-footer {
  margin-top: auto;
  padding-top: 0.4rem;
  border-top: 1px solid #f1f5f9;
  display: flex;
  justify-content: space-between;
  font-size: 0.6875rem;
  color: #64748b;
}

/* ==========================================================================
   前台雙色系視覺控制層（Frontend Theme System & Contrast Enforcement）
   確保明色系與暗色系下人類視覺反差清晰，UI 顏色完整統一，絕不出現色系失調
   ========================================================================== */

/* --- 1. 詳情頁 Hero 標題看板面板 --- */
.item-detail-hero-box {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.25rem;
  background: var(--frontend-surface-card);
  border-radius: 0.75rem;
  border: 1px solid var(--frontend-border);
  box-shadow: var(--frontend-card-shadow);
  margin-bottom: 1.5rem;
  color: var(--frontend-text);
}

.item-detail-avatar {
  width: 96px;
  height: 96px;
  border-radius: 0.75rem;
  background: var(--frontend-surface-alt);
  border: 1px solid var(--frontend-border);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.item-detail-avatar img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.15));
}

/* --- 2. AI Quick Answer 摘要卡片 --- */
.quick-answer-card,
#section-quick-answer {
  background: var(--frontend-quick-answer-bg) !important;
  border-left: 4px solid var(--frontend-quick-answer-border) !important;
  border-radius: 0.5rem;
}

.quick-answer-card p,
#section-quick-answer p {
  color: var(--frontend-quick-answer-text) !important;
}

/* --- 3. 暗色系模式強制適配與對比度反差增強 --- */
html.dark-style {
  color-scheme: dark;
}

/* 暗色系卡片與容器 */
html.dark-style .card {
  background-color: var(--frontend-surface-card) !important;
  border-color: var(--frontend-border) !important;
  color: var(--frontend-text) !important;
  box-shadow: var(--frontend-card-shadow);
}

/* 強制修復卡片標頭在暗色下被 bg-white 污染的問題 */
html.dark-style .card-header,
html.dark-style .card-header.bg-white,
html.dark-style .card-footer,
html.dark-style .card-footer.bg-white {
  background-color: var(--frontend-surface-header) !important;
  border-color: var(--frontend-border) !important;
  color: var(--frontend-text-dark) !important;
}

/* 強制暗色系文字高對比度反差 */
html.dark-style .text-dark,
html.dark-style h1.text-dark,
html.dark-style h2.text-dark,
html.dark-style h3.text-dark,
html.dark-style h4.text-dark,
html.dark-style h5.text-dark,
html.dark-style h6.text-dark,
html.dark-style span.text-dark,
html.dark-style p.text-dark,
html.dark-style strong.text-dark,
html.dark-style div.text-dark,
html.dark-style a.text-dark {
  color: var(--frontend-text-dark) !important;
}

html.dark-style .text-muted,
html.dark-style small.text-muted {
  color: var(--frontend-muted) !important;
}

html.dark-style .text-secondary {
  color: #b4b7bd !important;
}

/* 列表清單在暗色模式下的背景與邊框 */
html.dark-style .list-group-item {
  background-color: var(--frontend-surface-card) !important;
  border-color: var(--frontend-border) !important;
  color: var(--frontend-text) !important;
}

html.dark-style .list-group-item:hover {
  background-color: rgba(255, 255, 255, 0.03) !important;
}

/* 邊框顏色對齊 */
html.dark-style .border,
html.dark-style .border-top,
html.dark-style .border-bottom,
html.dark-style .border-start,
html.dark-style .border-end {
  border-color: var(--frontend-border) !important;
}

/* 鍵盤快捷鍵提示 */
html.dark-style kbd {
  background-color: rgba(255, 255, 255, 0.1);
  color: #f1f5f9;
  border: 1px solid var(--frontend-border);
}

/* 按鈕適配 */
html.dark-style .btn-outline-primary {
  color: #7e82ff;
  border-color: #696cff;
}
html.dark-style .btn-outline-primary:hover {
  background-color: #696cff;
  color: #ffffff;
}

html.dark-style .btn-outline-secondary {
  color: #cbc8e0;
  border-color: var(--frontend-border);
}
html.dark-style .btn-outline-secondary:hover {
  background-color: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  border-color: #7e82ff;
}

/* 麵包屑導覽 */
html.dark-style .breadcrumb-item,
html.dark-style .breadcrumb-item a {
  color: var(--frontend-muted);
}
html.dark-style .breadcrumb-item a:hover {
  color: #7e82ff;
}
html.dark-style .breadcrumb-item.active {
  color: var(--frontend-text-dark);
}

/* 表格與 DataTables 暗色適配 */
html.dark-style table.dataTable,
html.dark-style .table {
  color: var(--frontend-text);
  border-color: var(--frontend-border);
}
html.dark-style table.dataTable thead th,
html.dark-style .table thead th {
  background-color: rgba(255, 255, 255, 0.03) !important;
  color: var(--frontend-text-dark) !important;
  border-color: var(--frontend-border) !important;
}
html.dark-style table.dataTable tbody td,
html.dark-style .table tbody td {
  background-color: var(--frontend-surface-card) !important;
  color: var(--frontend-text) !important;
  border-color: var(--frontend-border) !important;
}
html.dark-style table.dataTable tbody tr:hover td,
html.dark-style .table tbody tr:hover td {
  background-color: rgba(255, 255, 255, 0.04) !important;
}

/* ==========================================================================
   Trust & Legal Pages (About, Data Sources, Changelog) - Light & Dark Modes
   ========================================================================== */
.trust-header-title {
  color: var(--frontend-text-dark) !important;
}

.trust-section-title {
  color: var(--frontend-text-dark) !important;
}

.trust-card {
  background-color: var(--frontend-surface-card) !important;
  border: 1px solid var(--frontend-border) !important;
  border-radius: var(--frontend-radius);
  box-shadow: var(--frontend-card-shadow);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.trust-card:hover {
  border-color: var(--frontend-primary) !important;
}

.trust-card-header {
  background-color: var(--frontend-surface-alt) !important;
  border-bottom: 1px solid var(--frontend-border) !important;
}

.trust-disclaimer-card {
  background-color: var(--frontend-surface-card) !important;
  border: 1px solid rgba(255, 171, 0, 0.45) !important;
  border-radius: var(--frontend-radius);
  box-shadow: var(--frontend-card-shadow);
}

.trust-disclaimer-header {
  background-color: rgba(255, 171, 0, 0.08) !important;
  border-bottom: 1px solid rgba(255, 171, 0, 0.2) !important;
}

.trust-clause-box {
  background-color: var(--frontend-surface-alt) !important;
  border: 1px solid var(--frontend-border) !important;
  border-radius: 0.5rem;
  padding: 1rem 1.25rem;
  transition: background-color 0.2s ease;
}

.trust-clause-title {
  color: #b26a00 !important;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.trust-clause-text {
  color: var(--frontend-text) !important;
  font-size: 0.9rem;
  line-height: 1.65;
  margin-bottom: 0;
}

.trust-formula-box {
  background-color: var(--frontend-surface-alt) !important;
  border: 1px solid var(--frontend-border) !important;
  color: var(--frontend-primary-dark) !important;
  border-radius: 0.5rem;
}

html.dark-style .trust-disclaimer-card {
  border-color: rgba(255, 171, 0, 0.35) !important;
}

html.dark-style .trust-disclaimer-header {
  background-color: rgba(255, 171, 0, 0.12) !important;
  border-bottom-color: rgba(255, 171, 0, 0.25) !important;
}

html.dark-style .trust-clause-box {
  background-color: rgba(255, 255, 255, 0.03) !important;
  border-color: rgba(255, 255, 255, 0.08) !important;
}

html.dark-style .trust-clause-title {
  color: #ffc107 !important;
}

html.dark-style .trust-clause-text {
  color: #e2e8f0 !important;
}

html.dark-style .trust-formula-box {
  background-color: rgba(0, 0, 0, 0.35) !important;
  border-color: var(--frontend-border) !important;
  color: #38bdf8 !important;
}

/* 網站圖片設定：非地圖頁以背景層套用，避免增加內容型 DOM。 */
body.frontend-non-map-page.frontend-has-image-side-left,
body.frontend-non-map-page.frontend-has-image-side-right {
  background-color: var(--frontend-background);
  background-image: var(--site-image-side-left, none), var(--site-image-side-right, none);
  background-position: left center, right center;
  background-repeat: no-repeat, no-repeat;
  background-size: min(18vw, 22rem) auto, min(18vw, 22rem) auto;
  background-attachment: fixed, fixed;
}

.frontend-brand__logo {
  display: block;
  width: auto;
  height: 2.25rem;
  max-width: min(15rem, 40vw);
  object-fit: contain;
  object-position: left center;
}

body.frontend-non-map-page.frontend-has-image-general-card .frontend-content .card,
body.frontend-non-map-page.frontend-has-image-general-card .frontend-panel,
body.frontend-non-map-page.frontend-has-image-general-card .frontend-entry,
body.frontend-non-map-page.frontend-has-image-general-card .frontend-mobile-list-item,
body.frontend-non-map-page.frontend-has-image-general-card .item-card {
  background-image: linear-gradient(rgba(30, 41, 59, 0.82), rgba(30, 41, 59, 0.9)), var(--site-image-general-card, none);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

body.frontend-non-map-page.frontend-has-image-home-hero .home-hero-card {
  background-image: linear-gradient(rgba(15, 23, 42, 0.5), rgba(15, 23, 42, 0.74)), var(--site-image-home-hero, none) !important;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

body.frontend-non-map-page.frontend-has-image-general-card .home-feature-card {
  background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-general-card, none) !important;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

body.frontend-non-map-page.frontend-has-image-home-card-items .home-feature-card:nth-child(1) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-items) !important; }
body.frontend-non-map-page.frontend-has-image-home-card-entities .home-feature-card:nth-child(2) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-entities) !important; }
body.frontend-non-map-page.frontend-has-image-home-card-breeding .home-feature-card:nth-child(3) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-breeding) !important; }
body.frontend-non-map-page.frontend-has-image-home-card-tech .home-feature-card:nth-child(4) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-tech) !important; }
body.frontend-non-map-page.frontend-has-image-home-card-map .home-feature-card:nth-child(5) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-map) !important; }
body.frontend-non-map-page.frontend-has-image-home-card-stations .home-feature-card:nth-child(6) { background-image: linear-gradient(rgba(15, 23, 42, 0.68), rgba(15, 23, 42, 0.88)), var(--site-image-home-card-stations) !important; }

@media (max-width: 1199.98px) {
  body.frontend-non-map-page.frontend-has-image-side-left,
  body.frontend-non-map-page.frontend-has-image-side-right {
    background-image: none;
  }
}

