:root {
    /* Light Mode Variables (Default) */
    --primary-purple: #6259FF;
    --primary-purple-light: #E0DFFE;
    --dark-bg: #1A1A1A;
    --heading-color: #1F2937;
    --text-color: #6B7280;
    --background-body: var(--white);
    --background-section: var(--light-gray-bg);
    --background-header: #F6F5FF;
    --background-card: var(--white);
    --white: #FFFFFF;
    --border-color: #E5E7EB;
    --light-gray-bg: #F9FAFB;
    --green-status: #10B981;
    --orange-status: #F59E0B;
    --red-status: #EF4444;
    --shadow-color: rgba(0, 0, 0, 0.07);
}

body.dark-mode {
    /* Dark Mode Variables */
    --heading-color: #F9FAFB;
    --text-color: #9CA3AF;
    --background-body: #111827;
    --background-section: #1F2937;
    --background-header: #1F2937;
    --background-card: rgba(31, 41, 55, 0.8);
    --border-color: #374151;
    --shadow-color: rgba(0, 0, 0, 0.2);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-color);
    background-color: var(--background-body);
    transition: background-color 0.3s, color 0.3s;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

.btn {
    display: inline-block;
    padding: 12px 24px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    border: none;
    transition: background-color 0.3s ease;
}

.btn-primary {
    background-color: var(--primary-purple);
    color: var(--white);
}

.btn-primary:hover {
    background-color: #5048d9;
}

.btn-dark {
    background-color: var(--dark-bg);
    color: var(--white);
}

.btn-dark:hover {
    background-color: #333;
}

/* --- Header & Navigation --- */
.main-header {
    padding: 10px 0;
    background-color: var(--background-header);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border-color);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    display: flex;
    align-items: baseline;
    gap: 10px;
    font-size: 24px;
    font-weight: 700;
    color: var(--heading-color);
}

.logo img {
    width: 32px;
    height: 32px;
}

.nav-links {
    display: flex;
    gap: 40px;
}

.nav-links a {
    font-weight: 500;
    color: var(--text-color);
    transition: color 0.3s ease;
}

.nav-links a.active,
.nav-links a:hover {
    color: var(--primary-purple);
}

.nav-action-mobile {
    display: none;
}

/* Logo Swapping for Dark/Light Mode */
.logo .logo-dark {
    display: none;
}

.logo .logo-light {
    display: block;
}

body.dark-mode .logo .logo-light {
    display: none;
}

body.dark-mode .logo .logo-dark {
    display: block;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 25px;
}

.nav-login {
    font-weight: 600;
    color: var(--text-color);
    transition: color 0.3s ease;
}

.nav-login:hover {
    color: var(--primary-purple);
}

.hamburger-menu {
    display: none;
    cursor: pointer;
}

.hamburger-menu .bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: all 0.3s ease-in-out;
    background-color: var(--heading-color);
}

/* --- Floating Theme Switcher --- */
#theme-switcher {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1001;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--background-card);
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 12px var(--shadow-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    color: var(--text-color);
}

#theme-switcher:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px var(--shadow-color);
    color: var(--primary-purple);
}

#theme-switcher svg {
    width: 22px;
    height: 22px;
}

#theme-switcher .moon-icon {
    display: none;
}

body.dark-mode #theme-switcher .moon-icon {
    display: block;
}

body.dark-mode #theme-switcher .sun-icon {
    display: none;
}

/* --- Section Headings --- */
.section-heading {
    text-align: center;
    font-size: 42px;
    font-weight: 800;
    color: var(--heading-color);
    margin-bottom: 20px;
    line-height: 1.2;
}

.section-subheading {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 60px auto;
    font-size: 18px;
    line-height: 1.6;
}

/* --- Hero Section --- */
.hero-section {
    padding: 80px 0;
    background: linear-gradient(180deg, var(--background-header) 0%, var(--background-body) 100%);
}

.hero-container {
    display: grid;
    grid-template-columns: 1fr 1.1fr;
    align-items: center;
    gap: 60px;
}

.hero-content h1 {
    font-size: 60px;
    font-weight: 800;
    color: var(--heading-color);
    line-height: 1.2;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 18px;
    line-height: 1.6;
    margin-bottom: 30px;
    max-width: 500px;
}

/* --- NEW, CORRECTED Hero Visual --- */
.hero-visual-wrapper {
    position: relative;
    min-height: 420px;
}

.insight-card {
    background-color: var(--background-card);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 10px 30px var(--shadow-color);
    backdrop-filter: blur(10px);
    position: absolute;
    animation: fadeIn 0.5s ease-out forwards;
    opacity: 0;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.data-card {
    width: 300px;
    top: 0;
    right: 0;
    animation-delay: 0.2s;
    z-index: 10;
}

.data-card .header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.data-card .header h4 {
    font-size: 16px;
    color: var(--heading-color);
}

.data-card .header .status {
    font-size: 12px;
    color: var(--green-status);
    font-weight: 600;
}

.live-graph path {
    stroke-dasharray: 1000;
    stroke-dashoffset: 1000;
    animation: draw 2s linear infinite;
}

@keyframes draw {
    to {
        stroke-dashoffset: 0;
    }
}

.ai-card {
    width: 340px;
    top: 150px;
    right: 80px;
    z-index: 15;
    animation-delay: 0.4s;
}

.ai-card h3 {
    font-size: 18px;
    color: var(--heading-color);
    margin-bottom: 15px;
}

.ai-card .insight {
    background-color: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 15px;
    text-align: center;
}

body.light-mode .ai-card .insight {
    background-color: var(--light-gray-bg);
}

.ai-card .insight-icon {
    color: var(--orange-status);
    margin-bottom: 8px;
}

.ai-card .insight-icon svg {
    width: 24px;
    height: 24px;
}

.ai-card .insight p {
    font-weight: 500;
    color: var(--heading-color);
    line-height: 1.5;
}

.action-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 20px;
    color: var(--heading-color);
}

.action-item .action-icon {
    color: var(--primary-purple);
}

.action-item .action-icon svg {
    width: 24px;
    height: 24px;
}

.ota-card {
    top: 400px;
    right: 260px;
    width: 280px;
    z-index: 5;
    animation-delay: 0.6s;
}

.ota-card .header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.ota-card h4 {
    font-size: 16px;
    color: var(--heading-color);
}

.ota-card .icon {
    color: var(--primary-purple);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background-color: var(--border-color);
    border-radius: 4px;
    overflow: hidden;
    margin-top: 5px;
}

.progress-fill {
    width: 75%;
    height: 100%;
    background-color: var(--primary-purple);
    border-radius: 4px;
}

.fleet-card {
    top: 20px;
    left: -20px;
    width: 240px;
    z-index: 5;
    animation-delay: 0.8s;
}

.fleet-card h4 {
    font-size: 16px;
    color: var(--heading-color);
    margin-bottom: 15px;
}

.fleet-card .stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
}

.fleet-card .stat:not(:last-child) {
    margin-bottom: 10px;
}

.fleet-card .stat .value {
    font-weight: 600;
    color: var(--heading-color);
}

.rule-card {
    bottom: -100px;
    right: -50px;
    width: 260px;
    z-index: 20;
    animation-delay: 1s;
}

.rule-card .header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.rule-card .header .icon {
    color: var(--primary-purple);
}

.rule-card .header h4 {
    font-size: 16px;
    color: var(--heading-color);
    margin: 0;
}

.rule-card p {
    font-family: monospace;
    font-size: 14px;
    line-height: 1.6;
}

.rule-card .highlight {
    color: var(--primary-purple);
    font-weight: 600;
}

/* --- Features Section --- */
.features-section {
    padding: 80px 0;
    background-color: var(--background-body);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.feature-card {
    background-color: var(--background-card);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 30px;
    text-align: center;
}

.feature-card .icon {
    color: var(--primary-purple);
    margin-bottom: 20px;
    background-color: var(--primary-purple-light);
    display: inline-flex;
    padding: 15px;
    border-radius: 50%;
}

body.dark-mode .feature-card .icon {
    background-color: rgba(98, 89, 255, 0.1);
}

.feature-card .icon svg {
    width: 32px;
    height: 32px;
}

.feature-card h3 {
    font-size: 20px;
    color: var(--heading-color);
    margin-bottom: 10px;
}

.feature-card p {
    line-height: 1.6;
}

/* --- Client Logos Section --- */
.client-logos-section {
    padding: 60px 0;
    background-color: var(--background-section);
    border-top: 1px solid var(--border-color);
}

.section-title {
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 40px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.logo-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 40px 60px;
}

.client-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 24px;
    font-weight: 700;
    color: var(--heading-color);
    filter: grayscale(100%);
    opacity: 0.6;
    transition: all 0.3s ease;
}

body.light-mode .client-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
}

body.dark-mode .client-logo {
    filter: invert(1) grayscale(100%);
    opacity: 0.7;
}

body.dark-mode .client-logo:hover {
    filter: invert(0) grayscale(0%);
    opacity: 1;
}

.client-logo svg {
    height: 32px;
}

.client-logo .logo-text {
    font-family: 'Inter', sans-serif;
}

/* --- Pricing Section --- */
.pricing-section {
    padding: 80px 0;
    background-color: var(--background-body);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    align-items: stretch;
}

.pricing-card {
    background-color: var(--background-card);
    border-radius: 16px;
    padding: 30px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 6px var(--shadow-color);
    text-align: left;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px var(--shadow-color);
}

.plan-name,
.plan-price .amount,
.includes-title {
    color: var(--heading-color);
}

.plan-price .currency,
.billing-info,
.features-list li {
    color: var(--text-color);
}

.plan-name {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 15px;
}

.plan-price {
    display: flex;
    align-items: flex-start;
    margin-bottom: 8px;
}

.plan-price .amount {
    font-size: 48px;
    font-weight: 800;
    line-height: 1;
}

.plan-price .currency {
    font-size: 16px;
    font-weight: 600;
    margin-left: 8px;
}

.billing-info {
    font-size: 14px;
    margin-bottom: 25px;
    height: 40px;
}

.pricing-card hr {
    border: none;
    height: 1px;
    background-color: var(--border-color);
    margin-bottom: 25px;
}

.includes-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 20px;
}

.features-list {
    margin-bottom: 40px;
    flex-grow: 1;
}

.features-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
    font-size: 16px;
}

.features-list li svg {
    flex-shrink: 0;
}

.btn-choose-plan {
    display: block;
    width: 100%;
    text-align: center;
    background-color: transparent;
    border: 2px solid var(--primary-purple);
    color: var(--primary-purple);
    font-weight: 700;
    padding: 16px;
    margin-top: auto;
}

.btn-choose-plan:hover {
    background-color: var(--primary-purple);
    color: var(--white);
}

.pricing-card.highlighted {
    background-color: var(--primary-purple);
    color: var(--white);
    transform: scale(1.05);
    border: none;
}

.pricing-card.highlighted .plan-name,
.pricing-card.highlighted .plan-price .amount,
.pricing-card.highlighted .includes-title {
    color: var(--white);
}

.pricing-card.highlighted .plan-price .currency,
.pricing-card.highlighted .billing-info,
.pricing-card.highlighted .features-list li {
    color: rgba(255, 255, 255, 0.85);
}

.pricing-card.highlighted hr {
    background-color: rgba(255, 255, 255, 0.2);
}

.pricing-card.highlighted .btn-choose-plan {
    background-color: var(--white);
    border-color: var(--white);
    color: var(--primary-purple);
}

.pricing-card.highlighted .btn-choose-plan:hover {
    background-color: #f0f0f0;
}

/* --- Blog Section --- */
.blog-section {
    padding: 80px 0;
    background-color: var(--background-section);
}

.blog-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 50px;
}

.blog-header .section-heading {
    text-align: left;
    margin-bottom: 0;
}

.view-all-link {
    font-weight: 600;
    color: var(--primary-purple);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

.blog-card {
    background-color: var(--background-card);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 6px var(--shadow-color);
    overflow: hidden;
}

.blog-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.blog-card-content {
    padding: 25px;
}

.blog-card .category {
    font-size: 14px;
    font-weight: 600;
    color: var(--primary-purple);
    margin-bottom: 10px;
}

.blog-card h3 {
    font-size: 20px;
    color: var(--heading-color);
    margin-bottom: 15px;
    line-height: 1.4;
}

.blog-card .read-more {
    font-weight: 600;
    color: var(--heading-color);
}

body.dark-mode .blog-card .read-more:hover {
    color: var(--primary-purple);
}

/* --- Footer --- */
.main-footer {
    padding: 80px 0;
    background-color: var(--background-body);
    border-top: 1px solid var(--border-color);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 60px;
}

.footer-col h4 {
    color: var(--heading-color);
}

.footer-col p {
    line-height: 1.6;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 20px;
    margin-bottom: 20px;
}

.social-links a svg {
    width: 24px;
    height: 24px;
    fill: var(--text-color);
    transition: fill 0.3s ease;
}

.social-links a:hover svg {
    fill: var(--primary-purple);
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-purple);
}

/* --- Responsive Adjustments --- */
@media (max-width: 1024px) {
    .nav-links {
        display: none;
        flex-direction: column;
        gap: 20px;
        background-color: var(--background-section);
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        padding: 20px 0;
        text-align: center;
        box-shadow: 0 4px 6px var(--shadow-color);
        border-top: 1px solid var(--border-color);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-actions {
        display: none;
    }

    .hamburger-menu {
        display: block;
    }

    .hero-visual-wrapper {
        margin-top: 40px;
        min-height: 0;
    }

    .insight-card {
        position: static;
        transform: none !important;
        width: 100%;
        max-width: 400px;
        margin: 0 auto 20px auto;
    }

    .features-grid {
        grid-template-columns: 1fr 1fr;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }

    .pricing-grid {
        grid-template-columns: 1fr 1fr;
        gap: 30px;
    }

    .nav-action-mobile {
        display: list-item;
        margin-top: 15px;
    }

    .nav-action-mobile .btn {
        display: inline-block;
        width: auto;
        padding: 12px 30px;
    }
}

@media (max-width: 768px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content h1 {
        font-size: 42px;
    }

    .section-heading {
        font-size: 32px;
    }

    .features-grid {
        grid-template-columns: 1fr;
    }

    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-links {
        justify-content: center;
    }
}