/* ===============================
   Global Dark Theme
   =============================== */
.theme-dark { color-scheme: dark; }
.theme-dark body { background:#0b1220; color:#e5e7eb; }





/* Main cards */
.theme-dark .card,
.theme-dark .dash-card,
.theme-dark .welcome-card,
.theme-dark .quote-card,
.theme-dark .feature-item,
.theme-dark .quick-cta .qa-chip,
.theme-dark .dash-link {
  background:#0f172a !important;   /* deep navy/black */
  color:#e5e7eb !important;        /* white text */
  border-color:#1f2a44 !important;
  box-shadow:none !important;      /* optional, flatter dark look */
}

/* Hero banners keep gradient but adjust text */
.theme-dark .welcome-hero {
  background: linear-gradient(135deg,#312e81,#0c4a6e);
}
.theme-dark .welcome-hero h2,
.theme-dark .welcome-hero .lead { color:#f1f5f9; }

/* Pills / chips */
.theme-dark .welcome-badge {
  background:#1e293b !important;
  color:#f8fafc !important;
  border:1px solid #334155 !important;
}
.theme-dark .qa-chip {
  background:#1e293b !important;
  color:#f8fafc !important;
  border:1px solid #334155 !important;
}

/* Feature icons */
.theme-dark .fi-icon {
  background:#1e293b !important;
  color:#f8fafc !important;
  box-shadow:none !important;
  border:1px solid #334155 !important;
}
.theme-dark .fi-body h6,
.theme-dark .fi-body p { color:#f8fafc !important; }

/* Quote card tweaks */
.theme-dark .quote-card:before {
  background: linear-gradient(180deg,#6d28d9,#0ea5e9);
}
.theme-dark .quote-card blockquote { color:#e5e7eb !important; }
.theme-dark .quote-card .text-sm,
.theme-dark .quote-card .poem-points li { color:#e5e7eb !important; }

/* Links (limit recolour sitewide only if you want) */
.theme-dark a { color:#93c5fd; }
.theme-dark a:hover { color:#bfdbfe; }

/* Form elements (general, keeps most inputs dark) */
.theme-dark .form-control,
.theme-dark .form-select,
.theme-dark input,
.theme-dark textarea {
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:#213250 !important;
}
.theme-dark .form-control::placeholder { color:#94a3b8; }

/* Muted text */
.theme-dark .text-muted,
.theme-dark small { color:#ffffff !important; }

/* --- Fix double knob in DARK MODE only --- */
.theme-dark .form-switch .form-check-input::before {
  content: none !important;          /* remove any custom pseudo-element knob */
}

/* Ensure the Bootstrap SVG knob renders once, correctly positioned */
.theme-dark .form-switch .form-check-input {
  background-color: #1f2937 !important;  /* track OFF */
  border-color: #334155 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23ffffff'/%3e%3c/svg%3e") !important;
  background-repeat: no-repeat !important;
  background-size: 1em 1em !important;
  background-position: left center !important;   /* OFF position */
}
.theme-dark .form-switch .form-check-input:checked {
  background-color: #0ea5e9 !important;          /* track ON */
  border-color: #0ea5e9 !important;
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'%3e%3ccircle r='3' fill='%23ffffff'/%3e%3c/svg%3e") !important;
  background-position: right center !important;  /* ON position */
}

/* ===============================
   KEEP SEARCH UI LIGHT (overrides)
   =============================== */

/* Core WP + Gutenberg search */
.theme-dark .wp-block-search__input,
.theme-dark .wp-block-search input[type="search"],
.theme-dark input[type="search"],
.theme-dark input[name="s"],
.theme-dark form[role="search"] input,
.theme-dark form[role="search"] select,
.theme-dark form.search-form input,
.theme-dark form.search-form select { 
  background:#ffffff !important;
  color:#000000 !important;
  border-color:#ccc !important;
  box-shadow:none !important;
}
.theme-dark .wp-block-search__input::placeholder,
.theme-dark .wp-block-search input[type="search"]::placeholder,
.theme-dark input[type="search"]::placeholder,
.theme-dark input[name="s"]::placeholder,
.theme-dark form[role="search"] input::placeholder,
.theme-dark form.search-form input::placeholder {
  color:#666 !important;
}

/* Common custom search wrappers you use across the site */
.theme-dark .search-container input,
.theme-dark .search-container select,
.theme-dark .search-bar input,
.theme-dark .search-bar select,
.theme-dark .property-search input,
.theme-dark .property-search select,
.theme-dark .hero-search input,
.theme-dark .hero-search select {
  background:#ffffff !important;
  color:#000000 !important;
  border-color:#ccc !important;
}

/* If your search inputs also have .form-control, beat the .form-control rule */
.theme-dark .search-container .form-control,
.theme-dark .search-bar .form-control,
.theme-dark .property-search .form-control,
.theme-dark .hero-search .form-control,
.theme-dark form.search-form .form-control,
.theme-dark form[role="search"] .form-control {
  background:#ffffff !important;
  color:#000000 !important;
  border-color:#ccc !important;
}

/* Optional: keep search submit buttons light too (tweak if needed) */
.theme-dark .search-container .btn,
.theme-dark .search-bar .btn,
.theme-dark .property-search .btn,
.theme-dark .hero-search .btn,
.theme-dark .wp-block-search .wp-block-search__button,
.theme-dark form.search-form button[type="submit"] {
  filter:none !important;
  /* comment out next line if you prefer your brand colour */
  background:#ffffff !important;
  color:#0f172a !important;
  border-color:#d1d5db !important;
}

/* ===============================
   DARK THEME TOKENS
   =============================== */
.theme-dark {
  --dm-bg:        #0b1220;  /* body */
  --dm-surface:   #0f172a;  /* cards/panels */
  --dm-surface-2: #111a2f;  /* subtle raised */
  --dm-text:      #e5e7eb;
  --dm-text-2:    #94a3b8;  /* muted */
  --dm-border:    #1f2a44;
  --dm-link:      #93c5fd;
  --dm-link-h:    #bfdbfe;
}


/* Optional: labels/help text near fields */
.theme-dark .form-label,
.theme-dark .form-text {
  color: #e5e7eb !important;
}

/* Base surfaces + text — only under <main> and footer */
.theme-dark main,
.theme-dark main .container,
.theme-dark main .container-fluid,
.theme-dark main section,
.theme-dark footer {
  background-color: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Components/utilities — only inside <main> */
.theme-dark main .bg-white,
.theme-dark main .bg-light,
.theme-dark main .bg-body,
.theme-dark main .card,
.theme-dark main .card-header,
.theme-dark main .card-body,
.theme-dark main .card-footer,
.theme-dark main .list-group-item,
.theme-dark main .accordion-item,
.theme-dark main .accordion-body,
.theme-dark main .table {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
}

/* Navbars/dropdowns that live in content (not the header) */
.theme-dark main .navbar,
.theme-dark main .dropdown-menu {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
}




.theme-dark .border,
.theme-dark .border-top,
.theme-dark .border-end,
.theme-dark .border-bottom,
.theme-dark .border-start { border-color: var(--dm-border) !important; }

.theme-dark h1, .theme-dark h2, .theme-dark h3,
.theme-dark h4, .theme-dark h5, .theme-dark h6 {
  color: #f1f5f9 !important;
}
.theme-dark .text-dark, .theme-dark .text-body, .theme-dark .text-black { color: var(--dm-text) !important; }
.theme-dark .text-muted, .theme-dark .text-secondary { color: var(--dm-text-2) !important; }
.theme-dark a { color: var(--dm-link); } .theme-dark a:hover { color: var(--dm-link-h); }

/* ===============================
   PAGE-SCOPED FIX: Student Accommodation
   (replicate pattern per page)
   =============================== */
.theme-dark .student-accommodation-page {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
}

/* This page’s inline/light blocks */
.theme-dark .student-accommodation-page .social-media-widget,
.theme-dark .student-accommodation-page .sidebar-widget,
.theme-dark .student-accommodation-page .ad-card,
.theme-dark .student-accommodation-page .social-icons-container {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
}
.theme-dark .student-accommodation-page .social-icons-container {
  background-color: var(--dm-surface-2) !important;
}

/* Article content */
.theme-dark .student-accommodation-page article p,
.theme-dark .student-accommodation-page article li { color: var(--dm-text) !important; }

/* Keep the brand red H1 from inline style, but make sure it’s readable on dark */
.theme-dark .student-accommodation-page h1[style] { text-shadow: 0 1px 0 rgba(0,0,0,.35); }

/* Ad overlay/CTA */
.theme-dark .student-accommodation-page .ad-overlay {
  background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0)) !important;
}
.theme-dark .student-accommodation-page .ad-cta {
  background: #d62959 !important; color: #fff !important;
}


/* ===============================
   KEEP SEARCH UI LIGHT (leave LAST)
   =============================== */
.theme-dark [role="search"] input,
.theme-dark [role="search"] select,
.theme-dark [role="search"] textarea,
.theme-dark .faq-search-wrap .searchbox input,
.theme-dark .atp-search-input-wrapper .atp-search-input,
.theme-dark form.search-form input,
.theme-dark .search-container input,
.theme-dark .search-bar input,
.theme-dark .property-search input,
.theme-dark .hero-search input,
.theme-dark .wp-block-search__input,
.theme-dark input[type="search"] {
  background:#fff !important; color:#000 !important; border-color:#ccc !important;
}
.theme-dark .faq-search-wrap .searchbox .go,
.theme-dark .faq-search-wrap .searchbox .clear,
.theme-dark .atp-search-input-wrapper .atp-search-btn,
.theme-dark .wp-block-search .wp-block-search__button,
.theme-dark form.search-form button[type="submit"] {
  background:#fff !important; color:#0f172a !important; border:1px solid #d1d5db !important;
}
.theme-dark .faq-search-wrap input::placeholder,
.theme-dark .atp-search-input-wrapper .atp-search-input::placeholder,
.theme-dark .search-container input::placeholder,
.theme-dark .search-bar input::placeholder,
.theme-dark .property-search input::placeholder,
.theme-dark .hero-search input::placeholder,
.theme-dark .wp-block-search__input::placeholder,
.theme-dark input[type="search"]::placeholder { color:#666 !important; }

/* Keep all H1 headings red in both light and dark mode */
.theme-dark h1 {
  color: #d62959 !important;
}

/* Exception: keep hero/main-title headings white */
.theme-dark h1.main-title {
  color: #ffffff !important;
}

/* ===============================
   FAQ — Dark Mode Overrides
   =============================== */

/* Page surface */
.theme-dark .faq-section {
  background: transparent !important; /* let body/main show */
  color: #e5e7eb !important;
}

/* Hero */
.theme-dark .faq-hero .sub { color: #94a3b8 !important; }
.theme-dark .ai-badge {
  color: #d62959 !important;
  background: rgba(214,41,89,.08) !important;
  border: 1px solid rgba(214,41,89,.35) !important;
}

/* Search box stays light */
.theme-dark .faq-search-wrap .searchbox input {
  background: #fff !important;
  color: #000 !important;
  border-color: #c24b60 !important;
  box-shadow: 0 8px 26px rgba(164,29,58,.16) !important;
}
.theme-dark .faq-search-wrap .searchbox input::placeholder { color: #666 !important; }
.theme-dark .faq-search-wrap .searchbox .go {
  background: #a41d3a !important;
  color: #fff !important;
}
.theme-dark .faq-search-wrap .searchbox .clear { color: #a41d3a !important; }

/* Results area */
.theme-dark .faq-results { color: #e5e7eb !important; }
.theme-dark .result-empty,
.theme-dark .result-error,
.theme-dark .result-loading {
  color: #94a3b8 !important;
}

/* Cards (minimal template) */
.theme-dark .faq-card { border-bottom: 1px solid #1f2a44 !important; }
.theme-dark .faq-card .q { color: #e5e7eb !important; }
.theme-dark .faq-card .a { color: #e5e7eb !important; }
.theme-dark .faq-card.example {
  background: #111a2f !important;
  border: 1px dashed #1f2a44 !important;
}

/* Highlight */
.theme-dark mark {
  background: rgba(214,41,89,.18) !important;
  color: #ffd6e0 !important;
}

/* ---------- If you also use the larger FAQ layout CSS you pasted ---------- */
.theme-dark .faq-content,
.theme-dark .categories-sidebar,
.theme-dark .faq-item,
.theme-dark .faq-answer,
.theme-dark .faq-question {
  background: #0f172a !important;
  color: #e5e7eb !important;
  border-color: #1f2a44 !important;
}
.theme-dark .faq-item:hover { border-color: #2892e9 !important; }
.theme-dark .faq-question:hover {
  background: #111a2f !important;
  color: #93c5fd !important;
}
.theme-dark .category-title { color: #93c5fd !important; border-color: #1f2a44 !important; }
.theme-dark .categories-sidebar { background: #111a2f !important; }
.theme-dark .social-buttons { background: rgba(255,255,255,.08) !important; }

/* ===== Find Agents — DARK MODE fixes ===== */

/* Cards/panels */
.theme-dark .find-agent-form,
.theme-dark .register-prompt {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,.35) !important; /* or 'none' if you prefer */
}

/* Headings + body copy inside the page */
.theme-dark .find-agent-form h2,
.theme-dark #agents-results h3,
.theme-dark .register-prompt h3 { color: #f1f5f9 !important; }

.theme-dark .find-agent-form p,
.theme-dark .register-prompt p { color: var(--dm-text) !important; }

/* Labels (form + radios) */
.theme-dark .find-agent-form .form-label,
.theme-dark .find-agent-form .form-check-label { color: #ffffff !important; }

/* Inputs/selects (kept dark) */
.theme-dark .find-agent-form .form-control,
.theme-dark .find-agent-form .form-select {
  background:#0b1324 !important;
  color:#ffffff !important;
  border-color:#213250 !important;
}
.theme-dark .find-agent-form .form-control::placeholder { color:#94a3b8 !important; }

/* Radios/checkboxes */
.theme-dark .find-agent-form .form-check-input {
  background-color:#0b1324 !important;
  border-color:#334155 !important;
}
.theme-dark .find-agent-form .form-check-input:checked {
  background-color:#b01e42 !important;
  border-color:#b01e42 !important;
}
.theme-dark .find-agent-form .form-check-input:focus {
  box-shadow:0 0 0 .25rem rgba(176,30,66,.25) !important;
  border-color:#b01e42 !important;
}

/* Buttons – keep brand red with better contrast on dark */
.theme-dark .btn-find-agents,
.theme-dark .btn-signup {
  background-color:#b01e42 !important;
  border-color:#b01e42 !important;
  color:#fff !important;
  box-shadow:0 4px 18px rgba(176,30,66,.35) !important;
}
.theme-dark .btn-find-agents:hover,
.theme-dark .btn-signup:hover {
  background-color:#931937 !important;
  border-color:#931937 !important;
}

/* Links inside the register prompt */
.theme-dark .register-prompt a { color:#93c5fd !important; }
.theme-dark .register-prompt a:hover { color:#bfdbfe !important; }

/* Optional: tone down the banner border on dark (or keep brand if you prefer) */
.theme-dark .home-worth-banner a img { border-color:#334155 !important; }


/* ===== WHY USE US — DARK MODE FIXES ===== */
.theme-dark .atp-why-use-us-page { color: var(--dm-text) !important; }

/* Panels/cards/containers */
.theme-dark .atp-why-use-us-page .card,
.theme-dark .atp-why-use-us-page .atp-main-title-container,
.theme-dark .atp-why-use-us-page .atp-action-btn {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: 0 2px 10px rgba(0,0,0,.35) !important; /* tweak or remove */
}

/* Light strips/banners/footers */
.theme-dark .atp-why-use-us-page .bg-light,
.theme-dark .atp-why-use-us-page .card-footer.bg-light,
.theme-dark .atp-why-use-us-page .atp-tagline-banner {
  background-color: var(--dm-surface-2) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
}

/* Action cards */
.theme-dark .atp-why-use-us-page .atp-action-card { box-shadow: 0 2px 6px rgba(0,0,0,.35) !important; }
.theme-dark .atp-why-use-us-page .atp-action-btn { border-color: var(--dm-border) !important; }
.theme-dark .atp-why-use-us-page .atp-action-icon {
  background: var(--dm-surface-2) !important;
  color: var(--atp-brand-color) !important; /* keep brand */
}
.theme-dark .atp-why-use-us-page .atp-action-title { color: #e5e7eb !important; }
.theme-dark .atp-why-use-us-page .atp-action-desc  { color: var(--dm-text-2) !important; }

/* Images / feature visuals */
.theme-dark .atp-why-use-us-page .atp-feature-image {
  border-color: var(--dm-border) !important;
  box-shadow: 0 2px 5px rgba(0,0,0,.35) !important;
}
.theme-dark .atp-why-use-us-page .atp-banner-container { box-shadow: 0 2px 6px rgba(0,0,0,.35) !important; }

/* Text utilities inside this page */
.theme-dark .atp-why-use-us-page .text-muted,
.theme-dark .atp-why-use-us-page small { color: var(--dm-text-2) !important; }

/* Buttons (keep brand) */
.theme-dark .atp-why-use-us-page .atp-btn-primary,
.theme-dark .atp-why-use-us-page .btn.atp-btn-primary {
  background-color: var(--atp-brand-color) !important;
  border-color: var(--atp-brand-color) !important;
  color:#fff !important;
}
.theme-dark .atp-why-use-us-page .atp-btn-primary:hover {
  background-color: var(--atp-brand-color-dark) !important;
  border-color: var(--atp-brand-color-dark) !important;
}

/* Sidebar cards */
.theme-dark .atp-why-use-us-page .why-use-us-sidebar .card {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
}

/* Borders & accents that were light by default */
.theme-dark .atp-why-use-us-page .atp-feature-image,
.theme-dark .atp-why-use-us-page .atp-action-btn { border-color: var(--dm-border) !important; }

/* Optional: keep branded headline color readable on dark */
.theme-dark .atp-why-use-us-page .atp-section-title { color: var(--atp-brand-color) !important; }
.theme-dark .atp-why-use-us-page .atp-section-title::after { background-color: var(--atp-brand-color) !important; }


.theme-dark .atp-why-use-us-page .atp-text-primary {
  color: var(--dm-text) !important; /* keep primary text readable */
}

/* ===== AI Mortgage Advisor — DARK MODE ===== */
.theme-dark .ai-mortgage-section{
  background: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Hero */
.theme-dark .ai-mortgage-section .hero h1{ color:#d62959 !important; } /* keep brand pop */
.theme-dark .ai-mortgage-section .hero .sub{ color: var(--dm-text) !important; }
.theme-dark .ai-mortgage-section .disclaimer{
  background: rgba(214,41,89,.08) !important;
  border: 1px solid rgba(214,41,89,.35) !important;
  color: var(--dm-text) !important;
}
.theme-dark .ai-mortgage-section .disclaimer a{ color:#ff91a7 !important; }

/* Card + grid */
.theme-dark .ai-mortgage-section .ai-card{
  background: var(--dm-surface) !important;
  border-color: var(--dm-border) !important;
  box-shadow: 0 8px 24px rgba(0,0,0,.35) !important;
}

/* Form */
.theme-dark .ai-mortgage-section .ai-form label{ color:#e5e7eb !important; }
.theme-dark .ai-mortgage-section .ai-form input{
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:#213250 !important;
}
.theme-dark .ai-mortgage-section .ai-form input::placeholder{ color:#94a3b8 !important; }
.theme-dark .ai-mortgage-section .ai-form input:focus{
  border-color:#c24b60 !important;
  box-shadow:0 0 0 3px rgba(194,75,96,.25) !important;
}

/* Buttons */
.theme-dark .ai-mortgage-section .ai-btn-primary{
  background:#a41d3a !important; color:#fff !important; border:0 !important;
}
.theme-dark .ai-mortgage-section .ai-btn-ghost{
  background:transparent !important; color:#d62959 !important; border:1px solid #d62959 !important;
}
.theme-dark .ai-mortgage-section .ai-btn-ghost:hover{ background:rgba(214,41,89,.12) !important; }

/* Results placeholder */
.theme-dark .ai-mortgage-section .ai-results .ai-placeholder{ color: var(--dm-text-2) !important; }

/* Bands */
.theme-dark .ai-mortgage-section .ai-bands .ai-band{
  background: var(--dm-surface-2) !important;
  border-color: var(--dm-border) !important;
  color: var(--dm-text) !important;
}
.theme-dark .ai-mortgage-section .ai-bands .ai-band.active{
  background: var(--dm-surface) !important;
  border-color: rgba(214,41,89,.35) !important;
  box-shadow: 0 8px 18px rgba(0,0,0,.35) !important;
}
.theme-dark .ai-mortgage-section .ai-bands .label{ color:#e5e7eb !important; }
.theme-dark .ai-mortgage-section .ai-bands .tag{
  background:#1e293b !important; color:#e5e7eb !important;
}
.theme-dark .ai-mortgage-section .ai-bands .price{ color:#d62959 !important; }
.theme-dark .ai-mortgage-section .ai-bands .monthly{ color: var(--dm-text) !important; }

/* Breakdown + help */
.theme-dark .ai-mortgage-section .ai-breakdown h3,
.theme-dark .ai-mortgage-section .ai-advice h3{ color:#e5e7eb !important; }
.theme-dark .ai-mortgage-section .ai-breakdown li{ border-bottom:1px dashed var(--dm-border) !important; }
.theme-dark .ai-mortgage-section .ai-help-btn{
  background: var(--dm-surface-2) !important; color:#e5e7eb !important;
}
.theme-dark .ai-mortgage-section .ai-help-btn:hover{ background:#1b2437 !important; }
.theme-dark .ai-mortgage-section .ai-help-panel{
  background: var(--dm-surface) !important; border-color: var(--dm-border) !important; color: var(--dm-text) !important;
}
.theme-dark .ai-mortgage-section .ai-rateShock{
  background: var(--dm-surface-2) !important; border-color: var(--dm-border) !important; color: var(--dm-text) !important;
}

/* Advice CTAs */
.theme-dark .ai-mortgage-section .ai-btn-secondary{
  background:#a41d3a !important; color:#fff !important;
}
.theme-dark .ai-mortgage-section .ai-btn-outline{
  background:transparent !important; color:#d62959 !important; border:1px solid #d62959 !important;
}
.theme-dark .ai-mortgage-section .ai-btn-outline:hover{ background:rgba(214,41,89,.12) !important; }

/* Footnote */
.theme-dark .ai-mortgage-section .ai-footnote{ color: var(--dm-text-2) !important; }
.theme-dark .ai-mortgage-section .ai-footnote a{ color:#ff91a7 !important; }

/* ===== Valuation Page — Dark Mode ===== */
.theme-dark main.valuation-section{
  background: rgba(11,18,32,.78) !important; /* dark overlay over the photo */
  color: var(--dm-text) !important;
}

.theme-dark .valuation-card{
  background: rgba(15,23,42,.95) !important; /* var(--dm-surface)-like */
  color: var(--dm-text) !important;
  border: 1px solid var(--dm-border) !important;
  box-shadow: 0 8px 28px rgba(0,0,0,.35) !important;
}

/* Headings & copy */
.theme-dark .valuation-card > h1{ color:#f1f5f9 !important; }
.theme-dark .valuation-card > p,
.theme-dark .valuation-card .valuation-terms{ color: var(--dm-text) !important; }

/* Links, including the inline-styled login link */
.theme-dark .valuation-card a{ color:#ff91a7 !important; }
.theme-dark .valuation-card a:hover{ color:#ffd0da !important; }

/* Form fields */
.theme-dark .valuation-card form input.form-control,
.theme-dark .valuation-card form select.form-select{
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:#213250 !important;
}
.theme-dark .valuation-card form input.form-control::placeholder{
  color:#94a3b8 !important;
}
.theme-dark .valuation-card form input.form-control:focus,
.theme-dark .valuation-card form select.form-select:focus{
  border-color:#c24b60 !important;
  box-shadow:0 0 0 3px rgba(194,75,96,.25) !important;
  background:#0b1324 !important;
}

/* Button keeps brand colour */
.theme-dark .valuation-card form .valuation-btn{
  background:#a51c36 !important;
  color:#fff !important;
  border:0 !important;
}

/* Optional: if any Bootstrap helpers sneak in */
.theme-dark .valuation-card .bg-light{ background: var(--dm-surface) !important; color: var(--dm-text) !important; }


/* ===== What's Local — Dark Mode ===== */
.theme-dark body.page-whats-local{
  background: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Cards/panels */
.theme-dark .whatslocal-step-card,
.theme-dark .whatslocal-sidebar-card,
.theme-dark .whatslocal-promo-card{
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border: 1px solid var(--dm-border) !important;
  box-shadow: 0 10px 28px rgba(0,0,0,.35) !important;
}

/* Headings & copy */
.theme-dark .whatslocal-title{ color:#f1f5f9 !important; }
.theme-dark .whatslocal-desc{ color: var(--dm-text-2) !important; }
.theme-dark .whatslocal-step-title{ color:#ff91a7 !important; }
.theme-dark .whatslocal-step-content,
.theme-dark .whatslocal-sidebar-card p{ color: var(--dm-text) !important; }

/* Links */
.theme-dark .whatslocal-desc a{ color:#ff91a7 !important; }
.theme-dark .whatslocal-desc a:hover{ color:#ffd0da !important; }

/* Buttons (keep brand) */
.theme-dark .whatslocal-btn{
  background:#a12a43 !important;
  color:#fff !important;
  border-color:#a12a43 !important;
}
.theme-dark .whatslocal-btn:hover,
.theme-dark .whatslocal-btn:focus{
  background:#7d1832 !important;
  color:#fff !important;
}

/* Image shadows look heavy on dark – soften slightly */
.theme-dark .whatslocal-step-img{
  box-shadow: 0 2px 10px rgba(0,0,0,.35) !important;
}

/* Sidebar cards shadow tweak */
.theme-dark .whatslocal-sidebar-card,
.theme-dark .whatslocal-promo-card{
  box-shadow: 0 6px 20px rgba(0,0,0,.35) !important;
}

/* ===== House Sold Prices — Dark Mode ===== */
.theme-dark body.page-house-sold-prices{
  background: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Cards/panels */
.theme-dark .house-sold-step-card,
.theme-dark .house-sold-sidebar-card,
.theme-dark .house-sold-promo-card{
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border: 1px solid var(--dm-border) !important;
  box-shadow: 0 10px 28px rgba(0,0,0,.35) !important;
}

/* Headings & copy */
.theme-dark .house-sold-title{ color:#f1f5f9 !important; }
.theme-dark .house-sold-desc{ color: var(--dm-text-2) !important; }
.theme-dark .house-sold-step-title{ color:#ff91a7 !important; }
.theme-dark .house-sold-step-content,
.theme-dark .house-sold-sidebar-card p{ color: var(--dm-text) !important; }

/* Links */
.theme-dark .house-sold-desc a{ color:#ff91a7 !important; }
.theme-dark .house-sold-desc a:hover{ color:#ffd0da !important; }

/* Buttons (keep brand) */
.theme-dark .house-sold-btn{
  background:#a12a43 !important;
  color:#fff !important;
  border-color:#a12a43 !important;
}
.theme-dark .house-sold-btn:hover,
.theme-dark .house-sold-btn:focus{
  background:#7d1832 !important;
  color:#fff !important;
}

/* Image shadows – soften on dark */
.theme-dark .house-sold-step-img{
  box-shadow: 0 2px 10px rgba(0,0,0,.35) !important;
}

/* Sidebar card shadow tweak */
.theme-dark .house-sold-sidebar-card,
.theme-dark .house-sold-promo-card{
  box-shadow: 0 6px 20px rgba(0,0,0,.35) !important;
}

/* ===== Advice Guide Centre — Dark Mode ===== */
.theme-dark body.page-advice-guide-centre{
  background: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Header */
.theme-dark .advice-guide-title{ color:#f1f5f9 !important; }
.theme-dark .advice-guide-description{ color:var(--dm-text-2) !important; }
.theme-dark .advice-guide-description a{
  color:#ff91a7 !important;
  text-decoration: underline;
}
.theme-dark .advice-guide-description a:hover{ color:#ffd0da !important; }

/* Cards */
.theme-dark .category-card,
.theme-dark .sidebar-card{
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border: 1px solid var(--dm-border) !important;
  box-shadow: 0 10px 28px rgba(0,0,0,.35) !important;
}

/* Category accent strip */
.theme-dark .category-card::before{
  background:#ff91a7 !important;           /* brand accent on dark */
}

/* Category contents */
.theme-dark .category-title{ color:#e5e7eb !important; }
.theme-dark .category-card:hover .category-title{ color:#ff91a7 !important; }

.theme-dark .category-link{
  color: var(--dm-text-2) !important;
}
.theme-dark .category-link:hover{ color:#ff91a7 !important; }
.theme-dark .category-link::before{ color:#ff91a7 !important; }

/* Images/shadows on dark */
.theme-dark .category-image{
  box-shadow: 0 4px 12px rgba(0,0,0,.35) !important;
  border-color: rgba(255,255,255,.12) !important;
}

/* Sidebar banners (wrapper already .sidebar-card) */
.theme-dark .sidebar-banner img{
  filter: none !important; /* keep images natural */
}

/* CTA buttons (keep brand) */
.theme-dark .cta-button{
  background:#a12a43 !important;
  color:#fff !important;
}
.theme-dark .cta-button:hover{
  background:#851a33 !important;
  color:#fff !important;
}

/* Bottom banner container subtle edge on dark */
.theme-dark .bottom-banner-container{
  box-shadow: 0 6px 20px rgba(0,0,0,.35) !important;
  border-radius: 10px !important;
}

/* ===== Property Purchasing — Dark Mode ===== */
.theme-dark .property-purchasing-page{ color:var(--dm-text) !important; }

.theme-dark .pp-card{
  background:var(--dm-surface) !important;
  color:var(--dm-text) !important;
  border-color:var(--dm-border) !important;
  box-shadow:0 12px 30px rgba(0,0,0,.45) !important;
}

.theme-dark .pp-title,
.theme-dark .pp-h2{ color:#ffd0da !important; }

.theme-dark .pp-note{ color:var(--dm-text-2) !important; }
.theme-dark .help-to-buy-link{ color:#ff91a7 !important; }
.theme-dark .help-to-buy-link:hover{ color:#ffd0da !important; }

/* Buttons keep brand pop on dark */
.theme-dark .btn-primary{
  background:#c81e59 !important; border-color:#c81e59 !important; color:#fff !important;
}
.theme-dark .btn-outline-primary{
  background:transparent !important; color:#ff91a7 !important; border-color:#ff91a7 !important;
}
.theme-dark .btn-outline-primary:hover{
  background:rgba(255,145,167,.1) !important;
}

/* Social */
.theme-dark .social-media-section{ box-shadow:0 12px 30px rgba(0,0,0,.45) !important; }
.theme-dark .social-media-overlay{ background:linear-gradient(0deg, rgba(0,0,0,.6), rgba(0,0,0,.3)) !important; }

/* Ads */
.theme-dark .ad-spot{ box-shadow:0 12px 30px rgba(0,0,0,.45) !important; }

/* ===============================
   Sell Your Home — Dark Mode
   =============================== */
.theme-dark .sell-your-home-page,
.theme-dark .sell-your-home-page .container-fluid {
  background-color: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Cards/sections/panels */
.theme-dark .sell-your-home-page .section,
.theme-dark .sell-your-home-page .property-valuation-ad,
.theme-dark .sell-your-home-page .ad-spot {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important;
}

/* Headings keep brand colour for continuity */
.theme-dark .sell-your-home-page h1,
.theme-dark .sell-your-home-page h2,
.theme-dark .sell-your-home-page h3 {
  color: #c81e59 !important;
}

/* Body text & links */
.theme-dark .sell-your-home-page p,
.theme-dark .sell-your-home-page .ad-link {
  color: var(--dm-text) !important;
}
.theme-dark .sell-your-home-page .help-to-buy-link {
  color: #e85a84 !important;
}
.theme-dark .sell-your-home-page .help-to-buy-link:hover {
  color: #ff9ab6 !important;
}

/* Buttons */
.theme-dark .sell-your-home-page .btn-primary {
  background-color: #c81e59 !important;
  border-color: #c81e59 !important;
  color: #fff !important;
  filter: none !important;
  box-shadow: none !important;
}
.theme-dark .sell-your-home-page .btn-outline-primary {
  background: transparent !important;
  color: #ffc1d4 !important;
  border-color: #7a0f34 !important;
}
.theme-dark .sell-your-home-page .btn-outline-primary:hover {
  background: #c81e59 !important;
  color: #fff !important;
  border-color: #c81e59 !important;
}

/* Images stay true; flatten extra effects */
.theme-dark .sell-your-home-page .header-image img,
.theme-dark .sell-your-home-page .ad-image {
  filter: none !important;
  box-shadow: none !important;
}

/* Social strip overlay & pills */
.theme-dark .sell-your-home-page .social-media-overlay {
  background-color: rgba(0,0,0,0.45) !important;
  color: #fff !important;
}
.theme-dark .sell-your-home-page .social-icon {
  box-shadow: none !important;
}

/* ===============================
   Find a Solicitor — Dark Mode
   =============================== */
.theme-dark #find-solicitor-page,
.theme-dark .find-solicitor-page,
.theme-dark #find-solicitor-page .container-fluid.solicitor-page {
  background-color: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Cards / panels / sidebar */
.theme-dark #find-solicitor-page .solicitor-content-wrapper,
.theme-dark #find-solicitor-page .solicitor-sidebar,
.theme-dark #find-solicitor-page .bg-light,
.theme-dark #find-solicitor-page .ad-spot,
.theme-dark #find-solicitor-page .solicitor-ad-section,
.theme-dark #find-solicitor-page .solicitor-ad-business {
  background-color: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important;
}

/* Headings keep brand colour */
.theme-dark #find-solicitor-page .solicitor-main-title,
.theme-dark #find-solicitor-page .solicitor-section-title,
.theme-dark #find-solicitor-page .solicitor-form-title {
  color: #b01e42 !important;
}
.theme-dark #find-solicitor-page .solicitor-subtitle { color: var(--dm-text) !important; }

/* Body copy & links */
.theme-dark #find-solicitor-page p,
.theme-dark #find-solicitor-page .lead,
.theme-dark #find-solicitor-page .form-text { color: var(--dm-text) !important; }

.theme-dark #find-solicitor-page a.atp-link,
.theme-dark #find-solicitor-page .solicitor-login-link {
  color: #ffb6c7 !important;
}
.theme-dark #find-solicitor-page a.atp-link:hover,
.theme-dark #find-solicitor-page .solicitor-login-link:hover {
  color: #ffd9e1 !important;
  text-decoration: underline;
}

/* Forms */
.theme-dark #find-solicitor-page .form-label { color: #ffffff !important; }

.theme-dark #find-solicitor-page .form-control,
.theme-dark #find-solicitor-page .form-select,
.theme-dark #find-solicitor-page input,
.theme-dark #find-solicitor-page textarea {
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:#213250 !important;
  box-shadow:none !important;
}
.theme-dark #find-solicitor-page .form-control::placeholder,
.theme-dark #find-solicitor-page textarea::placeholder {
  color:#94a3b8 !important;
}

/* Buttons */
.theme-dark #find-solicitor-page .atp-primary-btn {
  background-color:#b01e42 !important;
  border-color:#b01e42 !important;
  color:#fff !important;
  filter:none !important;
  box-shadow:none !important;
}
.theme-dark #find-solicitor-page .atp-primary-btn:hover {
  background-color:#901835 !important;
  border-color:#901835 !important;
}

/* Images & utilities */
.theme-dark #find-solicitor-page .solicitor-banner-image img,
.theme-dark #find-solicitor-page .ad-image {
  filter:none !important;
  box-shadow:none !important;
}
.theme-dark #find-solicitor-page .shadow { box-shadow:none !important; }

/* Required asterisk – soften but keep branded */
.theme-dark #find-solicitor-page .required-field::after { color:#ff87a0 !important; }

/* ===============================
   Insurance Quotes — Dark Mode
   =============================== */
.theme-dark .insurance-main-section {
  background: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}

/* Kill inline #000 text on this page only */
.theme-dark .insurance-main-section [style*="#000"],
.theme-dark .insurance-main-section [style*="#000000"],
.theme-dark .insurance-main-section [style*="black"] {
  color: var(--dm-text) !important;
}

/* Page surfaces */
.theme-dark .main-layout-container,
.theme-dark .hero-section,
.theme-dark .insurance-info-section,
.theme-dark .insurance-type-card,
.theme-dark .combined-insurance-card,
.theme-dark .details-section,
.theme-dark .quote-form,
.theme-dark .quote-form-container .card,
.theme-dark .sidebar-ads-section .ad-card {
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important;
}

/* Slightly raised headers/rows */
.theme-dark .insurance-type-card .card-header {
  background: var(--dm-surface-2) !important;
  border-color: var(--dm-border) !important;
  color: var(--dm-text) !important;
}

/* Hero / glass cards */
.theme-dark .info-card { 
  background: rgba(15,23,42,.92) !important; 
  border-color: var(--dm-border) !important;
  color: var(--dm-text) !important;
}
.theme-dark .hero-image-container::after { background: linear-gradient(45deg, rgba(176,30,66,.15), rgba(59,130,246,.12)) !important; }

/* Headings keep brand */
.theme-dark .unique-heading-insurance,
.theme-dark .unique-heading-finding-insurance,
.theme-dark .unique-heading-ready-details,
.theme-dark .insurance-main-section h1,
.theme-dark .insurance-main-section h2 {
  color: #b01e42 !important;
}

/* Links */
.theme-dark .insurance-main-section a { color: var(--dm-link) !important; }
.theme-dark .insurance-main-section a:hover { color: var(--dm-link-h) !important; }

/* Forms */
.theme-dark .insurance-main-section .form-label { color:#fff !important; }
.theme-dark .insurance-main-section .form-control,
.theme-dark .insurance-main-section .form-select,
.theme-dark .insurance-main-section input,
.theme-dark .insurance-main-section textarea {
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:#213250 !important;
  box-shadow:none !important;
}
.theme-dark .insurance-main-section .form-control::placeholder,
.theme-dark .insurance-main-section textarea::placeholder { color:#94a3b8 !important; }

/* Buttons */
.theme-dark .insurance-main-section .btn-primary {
  background:#b01e42 !important;
  border-color:#b01e42 !important;
  color:#fff !important;
  box-shadow:none !important;
}
.theme-dark .insurance-main-section .btn-primary:hover {
  background:#901835 !important; border-color:#901835 !important;
}

/* Alerts tuned for dark */
.theme-dark .insurance-main-section .alert-info {
  background: rgba(59,130,246,.08) !important;
  color:#cfe3ff !important;
  border-left:3px solid #3B82F6 !important;
}
.theme-dark .insurance-main-section .alert-warning {
  background: rgba(245,158,11,.1) !important;
  color:#ffe6b0 !important;
  border-left:3px solid #F59E0B !important;
}

/* Detail cards & numbers */
.theme-dark .detail-card { 
  background: var(--dm-surface) !important; 
  border-color: var(--dm-border) !important; 
  box-shadow:none !important; 
}
.theme-dark .detail-card::before { background: linear-gradient(90deg,#b01e42,#c62f50) !important; }
.theme-dark .detail-number { box-shadow:none !important; }

/* Highlight card keeps bright brand gradient, text stays white */
.theme-dark .info-highlight-card { color:#fff !important; }
.theme-dark .info-highlight-card a { color:#fff !important; }

/* Ads / images */
.theme-dark .insurance-main-section .ad-card,
.theme-dark .insurance-main-section .competition-banner { box-shadow:none !important; }
.theme-dark .insurance-main-section img { filter:none !important; }

/* Flood info card border */
.theme-dark .flooding-info-card { border-color:#b01e42 !important; }

/* Tweak the big backdrop gradient */
.theme-dark .main-layout-container {
  background: linear-gradient(135deg, var(--dm-bg) 0%, #0c162d 100%) !important;
}

/* ==========================================================
   Bridging Loans — Dark Mode (scoped by .theme-dark on html/body)
   ========================================================== */

/* If you already defined these on the site, you can skip this block */
:root {
  --dm-bg: #0b1222;          /* page background */
  --dm-surface: #0f172a;     /* cards / panels */
  --dm-surface-2: #131d36;   /* headers / raised */
  --dm-text: #e5e7eb;        /* primary text */
  --dm-muted: #a7b0c3;       /* secondary text */
  --dm-border: #22324f;      /* subtle borders */
  --dm-link: #93c5fd;        /* links */
  --dm-link-h: #bfdbfe;      /* link hover */
}

/* Base + page background */
.theme-dark body {
  background-color: var(--dm-bg) !important;
  color: var(--dm-text) !important;
}
.theme-dark .container,
.theme-dark .row {
  background: transparent !important;
  color: var(--dm-text) !important;
}

/* Generic cards / surfaces */
.theme-dark .modern-card,
.theme-dark .content-section,
.theme-dark .feature-card,
.theme-dark .accordion-item {
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important;
}
.theme-dark .modern-card.bg-light,
.theme-dark .bg-light.modern-card {
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
}

/* Headings keep brand */
.theme-dark .content-section h1,
.theme-dark .content-section h2,
.theme-dark .content-section h3,
.theme-dark .content-section h4 {
  color: #b01e42 !important;
}

/* Body copy / muted text */
.theme-dark .lead,
.theme-dark .content-section p,
.theme-dark .small.text-muted,
.theme-dark .modern-form .form-text,
.theme-dark .modern-card p {
  color: var(--dm-text) !important;
}
.theme-dark .text-muted { color: var(--dm-muted) !important; }

/* Lists & bullets */
.theme-dark .content-section ul { color: var(--dm-text) !important; }
.theme-dark .content-section ul li::before { color: #b01e42 !important; }

/* Forms */
.theme-dark .modern-form .form-label { color: var(--dm-text) !important; }
.theme-dark .modern-form .form-control,
.theme-dark .modern-form .form-select,
.theme-dark .form-control,
.theme-dark .form-select {
  background: #0b1324 !important;
  color: #f8fafc !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important;
}
.theme-dark .form-control::placeholder { color: #8aa0bf !important; }

/* Buttons (brand) */
.theme-dark .modern-form .btn-danger,
.theme-dark .btn.btn-danger {
  background-color: #b01e42 !important;
  border-color: #b01e42 !important;
  color: #fff !important;
  box-shadow: none !important;
}
.theme-dark .modern-form .btn-danger:hover,
.theme-dark .btn.btn-danger:hover {
  background-color: #940d31 !important;
  border-color: #940d31 !important;
}

/* Links (including .link-dark) */
.theme-dark a { color: var(--dm-link) !important; }
.theme-dark a:hover { color: var(--dm-link-h) !important; }
.theme-dark a.link-dark { color: var(--dm-link) !important; }

/* Hero section (keep image, darken overlay slightly) */
.theme-dark .hero-section { color: #fff !important; }
.theme-dark .hero-section::after {
  background-color: rgba(176, 30, 66, 0.6) !important; /* was 0.7; a tad softer */
}

/* Feature cards */
.theme-dark .feature-card {
  background: var(--dm-surface) !important;
  border-color: var(--dm-border) !important;
}
.theme-dark .feature-card .icon { color: #1115d4 !important; }

/* Accordion */
.theme-dark .accordion-item { background: var(--dm-surface) !important; }
.theme-dark .accordion-button {
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  box-shadow: none !important;
}
.theme-dark .accordion-button:not(.collapsed) {
  background: #1115d4 !important;
  color: #fff !important;
}
.theme-dark .accordion-item,
.theme-dark .accordion-button,
.theme-dark .accordion-collapse {
  border-color: var(--dm-border) !important;
}

/* Quote box */
.theme-dark .quote-box {
  background-color: #0f1a33 !important;
  border-left-color: #1115d4 !important;
  color: var(--dm-text) !important;
}

/* Sticky form */
.theme-dark .sticky-form { color: var(--dm-text) !important; }

/* Ads / images: do NOT invert – just remove extra shadows */
.theme-dark .modern-card img,
.theme-dark .content-section img { filter: none !important; }
.theme-dark .modern-card,
.theme-dark .feature-card,
.theme-dark .accordion-item { box-shadow: none !important; }

/* Scroll to top button */
.theme-dark .scroll-to-top {
  background: #1115d4 !important;
  color: #fff !important;
  box-shadow: none !important;
}
.theme-dark .scroll-to-top:hover { background: #1115d4 !important; }

/* Borders & separators */
.theme-dark .border,
.theme-dark hr { border-color: var(--dm-border) !important; }

/* Bootstrap helpers that look too bright in dark */
.theme-dark .bg-light { background: var(--dm-surface) !important; }
.theme-dark .text-dark { color: var(--dm-text) !important; }

/* ==========================================================
   Homeowner Loans — Dark Mode (scoped by .theme-dark)
   ========================================================== */

:root{
  --dm-bg:#0b1222;
  --dm-surface:#0f172a;
  --dm-surface-2:#131d36;
  --dm-text:#e5e7eb;
  --dm-muted:#a7b0c3;
  --dm-border:#22324f;
  --dm-link:#93c5fd;
  --dm-link-h:#bfdbfe;
}

/* Page background & base text */
.theme-dark .homeowner-loans-page{
  background:var(--dm-bg) !important;
  color:var(--dm-text) !important;
}
.theme-dark .homeowner-loans-page *{
  text-shadow:none !important;
}

/* Headings keep brand look; sidebar headings slightly brighter */
.theme-dark .homeowner-title{ /* gradient stays readable on dark */ }
.theme-dark .loan-sidebar h2,
.theme-dark .loan-sidebar h4{
  color:#eef2f7 !important;
}

/* Surfaces & cards */
.theme-dark .loan-sidebar,
.theme-dark .card,
.theme-dark .header-section{
  background:var(--dm-surface) !important;
  color:var(--dm-text) !important;
  border-color:var(--dm-border) !important;
  box-shadow:none !important;
}
.theme-dark .card:hover,
.theme-dark .loan-sidebar:hover{
  box-shadow:none !important;
}

/* Sidebar underline accent */
.theme-dark .loan-sidebar h2:after{
  background:linear-gradient(90deg,#c31432,#b91e3e) !important;
}

/* Body copy & muted */
.theme-dark .lead,
.theme-dark p,
.theme-dark li,
.theme-dark .form-text,
.theme-dark .form-label{
  color:var(--dm-text) !important;
}
.theme-dark .text-muted{ color:var(--dm-muted) !important; }

/* Lists */
.theme-dark .loan-sidebar ul li{ color:var(--dm-text) !important; }
.theme-dark .loan-sidebar ul li:before{ color:#c31432 !important; }

/* Links */
.theme-dark .homeowner-loans-page a{ color:var(--dm-link) !important; }
.theme-dark .homeowner-loans-page a:hover{ color:var(--dm-link-h) !important; }

/* Buttons (brand) */
.theme-dark .btn-danger{
  background:linear-gradient(90deg,#c31432 0%,#b91e3e 100%) !important;
  border:none !important;
  color:#fff !important;
  box-shadow:none !important;
}
.theme-dark .btn-danger:hover{
  background:linear-gradient(90deg,#b91e3e 0%,#a01029 100%) !important;
  box-shadow:none !important;
}

/* Forms */
.theme-dark .form-control,
.theme-dark .form-select{
  background:#0b1324 !important;
  color:#f8fafc !important;
  border-color:var(--dm-border) !important;
  box-shadow:none !important;
}
.theme-dark .form-control::placeholder{ color:#8aa0bf !important; }
.theme-dark .form-check-input{
  background-color:#0b1324 !important;
  border-color:var(--dm-border) !important;
}
.theme-dark .form-check-input:checked{
  background-color:#c31432 !important;
  border-color:#c31432 !important;
}
.theme-dark .is-invalid{
  background:#160f12 !important;
  border-color:#ef9aa8 !important;
  box-shadow:0 0 0 3px rgba(195,20,50,.25) !important;
  color:#ffeef1 !important;
}

/* Alerts */
.theme-dark .alert-danger{
  background:#2a1518 !important;
  color:#f7c6cc !important;
  border:1px solid #5a1f27 !important;
  box-shadow:none !important;
}

/* Back to top */
.theme-dark .back-to-top{
  background:linear-gradient(145deg,#c31432,#b91e3e) !important;
  color:#fff !important;
  box-shadow:none !important;
}
.theme-dark .back-to-top:hover{
  background:linear-gradient(145deg,#d41638,#c31432) !important;
}

/* Images/logos: keep true colors */
.theme-dark .kisf-logo,
.theme-dark .homeowner-loans-page img{
  filter:none !important;
}

/* Borders & separators */
.theme-dark .card,
.theme-dark .loan-sidebar,
.theme-dark .form-control,
.theme-dark .form-select{
  border-color:var(--dm-border) !important;
}

/* General utility fallbacks */
.theme-dark .text-purple{ color:#e9d5ff !important; }
.theme-dark .text-danger{ color:#ff95a6 !important; } /* slightly lighter on deep background */

/* ==========================================================
   Advertisers Page — Dark Mode (scoped by .theme-dark)
   ========================================================== */

:root{
  --dm-bg:#0b1222;
  --dm-surface:#0f172a;
  --dm-surface-2:#131d36;
  --dm-text:#e5e7eb;
  --dm-muted:#a7b0c3;
  --dm-border:#22324f;
}

.theme-dark .advertisers-page{
  background:var(--dm-bg) !important;
  color:var(--dm-text) !important;
}

/* General text */
.theme-dark .advertisers-page p,
.theme-dark .advertisers-page li,
.theme-dark .advertisers-page .lead,
.theme-dark .advertisers-page .text-muted{
  color:var(--dm-text) !important;
}
.theme-dark .advertisers-page .text-muted{ color:var(--dm-muted) !important; }

/* Headings keep brand color */
.theme-dark .text-brand{ color:var(--brand-color) !important; }
.theme-dark .hero-text-blue{ color:#93c5fd !important; }
.theme-dark .hero-text-red{ color:var(--brand-color) !important; }

/* Hero + content surfaces */
.theme-dark .advertiser-hero,
.theme-dark .advertiser-content,
.theme-dark .advertiser-benefits,
.theme-dark .sample-advert-container{
  background:var(--dm-surface) !important;
  color:var(--dm-text) !important;
  box-shadow:none !important;
  border-color:var(--dm-border) !important;
}
.theme-dark .advertiser-benefits{ background:var(--dm-surface-2) !important; }

/* Cards */
.theme-dark .card{
  background:var(--dm-surface) !important;
  color:var(--dm-text) !important;
  border-color:var(--dm-border) !important;
  box-shadow:none !important;
}
.theme-dark .card-header{
  /* keep brand band for contrast */
  background:var(--brand-color) !important;
  color:#fff !important;
  border:none !important;
}
.theme-dark .advert-card:before{ background-color:var(--brand-color) !important; }

/* Lists & ticks */
.theme-dark .advertiser-benefits li{ color:var(--dm-text) !important; }
.theme-dark .advertiser-benefits li:before{ color:var(--brand-color) !important; }

/* Image holders / placeholders */
.theme-dark .advert-example,
.theme-dark .image-placeholder,
.theme-dark .image-upload-placeholder{
  background:var(--dm-surface-2) !important;
  border-color:var(--dm-border) !important;
}
.theme-dark .image-placeholder:hover,
.theme-dark .image-upload-placeholder:hover{
  border-color:var(--brand-color) !important;
  background:rgba(178,33,73,0.06) !important;
}

/* Sidebar */
.theme-dark .advertisers-sidebar{ position:sticky; top:20px; }
.theme-dark .advertisers-sidebar h3{
  color:#fff !important;
  border-color:var(--dm-border) !important;
}
.theme-dark .sidebar-widget{ /* remove hover elevation on dark */ }
.theme-dark .sell-property-overlay,
.theme-dark .ad-overlay{
  /* keep gradients; no change needed for readability on images */
}

/* Social widget */
.theme-dark .social-media-widget{ box-shadow:none !important; }
.theme-dark .social-media-overlay{ background:rgba(0,0,0,0.45) !important; }
.theme-dark .social-icons-container{
  background:var(--dm-surface-2) !important;
  border-top:1px solid var(--dm-border) !important;
}

/* Breadcrumbs */
.theme-dark .breadcrumb{ color:var(--dm-muted) !important; }
.theme-dark .breadcrumb .breadcrumb-item a{ color:#bfdbfe !important; }
.theme-dark .breadcrumb .breadcrumb-item a:hover{ color:#e0f2fe !important; }
.theme-dark .breadcrumb-item + .breadcrumb-item::before{
  color:var(--brand-color) !important;
}

/* Buttons */
.theme-dark .register-btn{
  background-color:var(--brand-color) !important;
  color:#fff !important;
  box-shadow:none !important;
}
.theme-dark .register-btn:hover{
  background-color:var(--brand-color-dark) !important;
  box-shadow:none !important;
}
.theme-dark #registerModal .btn-danger{
  background-color:#b01e42 !important; border-color:#b01e42 !important; color:#fff !important;
}
.theme-dark #registerModal .btn-outline-secondary{
  color:var(--dm-text) !important; border-color:var(--dm-border) !important;
}
.theme-dark #registerModal .btn-outline-secondary:hover{
  background:var(--dm-surface-2) !important; color:#fff !important;
}

/* Modal */
.theme-dark #registerModal .modal-content{
  background:var(--dm-surface) !important;
  color:var(--dm-text) !important;
  box-shadow:none !important;
}
.theme-dark #registerModal .modal-title{ color:#fff !important; }
.theme-dark #registerModal .btn-close{
  filter:invert(1) grayscale(100%) !important; opacity:.8;
}

/* Borders / dividers */
.theme-dark .divider{ background-color:var(--brand-color) !important; }
.theme-dark .advertiser-content h2:after,
.theme-dark .advertiser-hero h1:after{
  background-color:var(--brand-color) !important;
}

/* Images keep natural colors */
.theme-dark .advertisers-page img{ filter:none !important; }

/* Utility */
.theme-dark .bg-light{ background:var(--dm-surface-2) !important; color:var(--dm-text) !important; }
.theme-dark .border{ border-color:var(--dm-border) !important; }

/* Advertisers Page – Dark mode fix for "Text Advert" cards
   Keeps dimensions/spacing 100% unchanged, only colors switch. */
.theme-dark .advertisers-page .advert-example,
.theme-dark .advertisers-page .advert-example .sample-advert{
  /* visual only – do NOT alter padding/margins/border-width */
  background: var(--dm-surface) !important;
  color: var(--dm-text) !important;
  border-color: var(--dm-border) !important;
  box-shadow: none !important; /* avoid any elevation resize */
}

/* Headings + helper text colors inside the text-ad cards */
.theme-dark .advertisers-page .advert-example h4{
  color: var(--brand-color) !important;
}
.theme-dark .advertisers-page .advert-example p{
  color: var(--dm-muted) !important;
}

/* The inner light panel that wraps the preview image (keeps size) */
.theme-dark .advertisers-page .advert-example .sample-advert{
  background: var(--dm-surface-2) !important; /* only color swap */
}

/* Do NOT allow image zoom/scale in text advert samples */
.theme-dark .advertisers-page .advert-example .responsive-image-container:hover img{
  transform: none !important;
}

/* Ensure no other transforms affect the preview area */
.theme-dark .advertisers-page .advert-example .responsive-image-container img{
  transform: none !important;
}

/* Preserve intrinsic sizing — do not override width/height */
.theme-dark .advertisers-page .advert-example .responsive-image-container,
.theme-dark .advertisers-page .advert-example .responsive-image-container img{
  width: auto;
  max-width: 100%;
  height: auto;
}

/* Blogs page (news.css) — Dark mode without layout shifts
   - Only color tokens change
   - No padding/margin/border-width changes
   - Disables image zoom so thumbs never crop/shift
*/
.theme-dark .blog-modern{
  /* dark tokens */
  --bg:   #0b1220;
  --bg2:  #0a1326;
  --card: #0f172a;
  --line: #223045;
  --ink:  #e6edf7;
  --muted:#9db0c3;

  /* keep brand/accent but they look nicer slightly brighter on dark */
  --brand:#7c3aed; /* was #6d28d9 */
  --accent:#22b5f3; /* was #0ea5e9 */
}

/* backgrounds / borders (visual only) */
.theme-dark .blog-modern{
  background: linear-gradient(180deg, var(--bg) 0%, var(--bg2) 100%) !important;
  color: var(--ink);
}
.theme-dark .blog-modern .filters,
.theme-dark .blog-modern .roundup,
.theme-dark .blog-modern .card,
.theme-dark .blog-modern .pagination a,
.theme-dark .blog-modern .pagination span,
.theme-dark .blog-modern .alert{
  background: var(--card) !important;
  border-color: var(--line) !important;
  color: var(--ink) !important;
}

/* hero text/subtext */
.theme-dark .blog-modern .hero h1{ color: var(--ink) !important; }
.theme-dark .blog-modern .hero p,
.theme-dark .blog-modern .loading-msg .muted{ color: var(--muted) !important; }

/* subtle hero glow on dark (visual only) */
.theme-dark .blog-modern .hero::before{
  background:
    radial-gradient(600px 200px at 10% -20%, rgba(124,58,237,.22), transparent 60%),
    radial-gradient(500px 150px at 90% -10%, rgba(34,181,243,.22), transparent 60%);
  filter: blur(24px);
}

/* selects / inputs used in filters */
.theme-dark .blog-modern .select{
  background: var(--card) !important;
  border-color: var(--line) !important;
  color: var(--ink) !important;
}
.theme-dark .blog-modern .select select{ color: inherit; }

/* tags & tiny chips */
.theme-dark .blog-modern .tag{
  color: #c9d7e6 !important;
  background: #172133 !important;
  border-color: #223045 !important;
}

/* key/value (date + source) & excerpts */
.theme-dark .blog-modern .kv,
.theme-dark .blog-modern .excerpt{ color: var(--muted) !important; }

/* thumbnails: keep exact dimensions; just recolor the empty-state bg */
.theme-dark .blog-modern .thumb{ background:#111b2a !important; }

/* IMPORTANT: prevent any image zoom/crop on hover (no layout change) */
.theme-dark .blog-modern .card:hover .thumb img{
  transform: none !important;
}

/* keep pagination readable */
.theme-dark .blog-modern .pagination .current{
  background: linear-gradient(90deg, var(--brand), var(--accent)) !important;
  color:#fff !important; border-color: transparent !important;
}

/* alerts */
.theme-dark .blog-modern .alert{
  background: #1a2536 !important;
  border-color: #3b1520 !important;
  color: #f3c7cf !important;
}

/* skeletons / spinner (visual only) */
.theme-dark .blog-modern .skeleton{ background:#1a2333 !important; }
.theme-dark .blog-modern .skeleton-card{ background: var(--card) !important; border-color: var(--line) !important; }
.theme-dark .blog-modern .news-spinner{
  border-color: rgba(230,238,247,.15) !important;
  border-top-color: var(--brand) !important;
}

/* Overseas page — dark mode (no layout shifts)
   Append after overseas.css
*/
.theme-dark .hero-banner,
.theme-dark .countries-section{
  /* override page tokens locally (scoped to this page’s sections) */
  --brand:#e25577;
  --brand-dark:#c34363;
  --ink:#e6edf7;
  --ink-2:#b3c0cf;
  --bg:#0b1220;
  --bg-soft:#0a1326;
}

/* hero */
.theme-dark .hero-banner{
  background: linear-gradient(135deg, #0d1526 0%, #0a1220 100%) !important;
}
.theme-dark .overseas-title{ color: var(--brand) !important; }
.theme-dark .overseas-subtitle{ color: var(--ink) !important; }
.theme-dark .overseas-text{ color: var(--ink-2) !important; }

/* listing counter */
.theme-dark .listing-counter-box{
  background: linear-gradient(145deg, #0f172a, #0b1220) !important;
  border-color: #223045 !important;
  box-shadow: var(--shadow-md) !important;
}
.theme-dark .listing-counter-box::before{
  background: linear-gradient(135deg, rgba(226,85,119,.06) 0%, transparent 50%) !important;
}
.theme-dark .counter-value{
  color: var(--brand) !important;
  text-shadow: none !important;
}
.theme-dark .counter-value::after{
  background: rgba(226,85,119,.25) !important;
}
.theme-dark .counter-tagline{
  background: linear-gradient(90deg, #da2d55, #cf5353) !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
}


/* countries section */
.theme-dark .countries-section{ background: var(--bg-soft) !important; }
.theme-dark .country-card{
  background: #0f172a !important;
  border: 1px solid #223045 !important;
  box-shadow: var(--shadow-sm) !important;
}
.theme-dark .country-name{ color: var(--brand) !important; }
.theme-dark .country-description{ color: var(--ink-2) !important; }

.theme-dark .country-image-container{ background:#0b1220 !important; }
/* prevent any zoom/crop on hover in dark mode (no visual shift) */
.theme-dark .country-card:hover .country-image{ transform: none !important; }

.theme-dark .country-flag{
  background: rgba(15,23,42,.72) !important;
  border-color: #223045 !important;
  box-shadow: 0 4px 10px rgba(0,0,0,.35) !important;
}

/* magic door */
.theme-dark .magic-link .mystery-overlay{
  background:
    radial-gradient(120% 120% at 80% 20%, rgba(0,0,0,0) 0%, rgba(0,0,0,.55) 60%),
    linear-gradient(to top, rgba(8,14,22,.65), rgba(8,14,22,.2)) !important;
}
.theme-dark .badge-glass{
  background: rgba(0,0,0,.45) !important;
  border-color: rgba(255,255,255,.25) !important;
}

/* buttons */
.theme-dark .btn-country{
  background: var(--brand) !important;
  color:#fff !important;
  box-shadow: 0 4px 8px rgba(226,85,119,.35) !important;
}
.theme-dark .btn-country:hover{ background: var(--brand-dark) !important; }

/* back-to-top (if used on this page) */
.theme-dark .btn-back-to-top{
  background: var(--brand) !important;
  color:#fff !important;
}


/* =========================================================
   FOOTER MODALS — DARK MODE
   Targets:
     - #preferredLocationModal
     - #propertyFilterModal
   ========================================================= */

.theme-dark #preferredLocationModal .modal-content,
.theme-dark #propertyFilterModal .modal-content,
.theme-dark #preferredSearchModal .modal-content{
  background:#0f172a !important;              /* deep slate */
  color:#e6edf7 !important;                    /* ink */
  border:1px solid #223045 !important;         /* outline */
  box-shadow: 0 18px 50px rgba(0,0,0,.55) !important;
}

/* Headers */
.theme-dark #preferredLocationModal .modal-header,
.theme-dark #propertyFilterModal .modal-header{
  background: linear-gradient(135deg,#0b1220,#0f172a) !important;
  color: var(--ink) !important;
  border-bottom: 1px solid #223045 !important;
}

/* Property filter header had inline light gradient — hard override */
.theme-dark #propertyFilterModal .modal-header[style]{
  background: linear-gradient(135deg,#0b1220,#0f172a) !important;
}

/* Titles */
.theme-dark #preferredLocationModal .modal-title,
.theme-dark #propertyFilterModal .modal-title{
  color: var(--ink) !important;
}

/* Body + subtle separation */
.theme-dark #preferredLocationModal .modal-body,
.theme-dark #propertyFilterModal .modal-body,
.theme-dark #preferredSearchModal .modal-body{
  background:#0f172a !important;
  color: var(--ink) !important;
  border-top: 1px solid rgba(255,255,255,0.03) !important;
}

/* Close buttons (Bootstrap .btn-close uses an image mask) */
.theme-dark #preferredLocationModal .btn-close,
.theme-dark #propertyFilterModal .btn-close{
  filter: invert(1) hue-rotate(180deg) brightness(1.2);
  opacity: .9;
}
.theme-dark #preferredLocationModal .btn-close:hover,
.theme-dark #propertyFilterModal .btn-close:hover{
  opacity: 1;
}

/* "X" custom close icon keeps brand color; just ensure contrast on hover */
.theme-dark #preferredLocationModal .custom-close-icon{
  color: var(--brand) !important;
}
.theme-dark #preferredLocationModal .custom-close-icon:hover{
  filter: brightness(1.1);
}

/* ---------- Forms, Inputs, Selects, Groups ---------- */

/* Light chips/containers inside the modals */
.theme-dark #propertyFilterModal .bg-light{
  background:#0b1626 !important;
  border-color:#223045 !important;
  color: var(--ink) !important;
}

/* Labels and helper text */
.theme-dark #propertyFilterModal .form-label,
.theme-dark #propertyFilterModal .small,
.theme-dark #propertyFilterModal .text-secondary{
  color: var(--ink-2) !important;
}

/* Inputs */
.theme-dark #preferredLocationModal .form-control,
.theme-dark #propertyFilterModal .form-control,
.theme-dark #propertyFilterModal .form-select{
  background:#0b1220 !important;
  color: var(--ink) !important;
  border:1px solid #223045 !important;
  box-shadow: none !important;
}
.theme-dark #preferredLocationModal .form-control::placeholder,
.theme-dark #propertyFilterModal .form-control::placeholder{
  color:#8aa0b4 !important;
  opacity: .9;
}

/* Input-group adornments */
.theme-dark #propertyFilterModal .input-group-text{
  background:#0b1626 !important;
  color:#9fb4c9 !important;
  border-color:#223045 !important;
}

/* Select “chevron” is OS/native; ensure contrast on element */
.theme-dark #propertyFilterModal .form-select:focus,
.theme-dark #propertyFilterModal .form-control:focus,
.theme-dark #preferredLocationModal .form-control:focus{
  border-color: var(--brand) !important;
  box-shadow: 0 0 0 .2rem rgba(226,85,119,.25) !important; /* brand glow */
  outline: none !important;
}

/* Switch */
.theme-dark #propertyFilterModal .form-check-input{
  background-color:#223045 !important;
  border-color:#223045 !important;
}
.theme-dark #propertyFilterModal .form-check-input:checked{
  background-color: var(--brand) !important;
  border-color: var(--brand) !important;
}
.theme-dark #propertyFilterModal .form-check-input:focus{
  box-shadow: 0 0 0 .2rem rgba(226,85,119,.25) !important;
}

/* ---------- Buttons ---------- */

.theme-dark #propertyFilterModal .btn-primary,
.theme-dark #preferredLocationModal .btn-danger{
  background: var(--brand) !important;
  border-color: var(--brand) !important;
  color:#fff !important;
}
.theme-dark #propertyFilterModal .btn-primary:hover,
.theme-dark #preferredLocationModal .btn-danger:hover{
  background: var(--brand-dark) !important;
  border-color: var(--brand-dark) !important;
}

.theme-dark #propertyFilterModal .btn-outline-secondary{
  color: #c6d3e0 !important;
  border-color:#2a3a52 !important;
  background: transparent !important;
}
.theme-dark #propertyFilterModal .btn-outline-secondary:hover{
  background:#152238 !important;
  border-color:#375276 !important;
  color:#fff !important;
}

/* Modal backdrop a touch darker */
.theme-dark .modal-backdrop.show{
  opacity:.8 !important;
  background: #000 !important;
}

/* ---------- Odds & Ends ---------- */

/* Icons inside input-group and labels */
.theme-dark #propertyFilterModal .bi,
.theme-dark #propertyFilterModal svg[fill="currentColor"]{
  color:#9fb4c9 !important;
}

/* Price/SqFt block on mobile */
.theme-dark #propertyFilterModal .price-sqft-row{
  background:#0b1626 !important;
  border:1px solid #223045 !important;
}

/* Preferred location hint text */
.theme-dark #preferredLocationModal p{
  color: var(--ink-2) !important;
}

/* Text links inside the modals */
.theme-dark #preferredLocationModal a{
  color:#74b0ff !important;
}
.theme-dark #preferredLocationModal a:hover{
  color:#a7c9ff !important;
}

/* Ensure rounded/light borders read in dark */
.theme-dark #propertyFilterModal .rounded-3,
.theme-dark #propertyFilterModal .rounded-pill,
.theme-dark #preferredLocationModal .rounded-3{
  border-color:#223045 !important;
}

/* Make the select/inputs not “pop” on hover */
.theme-dark #propertyFilterModal .form-control:hover,
.theme-dark #propertyFilterModal .form-select:hover,
.theme-dark #preferredLocationModal .form-control:hover{
  border-color:#2a3a52 !important;
}

/* Keep the brand badge/icons readable */
.theme-dark #propertyFilterModal .text-primary{
  color: var(--brand) !important;
}





/* =========================================================
   INDEX (home) page — DARK MODE overrides
   Keeps carousel intact, fixes forced white backgrounds
   ========================================================= */

/* 1) Dark backdrop with a subtle overlay (keeps your bg image) */
.theme-dark body.home{
  color:#e6edf7 !important;
}
.theme-dark body.home::before{
  content:"";
  position:fixed;
  inset:0;
  background:linear-gradient(180deg, rgba(3,10,20,.65), rgba(3,10,20,.8));
  pointer-events:none;
  z-index: 0;
}

/* Ensure page content sits above the overlay */
.theme-dark body.home .main-content,
.theme-dark body.home .atp-modern-hero,
.theme-dark body.home .container,
.theme-dark body.home .container-fluid{
  position:relative;
  z-index:1;
}


/* 2) Neutralise global “force white” rules on sections */
.theme-dark body.home section:not(.hero-section),
.theme-dark body.home .main-content section{
  background:#0b1220 !important;
  backdrop-filter:none !important;
}

/* Keep the carousel itself as-is but put its section on dark */
.theme-dark body.home .featured-properties{
  background:#0b1220 !important;
}

/* Category selector bar */
.theme-dark body.home .carousel-category-selector{
  background:linear-gradient(135deg,#0d1526,#0b1220) !important;
}

/* Announcement + registration banners */
.theme-dark body.home .announcement-banner,
.theme-dark body.home .atp-registration-banner{
  background:#0f172a !important;
  border-top:1px solid #223045 !important;
  border-bottom:1px solid #223045 !important;
}
.theme-dark body.home .atp-registration-title{ color:#e6edf7 !important; }
.theme-dark body.home .atp-register-btn{
  background:var(--brand) !important; border-color:var(--brand) !important; color:#fff !important;
}
.theme-dark body.home .atp-register-btn:hover{
  background:var(--brand-dark) !important; border-color:var(--brand-dark) !important;
}


/* Restore visible pill button for "View Property" in dark mode */
.theme-dark .property-overlay .btn-view,
.theme-dark .btn-view {
    background: linear-gradient(45deg, #dc3545, #6d050fff);
    color: white !important;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
    box-shadow: 0 4px 15px rgba(157, 13, 15, 0.3);
}

/* Hover/active states */
.theme-dark .property-overlay .btn-view:hover,
.theme-dark .btn-view:hover {
  background: linear-gradient(45deg, #dc3545, #720611ff);
  color: #fff !important;
  box-shadow: 0 6px 20px rgba(179, 15, 42, 0.4);
  transform: translateY(-2px);
}


/* ======= SPECIFIC FIXES YOU ASKED FOR ======= */

/* 1) Preferred location CTA – make it white */
.theme-dark .atp-preferred-btn {
  color: #fff !important;
  border-color: rgba(255,255,255,0.35) !important;
  background: rgba(255,255,255,0.12) !important;
}
.theme-dark .atp-preferred-btn:hover {
  color: #fff !important;
  background: rgba(255,255,255,0.2) !important;
}

/* 2) "View Property" pill button – visible + white text */
.theme-dark .property-overlay .overlay-content a.btn-view,
.theme-dark .property-overlay a.btn-view,
.theme-dark a.btn-view,
.theme-dark .btn-view {
  background: linear-gradient(45deg, #dc3545, #6d050f);
  color: #fff !important;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  font-weight: 600;
  text-decoration: none !important;
  display: inline-block;
  box-shadow: 0 4px 15px rgba(157, 13, 15, 0.35);
  -webkit-text-fill-color: #fff !important; /* webkit quirk */
}
.theme-dark .btn-view:hover,
.theme-dark .property-overlay .btn-view:hover {
  background: linear-gradient(45deg, #dc3545, #720611);
  color: #fff !important;
  box-shadow: 0 6px 20px rgba(179, 15, 42, 0.45);
  transform: translateY(-2px);
}
.theme-dark .btn-view i,
.theme-dark .btn-view svg {
  color: #fff !important;
  fill: #fff !important;
}

/* Announcement banner title */
.theme-dark .banner-title { color: #fff; text-shadow: none; }

/* Navigation cards */
.theme-dark .primary-card { background: #a51c36; color: #fff; }
.theme-dark .secondary-card { background: #2a323b; color: #fff; }
.theme-dark .nav-card { border: 2px solid transparent; }
.theme-dark .nav-card .card-content small { color: #c7d0da; }

/* Business section */
.theme-dark .business-section { background: #a51c36; }
.theme-dark .business-btn {
  background: rgba(255,255,255,0.95);
  color: #000;
}
.theme-dark .business-btn:hover { color: #000; }

/* Misc small text contrasts */
.theme-dark .lead-text,
.theme-dark .feature-content p,
.theme-dark .property-location,
.theme-dark .description { color: #d5dde6; }

/* Inputs/focus rings contrast */
.theme-dark .form-control {
  background: #121820;
  color: #fff;
  border-color: #3a444f;
}
.theme-dark .form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(165, 28, 54, 0.25);
}

/* ============================
   DARK THEME — Sections Patch
   ============================ */

/* Global link color in dark */
.theme-dark a {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}
.theme-dark a:hover,
.theme-dark a:focus {
  color: var(--primary-light) !important;
  text-decoration: underline;
}

/* Section wrappers & titles */
.theme-dark .property-section {
  background: transparent;
}
.theme-dark .section-title {
  color: #fff;
}
.theme-dark .section-line {
  background: linear-gradient(90deg, var(--primary-color), #ff5b75);
}

/* ========== Location ========== */
.theme-dark .location-map {
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
}
.theme-dark .map-container {
  background: #0e1116;
  border: 1px solid rgba(255,255,255,0.06);
}
.theme-dark .map-container iframe {
  filter: grayscale(10%) contrast(1.02);
}
.theme-dark .location-details,
.theme-dark .location-info,
.theme-dark .nearby-places {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
  color: #e9eef5;
  border-radius: var(--border-radius-md);
}
.theme-dark .location-details { box-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.theme-dark .location-info h3,
.theme-dark .nearby-places h3 { color: #fff; }
.theme-dark .nearby-place { background: transparent; }
.theme-dark .place-icon {
  background: rgba(165, 28, 54, 0.12);
  color: #ffd7df;
}
.theme-dark .place-details h4 { color: #fff; }
.theme-dark .place-distance { color: #c7ced9; }

/* ========== Neighborhood ========== */
.theme-dark .stat-card {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
  color: #e9eef5;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}
.theme-dark .stat-icon {
  background: rgba(165,28,54,0.12);
  color: #ffd7df;
}
.theme-dark .stat-value { color: #fff; }
.theme-dark .stat-value span,
.theme-dark .stat-label { color: #c7ced9; }

.theme-dark .neighborhood-reviews {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
  color: #e9eef5;
}
.theme-dark .neighborhood-reviews h3 { color: #fff; }
.theme-dark .review-slide {
  background: #0b0e13;
  border: 1px solid rgba(255,255,255,0.05);
}
.theme-dark .reviewer-info h4 { color: #fff; }
.theme-dark .reviewer-info span { color: #b9c1cd; }
.theme-dark .review-nav {
  background: #0b0e13;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.08);
}
.theme-dark .review-nav:hover {
  background: var(--primary-color);
  color: #fff;
}
.theme-dark .review-dot { background: #3a4453; }
.theme-dark .review-dot.active,
.theme-dark .review-dot:hover { background: var(--primary-color); }

/* ========== Mortgage Calculator ========== */
.theme-dark .mortgage-calculator {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
  color: #e9eef5;
  box-shadow: 0 12px 36px rgba(0,0,0,0.55);
}
.theme-dark .calculator-form .form-label { color: #dfe6f0; }
.theme-dark .form-control,
.theme-dark .form-select {
  background: #0b0e13;
  color: #e9eef5;
  border: 1px solid rgba(255,255,255,0.08);
}
.theme-dark .form-control:focus,
.theme-dark .form-select:focus {
  background: #0b0e13;
  color: #fff;
  border-color: rgba(255,255,255,0.18);
  box-shadow: 0 0 0 0.25rem rgba(165,28,54,0.25);
}
.theme-dark .form-range::-webkit-slider-runnable-track { background: #2d3441; }
.theme-dark .form-range::-moz-range-track { background: #2d3441; }
.theme-dark .form-range::-webkit-slider-thumb { background: var(--primary-color); }
.theme-dark .range-values span { color: #b9c1cd; }

.theme-dark .result-card {
  background: #0b0e13;
  border: 1px solid rgba(255,255,255,0.06);
}
.theme-dark .result-title { color: #c7ced9; }
.theme-dark .result-value { color: #fff; }
.theme-dark .result-details {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
}
.theme-dark .result-item { border-bottom-color: rgba(255,255,255,0.08); }
.theme-dark .item-label { color: #c7ced9; }
.theme-dark .item-value { color: var(--primary-light); }
.theme-dark .calculator-disclaimer { color: #8c96a6; }

/* ========== CTA Section ========== */
.theme-dark .cta-container {
  background: linear-gradient(135deg, #a51c36 0%, #d32f4b 100%);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.08);
}
.theme-dark .cta-heading,
.theme-dark .cta-text { color: #fff; }
.theme-dark .btn.btn-light.cta-btn {
  background: #ffffff;
  color: #000;
  border: none;
}
.theme-dark .btn.btn-outline-light.cta-btn {
  border-color: #fff;
  color: #fff;
}
.theme-dark .btn.btn-outline-light.cta-btn:hover {
  background: rgba(255,255,255,0.12);
}

/* ========== Sidebar Cards ========== */
.theme-dark .sidebar-card {
  background: #0f1218;
  border: 1px solid rgba(255,255,255,0.06);
  color: #e9eef5;
  box-shadow: 0 12px 36px rgba(0,0,0,0.55);
}
.theme-dark .card-title { color: #fff; }

/* Agent card */
.theme-dark .agent-label { color: #b9c1cd; }
.theme-dark .agent-name { color: #ffd7df; }
.theme-dark .contact-item i { color: var(--primary-light); }

/* Details list */
.theme-dark .detail-item { border-bottom: 1px dashed rgba(255,255,255,0.08); }
.theme-dark .detail-label { color: #c7ced9; }
.theme-dark .detail-value { color: #fff; }
.theme-dark .epc-band.epc-c { background: #28a745; }

/* Inquiry form */
.theme-dark .inquiry-form .form-check-label { color: #dfe6f0; }

/* Action buttons */
.theme-dark .action-btn {
  background: #0b0e13;
  color: #e9eef5;
  border: 1px solid rgba(255,255,255,0.08);
}
.theme-dark .action-btn:hover {
  background: rgba(255,255,255,0.06);
}

/* Documents */
.theme-dark .document-item {
  background: #0b0e13;
  border: 1px solid rgba(255,255,255,0.06);
}
.theme-dark .document-name { color: #fff; }
.theme-dark .document-size { color: #b9c1cd; }
.theme-dark .document-icon { color: var(--primary-light); }
.theme-dark .document-action { color: #fff; }

/* Similar properties */
.theme-dark .similar-property { background: #0b0e13; border: 1px solid rgba(255,255,255,0.06); }
.theme-dark .property-info { background: #0f1218; }
.theme-dark .property-info h4 { color: #fff; }
.theme-dark .property-info p,
.theme-dark .property-meta { color: #c7ced9; }

/* Timeline */
.theme-dark .timeline-card { background: #0f1218; }
.theme-dark .property-timeline::before { background: rgba(255,255,255,0.08); }
.theme-dark .timeline-point {
  background: var(--primary-color);
  border-color: #0f1218;
}
.theme-dark .timeline-date { color: var(--primary-light); }
.theme-dark .timeline-text { color: #e9eef5; }

/* Back to Top */
.theme-dark #backToTopBtn {
  background: var(--primary-color);
  color: #fff;
  border: 1px solid rgba(255,255,255,0.08);
}
.theme-dark #backToTopBtn:hover {
  background: var(--primary-dark);
}

/* Pills / tabs hovering in dark (if present here) */
.theme-dark .nav-tabs { border-bottom-color: rgba(255,255,255,0.08); }
.theme-dark .nav-tabs .nav-link {
  color: #c7ced9;
}
.theme-dark .nav-tabs .nav-link.active,
.theme-dark .nav-tabs .nav-link:hover {
  color: #fff;
  border-bottom-color: var(--primary-light);
  background: transparent;
}

/* Buttons – ensure white text on dark */
.theme-dark .btn,
.theme-dark .btn-primary,
.theme-dark .btn-outline-primary {
  color: #fff;
}
.theme-dark .btn-outline-primary {
  border-color: var(--primary-light);
}
.theme-dark .btn-outline-primary:hover {
  background: var(--primary-light);
  border-color: var(--primary-light);
  color: #000;
}

/* ======================
   DARK MODE: Type Buttons
   ====================== */
.theme-dark .atp-property-types .atp-type-btn {
  background: rgba(255,255,255,0.08) !important; /* subtle dark background */
  color: #fff !important;
  border: 1px solid rgba(255,255,255,0.15) !important;
  box-shadow: 0 2px 6px rgba(0,0,0,0.4);
}

.theme-dark .atp-property-types .atp-type-btn:hover:not(.active) {
  background: rgba(255,255,255,0.18) !important;
  color: var(--primary-light) !important; /* subtle brand highlight */
  border-color: var(--primary-light) !important;
}

.theme-dark .atp-property-types .atp-type-btn.active,
.theme-dark .atp-property-types .atp-type-btn:active,
.theme-dark .atp-property-types .atp-type-btn:focus {
  background: linear-gradient(135deg, #b01e42 0%, #b01e42 100%) !important;
  color: #fff !important;
  border: none !important;
  box-shadow: 0 4px 12px rgba(196, 48, 43, 0.5);
}

/* ======================
   DARK MODE: Promo Offer
   ====================== */
.theme-dark .promo-offer {
  background: linear-gradient(135deg, #1a1d25, #14171f);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  text-align: center;
  box-shadow: 0 8px 20px rgba(0,0,0,0.6);
}

.theme-dark .promo-title {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--primary-light); /* your brand highlight */
  margin-bottom: 0.5rem;
}

.theme-dark .promo-sub {
  color: #c7ced9;
  font-size: 1rem;
  margin-bottom: 1rem;
}

.theme-dark .promo-price {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}
.theme-dark .promo-price .price {
  display: block;
  font-size: 1.4rem;
  font-weight: 800;
  color: #ffd7df; /* soft brand pink highlight */
}
.theme-dark .promo-price .per {
  font-size: .95rem;
  color: #b9c1cd;
}

.theme-dark .promo-restrict {
  font-size: 0.9rem;
  color: #c7ced9;
  background: #0f1218;
  border-radius: 8px;
  padding: .6rem .8rem;
  border: 1px dashed rgba(255,255,255,0.2);
  display: inline-block;
}

/* ===============================
   Add-to-Favourites Modal — Dark
   =============================== */
.theme-dark #atpAddFavModal .atp-fav-modal-content{
  background: linear-gradient(135deg,#0f172a 80%,#0a1326 100%);
  border: 1px solid #223045;
  box-shadow: 0 12px 36px rgba(2,6,23,.55);
  color: #e6edf7;
}

.theme-dark #atpAddFavModal .modal-header{
  border-bottom: none;
  background: transparent;
}

.theme-dark #atpAddFavModal .atp-fav-modal-title{
  color: #a51c36;          /* keep brand */
  text-shadow: none;       /* remove light-mode white shadow */
}

.theme-dark #atpAddFavModal .atp-fav-modal-body{
  color: #d9e1ee;          /* softer ink on dark */
}

.theme-dark #atpAddFavModal .atp-fav-msg{
  color: #dbe5f4;
  background: #0b1220;
  border: 1px solid #223045;
  box-shadow: 0 1px 0 rgba(255,255,255,.02), 0 6px 18px rgba(2,6,23,.35);
}

.theme-dark #atpAddFavModal .atp-fav-link{
  color: #a51c36;          /* brand link */
  text-decoration: underline dotted;
}
.theme-dark #atpAddFavModal .atp-fav-link:hover{
  color: #7c1427;
  text-decoration: underline;
}

.theme-dark #atpAddFavModal .atp-fav-close{
  color: #a51c36;
  background: #0f172a;
  border: 1px solid #223045;
  opacity: .95;
}
.theme-dark #atpAddFavModal .atp-fav-close:hover{
  background: #1a2235;
  opacity: 1;
}

.theme-dark #atpAddFavModal .atp-fav-float-close{
  background: #0b1220;
  color: #a51c36;
  border: 1px solid #223045;
  box-shadow: 0 6px 18px rgba(2,6,23,.4);
  opacity: .96;
}
.theme-dark #atpAddFavModal .atp-fav-float-close:hover{
  background: #1a2235;
  color: #7c1427;
  opacity: 1;
}

/* Mobile tweaks */
@media (max-width:576px){
  .theme-dark #atpAddFavModal .atp-fav-modal-content{
    padding: .7rem .2rem 1.1rem .2rem;
  }
  .theme-dark #atpAddFavModal .atp-fav-modal-title{
    font-size: .97rem;
  }
  .theme-dark #atpAddFavModal .atp-fav-modal-body,
  .theme-dark #atpAddFavModal .atp-fav-msg,
  .theme-dark #atpAddFavModal .atp-fav-link{
    font-size: .91rem;
  }
  .theme-dark #atpAddFavModal .atp-fav-float-close{
    width: 1.7rem; height: 1.7rem; font-size: 1.1rem; margin: .3rem .3rem 0 0;
  }
}

/* ===============================
   What's Local Modal — Dark mode
   =============================== */
.theme-dark #atpWhatsLocalModal .modal-content{
  background: linear-gradient(135deg,#0f172a 70%,#0a1326 100%);
  border:1px solid #223045;
  box-shadow: 0 12px 36px rgba(2,6,23,.55);
  color:#e6edf7;
  border-radius:1rem;
}
.theme-dark #atpWhatsLocalModal .modal-header{
  border-bottom:none;
  background:transparent;
  padding-bottom:0;
}
.theme-dark #atpWhatsLocalModal .modal-title{
  color:#e6edf7;
  font-weight:600;
}

/* Accordion */
.theme-dark #atpWhatsLocalModal .accordion-item{
  background:#0b1220;
  border:1px solid #223045;
  border-radius:.5rem;
  box-shadow:0 1px 0 rgba(255,255,255,.02), 0 6px 18px rgba(2,6,23,.35);
}
.theme-dark #atpWhatsLocalModal .accordion-button{
  color:#e6edf7;
  background:#0f172a;
  border-radius:.5rem;
}
.theme-dark #atpWhatsLocalModal .accordion-button:not(.collapsed){
  color:#e6edf7;
  background:#121a2c;
  box-shadow: inset 0 0 0 1px #2a3a56;
}
.theme-dark #atpWhatsLocalModal .accordion-button:focus{
  box-shadow:0 0 0 .2rem rgba(165,28,54,.35);
  border-color:#a51c36;
}
.theme-dark #atpWhatsLocalModal .accordion-body{
  background:#0b1220;
  color:#dbe5f4;
  border-radius:.5rem;
}

/* Close button (Bootstrap's SVG) */
.theme-dark #atpWhatsLocalModal .btn-close{
  filter: invert(1) grayscale(100%) brightness(200%);
  opacity:.8;
}
.theme-dark #atpWhatsLocalModal .btn-close:hover{
  opacity:1;
}

/* Keep brand accent for any links inside */
.theme-dark #atpWhatsLocalModal a{
  color:#a51c36;
}
.theme-dark #atpWhatsLocalModal a:hover{
  color:#7c1427;
  text-decoration:underline;
}

/* Optional: tweak accordion chevron visibility */
.theme-dark #atpWhatsLocalModal .accordion-button::after{
  filter: invert(1) brightness(1.4);
}

/* Mobile tweaks */
@media (max-width: 767.98px){
  .theme-dark #atpWhatsLocalModal .modal-dialog{
    max-width:98vw;
    margin:.5rem auto;
  }
  .theme-dark #atpWhatsLocalModal .modal-content{
    padding:.2rem .2rem 1rem .2rem;
  }
  .theme-dark #atpWhatsLocalModal .modal-title{
    font-size:1.05rem;
  }
  .theme-dark #atpWhatsLocalModal .accordion-button{
    font-size:.97rem;
  }
}

/* Dark mode: make ONLY the two ad buttons' text black */
.theme-dark .ads-section .business-section .button-container a,
.theme-dark .ads-section .business-section .button-container a:visited,
.theme-dark .ads-section .business-section .button-container a:hover,
.theme-dark .ads-section .business-section .button-container a:focus {
  color: #000 !important;
  -webkit-text-fill-color: #000 !important; /* beats Safari's fill */
}

/* Ensure the icons inside those links are black too */
.theme-dark .ads-section .business-section .button-container a i {
  color: #000 !important;
}





