/**
 * TOP / 地価公示ダッシュボード：後付け UI（既存マークアップ・既存スクリプト非改変）
 */

.lib-map-title {
  position: absolute;
  top: 16px;
  left: 16px;
  font-size: 24px;
  font-weight: 700;
  color: #111;
  background: rgba(255, 255, 255, 0.92);
  padding: 10px 14px;
  border-radius: 10px;
  z-index: 50;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.12);
  pointer-events: none;
}

.hidden-by-ai {
  display: none !important;
}

/*
 * サイトマップ＝地価公示ダッシュボード .lib-filter-card と同一トークンの「白カード枠」
 * background / border / border-radius / padding / box-shadow を文字単位で揃える
 *
 * TOP フッターは Python build_dark_footer_sitemap_html の
 * details.lib-st-expander[data-testid="stExpander"]（st-sitemap-expander ではない）。
 */
#app section[data-section="cta_footer"] details.lib-st-expander[data-testid="stExpander"],
#app.lib-app--top details.lib-expander.st-sitemap-expander,
#app.lib-app--top details.st-sitemap-expander.lib-expander {
  background: #fff !important;
  border: 1px solid rgba(15, 28, 46, 0.12) !important;
  border-radius: 16px !important;
  padding: 1rem 1.1rem !important;
  box-shadow: 0 8px 28px rgba(15, 28, 46, 0.06) !important;
  margin: 1rem 0 !important;
  box-sizing: border-box !important;
  max-width: 100%;
  overflow: hidden;
}

/* 内側に別カード風の枠が重なるのを抑え、一枚の白カードに見せる */
#app section[data-section="cta_footer"] details.lib-st-expander .stColumn,
#app section[data-section="cta_footer"] details.lib-st-expander [data-testid="column"],
#app.lib-app--top details.st-sitemap-expander .stColumn,
#app.lib-app--top details.st-sitemap-expander [data-testid="column"] {
  background: transparent !important;
  box-shadow: none !important;
  border: none !important;
}

#app section[data-section="cta_footer"] details.lib-st-expander > summary,
#app.lib-app--top details.st-sitemap-expander > summary,
#app.lib-app--top details.st-sitemap-expander > summary.st-node--sitemap-expander-summary {
  cursor: pointer;
  font-weight: 800 !important;
  font-size: clamp(1rem, 2.2vw, 1.2rem) !important;
  color: #0f1c2e !important;
  letter-spacing: 0.02em;
  padding: 0.2rem 0 0.65rem !important;
  margin: 0 !important;
  border-bottom: 1px solid rgba(15, 28, 46, 0.08);
  list-style: none;
  background: transparent !important;
}

#app section[data-section="cta_footer"] details.lib-st-expander > summary::-webkit-details-marker,
#app section[data-section="cta_footer"] details.lib-st-expander > summary::marker,
#app.lib-app--top details.st-sitemap-expander > summary::-webkit-details-marker,
#app.lib-app--top details.st-sitemap-expander > summary::marker {
  display: none;
}

/* DSL: .st-sitemap-block-title / フッター HTML: <p><strong>見出し</strong></p>（段落に余白） */
#app section[data-section="cta_footer"] details.lib-st-expander .stMarkdown p {
  margin: 1rem 0 0.45rem !important;
}

#app section[data-section="cta_footer"] details.lib-st-expander .stMarkdown p strong {
  font-size: 0.8rem !important;
  font-weight: 700 !important;
  color: #334155 !important;
  letter-spacing: 0.01em;
}

#app.lib-app--top details.st-sitemap-expander .st-sitemap-block-title {
  font-size: 0.8rem !important;
  font-weight: 700 !important;
  color: #334155 !important;
  margin: 1rem 0 0.45rem !important;
  letter-spacing: 0.01em;
}

#app section[data-section="cta_footer"]
  details.lib-st-expander
  [data-testid="stVerticalBlock"]
  > [data-testid="stMarkdown"]:first-child
  p,
#app.lib-app--top details.st-sitemap-expander .st-sitemap-block-title:first-of-type {
  margin-top: 0.75rem !important;
}

#app section[data-section="cta_footer"] details.lib-st-expander .stHorizontalBlock,
#app section[data-section="cta_footer"] details.lib-st-expander .st-horizontal-block,
#app.lib-app--top details.st-sitemap-expander .stHorizontalBlock,
#app.lib-app--top details.st-sitemap-expander .st-horizontal-block {
  margin-top: 0.35rem;
  margin-bottom: 0.25rem;
}

/* ナビボタンはフィルタ内コントロールに近い角丸・枠（白地のまま） */
#app section[data-section="cta_footer"] details.lib-st-expander button.lib-st-secondary-btn,
#app section[data-section="cta_footer"] details.lib-st-expander .lib-st-secondary-btn,
#app.lib-app--top details.st-sitemap-expander button.lib-btn,
#app.lib-app--top details.st-sitemap-expander .lib-btn {
  border-radius: 8px !important;
  box-sizing: border-box;
}

#app section[data-section="cta_footer"] details.lib-st-expander button.lib-st-secondary-btn,
#app section[data-section="cta_footer"] details.lib-st-expander .lib-st-secondary-btn,
#app.lib-app--top details.st-sitemap-expander button.lib-btn--secondary,
#app.lib-app--top details.st-sitemap-expander .lib-btn--secondary {
  background: #fff !important;
  border: 1px solid rgba(15, 28, 46, 0.18) !important;
  color: #0f1c2e !important;
}
