:root {
    /* Colors (Dark Theme) */
    --primary-color: #2b97c5;
    --primary-dark: #0ea5e9;
    --primary-light: #7dd3fc;
    --accent-color: #00d2ff;
    --p-color: #dff0f8;
    --bg-white: var(--bg-main);
    --bg-light: var(--bg-card);
    --border-color: rgba(255, 255, 255, 0.08);
    --text-dark: #ffffff;
    --text-main-color: #f1f5f9;
    --text-light: #94a3b8;
    --glass-bg: rgba(22, 27, 34, 0.7);
    --glass-border: rgba(255, 255, 255, 0.1);

    /* Spacing */
    --container-width: 1200px;
    --header-height: 130px;
    --section-padding: 100px 0;

    /* Transitions */
    --transition-fast: 0.3s ease;
}

/* Base Dark Theme Enforcement */
html,
body,
main {
    background-color: var(--bg-main) !important;
    color: var(--text-main) !important;
}


/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 20px;
    margin-bottom: 100px;
    width: 100%;
}

/* ==========================================================================
   HOME OVERRIDES (restore after revert)
   - Make common.css container not draw page-edge "lines" on Home
   - Re-apply hero + solutions infographic + animations
   ========================================================================== */

:root {
    --hero-cta-height: 72px;
    /* Place image here if you add static/images/solutions_flow_ref.png */
    --flow-bg-image: url('../images/solutions_flow_ref.png');
}

main .container {
    background: transparent;
    box-shadow: none;
}

/* Hero (restore) */
.hero,
.hero-section {
    position: relative;
    height: auto;
    min-height: 600px;
    padding-top: 0px;
    /* Fixed Pixel Spacing: 
       - Exact same pixel distance on all screens
       - Increased to 560px to lower content significantly */
    padding-bottom: 100px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    overflow: hidden;
    /* contain grid background and particles */
    background-color: #000;
    background-image:
        linear-gradient(rgba(24, 11, 11, 0.2), rgba(0, 0, 0, 0.2)),
        url('../images/hero_abstract_bg.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle 500px at var(--hero-mouse-x, 50%) var(--hero-mouse-y, 50%),
            rgba(56, 189, 248, 0.12) 0%,
            transparent 100%);
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
    z-index: 1;
}

.hero:hover::after {
    opacity: 1;
}

.hero-bg {
    position: absolute;
    bottom: var(--hero-cta-height);
    left: 0;
    right: 0;
    width: 100%;
    height: 192px;
    /* 80% */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 0;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: stretch;
    max-width: 1200px;
    width: 100%;
    padding: 40px 20px;
    padding-bottom: calc(240px + var(--hero-cta-height));
}

/* Dynamic Hero Animations */
@keyframes heroTextSlideUp {
    0% {
        opacity: 0;
        transform: translateY(40px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes heroImageFloat {
    0% {
        transform: translateY(0) rotate(0deg);
    }

    25% {
        transform: translateY(-8px) rotate(0.5deg);
    }

    50% {
        transform: translateY(-15px) rotate(0deg);
    }

    75% {
        transform: translateY(-8px) rotate(-0.5deg);
    }

    100% {
        transform: translateY(0) rotate(0deg);
    }
}

@keyframes cinematicGlow {
    0% {
        opacity: 0.4;
        filter: blur(50px) brightness(1);
        transform: translate(-50%, -50%) scale(1);
    }

    50% {
        opacity: 0.7;
        filter: blur(70px) brightness(1.3);
        transform: translate(-50%, -50%) scale(1.1);
    }

    100% {
        opacity: 0.4;
        filter: blur(50px) brightness(1);
        transform: translate(-50%, -50%) scale(1);
    }
}

@keyframes heroImageEntrance {
    0% {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
        filter: blur(10px);
    }

    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

@keyframes cinematicSheen {
    0% {
        transform: translateX(-200%) skewX(-30deg);
        opacity: 0;
    }

    20% {
        opacity: 0.8;
    }

    50% {
        opacity: 0;
    }

    100% {
        transform: translateX(200%) skewX(-30deg);
        opacity: 0;
    }
}

@keyframes particleDrift {
    0% {
        transform: translate(0, 0) scale(1);
        opacity: 0;
    }

    20% {
        opacity: 0.6;
    }

    80% {
        opacity: 0.6;
    }

    100% {
        transform: translate(var(--dx), var(--dy)) scale(0.5);
        opacity: 0;
    }
}

@keyframes gridEntrance {
    0% {
        opacity: 0;
        transform: perspective(1000px) rotateX(60deg) scale(0.8);
    }

    100% {
        opacity: 0.15;
        transform: perspective(1000px) rotateX(60deg) scale(1);
    }
}

@keyframes godRaysSweep {
    0% {
        transform: rotate(-45deg) translateX(-50%);
        opacity: 0;
    }

    20% {
        opacity: 0.15;
    }

    80% {
        opacity: 0.15;
    }

    100% {
        transform: rotate(-45deg) translateX(50%);
        opacity: 0;
    }
}

@keyframes textEnergyPulse {

    0%,
    100% {
        text-shadow: 0 0 10px rgba(0, 210, 255, 0.5), 0 0 20px rgba(0, 210, 255, 0.3);
        transform: scale(1);
    }

    50% {
        text-shadow: 0 0 20px rgba(0, 210, 255, 0.8), 0 0 40px rgba(0, 210, 255, 0.5);
        transform: scale(1.02);
    }
}

@keyframes bokehMove {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(var(--bx), var(--by));
    }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 900;
    line-height: 1.2;
    margin-top: 20px;
    margin-bottom: 30px;
    text-align: center;
    color: #ffffff;
    position: relative;
    z-index: 10;
    letter-spacing: 2px;
    background: linear-gradient(90deg, #fff, #00d2ff, #fff);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation:
        heroTextSlideUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) forwards,
        textEnergyPulse 4s ease-in-out infinite;
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.5));
}

/* God Rays Layer */
.god-rays {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.ray {
    position: absolute;
    top: -50%;
    left: 10%;
    width: 200px;
    height: 200%;
    background: linear-gradient(to right, transparent, rgba(0, 210, 255, 0.05), transparent);
    transform: rotate(-45deg);
    animation: godRaysSweep 15s linear infinite;
}

.ray:nth-child(2) {
    left: 40%;
    animation-delay: -5s;
    width: 300px;
}

.ray:nth-child(3) {
    left: 70%;
    animation-delay: -10s;
    width: 150px;
}

/* Bokeh Depth Layer */
.bokeh-layer {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 2;
}

.bokeh {
    position: absolute;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(0, 210, 255, 0.2) 0%, transparent 70%);
    filter: blur(20px);
    will-change: transform;
}

.hero-copy {
    max-width: 560px;
    margin-top: 10px;
    margin-bottom: 20px;
    margin-left: 60px;
}

.hero-desc {
    font-size: 1.3rem;
    font-weight: 500;
    margin-bottom: 40px;
    text-align: left;
    max-width: 560px;
    line-height: 1.8;
    color: var(--text-light);
    border-left: 6px solid #0ea5e9;
    padding-left: 26px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    margin-left: 50px;
    opacity: 0;
    /* Start hidden for animation */
    animation: heroTextSlideUp 1s cubic-bezier(0.2, 0.8, 0.2, 1) 0.3s forwards;
}

.hero-media {
    position: absolute;
    left: 0;
    right: 0;
    bottom: calc(var(--hero-cta-height));
    width: 100%;
    display: flex;
    justify-content: flex-end;
    align-items: flex-end;
    z-index: 5;
    /* Elevated for cinematic layering */
    pointer-events: none;
    padding-right: 24px;
    transform: translateY(120px);
    transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
    will-change: transform;
    /* Optimization for parallax */
}

/* Cinematic Tech Grid Base */
.hero-grid-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 200%;
    height: 100%;
    background-image:
        linear-gradient(rgba(0, 210, 255, 0.15) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 210, 255, 0.15) 1px, transparent 1px);
    background-size: 60px 60px;
    transform: perspective(1000px) rotateX(60deg);
    transform-origin: center;
    pointer-events: none;
    z-index: 0;
    opacity: 0;
    mask-image: radial-gradient(circle at center, black 0%, transparent 70%);
    animation: gridEntrance 2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.data-particle {
    position: absolute;
    background: radial-gradient(circle at 35% 35%, #ffffff 0%, #cbd5e1 40%, #475569 100%);
    border-radius: 50%;
    /* Spherical shape */

    transform-origin: center;
    pointer-events: none;
    z-index: 4;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.6);
    filter: blur(1.5px);
    /* Added blur effect */
    opacity: 0;
    will-change: transform, opacity;
}



@media (max-width: 768px) {
    .data-particle {
        display: none !important;
    }
}

.hero-media-img {
    width: auto;
    max-width: 100%;
    height: auto;
    max-height: 374px;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 20px 40px rgba(0, 0, 0, 0.4));
    /* transition: transform 0.5s ease; Removed to avoid conflict with animation */
    animation: heroImageEntrance 1.2s cubic-bezier(0.2, 0.8, 0.2, 1) forwards,
        heroImageFloat 6s ease-in-out 1.2s infinite;
}

/* Hover effect removed to prioritize float animation */
/* .hero-media:hover .hero-media-img {
    transform: translateY(-10px) rotate(1deg);
} */

/* Notebook image reveal animation removed per request */
.hero-media-blinds {
    position: relative;
    display: inline-block;
}

.hero-media-blinds::before {
    content: '';
    position: absolute;
    top: 55%;
    left: 50%;
    width: 140%;
    /* Extra wide for cinematic depth */
    height: 100%;
    background: radial-gradient(circle at center,
            rgba(255, 255, 255, 0.05) 0%,
            rgba(200, 220, 255, 0.02) 45%,
            transparent 75%);
    filter: blur(80px);
    transform: translate(-50%, -50%);
    z-index: 0;
    pointer-events: none;
    animation: heroImageEntrance 1.5s cubic-bezier(0.2, 0.8, 0.2, 1) forwards,
        cinematicGlow 8s ease-in-out 1.5s infinite;
}

.hero-media-blinds::after {
    content: '';
    position: absolute;
    top: 60%;
    left: 60%;
    /* Offset light source for lens-flare feel */
    width: 60%;
    height: 40%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    filter: blur(30px);
    transform: translate(-50%, -50%);
    z-index: 0;
    pointer-events: none;
    mix-blend-mode: overlay;
    animation: heroImageEntrance 1.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}

.hero-media-blinds::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent 45%, rgba(255, 255, 255, 0.6) 50%, transparent 55%);
    z-index: 2;
    pointer-events: none;
    mix-blend-mode: overlay;
    animation: cinematicSheen 4s ease-in-out 3s infinite;
    /* Glass glint / sheen */
    opacity: 0;
}

.hero-media-blinds .hero-media-img {
    opacity: 1;
    transform: none;
    z-index: 1;
    position: relative;
    filter: drop-shadow(0 40px 80px rgba(0, 0, 0, 0.8));
    transition: transform 0.1s ease-out;
    /* Smooth mouse reaction */
}


@media (prefers-reduced-motion: reduce) {

    .hero-media-blinds::before,
    .hero-media-blinds .hero-media-img {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
        filter: none !important;
    }
}

/* 데스크톱에서 CTA 버튼 영역을 250px 아래로 */
@media (min-width: 769px) {

    /* 아래로 내린 만큼 다음 섹션과 겹치지 않도록 공간 확보 */
    .hero.hero-section {
        padding-bottom: 40px;
        /* 데스크톱: 버튼-다음 섹션 간격 축소 */
    }

    /* "현장 중심의 … 컨설팅 솔루션"부터(=hero-content) 아래로 250px 이동 */
    .hero-content {
        padding-top: calc(40px + 150px);
    }

    .hero-cta-bar {
        /* NOTE: home.html fade-in JS sets inline `transform`, so don't use transform for layout here */
        transform: none !important;
        bottom: 0px !important;
        /* 데스크톱에서 CTA 버튼 영역을 위로 80px 이동 */
    }

    /* 데스크톱: "컨솔 솔루션이란?" 섹션 상단 여백 추가 축소 */
    #solutions.section {
        padding-top: 0;
        margin-top: -10px;
    }
}

.hero-cta-bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: var(--hero-cta-height);
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(22, 27, 34, 0.8);
    backdrop-filter: blur(10px);
    border-top: 1px solid var(--border-main);
    z-index: 3;
}

.hero-btns {
    display: flex;
    gap: 20px;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 22px;
    border-radius: 10px;
    font-weight: 800;
    text-decoration: none;
    transition: transform 260ms cubic-bezier(.2, .8, .2, 1), box-shadow 260ms cubic-bezier(.2, .8, .2, 1), background-color 260ms ease;
    background: transparent;
    color: #ffffff;
    border: none;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}

.hero-cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(212, 175, 55, 0) 0%, rgba(0, 170, 255, 0.10) 40%, rgba(212, 175, 55, 0) 70%);
    transform: translateX(-120%);
    transition: transform 420ms ease;
    pointer-events: none;
}

.hero-cta:hover {
    transform: translateY(-4px) scale(1.05);
    box-shadow: 0 20px 40px rgba(0, 210, 255, 0.2);
    background-color: rgba(255, 255, 255, 0.08);
}

.hero-cta:hover::before {
    transform: translateX(120%);
}

.hero-cta i {
    transition: transform 0.3s ease;
}

.hero-cta:hover i {
    transform: rotate(15deg) scale(1.2);
}

/* Solutions infographic (restore) */
.solutions-wrap {
    display: grid;
    grid-template-columns: 360px 1fr;
    gap: 28px;
    margin-top: 40px;
    align-items: start;
}

.solutions-side {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 35px 30px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.solutions-side-title {
    font-weight: 900;
    font-size: 1.1rem;
    color: var(--primary-dark);
    margin-bottom: 16px;
}

.solutions-timeline {
    list-style: none;
    padding: 0;
    margin: 0;
    position: relative;
}

.solutions-timeline::before {
    content: '';
    position: absolute;
    left: 12px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: rgba(56, 189, 248, 0.2);
}

.solutions-timeline li {
    display: grid;
    grid-template-columns: 24px 1fr;
    gap: 14px;
    padding: 14px 0;
}

.solutions-timeline .dot {
    width: 12px;
    height: 12px;
    margin-top: 6px;
    border-radius: 50%;
    background: var(--primary-color);
    box-shadow: 0 0 0 5px rgba(0, 51, 102, 0.12);
    z-index: 1;
    justify-self: center;
}

.solutions-timeline .t {
    font-weight: 900;
    color: var(--primary-color);
    margin-bottom: 4px;
}

.solutions-timeline .d {
    color: var(--text-light);
    font-size: 0.95rem;
    line-height: 1.55;
}

.solutions-main {
    display: grid;
    gap: 14px;
}

.solution-panel {
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.solution-panel::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle 300px at var(--panel-mouse-x, 50%) var(--panel-mouse-y, 50%),
            rgba(255, 255, 255, 0.08) 0%,
            transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 0;
}

.solution-panel:hover::before {
    opacity: 1;
}

.solution-panel::after {
    content: '';
    position: absolute;
    inset: -1px;
    background: linear-gradient(90deg, transparent, var(--primary-dark), transparent);
    z-index: 0;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.solution-panel:hover::after {
    opacity: 0.2;
}

.solution-panel>* {
    position: relative;
    z-index: 1;
}

.solution-panel summary {
    cursor: pointer;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 18px 18px;
    font-weight: 900;
    color: var(--primary-color);
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid var(--border-main);
    transition: transform 220ms cubic-bezier(.2, .8, .2, 1), box-shadow 220ms cubic-bezier(.2, .8, .2, 1), background-color 220ms ease;
}

.solution-panel summary::-webkit-details-marker {
    display: none;
}

.solution-panel summary::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(120deg, rgba(212, 175, 55, 0) 0%, rgba(0, 170, 255, 0.10) 40%, rgba(212, 175, 55, 0) 70%);
    transform: translateX(-120%);
    transition: transform 420ms ease;
    pointer-events: none;
}

.solution-panel summary:hover {
    background-color: rgba(0, 170, 255, 0.04);
    box-shadow: 0 12px 26px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}

.solution-panel summary:hover::before {
    transform: translateX(120%);
}

.solution-panel summary:focus-visible {
    outline: 3px solid rgba(0, 170, 255, 0.35);
    outline-offset: 2px;
}

.solution-panel summary::after {
    content: '';
    margin-left: auto;
    width: 18px;
    height: 18px;
    background: currentColor;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E") center/contain no-repeat;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3Cpolyline%3E%3C/svg%3E") center/contain no-repeat;
    opacity: 0.6;
    transform: rotate(-90deg);
    transition: transform var(--transition-fast);
}

.solution-panel[open] summary::after {
    transform: rotate(0deg);
}

.solution-panel .ico {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: rgba(56, 189, 248, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    flex: 0 0 auto;
    transition: transform 220ms cubic-bezier(.2, .8, .2, 1), background-color 220ms ease;
}

.solution-panel summary:hover .ico {
    transform: scale(1.05);
    background: rgba(56, 189, 248, 0.2);
}

.solution-panel .ico i {
    width: 22px;
    height: 22px;
}

.solution-list {
    margin: 0;
    padding: 0 18px 18px 18px;
    list-style: none;
    display: grid;
    gap: 10px;
}

.solution-list li {
    position: relative;
    padding-left: 18px;
    color: var(--text-light);
    line-height: 1.55;
}

.solution-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.55em;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent-color);
}

/* Gold/Navy flow (restore) */
/* Modern Solutions Flow Diagram */
.solutions-flow {
    margin-top: 60px;
    border-radius: 32px;
    padding: 60px 20px;
    background:
        radial-gradient(circle at 50% 0%, rgba(56, 189, 248, 0.15) 0%, transparent 70%),
        linear-gradient(135deg, #0a0c10 0%, #0f172a 100%);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.solutions-flow::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.01) 0px, rgba(255, 255, 255, 0.01) 1px, transparent 1px, transparent 10px);
    opacity: 0.5;
    pointer-events: none;
}

.flow-diagram {
    width: 100%;
    max-width: 700px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 40px;
    position: relative;
    z-index: 2;
}

/* Supply Node (Top) */
.flow-top {
    background: linear-gradient(135deg, #fde047 0%, #eab308 100%);
    color: #000;
    padding: 14px 28px;
    border-radius: 999px;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 12px;
    box-shadow: 0 10px 30px rgba(234, 179, 8, 0.3);
    position: relative;
}

.flow-top::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    width: 2px;
    height: 40px;
    background: linear-gradient(to bottom, #eab308, rgba(234, 179, 8, 0.2));
    transform: translateX(-50%);
}

/* Consultant Node (Middle) */
.flow-mid {
    width: 160px;
    height: 160px;
    background: radial-gradient(circle at center, #1e293b 0%, #0f172a 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(56, 189, 248, 0.3);
    position: relative;
    box-shadow: 0 0 40px rgba(56, 189, 248, 0.15);
    transition: all 0.4s ease;
}

.flow-mid:hover {
    transform: scale(1.05);
    border-color: var(--primary-color);
    box-shadow: 0 0 60px rgba(56, 189, 248, 0.3);
}

.flow-mid-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: #fff;
    font-weight: 800;
    font-size: 1.15rem;
}

.flow-mid::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    width: 2px;
    height: 40px;
    background: linear-gradient(to bottom, rgba(56, 189, 248, 0.3), transparent);
    transform: translateX(-50%);
}

/* Branching line for Bottom Nodes */
.flow-branch {
    display: flex;
    gap: 30px;
    position: relative;
    width: 100%;
    justify-content: center;
}

.flow-branch::before {
    content: '';
    position: absolute;
    top: -20px;
    left: 50%;
    width: 300px;
    height: 2px;
    background: rgba(56, 189, 248, 0.15);
    transform: translateX(-50%);
}

/* Business Nodes (Bottom) */
.flow-leaf {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 18px 32px;
    border-radius: 20px;
    color: #fde047;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.flow-leaf:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-5px);
    border-color: rgba(253, 224, 71, 0.5);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.flow-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.9;
}

.flow-caption {
    margin-top: 30px;
    color: var(--text-light);
    font-weight: 700;
    font-size: 1.9rem;
    opacity: 1;
}


/* Automation box + hover animation (restore) */
.automation-box {
    margin-top: 36px;
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px 30px;
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
}

.automation-title {
    font-size: 1.2rem;
    font-weight: 900;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 18px;
}

.automation-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.automation-item {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border-main);
    border-radius: 12px;
    padding: 12px 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.03);
    position: relative;
    overflow: hidden;
    transform: translateY(0) scale(1);
    transition: transform 260ms cubic-bezier(.2, .8, .2, 1), box-shadow 260ms cubic-bezier(.2, .8, .2, 1), border-color 260ms ease;
    cursor: pointer;
}

.automation-item:hover {
    background: rgba(56, 189, 248, 0.1);
    border-color: rgba(56, 189, 248, 0.4);
    box-shadow: 0 0 20px rgba(56, 189, 248, 0.3);
    transform: translateY(-2px);
}

.automation-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(circle 100px at var(--auto-mouse-x, 50%) var(--auto-mouse-y, 50%),
            rgba(56, 189, 248, 0.15) 0%,
            transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
    pointer-events: none;
    z-index: 1;
}

.automation-item:hover::after {
    opacity: 1;
}

.automation-item>* {
    position: relative;
    z-index: 2;
}

.automation-item::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 14px;
    background: conic-gradient(from 0deg, rgba(212, 175, 55, 0.0), rgba(212, 175, 55, 0.85), rgba(0, 170, 255, 0.65), rgba(212, 175, 55, 0.0));
    opacity: 0;
    transition: opacity 220ms ease;
    pointer-events: none;
    z-index: 0;
    -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    -webkit-mask-composite: xor;
    mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
    mask-composite: exclude;
    padding: 2px;
}

.automation-item::after {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(220px 120px at 30% 20%, rgba(0, 170, 255, 0.14) 0%, rgba(0, 170, 255, 0) 65%);
    opacity: 0;
    transition: opacity 220ms ease;
    pointer-events: none;
    z-index: 0;
}

.automation-item>* {
    position: relative;
    z-index: 1;
}

.automation-item:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.10);
    border-color: rgba(0, 170, 255, 0.55);
}

.automation-item:hover::before {
    opacity: 1;
    animation: automationBorderSpin 1.3s linear infinite;
}

.automation-item:hover::after {
    opacity: 1;
}

.automation-item .num {
    font-weight: 900;
    color: var(--primary-color);
    min-width: 28px;
}

.automation-item:hover .num {
    color: var(--accent-color);
}

.automation-item .name {
    font-weight: 700;
    color: var(--text-main);
}

@keyframes automationBorderSpin {
    to {
        transform: rotate(360deg);
    }
}

/* ==========================================================================
   RESPONSIVE & FINAL THEME OVERRIDES
   ========================================================================== */

/* 1. Mobile & Tablet Adjustments */
@media (max-width: 768px) {
    .section {
        padding: 60px 0;
    }

    .hero.hero-section {
        min-height: auto;
        height: auto !important;
        padding-top: 150px !important;
        padding-bottom: 0px !important;
        display: flex;
        flex-direction: column;
        justify-content: flex-start;
        align-items: center;
    }

    .hero-content {
        padding-top: 0 !important;
        padding-bottom: 0 !important;
        margin-top: 0 !important;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .hero-title {
        font-size: 2.2rem !important;
        margin-top: 0 !important;
        margin-bottom: 10px !important;
    }

    .hero-copy {
        margin-left: 0 !important;
        width: 100%;
    }

    .hero-desc {
        font-size: 1.1rem !important;
        padding-left: 0 !important;
        border-left: none !important;
        text-align: center !important;
        margin-bottom: 30px !important;
    }

    .hero-media {
        position: relative !important;
        top: auto !important;
        bottom: auto !important;
        margin-top: -240px !important;
        padding-right: 0 !important;
        justify-content: center !important;
    }

    .hero-media-img {
        margin-top: 100px !important;
        max-height: 140px !important;
    }

    .hero-cta-bar {
        position: relative !important;
        top: auto !important;
        bottom: auto !important;
        margin-top: 20px !important;
        background: var(--glass-bg) !important;
        backdrop-filter: blur(10px);
        width: 100% !important;
        height: auto !important;
        padding: 20px 0 !important;
        border-top: 1px solid var(--glass-border) !important;
    }

    .hero-btns {
        gap: 12px !important;
    }

    .hero-cta {
        padding: 10px 16px !important;
        font-size: 0.9rem !important;
    }

    .solutions-wrap {
        grid-template-columns: 1fr;
    }

    .automation-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .checklist-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.8rem !important;
    }

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

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

/* 2. Global Dark Theme Enforcement */
.section {
    background-color: var(--bg-main) !important;
    color: var(--text-main) !important;
    position: relative;
    z-index: 1;
}

/* Fix for containers in home to be transparent and not light */
main .container {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

.bg-white,
.bg-light,
.bg-transparent {
    background-color: transparent !important;
}

/* Ensure no shadows or borders reveal white */
section,
div,
main {
    box-shadow: none !important;
    border-color: var(--border-main) !important;
}


/* 3. Hero CTA Bar Overrides (Desktop) */
@media (min-width: 769px) {
    .hero-cta-bar {
        background: var(--glass-bg) !important;
        border-top: 1px solid var(--glass-border) !important;
        backdrop-filter: blur(12px);
        box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.4);
    }

    .hero-cta {
        background: rgba(255, 255, 255, 0.03) !important;
        border: 1px solid var(--glass-border) !important;
    }

    .hero-cta:hover {
        background: var(--primary-color) !important;
        color: #ffffff !important;
    }

    /* Move solutions section down to avoid any overlap or visual density */
    #solutions.section {
        padding-top: 60px !important;
    }
}

/* Cleanup: Utilities & Animations */
.text-center {
    text-align: center;
}

.fade-in {
    opacity: 1;
}

/* Fallback if JS fails */

/* ADJUSTMENT: Match Footer Spacing to About Page (40px) */
/* 1. Reset Footer Top Margin */
main~.site-footer {
    margin-top: 0 !important;
    background: #000000 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

/* 2. Specific spacing for the last section on Home */
#solutions.section {
    padding-bottom: 0 !important;
}

#solutions .container {
    margin-bottom: 50px !important;
    /* Force 40px gap */
}

/* ========================================================================
   MOBILE: Disable Hero Blur Effects
   ======================================================================== */
@media (max-width: 768px) {

    /* Remove blur/backdrop-filter from hero */
    .hero::after {
        display: none !important;
    }

    /* Hide bokeh blur effects */
    .bokeh-layer,
    .bokeh {
        display: none !important;
    }

    /* Hide god-rays */
    .god-rays,
    .ray {
        display: none !important;
    }

    /* Hide particles (which have blur) */
    .data-particle,
    #particle-container {
        display: none !important;
    }

    /* Hide grid background */
    .hero-grid-bg {
        display: none !important;
    }

    /* Remove glow/blur effects from notebook image */
    .hero-media-blinds::before,
    .hero-media-blinds::after {
        display: none !important;
    }

    /* Remove blur from image */
    .hero-media-img {
        filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.3)) !important;
    }

    /* Remove backdrop-filter from CTA bar */
    .hero-cta-bar {
        backdrop-filter: none !important;
    }
}

/* Mobile: Center Hero Description and Add Spacing (max-width: 1000px) */
@media (max-width: 1000px) {
    .hero-content {
        padding-left: 40px !important;
        padding-right: 40px !important;
    }

    .hero-copy {
        margin-left: 0 !important;
        margin-right: 0 !important;
        text-align: center !important;
        max-width: 100% !important;
        padding: 0;
        /* Removing inner padding since container has 40px */
    }

    .hero-desc {
        text-align: center !important;
        border-left: none !important;
        padding-left: 0 !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
        max-width: 100% !important;
    }
}