:root {
    --paper: #E8EAE4;
    --plate: #FBFBF9;
    --ink: #191D18;
    --ink-soft: #5C635B;
    --steel: #909789;
    --line: #CBCFC4;
    --seam: #B4331F;

    --wrap: 1080px;

    --display: "Archivo Narrow", "Arial Narrow", sans-serif;
    --body: "Karla", system-ui, sans-serif;

    /* compatibility with old class names */
    --bg: var(--paper);
    --card: var(--plate);
    --text: var(--ink);
    --muted: var(--ink-soft);
    --border: var(--line);
    --accent: var(--seam);
}

* {
    box-sizing: border-box;
}

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

body {
    margin: 0;
    background: var(--paper);
    color: var(--ink);
    font: 400 16px/1.55 var(--body);
}

.wrap,
.container {
    width: 100%;
    max-width: var(--wrap);
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

a {
    color: inherit;
}

.seam {
    height: 2px;
    margin: 0;
    border: 0;
    background:
        repeating-linear-gradient(
            to right,
            var(--seam) 0 9px,
            transparent 9px 17px
        );
}

.seam--quiet {
    background:
        repeating-linear-gradient(
            to right,
            var(--line) 0 9px,
            transparent 9px 17px
        );
}


/* HEADER */

.site {
    background: var(--plate);
    border-bottom: 1px solid var(--line);
}

.site-row {
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
}

.logo {
    color: var(--ink);
    text-decoration: none;
    font: 700 25px/1 var(--display);
    letter-spacing: -.01em;
}

.logo span {
    color: var(--seam);
}

.nav {
    display: flex;
    gap: 28px;
}

.nav a {
    padding: 8px 0 6px;
    border-bottom: 2px solid transparent;
    color: var(--ink-soft);
    text-decoration: none;
    font: 500 15px/1 var(--body);
}

.nav a:hover {
    color: var(--ink);
}

.nav a[aria-current] {
    color: var(--ink);
    border-image:
        repeating-linear-gradient(
            to right,
            var(--seam) 0 9px,
            transparent 9px 17px
        ) 2;
}


/* BREADCRUMBS */

.breadcrumbs {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    padding: 18px 0 0;
    margin: 0;
    color: var(--steel);
    font-size: 14px;
}

.breadcrumbs a {
    color: var(--ink-soft);
    text-decoration: none;
    border-bottom: 1px solid var(--line);
}

.breadcrumbs a:hover {
    border-color: var(--seam);
}

.breadcrumbs span {
    padding: 0 8px;
}

.breadcrumbs span:last-child {
    padding-right: 0;
}


/* HOME */

.hero {
    max-width: none;
    padding: 64px 0 0;
}

.hero h1 {
    max-width: 16ch;
    margin: 0 0 14px;
    font: 700 clamp(38px, 6vw, 64px)/.98 var(--display);
    letter-spacing: -.02em;
}

.hero-copy {
    max-width: 52ch;
    margin: 0 0 34px;
    color: var(--ink-soft);
    font-size: 18px;
}

.plate,
.lookup-box {
    position: relative;
    margin-top: 0;
    padding: 26px 26px 22px;
    background: var(--plate);
    border: 1px solid var(--line);
    border-top: 2px solid var(--ink);
    border-radius: 0;
}

.plate::after,
.lookup-box::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 14px;
    opacity: .5;

    background:
        repeating-linear-gradient(
            to right,
            var(--steel) 0 1px,
            transparent 1px 9px
        );
}

.plate label,
.lookup-box label,
.model-search-label {
    display: block;
    margin-bottom: 10px;
    font: 700 13px/1 var(--body);
    letter-spacing: .02em;
}

.searchrow,
.search-row {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.searchrow input,
.search-row input,
.model-filter-search {
    flex: 1 1 260px;
    min-width: 0;
    padding: 15px 16px;
    color: var(--ink);
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 0;
    font: 400 18px/1 var(--body);
}

.searchrow input:focus,
.search-row input:focus,
.model-filter-search:focus {
    outline: 2px solid var(--ink);
    outline-offset: -1px;
}

.btn,
.search-row button {
    padding: 15px 30px;
    color: var(--plate);
    background: var(--ink);
    border: 1px solid var(--ink);
    border-radius: 0;
    cursor: pointer;
    font: 700 16px/1 var(--body);
}

.btn:hover,
.search-row button:hover {
    background: var(--seam);
    border-color: var(--seam);
}

.hint {
    margin: 14px 0 0;
    color: var(--steel);
    font-size: 14px;
}

.counts {
    display: flex;
    flex-wrap: wrap;
    gap: 0;
    margin: 38px 0 0;
    border-top: 1px solid var(--line);
}

.counts div {
    flex: 1 1 140px;
    padding: 16px 20px 18px;
    border-right: 1px solid var(--line);
}

.counts div:last-child {
    border-right: 0;
}

.counts b {
    display: block;
    font: 600 30px/1 var(--display);
}

.counts span {
    color: var(--ink-soft);
    font-size: 14px;
}

.jump {
    padding: 44px 0 72px;
}

.jump h2 {
    margin: 0 0 16px;
    font: 600 15px/1 var(--body);
}

.jumplist {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.jumplist a {
    display: inline-block;
    padding: 8px 14px;
    color: var(--ink);
    background: var(--plate);
    border: 1px solid var(--line);
    text-decoration: none;
    font: 600 16px/1 var(--display);
}

.jumplist a:hover {
    border-color: var(--ink);
}


/* COMMON PAGE HEAD */

.page-head,
.phead {
    padding: 44px 0 26px;
}

.page-head h1,
.phead h1 {
    margin: 0 0 12px;
    font: 700 clamp(34px, 5vw, 52px)/1 var(--display);
    letter-spacing: -.02em;
}

.page-head p,
.phead p {
    max-width: 58ch;
    margin-top: 0;
    color: var(--ink-soft);
}

.eyebrow {
    margin: 0 0 8px;
    color: var(--seam);
    font: 700 13px/1 var(--body);
    letter-spacing: .08em;
}

.directory-summary,
.brand-model-summary {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    margin-top: 22px;
    color: var(--ink-soft);
}

.directory-summary strong,
.brand-model-summary strong {
    color: var(--ink);
}


/* BRANDS DIRECTORY */

.legend {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    margin: 0 0 20px;
    color: var(--ink-soft);
    font-size: 13px;
}

.legend span {
    display: flex;
    gap: 7px;
    align-items: center;
}

.key {
    display: inline-block;
    width: 14px;
    height: 5px;
}

.key-current {
    background: var(--seam);
}

.key-retired {
    background: var(--ink);
}

.key-unknown {
    background: var(--steel);
}

.brand-directory {
    display: block;
    padding-bottom: 72px;
    border-top: 1px solid var(--line);
}

.brand-directory-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 150px 230px;
    gap: 20px;
    align-items: center;

    min-height: 0;
    padding: 18px 4px;

    color: inherit;
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0;

    text-decoration: none;
}

.brand-directory-card:hover {
    background: var(--plate);
}

.brand-directory-name {
    font: 600 24px/1.05 var(--display);
    letter-spacing: -.01em;
}

.brand-directory-country {
    margin: 0;
    color: var(--ink-soft);
    font-size: 14px;
}

.brand-directory-count {
    display: block;
    text-align: right;
}

.brand-directory-count b {
    display: block;
    font: 600 17px/1 var(--display);
}

.coverage-bar {
    display: flex;
    width: 100%;
    height: 5px;
    margin-top: 8px;
    background: var(--line);
}

.coverage-bar i {
    display: block;
    height: 100%;
}

.coverage-current {
    background: var(--seam);
}

.coverage-retired {
    background: var(--ink);
}

.coverage-unknown {
    background: var(--steel);
}

.models-pending {
    color: var(--steel);
    font-size: 14px;
}


/* BRAND PAGE */

.brand-page-head {
    padding-top: 34px;
    padding-bottom: 30px;
}

.brand-page-head h1 {
    font-size: clamp(40px, 7vw, 68px);
    line-height: .95;
}

.brand-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.description {
    max-width: 760px;
    margin-top: 25px;
    font-size: 17px;
    line-height: 1.7;
}

.model-directory-controls {
    position: relative;
    max-width: none;
    margin: 4px 0 32px;
    padding-top: 30px;
}

.model-directory-controls::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;

    background:
        repeating-linear-gradient(
            to right,
            var(--seam) 0 9px,
            transparent 9px 17px
        );
}

.model-filter-search {
    max-width: 420px;
    font-size: 17px;
}

.model-filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 14px;
}

.model-filter-button {
    width: auto;
    margin: 0;
    padding: 10px 15px;
    color: var(--ink);
    background: var(--plate);
    border: 1px solid var(--line);
    border-radius: 0;
    cursor: pointer;
    font: 500 15px/1 var(--body);
}

.model-filter-button span {
    margin-left: 6px;
    color: var(--ink-soft);
    opacity: 1;
}

.model-filter-button:hover {
    border-color: var(--ink);
}

.model-filter-button.is-active {
    color: var(--plate);
    background: var(--ink);
    border-color: var(--ink);
}

.model-filter-button.is-active span {
    color: var(--paper);
}

.model-no-results,
.empty-state {
    margin-top: 20px;
    padding: 20px;
    color: var(--ink-soft);
    background: var(--plate);
    border: 1px solid var(--line);
    border-radius: 0;
}

.model-group {
    margin: 38px 0 0;
}

.model-group-head {
    display: flex;
    gap: 16px;
    align-items: baseline;
    justify-content: space-between;
    margin-bottom: 16px;
}

.model-group-head h2 {
    margin: 0;
    font: 600 22px/1 var(--display);
}

.model-group-head p {
    margin: 0;
    color: var(--ink-soft);
    font-size: 14px;
}

.model-group-count {
    min-width: 40px;
    padding: 0;
    color: var(--ink-soft);
    background: transparent;
    border: 0;
    font: 600 16px/1 var(--display);
}

.model-grid {
    display: grid;
    grid-template-columns:
        repeat(
            auto-fill,
            minmax(148px, 1fr)
        );
    gap: 10px;
}

.model-directory-card {
    display: block;
    min-height: 0;
    padding: 13px 14px 12px;

    color: inherit;
    background: var(--plate);
    border: 1px solid var(--line);
    border-left: 4px solid var(--steel);
    border-radius: 0;

    text-decoration: none;
}

.model-directory-card[data-lifecycle="current"] {
    border-left-color: var(--seam);
}

.model-directory-card[data-lifecycle="retired"] {
    border-left-color: var(--ink);
}

.model-directory-card[data-lifecycle="unknown"] {
    border-left-color: var(--steel);
    border-left-style: dashed;
}

.model-directory-card:hover {
    border-color: var(--ink);
}

.model-directory-card strong {
    display: block;
    font: 600 19px/1 var(--display);
    letter-spacing: .01em;
}

.model-number {
    margin-top: 4px;
    color: var(--ink-soft);
    font-size: 13px;
}

.model-card-type {
    margin-top: 5px;
    color: var(--ink-soft);
    font-size: 13px;
}


/* MODEL PAGE */

.model-page-head {
    padding: 30px 0 16px;
}

.model-page-head .eyebrow {
    margin-bottom: 6px;
    color: var(--ink-soft);
    font: 500 16px/1 var(--body);
    letter-spacing: 0;
}

.model-page-head h1 {
    margin: 0 0 16px;
    font: 700 clamp(56px, 12vw, 110px)/.9 var(--display);
    letter-spacing: -.03em;
}

.model-page-head > p:not(.eyebrow) {
    color: var(--ink-soft);
}

.model-facts {
    max-width: none;
    margin: 20px 0 0;
}

.model-facts h2 {
    margin: 0 0 10px;
    font: 600 22px/1 var(--display);
}

.facts-grid {
    display: block;
    overflow: visible;

    margin: 0;
    padding: 0;

    background: var(--plate);
    border: 0;
    border-top: 2px solid var(--ink);
    border-bottom: 1px solid var(--line);
    border-radius: 0;
}

.facts-grid div {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);

    padding: 0;
    background: transparent;
    border-bottom: 1px solid var(--line);
}

.facts-grid div:last-child {
    border-bottom: 0;
}

.facts-grid dt {
    margin: 0;
    padding: 15px 18px;
    color: var(--ink-soft);
    font-size: 14px;
}

.facts-grid dd {
    margin: 0;
    padding: 15px 18px;
    border-left: 1px solid var(--line);
    font-weight: 700;
}

.relation-section {
    max-width: none;
    margin: 44px 0 0;
}

.relation-section h2 {
    margin: 0 0 18px;
    font: 600 22px/1 var(--display);
}

.relation-list {
    position: relative;
    display: grid;
    gap: 12px;
    padding-left: 26px;
}

.relation-list::before {
    content: "";
    position: absolute;
    left: 7px;
    top: 0;
    bottom: 0;
    width: 2px;

    background:
        repeating-linear-gradient(
            to bottom,
            var(--seam) 0 7px,
            transparent 7px 13px
        );
}

.relation-box {
    position: relative;
    display: block;

    padding: 15px 18px;
    color: inherit;
    background: var(--plate);
    border: 1px solid var(--line);
    border-radius: 0;

    text-decoration: none;
}

.relation-box::before {
    content: "";
    position: absolute;
    left: -28px;
    top: 20px;

    width: 10px;
    height: 10px;

    background: var(--paper);
    border: 2px solid var(--seam);
    border-radius: 50%;
}

.relation-box:hover {
    border-color: var(--ink);
}

.relation-box strong {
    font: 600 20px/1 var(--display);
}

.relation-box span {
    display: block;
    margin-top: 4px;
    color: var(--ink-soft);
    font-size: 13px;
}

.manual-section,
.sources-section {
    max-width: 56ch;
    margin: 38px 0 0;
    padding: 20px 22px;

    background: var(--plate);
    border: 1px solid var(--line);
    border-left: 4px solid var(--steel);
}

.manual-section h2,
.sources-section h2 {
    margin: 0 0 8px;
    font: 700 15px/1 var(--body);
}

.manual-link,
.source-list a {
    color: var(--ink);
}

.manual-link {
    display: inline;
    padding: 0;
    border: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    font-weight: 500;
}

.manual-link:hover,
.source-list a:hover {
    border-color: var(--seam);
}

.source-list {
    margin: 0;
    padding-left: 20px;
}


/* LOOKUP RESULTS */

.results {
    margin: 42px 0 72px;
}

.results h2 {
    font: 600 22px/1 var(--display);
}

.result-list {
    display: grid;
    gap: 0;
    border-top: 1px solid var(--line);
}

.result-card {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 20px;

    padding: 15px 4px;

    color: var(--ink);
    background: transparent;
    border: 0;
    border-bottom: 1px solid var(--line);
    border-radius: 0;

    text-decoration: none;
}

.result-card:hover {
    background: var(--plate);
}

.result-card strong {
    font: 600 20px/1 var(--display);
}

.result-card span {
    margin: 0;
    color: var(--ink-soft);
    font-size: 13px;
}


/* FOOTER */

.foot {
    margin-top: 80px;
    background: var(--plate);
    border-top: 1px solid var(--line);
}

.foot-inner {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
    justify-content: space-between;

    padding-top: 24px;
    padding-bottom: 28px;
}

.foot p {
    max-width: 52ch;
    margin: 0;
    color: var(--ink-soft);
    font-size: 14px;
}

.foot nav {
    display: flex;
    gap: 20px;
    font-size: 14px;
}

.foot a {
    color: var(--ink-soft);
}


/* MOBILE */

@media (max-width: 800px) {

    .brand-directory-card {
        grid-template-columns: 1fr;
        gap: 6px;
        padding: 16px 4px;
    }

    .brand-directory-count {
        text-align: left;
    }

    .coverage-bar {
        max-width: 260px;
    }

    .facts-grid div {
        grid-template-columns: 1fr;
    }

    .facts-grid dt {
        padding-bottom: 4px;
        border-bottom: 0;
    }

    .facts-grid dd {
        padding-top: 0;
        border-left: 0;
    }
}

@media (max-width: 600px) {

    .wrap,
    .container {
        padding-left: 18px;
        padding-right: 18px;
    }

    .nav {
        gap: 16px;
    }

    .hero {
        padding-top: 44px;
    }

    .searchrow,
    .search-row {
        display: block;
    }

    .btn,
    .search-row button {
        width: 100%;
        margin-top: 10px;
    }

    .counts div {
        flex-basis: 50%;
    }

    .counts div:nth-child(2) {
        border-right: 0;
    }

    .model-grid {
        grid-template-columns:
            repeat(
                2,
                minmax(0, 1fr)
            );
    }

    .model-page-head h1 {
        font-size: clamp(52px, 22vw, 88px);
    }
}

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

    * {
        transition: none !important;
        animation: none !important;
    }
}

/* Seam Guide finishing touches */

.model-filter-search {
    display: block;
    width: 100%;
    max-width: 420px;
}

.model-card-type {
    font-size: 12px;
    line-height: 1.25;
}

@media (min-width: 700px) {
    .model-grid {
        grid-template-columns:
            repeat(
                auto-fill,
                minmax(158px, 1fr)
            );
    }
}

.brandtop {
    display: grid;
    grid-template-columns:
        minmax(0, 1fr)
        300px;
    gap: 48px;

    padding: 34px 0;
}

.brandtop h1 {
    margin: 16px 0 14px;
    font: 700 clamp(40px, 7vw, 68px)/.95 var(--display);
    letter-spacing: -.02em;
}

.brandtop .description {
    margin-top: 0;
    color: var(--ink-soft);
}

.brand-facts {
    align-self: start;

    background: var(--plate);
    border-top: 2px solid var(--ink);
    border-bottom: 1px solid var(--line);
}

.brand-facts dl {
    display: grid;
    grid-template-columns: auto 1fr;
    margin: 0;
}

.brand-facts dt,
.brand-facts dd {
    padding: 12px 16px;
    border-bottom: 1px solid var(--line);
}

.brand-facts dt {
    color: var(--ink-soft);
    font-size: 14px;
}

.brand-facts dd {
    margin: 0;
    text-align: right;
    font-weight: 700;
}

.brand-facts dl > :nth-last-child(-n+2) {
    border-bottom: 0;
}

@media (max-width: 800px) {

    .brandtop {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .brand-facts dd {
        text-align: right;
    }
}

.status-badge {
    display: inline-block;
    margin-top: 4px;
    padding: 8px 12px;

    color: var(--ink);
    background: transparent;
    border: 1px solid var(--ink);

    font: 700 13px/1 var(--body);
}

.status-badge.is-current {
    color: #fff;
    background: var(--seam);
    border-color: var(--seam);
}

.model-page-head {
    padding-bottom: 26px;
}

.model-facts {
    margin-top: 12px;
}
