/* =======================================================
   MODERN THEME SYSTEM - Light & Dark Mode
   Professional, Clean, and Beautiful Design
   ======================================================= */

/* ===========================
   CSS VARIABLES - LIGHT MODE (DEFAULT)
   =========================== */
:root {
    /* Primary Green Palette - Enhanced */
    --primary-green: #10b981;
    --primary-green-light: #34d399;
    --primary-green-dark: #059669;
    --primary-green-darker: #047857;
    --green-50: #ecfdf5;
    --green-100: #d1fae5;
    --green-200: #a7f3d0;
    
    /* Accent Colors */
    --accent-blue: #3b82f6;
    --accent-purple: #8b5cf6;
    --accent-orange: #f59e0b;
    
    /* Background Colors - Warmer, More Vibrant */
    --bg-primary: #ffffff;
    --bg-secondary: #f0fdf4;
    --bg-tertiary: #ecfdf5;
    --bg-card: #ffffff;
    --bg-card-hover: #f0fdf4;
    
    /* Text Colors - Better Contrast */
    --text-primary: #0f172a;
    --text-secondary: #334155;
    --text-tertiary: #64748b;
    --text-inverse: #ffffff;
    
    /* Border Colors */
    --border-light: #d1fae5;
    --border-medium: #a7f3d0;
    --border-dark: #6ee7b7;
    
    /* Shadow System - Enhanced */
    --shadow-sm: 0 2px 4px 0 rgba(16, 185, 129, 0.08);
    --shadow-md: 0 4px 8px -1px rgba(16, 185, 129, 0.12), 0 2px 4px -1px rgba(16, 185, 129, 0.08);
    --shadow-lg: 0 12px 24px -3px rgba(16, 185, 129, 0.15), 0 6px 12px -2px rgba(16, 185, 129, 0.1);
    --shadow-xl: 0 24px 48px -5px rgba(16, 185, 129, 0.2), 0 12px 24px -5px rgba(16, 185, 129, 0.15);
    --shadow-green: 0 12px 32px -5px rgba(16, 185, 129, 0.3);
    
    /* Gradient System - More Vibrant */
    --gradient-primary: linear-gradient(135deg, #10b981 0%, #059669 100%);
    --gradient-secondary: linear-gradient(135deg, #34d399 0%, #10b981 100%);
    --gradient-light: linear-gradient(135deg, #ecfdf5 0%, #d1fae5 100%);
    --gradient-hero: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 50%, #d1fae5 100%);
    --gradient-card: linear-gradient(135deg, #ffffff 0%, #f0fdf4 100%);
    --gradient-vibrant: linear-gradient(135deg, #10b981 0%, #3b82f6 100%);
    
    /* Header & Navigation */
    --header-bg: rgba(255, 255, 255, 0.98);
    --header-shadow: 0 2px 8px 0 rgba(16, 185, 129, 0.1);
    --nav-text: #0f172a;
    --nav-hover: #10b981;
    
    /* Footer */
    --footer-bg: #0f172a;
    --footer-text: #cbd5e1;
    --footer-heading: #ffffff;
}

/* ===========================
   DARK MODE VARIABLES
   =========================== */
[data-theme="dark"] {
    /* Primary Green Palette - Brighter for dark mode */
    --primary-green: #34d399;
    --primary-green-light: #6ee7b7;
    --primary-green-dark: #10b981;
    --primary-green-darker: #059669;
    --green-50: #134e4a;
    --green-100: #115e59;
    --green-200: #0f766e;
    
    /* Accent Colors */
    --accent-blue: #60a5fa;
    --accent-purple: #a78bfa;
    --accent-orange: #fbbf24;
    
    /* Background Colors - Richer, More Depth */
    --bg-primary: #0a0f1a;
    --bg-secondary: #111827;
    --bg-tertiary: #1f2937;
    --bg-card: #111827;
    --bg-card-hover: #1f2937;
    
    /* Text Colors */
    --text-primary: #f9fafb;
    --text-secondary: #e5e7eb;
    --text-tertiary: #9ca3af;
    --text-inverse: #0a0f1a;
    
    /* Border Colors - With green tint */
    --border-light: #1f2937;
    --border-medium: #374151;
    --border-dark: #4b5563;
    
    /* Shadow System - With glow effects */
    --shadow-sm: 0 2px 4px 0 rgba(16, 185, 129, 0.1);
    --shadow-md: 0 4px 8px -1px rgba(16, 185, 129, 0.15), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 12px 24px -3px rgba(16, 185, 129, 0.2), 0 6px 12px -2px rgba(0, 0, 0, 0.4);
    --shadow-xl: 0 24px 48px -5px rgba(16, 185, 129, 0.25), 0 12px 24px -5px rgba(0, 0, 0, 0.5);
    --shadow-green: 0 12px 32px -5px rgba(52, 211, 153, 0.4);
    
    /* Gradient System - More vibrant */
    --gradient-primary: linear-gradient(135deg, #34d399 0%, #10b981 100%);
    --gradient-secondary: linear-gradient(135deg, #6ee7b7 0%, #34d399 100%);
    --gradient-light: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    --gradient-hero: linear-gradient(135deg, #0a0f1a 0%, #111827 50%, #1f2937 100%);
    --gradient-card: linear-gradient(135deg, #111827 0%, #1f2937 100%);
    --gradient-vibrant: linear-gradient(135deg, #34d399 0%, #60a5fa 100%);
    
    /* Header & Navigation */
    --header-bg: rgba(10, 15, 26, 0.98);
    --header-shadow: 0 2px 8px 0 rgba(52, 211, 153, 0.15);
    --nav-text: #f9fafb;
    --nav-hover: #34d399;
    
    /* Footer */
    --footer-bg: #030712;
    --footer-text: #e5e7eb;
    --footer-heading: #f9fafb;
}

/* ===========================
   SMOOTH TRANSITIONS
   =========================== */
* {
    transition: background-color 0.3s ease, 
                color 0.3s ease, 
                border-color 0.3s ease,
                box-shadow 0.3s ease;
}

/* ===========================
   BASE STYLES
   =========================== */
body {
    background: var(--bg-primary) !important;
    color: var(--text-primary) !important;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    line-height: 1.6;
}

/* ===========================
   THEME TOGGLE BUTTON
   =========================== */
.theme-toggle {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: var(--gradient-primary);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-green);
    z-index: 9999;
    transition: all 0.3s ease;
}

.theme-toggle:hover {
    transform: scale(1.1) rotate(180deg);
    box-shadow: 0 15px 35px -5px rgba(16, 185, 129, 0.4);
}

.theme-toggle svg {
    width: 28px;
    height: 28px;
    fill: white;
}

.theme-toggle .icon-sun,
[data-theme="dark"] .theme-toggle .icon-moon {
    display: block;
}

.theme-toggle .icon-moon,
[data-theme="dark"] .theme-toggle .icon-sun {
    display: none;
}

/* ===========================
   HEADER & NAVIGATION
   =========================== */
.main-header,
header {
    background: var(--header-bg) !important;
    box-shadow: var(--header-shadow) !important;
    backdrop-filter: blur(10px);
}

.main-menu > ul > li > a,
.nav-link,
.navigation li a {
    color: var(--nav-text) !important;
    font-weight: 500;
    transition: all 0.3s ease;
}

.main-menu > ul > li > a:hover,
.nav-link:hover,
.navigation li a:hover {
    color: var(--nav-hover) !important;
}

.logo img {
    filter: brightness(var(--logo-brightness, 1));
    transition: filter 0.3s ease;
}

[data-theme="dark"] .logo img {
    --logo-brightness: 1.2;
}

/* ===========================
   SECTIONS
   =========================== */
section,
.section {
    background: var(--bg-primary) !important;
    color: var(--text-primary) !important;
}

section:nth-child(even),
.section-alternate {
    background: var(--bg-secondary) !important;
}

/* Hero Sections */
.banner-section,
.hero-section,
.main-slider {
    background: var(--gradient-hero) !important;
    position: relative;
    overflow: hidden;
}

/* ===========================
   CARDS & BOXES
   =========================== */
.card,
.feature-block,
.service-block,
.inner-box,
.news-block,
.pricing-block,
.team-block {
    background: var(--bg-card) !important;
    border: 1px solid var(--border-light) !important;
    border-radius: 16px;
    box-shadow: var(--shadow-md) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
}

.card::before,
.feature-block::before,
.service-block::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-primary);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.card:hover::before,
.feature-block:hover::before,
.service-block:hover::before {
    transform: scaleX(1);
}

.card:hover,
.feature-block:hover,
.service-block:hover,
.inner-box:hover,
.news-block:hover,
.pricing-block:hover,
.team-block:hover {
    background: var(--bg-card-hover) !important;
    box-shadow: var(--shadow-xl) !important;
    transform: translateY(-8px);
    border-color: var(--primary-green) !important;
}

/* Icon Boxes */
.icon-box,
.icon {
    background: var(--gradient-light) !important;
    border-radius: 16px;
    padding: 24px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    box-shadow: var(--shadow-sm);
}

.icon-box::before,
.icon::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 16px;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.icon-box:hover::before,
.icon:hover::before {
    opacity: 1;
}

.icon-box:hover,
.icon:hover {
    background: var(--gradient-primary) !important;
    transform: scale(1.1) rotate(5deg);
    box-shadow: var(--shadow-green);
}

.icon-box i,
.icon i {
    color: var(--primary-green) !important;
    font-size: 36px;
    transition: all 0.4s ease;
}

.icon-box:hover i,
.icon:hover i {
    color: white !important;
    transform: scale(1.1);
}

/* ===========================
   TYPOGRAPHY
   =========================== */
h1, h2, h3, h4, h5, h6,
.heading,
.title {
    color: var(--text-primary) !important;
    font-weight: 700;
    line-height: 1.2;
}

p,
.text,
.description {
    color: var(--text-secondary) !important;
    line-height: 1.7;
}

a {
    color: var(--primary-green) !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

a:hover {
    color: var(--primary-green-light) !important;
}

/* ===========================
   BUTTONS
   =========================== */
.btn,
.button,
button {
    border-radius: 12px;
    padding: 14px 32px;
    font-weight: 600;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.btn-primary,
.theme-btn {
    background: var(--gradient-primary) !important;
    color: white !important;
    box-shadow: var(--shadow-green);
}

.btn-primary::before,
.theme-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:hover::before,
.theme-btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary:hover,
.theme-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 20px 40px -5px rgba(16, 185, 129, 0.5);
}

.btn-outline {
    background: transparent !important;
    border: 2px solid var(--primary-green) !important;
    color: var(--primary-green) !important;
}

.btn-outline:hover {
    background: var(--gradient-primary) !important;
    color: white !important;
    border-color: transparent !important;
    transform: translateY(-3px);
    box-shadow: var(--shadow-green);
}

/* ===========================
   FORMS
   =========================== */
input,
textarea,
select,
.form-control,
.subscribe-form input,
.subscribe-form textarea {
    background: var(--bg-card) !important;
    border: 2px solid var(--border-light) !important;
    color: var(--text-primary) !important;
    border-radius: 12px !important;
    padding: 14px 20px !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    font-size: 15px !important;
    width: 100% !important;
    font-family: inherit !important;
}

input:focus,
textarea:focus,
select:focus,
.form-control:focus,
.subscribe-form input:focus,
.subscribe-form textarea:focus {
    border-color: var(--primary-green) !important;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.15) !important;
    outline: none !important;
    background: var(--bg-primary) !important;
}

input::placeholder,
textarea::placeholder,
.subscribe-form input::placeholder,
.subscribe-form textarea::placeholder {
    color: var(--text-tertiary) !important;
    opacity: 0.7 !important;
}

.subscribe-form .form-group {
    display: flex !important;
    flex-direction: column !important;
    gap: 16px !important;
}

.subscribe-form button[type="submit"],
.theme-btn-two {
    background: var(--gradient-primary) !important;
    color: white !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 16px 32px !important;
    font-weight: 700 !important;
    font-size: 16px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    box-shadow: var(--shadow-green) !important;
    width: 100% !important;
}

.subscribe-form button[type="submit"]:hover,
.theme-btn-two:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 20px 40px -5px rgba(16, 185, 129, 0.5) !important;
}

/* ===========================
   FOOTER
   =========================== */
footer,
.main-footer {
    background: var(--footer-bg) !important;
    color: var(--footer-text) !important;
    border-top: 1px solid var(--border-light);
}

footer h3,
footer h4,
.main-footer h3,
.main-footer h4 {
    color: var(--footer-heading) !important;
}

footer a,
.main-footer a {
    color: var(--footer-text) !important;
}

footer a:hover,
.main-footer a:hover {
    color: var(--primary-green-light) !important;
}

/* ===========================
   UTILITY CLASSES
   =========================== */
.bg-green {
    background: var(--gradient-primary) !important;
}

.text-green {
    color: var(--primary-green) !important;
}

.border-green {
    border-color: var(--primary-green) !important;
}

.shadow-green {
    box-shadow: var(--shadow-green) !important;
}

/* ===========================
   SCROLLBAR STYLING
   =========================== */
::-webkit-scrollbar {
    width: 12px;
}

::-webkit-scrollbar-track {
    background: var(--bg-secondary);
}

::-webkit-scrollbar-thumb {
    background: var(--gradient-primary);
    border-radius: 10px;
    border: 2px solid var(--bg-secondary);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--gradient-secondary);
    border-color: var(--bg-primary);
}

/* ===========================
   ACCENT HIGHLIGHTS
   =========================== */
.accent-glow {
    position: relative;
}

.accent-glow::after {
    content: '';
    position: absolute;
    inset: -20px;
    background: radial-gradient(circle, rgba(16, 185, 129, 0.15) 0%, transparent 70%);
    border-radius: 50%;
    z-index: -1;
    animation: pulse 3s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
        transform: scale(1);
    }
    50% {
        opacity: 1;
        transform: scale(1.1);
    }
}

/* ===========================
   ANIMATIONS
   =========================== */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* ===========================
   RESPONSIVE
   =========================== */
@media (max-width: 768px) {
    .theme-toggle {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
    }
    
    .theme-toggle svg {
        width: 24px;
        height: 24px;
    }
}
