/* Phase 2: Eloquent & Premium Tech UI */
:root {
    /* Deep Tech Palette */
    --primary-bg: #0f172a;
    /* Midnight Blue */
    --surface-bg: #1e293b;
    /* Lighter Slate */
    --surface-glass: rgba(30, 41, 59, 0.7);

    --accent-primary: #6366f1;
    /* Indigo */
    --accent-secondary: #ec4899;
    /* Pink/Rose for gradients */
    --accent-glow: rgba(99, 102, 241, 0.4);

    --text-main: #f8fafc;
    /* White/Ice */
    --text-muted: #94a3b8;
    /* Slate Grey */

    /* Layout */
    --container-width: 1200px;
    --header-height: 80px;
    --radius-lg: 16px;
    --radius-xl: 24px;

    /* Effects */
    --glass-blur: blur(12px);
    --shadow-glow: 0 0 20px var(--accent-glow);
    --transition-slow: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--primary-bg);
    color: var(--text-main);
    margin: 0;
    line-height: 1.7;
    overflow-x: hidden;
}

h1,
h2,
h3 {
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-top: 0;
    line-height: 1.1;
}

h1 {
    background: linear-gradient(135deg, #fff 0%, #cbd5e1 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

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

.container {
    width: 88%;
    max-width: var(--container-width);
    margin: 0 auto;
}

/* Navbar: Glassmorphic */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: var(--glass-blur);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    z-index: 1000;
    display: flex;
    align-items: center;
    transition: var(--transition-slow);
}

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

.logo {
    font-size: 1.75rem;
    font-weight: 800;
    background: linear-gradient(to right, var(--accent-primary), var(--accent-secondary));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

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

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

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent-primary);
    transition: var(--transition-slow);
}

.nav-links a:hover {
    color: #fff;
}

.nav-links a:hover::after {
    width: 100%;
}

/* Hero Section: Immersive */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    position: relative;
    overflow: hidden;
    padding-top: var(--header-height);
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('xifybgd4.webp') no-repeat center center/cover;
    z-index: -2;
    transform: scale(1.1);
    /* Subtle zoom for depth */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(15, 23, 42, 0.3), var(--primary-bg));
    z-index: -1;
}

.hero-content {
    max-width: 800px;
    text-align: center;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero h1 {
    font-size: clamp(3rem, 8vw, 6rem);
    /* Fluid type */
    margin-bottom: 24px;
    text-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
}

.tagline {
    font-size: clamp(1.2rem, 2vw, 1.8rem);
    color: #cbd5e1;
    font-weight: 300;
    margin-bottom: 48px;
    opacity: 0.9;
}

/* Buttons: Glowing & Gradient */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 99px;
    cursor: pointer;
    transition: var(--transition-slow);
    position: relative;
    overflow: hidden;
    border: none;
}

.primary-btn {
    background: linear-gradient(135deg, var(--accent-primary), var(--accent-secondary));
    color: white;
    box-shadow: 0 4px 15px var(--accent-glow);
}

.primary-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: 0.5s;
}

.primary-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px var(--accent-glow);
}

.primary-btn:hover::before {
    left: 100%;
}

.secondary-btn {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
}

.secondary-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* Sections */
section {
    padding: 120px 0;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 60px;
    background: linear-gradient(to right, #fff, #94a3b8);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* About Section */
.about-section {
    background: var(--primary-bg);
}

.about-text {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.25rem;
    color: var(--text-muted);
}

/* Gallery/Solutions cards */
.gallery-section {
    background: #0b1120;
    /* Slightly darker */
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
}

.gallery-item {
    background: var(--surface-bg);
    border-radius: var(--radius-xl);
    overflow: hidden;
    position: relative;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: var(--transition-slow);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.gallery-item:hover {
    transform: translateY(-10px);
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.card-img-wrapper {
    height: 280px;
    overflow: hidden;
    position: relative;
}

.card-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.8s ease;
}

.gallery-item:hover .card-img-wrapper img {
    transform: scale(1.1);
}

.card-content {
    padding: 32px;
}

.card-content h3 {
    font-size: 1.5rem;
    margin-bottom: 8px;
    color: #fff;
}

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

/* Contact */
.contact-section {
    text-align: center;
    background: linear-gradient(to top, #0f172a, #1e293b);
}

/* Footer */
footer {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding: 60px 0;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* Modal: Premium Glass */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(16px);
}

.modal-content {
    background: rgba(30, 41, 59, 0.8);
    backdrop-filter: blur(20px);
    margin: 10vh auto;
    padding: 48px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 90%;
    max-width: 480px;
    border-radius: var(--radius-xl);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    position: relative;
    animation: modalSlideUp 0.5s ease-out;
    color: white;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

.close {
    color: var(--text-muted);
    font-size: 32px;
    position: absolute;
    right: 24px;
    top: 24px;
    transition: 0.3s;
}

.close:hover {
    color: white;
}

.modal-step input {
    width: 100%;
    padding: 16px;
    margin: 16px 0 24px 0;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 12px;
    font-size: 1rem;
    transition: 0.3s;
}

.modal-step input:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(0, 0, 0, 0.3);
}

.auth-btn {
    width: 100%;
    padding: 16px;
    border-radius: 12px;
    font-weight: 600;
    margin-top: 8px;
    cursor: pointer;
    border: none;
    font-size: 1rem;
    background: var(--accent-primary);
    color: white;
    transition: 0.3s;
}

.auth-btn:hover {
    background: #4f46e5;
}

.auth-btn.secondary {
    background: transparent;
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-muted);
}

.auth-btn.secondary:hover {
    border-color: white;
    color: white;
}

/* Scroll Animation Utilities */
.fade-in-section {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 1s ease-out, transform 1s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: opacity, transform;
}

.fade-in-section.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile */
@media (max-width: 768px) {
    :root {
        --header-height: 70px;
    }

    .nav-links {
        display: none;
    }

    .hero h1 {
        font-size: 3.5rem;
    }
}
