/* Egonex Website - Theme System */
/* Sistema colori e temi personalizzabili */

/* Light Theme (Default) */
:root {
    /* Light theme colors */
    --theme-bg-primary: #ffffff;
    --theme-bg-secondary: #f9fafb;
    --theme-bg-tertiary: #f3f4f6;
    
    --theme-text-primary: #1a1a1a;
    --theme-text-secondary: #6b7280;
    --theme-text-tertiary: #9ca3af;
    
    --theme-border-primary: #e5e7eb;
    --theme-border-secondary: #d1d5db;
    
    --theme-shadow-primary: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --theme-shadow-secondary: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --theme-shadow-tertiary: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}


/* High Contrast Theme */
[data-theme="high-contrast"] {
    --theme-bg-primary: #ffffff;
    --theme-bg-secondary: #f0f0f0;
    --theme-bg-tertiary: #e0e0e0;
    
    --theme-text-primary: #000000;
    --theme-text-secondary: #333333;
    --theme-text-tertiary: #666666;
    
    --theme-border-primary: #000000;
    --theme-border-secondary: #333333;
    
    --theme-shadow-primary: 0 1px 2px 0 rgba(0, 0, 0, 0.2);
    --theme-shadow-secondary: 0 4px 6px -1px rgba(0, 0, 0, 0.3);
    --theme-shadow-tertiary: 0 10px 15px -3px rgba(0, 0, 0, 0.4);
}

/* Theme-aware components */
.theme-bg-primary {
    background-color: var(--theme-bg-primary);
}

.theme-bg-secondary {
    background-color: var(--theme-bg-secondary);
}

.theme-bg-tertiary {
    background-color: var(--theme-bg-tertiary);
}

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

.theme-text-secondary {
    color: var(--theme-text-secondary);
}

.theme-text-tertiary {
    color: var(--theme-text-tertiary);
}

.theme-border-primary {
    border-color: var(--theme-border-primary);
}

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

.theme-shadow-primary {
    box-shadow: var(--theme-shadow-primary);
}

.theme-shadow-secondary {
    box-shadow: var(--theme-shadow-secondary);
}

.theme-shadow-tertiary {
    box-shadow: var(--theme-shadow-tertiary);
}

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


/* Theme-aware cards */
.theme-card {
    background-color: var(--theme-bg-primary);
    border: 1px solid var(--theme-border-primary);
    border-radius: 8px;
    padding: var(--spacing-xl);
    box-shadow: var(--theme-shadow-secondary);
    transition: all 0.3s ease;
}

.theme-card:hover {
    box-shadow: var(--theme-shadow-tertiary);
    transform: translateY(-2px);
}

.theme-card h3 {
    color: var(--theme-text-primary);
}

.theme-card p {
    color: var(--theme-text-secondary);
}

/* Theme-aware forms */
.theme-form input,
.theme-form textarea,
.theme-form select {
    background-color: var(--theme-bg-primary);
    border: 2px solid var(--theme-border-primary);
    color: var(--theme-text-primary);
}

.theme-form input:focus,
.theme-form textarea:focus,
.theme-form select:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(68, 114, 196, 0.1);
}

.theme-form label {
    color: var(--theme-text-primary);
}

/* Theme-aware navigation */
.theme-nav {
    background-color: var(--theme-bg-primary);
    border-bottom: 1px solid var(--theme-border-primary);
    box-shadow: var(--theme-shadow-primary);
}

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

.theme-nav a:hover {
    color: var(--primary-blue);
}

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

.theme-footer h4 {
    color: var(--theme-text-primary);
}

.theme-footer a {
    color: var(--theme-text-secondary);
}

.theme-footer a:hover {
    color: var(--egonex-orange);
}

/* Theme-aware sections */
.theme-section-light {
    background-color: var(--theme-bg-secondary);
}


/* Theme-aware buttons */
.theme-btn-primary {
    background-color: var(--primary-blue);
    color: var(--bg-white);
    border: 2px solid var(--primary-blue);
}

.theme-btn-primary:hover {
    background-color: #3a5fb8;
    border-color: #3a5fb8;
}

.theme-btn-secondary {
    background-color: var(--egonex-orange);
    color: var(--bg-white);
    border: 2px solid var(--egonex-orange);
}

.theme-btn-secondary:hover {
    background-color: #d97706;
    border-color: #d97706;
}

.theme-btn-outline {
    background-color: transparent;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
}

.theme-btn-outline:hover {
    background-color: var(--primary-blue);
    color: var(--bg-white);
}

/* Theme-aware stats */
.theme-stat {
    background-color: var(--theme-bg-primary);
    border: 1px solid var(--theme-border-primary);
    box-shadow: var(--theme-shadow-primary);
}

.theme-stat-number {
    color: var(--primary-blue);
}

.theme-stat-label {
    color: var(--theme-text-secondary);
}

/* Theme-aware timeline - REMOVED: Replaced with horizontal roadmap module */

/* Theme-aware cookie banner */
.theme-cookie-banner {
    background-color: var(--theme-bg-primary);
    border-top: 1px solid var(--theme-border-primary);
    box-shadow: var(--theme-shadow-tertiary);
}

.theme-cookie-banner h4 {
    color: var(--theme-text-primary);
}

.theme-cookie-banner p {
    color: var(--theme-text-secondary);
}

/* Theme-aware language switcher */
.theme-language-switcher button {
    background-color: transparent;
    border: 2px solid var(--primary-blue);
    color: var(--primary-blue);
}

.theme-language-switcher button.active {
    background-color: var(--primary-blue);
    color: var(--bg-white);
}

.theme-language-switcher button:hover {
    background-color: var(--primary-blue);
    color: var(--bg-white);
}

/* Theme-aware mobile menu */
.theme-mobile-menu {
    background-color: var(--theme-bg-primary);
    box-shadow: var(--theme-shadow-tertiary);
}

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

.theme-mobile-menu a:hover {
    background-color: var(--theme-bg-secondary);
    color: var(--primary-blue);
}

/* Theme-aware mobile nav */
.theme-mobile-nav {
    background-color: var(--theme-bg-primary);
    box-shadow: var(--theme-shadow-secondary);
}

.theme-mobile-nav .mobile-menu-toggle span {
    background-color: var(--theme-text-primary);
}

/* Theme-aware hero section */
.theme-hero {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--egonex-orange) 100%);
    color: var(--bg-white);
}

.theme-hero h1,
.theme-hero h2,
.theme-hero h3,
.theme-hero h4,
.theme-hero h5,
.theme-hero h6 {
    color: var(--bg-white);
}

.theme-hero p {
    color: var(--bg-white);
    opacity: 0.9;
}

/* Theme-aware social links */
.theme-social-links a {
    color: var(--theme-text-secondary);
}

.theme-social-links a:hover {
    color: var(--egonex-orange);
}

/* Theme-aware form validation */
.theme-form .error {
    border-color: #ef4444;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.theme-form .error-message {
    color: #ef4444;
    font-size: var(--font-size-sm);
    margin-top: var(--spacing-xs);
}

.theme-form .success {
    border-color: var(--success-green);
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.1);
}

.theme-form .success-message {
    color: var(--success-green);
    font-size: var(--font-size-sm);
    margin-top: var(--spacing-xs);
}

/* Theme-aware loading states */
.theme-loading {
    opacity: 0.6;
    pointer-events: none;
}

.theme-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--theme-border-primary);
    border-top: 2px solid var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Theme-aware tooltips */
.theme-tooltip {
    position: relative;
    display: inline-block;
}

.theme-tooltip .tooltip-text {
    visibility: hidden;
    width: 200px;
    background-color: var(--theme-bg-tertiary);
    color: var(--theme-text-primary);
    text-align: center;
    border-radius: 6px;
    padding: var(--spacing-sm);
    position: absolute;
    z-index: 1;
    bottom: 125%;
    left: 50%;
    margin-left: -100px;
    opacity: 0;
    transition: opacity 0.3s;
    box-shadow: var(--theme-shadow-secondary);
    border: 1px solid var(--theme-border-primary);
}

.theme-tooltip .tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: var(--theme-bg-tertiary) transparent transparent transparent;
}

.theme-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Theme-aware progress bars */
.theme-progress {
    width: 100%;
    height: 8px;
    background-color: var(--theme-bg-tertiary);
    border-radius: 4px;
    overflow: hidden;
}

.theme-progress-bar {
    height: 100%;
    background-color: var(--primary-blue);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.theme-progress-bar.success {
    background-color: var(--success-green);
}

.theme-progress-bar.warning {
    background-color: var(--egonex-orange);
}

.theme-progress-bar.error {
    background-color: #ef4444;
}
