@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;700&family=Syne:wght@700;800&display=swap');

html { scroll-behavior: smooth; }

:focus-visible { outline: 2px solid var(--accent-secondary); outline-offset: 3px; }

.top-bar { display: none; }

:root {
    --bg-main: #06060c;
    --bg-surface: #121220;
    --accent-primary: #7000ff;
    --accent-secondary: #9d00ff;
    --accent-glow: rgba(112, 0, 255, 0.4);
    --text-primary: #ffffff;
    --text-secondary: #b0b0c5;
    --line-color: #2a2a3e;
    --nav-width: 80px;
}

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

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: 'Inter', sans-serif;
    overflow-x: hidden;
    display: flex;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(112, 0, 255, 0.05) 0%, transparent 40%),
        radial-gradient(circle at 80% 70%, rgba(157, 0, 255, 0.05) 0%, transparent 40%);
}

.side-nav {
    width: var(--nav-width);
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    background: var(--bg-surface);
    border-right: 1px solid var(--line-color);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
    padding: 2rem 0;
    z-index: 1000;
}

.nav-logo-img {
    width: 40px;
    height: 40px;
    object-fit: contain;
    margin-bottom: 1rem;
    filter: drop-shadow(0 0 10px var(--accent-glow));
}

.nav-logo-text {
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1.2rem;
    color: var(--accent-primary);
    writing-mode: vertical-rl;
    text-transform: uppercase;
    text-decoration: none;
    letter-spacing: 0.2em;
    transform: rotate(180deg);
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    list-style: none;
}

.nav-menu a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    writing-mode: vertical-rl;
    transform: rotate(180deg);
    transition: all 0.3s;
    letter-spacing: 0.1em;
}

.nav-menu a:hover {
    color: var(--accent-primary);
    text-shadow: 0 0 10px var(--accent-glow);
}

main {
    margin-left: var(--nav-width);
    width: calc(100% - var(--nav-width));
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 4rem;
}

section {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: center;
    position: relative;
    padding: 10rem 0;
}

.section-title {
    font-family: 'Syne', sans-serif;
    font-size: 4rem;
    text-transform: uppercase;
    margin-bottom: 4rem;
    color: var(--text-primary);
    position: relative;
    display: inline-block;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -1rem;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent-primary);
}

.hero {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 6rem;
    align-items: center;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: linear-gradient(rgba(112, 0, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(112, 0, 255, 0.03) 1px, transparent 1px);
    background-size: 40px 40px;
    z-index: -1;
}

.hero-text h1 {
    font-family: 'Syne', sans-serif;
    font-size: clamp(3rem, 5.6vw, 8rem);
    line-height: 0.85;
    white-space: nowrap;
    text-transform: uppercase;
    margin-bottom: 2rem;
    position: relative;
    color: transparent;
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.2);
}

.hero-text h1 span {
    color: var(--text-primary);
    -webkit-text-stroke: 0;
    text-shadow: 0 0 30px rgba(112, 0, 255, 0.4);
}

.hero-text p {
    font-size: 1.1rem;
    color: var(--text-secondary);
    max-width: 500px;
    margin-bottom: 4rem;
    line-height: 1.8;
}

.hero-image {
    width: 100%;
    height: clamp(600px, 82vh, 820px);
    background: #08080c;
    border-left: 2px solid var(--accent-primary);
    position: relative;
    overflow: hidden;
    box-shadow: -20px 0 50px rgba(0, 0, 0, 0.5);
}

.hero-image::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(112, 0, 255, 0.05));
}

.cta-group {
    display: flex;
    gap: 2rem;
}

.btn-forge {
    padding: 1.5rem 3rem;
    background: var(--accent-primary);
    color: #fff;
    text-decoration: none;
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    clip-path: polygon(5% 0, 100% 0, 95% 100%, 0 100%);
    transition: all 0.3s;
    display: inline-block;
}

.btn-forge:hover {
    background: var(--accent-secondary);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px var(--accent-glow);
}

.btn-ghost {
    padding: 1.5rem 3rem;
    border: 1px solid var(--line-color);
    color: var(--text-primary);
    text-decoration: none;
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    clip-path: polygon(5% 0, 100% 0, 95% 100%, 0 100%);
    transition: all 0.3s;
    display: inline-block;
}

.btn-ghost:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--accent-primary);
}

.features-layout {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    gap: 2rem;
}

.feature-block {
    grid-column: span 6;
    padding: 4rem;
    background: var(--bg-surface);
    border: 1px solid var(--line-color);
    position: relative;
    transition: all 0.4s;
}

.feature-block:hover {
    border-color: var(--accent-primary);
    transform: scale(1.02);
}

.feature-block.wide {
    grid-column: span 12;
}

.feature-block .num {
    font-family: 'Syne', sans-serif;
    font-size: 4rem;
    color: rgba(112, 0, 255, 0.15);
    position: absolute;
    top: 2rem;
    right: 2rem;
}

.feature-block h3 {
    font-family: 'Syne', sans-serif;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-transform: uppercase;
    color: var(--accent-primary);
}

.feature-block p {
    color: var(--text-secondary);
    font-size: 1rem;
    max-width: 450px;
}

.feature-block.wide p {
    max-width: 640px;
}

.feature-block .lines {
    font-size: 1.05rem;
    line-height: 1.6;
}

.feature-block .lines span {
    display: block;
    margin-bottom: 0.75rem;
}

.feature-block .lines span:last-child {
    margin-bottom: 0;
}

.feature-block .lines .lead {
    color: var(--text-primary);
    font-weight: 500;
}

.feature-link {
    color: var(--accent-primary);
    text-decoration: none;
    font-weight: 700;
    border-bottom: 1px dashed var(--accent-primary);
    transition: all 0.3s;
}

.feature-link:hover {
    color: var(--accent-secondary);
    border-bottom-style: solid;
}

.demo-wrap {
    width: 100%;
    background: #040408;
    border: 1px solid var(--line-color);
    padding: 2rem;
    position: relative;
}

.demo-frame {
    aspect-ratio: 16/9;
    background: #020205;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-primary);
    font-family: 'Syne', sans-serif;
    font-size: 1.5rem;
    text-transform: uppercase;
    border: 1px dashed rgba(112, 0, 255, 0.2);
    box-shadow: inset 0 0 50px rgba(0, 0, 0, 0.5);
}

.team-layout {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1px;
    background: var(--line-color);
}

.team-member {
    background: var(--bg-main);
    padding: 4rem 2rem;
    text-align: center;
    transition: background 0.3s;
}

.team-member:hover {
    background: var(--bg-surface);
}

.team-member h3 {
    font-family: 'Syne', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

.team-member h3 a {
    color: inherit;
    text-decoration: none;
}

.team-member h3 a:hover {
    color: var(--accent-secondary);
}

.team-member p {
    color: var(--accent-primary);
    font-weight: 700;
    text-transform: uppercase;
    font-size: 0.8rem;
    letter-spacing: 0.1em;
}

footer.container {
    padding: 3rem 4rem 3rem;
    border-top: 1px solid var(--line-color);
    background: linear-gradient(to bottom, rgba(112, 0, 255, 0.03), transparent);
}

.footer-main {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 4rem;
}

.footer-brand {
    max-width: 400px;
}

.footer-logo {
    font-family: 'Syne', sans-serif;
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent-primary);
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.footer-brand p {
    color: var(--text-secondary);
    font-size: 1rem;
    line-height: 1.6;
}

.footer-nav {
    display: flex;
    gap: 6rem;
}

.nav-col h4 {
    font-family: 'Syne', sans-serif;
    font-size: 0.8rem;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    letter-spacing: 0.1em;
}

.nav-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.nav-col a {
    color: var(--text-primary);
    text-decoration: none;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s;
    opacity: 0.6;
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.nav-col a i {
    width: 1.5rem;
    text-align: center;
    font-size: 1.2rem;
    color: var(--accent-primary);
}

.nav-col a:hover {
    color: var(--text-primary);
    opacity: 1;
    transform: translateX(5px);
}

.footer-bottom {
    padding-top: 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-secondary);
    font-size: 0.7rem;
    font-family: 'Syne', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    opacity: 0.5;
}

.copyright p {
    margin-bottom: 0.4rem;
    text-transform: none;
    letter-spacing: 0.05em;
    color: var(--text-secondary);
}

.build-info {
    opacity: 0.3;
}

@media (max-width: 1024px) {
    .footer-main {
        flex-direction: column;
        gap: 4rem;
    }

    .footer-nav {
        gap: 4rem;
    }

    /* Desktop lays out nav + main side by side; on mobile the top bar must stack above main. */
    body {
        display: block;
    }

    .side-nav {
        display: none;
    }

    .top-bar {
        display: flex;
        position: sticky;
        top: 0;
        z-index: 1000;
        justify-content: space-between;
        align-items: center;
        padding: 0.9rem 1.5rem;
        background: rgba(18, 18, 32, 0.92);
        backdrop-filter: blur(8px);
        border-bottom: 1px solid var(--line-color);
    }

    .top-bar .nav-logo-text {
        writing-mode: horizontal-tb;
        transform: none;
        font-size: 0.9rem;
        letter-spacing: 0.06em;
    }

    .top-bar nav { display: flex; gap: 0.75rem; }

    .top-bar nav a {
        color: var(--text-secondary);
        text-decoration: none;
        font-size: 0.75rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.1em;
    }

    /* .container's side padding would otherwise beat plain `section` and zero the vertical spacing. */
    section.container { min-height: auto; padding-top: 4rem; padding-bottom: 4rem; }

    .btn-ghost { padding: 1.2rem 2rem; white-space: nowrap; }

    .section-title { font-size: 2.5rem; margin-bottom: 3rem; }

    .feature-block { padding: 2.5rem 1.5rem; }

    .feature-block h3 { font-size: 1.5rem; overflow-wrap: anywhere; }

    footer.container { padding: 3rem 2rem; }

    .footer-brand { max-width: 100%; }

    .footer-logo { font-size: 1.4rem; }

    .footer-nav { gap: 2rem; }

    main {
        margin-left: 0;
        width: 100%;
    }

    .container {
        padding: 0 2rem;
    }

    .hero {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding-top: 4rem;
    }

    .hero-text h1 {
        font-size: clamp(3rem, 14vw, 5rem);
    }

    /* 12 columns plus 2rem gaps are wider than a phone, so stack the cards. */
    .features-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 1.25rem;
    }

    .feature-block,
    .feature-block.wide {
        grid-column: auto;
    }

    .team-layout {
        grid-template-columns: 1fr;
    }
}
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    * { transition: none !important; }
}

/* Phone/tablet: centred headings and footer, smaller card numbers. */
@media (max-width: 1024px) {
    .hero-text,
    .section-title {
        text-align: center;
    }

    .section-title {
        align-self: center;
    }

    .cta-group {
        justify-content: center;
    }

    .feature-block {
        padding-top: 3.25rem;
    }

    .feature-block .num {
        top: 0.75rem;
        right: 1rem;
        font-size: 1.75rem;
    }

    .footer-main,
    .footer-bottom {
        align-items: center;
        text-align: center;
    }

    .footer-brand,
    .footer-nav {
        align-items: center;
    }

    /* Centre the list as a block; icons and labels line up inside it. */
    .nav-col ul {
        align-items: flex-start;
        width: fit-content;
        margin: 0 auto;
    }

    .footer-nav {
        justify-content: center;
    }

    .nav-col a:hover {
        transform: none;
    }
}

/* Gallery */
.gallery-stage {
    position: relative;
    border: 1px solid var(--line-color);
    background: #08080c;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.45);
}

.gallery-track {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    overscroll-behavior-x: contain;
}

.gallery-track::-webkit-scrollbar {
    display: none;
}

.gallery-slide {
    position: relative;
    flex: 0 0 100%;
    scroll-snap-align: start;
    scroll-snap-stop: always;
}

.gallery-slide img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 9;
    object-fit: contain;
}

.gallery-slide figcaption {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 2.5rem 1.5rem 1.1rem;
    background: linear-gradient(to top, rgba(6, 6, 12, 0.92), transparent);
    font-family: 'Syne', sans-serif;
    font-weight: 800;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    pointer-events: none;
}

.gallery-count {
    position: absolute;
    right: 1.5rem;
    bottom: 1.1rem;
    font-family: 'Syne', sans-serif;
    font-weight: 700;
    font-size: 0.8rem;
    letter-spacing: 0.1em;
    color: var(--text-secondary);
}

.gallery-nav {
    position: absolute;
    top: 50%;
    width: 48px;
    height: 48px;
    margin-top: -24px;
    border: 1px solid var(--line-color);
    background: rgba(6, 6, 12, 0.75);
    color: var(--text-primary);
    font-size: 1.8rem;
    line-height: 1;
    cursor: pointer;
    transition: all 0.3s;
}

.gallery-nav.prev { left: 1rem; }
.gallery-nav.next { right: 1rem; }

.gallery-nav:hover {
    border-color: var(--accent-primary);
    background: var(--accent-primary);
}

.gallery-thumbs {
    display: flex;
    gap: 0.75rem;
    margin-top: 1rem;
    overflow-x: auto;
    padding-bottom: 0.4rem;
    scrollbar-width: thin;
    scrollbar-color: var(--accent-primary) transparent;
}

.gallery-thumb {
    flex: 0 0 auto;
    width: 160px;
    padding: 0;
    border: 1px solid var(--line-color);
    background: #08080c;
    opacity: 0.5;
    cursor: pointer;
    transition: all 0.3s;
}

.gallery-thumb img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

.gallery-thumb:hover,
.gallery-thumb[aria-current] {
    opacity: 1;
}

.gallery-thumb[aria-current] {
    border-color: var(--accent-primary);
    box-shadow: 0 0 20px var(--accent-glow);
}

@media (max-width: 700px) {
    .gallery-nav { display: none; }

    .gallery-slide figcaption { padding: 1.5rem 0.9rem 0.7rem; font-size: 0.75rem; }

    .gallery-count { right: 0.9rem; bottom: 0.7rem; font-size: 0.65rem; }

    .gallery-thumb { width: 96px; }
}

@media (max-width: 480px) {
    .top-bar { padding: 0.9rem 1rem; }

    .top-bar .nav-logo-text { font-size: 0.75rem; letter-spacing: 0.04em; }

    .top-bar nav { gap: 0.6rem; }

    .top-bar nav a { font-size: 0.65rem; letter-spacing: 0.06em; }
}
