/* Public pages (landing, auth, support) dark mode */

html[data-theme="dark"] {
    --primary-light: rgba(26, 107, 60, 0.18);
    --primary-subtle: rgba(26, 107, 60, 0.28);
    --accent: #E8B84B;
    --accent-dark: #F0C040;
    --accent-light: rgba(232, 184, 75, 0.15);
    --accent-subtle: rgba(232, 184, 75, 0.28);
    --border: var(--dm-border);
    --bg-soft: var(--dm-bg);
    --white: var(--dm-surface);
    --dark: var(--dm-text);
    --muted: var(--dm-text-secondary);
}

html[data-theme="dark"],
html[data-theme="dark"] body {
    background: var(--dm-bg) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] body::before {
    opacity: 0 !important;
    filter: none !important;
}

html[data-theme="dark"] body::after {
    opacity: 0 !important;
    filter: none !important;
}

/* Login / register / auth — keep light-mode hero background in dark mode */
html[data-theme="dark"] body:has(.login-shell),
html[data-theme="dark"] body:has(.register-shell),
html[data-theme="dark"] body:has(.forgot-shell),
html[data-theme="dark"] body:has(.reset-shell) {
    background: transparent !important;
}

html[data-theme="dark"] body:has(.login-shell)::before,
html[data-theme="dark"] body:has(.register-shell)::before,
html[data-theme="dark"] body:has(.forgot-shell)::before,
html[data-theme="dark"] body:has(.reset-shell)::before {
    opacity: 1 !important;
    filter: blur(8px) !important;
}

html[data-theme="dark"] body:has(.login-shell)::after,
html[data-theme="dark"] body:has(.register-shell)::after,
html[data-theme="dark"] body:has(.forgot-shell)::after,
html[data-theme="dark"] body:has(.reset-shell)::after {
    opacity: 1 !important;
}

/* Theme toggle */
.public-theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    padding: 0;
    border: 1.5px solid var(--primary, #1a6b3c);
    border-radius: 8px;
    background: transparent;
    color: var(--primary, #1a6b3c);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
    flex-shrink: 0;
}

.public-theme-toggle:hover {
    background: var(--primary, #1a6b3c);
    color: #fff;
}

.public-theme-toggle .theme-icon-light {
    display: none;
}

html[data-theme="dark"] .public-theme-toggle {
    border-color: var(--dm-border);
    color: var(--dm-text);
    background: var(--dm-surface-raised);
}

html[data-theme="dark"] .public-theme-toggle:hover {
    background: var(--dm-surface);
    border-color: #4ade80;
    color: #4ade80;
}

html[data-theme="dark"] .public-theme-toggle .theme-icon-dark {
    display: none;
}

html[data-theme="dark"] .public-theme-toggle .theme-icon-light {
    display: inline-block;
}

/* Landing navbar */
html[data-theme="dark"] .landing-nav {
    background: rgba(28, 28, 30, 0.98) !important;
    border-bottom-color: transparent !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

html[data-theme="dark"] .landing-nav.scrolled {
    background: rgba(28, 28, 30, 0.98) !important;
    border-bottom-color: var(--dm-border) !important;
    box-shadow: 0 1px 8px rgba(0, 0, 0, 0.35) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

html[data-theme="dark"] .landing-nav .nav-brand {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .landing-nav .nav-brand strong {
    color: var(--dm-primary) !important;
}

html[data-theme="dark"] .landing-nav .nav-brand em {
    color: #F0C040 !important;
}

html[data-theme="dark"] .landing-nav .btn-outline {
    border-color: #4ade80 !important;
    color: #4ade80 !important;
    background: transparent !important;
}

html[data-theme="dark"] .landing-nav .btn-outline:hover {
    background: #4ade80 !important;
    color: #1c1c1e !important;
}

html[data-theme="dark"] .landing-nav .btn-primary {
    background: var(--dm-primary) !important;
    color: #fff !important;
}

html[data-theme="dark"] .landing-nav .btn-primary:hover {
    background: var(--dm-primary-hover) !important;
}

/* Login / auth cards */
html[data-theme="dark"] .login-card,
html[data-theme="dark"] .register-shell .card,
html[data-theme="dark"] .forgot-shell .card,
html[data-theme="dark"] .card:not(.service-card):not(.process-card):not(.contact-card):not(.why-item):not(.accordion-item) {
    background: var(--dm-surface) !important;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35) !important;
}

html[data-theme="dark"] .card-img {
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .brand .login-title,
html[data-theme="dark"] .login-title {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .brand .sub,
html[data-theme="dark"] .sub {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .brand .sub strong,
html[data-theme="dark"] .sub strong {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .invalid-feedback,
html[data-theme="dark"] .invalid-feedback.show {
    color: #fca5a5 !important;
}

html[data-theme="dark"] .form-group label,
html[data-theme="dark"] .contact-form label {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .form-control,
html[data-theme="dark"] .register-shell .form-control,
html[data-theme="dark"] .register-shell .custom-dropdown-trigger,
html[data-theme="dark"] .contact-form .form-control,
html[data-theme="dark"] .contact-form .custom-dropdown-trigger {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .form-control:focus,
html[data-theme="dark"] .register-shell .form-control:focus,
html[data-theme="dark"] .register-shell .custom-dropdown-trigger.open,
html[data-theme="dark"] .register-shell .custom-dropdown-trigger-input:focus,
html[data-theme="dark"] .contact-form .form-control:focus,
html[data-theme="dark"] .contact-form .custom-dropdown-trigger.open {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-primary) !important;
}

/* Register custom date field (visible text is .custom-date-display overlay) */
html[data-theme="dark"] .register-shell .account-date-input,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input {
    color-scheme: dark;
}

html[data-theme="dark"] .register-shell .account-date-input::-webkit-calendar-picker-indicator,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input::-webkit-calendar-picker-indicator {
    filter: invert(1) brightness(1.4);
    opacity: 0.75;
}

html[data-theme="dark"] .register-shell .account-date-input.is-placeholder,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input.is-placeholder {
    background: var(--dm-bg) !important;
}

html[data-theme="dark"] .register-shell .account-date-input.is-placeholder + .custom-date-display,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input.is-placeholder + .custom-date-display {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .account-date-input:not(.is-placeholder),
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input:not(.is-placeholder) {
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .register-shell .account-date-input:not(.is-placeholder) + .custom-date-display,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input:not(.is-placeholder) + .custom-date-display {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .account-date-input.is-placeholder:hover,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input.is-placeholder:hover {
    border-color: var(--dm-border) !important;
    background: var(--dm-bg) !important;
}

html[data-theme="dark"] .register-shell .account-date-input:not(.is-placeholder):hover,
html[data-theme="dark"] .register-shell .account-date-input:focus,
html[data-theme="dark"] .register-shell .account-date-input:focus-visible,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input:not(.is-placeholder):hover,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input:focus,
html[data-theme="dark"] .ae-doctor-register-shell .account-date-input:focus-visible {
    border-color: var(--dm-primary) !important;
    background: var(--dm-surface-raised) !important;
}

/* Mobile number (+63 prefix) */
html[data-theme="dark"] .mobile-input-prefix {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .mobile-input-wrap .form-control,
html[data-theme="dark"] .mobile-input-wrap .patient-mobile-input {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .mobile-input-wrap:focus-within .mobile-input-prefix,
html[data-theme="dark"] .mobile-input-wrap:has(.form-control:focus) .mobile-input-prefix,
html[data-theme="dark"] .mobile-input-wrap:has(.patient-mobile-input:focus) .mobile-input-prefix {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-primary) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .mobile-input-wrap:focus-within .form-control,
html[data-theme="dark"] .mobile-input-wrap:focus-within .patient-mobile-input,
html[data-theme="dark"] .mobile-input-wrap:has(.form-control:focus) .form-control,
html[data-theme="dark"] .mobile-input-wrap:has(.patient-mobile-input:focus) .patient-mobile-input {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-primary) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .form-control::placeholder {
    color: var(--dm-text-secondary) !important;
    opacity: 0.75;
}

html[data-theme="dark"] .toggle-pw i {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .toggle-pw i:hover {
    color: #4ade80 !important;
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .links {
    border-top-color: var(--dm-border) !important;
}

html[data-theme="dark"] .links a {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .links a:hover {
    color: #4ade80 !important;
}

html[data-theme="dark"] .links .divider {
    color: var(--dm-border) !important;
}

html[data-theme="dark"] .error-msg {
    background: rgba(220, 38, 38, 0.12) !important;
    border-color: rgba(220, 38, 38, 0.35) !important;
    color: #fca5a5 !important;
}

html[data-theme="dark"] .sent-icon {
    background: var(--dm-primary-subtle) !important;
    color: var(--dm-primary) !important;
}

html[data-theme="dark"] .sent-message,
html[data-theme="dark"] .note {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .email-box {
    background: var(--dm-primary-subtle) !important;
    border-color: rgba(26, 107, 60, 0.35) !important;
    color: #86efac !important;
}

/* Register wizard */
html[data-theme="dark"] .step-dot:not(:last-child)::after {
    background: var(--dm-border) !important;
}

html[data-theme="dark"] .step-dot.line-done:not(:last-child)::after {
    background: var(--dm-primary) !important;
}

html[data-theme="dark"] .step-dot .circle {
    background: var(--dm-surface-raised) !important;
    color: var(--dm-text-secondary) !important;
    border: 2px solid var(--dm-border) !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .step-dot .circle.active,
html[data-theme="dark"] .step-dot .circle.done,
html[data-theme="dark"] .ae-doctor-register-shell .step-dot .circle.active,
html[data-theme="dark"] .ae-doctor-register-shell .step-dot .circle.done {
    background: var(--dm-primary) !important;
    border-color: var(--dm-primary) !important;
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(26, 107, 60, 0.4) !important;
}

html[data-theme="dark"] .register-shell .custom-dropdown-list {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4) !important;
}

html[data-theme="dark"] .register-shell .custom-dropdown-option {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .custom-dropdown-option:hover,
html[data-theme="dark"] .register-shell .custom-dropdown-option.selected {
    background: var(--dm-surface-raised) !important;
}

/* Partner clinics multi-select dropdown */
html[data-theme="dark"] .register-shell .clinic-multi-select-hint,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select-hint {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select--dropdown .custom-dropdown-list,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select--dropdown .custom-dropdown-list {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.45) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-empty,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-empty {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item {
    background: transparent !important;
    border: none !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item:hover,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item:hover {
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item input:checked + span,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select--dropdown .clinic-multi-select-menu-item input:checked + span {
    color: #4ade80 !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select-option,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select-option {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .clinic-multi-select-option:hover,
html[data-theme="dark"] .ae-doctor-register-shell .clinic-multi-select-option:hover {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .btn-outline {
    border-color: var(--dm-primary) !important;
    color: var(--dm-primary) !important;
    background: transparent !important;
}

html[data-theme="dark"] .register-shell .btn-outline:hover {
    background: var(--dm-primary) !important;
    color: #fff !important;
}

html[data-theme="dark"] .register-shell .nav-btns .btn-outline,
html[data-theme="dark"] .ae-doctor-register-shell .nav-btns .btn-outline {
    border-color: #fff !important;
    color: #fff !important;
    background: transparent !important;
}

html[data-theme="dark"] .register-shell .nav-btns .btn-outline:hover,
html[data-theme="dark"] .register-shell .nav-btns .btn-outline:focus,
html[data-theme="dark"] .register-shell .nav-btns .btn-outline:active,
html[data-theme="dark"] .ae-doctor-register-shell .nav-btns .btn-outline:hover,
html[data-theme="dark"] .ae-doctor-register-shell .nav-btns .btn-outline:focus,
html[data-theme="dark"] .ae-doctor-register-shell .nav-btns .btn-outline:active {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: #fff !important;
    color: #fff !important;
}

html[data-theme="dark"] .register-shell .pw-requirements,
html[data-theme="dark"] .ae-doctor-register-shell .pw-requirements {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .pw-requirements-title,
html[data-theme="dark"] .ae-doctor-register-shell .pw-requirements-title {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .pw-req-item,
html[data-theme="dark"] .ae-doctor-register-shell .pw-req-item {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .pw-req-item.met,
html[data-theme="dark"] .register-shell .pw-req-item.met i,
html[data-theme="dark"] .ae-doctor-register-shell .pw-req-item.met,
html[data-theme="dark"] .ae-doctor-register-shell .pw-req-item.met i {
    color: #4ade80 !important;
}

/* Register ID upload drop zone + browse popover */
html[data-theme="dark"] .register-shell .drop-zone,
html[data-theme="dark"] .ae-doctor-register-shell .drop-zone {
    background: var(--dm-bg) !important;
    border-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .drop-zone:hover,
html[data-theme="dark"] .register-shell .drop-zone.drag-over,
html[data-theme="dark"] .ae-doctor-register-shell .drop-zone:hover,
html[data-theme="dark"] .ae-doctor-register-shell .drop-zone.drag-over {
    border-color: var(--dm-primary) !important;
    background: var(--dm-primary-subtle) !important;
}

html[data-theme="dark"] .register-shell .drop-zone-content p,
html[data-theme="dark"] .ae-doctor-register-shell .drop-zone-content p {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .drop-zone-content p[style*="font-weight:500"],
html[data-theme="dark"] .ae-doctor-register-shell .drop-zone-content p[style*="font-weight:500"] {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell #discountTypeHint,
html[data-theme="dark"] .ae-doctor-register-shell #discountTypeHint {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .register-shell .file-preview,
html[data-theme="dark"] .ae-doctor-register-shell .file-preview {
    background: var(--dm-primary-subtle) !important;
    border-color: rgba(26, 107, 60, 0.35) !important;
}

html[data-theme="dark"] .register-shell .file-preview #fileName,
html[data-theme="dark"] .register-shell .file-preview span[style*="color:#444"],
html[data-theme="dark"] .ae-doctor-register-shell .file-preview #fileName,
html[data-theme="dark"] .ae-doctor-register-shell .file-preview span[style*="color:#444"] {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .file-preview .remove-file:hover,
html[data-theme="dark"] .ae-doctor-register-shell .file-preview .remove-file:hover {
    background: rgba(220, 38, 38, 0.12) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-modal-overlay::before,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-modal-overlay::before {
    background: var(--dm-surface) !important;
    border-left-color: var(--dm-border) !important;
    border-top-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-modal-overlay.arrow-reverse::before,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-modal-overlay.arrow-reverse::before {
    border-right-color: var(--dm-border) !important;
    border-bottom-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-modal,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-modal {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.45) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-option,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-option {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-option:hover,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-option:hover {
    border-color: var(--dm-primary) !important;
    background: var(--dm-primary-subtle) !important;
}

html[data-theme="dark"] .register-shell .reg-upload-option i,
html[data-theme="dark"] .ae-doctor-register-shell .reg-upload-option i {
    color: #4ade80 !important;
}

html[data-theme="dark"] .register-shell .discount-ocr-status.is-loading,
html[data-theme="dark"] .ae-doctor-register-shell .discount-ocr-status.is-loading {
    background: rgba(59, 130, 246, 0.12) !important;
    border-color: rgba(96, 165, 250, 0.35) !important;
    color: #93c5fd !important;
}

html[data-theme="dark"] .register-shell .discount-ocr-status.is-success,
html[data-theme="dark"] .ae-doctor-register-shell .discount-ocr-status.is-success {
    background: var(--dm-primary-subtle) !important;
    border-color: rgba(26, 107, 60, 0.35) !important;
    color: #86efac !important;
}

html[data-theme="dark"] .register-shell .discount-ocr-status.is-warning,
html[data-theme="dark"] .ae-doctor-register-shell .discount-ocr-status.is-warning {
    background: rgba(245, 158, 11, 0.12) !important;
    border-color: rgba(251, 191, 36, 0.35) !important;
    color: #fcd34d !important;
}

html[data-theme="dark"] .register-shell .discount-ocr-status.is-error,
html[data-theme="dark"] .ae-doctor-register-shell .discount-ocr-status.is-error {
    background: rgba(220, 38, 38, 0.12) !important;
    border-color: rgba(248, 113, 113, 0.35) !important;
    color: #fca5a5 !important;
}

html[data-theme="dark"] #cameraBox {
    background: var(--dm-surface) !important;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.55) !important;
}

html[data-theme="dark"] #cameraBox .cam-header {
    border-bottom-color: var(--dm-border) !important;
}

html[data-theme="dark"] #cameraBox .cam-header h3 {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] #cameraBox .cam-header h3 i {
    color: #4ade80 !important;
}

html[data-theme="dark"] #cameraBox .cam-close {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] #cameraBox .cam-close:hover {
    color: #f87171 !important;
}

html[data-theme="dark"] #cameraBox .cam-body {
    background: var(--dm-surface) !important;
}

html[data-theme="dark"] #cameraBox .retake-btn {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] #cameraBox .retake-btn:hover {
    background: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .terms-modal,
html[data-theme="dark"] .upload-modal {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45) !important;
}

html[data-theme="dark"] .terms-modal-overlay,
html[data-theme="dark"] .upload-modal-overlay {
    background: rgba(0, 0, 0, 0.65) !important;
}

html[data-theme="dark"] .terms-modal-header,
html[data-theme="dark"] .upload-modal-header {
    border-bottom-color: var(--dm-border) !important;
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .terms-modal-header h4,
html[data-theme="dark"] .upload-modal-header h4,
html[data-theme="dark"] .terms-modal-body h4 {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .terms-modal-body,
html[data-theme="dark"] .terms-modal-body p,
html[data-theme="dark"] .terms-modal-body li,
html[data-theme="dark"] .upload-modal-body,
html[data-theme="dark"] .checkbox-inline {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .terms-modal-footer,
html[data-theme="dark"] .upload-modal-footer {
    border-top-color: var(--dm-border) !important;
    background: var(--dm-surface-raised) !important;
}

html[data-theme="dark"] .terms-modal .upload-modal-close {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .terms-modal .upload-modal-close:hover,
html[data-theme="dark"] .terms-modal .upload-modal-close:focus-visible {
    color: #dc2626 !important;
}

html[data-theme="dark"] .register-shell .checkbox-inline input[type="checkbox"]:not(:checked) {
    background-color: var(--dm-surface-raised) !important;
    background-image: none !important;
    border-color: var(--dm-border) !important;
}

html[data-theme="dark"] .register-shell .checkbox-inline input[type="checkbox"]:checked {
    background-color: #eab308 !important;
    border-color: #eab308 !important;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%23ffffff'%3E%3Cpath d='M12.207 4.793a1 1 0 0 1 0 1.414l-5 5a1 1 0 0 1-1.414 0l-2.5-2.5a1 1 0 0 1 1.414-1.414L6.5 9.086l4.293-4.293a1 1 0 0 1 1.414 0z'/%3E%3C/svg%3E") !important;
    background-repeat: no-repeat !important;
    background-position: center !important;
    background-size: 0.72rem 0.72rem !important;
}

html[data-theme="dark"] .terms-modal-body::-webkit-scrollbar-thumb {
    background: var(--dm-border) !important;
}

/* Index page sections */
html[data-theme="dark"] .trust-bar {
    background: var(--dm-surface) !important;
    border-bottom-color: var(--dm-border) !important;
}

html[data-theme="dark"] .trust-bar .trust-item {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .trust-bar .trust-item .icon-wrap {
    background: var(--dm-primary-subtle) !important;
    color: var(--dm-primary) !important;
}

html[data-theme="dark"] .section-title,
html[data-theme="dark"] .service-card h5,
html[data-theme="dark"] .process-card .process-head h5,
html[data-theme="dark"] .why-item h6,
html[data-theme="dark"] .contact-card h6,
html[data-theme="dark"] .check-list li,
html[data-theme="dark"] .business-hours li span:last-child {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .section-title .accent {
    color: #F0C040 !important;
}

html[data-theme="dark"] .section-subtitle,
html[data-theme="dark"] #about p,
html[data-theme="dark"] .service-card p,
html[data-theme="dark"] .process-step p,
html[data-theme="dark"] .why-item p,
html[data-theme="dark"] .contact-card p,
html[data-theme="dark"] .contact-card a,
html[data-theme="dark"] .accordion-body,
html[data-theme="dark"] .business-hours li span:first-child {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .process-step p strong {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .check-list li i {
    color: #F0C040 !important;
}

html[data-theme="dark"] .contact-card a:hover {
    color: #4ade80 !important;
}

html[data-theme="dark"] .service-card .icon,
html[data-theme="dark"] .why-item .icon,
html[data-theme="dark"] .contact-card .icon,
html[data-theme="dark"] .process-card .process-head .badge-icon {
    background: var(--dm-primary-subtle) !important;
    color: #4ade80 !important;
}

html[data-theme="dark"] .bg-soft,
html[data-theme="dark"] .bg-white {
    background-color: var(--dm-bg) !important;
}

html[data-theme="dark"] .service-card,
html[data-theme="dark"] .process-card,
html[data-theme="dark"] .why-item,
html[data-theme="dark"] .contact-card,
html[data-theme="dark"] .accordion-item {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
}

html[data-theme="dark"] .service-card:hover,
html[data-theme="dark"] .why-item:hover,
html[data-theme="dark"] .contact-card:hover {
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.3) !important;
}

html[data-theme="dark"] .process-card {
    border-color: var(--dm-primary) !important;
}

html[data-theme="dark"] .process-card .process-head {
    border-bottom-color: var(--dm-border) !important;
}

html[data-theme="dark"] .process-step:not(:last-child) {
    border-bottom-color: var(--dm-border) !important;
}

html[data-theme="dark"] .accordion-button {
    background: var(--dm-surface) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .accordion-button:hover,
html[data-theme="dark"] .accordion-button:focus {
    background: var(--dm-surface-raised) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .accordion-button:not(.collapsed) {
    background: var(--dm-surface-raised) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .accordion-button .faq-arrow {
    background: var(--dm-surface-raised) !important;
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .accordion-item:has(.accordion-button:not(.collapsed)) {
    border-color: var(--dm-primary) !important;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25) !important;
}

html[data-theme="dark"] .divider {
    background: linear-gradient(90deg, transparent, var(--dm-border), transparent) !important;
}

html[data-theme="dark"] .back-to-top {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35) !important;
}

html[data-theme="dark"] .back-to-top:hover {
    background: var(--dm-primary) !important;
    color: #fff !important;
}

/* Support pages (contact, terms) */
html[data-theme="dark"] .support-page-content {
    background: var(--dm-bg);
}

html[data-theme="dark"] .verification-back-btn {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .verification-back-btn:hover,
html[data-theme="dark"] .verification-back-btn:focus {
    background: var(--dm-surface-raised) !important;
    border-color: var(--dm-border) !important;
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .page-heading h1,
html[data-theme="dark"] .page-heading h2,
html[data-theme="dark"] .support-card h3,
html[data-theme="dark"] .support-card h4,
html[data-theme="dark"] .support-card h5 {
    color: var(--dm-text) !important;
}

html[data-theme="dark"] .page-heading p,
html[data-theme="dark"] .support-card p,
html[data-theme="dark"] .support-card li {
    color: var(--dm-text-secondary) !important;
}

html[data-theme="dark"] .support-card,
html[data-theme="dark"] .contact-panel,
html[data-theme="dark"] .legal-section,
html[data-theme="dark"] .content-card,
html[data-theme="dark"] .contact-page .contact-card {
    background: var(--dm-surface) !important;
    border-color: var(--dm-border) !important;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25) !important;
}

html[data-theme="dark"] .page-heading .badge-label,
html[data-theme="dark"] .contact-page .page-heading .badge-label,
html[data-theme="dark"] .section-accent {
    background: var(--dm-primary-subtle) !important;
    border-color: rgba(26, 107, 60, 0.35) !important;
    color: #86efac !important;
}

html[data-theme="dark"] .alert-success {
    background: var(--dm-primary-subtle) !important;
    border-color: rgba(26, 107, 60, 0.35) !important;
    color: #86efac !important;
}

html[data-theme="dark"] .alert-danger {
    background: rgba(220, 38, 38, 0.12) !important;
    border-color: rgba(220, 38, 38, 0.35) !important;
    color: #fca5a5 !important;
}
