:root {
  --theme-bg: #f9f7f2;
  --theme-surface: #ffffff;
  --theme-text: #2c2c2c;
  --theme-muted: #6b7280;
  --theme-primary: #f43f5e;
  --theme-primary-strong: #be123c;
  --theme-accent: #b76e79;
  --theme-header-start: rgba(122, 31, 47, 0.88);
  --theme-header-middle: rgba(183, 110, 121, 0.46);
  --theme-header-end: rgba(183, 110, 121, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #1e293b;
  --theme-footer-bg: #1a1a1a;
  --theme-footer-orb-1: #f43f5e;
  --theme-footer-orb-2: #3b82f6;
}

body[class*="theme-"] {
  background-color: var(--theme-bg);
  color: var(--theme-text);
}

body[class*="theme-"] .bg-cream { background-color: var(--theme-bg) !important; }
body[class*="theme-"] .bg-white { background-color: var(--theme-surface) !important; }
body[class*="theme-"] .text-dark-gray { color: var(--theme-text) !important; }
body[class*="theme-"] .text-gray-400,
body[class*="theme-"] .text-gray-500 { color: var(--theme-muted) !important; }

body[class*="theme-"] .text-rose-300,
body[class*="theme-"] .text-rose-400,
body[class*="theme-"] .text-rose-500,
body[class*="theme-"] .text-rose-600,
body[class*="theme-"] .text-rose-700,
body[class*="theme-"] .text-rose-gold { color: var(--theme-primary) !important; }

body[class*="theme-"] .bg-rose-400,
body[class*="theme-"] .bg-rose-500,
body[class*="theme-"] .bg-rose-600,
body[class*="theme-"] .bg-rose-gold { background-color: var(--theme-primary) !important; }

body[class*="theme-"] .border-rose-100,
body[class*="theme-"] .border-rose-200,
body[class*="theme-"] .border-rose-300,
body[class*="theme-"] .border-rose-400,
body[class*="theme-"] .border-rose-500,
body[class*="theme-"] .border-rose-gold { border-color: var(--theme-primary) !important; }

body[class*="theme-"] .from-rose-400,
body[class*="theme-"] .from-rose-500,
body[class*="theme-"] .from-rose-gold {
  --tw-gradient-from: var(--theme-primary) var(--tw-gradient-from-position) !important;
  --tw-gradient-to: rgb(0 0 0 / 0) var(--tw-gradient-to-position) !important;
  --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to) !important;
}

body[class*="theme-"] .to-rose-600,
body[class*="theme-"] .to-rose-700,
body[class*="theme-"] .to-rose-gold {
  --tw-gradient-to: var(--theme-primary-strong) var(--tw-gradient-to-position) !important;
}

body[class*="theme-"] #main-header {
  background: linear-gradient(
    to bottom,
    var(--theme-header-start) 0%,
    var(--theme-header-middle) 48%,
    var(--theme-header-end) 100%
  ) !important;
}

body[class*="theme-"] #main-header .cta-btn {
  background-color: var(--theme-cta-bg) !important;
  color: var(--theme-cta-text) !important;
}

body[class*="theme-"] #main-header.scrolled-mode {
  background: var(--theme-surface) !important;
}

body[class*="theme-"] #main-header.scrolled-mode .nav-link,
body[class*="theme-"] #main-header.scrolled-mode .brand-text {
  color: var(--theme-text) !important;
}

body[class*="theme-"] #main-header.scrolled-mode .brand-sub,
body[class*="theme-"] #main-header.scrolled-mode .mobile-toggle,
body[class*="theme-"] #main-header.scrolled-mode .mobile-phone-icon {
  color: var(--theme-muted) !important;
}

body[class*="theme-"] #main-header.scrolled-mode .cta-btn {
  background-color: var(--theme-primary-strong) !important;
  color: #ffffff !important;
}

body[class*="theme-"] footer,
body[class*="theme-"] footer .bg-\[\#1a1a1a\] {
  background-color: var(--theme-footer-bg) !important;
}

body[class*="theme-"] footer .bg-rose-500 {
  background-color: var(--theme-footer-orb-1) !important;
}

body[class*="theme-"] footer .bg-blue-500 {
  background-color: var(--theme-footer-orb-2) !important;
}

body.theme-default {
  --theme-bg: #f9f7f2;
  --theme-surface: #ffffff;
  --theme-text: #2c2c2c;
  --theme-muted: #6b7280;
  --theme-primary: #f43f5e;
  --theme-primary-strong: #be123c;
  --theme-accent: #b76e79;
  --theme-header-start: rgba(122, 31, 47, 0.88);
  --theme-header-middle: rgba(183, 110, 121, 0.46);
  --theme-header-end: rgba(183, 110, 121, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #1e293b;
  --theme-footer-bg: #1a1a1a;
  --theme-footer-orb-1: #f43f5e;
  --theme-footer-orb-2: #3b82f6;
}

body.theme-ocean {
  --theme-bg: #eff8ff;
  --theme-surface: #ffffff;
  --theme-text: #0f172a;
  --theme-muted: #475569;
  --theme-primary: #0ea5e9;
  --theme-primary-strong: #0369a1;
  --theme-accent: #0f766e;
  --theme-header-start: rgba(3, 105, 161, 0.9);
  --theme-header-middle: rgba(14, 116, 144, 0.42);
  --theme-header-end: rgba(14, 116, 144, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #0f172a;
  --theme-footer-bg: #0b1728;
  --theme-footer-orb-1: #0ea5e9;
  --theme-footer-orb-2: #22d3ee;
}

body.theme-emerald {
  --theme-bg: #f2fbf6;
  --theme-surface: #ffffff;
  --theme-text: #1b4332;
  --theme-muted: #4b6358;
  --theme-primary: #10b981;
  --theme-primary-strong: #047857;
  --theme-accent: #059669;
  --theme-header-start: rgba(4, 120, 87, 0.9);
  --theme-header-middle: rgba(16, 185, 129, 0.38);
  --theme-header-end: rgba(16, 185, 129, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #1b4332;
  --theme-footer-bg: #0f1f1a;
  --theme-footer-orb-1: #10b981;
  --theme-footer-orb-2: #22c55e;
}

body.theme-amber {
  --theme-bg: #fff9f0;
  --theme-surface: #ffffff;
  --theme-text: #422006;
  --theme-muted: #7c5c34;
  --theme-primary: #f59e0b;
  --theme-primary-strong: #b45309;
  --theme-accent: #ea580c;
  --theme-header-start: rgba(180, 83, 9, 0.9);
  --theme-header-middle: rgba(245, 158, 11, 0.4);
  --theme-header-end: rgba(245, 158, 11, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #422006;
  --theme-footer-bg: #1f1408;
  --theme-footer-orb-1: #f59e0b;
  --theme-footer-orb-2: #fb923c;
}

body.theme-midnight {
  --theme-bg: #edf2ff;
  --theme-surface: #ffffff;
  --theme-text: #1e1b4b;
  --theme-muted: #4c4f7c;
  --theme-primary: #6366f1;
  --theme-primary-strong: #4338ca;
  --theme-accent: #0f172a;
  --theme-header-start: rgba(30, 27, 75, 0.93);
  --theme-header-middle: rgba(67, 56, 202, 0.35);
  --theme-header-end: rgba(67, 56, 202, 0);
  --theme-cta-bg: #ffffff;
  --theme-cta-text: #1e1b4b;
  --theme-footer-bg: #111827;
  --theme-footer-orb-1: #6366f1;
  --theme-footer-orb-2: #3b82f6;
}
