/* ============================================
   NxtGen Technologies — Global Stylesheet
   Modern, clean design with light theme
   ============================================ */

/* --- Reset & Base --- */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --bg: #ffffff;
    --bg-alt: #f7f8fc;
    --bg-card: #ffffff;
    --bg-card-hover: #f0f1f8;
    --surface: #f0f1f8;
    --border: #e2e4ef;
    --border-light: #c8cbe0;
    --text: #1e1e2e;
    --text-muted: #5a5d78;
    --text-dim: #8b8ea8;
    --primary: #4f46e5;
    --primary-light: #4f46e5;
    --primary-dark: #4338ca;
    --accent: #0891b2;
    --accent-light: #0891b2;
    --green: #059669;
    --green-light: #059669;
    --amber: #d97706;
    --rose: #e11d48;
    --gradient-1: linear-gradient(135deg, #4f46e5, #0891b2);
    --gradient-2: linear-gradient(135deg, #4f46e5, #9333ea);
    --gradient-3: linear-gradient(135deg, #0891b2, #059669);
    --radius: 12px;
    --radius-sm: 8px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --shadow: 0 4px 24px rgba(0,0,0,0.06);
    --shadow-lg: 0 12px 48px rgba(0,0,0,0.08);
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-display: 'Space Grotesk', 'Inter', sans-serif;
    --container: 1200px;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    overflow-x: hidden;
}

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

a:hover {
    color: var(--accent);
}

img {
    max-width: 100%;
    display: block;
}

ul { list-style: none; }

/* --- Container --- */
.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 24px;
}

/* --- Typography --- */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text);
}

h1 { font-size: clamp(2.5rem, 6vw, 4rem); }
h2 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.5rem); }
h4 { font-size: 1.1rem; }

.gradient-text {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* --- Navigation --- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    padding: 16px 0;
    transition: all var(--transition);
    background: transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    padding: 10px 0;
    box-shadow: 0 2px 16px rgba(0,0,0,0.04);
}

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

.logo {
    display: flex;
    align-items: baseline;
    gap: 2px;
    text-decoration: none;
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.5rem;
}

.logo-nxt {
    color: var(--text);
}

.logo-gen {
    background: var(--gradient-1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.logo-sub {
    font-size: 0.55rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-left: 8px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-links a {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color var(--transition);
    position: relative;
}

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

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--gradient-1);
    border-radius: 1px;
}

.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 4px;
}

.nav-toggle span {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--text);
    border-radius: 2px;
    transition: all var(--transition);
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* --- Buttons --- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 24px;
    border-radius: var(--radius-sm);
    font-family: var(--font);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: all var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient-1);
    color: #fff;
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.3);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(99, 102, 241, 0.4);
    color: #fff;
}

.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border-light);
}

.btn-outline:hover {
    border-color: var(--primary-light);
    color: var(--primary-light);
    background: rgba(99, 102, 241, 0.05);
}

.btn-white {
    background: #fff;
    color: #1e1e2e;
}

.btn-white:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    color: #1e1e2e;
}

.btn-outline-white {
    background: transparent;
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.btn-outline-white:hover {
    border-color: #fff;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

.btn-nav {
    background: var(--gradient-1);
    color: #fff !important;
    padding: 8px 20px;
    border-radius: var(--radius-sm);
}

.btn-nav:hover {
    color: #fff !important;
    transform: translateY(-1px);
}

.btn-nav::after { display: none !important; }

.btn-lg {
    padding: 14px 32px;
    font-size: 1rem;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 0.8rem;
}

.btn-full {
    width: 100%;
}

/* --- Sections --- */
.section {
    padding: 100px 0;
}

.section-alt {
    background: var(--bg-alt);
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 64px;
}

.section-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(79, 70, 229, 0.08);
    border: 1px solid rgba(79, 70, 229, 0.15);
    border-radius: 100px;
    color: var(--primary);
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 20px;
}

.section-title {
    margin-bottom: 16px;
}

.section-desc {
    color: var(--text-muted);
    font-size: 1.1rem;
    line-height: 1.7;
}

/* --- Cards --- */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 32px;
    transition: all var(--transition);
}

.card {
    box-shadow: var(--shadow);
}

.card:hover {
    border-color: var(--border-light);
    background: var(--bg-card-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card-icon {
    width: 48px;
    height: 48px;
    color: var(--primary);
    margin-bottom: 20px;
}

.card h3 {
    margin-bottom: 12px;
    font-size: 1.2rem;
}

.card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* --- Page Hero (Inner Pages) --- */
.page-hero {
    position: relative;
    padding: 160px 0 80px;
    text-align: center;
    overflow: hidden;
}

.page-hero-title {
    margin-bottom: 20px;
}

.page-hero-subtitle {
    color: var(--text-muted);
    font-size: 1.15rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.7;
}

/* --- CTA Section --- */
.section-cta {
    padding: 80px 0;
    background: transparent;
}

.cta-box {
    background: var(--gradient-1);
    border-radius: var(--radius-lg);
    padding: 80px 48px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 50%;
}

.cta-box::after {
    content: '';
    position: absolute;
    bottom: -30%;
    left: -10%;
    width: 300px;
    height: 300px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
}

.cta-box h2 {
    font-size: clamp(1.8rem, 3.5vw, 2.5rem);
    margin-bottom: 16px;
    position: relative;
    z-index: 1;
    color: #fff;
}

.cta-box p {
    color: rgba(255, 255, 255, 0.85);
    font-size: 1.1rem;
    max-width: 500px;
    margin: 0 auto 32px;
    position: relative;
    z-index: 1;
}

.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

/* --- Footer --- */
.footer {
    background: var(--bg-alt);
    border-top: 1px solid var(--border);
    padding: 64px 0 32px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
    margin-bottom: 48px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-top: 16px;
    line-height: 1.6;
}

.footer-location {
    color: var(--text-dim) !important;
    font-size: 0.85rem !important;
}

.footer-links h4 {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: var(--text-muted);
    margin-bottom: 20px;
    font-family: var(--font);
}

.footer-links ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links a {
    color: var(--text-dim);
    font-size: 0.9rem;
    transition: color var(--transition);
}

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

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 24px;
    text-align: center;
}

.footer-bottom p {
    color: var(--text-dim);
    font-size: 0.8rem;
}

/* --- Hero Background Effects --- */
.hero-bg {
    position: absolute;
    inset: 0;
    overflow: hidden;
    z-index: 0;
}

.hero-gradient {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 80% 60% at 50% 20%, rgba(79, 70, 229, 0.07), transparent),
                radial-gradient(ellipse 60% 50% at 80% 50%, rgba(8, 145, 178, 0.05), transparent),
                radial-gradient(ellipse 50% 40% at 20% 60%, rgba(147, 51, 234, 0.04), transparent);
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(0,0,0,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0,0,0,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, black, transparent);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, black, transparent);
}

/* --- Animations --- */
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); }
}

@keyframes pulse {
    0%, 100% { opacity: 0.4; }
    50% { opacity: 0.8; }
}

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

.fade-in {
    animation: fadeInUp 0.6s ease forwards;
}

/* --- Responsive --- */
@media (max-width: 968px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }
}

@media (max-width: 768px) {
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: var(--bg-card);
        flex-direction: column;
        padding: 80px 32px 32px;
        gap: 24px;
        transition: right var(--transition);
        border-left: 1px solid var(--border);
        z-index: 999;
    }

    .nav-links.open {
        right: 0;
    }

    .nav-links a.active::after {
        display: none;
    }

    .section {
        padding: 64px 0;
    }

    .page-hero {
        padding: 120px 0 60px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .cta-box {
        padding: 48px 24px;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .logo-sub {
        display: none;
    }
}
