/* ===================================
   GLOBAL DESIGN SYSTEM & ROOT VARIABLES
   =================================== */

:root {
    /* Primary Color Palette */
    --primary: #4F46E5;     /* Indigo – Trust & Technology */
    --primary-dark: #3730A3;
    --primary-light: #818CF8;
    --secondary: #0EA5E9;   /* Sky Blue – Growth */
    --secondary-dark: #0284C7;
    --secondary-light: #38BDF8;
    --accent: #22C55E;      /* Green – Success */
    --accent-dark: #16A34A;
    --accent-light: #4ADE80;

    /* Neutral Colors */
    --dark: #0F172A;        /* Slate Dark */
    --light: #F8FAFC;       /* Soft White */
    --muted: #64748B;       /* Gray Text */
    --border: #E2E8F0;

    /* Status Colors */
    --danger: #EF4444;
    --warning: #F59E0B;
    --info: #3B82F6;
    --success: #10B981;

    /* Typography */
    --font-primary: 'Inter', 'Poppins', -apple-system, BlinkMacSystemFont, sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;
    --spacing-2xl: 4rem;

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===================================
   GLOBAL STYLES & RESETS
   =================================== */

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    font-size: 16px;
    line-height: 1.6;
    color: var(--dark);
    background-color: #ffffff;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Poppins', var(--font-primary);
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

h1 { font-size: 48px; }
h2 { font-size: 36px; }
h3 { font-size: 24px; }
h4 { font-size: 20px; }

a {
    text-decoration: none;
    color: var(--primary);
    transition: all var(--transition-base);
}

a:hover {
    color: var(--primary-dark);
}

img {
    max-width: 100%;
    height: auto;
}

/* ===================================
   UTILITY CLASSES
   =================================== */

.text-gradient {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.min-vh-90 {
    min-height: 90vh;
}

/* ===================================
   NAVIGATION
   =================================== */

.navbar {
    padding: 1rem 0;
    transition: all var(--transition-base);
}

.navbar-brand {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark) !important;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.brand-icon {
    font-size: 1.75rem;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-link {
    font-weight: 500;
    color: var(--dark) !important;
    padding: 0.5rem 1rem !important;
    transition: all var(--transition-base);
    position: relative;
}

.nav-link:hover {
    color: var(--primary) !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: all var(--transition-base);
    transform: translateX(-50%);
}

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

.nav-link.active {
    color: var(--primary) !important;
    font-weight: 600;
}

.nav-link.active::after {
    width: 80%;
}

.dropdown-item.active {
    background-color: var(--primary);
    color: #ffffff !important;
    font-weight: 500;
}

.dropdown-item.active:hover {
    background-color: var(--primary-dark);
    color: #ffffff !important;
}

.navbar .btn-primary {
    padding: 0.5rem 1.5rem;
    border-radius: var(--radius-lg);
}

.dropdown-menu-modules {
    padding: 1rem;
    border: none;
    box-shadow: var(--shadow-xl);
    border-radius: var(--radius-lg);
    min-width: 280px;
}

.dropdown-menu-modules .dropdown-item {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.dropdown-menu-modules .dropdown-item:hover {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(14, 165, 233, 0.1));
    transform: translateX(5px);
}

.dropdown-menu-modules .dropdown-item i {
    font-size: 1.25rem;
    color: var(--primary);
}

/* ===================================
   BUTTONS
   =================================== */

.btn {
    font-weight: 500;
    border-radius: var(--radius-lg);
    padding: 0.75rem 1.5rem;
    transition: all var(--transition-base);
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
    background: linear-gradient(135deg, var(--primary-dark), var(--secondary-dark));
}

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

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

.btn-light {
    background: white;
    color: var(--primary);
    box-shadow: var(--shadow-md);
}

.btn-light:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline-light {
    border: 2px solid white;
    color: white;
    background: transparent;
}

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

/* ===================================
   HERO SECTION
   =================================== */

.hero-section {
    padding: 4rem 0 6rem;
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #F8FAFC 0%, #EEF2FF 100%);
}

.hero-bg-elements {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
    z-index: 0;
}

.gradient-circle {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.3;
    animation: float 20s infinite ease-in-out;
}

.gradient-circle-1 {
    width: 600px;
    height: 600px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    top: -300px;
    right: -200px;
}

.gradient-circle-2 {
    width: 400px;
    height: 400px;
    background: linear-gradient(135deg, var(--secondary), var(--accent));
    bottom: -200px;
    left: -100px;
    animation-delay: -10s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(30px, -30px) scale(1.1); }
    66% { transform: translate(-20px, 20px) scale(0.9); }
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-section h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
    margin-bottom: 1.5rem;
}

.hero-section .lead {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--muted);
}

.hero-cta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.trust-indicators {
    margin-top: 2rem;
}

.trust-badge {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
}

.trust-badge:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.trust-badge i {
    font-size: 1.5rem;
}

.trust-badge span {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--dark);
}

.hero-image {
    position: relative;
    z-index: 1;
}

.animated-float {
    animation: floating 6s ease-in-out infinite;
}

@keyframes floating {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

/* ===================================
   ERP MODULES SECTION
   =================================== */

.modules-section {
    padding: 6rem 0;
    background: white;
}

.module-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 2rem;
    height: 100%;
    border: 1px solid var(--border);
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
}

.module-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--transition-base);
}

.module-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
    border-color: var(--primary);
}

.module-card:hover::before {
    transform: scaleX(1);
}

.module-card.featured {
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.05), rgba(14, 165, 233, 0.05));
    border: 2px solid var(--primary);
}

.module-icon {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    transition: all var(--transition-base);
}

.module-card:hover .module-icon {
    transform: scale(1.1) rotate(5deg);
}

.module-icon.accounting { background: linear-gradient(135deg, #EEF2FF, #DBEAFE); color: var(--primary); }
.module-icon.procurement { background: linear-gradient(135deg, #F0FDF4, #DCFCE7); color: var(--accent); }
.module-icon.sales { background: linear-gradient(135deg, #FFF7ED, #FED7AA); color: var(--warning); }
.module-icon.crm { background: linear-gradient(135deg, #FCE7F3, #FBCFE8); color: #EC4899; }
.module-icon.stock { background: linear-gradient(135deg, #F0FDFA, #CCFBF1); color: #14B8A6; }
.module-icon.manufacturing { background: linear-gradient(135deg, #FDF4FF, #FAE8FF); color: #A855F7; }
.module-icon.projects { background: linear-gradient(135deg, #FEF3C7, #FDE68A); color: #D97706; }
.module-icon.assets { background: linear-gradient(135deg, #DBEAFE, #BFDBFE); color: #3B82F6; }
.module-icon.pos { background: linear-gradient(135deg, #FFEDD5, #FED7AA); color: #F97316; }
.module-icon.quality { background: linear-gradient(135deg, #DCFCE7, #BBF7D0); color: #16A34A; }
.module-icon.support { background: linear-gradient(135deg, #E0E7FF, #C7D2FE); color: #6366F1; }
.module-icon.hr { background: linear-gradient(135deg, #FCE7F3, #FBCFE8); color: #DB2777; }
.module-icon.builder { background: linear-gradient(135deg, var(--primary), var(--secondary)); color: white; }

.module-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--dark);
}

.module-description {
    color: var(--muted);
    margin-bottom: 1.5rem;
    line-height: 1.7;
}

.module-features {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
}

.feature-tag {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.75rem;
    padding: 0.25rem 0.75rem;
    background: var(--light);
    border-radius: var(--radius-md);
    color: var(--muted);
    font-weight: 500;
}

.feature-tag i {
    font-size: 0.875rem;
    color: var(--accent);
}

.module-link {
    color: var(--primary);
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all var(--transition-base);
}

.module-card:hover .module-link {
    gap: 1rem;
}

.module-link i {
    transition: all var(--transition-base);
}

/* ===================================
   WHY CHOOSE SECTION
   =================================== */

.why-choose-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, #F8FAFC 0%, #EEF2FF 100%);
}

.feature-box {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-xl);
    height: 100%;
    border: 1px solid var(--border);
    transition: all var(--transition-base);
}

.feature-box:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: transparent;
}

.feature-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    margin-bottom: 1.5rem;
    transition: all var(--transition-base);
}

.feature-box:hover .feature-icon {
    transform: scale(1.1) rotate(-5deg);
}

.feature-title {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--dark);
}

.feature-text {
    color: var(--muted);
    line-height: 1.7;
    margin-bottom: 0;
}

/* ===================================
   DASHBOARD PREVIEW SECTION
   =================================== */

.dashboard-section {
    padding: 6rem 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.stat-item {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: all var(--transition-base);
}

.stat-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.5rem;
}

.stat-label {
    color: var(--muted);
    font-size: 0.875rem;
    font-weight: 500;
}

.dashboard-preview {
    position: relative;
}

.dashboard-preview img {
    border-radius: var(--radius-xl);
    transition: all var(--transition-slow);
}

.dashboard-preview:hover img {
    transform: scale(1.02);
}

/* ===================================
   INDUSTRIES SECTION
   =================================== */

.industries-section {
    padding: 6rem 0;
    background: white;
}

.industry-card {
    background: white;
    padding: 2rem 1.5rem;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    text-align: center;
    transition: all var(--transition-base);
    height: 100%;
}

.industry-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
    border-color: var(--primary);
}

.industry-card i {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
    display: block;
    transition: all var(--transition-base);
}

.industry-card:hover i {
    transform: scale(1.2);
}

.industry-card h5 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
    margin-bottom: 0;
}

/* ===================================
   TESTIMONIALS SECTION
   =================================== */

.testimonials-section {
    padding: 6rem 0;
}

.testimonial-card {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-xl);
    max-width: 800px;
    margin: 0 auto;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
}

.stars i {
    font-size: 1.25rem;
}

.testimonial-text {
    font-size: 1.25rem;
    line-height: 1.8;
    color: var(--dark);
    font-style: italic;
    margin-bottom: 2rem;
}

.testimonial-author {
    display: flex;
    flex-direction: column;
}

.testimonial-author strong {
    font-size: 1.1rem;
    color: var(--dark);
    margin-bottom: 0.25rem;
}

.testimonial-author span {
    color: var(--muted);
    font-size: 0.9rem;
}

.carousel-control-prev,
.carousel-control-next {
    width: 50px;
    height: 50px;
    background: var(--primary);
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 1;
}

.carousel-control-prev {
    left: -80px;
}

.carousel-control-next {
    right: -80px;
}

.carousel-control-prev:hover,
.carousel-control-next:hover {
    background: var(--primary-dark);
}

/* ===================================
   CTA SECTION
   =================================== */

.cta-section {
    padding: 6rem 0;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
}

.cta-box {
    padding: 3rem;
}

.cta-box h2,
.cta-box p {
    color: white;
}

.cta-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
}

/* ===================================
   FOOTER
   =================================== */

.footer {
    background: var(--dark);
    color: #94A3B8;
}

.footer-title {
    color: white;
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.footer-text {
    line-height: 1.8;
}

.social-links {
    display: flex;
    gap: 1rem;
}

.social-link {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    transition: all var(--transition-base);
}

.social-link:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.footer-links {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    color: #94A3B8;
    transition: all var(--transition-base);
}

.footer-links a:hover {
    color: white;
    padding-left: 5px;
}

.footer-divider {
    border-color: rgba(255, 255, 255, 0.1);
}

.footer-copyright {
    color: #94A3B8;
}

.footer-bottom-links {
    list-style: none;
    display: flex;
    gap: 2rem;
    margin: 0;
    padding: 0;
    justify-content: flex-end;
}

.footer-bottom-links a {
    color: #94A3B8;
}

.footer-bottom-links a:hover {
    color: white;
}

/* ===================================
   MODULE PAGE STYLES
   =================================== */

.page-header {
    padding: 6rem 0 4rem;
    background: linear-gradient(135deg, #F8FAFC 0%, #EEF2FF 100%);
    position: relative;
    overflow: hidden;
}

.page-header h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
}

.breadcrumb {
    background: transparent;
    padding: 0;
    margin-bottom: 2rem;
}

.breadcrumb-item + .breadcrumb-item::before {
    content: "›";
    color: var(--muted);
}

.breadcrumb-item.active {
    color: var(--primary);
}

.feature-section {
    padding: 4rem 0;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.feature-item {
    padding: 2rem;
    background: white;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border);
    transition: all var(--transition-base);
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.feature-item i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.feature-item h4 {
    margin-bottom: 1rem;
}

.feature-item p {
    color: var(--muted);
    margin-bottom: 0;
}

/* ===================================
   RESPONSIVE DESIGN
   =================================== */

@media (max-width: 991px) {
    h1 { font-size: 36px; }
    h2 { font-size: 28px; }
    h3 { font-size: 22px; }

    .hero-section {
        padding: 3rem 0 4rem;
    }

    .modules-section,
    .why-choose-section,
    .dashboard-section,
    .industries-section,
    .testimonials-section,
    .cta-section {
        padding: 4rem 0;
    }

    .hero-cta {
        justify-content: center;
    }

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

    .carousel-control-prev,
    .carousel-control-next {
        display: none;
    }

    .footer-bottom-links {
        justify-content: center;
        margin-top: 1rem;
    }
}

@media (max-width: 767px) {
    .hero-section h1 {
        font-size: 2rem;
    }

    .hero-section .lead {
        font-size: 1rem;
    }

    .btn-lg {
        padding: 0.75rem 1.25rem;
        font-size: 1rem;
    }

    .module-card {
        padding: 1.5rem;
    }

    .testimonial-card {
        padding: 2rem 1.5rem;
    }

    .testimonial-text {
        font-size: 1rem;
    }

    .cta-box {
        padding: 2rem 1rem;
    }
}

/* ===================================
   ANIMATIONS & MICRO-INTERACTIONS
   =================================== */

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

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

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

/* Smooth scroll padding for fixed navbar */
html {
    scroll-padding-top: 80px;
}

/* Loading skeleton for images */
img:not([src]) {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}


.workflow-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4F46E5, #0EA5E9);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    flex-shrink: 0;
}

.workflow-step {
    padding: 1rem;
    border-left: 3px solid #E2E8F0;
    margin-left: 20px;
}

.workflow-step:last-child {
    border-left-color: transparent;
}


.industry-detail-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-xl);
    border: 1px solid var(--border);
    height: 100%;
    transition: all 0.3s ease;
}

.industry-detail-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.industry-detail-card .industry-icon {
    width: 80px;
    height: 80px;
    border-radius: var(--radius-lg);
    background: linear-gradient(135deg, rgba(79, 70, 229, 0.1), rgba(14, 165, 233, 0.1));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}


/* Desktop Mega Menu: Show on click */
@media (min-width: 992px) {
    .nav-item.mega-menu.dropdown .dropdown-menu {
        transition: all 0.2s ease-in-out;
        margin-top: 0;
    }
    .nav-item.mega-menu.dropdown.show .dropdown-menu {
        display: block !important;
    }
}
