/* Semantic colors keep all existing page-specific components consistent in both themes. */
:root {
  color-scheme:light;
  --page-bg:#FFFFFF;
  --surface:#FFFFFF;
  --surface-soft:#F8F9FA;
  --surface-warm:#FFF6F7;
  --surface-glass:rgba(255,255,255,.96);
  --page-gradient:linear-gradient(145deg,#FFFFFF,#FDF6F7);
  --link:#C90012;
  --muted:#626B76;
  --placeholder:#717B87;
  --gray-border:#EDD8DC;
}
body { background-color:var(--page-bg); }
.theme-toggle { display:inline-flex; align-items:center; justify-content:center; flex-shrink:0; width:40px; height:40px; padding:0; color:var(--text); background:var(--surface); border:1px solid var(--gray-border); border-radius:50%; cursor:pointer; }
.theme-toggle:hover { color:var(--link); border-color:var(--link); background:var(--pale); }
.theme-toggle:focus-visible { outline:3px solid var(--accent); outline-offset:4px; }
.theme-icon-sun { display:none; }
html[data-theme="dark"] .theme-icon-sun { display:block; }
html[data-theme="dark"] .theme-icon-moon { display:none; }
@media (min-width:1200px) and (max-width:1399px) { .theme-toggle { width:36px; height:36px; } }
@media (prefers-reduced-motion:no-preference) {
  .theme-toggle { transition:color .2s,background-color .2s,border-color .2s,transform .2s; }
  .theme-toggle:active { transform:scale(.94); }
}
html[data-theme="dark"] {
  color-scheme:dark;
  --page-bg:#0C1117;
  --surface:#111820;
  --surface-soft:#17212B;
  --surface-warm:#211A23;
  --surface-glass:rgba(17,24,32,.96);
  --page-gradient:linear-gradient(145deg,#141C26,#0C1117);
  --text:#F1F4F8;
  --muted:#AFB9C6;
  --placeholder:#9BA8B8;
  --link:#FF7A87;
  --accent:#FF7A87;
  --pale:#1B2530;
  --gray-border:#35414F;
  --shadow-sm:0 4px 14px #00000020;
  --shadow-md:0 14px 36px #00000035;
  --shadow-lg:0 24px 60px #00000040;
}
html[data-theme="dark"] body { background:var(--page-bg); }
html[data-theme="dark"] .site-header,
html[data-theme="dark"] .site-header.scrolled { background:var(--surface-glass); border-bottom-color:var(--gray-border); box-shadow:0 4px 20px #00000020; }
html[data-theme="dark"] main :is(h1,h2,h3,h4) { color:var(--text); }
html[data-theme="dark"] .logo-text small { color:var(--muted); }
/* Preserve the supplied logo artwork and give its dark lettering a light backing. */
html[data-theme="dark"] .site-header .logo-mark { background:#FFFFFF; border-radius:6px; padding:2px; }
html[data-theme="dark"] .nav-links a.active { color:var(--link); }
html[data-theme="dark"] .nav-links a::after { background:var(--link); }
html[data-theme="dark"] .mobile-menu { background:var(--surface); border-left:1px solid var(--gray-border); }
html[data-theme="dark"] .overlay { background:#00000070; }
html[data-theme="dark"] .hero,
html[data-theme="dark"] .page-header { background:var(--page-gradient); }
html[data-theme="dark"] .blueprint-bg { background-image:linear-gradient(#FFFFFF04 1px,transparent 1px),linear-gradient(90deg,#FFFFFF04 1px,transparent 1px); }
html[data-theme="dark"] .filter-bar { background:var(--surface-glass); border-color:var(--gray-border); }
html[data-theme="dark"] .filter-btn.active,
html[data-theme="dark"] .btn-primary { background:#C90012; border-color:#C90012; color:#FFFFFF; }
html[data-theme="dark"] .btn-primary:hover { background:#8F0010; }
html[data-theme="dark"] .kisvera-social { border-color:var(--gray-border); }
html[data-theme="dark"] .kisvera-social:hover { color:#FFFFFF; border-color:#FF1725; background:#C90012; }
html[data-theme="dark"] .btn-text { color:var(--link); }
html[data-theme="dark"] :is(.product-card,.team-card,.pricing-card,.approach-card,.vertical-card,.technology-card,.assurance-feature,.assurance-scope,.contact-form-wrap) { border-color:var(--gray-border); box-shadow:var(--shadow-sm); }
html[data-theme="dark"] .industry-panel { background:var(--surface); }
html[data-theme="dark"] .technology-panel { border-top-color:var(--link); }
html[data-theme="dark"] .build-icon { background:#FF7A8712; color:var(--link); }
html[data-theme="dark"] .build-index { color:var(--link); }
html[data-theme="dark"] .technology-build .area-tag { color:var(--link); border-color:var(--gray-border); }
html[data-theme="dark"] .assurance-visual { background:#111820; border-color:var(--gray-border); }
html[data-theme="dark"] .assurance-workflow li { border-top-color:var(--link); }
html[data-theme="dark"] .assurance-workflow li::after,
html[data-theme="dark"] .workflow-number { color:var(--link); }
html[data-theme="dark"] .form-control { color:var(--text); background-color:var(--surface-soft); border-color:var(--gray-border); }
html[data-theme="dark"] .form-control::placeholder { color:var(--placeholder); }
html[data-theme="dark"] select.form-control { background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23FF7A87' d='M6 8L0 0h12z'/%3E%3C/svg%3E"); }
html[data-theme="dark"] .form-status.success { background:#142C20; border-color:#296641; color:#A1EDBA; }
html[data-theme="dark"] .form-status.error { background:#351B22; border-color:#79404C; color:#FFB3BC; }
html[data-theme="dark"] .site-footer { background:#0A0F15; border-top:1px solid var(--gray-border); }
html[data-theme="dark"] .site-footer .footer-brand p { color:#D0D7E0; }
html[data-theme="dark"] .site-footer .footer-bottom { color:#ADB8C6; }
html[data-theme="dark"] .social-status { background:var(--surface-soft); border:1px solid var(--gray-border); }
html[data-theme="dark"] :is(.kiswera-ai-panel,.kiswera-ai-msg.bot,.kiswera-ai-typing,.kiswera-ai-input,.kiswera-ai-suggestion) { background:var(--surface); border-color:var(--gray-border); color:var(--text); }
html[data-theme="dark"] .kiswera-ai-messages { background:var(--page-bg); }
html[data-theme="dark"] .kiswera-ai-input input { background:var(--surface-soft); color:var(--text); border-color:var(--gray-border); }
html[data-theme="dark"] .kiswera-ai-msg.bot a,
html[data-theme="dark"] .kiswera-ai-suggestion { color:var(--link); }
html[data-theme="dark"] .kiswera-ai-header-text h3 { color:#FFFFFF; }
html[data-theme="dark"] .kiswera-ai-header-text p { color:#FFFFFFCC; }
/* Existing red information strips stay red with white text, distinct from neutral cards. */
html[data-theme="dark"] :is(.tech-map-section,.process-strip,.team-imagery,.values-strip,.trial-banner) { background:#8F0010; }
html[data-theme="dark"] :is(.tech-map-section,.process-strip,.team-imagery,.values-strip,.trial-banner) :is(h2,h3,h4) { color:#FFFFFF; }

html[data-theme="dark"] .technology-build .build-panel-heading h3 { color:var(--link); }
html[data-theme="dark"] .form-control,
html[data-theme="dark"] .kiswera-ai-input input { border-color:#647385; }
html[data-theme="dark"] .form-control:focus,
html[data-theme="dark"] .kiswera-ai-input input:focus { border-color:var(--link); box-shadow:0 0 0 3px #FF7A8726; }
