/* Root Variables */
:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --info-color: #0dcaf0;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --dark-color: #212529;
    --light-color: #f8f9fa;
    --navbar-gradient: linear-gradient(90deg, #3f2dba 0%, #1b3fba 100%);
    --navbar-gradient-scrolled: linear-gradient(90deg, rgba(50, 31, 146, 0.98) 0%, rgba(18, 56, 155, 0.98) 100%);
    --mid-gradient: linear-gradient(180deg, #f2f3f5 0%, #ffffff 70%);
}

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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    overflow-x: hidden;
}

html {
    scroll-behavior: smooth;
}

/* Navigation */
.navbar {
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    background: var(--navbar-gradient);
    backdrop-filter: blur(6px);
}

.navbar.navbar-scrolled {
    background: var(--navbar-gradient-scrolled);
    box-shadow: 0 12px 30px rgba(18, 36, 102, 0.45);
}

.navbar-brand {
    font-size: 1.5rem;
    letter-spacing: -0.5px;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: #fff;
    transition: width 0.3s ease;
}

.navbar-nav .nav-link:hover {
    color: rgba(255, 255, 255, 0.8) !important;
    transform: translateY(-4px);
}

.navbar-nav .nav-link:hover::after {
    width: 100%;
}

.navbar-collapse {
    position: relative;
}

/* Fix for language selector underline visibility */
.navbar-nav .nav-item.dropdown .nav-link {
    position: relative;
    overflow: hidden;
}

.navbar-nav .nav-item.dropdown .nav-link::after {
    display: none !important;
}

.navbar-nav .nav-item.dropdown .nav-link:hover::after {
    display: none;
}

.nav-progress-wrapper {
    position: relative;
    display: flex;
    gap: 0.25rem;
    align-items: center;
}

.nav-progress-wrapper .nav-link {
    position: relative;
    transition: color 0.25s ease, transform 0.25s ease;
}

.nav-progress-wrapper .nav-link.active {
    color: #fff !important;
    transform: translateY(-2px);
}

.nav-progress-indicator {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 2px;
    width: 24px;
    background: #fff;
    border-radius: 999px;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 0.3s ease, width 0.3s ease, left 0.3s ease, opacity 0.3s ease;
    pointer-events: none;
    opacity: 0;
}

.navbar.navbar-compact {
    padding: 0.5rem 0;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(21, 58, 138, 0.3);
}

.navbar.navbar-compact .navbar-brand {
    font-size: 1.25rem;
}

/* Hero Section */
.hero-section {
    background: linear-gradient(135deg, #3f2dba 0%, #2c1b80 45%, #153a8a 100%);
    position: relative;
    padding-top: 80px;
    overflow: hidden;
}

.hero-section .container {
    position: relative;
    z-index: 2;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="grid" width="100" height="100" patternUnits="userSpaceOnUse"><path d="M 100 0 L 0 0 0 100" fill="none" stroke="rgba(255,255,255,0.05)" stroke-width="1"/></pattern></defs><rect width="100%" height="100%" fill="url(%23grid)" /></svg>');
    opacity: 0.2;
    z-index: 0;
}

.hero-parallax-layer {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(60% 60% at 50% 30%, rgba(255, 255, 255, 0.18) 0%, rgba(255, 255, 255, 0) 80%),
        url('../images/dashboard.webp');
    background-repeat: no-repeat;
    background-position: center 20%;
    background-size: 960px auto;
    opacity: 0.18;
    z-index: 1;
    pointer-events: none;
    transform: translateY(0);
    transition: transform 0.2s ease-out;
}

.hero-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
}

.hero-wave svg {
    position: relative;
    display: block;
    width: calc(100% + 1.3px);
    height: 80px;
}

.hero-content {
    will-change: transform;
    transition: transform 0.3s ease-out;
}

.hero-section [data-parallax],
.stats-row[data-parallax] {
    will-change: transform;
    transition: transform 0.3s ease-out;
}

.stats-row {
    transition: transform 0.3s ease-out;
}

.share-actions .btn {
    width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.share-actions .btn:hover,
.share-actions .btn:focus-visible {
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(12, 52, 163, 0.35);
}

.share-actions .btn i {
    font-size: 1rem;
}

.ripple {
    position: relative;
    overflow: hidden;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.ripple:hover,
.ripple:focus-visible {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 12px 35px rgba(21, 58, 138, 0.35);
}

.ripple:active {
    transform: translateY(0) scale(0.99);
}

.ripple-effect {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.35);
    transform: scale(0);
    animation: ripple-animation 0.6s ease-out forwards;
    pointer-events: none;
}

@keyframes ripple-animation {
    to {
        transform: scale(10);
        opacity: 0;
    }
}

.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px) scale(0.98);
    transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.6s ease;
}

.reveal-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

.reveal-on-scroll.is-visible:nth-of-type(odd) {
    transition-delay: 0.05s;
}

.reveal-on-scroll.is-visible:nth-of-type(even) {
    transition-delay: 0.1s;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-in {
    animation: fadeInUp 0.8s ease-out;
}

.animate-fade-in-delay-1 {
    animation: fadeInUp 0.8s ease-out 0.2s both;
}

.animate-fade-in-delay-2 {
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.animate-fade-in-delay-3 {
    animation: fadeInUp 0.8s ease-out 0.6s both;
}

/* Mockup Browser */
.mockup-browser {
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    transform: perspective(1000px) rotateY(-10deg);
    transition: all 0.3s ease;
}

.mockup-browser:hover {
    transform: perspective(1000px) rotateY(0deg);
}

.mockup-header {
    background: #f5f5f5;
    padding: 12px 16px;
    display: flex;
    gap: 8px;
    border-bottom: 1px solid #ddd;
}

.mockup-header .dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ddd;
}

.mockup-header .dot:nth-child(1) {
    background: #ff5f56;
}

.mockup-header .dot:nth-child(2) {
    background: #ffbd2e;
}

.mockup-header .dot:nth-child(3) {
    background: #27c93f;
}

.mockup-content {
    padding: 60px 40px;
    text-align: center;
    background: linear-gradient(to bottom, #f8f9fa, white);
    min-height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

/* Feature Cards */
.feature-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(244, 247, 255, 0.98) 100%);
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

.feature-icon {
    width: 70px;
    height: 70px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
    color: white;
}

/* Solutions Section with Parallax */
.solutions-section {
    position: relative;
    overflow: hidden;
    background: linear-gradient(180deg, rgba(248, 249, 250, 0.95) 0%, rgba(255, 255, 255, 0.95) 100%);
}

.solutions-parallax-layer {
    position: absolute;
    top: 150px; /* Lowered the parallax layer */
    left: 0;
    right: 0;
    bottom: -400px;
    background-image: url('../images/dashboard.webp');
    background-size: contain;
    background-position: center center;
    background-repeat: no-repeat;
    opacity: 1;
    z-index: 0;
    transform: translateY(0);
    will-change: transform;
}

/* Solution Cards */
.solution-card {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(20px);
    padding: 2rem 1.75rem;
    border-radius: 14px;
    border: 2px solid rgba(13, 110, 253, 0.15);
    box-shadow: 0 12px 30px rgba(13, 110, 253, 0.1), 0 4px 10px rgba(0, 0, 0, 0.05);
    transition: all 0.35s ease;
}

.solution-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 40px rgba(13, 110, 253, 0.12);
}

.solution-icon {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 10px 25px rgba(13, 110, 253, 0.2);
}

.solution-icon.icon-sales {
    background: linear-gradient(135deg, #0d6efd 0%, #6f42c1 100%);
}

.solution-icon.icon-service {
    background: linear-gradient(135deg, #20c997 0%, #0dcaf0 100%);
}

.solution-icon.icon-operations {
    background: linear-gradient(135deg, #fd7e14 0%, #ffc107 100%);
}

.solution-icon.icon-intelligence {
    background: linear-gradient(135deg, #6f42c1 0%, #d63384 100%);
}

/* Benefit Cards */
.benefit-card {
    text-align: center;
    padding: 2rem 1.5rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(243, 244, 255, 0.98) 100%);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.benefit-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1);
}

.benefit-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Demo Cards */
.demo-card {
    text-align: center;
    padding: 2rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(235, 241, 255, 0.98) 100%);
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.demo-card:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.demo-image {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, rgba(94, 96, 206, 0.12) 0%, rgba(37, 99, 235, 0.18) 100%);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
}

/* Pricing */
.pricing-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(237, 241, 255, 0.99) 100%);
    border-radius: 18px;
    padding: 2.5rem 2.25rem;
    border: 1px solid rgba(13, 110, 253, 0.1);
    display: flex;
    flex-direction: column;
    position: relative;
    transition: all 0.35s ease;
    min-height: 100%;
}

.pricing-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(13, 110, 253, 0.15);
}

.pricing-card.featured {
    border-color: var(--primary-color);
    box-shadow: 0 24px 50px rgba(13, 110, 253, 0.2);
}

.pricing-badge {
    position: absolute;
    top: 18px;
    right: 24px;
    background: rgba(13, 110, 253, 0.12);
    color: var(--primary-color);
    font-weight: 600;
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.8rem;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.pricing-card.featured .pricing-badge {
    background: var(--primary-color);
    color: white;
}

.pricing-header {
    margin-bottom: 2rem;
}

.pricing-price {
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    font-weight: 700;
    color: var(--dark-color);
}

.pricing-price .currency {
    font-size: 1.5rem;
}

.pricing-price .amount {
    font-size: 2.75rem;
    letter-spacing: -1px;
}

.pricing-price .period {
    font-size: 0.95rem;
    color: var(--secondary-color);
}

.pricing-card.featured .pricing-price {
    color: var(--primary-color);
}

.pricing-card .btn {
    border-radius: 12px;
    font-weight: 600;
}

.pricing-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    margin-bottom: 0.85rem;
    color: var(--secondary-color);
    font-size: 0.95rem;
}

.pricing-features li i {
    margin-top: 0.2rem;
}

/* Testimonials */
.testimonial-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(240, 242, 255, 0.98) 100%);
    border-radius: 16px;
    padding: 2.25rem;
    border: 1px solid rgba(108, 117, 125, 0.15);
    box-shadow: 0 12px 30px rgba(108, 117, 125, 0.12);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.testimonial-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 18px 45px rgba(108, 117, 125, 0.18);
}

.testimonial-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3f2dba 0%, #153a8a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.6rem;
    margin-bottom: 1.5rem;
}

.testimonial-quote {
    font-style: italic;
    color: #343a40;
    line-height: 1.6;
    flex-grow: 1;
}

.testimonial-meta {
    margin-top: 1.5rem;
}

.testimonial-meta .name {
    display: block;
    font-weight: 600;
    color: var(--dark-color);
}

.testimonial-meta .role {
    font-size: 0.9rem;
    color: var(--secondary-color);
}

/* FAQ */
.faq-accordion .accordion-item {
    border: none;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 1rem;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.08);
}

.faq-accordion .accordion-button {
    font-weight: 600;
    padding: 1.25rem;
}

.faq-accordion .accordion-button:not(.collapsed) {
    color: var(--primary-color);
    background-color: rgba(13, 110, 253, 0.08);
    box-shadow: none;
}

.faq-accordion .accordion-body {
    padding: 1.25rem;
    color: var(--secondary-color);
    line-height: 1.7;
}

/* CTA */
.cta-panel {
    background: linear-gradient(135deg, #3f2dba 0%, #2c1b80 40%, #153a8a 100%);
    border-radius: 24px;
    padding: 3rem;
    position: relative;
    overflow: hidden;
}

.cta-panel::after {
    content: '';
    position: absolute;
    top: -80px;
    right: -120px;
    width: 240px;
    height: 240px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.cta-panel::before {
    content: '';
    position: absolute;
    bottom: -120px;
    left: -80px;
    width: 220px;
    height: 220px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
}

.cta-panel .btn {
    font-size: 1.05rem;
    font-weight: 600;
}


/* Contact Form */
.contact-form-card {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.97) 0%, rgba(245, 247, 255, 1) 100%);
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.form-label {
    font-weight: 600;
    color: #333;
    margin-bottom: 0.5rem;
}

.form-control {
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.1);
}

/* Buttons */
.btn {
    border-radius: 8px;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-primary {
    background: linear-gradient(135deg, #3f2dba 0%, #2c1b80 45%, #153a8a 100%);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #2c1b80 0%, #3f2dba 55%, #0f2f6f 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.4);
}

.btn-outline-primary {
    border: 2px solid rgba(13, 110, 253, 0.6);
    color: var(--primary-color);
    background: transparent;
}

.btn-outline-primary:hover {
    background: var(--primary-color);
    color: #fff;
}

.btn-outline-light {
    border: 2px solid rgba(255, 255, 255, 0.8);
}

.btn-outline-light:hover {
    background: white;
    color: var(--primary-color);
    transform: translateY(-2px);
}

/* Footer */
footer {
    margin-top: 0;
}

footer a:hover {
    color: white !important;
    text-decoration: underline !important;
}

.gradient-mid {
    background: var(--mid-gradient);
}

/* Alert Messages */
.alert {
    border-radius: 8px;
    padding: 1rem;
    margin-top: 1rem;
    animation: fadeInUp 0.5s ease-out;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-section {
        min-height: 100vh;
    }

    .display-3 {
        font-size: 2.5rem;
    }

    .display-4 {
        font-size: 2rem;
    }

    .mockup-browser {
        transform: none;
    }

    .contact-form-card {
        padding: 2rem 1.5rem;
    }

    .feature-card,
    .benefit-card,
    .demo-card,
    .solution-card,
    .pricing-card,
    .testimonial-card {
        margin-bottom: 1.5rem;
    }

    .cta-panel {
        padding: 2.25rem;
    }
}

/* Section Spacing */
section {
    scroll-margin-top: 80px;
}

/* Smooth Transitions */
* {
    transition: color 0.2s ease, background-color 0.2s ease;
}

/* Loading States */
.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* Success/Error States */
.form-success {
    border-color: var(--success-color) !important;
}

.form-error {
    border-color: var(--danger-color) !important;
}

/* Utility Classes */
.text-gradient {
    background: linear-gradient(135deg, #3f2dba 0%, #2c1b80 45%, #153a8a 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.shadow-lg-custom {
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
}

/* Back to Top Button */
.btn-back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3f2dba 0%, #2c1b80 45%, #153a8a 100%);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: 0 4px 20px rgba(63, 45, 186, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.4s ease, transform 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 1000;
}

.btn-back-to-top.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    animation: backToTopPop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.btn-back-to-top:hover {
    background: linear-gradient(135deg, #2c1b80 0%, #3f2dba 55%, #0f2f6f 100%);
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 8px 30px rgba(63, 45, 186, 0.6);
}

.btn-back-to-top:active {
    transform: translateY(-2px) scale(0.98);
}

@media (max-width: 768px) {
    .btn-back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }
}

@keyframes backToTopPop {
    0% {
        transform: translateY(30px) scale(0.85);
        opacity: 0;
    }
    60% {
        transform: translateY(-6px) scale(1.07);
        opacity: 1;
    }
    100% {
        transform: translateY(0) scale(1);
    }
}
