:root {
  color-scheme: dark;
  --comet-page-bg: #0f172a;
  --comet-page-bg-soft: #111827;
  --comet-header-bg: linear-gradient(90deg, rgba(11, 18, 32, 0.75), rgba(15, 23, 42, 0.75));
  --comet-panel-bg: #0b1220;
  --comet-panel-bg-soft: #0a0f1e;
  --comet-panel-bg-elevated: #111827;
  --comet-input-bg: #0b1220;
  --comet-input-readonly-bg: #111827;
  --comet-text: #e2e8f0;
  --comet-text-strong: #f8fafc;
  --comet-muted: #94a3b8;
  --comet-muted-strong: #cbd5e1;
  --comet-link: #93c5fd;
  --comet-link-hover: #ffffff;
  --comet-border: #374151;
  --comet-border-soft: rgba(55, 65, 81, 0.72);
  --comet-focus: #60a5fa;
  --comet-code-bg: #0a0f1e;
  --comet-code-text: #e5e7eb;
  --comet-accent: #3b82f6;
  --comet-accent-strong: #2563eb;
  --comet-accent-soft: rgba(59, 130, 246, 0.16);
  --comet-success: #22c55e;
  --comet-success-soft: rgba(34, 197, 94, 0.14);
  --comet-warning: #f59e0b;
  --comet-warning-soft: rgba(245, 158, 11, 0.14);
  --comet-error: #ef4444;
  --comet-error-soft: rgba(239, 68, 68, 0.14);
  --comet-shadow: rgba(2, 6, 23, 0.28);
  --comet-disabled-bg: #334155;
  --comet-disabled-text: #94a3b8;
  --comet-banner-opacity: 0.5;
  --comet-banner-height: clamp(190px, 28vh, 340px);
}

html[data-theme="light"] {
  color-scheme: light;
  --comet-page-bg: #f6f9fd;
  --comet-page-bg-soft: #edf4fb;
  --comet-header-bg: linear-gradient(90deg, rgba(255, 255, 255, 0.75), rgba(234, 244, 255, 0.75));
  --comet-panel-bg: #ffffff;
  --comet-panel-bg-soft: #f8fbff;
  --comet-panel-bg-elevated: #eef6ff;
  --comet-input-bg: #ffffff;
  --comet-input-readonly-bg: #eef2f7;
  --comet-text: #122033;
  --comet-text-strong: #0f172a;
  --comet-muted: #52657d;
  --comet-muted-strong: #334155;
  --comet-link: #075ca8;
  --comet-link-hover: #023d73;
  --comet-border: #b9c6d6;
  --comet-border-soft: rgba(148, 163, 184, 0.7);
  --comet-focus: #0ea5e9;
  --comet-code-bg: #edf3f9;
  --comet-code-text: #122033;
  --comet-accent: #0f74bf;
  --comet-accent-strong: #075ca8;
  --comet-accent-soft: rgba(14, 116, 191, 0.12);
  --comet-success: #12853d;
  --comet-success-soft: rgba(18, 133, 61, 0.12);
  --comet-warning: #a86405;
  --comet-warning-soft: rgba(168, 100, 5, 0.13);
  --comet-error: #c0262d;
  --comet-error-soft: rgba(192, 38, 45, 0.12);
  --comet-shadow: rgba(15, 23, 42, 0.13);
  --comet-disabled-bg: #dbe4ef;
  --comet-disabled-text: #64748b;
  --comet-banner-opacity: 0.7;
}

body {
  position: relative;
  background: var(--comet-page-bg);
  color: var(--comet-text);
}

body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--comet-banner-height);
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(180deg, rgba(15, 23, 42, 0) 0%, var(--comet-page-bg) 100%),
    url("background-banner.png");
  background-position: center top;
  background-repeat: no-repeat;
  background-size: cover;
  opacity: var(--comet-banner-opacity);
}

body > * {
  position: relative;
  z-index: 1;
}

.site-header {
  position: relative;
  z-index: 3;
  width: 100vw;
  background: var(--comet-header-bg) !important;
  margin-left: calc(50% - 50vw) !important;
  margin-right: calc(50% - 50vw) !important;
  margin-top: 0 !important;
  border-radius: 0 !important;
  box-sizing: border-box;
}

.theme-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 2px;
  border: 1px solid var(--comet-border);
  border-radius: 999px;
  background: var(--comet-panel-bg);
  box-shadow: 0 1px 6px var(--comet-shadow);
}

.theme-button {
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--comet-muted-strong);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}

.theme-button svg {
  width: 17px;
  height: 17px;
}

.theme-button:hover,
.theme-button:focus-visible {
  color: var(--comet-text-strong);
  background: var(--comet-accent-soft);
  outline: none;
}

.theme-button.active {
  color: #ffffff;
  background: var(--comet-accent-strong);
}

.theme-button:focus-visible {
  box-shadow: 0 0 0 2px var(--comet-focus);
}

.canfar-heading-logo {
  width: 24px !important;
  height: 24px !important;
}

html[data-theme="light"] img[src*="canfar-logo.png"],
html[data-theme="light"] img[data-comet-theme-logo="canfar"] {
  content: url("canfar-logo-light.png");
}

.btn-cadc img {
  object-fit: contain;
  background: #ffffff;
  border-radius: 6px;
  padding: 4px;
  box-sizing: border-box;
}

html[data-theme="light"] body {
  background: var(--comet-page-bg) !important;
  color: var(--comet-text) !important;
}

html[data-theme="light"] .wrap {
  background: transparent !important;
  color: var(--comet-text) !important;
}

html[data-theme="light"] .site-header {
  background: var(--comet-header-bg) !important;
  border-color: var(--comet-border) !important;
  box-shadow: 0 1px 10px var(--comet-shadow);
}

html[data-theme="light"] .comet-word text,
html[data-theme="light"] .comet-word text[fill] {
  fill: #075ca8 !important;
}

html[data-theme="light"] .brand:hover .comet-word text {
  fill: #0f172a !important;
}

html[data-theme="light"] .version-label,
html[data-theme="light"] .comet-word text[style*="fill:#ffffff"],
html[data-theme="light"] .comet-word text[style*="fill: #ffffff"] {
  color: var(--comet-text-strong) !important;
  fill: var(--comet-text-strong) !important;
}

html[data-theme="light"] .nav-links a,
html[data-theme="light"] .dropdown summary {
  color: var(--comet-muted-strong) !important;
}

html[data-theme="light"] .nav-links a.active,
html[data-theme="light"] .nav-links a:hover,
html[data-theme="light"] .dropdown[open] summary,
html[data-theme="light"] .dropdown summary:hover {
  color: var(--comet-link-hover) !important;
}

html[data-theme="light"] .dropdown-menu {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  box-shadow: 0 12px 32px var(--comet-shadow);
}

html[data-theme="light"] .dropdown-menu a {
  color: var(--comet-muted-strong) !important;
}

html[data-theme="light"] .dropdown-menu a:hover {
  background: var(--comet-panel-bg-elevated) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .hostline,
html[data-theme="light"] .muted,
html[data-theme="light"] .small,
html[data-theme="light"] .site-footer,
html[data-theme="light"] .footer-sep,
html[data-theme="light"] .tagline,
html[data-theme="light"] .effective,
html[data-theme="light"] .contact-meta,
html[data-theme="light"] .file-meta,
html[data-theme="light"] .workflow-list-subtitle,
html[data-theme="light"] .workflow-overview-meta,
html[data-theme="light"] #workflow-overview-summary,
html[data-theme="light"] #harbor-repo-modal-note,
html[data-theme="light"] #autotest-progress-label,
html[data-theme="light"] #autotest-daily-info {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] a,
html[data-theme="light"] .feature strong,
html[data-theme="light"] details:not(.dropdown) > summary,
html[data-theme="light"] .contact-name,
html[data-theme="light"] .provider-title-inline,
html[data-theme="light"] h3 {
  color: var(--comet-link) !important;
}

html[data-theme="light"] a:hover {
  color: var(--comet-link-hover) !important;
}

html[data-theme="light"] #wizard-steps .current,
html[data-theme="light"] #wizard-steps .current strong {
  color: #0f172a !important;
  text-decoration-color: #0f172a !important;
}

html[data-theme="light"] h1,
html[data-theme="light"] h4,
html[data-theme="light"] label,
html[data-theme="light"] .file-name,
html[data-theme="light"] .at-file-hdr,
html[data-theme="light"] .workflow-stat strong,
html[data-theme="light"] .modal-card h3,
html[data-theme="light"] .inner h3 {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] h2,
html[data-theme="light"] .deploy-mode h4,
html[data-theme="light"] .tab-panel h4 {
  color: #8a5204 !important;
}

html[data-theme="light"] .box,
html[data-theme="light"] form,
html[data-theme="light"] .provider-box,
html[data-theme="light"] .feature,
html[data-theme="light"] .deploy-mode,
html[data-theme="light"] .toc,
html[data-theme="light"] .tab-panel,
html[data-theme="light"] details:not(.dropdown),
html[data-theme="light"] .modal-card,
html[data-theme="light"] #reset-modal .inner,
html[data-theme="light"] .template-apply-popover,
html[data-theme="light"] .template-ai-panel,
html[data-theme="light"] .custom-ai-panel,
html[data-theme="light"] .file-block,
html[data-theme="light"] .workflow-file-row,
html[data-theme="light"] .workflow-overview,
html[data-theme="light"] .workflow-stat,
html[data-theme="light"] .at-file,
html[data-theme="light"] .collision-merge-shell,
html[data-theme="light"] .collision-code-pane,
html[data-theme="light"] .collision-merge-loading,
html[data-theme="light"] .collision-merge-error {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
}

html[data-theme="light"] a.btn:not(.btn-gh),
html[data-theme="light"] button.btn {
  color: #ffffff !important;
}

html[data-theme="light"] a.btn-gh,
html[data-theme="light"] a.btn-cadc {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .btn:disabled,
html[data-theme="light"] .btn[disabled] {
  color: #51657d !important;
}

html[data-theme="light"] .highlight-box {
  background: linear-gradient(135deg, #e6f3ff 0%, #ffffff 100%) !important;
  border-color: var(--comet-accent) !important;
}

html[data-theme="light"] .cfi-badge {
  background: #dbeafe !important;
  border: 1px solid #93c5fd !important;
  color: #0b4f8a !important;
}

html[data-theme="light"] .candiapl-hero-logo ~ .box,
html[data-theme="light"] .candiapl-hero-logo ~ .box p,
html[data-theme="light"] .candiapl-hero-logo ~ .box ul,
html[data-theme="light"] .candiapl-hero-logo ~ .box li {
  color: #1e293b !important;
}

html[data-theme="light"] .candiapl-hero-logo ~ .box .muted {
  color: #475569 !important;
}

html[data-theme="light"] .pillar-list li {
  background: #f8fbff !important;
  border-color: var(--comet-border) !important;
  border-left-color: var(--comet-accent) !important;
  color: #1e293b !important;
}

html[data-theme="light"] .pillar-list li strong {
  color: #8a5204 !important;
}

html[data-theme="light"] .pillar-list li .abbr {
  color: #52657d !important;
}

html[data-theme="light"] .pillar-list li p {
  color: #243449 !important;
}

html[data-theme="light"] .logo-wrap ~ .box,
html[data-theme="light"] .logo-wrap ~ .box p,
html[data-theme="light"] .logo-wrap ~ .box ul,
html[data-theme="light"] .logo-wrap ~ .box li {
  color: #1e293b !important;
}

html[data-theme="light"] .logo-wrap ~ .box .muted,
html[data-theme="light"] .logo-wrap ~ .box .feature p,
html[data-theme="light"] .logo-wrap ~ .box .deploy-mode p {
  color: #475569 !important;
}

html[data-theme="light"] .logo-wrap ~ .box .feature,
html[data-theme="light"] .logo-wrap ~ .box .deploy-mode,
html[data-theme="light"] .logo-wrap ~ .box .step-list li {
  background: #f8fbff !important;
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] .logo-wrap ~ .box .step-list li {
  border-left-color: var(--comet-accent) !important;
}

html[data-theme="light"] .logo-wrap ~ .highlight-box .btn {
  background: #dbeafe !important;
  border: 1px solid #93c5fd !important;
  color: #0b4f8a !important;
}

html[data-theme="light"] .logo-wrap ~ .highlight-box .btn:hover {
  background: #bfdbfe !important;
  border-color: #60a5fa !important;
  color: #083c6b !important;
}

html[data-theme="light"] .contact-page .box,
html[data-theme="light"] .contact-page .box p,
html[data-theme="light"] .contact-page .box ul,
html[data-theme="light"] .contact-page .box li {
  color: #1e293b !important;
}

html[data-theme="light"] .contact-page .muted,
html[data-theme="light"] .contact-page .contact-meta {
  color: #475569 !important;
}

html[data-theme="light"] .contact-page .highlight-box .muted {
  color: #334155 !important;
}

html[data-theme="light"] .contact-page li::marker {
  color: #64748b !important;
}

html[data-theme="light"] .step-list li,
html[data-theme="light"] .tab,
html[data-theme="light"] .tab-btn,
html[data-theme="light"] .btn-gh,
html[data-theme="light"] .btn-ghost,
html[data-theme="light"] .icon-btn,
html[data-theme="light"] .seg-toggle,
html[data-theme="light"] .file-view-toggle-btn {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
}

html[data-theme="light"] .tab.active,
html[data-theme="light"] .tab-btn.active,
html[data-theme="light"] .seg-toggle.active,
html[data-theme="light"] .file-view-toggle-btn.active {
  background: var(--comet-panel-bg-elevated) !important;
  color: var(--comet-link) !important;
  border-color: var(--comet-accent) !important;
}

html[data-theme="light"] .btn-gh:hover,
html[data-theme="light"] .btn-ghost:hover,
html[data-theme="light"] .icon-btn:hover,
html[data-theme="light"] .seg-toggle:hover,
html[data-theme="light"] .file-view-toggle-btn:hover {
  background: var(--comet-panel-bg-elevated) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] input:not([type="checkbox"]):not([type="radio"]):not([type="range"]),
html[data-theme="light"] select,
html[data-theme="light"] textarea {
  background: var(--comet-input-bg) !important;
  color: var(--comet-text-strong) !important;
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] input::placeholder,
html[data-theme="light"] textarea::placeholder {
  color: #74849a !important;
}

html[data-theme="light"] input[readonly],
html[data-theme="light"] textarea[readonly],
html[data-theme="light"] select:disabled,
html[data-theme="light"] input:disabled,
html[data-theme="light"] textarea:disabled,
html[data-theme="light"] button:disabled,
html[data-theme="light"] .btn:disabled,
html[data-theme="light"] .btn[disabled] {
  background: var(--comet-disabled-bg) !important;
  color: var(--comet-disabled-text) !important;
  border-color: var(--comet-border-soft) !important;
  opacity: 1 !important;
}

html[data-theme="light"] .pem-action-btn {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .pem-action-btn:hover,
html[data-theme="light"] .pem-action-btn:focus-visible {
  background: var(--comet-panel-bg-elevated) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .pem-action-btn[aria-pressed="true"] {
  background: var(--comet-accent-soft) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .pem-title {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] #flow-reset {
  color: #075ca8 !important;
}

html[data-theme="light"] input:focus,
html[data-theme="light"] select:focus,
html[data-theme="light"] textarea:focus,
html[data-theme="light"] button:focus-visible,
html[data-theme="light"] a:focus-visible {
  outline-color: var(--comet-focus) !important;
}

html[data-theme="light"] pre,
html[data-theme="light"] code:not(.hostval),
html[data-theme="light"] .code-block,
html[data-theme="light"] .at-file-body pre,
html[data-theme="light"] .collision-code-pane pre,
html[data-theme="light"] .file-block pre {
  background: var(--comet-code-bg) !important;
  color: var(--comet-code-text) !important;
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] .hostval {
  color: #8a5204 !important;
  background: #fff7e6 !important;
  border: 1px solid #d8bd7f !important;
  border-radius: 4px;
  padding: 2px 5px;
}

html[data-theme="light"] .divider,
html[data-theme="light"] .site-footer,
html[data-theme="light"] .tab-list,
html[data-theme="light"] .workflow-file-tree-root .file-block summary,
html[data-theme="light"] .collision-merge-loading,
html[data-theme="light"] .collision-merge-error {
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] .alert.error,
html[data-theme="light"] .error,
html[data-theme="light"] .collision-merge-error,
html[data-theme="light"] #harbor-repo-modal-note.error {
  color: var(--comet-error) !important;
}

html[data-theme="light"] .alert.error {
  background: var(--comet-error-soft) !important;
  border-color: var(--comet-error) !important;
}

html[data-theme="light"] .alert.warn {
  background: var(--comet-warning-soft) !important;
  border-color: var(--comet-warning) !important;
  color: #7a4700 !important;
}

html[data-theme="light"] .new-file,
html[data-theme="light"] .file-block.new,
html[data-theme="light"] .workflow-file-row.new {
  border-color: var(--comet-success) !important;
  background: var(--comet-success-soft) !important;
}

html[data-theme="light"] .collision,
html[data-theme="light"] .file-block.collision,
html[data-theme="light"] .workflow-file-row.collision {
  border-color: var(--comet-warning) !important;
  background: var(--comet-warning-soft) !important;
}

html[data-theme="light"] #reset-modal,
html[data-theme="light"] .modal-backdrop,
html[data-theme="light"] .custom-template-modal,
html[data-theme="light"] .template-apply-modal {
  background: rgba(15, 23, 42, 0.36) !important;
}

html[data-theme="light"] .btn,
html[data-theme="light"] .btn-primary {
  box-shadow: none;
}

html[data-theme="light"] .btn-danger {
  background: #dc2626 !important;
  border-color: #b91c1c !important;
  color: #ffffff !important;
}

html[data-theme="light"] .btn-success {
  background: #15803d !important;
  border-color: #166534 !important;
  color: #ffffff !important;
}

/* Wizard light-theme completion pass: Step 2 through Step 5 include many
   inline/default dark controls in app.html, so these overrides keep the whole
   flow on the light palette. */
html[data-theme="light"] #step2 .box,
html[data-theme="light"] #step3 .box,
html[data-theme="light"] #step4 .box,
html[data-theme="light"] #step5 .box,
html[data-theme="light"] #workflow-fyi,
html[data-theme="light"] #form-setup4,
html[data-theme="light"] #setup4-fields,
html[data-theme="light"] #secrets-summary,
html[data-theme="light"] #confirm-gh-status,
html[data-theme="light"] #confirm-gl-status,
html[data-theme="light"] #confirm-secrets,
html[data-theme="light"] #finish-logs,
html[data-theme="light"] .workflow-all-files-panel,
html[data-theme="light"] .workflow-folder-node,
html[data-theme="light"] .workflow-all-files-item,
html[data-theme="light"] .file-block,
html[data-theme="light"] .at-file,
html[data-theme="light"] .custom-template-card {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: 0 1px 8px var(--comet-shadow);
}

html[data-theme="light"] #step2 [style*="background:#0b1220"],
html[data-theme="light"] #step2 [style*="background: #0b1220"],
html[data-theme="light"] #step2 [style*="background:#111827"],
html[data-theme="light"] #step2 [style*="background: #111827"],
html[data-theme="light"] #step2 [style*="background:#0a0f1e"],
html[data-theme="light"] #step2 [style*="background: #0a0f1e"],
html[data-theme="light"] #step3 [style*="background:#0b1220"],
html[data-theme="light"] #step3 [style*="background: #0b1220"],
html[data-theme="light"] #step3 [style*="background:#111827"],
html[data-theme="light"] #step3 [style*="background: #111827"],
html[data-theme="light"] #step3 [style*="background:#0a0f1e"],
html[data-theme="light"] #step3 [style*="background: #0a0f1e"],
html[data-theme="light"] #step4 [style*="background:#0b1220"],
html[data-theme="light"] #step4 [style*="background: #0b1220"],
html[data-theme="light"] #step4 [style*="background:#111827"],
html[data-theme="light"] #step4 [style*="background: #111827"],
html[data-theme="light"] #step4 [style*="background:#0a0f1e"],
html[data-theme="light"] #step4 [style*="background: #0a0f1e"],
html[data-theme="light"] #step5 [style*="background:#0b1220"],
html[data-theme="light"] #step5 [style*="background: #0b1220"],
html[data-theme="light"] #step5 [style*="background:#111827"],
html[data-theme="light"] #step5 [style*="background: #111827"],
html[data-theme="light"] #step5 [style*="background:#0a0f1e"],
html[data-theme="light"] #step5 [style*="background: #0a0f1e"],
html[data-theme="light"] #dir-modal [style*="background:#0b1220"],
html[data-theme="light"] #dir-modal [style*="background: #0b1220"] {
  background: var(--comet-input-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] #step2 [style*="color:#94a3b8"],
html[data-theme="light"] #step2 [style*="color: #94a3b8"],
html[data-theme="light"] #step3 [style*="color:#94a3b8"],
html[data-theme="light"] #step3 [style*="color: #94a3b8"],
html[data-theme="light"] #step4 [style*="color:#94a3b8"],
html[data-theme="light"] #step4 [style*="color: #94a3b8"],
html[data-theme="light"] #step5 [style*="color:#94a3b8"],
html[data-theme="light"] #step5 [style*="color: #94a3b8"] {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] #step2 .tile {
  background: linear-gradient(180deg, #ffffff, #f4f9ff) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: none !important;
}

html[data-theme="light"] #step2 .tile.selected {
  background: linear-gradient(180deg, #e8f4ff, #dbeafe) !important;
  border-color: var(--comet-accent) !important;
  box-shadow: inset 0 0 0 2px rgba(14, 116, 191, 0.18) !important;
}

html[data-theme="light"] #step2 .tile.coming-soon::after {
  background: #fff7e6 !important;
  border-color: #d8bd7f !important;
  color: #8a5204 !important;
}

html[data-theme="light"] #step2 .tile .icon svg,
html[data-theme="light"] #step2 .tile .name,
html[data-theme="light"] #step3 .tile .icon svg,
html[data-theme="light"] #step3 .tile .name {
  color: var(--comet-link) !important;
}

html[data-theme="light"] #step2 .tile .desc,
html[data-theme="light"] #step3 .tile .desc,
html[data-theme="light"] #repo-selected,
html[data-theme="light"] #repo-full-name,
html[data-theme="light"] #setup4-status,
html[data-theme="light"] #finish-action,
html[data-theme="light"] #finish-subtitle {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] #step3 input[readonly],
html[data-theme="light"] #step3 input[type="text"],
html[data-theme="light"] #step3 input[type="password"],
html[data-theme="light"] #step3 select,
html[data-theme="light"] #step3 textarea,
html[data-theme="light"] .secret-edit-wrap input,
html[data-theme="light"] .secret-static-value,
html[data-theme="light"] #harbor-cli-secret-existing,
html[data-theme="light"] #dir-filter,
html[data-theme="light"] #dir-tree {
  background: var(--comet-input-bg) !important;
  color: var(--comet-text-strong) !important;
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] .secret-edit-toggle,
html[data-theme="light"] #dir-close,
html[data-theme="light"] .pw-toggle {
  color: var(--comet-muted-strong) !important;
}

html[data-theme="light"] .secret-edit-toggle:hover,
html[data-theme="light"] #dir-close:hover,
html[data-theme="light"] .pw-toggle:hover {
  background: var(--comet-panel-bg-elevated) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .help-tip,
html[data-theme="light"] .help-tip.file-tip {
  background: var(--comet-panel-bg-elevated) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .help-tip .tip,
html[data-theme="light"] .workflow-floating-tip.help {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: 0 12px 28px var(--comet-shadow);
}

html[data-theme="light"] #dir-modal {
  background: rgba(15, 23, 42, 0.42) !important;
}

html[data-theme="light"] #dir-modal > div {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: 0 20px 42px rgba(15, 23, 42, 0.22);
}

html[data-theme="light"] #dir-browser,
html[data-theme="light"] #dir-tree {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
}

html[data-theme="light"] #dir-tree svg,
html[data-theme="light"] .workflow-folder-icon {
  color: #b77a04 !important;
}

html[data-theme="light"] .template-ai-trigger,
html[data-theme="light"] .template-filter-trigger,
html[data-theme="light"] .template-apply-trigger,
html[data-theme="light"] .template-popup-back,
html[data-theme="light"] .workflow-overview-dir-btn,
html[data-theme="light"] .workflow-fyi-resize-toggle {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
  box-shadow: none !important;
}

html[data-theme="light"] .template-ai-trigger:hover,
html[data-theme="light"] .template-filter-trigger:hover,
html[data-theme="light"] .template-apply-trigger:hover,
html[data-theme="light"] .workflow-overview-dir-btn:hover,
html[data-theme="light"] .workflow-fyi-resize-toggle:hover {
  background: var(--comet-panel-bg-elevated) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .template-ai-popover,
html[data-theme="light"] .template-apply-popover,
html[data-theme="light"] .template-ai-trigger-tip,
html[data-theme="light"] .custom-ai-panel,
html[data-theme="light"] .custom-template-empty {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: 0 16px 30px var(--comet-shadow);
}

html[data-theme="light"] .template-apply-tabs,
html[data-theme="light"] .template-ai-multiselect,
html[data-theme="light"] .template-ai-field select,
html[data-theme="light"] .custom-ai-field input,
html[data-theme="light"] .custom-ai-field select,
html[data-theme="light"] .custom-template-card select {
  background: var(--comet-input-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .template-apply-title,
html[data-theme="light"] .template-ai-popover-title,
html[data-theme="light"] .custom-template-card h4,
html[data-theme="light"] .template-ai-trigger-tip strong,
html[data-theme="light"] .custom-ai-panel > summary,
html[data-theme="light"] .custom-ai-field label,
html[data-theme="light"] .template-ai-multiselect > summary,
html[data-theme="light"] .template-ai-feature-controls,
html[data-theme="light"] .template-ai-feature-controls label,
html[data-theme="light"] .template-ai-feature-list label {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .template-apply-tab {
  background: transparent !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-muted-strong) !important;
}

html[data-theme="light"] .template-apply-tab.active {
  background: var(--comet-success-soft) !important;
  color: var(--comet-success) !important;
}

html[data-theme="light"] .template-ai-status,
html[data-theme="light"] .template-ai-note,
html[data-theme="light"] .custom-ai-note,
html[data-theme="light"] .custom-ai-summary,
html[data-theme="light"] .workflow-all-files-summary,
html[data-theme="light"] .workflow-all-files-note,
html[data-theme="light"] .workflow-folder-count,
html[data-theme="light"] .secret-edit-note {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] .workflow-all-files-controls select,
html[data-theme="light"] .workflow-overview-stat {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .workflow-overview-stat .value {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .workflow-overview-stat .label {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] .workflow-overview-stat.updated,
html[data-theme="light"] .workflow-all-files-badge.updated {
  background: var(--comet-accent-soft) !important;
  border-color: rgba(14, 116, 191, 0.32) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .workflow-overview-stat.new,
html[data-theme="light"] .workflow-all-files-badge.new {
  background: var(--comet-success-soft) !important;
  border-color: rgba(18, 133, 61, 0.38) !important;
  color: var(--comet-success) !important;
}

html[data-theme="light"] .workflow-overview-stat.collision,
html[data-theme="light"] .workflow-all-files-badge.collision {
  background: var(--comet-warning-soft) !important;
  border-color: rgba(168, 100, 5, 0.4) !important;
  color: var(--comet-warning) !important;
}

html[data-theme="light"] .template-new-tip {
  background: #dcfce7 !important;
  border: 1px solid #15803d !important;
  color: #166534 !important;
}

html[data-theme="light"] .template-new-tip svg,
html[data-theme="light"] .template-new-tip svg * {
  stroke: #166534 !important;
}

html[data-theme="light"] .template-new-tip .tip,
html[data-theme="light"] .workflow-floating-tip.new {
  background: #f0fdf4 !important;
  border-color: #15803d !important;
  color: #14532d !important;
}

html[data-theme="light"] .collision-tip {
  background: #fffbeb !important;
  border: 1px solid #a86405 !important;
  color: #7a4700 !important;
}

html[data-theme="light"] .collision-tip svg,
html[data-theme="light"] .collision-tip svg * {
  stroke: #7a4700 !important;
}

html[data-theme="light"] .collision-tip .tip,
html[data-theme="light"] .workflow-floating-tip.collision {
  background: #fffbeb !important;
  border-color: #a86405 !important;
  color: #7a4700 !important;
}

html[data-theme="light"] #repos option.repo-placeholder-option {
  color: var(--comet-link) !important;
  font-weight: 700 !important;
}

html[data-theme="light"] .workflow-all-files-badge.existing {
  background: #eef2f7 !important;
  border-color: var(--comet-border-soft) !important;
  color: var(--comet-muted-strong) !important;
}

html[data-theme="light"] .workflow-overview-stat.collision .value {
  color: var(--comet-warning) !important;
}

html[data-theme="light"] .workflow-all-files-item .path,
html[data-theme="light"] .workflow-all-files-title,
html[data-theme="light"] .file-name,
html[data-theme="light"] .at-file-hdr,
html[data-theme="light"] .at-fname,
html[data-theme="light"] .workflow-folder-node summary {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] #workflow-fyi details.file-block > summary,
html[data-theme="light"] .workflow-file-tree-root .file-block summary,
html[data-theme="light"] .workflow-folder-node > summary {
  background: linear-gradient(180deg, #edf7ff, #dbeafe) !important;
  border: 1px solid #b8d6f5 !important;
  color: #0b4f8a !important;
  border-radius: 7px !important;
}

html[data-theme="light"] #workflow-fyi details.file-block > summary,
html[data-theme="light"] .workflow-file-tree-root .file-block summary,
html[data-theme="light"] .workflow-folder-node > summary {
  padding: 4px 7px !important;
  margin-bottom: 7px !important;
}

html[data-theme="light"] .workflow-folder-node {
  background: linear-gradient(180deg, #ffffff, #f3f9ff) !important;
}

html[data-theme="light"] .workflow-fyi-viewport,
html[data-theme="light"] .workflow-all-files-list,
html[data-theme="light"] .collision-code-scroll,
html[data-theme="light"] #autotest-file-list {
  scrollbar-color: #9fb0c4 transparent !important;
}

html[data-theme="light"] .workflow-fyi-viewport::-webkit-scrollbar-thumb,
html[data-theme="light"] .workflow-all-files-list::-webkit-scrollbar-thumb,
html[data-theme="light"] .collision-code-scroll::-webkit-scrollbar-thumb,
html[data-theme="light"] #autotest-file-list::-webkit-scrollbar-thumb {
  background: #9fb0c4 !important;
}

html[data-theme="light"] .file-block pre,
html[data-theme="light"] #confirm-files pre,
html[data-theme="light"] #finish-logs pre,
html[data-theme="light"] .at-file-body pre {
  background: var(--comet-code-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-code-text) !important;
}

html[data-theme="light"] pre code,
html[data-theme="light"] .file-block pre code,
html[data-theme="light"] .file-block .code-lang-yaml,
html[data-theme="light"] .file-block .code-lang-py,
html[data-theme="light"] .file-block .code-lang-docker,
html[data-theme="light"] .file-block .code-lang-ignore,
html[data-theme="light"] .file-block .code-lang-md,
html[data-theme="light"] .file-block .code-lang-generic,
html[data-theme="light"] .collision-code-rows,
html[data-theme="light"] .collision-code-text {
  background: transparent !important;
  color: var(--comet-code-text) !important;
}

html[data-theme="light"] .code-line-gutter,
html[data-theme="light"] .collision-code-gutter {
  background: #dbe7f3 !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-muted) !important;
}

html[data-theme="light"] .tok-key,
html[data-theme="light"] .tok-func,
html[data-theme="light"] .tok-br-0 {
  color: #075ca8 !important;
}

html[data-theme="light"] .tok-str,
html[data-theme="light"] .tok-num,
html[data-theme="light"] .tok-op,
html[data-theme="light"] .tok-br-4 {
  color: #9a5b00 !important;
}

html[data-theme="light"] .tok-comment {
  color: #64748b !important;
}

html[data-theme="light"] .tok-kw,
html[data-theme="light"] .tok-bool,
html[data-theme="light"] .tok-var,
html[data-theme="light"] .tok-prop,
html[data-theme="light"] .tok-deco,
html[data-theme="light"] .tok-br-1,
html[data-theme="light"] .tok-br-2,
html[data-theme="light"] .tok-br-3,
html[data-theme="light"] .tok-br-5 {
  color: #0f766e !important;
}

html[data-theme="light"] .collision-merge-shell,
html[data-theme="light"] .collision-code-pane {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text) !important;
  box-shadow: 0 12px 24px var(--comet-shadow);
}

html[data-theme="light"] .collision-merge-topbar,
html[data-theme="light"] .collision-merge-subbar,
html[data-theme="light"] .collision-code-pane-header,
html[data-theme="light"] .collision-merge-loading,
html[data-theme="light"] .collision-merge-error {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .collision-code-line.added {
  background: rgba(18, 133, 61, 0.12) !important;
}

html[data-theme="light"] .collision-code-line.removed {
  background: rgba(192, 38, 45, 0.10) !important;
}

html[data-theme="light"] .collision-merge-status,
html[data-theme="light"] .collision-merge-transfer-head {
  color: var(--comet-muted) !important;
}

html[data-theme="light"] .collision-merge-btn,
html[data-theme="light"] .collision-merge-btn.bulk,
html[data-theme="light"] .collision-change-arrow,
html[data-theme="light"] .collision-diff-arrow,
html[data-theme="light"] .collision-merge-tab {
  background: var(--comet-panel-bg-soft) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .collision-merge-btn:hover,
html[data-theme="light"] .collision-change-arrow:hover,
html[data-theme="light"] .collision-diff-arrow:hover,
html[data-theme="light"] .collision-merge-tab:hover {
  background: var(--comet-panel-bg-elevated) !important;
  border-color: var(--comet-accent) !important;
  color: var(--comet-link) !important;
}

html[data-theme="light"] .collision-merge-btn.active,
html[data-theme="light"] .collision-merge-tab.selected {
  background: var(--comet-success-soft) !important;
  border-color: var(--comet-success) !important;
  color: var(--comet-success) !important;
}

html[data-theme="light"] #autotest-progress-bar {
  background: #dbe7f3 !important;
}

html[data-theme="light"] #autotest-progress-projection {
  background: linear-gradient(90deg, rgba(14, 116, 191, 0.20), rgba(15, 118, 110, 0.24)) !important;
}

html[data-theme="light"] .setup4-linear-progress {
  background: #dbeafe !important;
  border-color: #b8d6f5 !important;
  box-shadow: inset 0 1px 3px rgba(15, 23, 42, 0.12) !important;
}

html[data-theme="light"] .finish-error-summary summary {
  color: #991b1b !important;
}

html[data-theme="light"] .finish-error-summary pre {
  background: #fff7f7 !important;
  color: #7f1d1d !important;
  border-color: #fecaca !important;
}

html[data-theme="light"] #autotest-coverage {
  background: linear-gradient(90deg, #12853d 0 var(--coverage-pct), #dbe7f3 var(--coverage-pct) 100%) !important;
}

html[data-theme="light"] .modal-card,
html[data-theme="light"] .modal-card input,
html[data-theme="light"] #harbor-repo-modal input[readonly] {
  background: var(--comet-panel-bg) !important;
  border-color: var(--comet-border) !important;
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] .modal-card h4,
html[data-theme="light"] .modal-card h3 {
  color: var(--comet-text-strong) !important;
}

html[data-theme="light"] #confirm-remote,
html[data-theme="light"] #finish-remote-dir,
html[data-theme="light"] #confirm-secrets code,
html[data-theme="light"] #secrets-list code {
  background: #eef6ff !important;
  color: var(--comet-text-strong) !important;
  border: 1px solid var(--comet-border-soft) !important;
}

html[data-theme="light"] .status-dot.status-up {
  background: #22c55e !important;
}

@media (max-width: 760px) {
  .theme-switch {
    align-self: center;
  }

  .theme-button {
    width: 34px;
    height: 34px;
  }
}
