/* AXIOM_MY_CITY_DARK_FIX_V951
   Visual-only corrections to AXIOM My City v9.5.
   Uses the site's native html[data-axiom-theme] state.
   Never hides news, changes city selection, touches database or services.
*/

/* Modal group titles were the last white blocks in the dark theme. */
html[data-axiom-theme="dark"] .axrg-modal {
  --city-card: #22242e;
  --city-card-hover: #30323f;
  --city-control: #292b36;
  --city-line: #454855;
  --city-ink: #f4f5f8;
  --city-muted: #b6bac9;
  --city-accent: #e75060;
  --city-accent-text: #ff9da6;
  --city-accent-soft: #392831;
  color-scheme: dark;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-shade {
  background: rgba(5, 7, 13, .48) !important;
  -webkit-backdrop-filter: blur(2px);
  backdrop-filter: blur(2px);
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-dialog {
  background: #22242e !important;
  color: #f4f5f8 !important;
  border: 1px solid #424553 !important;
  border-radius: 17px !important;
  box-shadow: 0 24px 64px rgba(0,0,0,.36) !important;
}
html[data-axiom-theme="dark"] .axrg-modal :is(.axrg-dialoghead,.axrg-options,.axrg-dialog-footer) {
  background: #22242e !important;
  color: #f4f5f8 !important;
  border-color: #414450 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-group-title {
  display: block;
  background: #30323e !important;
  color: #c0c4d3 !important;
  border: 1px solid #414450 !important;
  border-radius: 6px;
  padding: 8px 10px;
  line-height: 1.35;
  letter-spacing: .06em;
  font-weight: 750;
}
html[data-axiom-theme="dark"] .axrg-modal :is(h2,.axrg-choice-info strong) {
  color: #f6f7fb !important;
}
html[data-axiom-theme="dark"] .axrg-modal :is(.axrg-dialoghead p,.axrg-search-label span,.axrg-choice-info small,.axrg-dialog-footer) {
  color: #b8bdcd !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice {
  background: #272934 !important;
  border: 1px solid #444755 !important;
  color: #f3f4f8 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice:hover,
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice:focus-visible {
  background: #333644 !important;
  border-color: #838b9d !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice.chosen,
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice[aria-selected="true"] {
  background: #3c2933 !important;
  border-color: #de5667 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-choice-pin {
  background: transparent !important;
  border: none !important;
  color: #c2c6d5 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-close {
  background: #30323e !important;
  color: #f4f5f8 !important;
  border-color: #4b4e5e !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-close:hover {
  background: #414451 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-city-search {
  background: #2b2e3a !important;
  color: #f5f6fa !important;
  border: 1px solid #555967 !important;
  box-shadow: none !important;
  outline: none !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-city-search:focus {
  border-color: #e85c6c !important;
  box-shadow: 0 0 0 2px rgba(232,92,108,.18) !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-city-search::placeholder {
  color: #b3b7c6 !important;
  opacity: 1;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-source-live {
  color: #8ce0a8 !important;
}
html[data-axiom-theme="dark"] .axrg-modal .axrg-options {
  scrollbar-color: #535766 #22242e;
  scrollbar-width: thin;
}

/* Public page: keep the dark background, but raise card/text contrast. */
html[data-axiom-theme="dark"] #axrg-root {
  --city-ink: #f4f5f8;
  --city-muted: #b6bac8;
  --city-line: #393c48;
  --city-card: #252731;
  --city-card-hover: #30323e;
  --city-control: #2b2d39;
  --city-accent-text: #ff9ba5;
}
html[data-axiom-theme="dark"] #axrg-root :is(.axrg-header,.axrg-tabbar,.axrg-dayhead,.axrg-important,.axrg-timeline) {
  border-color: #3a3d48 !important;
}
html[data-axiom-theme="dark"] #axrg-root :is(.axrg-head-title h1,.axrg-sectionhead h2,.axrg-dayhead h3,.axrg-card-main strong,.axrg-story h1) {
  color: #f4f5f8 !important;
}
html[data-axiom-theme="dark"] #axrg-root :is(.axrg-kicker,.axrg-head-title p,.axrg-card-description,.axrg-card-eyebrow,.axrg-updated,.axrg-dayhead span,.axrg-timeline-sub) {
  color: #b7bac7 !important;
}
html[data-axiom-theme="dark"] #axrg-root .axrg-card {
  background: #252731 !important;
  border-color: #3e414e !important;
}
html[data-axiom-theme="dark"] #axrg-root .axrg-card:hover {
  background: #2d303c !important;
  border-color: #dc4d5e !important;
  box-shadow: 0 7px 24px rgba(0,0,0,.20) !important;
}
html[data-axiom-theme="dark"] #axrg-root .axrg-select,
html[data-axiom-theme="dark"] #axrg-root .axrg-refresh {
  background: #2b2d39 !important;
  border-color: #454855 !important;
  color: #f3f4f8 !important;
}
html[data-axiom-theme="dark"] #axrg-root .axrg-select:hover,
html[data-axiom-theme="dark"] #axrg-root .axrg-refresh:hover {
  background: #373945 !important;
  border-color: #da5362 !important;
}
html[data-axiom-theme="dark"] #axrg-root .axrg-tabs button.active,
html[data-axiom-theme="dark"] #axrg-root .axrg-tabs button[aria-selected="true"] {
  background: #38262e !important;
  color: #ff9da7 !important;
  border-color: #ec9eaa !important;
}

/* Regional admin: update dark-only controls and list separators. */
html[data-axiom-theme="dark"] #axr-workspace :is(.axr-card,.axr-aside-card,.axr-tile,.axr-source-row,.axr-source-form-card) {
  background: #252731 !important;
  border-color: #414451 !important;
}
html[data-axiom-theme="dark"] #axr-workspace :is(.axr-card h2,.axr-card h3,.axr-source-title strong) {
  color: #f5f6fa !important;
}
html[data-axiom-theme="dark"] #axr-workspace :is(.axr-line,.axr-source-row,.axr-tabs,.axr-source-list) {
  border-color: #414451 !important;
}
html[data-axiom-theme="dark"] #axr-workspace :is(input:not([type=checkbox]),select,textarea) {
  background: #2b2d39 !important;
  color: #f4f5f8 !important;
  border-color: #555966 !important;
}

/* Light mode stays light, including the city grouping labels. */
html[data-axiom-theme="light"] .axrg-modal .axrg-group-title {
  background: #f2f3f6 !important;
  color: #666d7c !important;
  border-color: #e3e5ec !important;
}

@media (prefers-reduced-motion: reduce) {
  .axrg-modal .axrg-dialog,
  .axrg-modal .axrg-choice,
  #axrg-root .axrg-card { transition: none !important; }
}
