/* broadwayinc.com landing page: the page shell only (top bar, the
   "Build With Us" header and the footer). Each product section carries its
   own stylesheet in products/<name>/, scoped under its section class, so
   nothing here styles inside a product section and nothing there leaks out.

   One language with the product sections: neutral ink on white, square
   corners, hairlines, a monospace for the running text, and the soft
   hard-edged offset shadow DDBD uses. Avenir, the logo's face, is kept for
   the brand: the wordmark, the headline and the product names. */

@font-face {
    font-family: "Avenir broadway";
    src: url("../fonts/Avenir.woff") format("woff");
    font-display: swap;
}

:root {
    --bw-ink: #111111;
    --bw-paper: #ffffff;
    --bw-muted: #5e5e5e;
    --bw-faint: #8a8a8a;
    --bw-line: #d9d9d9;
    --bw-line-soft: #ebebeb;
    --bw-shadow: rgba(17, 17, 17, 0.14);
    --bw-logo: "Avenir broadway", "Avenir Next", Avenir, "Helvetica Neue", Arial, sans-serif;
    --bw-mono: "Google Sans Code", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    --bw-gutter: clamp(1rem, 4vw, 2rem);
    --bw-top-h: 60px;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}

body {
    margin: 0;
    background: var(--bw-paper);
    color: var(--bw-ink);
    font-family: var(--bw-mono);
    font-size: 16px;
    line-height: 1.6;
    overflow-x: hidden;
}

/* Shown only when focused from the keyboard. */
.bw-skip {
    position: absolute;
    left: 1rem;
    top: -4rem;
    z-index: 20;
    padding: 0.5rem 0.9rem;
    background: var(--bw-ink);
    color: var(--bw-paper);
    font: 500 13px var(--bw-mono);
    text-decoration: none;
}

.bw-skip:focus {
    top: 0.7rem;
}

.bw-wrap {
    max-width: 1116px;
    margin: 0 auto;
    padding: 0 var(--bw-gutter);
    box-sizing: border-box;
}

/* ─── top bar ─── */
.bw-top {
    position: sticky;
    top: 0;
    z-index: 10;
    background: rgba(255, 255, 255, 0.88);
    -webkit-backdrop-filter: saturate(1.6) blur(14px);
    backdrop-filter: saturate(1.6) blur(14px);
    border-bottom: 1px solid transparent;
    transition: border-color 0.2s ease;
}

/* the hairline shows once the page has scrolled (set by the page script) */
.bw-top.is-scrolled {
    border-bottom-color: var(--bw-line-soft);
}

.bw-top .bw-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    height: var(--bw-top-h);
}

.bw-logo {
    color: var(--bw-ink);
    font-family: var(--bw-logo);
    font-size: 22px;
    letter-spacing: -0.015em;
    text-decoration: none;
    white-space: nowrap;
}

.bw-nav {
    display: flex;
    gap: clamp(16px, 3vw, 32px);
}

.bw-nav a {
    color: var(--bw-muted);
    font-size: 13px;
    letter-spacing: 0.02em;
    text-decoration: none;
    text-underline-offset: 6px;
    transition: color 0.15s ease;
}

.bw-nav a:hover,
.bw-nav a:focus-visible {
    color: var(--bw-ink);
    text-decoration: underline;
    text-decoration-thickness: 1px;
}

/* ─── Build With Us ─── */
/* A soft gradient band, as the product heroes have, and nothing else. */
.bw-intro {
    min-height: min(800px, calc(100svh - var(--bw-top-h)));
    display: flex;
    align-items: center;
    padding: clamp(72px, 10vw, 120px) 0 clamp(64px, 8vw, 96px);
    text-align: center;
    background: linear-gradient(180deg, #f1f1f1 0%, #f8f8f8 50%, var(--bw-paper) 100%);
}

.bw-intro-inner {
    width: 100%;
}

/* The name and the headline are one pair in the logo's face, the name a
   third of the headline's size at every width (28/84 at the top end). */
.bw-eyebrow {
    margin: 0 0 clamp(12px, 1.6vw, 18px);
    color: var(--bw-ink);
    font-family: var(--bw-logo);
    font-size: clamp(18px, 2.2vw, 28px);
    line-height: 1.2;
    letter-spacing: -0.01em;
}

.bw-intro h1 {
    margin: 0;
    color: var(--bw-ink);
    font-family: var(--bw-logo);
    font-weight: 400;
    font-size: clamp(46px, 6.6vw, 84px);
    line-height: 1.02;
    letter-spacing: -0.04em;
    text-wrap: balance;
}

.bw-lede {
    margin: clamp(18px, 2.4vw, 24px) auto 0;
    max-width: 44ch;
    color: var(--bw-muted);
    font-size: clamp(15px, 1.4vw, 17px);
    line-height: 1.6;
    text-wrap: balance;
}

/* ─── the product cards ─── */
.bw-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    max-width: 920px;
    margin: clamp(44px, 6vw, 64px) auto 0;
    padding: 0;
    list-style: none;
    text-align: left;
}

/* Square, a hairline, and the soft offset shadow; on hover the edge turns ink
   and the card lifts toward its shadow, the way the DDBD buttons do. */
.bw-card {
    display: flex;
    align-items: center;
    gap: 14px;
    height: 100%;
    box-sizing: border-box;
    padding: 16px 18px;
    border: 1px solid var(--bw-line);
    background: var(--bw-paper);
    color: var(--bw-ink);
    text-decoration: none;
    box-shadow: 3px 3px 0 var(--bw-line-soft);
    transition: transform 0.12s ease, box-shadow 0.12s ease, border-color 0.12s ease;
}

.bw-card:hover,
.bw-card:focus-visible {
    border-color: var(--bw-ink);
    box-shadow: 4px 4px 0 var(--bw-shadow);
    transform: translate(-1px, -1px);
}

.bw-card:focus-visible {
    outline: none;
}

.bw-card-mark {
    flex: none;
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.bw-card-mark--ddbd {
    display: grid;
    place-items: center;
    background: var(--bw-ink);
    color: var(--bw-paper);
}

.bw-card-mark--ddbd svg {
    width: 26px;
    height: 26px;
}

.bw-card-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.bw-card-name {
    font-family: var(--bw-logo);
    font-size: 18px;
    line-height: 1.2;
}

.bw-card-desc {
    color: var(--bw-muted);
    font-size: 12px;
    line-height: 1.4;
}

.bw-card-arrow {
    margin-left: auto;
    color: var(--bw-faint);
    font-size: 14px;
    transition: transform 0.12s ease, color 0.12s ease;
}

.bw-card:hover .bw-card-arrow,
.bw-card:focus-visible .bw-card-arrow {
    color: var(--bw-ink);
    transform: translateY(2px);
}

@media (max-width: 760px) {
    .bw-cards {
        grid-template-columns: minmax(0, 1fr);
        max-width: 420px;
        gap: 12px;
    }
}

/* The product sections follow one another; each brings its own band, so a
   hairline is all that marks where one ends. */
.bw-products > section {
    border-top: 1px solid var(--bw-line-soft);
    scroll-margin-top: var(--bw-top-h);
}

/* ─── footer ─── */
/* Plain columns on white: the name, the products, one column per office.
   No boxes; a hairline above, and one above the copyright line. */
.bw-footer {
    border-top: 1px solid var(--bw-line);
    background: var(--bw-paper);
    color: var(--bw-muted);
    font-size: 13px;
    line-height: 1.7;
}

.bw-footer a {
    color: var(--bw-ink);
    text-decoration: none;
    text-underline-offset: 4px;
}

.bw-footer a:hover,
.bw-footer a:focus-visible {
    text-decoration: underline;
    text-decoration-thickness: 1px;
}

.bw-footer-main {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 0.8fr) minmax(0, 1.2fr) minmax(0, 1.2fr);
    gap: 32px;
    padding: clamp(48px, 7vw, 72px) 0 clamp(40px, 6vw, 56px);
}

.bw-footer-brand .bw-logo {
    font-size: 22px;
}

.bw-footer-brand p {
    margin: 10px 0 0;
    max-width: 26ch;
}

.bw-footer h2 {
    margin: 0 0 12px;
    color: var(--bw-ink);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.bw-footer ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.bw-footer address {
    font-style: normal;
}

.bw-office-name {
    display: block;
    color: var(--bw-ink);
}

.bw-footer-base {
    padding: 20px 0 28px;
    border-top: 1px solid var(--bw-line-soft);
    color: var(--bw-faint);
    font-size: 12px;
}

@media (max-width: 900px) {
    .bw-footer-main {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
        row-gap: 36px;
    }
}

@media (max-width: 560px) {
    .bw-nav {
        gap: 14px;
    }

    .bw-nav a {
        font-size: 12px;
    }

    .bw-logo {
        font-size: 20px;
    }

    .bw-lede {
        max-width: 24ch;
    }

    .bw-footer-main {
        grid-template-columns: minmax(0, 1fr);
    }
}

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

    .bw-card,
    .bw-card-arrow,
    .bw-top,
    .bw-nav a {
        transition: none;
    }
}
