/* ==========================================================================
   TensorDelta: site styles
   Light, typographic, monochrome. One 12-column grid, hairline rules.
   ========================================================================== */

:root {
    --bg: #ffffff;
    --bg-soft: #fafafa;
    --ink: #111111;
    --ink-2: #4d4d4d;
    --ink-3: #737373;
    --mute: #8f8f8f;
    --line: #ebebeb;
    --line-2: #d9d9d9;

    --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
    --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

    --frame: min(1360px, calc(100% - 48px));
    --gutter: 40px;
    --gap: 24px;
    --header-h: 64px;

    color-scheme: light;
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-h);
    background: var(--bg);
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 16px;
    line-height: 1.6;
    color: var(--ink);
    background: var(--bg);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-feature-settings: "ss01" 0;
}

/* Frame: two hairlines that run the full height of the page */
body::before {
    content: "";
    position: fixed;
    top: 0;
    bottom: 0;
    left: 50%;
    width: var(--frame);
    transform: translateX(-50%);
    border-inline: 1px solid var(--line);
    pointer-events: none;
    z-index: 60;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; }
ul, ol { padding: 0; list-style: none; }

::selection { background: var(--ink); color: #fff; }

:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.skip-link {
    position: fixed;
    top: 12px;
    left: 12px;
    z-index: 100;
    padding: 10px 14px;
    border-radius: 8px;
    background: var(--ink);
    color: #fff;
    font-size: 14px;
    transform: translateY(-200%);
}
.skip-link:focus { transform: none; }

/* ---------- Layout ---------- */

.wrap {
    width: var(--frame);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.grid {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--gap);
}

.col-label { grid-column: 1 / span 3; }
.col-main { grid-column: 4 / -1; }

/* ---------- Type ---------- */

h1 {
    max-width: 12.5em;
    font-size: clamp(3rem, 7.4vw, 6.9rem);
    font-weight: 450;
    line-height: .96;
    letter-spacing: -.058em;
    text-wrap: balance;
}

h2 {
    max-width: 19em;
    font-size: clamp(2.1rem, 4.3vw, 3.9rem);
    font-weight: 450;
    line-height: 1.04;
    letter-spacing: -.045em;
    text-wrap: balance;
}

.mute { color: var(--mute); }

.label {
    font-family: var(--mono);
    font-size: 12.5px;
    line-height: 1.5;
    color: var(--ink-3);
}
.label span { margin-right: 14px; color: var(--ink); }

.lede {
    max-width: 44ch;
    margin-top: 28px;
    font-size: 18px;
    line-height: 1.6;
    color: var(--ink-2);
}

.link {
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 4px;
    text-decoration-color: var(--line-2);
    transition: text-decoration-color .15s;
}
.link:hover { text-decoration-color: var(--ink); }

/* ---------- Buttons ---------- */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    height: 44px;
    padding: 0 20px;
    border: 1px solid transparent;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    line-height: 1;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color .15s, border-color .15s, color .15s;
}
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #3a3a3a; }
.btn-line { background: var(--bg); color: var(--ink); border-color: var(--line-2); }
.btn-line:hover { border-color: var(--ink); }
.btn-sm { height: 36px; padding: 0 14px; font-size: 14px; }

.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }

/* ---------- Header ---------- */

.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, .88);
    -webkit-backdrop-filter: saturate(180%) blur(12px);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--line);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 28px;
    height: var(--header-h);
}

.brand img { width: auto; height: 26px; }

.nav { display: flex; gap: 2px; }
.nav a {
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 14px;
    color: var(--ink-2);
    transition: color .15s, background-color .15s;
}
.nav a:hover,
.nav a[aria-current="page"] { color: var(--ink); background: #f2f2f2; }

.header-cta { margin-left: auto; }

.menu-toggle {
    display: none;
    margin-left: auto;
    height: 36px;
    padding: 0 14px;
    border: 1px solid var(--line-2);
    border-radius: 8px;
    background: var(--bg);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}
.menu-toggle[aria-expanded="true"] { border-color: var(--ink); }

.mobile-nav { border-top: 1px solid var(--line); }
.mobile-nav[hidden] { display: none; }
.mobile-nav .wrap { display: grid; padding-block: 8px 24px; }
.mobile-nav a {
    padding: 14px 0;
    border-bottom: 1px solid var(--line);
    font-size: 26px;
    font-weight: 450;
    letter-spacing: -.035em;
}

/* ---------- Hero ---------- */

.hero-inner {
    display: flex;
    flex-direction: column;
    min-height: min(calc(100svh - var(--header-h)), 860px);
    padding-top: 40px;
    padding-bottom: 56px;
}
.hero h1 { margin-top: auto; padding-top: 96px; }

.hero-foot {
    display: grid;
    grid-template-columns: repeat(12, minmax(0, 1fr));
    column-gap: var(--gap);
    margin-top: 56px;
    padding-top: 28px;
    border-top: 1px solid var(--line);
}
.hero-lead { grid-column: 1 / span 6; }
.hero-lead p { max-width: 46ch; font-size: 18px; line-height: 1.6; color: var(--ink-2); }
.hero-lead strong { font-weight: 500; color: var(--ink); }

.hero-list { grid-column: 9 / -1; align-self: end; }
.hero-list li + li { border-top: 1px solid var(--line); }
.hero-list a {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    padding: 11px 0;
    font-size: 15px;
    color: var(--ink-2);
    transition: color .15s;
}
.hero-list a::after { content: "→"; color: var(--mute); transition: transform .2s, color .15s; }
.hero-list a:hover { color: var(--ink); }
.hero-list a:hover::after { color: var(--ink); transform: translateX(3px); }

/* ---------- Sections ---------- */

.section {
    position: relative;
    padding-block: clamp(80px, 9vw, 136px);
    border-top: 1px solid var(--line);
}

/* small crosshairs where the section rule meets the frame */
.section::before,
.section::after {
    content: "";
    position: absolute;
    top: -5px;
    width: 9px;
    height: 9px;
    background:
        linear-gradient(var(--mute), var(--mute)) center / 1px 100% no-repeat,
        linear-gradient(var(--mute), var(--mute)) center / 100% 1px no-repeat;
}
.section::before { left: calc((100% - var(--frame)) / 2 - 4px); }
.section::after { right: calc((100% - var(--frame)) / 2 - 4px); }

.section .col-label { padding-top: .55em; }

/* About */
.statement {
    max-width: 24em;
    font-size: clamp(1.75rem, 3.1vw, 2.75rem);
    line-height: 1.16;
    letter-spacing: -.035em;
    color: var(--mute);
}
.statement strong { font-weight: 450; color: var(--ink); }

.pair {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--gap);
    margin-top: 72px;
}
.pair h3 { font-size: 18px; font-weight: 500; letter-spacing: -.015em; }
.pair p { margin-top: 8px; max-width: 40ch; color: var(--ink-2); }

.pair-4 { row-gap: 48px; }

/* Stacked blocks inside a section (heading, then a list, a gallery...) */
.section > .wrap + .wrap { margin-top: 72px; }

/* Services / applications */
.svc {
    margin-inline: calc(-1 * var(--gutter));
    padding: 36px var(--gutter) 40px;
    border-top: 1px solid var(--line);
}
.svc:last-child { border-bottom: 1px solid var(--line); }

.svc-idx { font-family: var(--mono); font-size: 12.5px; color: var(--ink-3); padding-top: .5em; }
.svc-title {
    grid-column: 4 / span 4;
    font-size: clamp(22px, 2.1vw, 28px);
    font-weight: 450;
    line-height: 1.15;
    letter-spacing: -.03em;
    padding-right: 24px;
}
.svc-body { grid-column: 8 / -1; }
.svc-body > p { color: var(--ink-2); }
.svc-body ul { margin-top: 20px; }
.svc-body li {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 16px;
    padding: 10px 0;
    border-top: 1px solid var(--line);
    font-size: 15px;
}
.svc-body strong { font-weight: 500; }
.svc-body span { color: var(--ink-3); }

/* Why */
.stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-top: 72px;
    border-top: 1px solid var(--line);
}
.stat { padding: 28px var(--gap) 0 0; }
.stat + .stat { padding-left: var(--gap); border-left: 1px solid var(--line); }
.stat-value {
    font-size: clamp(64px, 8.4vw, 128px);
    font-weight: 400;
    line-height: .9;
    letter-spacing: -.065em;
    font-variant-numeric: tabular-nums;
}
.stat-value span { color: var(--mute); margin-left: .04em; }
.stat h3 { margin-top: 28px; font-size: 16px; font-weight: 500; }
.stat p:last-child { margin-top: 4px; color: var(--ink-2); }

.meta {
    margin-top: 16px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink-3);
}
.meta .link { font-family: var(--font); font-size: 15px; color: var(--ink); }

.note {
    max-width: 78ch;
    margin-top: 28px;
    font-size: 13.5px;
    line-height: 1.55;
    color: var(--ink-3);
}

/* Products (home) */
.products {
    display: grid;
    grid-template-columns: 1fr 1fr;
    margin-inline: calc(-1 * var(--gutter));
    border-block: 1px solid var(--line);
}
.product {
    display: flex;
    flex-direction: column;
    padding: 32px var(--gutter) 36px;
    transition: background-color .15s;
}
.product + .product { border-left: 1px solid var(--line); }
.product:hover { background: var(--bg-soft); }
.product:focus-visible { outline-offset: -2px; border-radius: 0; }

.product-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink-3);
}
.product-head span:first-child { color: var(--ink); }
.product-name {
    margin-top: 72px;
    font-size: clamp(44px, 5.4vw, 80px);
    font-weight: 450;
    line-height: .95;
    letter-spacing: -.055em;
}
.product-tagline { max-width: 24ch; margin-top: 20px; font-size: 22px; line-height: 1.25; letter-spacing: -.025em; }
.product-text { max-width: 46ch; margin-top: 14px; color: var(--ink-2); }

.product-specs { margin-top: 36px; }
.product-specs div {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    padding: 10px 0;
    border-top: 1px solid var(--line);
    font-size: 15px;
}
.product-specs dt { flex: none; color: var(--ink-3); }
.product-specs dd { text-align: right; }

.product-cta {
    display: inline-flex;
    gap: 8px;
    margin-top: auto;
    padding-top: 36px;
    font-weight: 500;
}
.product-cta::after { content: "→"; transition: transform .2s; }
.product:hover .product-cta::after { transform: translateX(3px); }

/* Figures */
.hero-figure { padding-bottom: clamp(64px, 7vw, 104px); }
.figure { margin: 0; }
.figure img { width: 100%; border-radius: 6px; background: var(--bg-soft); }
.figure figcaption,
.gallery figcaption {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 24px;
    margin-top: 14px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink-3);
}

.gallery {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: var(--gap);
}
.gallery figure { margin: 0; }
.gallery img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 6px; background: var(--bg-soft); }

/* Steps */
.steps {
    display: grid;
    grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr));
    gap: 40px var(--gap);
    margin-top: 72px;
}
.steps li { padding-top: 18px; border-top: 1px solid var(--line); }
.step-idx { font-family: var(--mono); font-size: 12.5px; color: var(--ink-3); }
.steps h3 { margin-top: 36px; font-size: 18px; font-weight: 500; letter-spacing: -.015em; }
.steps p { margin-top: 8px; font-size: 15px; color: var(--ink-2); }
.steps + .meta { margin-top: 48px; }

/* Flow diagram (TerraSensing) */
.flow {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 40px var(--gap);
}
.flow-art {
    position: relative;
    display: grid;
    place-items: center;
    aspect-ratio: 4 / 3;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: var(--bg-soft);
}
.flow-art svg { width: 76%; height: auto; overflow: visible; color: var(--ink); }
.flow li:not(:last-child) .flow-art::after {
    content: "→";
    position: absolute;
    top: 50%;
    right: calc(var(--gap) / -2);
    z-index: 1;
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border: 1px solid var(--line-2);
    border-radius: 50%;
    background: var(--bg);
    font-size: 13px;
    transform: translate(50%, -50%);
}
.flow-tag {
    position: absolute;
    top: 12px;
    left: 12px;
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 4px 10px;
    border-radius: 999px;
    background: var(--ink);
    color: #fff;
    font-family: var(--mono);
    font-size: 11.5px;
}
.flow-tag::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #fff; }
.flow h3 { display: flex; gap: 12px; margin-top: 18px; font-size: 16px; font-weight: 500; letter-spacing: -.01em; }
.flow h3 span { font-family: var(--mono); font-size: 12.5px; font-weight: 400; color: var(--ink-3); padding-top: .2em; }
.flow p { margin-top: 6px; max-width: 34ch; font-size: 15px; color: var(--ink-2); }

/* Benchmark bars */
.bars { margin: 72px 0 0; padding-top: 20px; border-top: 1px solid var(--line); }
.bars figcaption {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 4px 24px;
    font-family: var(--mono);
    font-size: 12.5px;
    color: var(--ink-3);
}
.bars ul { margin-top: 28px; }
.bars li {
    display: grid;
    grid-template-columns: minmax(0, 15em) minmax(0, 1fr) 6em;
    align-items: center;
    gap: 6px 20px;
    padding: 9px 0;
    font-size: 15px;
    color: var(--ink-2);
}
.bars-track { height: 14px; }
.bars-bar {
    display: block;
    width: calc(var(--v) / 110 * 100%);
    height: 100%;
    border-radius: 0 4px 4px 0;
    background: var(--mute);
}
.bars-value { text-align: right; font-variant-numeric: tabular-nums; }
.bars .is-ours { color: var(--ink); font-weight: 500; }
.bars .is-ours .bars-bar { background: var(--ink); }

/* Next product */
.next { border-top: 1px solid var(--line); }
.next-link {
    align-items: end;
    padding-block: 56px 64px;
    transition: background-color .15s;
}
.next-link:hover { background: var(--bg-soft); }
.next-link:focus-visible { outline-offset: -2px; border-radius: 0; }
.next-name {
    grid-column: 4 / span 6;
    font-size: clamp(2.6rem, 6vw, 5.4rem);
    font-weight: 450;
    line-height: 1;
    letter-spacing: -.055em;
}
.next-name::after { content: " →"; color: var(--mute); transition: color .15s; }
.next-link:hover .next-name::after { color: var(--ink); }
.next-sub { grid-column: 10 / -1; justify-self: end; text-align: right; color: var(--ink-3); }

/* Contact */
.contact h2 { max-width: 16em; }
.email {
    display: inline-block;
    margin-top: 48px;
    font-size: clamp(28px, 4.4vw, 60px);
    font-weight: 450;
    line-height: 1.1;
    letter-spacing: -.045em;
    text-decoration: underline;
    text-decoration-thickness: 1.5px;
    text-underline-offset: .14em;
    text-decoration-color: var(--line-2);
    overflow-wrap: anywhere;
    transition: text-decoration-color .15s;
}
.email:hover { text-decoration-color: var(--ink); }

/* ---------- Footer ---------- */

.site-footer { border-top: 1px solid var(--line); }
.footer-top { padding-top: 56px; padding-bottom: 72px; row-gap: 32px; }
.footer-logo { width: auto; height: 24px; }
.footer-about { grid-column: 4 / span 4; max-width: 44ch; font-size: 15px; color: var(--ink-2); }
.site-footer .footer-col:nth-of-type(1) { grid-column: 9 / span 2; }
.site-footer .footer-col:nth-of-type(2) { grid-column: 11 / span 2; }
.footer-col h3 { margin-bottom: 12px; font-family: var(--mono); font-size: 12.5px; font-weight: 400; color: var(--ink-3); }
.footer-col a { display: block; width: fit-content; padding: 3px 0; font-size: 15px; color: var(--ink-2); transition: color .15s; }
.footer-col a:hover { color: var(--ink); }
.footer-col p { font-size: 13.5px; color: var(--ink-3); }

.footer-bottom {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px;
    padding-block: 22px 28px;
    border-top: 1px solid var(--line);
    font-size: 13.5px;
    color: var(--ink-3);
}
.footer-bottom a:hover { color: var(--ink); }

/* ---------- Responsive ---------- */

@media (max-width: 1100px) {
    .col-label, .col-main { grid-column: 1 / -1; }
    .section .col-label { padding-top: 0; margin-bottom: 28px; }

    .svc-idx { grid-column: 1 / -1; padding: 0 0 10px; }
    .svc-title { grid-column: 1 / span 5; }
    .svc-body { grid-column: 6 / -1; }

    .next-link .col-label { margin-bottom: 20px; }
    .next-name { grid-column: 1 / span 8; }
    .next-sub { grid-column: 9 / -1; }

    .hero-lead { grid-column: 1 / span 7; }

    .footer-top .col-label { grid-column: 1 / -1; }
    .footer-about { grid-column: 1 / span 6; }
    .site-footer .footer-col:nth-of-type(1) { grid-column: 8 / span 2; }
    .site-footer .footer-col:nth-of-type(2) { grid-column: 10 / span 3; }
}

@media (max-width: 899px) {
    .nav, .header-cta { display: none; }
    .menu-toggle { display: inline-flex; align-items: center; }

    .hero-lead, .hero-list { grid-column: 1 / -1; }
    .hero-list { margin-top: 40px; }

    .svc-title, .svc-body { grid-column: 1 / -1; }
    .svc-body { margin-top: 16px; }

    .products { grid-template-columns: 1fr; }
    .product + .product { border-left: 0; border-top: 1px solid var(--line); }
    .product-name { margin-top: 48px; }

    .steps, .flow { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .flow li:not(:last-child) .flow-art::after { display: none; }

    .bars li { grid-template-columns: minmax(0, 1fr) 6em; }
    .bars-label { grid-column: 1 / -1; }
    .bars-track { grid-column: 1; }

    .next-name, .next-sub { grid-column: 1 / -1; justify-self: start; text-align: left; }
    .next-sub { margin-top: 12px; }

    .footer-about { grid-column: 1 / -1; }
    .site-footer .footer-col:nth-of-type(1) { grid-column: 1 / span 6; }
    .site-footer .footer-col:nth-of-type(2) { grid-column: 7 / -1; }
}

@media (max-width: 640px) {
    :root { --frame: 100%; --gutter: 20px; --gap: 16px; }
    body::before, .section::before, .section::after { display: none; }

    .hero-inner { min-height: 0; padding-top: 28px; padding-bottom: 40px; }
    .hero h1 { padding-top: 64px; }
    .hero-lead p { font-size: 17px; }
    .actions .btn { flex: 1 1 auto; }

    .pair, .stats { grid-template-columns: 1fr; }
    .pair { gap: 28px; margin-top: 48px; }
    .stat + .stat { padding-left: 0; border-left: 0; border-top: 1px solid var(--line); margin-top: 28px; }
    .stat { padding-right: 0; }

    .gallery, .steps, .flow { grid-template-columns: 1fr; }
    .steps h3 { margin-top: 20px; }
    .product-tagline { font-size: 20px; }
    .next-link { padding-block: 44px 48px; }
}
