:root {
    --bg-color: #05060a;
    --halo-color: 160, 90, 255;
    --text-main: #FFFFFF;
    --font-heading: 'Outfit', sans-serif;
}

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

html,
body {
    background-color: var(--bg-color);
    color: var(--text-main);
    font-family: var(--font-heading);
    min-height: 100%;
    width: 100%;
    overflow-x: hidden;
    overflow-y: auto;
}

/* Main container */
.container {
    width: 100%;
    min-height: 100vh;
    padding: 4rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    position: relative;
    overflow: hidden;
    isolation: isolate;
}

/* Halo */
.container::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: -1;
    background: radial-gradient(circle at 15% 50%,
            rgba(var(--halo-color), 0.55) 0%,
            rgba(var(--halo-color), 0.25) 18%,
            rgba(var(--halo-color), 0.10) 35%,
            rgba(var(--halo-color), 0.00) 60%);
    filter: blur(45px);
    transform: translate3d(0, 0, 0);
}

/* Vignette */
.container::after {
    content: "";
    position: absolute;
    inset: -20%;
    pointer-events: none;
    z-index: -1;
    background: radial-gradient(circle at 50% 50%,
            rgba(255, 255, 255, 0.02) 0%,
            rgba(0, 0, 0, 0.0) 35%,
            rgba(0, 0, 0, 0.65) 75%,
            rgba(0, 0, 0, 0.90) 100%);
}

/* HERO GRID */
.hero {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 4rem;
    width: 100%;
    max-width: 1400px;
    align-items: center;

    justify-items: center;
    /* center items in each column */
}

/* Left column */
.hero-content {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    justify-self: start;
    /* keep text aligned left */
}

.title {
    font-size: clamp(3rem, 8vw, 7rem);
    font-weight: 900;
    line-height: 0.9;
    letter-spacing: -0.02em;
    text-transform: uppercase;
}

.outline {
    -webkit-text-stroke: 1px var(--text-main);
    color: transparent;
}

.tagline {
    font-size: 0.8rem;
    letter-spacing: 0.2em;
    line-height: 1.8;
    opacity: 0.8;
    max-width: 500px;
    font-weight: 400;
    text-transform: uppercase;
}

/* Right column */
.hero-visual {
    width: 100%;
    max-width: 550px;
    aspect-ratio: 1;
    position: relative;
    border-radius: 2rem;
    overflow: hidden;
    background: radial-gradient(circle at center, rgba(203, 148, 126, 0.05) 0%, transparent 70%);
}

/* Spline container */
#spline-container {
    width: 100%;
    height: 100%;
}

#canvas3d,
#spline-container iframe {
    width: 100% !important;
    height: 100% !important;
    border-radius: 2rem;
}

/* Tablet */
@media (max-width: 1024px) {
    .hero {
        grid-template-columns: 1fr;
        gap: 3rem;
        text-align: center;
    }

    .hero-content {
        align-items: center;
        justify-self: center;
    }

    .tagline {
        margin: 0 auto;
    }

    .hero-visual {
        max-width: 600px;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .container {
        padding: 4rem 1.5rem;
    }

    .title {
        font-size: clamp(2.5rem, 12vw, 4rem);
    }

    .tagline {
        font-size: 0.7rem;
        letter-spacing: 0.15em;
    }
}

/* ENGINEERING SECTION */
.section {
    padding: 8rem 2rem;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 900;
    margin-bottom: 4rem;
    text-transform: uppercase;
    line-height: 1.1;
}

.accent {
    background: linear-gradient(to right, #fff, rgba(var(--halo-color), 0.8));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.card {
    background: rgba(255, 255, 255, 0.03);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 2rem;
    padding: 3rem 2.5rem;
    position: relative;
    transition: all 0.4s cubic-bezier(0.23, 1, 0.32, 1);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    overflow: hidden;
}

/* Halo/Shadow behind card */
.card::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: radial-gradient(circle at 50% 0%,
            rgba(var(--halo-color), 0.15) 0%,
            transparent 70%);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.card:hover {
    transform: translateY(-10px);
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(var(--halo-color), 0.3);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.card:hover::before {
    opacity: 1;
}

.card-icon {
    width: 60px;
    height: 60px;
    margin-bottom: 0.5rem;
}

.card-icon img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(var(--halo-color), 0.5));
}

.card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
}

.card p {
    font-size: 0.9rem;
    line-height: 1.7;
    opacity: 0.7;
    font-weight: 400;
}

/* Specific Halo Colors per card type */
.card:nth-child(1):hover {
    --halo-color: 160, 90, 255;
}

.card:nth-child(2):hover {
    --halo-color: 0, 242, 255;
}

.card:nth-child(3):hover {
    --halo-color: 0, 140, 255;
}

/* Responsive adjustments for section */
@media (max-width: 1024px) {
    .section {
        padding: 6rem 1.5rem;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .cards {
        gap: 2rem;
    }
}

/* FOOTER */
.footer {
    padding: 4rem 2rem;
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    opacity: 0.5;
    transition: opacity 0.3s ease;
}

.footer:hover {
    opacity: 0.8;
}

.footer address {
    font-style: normal;
    font-size: 0.75rem;
    line-height: 1.6;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.footer p {
    margin-top: 0.5rem;
}

.footer a {
    color: inherit;
    text-decoration: none;
    border-bottom: 1px solid transparent;
    transition: border-color 0.3s ease;
}

.footer a:hover {
    border-color: rgba(var(--halo-color), 0.5);
}