/* General Reset & Typography */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body {
    background-color: #fafafa;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1d1d1f;
    overflow-x: hidden;
}

/* Navigation & Logo */
.nav-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.nav-logo-img {
    height: 58px; 
    width: auto;
    display: block;
    transition: transform 0.3s ease;
}

.nav-logo-link:hover .nav-logo-img {
    transform: scale(1.05);
}

.top-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 4px 5%;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    background: rgba(255, 255, 255, 0.01);
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-links {
    display: flex;
    gap: 30px;
    align-items: center;
}

.nav-links a {
    text-decoration: none;
    color: #1d1d1f;
    font-size: 0.9rem;
    font-weight: 500;
    transition: opacity 0.2s;
}

.nav-links a:hover {
    opacity: 0.7;
}

.nav-hidden {
    transform: translateY(-100%);
    opacity: 0;
    pointer-events: none;
}

/* Floating Atmosphere Elements */
.floating-elements {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.particle {
    position: absolute;
    width: 32px;
    height: 32px;
    color: #5170ff;
    opacity: 0.25; 
    stroke-width: 1.8px;
    animation: drift 25s infinite ease-in-out alternate, 
               breathe 6s infinite ease-in-out;
    transition: transform 0.6s cubic-bezier(0.2, 0, 0.2, 1), 
                opacity 0.6s ease, 
                left 0.8s ease, 
                top 0.8s ease;
}

/* Position Mapping */
.p1 { top: 12%; left: 8%; transform: scale(0.9); animation-delay: -2s; }
.p2 { top: 18%; right: 12%; transform: scale(1.1); animation-delay: -5s; }
.p3 { bottom: 15%; left: 10%; transform: scale(0.8); animation-delay: -1s; }
.p4 { bottom: 20%; right: 15%; transform: scale(1.2); animation-delay: -8s; }
.p5 { top: 45%; left: 25%; transform: scale(0.7); animation-delay: -3s; }
.p6 { top: 35%; right: 30%; transform: scale(0.85); animation-delay: -6s; }
.p7 { bottom: 40%; left: 35%; transform: scale(0.95); animation-delay: -10s; }
.p8 { bottom: 35%; right: 20%; transform: scale(0.75); animation-delay: -4s; }
.p9 { top: 60%; left: 15%; transform: scale(0.6); opacity: 0.15; }
.p10 { top: 25%; left: 45%; transform: scale(0.5); opacity: 0.15; }
.p11 { bottom: 50%; right: 40%; transform: scale(0.65); opacity: 0.2; }
.p12 { top: 10%; left: 30%; transform: scale(0.7); opacity: 0.18; }

@keyframes breathe {
    0%, 100% { transform: translateY(0) rotate(0deg); opacity: 0.2; }
    50% { transform: translateY(-25px) rotate(8deg); opacity: 0.35; }
}

@keyframes drift {
    0% { transform: translateX(0); }
    100% { transform: translateX(50px); }
}

/* Scroll Prompt */
.scroll-prompt {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    z-index: 10;
    opacity: 0.6;
    transition: opacity 0.5s ease;
}

.scroll-prompt span {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: #1d1d1f;
}

.mouse {
    width: 26px;
    height: 42px;
    border: 2px solid #1d1d1f;
    border-radius: 20px;
    position: relative;
}

.wheel {
    width: 3px;
    height: 8px;
    background: #5170ff;
    border-radius: 2px;
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    animation: scroll-wheel 2s infinite;
}

@keyframes scroll-wheel {
    0% { transform: translate(-50%, 0); opacity: 1; }
    100% { transform: translate(-50%, 15px); opacity: 0; }
}

/* Sticky & Hero Setup */
.scroll-wrapper {
    height: 300vh; 
}

.sticky-container {
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

h1 {
    font-size: 5rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    z-index: 10;
    text-align: center;
}

#text-merged {
    color: #5170ff;
}

.card-container {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* Floating Bento Icon Cards */
.icon-card {
    position: absolute;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    width: 120px;
    height: 120px;
    border-radius: 30px;
    opacity: 0;
    z-index: 5;
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05), inset 0 0 0 1px rgba(255, 255, 255, 0.4);
}

.icon-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    z-index: -1;
    border-radius: 30px;
    background: linear-gradient(135deg, rgba(190, 170, 255, 0.4) 0%, rgba(160, 220, 255, 0.4) 100%);
    filter: blur(15px);
    transform: scale(0.9);
}

.icon-card svg {
    width: 42px;
    height: 42px;
    stroke: #1d1d1f;
    stroke-width: 1.5px;
}

.icon-card span {
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #1d1d1f;
    opacity: 0.8;
}

#card-1 { top: 20%; left: -25%; }
#card-2 { top: 60%; right: -25%; }
#card-3 { top: 15%; right: -30%; }
#card-4 { top: 75%; left: -30%; }
#card-5 { bottom: -40%; left: 35%; }
#card-6 { bottom: -40%; right: 35%; }

#logo-container {
    position: absolute;
    opacity: 0;
    transform: scale(0.1);
    display: none; 
    justify-content: center;
    align-items: center;
    z-index: 100;
}

#logo {
    width: 300px;
    height: auto;
}

/* SHARED HEADER STYLES (Used by multiple sections) */
.section-header {
    text-align: center;
    margin-bottom: 80px;
    opacity: 0; 
    transform: translateY(20px);
    transition: all 1s ease-out;
}

/* Triggered by JS Intersection Observer */
.section-header.reveal {
    opacity: 1;
    transform: translateY(0);
}

.section-title {
    font-size: 3.5rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 16px;
}

.section-subtitle {
    font-size: 1.25rem;
    color: #86868b;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.4;
}

/* Bento Grid Section */
.features-section {
    padding: 120px 5% 100px 5%; 
    background: #fafafa;
    min-height: 100vh;
    z-index: 20;
    position: relative;
    margin-top: 0;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    grid-template-rows: repeat(2, 300px) auto;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.bento-item {
    opacity: 0;
    transform: translateY(60px);
    transition: opacity 0.8s ease-out, transform 0.6s cubic-bezier(0.2, 0, 0.2, 1), box-shadow 0.3s ease;
    background: #f5f5f7;
    border-radius: 24px;
    padding: 40px;
    cursor: default;
}

.bento-item.reveal {
    opacity: 1;
    transform: translateY(0);
}

.bento-item:hover {
    transform: translateY(-5px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.05);
}

.bento-item h3 {
    font-size: 1.5rem;
    margin-bottom: 10px;
    font-weight: 600;
}

.bento-item p {
    color: #86868b;
    line-height: 1.5;
}

.large { grid-column: span 2; grid-row: span 2; }
.medium { grid-column: span 2; }
.small { grid-column: span 1; }

.feature-image-wrapper {
    width: 100%;
    display: flex;
    justify-content: center;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

.feature-img {
    height: auto;
    display: block;
    mix-blend-mode: multiply;
    transition: transform 0.6s cubic-bezier(0.2, 0, 0.2, 1);
}

.bento-item.large {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    overflow: hidden;
    padding-bottom: 0;
}

.bento-item.large .feature-img {
    width: 95%;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.03));
}

.bento-item.medium {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    overflow: hidden;
    padding-bottom: 30px;
}

.bento-item.medium .feature-image-wrapper {
    flex-grow: 1;
    align-items: center; 
    margin-top: 10px;
}

.feature-img.secondary, 
.feature-img.tertiary {
    width: 110%; 
    object-fit: contain;
    filter: drop-shadow(0 15px 30px rgba(0,0,0,0.05));
}

.bento-item.small {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 30px;
    min-height: 220px;
}

.micro-icon {
    width: 48px;
    height: 48px;
    color: #5170ff;
    margin-bottom: 15px;
    stroke-width: 1.5;
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.bento-item.small:hover .micro-icon {
    transform: scale(1.2) rotate(5deg);
}

/* Industry Carousel */
.industry-carousel {
    padding: 100px 0;
    margin-bottom: 40px;
    background-color: #fafafa;
    overflow: hidden;
}

.carousel-label {
    text-align: center;
    color: #86868b;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    margin-bottom: 40px;
}

.marquee {
    display: flex;
    width: 100%;
    overflow: hidden;
    mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
    -webkit-mask-image: linear-gradient(to right, transparent, black 15%, black 85%, transparent);
}

.marquee-content {
    display: flex;
    width: max-content;
    animation: scroll-loop 30s linear infinite;
}

.marquee-group {
    display: flex;
    flex-shrink: 0;
    gap: 100px;
    padding-right: 100px; 
}

.industry-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    min-width: 180px;
}

.ind-icon {
    width: 28px;
    height: 28px;
    stroke: #1d1d1f;
    opacity: 0.4;
    stroke-width: 1.5px;
    transition: all 0.3s ease;
}

.industry-item span {
    font-size: 1.4rem;
    font-weight: 600;
    color: #1d1d1f;
    opacity: 0.4;
    white-space: nowrap;
    letter-spacing: -0.01em;
    transition: all 0.3s ease;
}

.industry-item:hover .ind-icon,
.industry-item:hover span {
    opacity: 0.8;
    color: #5170ff;
}

@keyframes scroll-loop {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); } 
}

/* Software Detail Section */
.software-detail {
    padding: 100px 5%;
    background-color: #fafafa;
}

.detail-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8%;
    max-width: 1200px;
    margin: 0 auto 150px auto;
}

.detail-row.reverse {
    flex-direction: row-reverse;
}

.detail-video-wrapper {
    flex: 1.2;
    background: transparent;
    border-radius: 20px;
    overflow: hidden;
}

.detail-video {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.05);
}

.detail-text {
    flex: 1;
}

.detail-label {
    display: inline-block;
    color: #5170ff;
    font-weight: 700;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 15px;
}

.detail-text h2 {
    font-size: 2.8rem;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
    line-height: 1.1;
}

.detail-text p {
    font-size: 1.15rem;
    color: #86868b;
    line-height: 1.6;
    margin-bottom: 30px;
}

.detail-list {
    list-style: none;
}

.detail-list li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 12px;
    font-weight: 500;
    color: #1d1d1f;
}

.detail-list li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #5170ff;
    font-weight: 900;
}

/* Process Section Refresh */
.process-section .section-header {
    margin-bottom: 60px;
    position: relative;
    z-index: 5; /* Keeps it above the connecting line */
}

.process-section {
    padding: 120px 5%;
    background: #fafafa;
    position: relative;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); 
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2; /* Ensures cards are above the background line */
}

/* Connecting Line Background */
.process-grid::before {
    content: '';
    position: absolute;
    top: 60px; 
    left: 10%;
    right: 10%;
    height: 2px;
    background: linear-gradient(90deg, #5170ff 0%, #e5e5e7 100%);
    z-index: 1;
    opacity: 0.3;
}

.process-step {
    background: #fff;
    padding: 40px;
    border-radius: 24px;
    border: 1px solid #e5e5e7;
    transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    z-index: 3;
    opacity: 0; /* JS reveal will handle this */
    transform: translateY(30px);
}

/* Applying same reveal logic to steps as bento items */
.process-step.reveal {
    opacity: 1;
    transform: translateY(0);
}

.process-step:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.04);
    border-color: #5170ff;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: #5170ff;
    color: #fff;
    border-radius: 10px;
    font-size: 0.85rem;
    font-weight: 800;
    margin-bottom: 25px;
    box-shadow: 0 10px 20px rgba(81, 112, 255, 0.2);
}

.process-step h3 {
    margin-bottom: 15px;
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.process-step p {
    color: #86868b;
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Responsive Process Grid */
@media (max-width: 992px) {
    .process-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .process-grid::before {
        display: none; 
    }
}

/* Final CTA */
.cta-final {
    padding: 120px 5%;
    text-align: center;
    background: #fff;
}

.cta-container h2 {
    font-size: 3.5rem;
    letter-spacing: -0.02em;
    margin-bottom: 20px;
}

.cta-button {
    display: inline-block;
    padding: 18px 40px;
    background: #5170ff;
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: all 0.3s ease;
    margin-top: 30px;
}

.cta-button:hover {
    background: #3d59d4;
    transform: scale(1.05);
    box-shadow: 0 20px 40px rgba(81, 112, 255, 0.2);
}