/* VRSecLabs: landing page (index.html only). Loaded after style.css + revamp.css. */

.hx-section {
    position: relative;
    padding: clamp(4.5rem, 9vw, 8rem) 0;
    background: var(--bg-void);
}

.hx-head {
    max-width: 760px;
    margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}

.hx-head h2 {
    text-align: left;
    margin-bottom: 1rem;
}

.hx-head p {
    margin: 0;
    font-size: 1.125rem;
    line-height: 1.6;
}

/* ── Hero ── */
.hx-hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: flex-end;
    min-height: 100vh;
    min-height: 100dvh;
    padding: calc(var(--nav-h) + var(--banner-extra) + 3rem) 0 clamp(3rem, 9vh, 6rem);
    overflow: hidden;
    background: var(--bg-void);
}

.hx-hero canvas {
    position: absolute;
    inset: 0;
    z-index: -2;
    width: 100%;
    height: 100%;
    display: block;
}

.hx-hero::after {
    content: '';
    position: absolute;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background:
        linear-gradient(180deg, rgba(8, 9, 11, 0.75) 0%, rgba(8, 9, 11, 0) 22%),
        linear-gradient(0deg, var(--bg-void) 0%, rgba(8, 9, 11, 0) 24%),
        linear-gradient(90deg, var(--bg-void) 0%, rgba(8, 9, 11, 0.88) 32%, rgba(8, 9, 11, 0) 70%);
}

.hx-hero-inner {
    position: relative;
}

.hx-title {
    margin: 0 0 1.75rem;
    font-size: clamp(2.6rem, 6.6vw, 6.25rem);
    font-weight: 600;
    line-height: 0.96;
    letter-spacing: -0.04em;
    text-transform: uppercase;
    color: var(--text-primary);
}

.hx-line {
    display: block;
    overflow: hidden;
    padding-bottom: 0.06em;
    margin-bottom: -0.06em;
}

.hx-line>span {
    display: block;
}

.hx-title i {
    font-style: normal;
    color: var(--accent);
}

.hx-sub {
    max-width: 46ch;
    margin: 0 0 2.25rem;
    font-size: clamp(1.0625rem, 1.5vw, 1.25rem);
    line-height: 1.6;
    color: var(--text-secondary);
}

.hx-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
}

@media (prefers-reduced-motion: no-preference) {
    .hx-line>span {
        transform: translateY(110%);
        animation: hx-up 1.05s var(--ease-out) forwards;
        animation-delay: calc(0.15s + var(--i, 0) * 0.13s);
    }

    .hx-hero .hx-sub,
    .hx-hero .hx-actions {
        opacity: 0;
        transform: translateY(16px);
        animation: hx-fade 0.9s var(--ease-out) forwards;
    }

    .hx-hero .hx-sub {
        animation-delay: 0.62s;
    }

    .hx-hero .hx-actions {
        animation-delay: 0.78s;
    }

    .hx-hero canvas {
        opacity: 0;
        animation: hx-canvas 1.8s ease-out 0.2s forwards;
    }
}

@keyframes hx-up {
    to {
        transform: translateY(0);
    }
}

@keyframes hx-fade {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes hx-canvas {
    to {
        opacity: 1;
    }
}

/* ── Stats strip ── */
.hx-stats {
    background: var(--bg-void);
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.hx-stats .stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0;
    text-align: left;
}

.hx-stats .stat-item {
    padding: 2.25rem 2rem;
    border-left: 1px solid var(--border);
}

.hx-stats .stat-item:first-child {
    padding-left: 0;
    border-left: 0;
}

.hx-stats .stat-item::after {
    display: none;
}

.hx-stats .stat-item h3 {
    margin: 0 0 0.4rem;
    font-family: var(--font-mono);
    font-size: clamp(2rem, 3.6vw, 3.25rem);
    font-weight: 500;
    letter-spacing: -0.04em;
    line-height: 1;
    color: var(--text-primary);
}

.hx-stats .stat-item p {
    margin: 0;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--text-tertiary);
}

/* ── Capabilities explorer ── */
.hx-cap-grid {
    display: grid;
    grid-template-columns: minmax(250px, 340px) minmax(0, 1fr);
    gap: clamp(2rem, 6vw, 6rem);
    align-items: start;
}

.hx-tabs {
    display: flex;
    flex-direction: column;
    border-top: 1px solid var(--border);
}

.hx-tab {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.4rem 0;
    border: 0;
    border-bottom: 1px solid var(--border);
    background: none;
    color: var(--text-tertiary);
    font-family: var(--font-header);
    font-size: clamp(1.1rem, 1.6vw, 1.4rem);
    font-weight: 500;
    letter-spacing: -0.02em;
    text-align: left;
    cursor: pointer;
    transition: color 0.3s ease;
}

.hx-tab em {
    font-family: var(--font-mono);
    font-size: 0.78rem;
    font-style: normal;
    letter-spacing: 0.02em;
}

.hx-tab::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -1px;
    width: 0;
    height: 1px;
    background: var(--accent);
    transition: width 0.55s var(--ease-out);
}

.hx-tab:hover {
    color: var(--text-secondary);
}

.hx-tab[aria-selected='true'] {
    color: var(--text-primary);
}

.hx-tab[aria-selected='true']::after {
    width: 100%;
}

.hx-panel[hidden] {
    display: none;
}

.hx-panel {
    border-top: 1px solid var(--border);
}

@media (prefers-reduced-motion: no-preference) {
    .hx-panel.is-entering {
        animation: hx-panel 0.55s var(--ease-out);
    }
}

@keyframes hx-panel {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: none;
    }
}

.hx-lede {
    max-width: 38ch;
    margin: 0;
    padding: 1.6rem 0;
    font-size: clamp(1.2rem, 1.9vw, 1.6rem);
    font-weight: 500;
    line-height: 1.3;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

.hx-caps {
    list-style: none;
    margin: 0;
    padding: 0;
}

.hx-caps li {
    display: grid;
    grid-template-columns: minmax(170px, 0.8fr) minmax(0, 1.6fr);
    gap: 1.5rem 2.5rem;
    padding: 1.4rem 0;
    border-top: 1px solid var(--border);
}

.hx-caps h3 {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 500;
    letter-spacing: -0.01em;
    color: var(--text-primary);
}

.hx-caps p {
    margin: 0;
    max-width: 52ch;
    font-size: 0.97rem;
    line-height: 1.65;
}

.hx-link {
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 1.5rem;
    padding-top: 1.4rem;
    width: 100%;
    border-top: 1px solid var(--border);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.hx-link i {
    font-size: 0.78em;
    transition: transform 0.25s var(--ease-out);
}

.hx-link:hover {
    color: var(--accent);
}

.hx-link:hover i {
    transform: translateX(4px);
}

/* ── Engagement method ── */
.hx-method {
    border-top: 1px solid var(--border);
}

.hx-steps {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: clamp(1.5rem, 3vw, 3rem);
    position: relative;
    margin: 0;
    padding: 2.75rem 0 0;
}

.hx-steps::before,
.hx-steps::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
}

.hx-steps::before {
    background: var(--border-strong);
}

.hx-steps::after {
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 1.8s var(--ease-out);
}

.hx-steps.is-in::after {
    transform: scaleX(1);
}

.hx-steps li {
    position: relative;
}

.hx-steps li::before {
    content: '';
    position: absolute;
    top: calc(-2.75rem - 3px);
    left: 0;
    width: 7px;
    height: 7px;
    background: var(--accent);
}

.hx-steps h3 {
    margin: 0 0 0.75rem;
    font-size: 1.5rem;
    font-weight: 500;
    letter-spacing: -0.03em;
}

.hx-steps p {
    margin: 0;
    max-width: 30ch;
    font-size: 0.97rem;
    line-height: 1.65;
}

@media (prefers-reduced-motion: no-preference) {
    .js .hx-steps li {
        opacity: 0;
        transform: translateY(14px);
        transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
        transition-delay: calc(var(--i, 0) * 0.28s);
    }

    .js .hx-steps.is-in li {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .hx-steps::after {
        transform: scaleX(1);
        transition: none;
    }
}

/* ── Bento cells (assurances + research) ── */
.hx-bento {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.hx-cell {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding: clamp(1.5rem, 2.4vw, 2.25rem);
    overflow: hidden;
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    transition: border-color 0.3s ease;
}

.hx-cell>* {
    position: relative;
}

.hx-cell::before {
    content: '';
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0;
    background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 0%), rgba(var(--accent-rgb), 0.13), transparent 45%);
    transition: opacity 0.4s ease;
}

@media (hover: hover) {
    .hx-cell:hover {
        border-color: var(--border-strong);
    }

    .hx-cell:hover::before {
        opacity: 1;
    }
}

.hx-cell h3 {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 500;
    letter-spacing: -0.02em;
}

.hx-cell p {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.6;
}

.hx-cell--lead {
    grid-column: span 2;
    grid-row: span 2;
    justify-content: flex-end;
    min-height: 22rem;
    background:
        linear-gradient(160deg, rgba(var(--accent-rgb), 0.12) 0%, rgba(var(--accent-rgb), 0) 55%),
        var(--bg-surface);
}

.hx-cell--lead h3 {
    font-size: clamp(1.7rem, 3vw, 2.5rem);
    letter-spacing: -0.035em;
    line-height: 1.05;
}

.hx-cell--lead p {
    max-width: 44ch;
    font-size: 1.02rem;
}

.hx-cell--wide {
    grid-column: span 2;
}

.hx-cell--grid {
    background-color: var(--bg-surface);
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
    background-size: 30px 30px;
}

.hx-chips {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.hx-chips span {
    padding: 0.3rem 0.65rem;
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    color: var(--text-primary);
}

/* ── Government ── */
.hx-gov {
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
    background:
        radial-gradient(60% 90% at 0% 0%, rgba(var(--accent-rgb), 0.07), transparent 60%),
        var(--bg-void);
}

.hx-gov-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: clamp(2.5rem, 7vw, 7rem);
    align-items: start;
}

.hx-gov h2 {
    text-align: left;
    margin-bottom: 1.25rem;
}

.hx-gov .hx-sub {
    margin-bottom: 2rem;
    max-width: 52ch;
}

.hx-pillars {
    list-style: none;
    margin: 0;
    padding: 0;
    border-top: 1px solid var(--border-strong);
}

.hx-pillars li {
    padding: 1.6rem 0;
    border-bottom: 1px solid var(--border);
}

.hx-pillars h3 {
    margin: 0 0 0.5rem;
    font-size: 1.35rem;
    font-weight: 500;
    letter-spacing: -0.025em;
}

.hx-pillars p {
    margin: 0;
    max-width: 46ch;
    font-size: 0.97rem;
    line-height: 1.65;
}

/* ── Research & products ── */
.hx-bento--research {
    grid-template-columns: 2fr 1fr;
}

.hx-bento--research .hx-cell--disc {
    grid-row: span 2;
    min-height: 20rem;
    justify-content: flex-start;
}

.hx-bento--research .hx-cell--disc h3 {
    font-size: clamp(1.5rem, 2.6vw, 2.1rem);
    letter-spacing: -0.03em;
}

.hx-bento--research .hx-cell--disc p {
    max-width: 44ch;
}

.hx-logos {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1.25rem 2.75rem;
    margin: auto 0 0;
    padding: 2rem 0 0;
}

.hx-logos i {
    font-size: 2.1rem;
    color: var(--text-tertiary);
    transition: color 0.3s ease;
}

.hx-logos li:hover i {
    color: var(--text-primary);
}

.hx-cell--link {
    justify-content: space-between;
    color: inherit;
}

.hx-more {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    margin-top: 1.25rem;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.hx-more i {
    font-size: 0.78em;
    transition: transform 0.25s var(--ease-out);
}

.hx-cell--link:hover .hx-more {
    color: var(--accent);
}

.hx-cell--link:hover .hx-more i {
    transform: translateX(4px);
}

/* ── Closing CTA ── */
.hx-cta {
    padding: clamp(4rem, 8vw, 7rem) 0;
    border-top: 1px solid var(--border);
    background:
        radial-gradient(60% 140% at 100% 100%, rgba(var(--accent-rgb), 0.12), transparent 60%),
        var(--bg-void);
}

.hx-cta-inner {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 2.5rem 4rem;
    flex-wrap: wrap;
}

.hx-cta h2 {
    max-width: 13ch;
    margin: 0;
    text-align: left;
    font-size: clamp(2.4rem, 5.5vw, 4.5rem);
    line-height: 1;
    letter-spacing: -0.04em;
}

.hx-cta p {
    max-width: 38ch;
    margin: 0 0 1.5rem;
    font-size: 1.1rem;
}

/* ── Quote ── */
.hx-quote {
    border-top: 1px solid var(--border);
    background: var(--bg-void);
}

.hx-quote-grid {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
    gap: clamp(2.5rem, 7vw, 7rem);
    align-items: start;
}

.hx-quote h2 {
    text-align: left;
    margin-bottom: 1rem;
}

.hx-quote .hx-mail {
    margin-top: 1.5rem;
    font-size: 0.95rem;
}

.hx-quote .hx-mail a {
    color: var(--text-primary);
    text-decoration: underline;
    text-decoration-color: var(--accent);
    text-underline-offset: 4px;
}

.hx-form {
    padding: clamp(1.5rem, 3vw, 2.5rem);
    background: var(--bg-surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
}

/* ── Responsive ── */
@media (max-width: 960px) {
    .hx-cap-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .hx-tabs {
        flex-direction: row;
        gap: 1.75rem;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        border-top: 0;
        border-bottom: 1px solid var(--border);
        scrollbar-width: none;
    }

    .hx-tabs::-webkit-scrollbar {
        display: none;
    }

    .hx-tab {
        flex: 0 0 auto;
        gap: 0.6rem;
        padding: 1rem 0;
        border-bottom: 0;
        white-space: nowrap;
        scroll-snap-align: start;
    }

    .hx-tab::after {
        bottom: 0;
    }

    .hx-panel {
        border-top: 0;
    }

    .hx-caps li {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .hx-steps {
        grid-template-columns: 1fr 1fr;
        row-gap: 3rem;
    }

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

    .hx-cell--lead {
        grid-row: auto;
        min-height: 16rem;
    }

    .hx-gov-grid,
    .hx-quote-grid {
        grid-template-columns: 1fr;
    }

    .hx-bento--research {
        grid-template-columns: 1fr 1fr;
    }

    .hx-bento--research .hx-cell--disc {
        grid-column: span 2;
        grid-row: auto;
        min-height: 0;
    }

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

    .hx-stats .stat-item:nth-child(odd) {
        padding-left: 0;
        border-left: 0;
    }

    .hx-stats .stat-item:nth-child(n + 3) {
        border-top: 1px solid var(--border);
    }
}

@media (max-width: 600px) {
    .hx-hero {
        padding-top: calc(var(--nav-h) + var(--banner-extra) + 2rem);
    }

    .hx-hero canvas {
        opacity: 0.9;
    }

    .hx-steps {
        grid-template-columns: 1fr;
        padding-top: 0;
        padding-left: 1.75rem;
        row-gap: 2.25rem;
    }

    .hx-steps::before,
    .hx-steps::after {
        top: 0;
        bottom: 0;
        left: 0;
        right: auto;
        width: 1px;
        height: auto;
    }

    .hx-steps::after {
        transform: scaleY(0);
        transform-origin: top;
    }

    .hx-steps.is-in::after {
        transform: scaleY(1);
    }

    .hx-steps li::before {
        top: 0.55rem;
        left: calc(-1.75rem - 3px);
    }

    .hx-bento,
    .hx-bento--research {
        grid-template-columns: 1fr;
    }

    .hx-cell--lead,
    .hx-cell--wide,
    .hx-bento--research .hx-cell--disc {
        grid-column: auto;
    }

    .hx-stats .stat-item {
        padding: 1.6rem 1rem;
    }

    .hx-actions .btn-primary {
        flex: 1 1 100%;
    }
}
