/* Theme Switcher - Color Scheme Variants */
/* Light: Primary on Light (#2f1f4f on #dedede) */
/* Dark: Accent on Primary (#d35b74 on #2f1f4f) */

:root {
    /* Light Theme (Default) */
    --theme-bg-primary: #ffffff;
    --theme-bg-secondary: #f5f5f7;
    --theme-bg-tertiary: #dedede;
    --theme-text-primary: #2f1f4f;
    --theme-text-secondary: #1d1d1f;
    --theme-text-light: #6b6b6b;
    --theme-accent-primary: #d35b74;
    --theme-accent-secondary: #4949e7;
    --theme-border: rgba(0, 0, 0, 0.05);
    --theme-shadow: rgba(0, 0, 0, 0.1);
    --theme-nav-bg: rgba(255, 255, 255, 0.8);
    --theme-button-bg: #2f1f4f;
    --theme-button-text: #ffffff;
    --theme-logo-filter: brightness(0) saturate(100%) invert(12%) sepia(32%) saturate(1677%) hue-rotate(227deg) brightness(90%) contrast(95%);
}

/* Dark Theme */
body.theme-dark {
    --theme-bg-primary: #2f1f4f;
    --theme-bg-secondary: #1a1227;
    --theme-bg-tertiary: #3d2e5f;
    --theme-text-primary: #d35b74;
    --theme-text-secondary: #dedede;
    --theme-text-light: #b0a0c8;
    --theme-accent-primary: #d35b74;
    --theme-accent-secondary: #4949e7;
    --theme-border: rgba(211, 91, 116, 0.2);
    --theme-shadow: rgba(0, 0, 0, 0.3);
    --theme-nav-bg: rgba(47, 31, 79, 0.8);
    --theme-button-bg: #d35b74;
    --theme-button-text: #ffffff;
    --theme-logo-filter: brightness(0) saturate(100%) invert(50%) sepia(32%) saturate(1358%) hue-rotate(306deg) brightness(89%) contrast(85%);
}

/* Theme Transition */
body,
body * {
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

/* Apply Theme Variables to Elements */
body {
    background-color: var(--theme-bg-primary);
    color: var(--theme-text-secondary);
}

/* Navigation Theme */
.minimal-nav {
    background: var(--theme-nav-bg);
    border-bottom: 1px solid var(--theme-border);
}

.nav-menu a {
    color: var(--theme-text-primary);
}

.nav-menu a:hover {
    color: var(--theme-accent-secondary);
}

/* Hero Section Theme */
.hero-minimal {
    background: linear-gradient(180deg, var(--theme-bg-primary) 0%, var(--theme-bg-secondary) 100%);
}

.hero-headline {
    color: var(--theme-text-primary);
}

.hero-subtext {
    color: var(--theme-text-light);
}

/* Feature Section Theme */
.feature-section {
    background: var(--theme-bg-primary);
}

.feature-title {
    color: var(--theme-text-primary);
}

.feature-desc {
    color: var(--theme-text-light);
}

.learn-more {
    color: var(--theme-accent-secondary);
    border-color: var(--theme-accent-secondary);
}

.learn-more:hover,
.learn-more:focus-visible {
    background-color: transparent;
    color: var(--theme-accent-secondary);
    transform: scale(1.03);
}

.learn-more:active {
    transform: scale(1.01);
}

/* Button Theme */
.contact-btn,
.cta-btn {
    background-color: var(--theme-button-bg);
    color: var(--theme-button-text);
    border: none;
}

.contact-btn:hover,
.cta-btn:hover {
    background-color: var(--theme-accent-secondary);
}

/* Footer Theme */
footer {
    background-color: var(--theme-bg-secondary);
    color: var(--theme-text-secondary);
    border-top: 1px solid var(--theme-border);
}

/* Industries Showcase Theme */
.industries-highlight {
    background: linear-gradient(180deg, var(--theme-bg-secondary) 0%, var(--theme-bg-primary) 100%);
}

.industries-title {
    color: var(--theme-text-primary);
}

.industry-badge {
    background: var(--theme-bg-secondary);
    color: var(--theme-text-primary);
    border: 1px solid var(--theme-border);
}

.industry-badge:hover {
    border-color: var(--theme-accent-secondary);
    color: var(--theme-accent-secondary);
}

/* Contact Section Theme */
.contact-minimal {
    background: linear-gradient(135deg, var(--theme-bg-secondary) 0%, var(--theme-bg-primary) 100%);
}

.contact-title {
    color: var(--theme-text-primary);
}

.contact-subtitle {
    color: var(--theme-text-light);
}

/* Theme Switcher Button Styles */
.theme-switcher {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    border: 2px solid var(--theme-accent-secondary);
    border-radius: 50px;
    padding: 0.5rem 1rem;
    cursor: pointer;
    color: var(--theme-text-primary);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    transition: all 0.3s ease;
    margin-left: 1rem;
}

.theme-switcher:hover {
    background-color: var(--theme-accent-secondary);
    color: var(--theme-button-text);
    transform: scale(1.05);
}

.theme-switcher i {
    font-size: 1.1rem;
    transition: transform 0.3s ease;
}

.theme-switcher:hover i {
    transform: rotate(180deg);
}

body.theme-dark .theme-switcher {
    border-color: var(--theme-accent-primary);
}

body.theme-dark .theme-switcher:hover {
    background-color: var(--theme-accent-primary);
}

/* Section Backgrounds */
.feature-visual .visual-container {
    background: transparent;
    border: none;
    box-shadow: none;
    border-radius: 0;
    overflow: visible;
}

.feature-visual .svg-visual {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: transparent;
    border: none;
    box-shadow: none;
}

#data-intelligence-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
    background: transparent;
    border: none;
    box-shadow: none;
}

/* SVG Filter for Theme */
body.theme-dark .svg-visual {
    filter: brightness(1.1) contrast(1.1);
}

body.theme-dark #data-intelligence-image {
    filter: none;
}

/* SVG Main Label Styling */
.svg-visual::part(.main-label) {
    fill: var(--theme-text-primary) !important;
    font-size: 34px;
}

/* Target SVG internal elements via object tag styling */
object.svg-visual {
    filter: none;
    background: transparent;
    border: none;
    box-shadow: none;
}

/* For embedded SVG content in object tags */
@supports (selector(:where(body))) {
    body .svg-visual {
        color: var(--theme-text-primary, #2f1f4f);
    }
    
    body.theme-dark .svg-visual {
        color: var(--theme-text-primary, #d35b74);
    }
}

/* Heading Colors */
h1, h2, h3, h4, h5, h6 {
    color: var(--theme-text-primary);
}

/* Text Colors */
p {
    color: var(--theme-text-secondary);
}

/* Link Colors */
a {
    color: var(--theme-accent-secondary);
}

/* Code and Pre */
code {
    background-color: var(--theme-bg-secondary);
    color: var(--theme-text-primary);
    border: 1px solid var(--theme-border);
}

/* Form Elements */
input, textarea, select {
    background-color: var(--theme-bg-secondary);
    color: var(--theme-text-secondary);
    border: 1px solid var(--theme-border);
}

input:focus, textarea:focus, select:focus {
    border-color: var(--theme-accent-secondary);
    box-shadow: 0 0 0 3px rgba(73, 73, 231, 0.1);
}

/* Responsive */
@media (max-width: 768px) {
    .theme-switcher {
        margin-left: 0.5rem;
        padding: 0.4rem 0.75rem;
        font-size: 0.75rem;
    }

    .theme-switcher i {
        font-size: 0.9rem;
    }
}
