@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500&display=swap");

:root {
    --bg: #ffffff;
    --surface: #ffffff;
    --surface-strong: #ffffff;
    --ink: #111111;
    --muted: #555555;
    --line: #d9d9d9;
    --line-strong: #111111;
}

* {
    box-sizing: border-box;
}

body {
    background: var(--bg);
    color: var(--ink);
    font-family: "IBM Plex Mono", "SFMono-Regular", "Menlo", monospace;
    margin: 0;
    min-height: 100vh;
}

a {
    color: inherit;
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
    text-underline-offset: 0.2em;
}

.home,
.archive-page,
.artifact-page,
#gallery {
    padding-left: 20px;
    padding-right: 20px;
}

.home {
    max-width: 1080px;
    margin: 0 auto;
    padding-top: 64px;
    padding-bottom: 96px;
}

.hero,
.section-grid {
    display: grid;
    gap: 24px;
}

.hero {
    grid-template-columns: minmax(0, 1.5fr) minmax(280px, 0.75fr);
    align-items: stretch;
    margin-bottom: 56px;
}

.hero-copy,
.panel,
.hero-panel,
.artifact-card,
.artifact-detail-card {
    background: var(--surface);
    border: 1px solid var(--line);
}

.hero-copy,
.hero-panel,
.panel {
    border-radius: 0;
    padding: 32px;
}

.eyebrow,
.panel-label,
.nav,
.featured-meta,
.enter,
.button {
    letter-spacing: 0.12em;
    text-transform: uppercase;
    font-size: 11px;
}

.eyebrow,
.panel-label,
.featured-meta,
.nav {
    margin: 0 0 16px;
}

h1 {
    font-family: Palatino, "Palatino Linotype", "Book Antiqua", serif;
    font-size: clamp(34px, 7vw, 64px);
    line-height: 1;
    font-weight: 400;
    margin: 0 0 24px;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

h2 {
    font-size: 13px;
    font-weight: 400;
    margin: 0 0 12px;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.lede,
.statement,
.panel-note,
.artifact-row span:last-child,
.footer {
    color: var(--muted);
    line-height: 1.7;
}

.lede {
    max-width: 54ch;
    margin: 0;
    font-size: 14px;
}

.statement {
    margin: 0;
    text-align: center;
    font-size: 14px;
}

.statement.left {
    text-align: left;
}

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

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 0 16px;
    border-radius: 0;
    border: 1px solid var(--line-strong);
    transition: background-color 160ms ease, color 160ms ease;
}

.button:hover {
    text-decoration: none;
}

.button-primary {
    background: var(--ink);
    color: var(--bg);
}

.button-secondary {
    background: transparent;
}

.button-secondary:hover,
.button-primary:hover {
    background: var(--ink);
    color: var(--bg);
}

.flow-stack {
    display: grid;
    gap: 14px;
    margin: 24px 0 0;
}

.flow-node,
.flow-arrow {
    text-align: center;
}

.flow-node {
    padding: 0;
    border: 1px solid var(--line);
    border-width: 0 0 1px;
    background: transparent;
    text-transform: lowercase;
    padding-bottom: 14px;
}

.flow-arrow {
    height: 10px;
    border-left: 1px solid var(--ink);
    margin-left: 12px;
}

.panel-note {
    margin: 18px 0 0;
    font-size: 13px;
}

.section-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    margin-bottom: 18px;
}

.card-grid {
    display: grid;
    gap: 0;
}

.mini-card,
.artifact-row,
.featured-link {
    border: 1px solid var(--line);
    border-radius: 0;
    background: var(--surface-strong);
}

.mini-card {
    padding: 14px 0;
    border-width: 0 0 1px;
}

.mini-card:first-child {
    padding-top: 4px;
}

.mini-card:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.mini-card p,
.artifact-row span:last-child {
    margin: 0;
    font-size: 13px;
}

.artifact-list {
    display: grid;
    gap: 0;
}

.artifact-row {
    display: grid;
    grid-template-columns: 160px minmax(0, 1fr);
    gap: 8px;
    padding: 12px 0;
    border-width: 0 0 1px;
}

.artifact-row:last-child {
    border-bottom: 0;
}

.artifact-row span:first-child,
.featured-hash {
    color: var(--ink);
}

.featured-panel {
    min-height: 100%;
}

.featured-artifact {
    min-height: 168px;
}

.featured-link {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 16px;
    align-items: center;
    padding: 0;
    border: 0;
}

.featured-link:hover {
    text-decoration: none;
}

.featured-link img {
    width: 120px;
    height: 120px;
    object-fit: contain;
}

.featured-hash,
.artifact-card code {
    font-size: 16px;
    margin: 0 0 6px;
}

.footer {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 12px 24px;
    padding: 28px 0 0;
    font-size: 12px;
    border-top: 1px solid var(--line);
}

.nav {
    display: inline-block;
    margin: 0 0 12px;
}

.nav-inline {
    margin: 0 0 28px;
}

.archive-page,
.artifact-page {
    max-width: 760px;
    margin: 0 auto;
    padding-top: 32px;
}

.page-header {
    margin-bottom: 40px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--line);
}

.page-kicker {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 11px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.page-title {
    font-family: Palatino, "Palatino Linotype", "Book Antiqua", serif;
    margin: 0;
    font-size: clamp(22px, 5vw, 34px);
    line-height: 1.08;
    font-weight: 400;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.page-intro {
    max-width: 44ch;
    margin: 14px 0 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
}

.artifact-header {
    margin-bottom: 32px;
}

.artifact-hashline {
    margin: 18px 0 0;
    font-size: 14px;
}

#gallery,
.artifact-page {
    padding-bottom: 80px;
}

#gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 200px));
    gap: 24px;
    justify-content: center;
    margin: 40px auto 0;
}

.artifact-card {
    border-radius: 0;
    padding: 20px;
    text-align: center;
}

.artifact-card img {
    display: block;
    width: 180px;
    height: 180px;
    object-fit: contain;
    margin-bottom: 16px;
}

.artifact-detail-card {
    border-radius: 0;
    padding: 24px 20px;
    text-align: center;
}

.artifact-detail-sigil {
    display: block;
    width: min(260px, 100%);
    margin: 0 auto 24px;
}

.artifact-detail-qr {
    display: block;
    width: 160px;
    margin: 0 auto 24px;
}

code {
    display: inline-block;
}

code,
pre {
    overflow-wrap: anywhere;
    word-break: break-word;
}

pre {
    border: 1px solid var(--line);
    background: var(--surface-strong);
    padding: 16px;
    text-align: left;
    white-space: pre-wrap;
}

@media (max-width: 820px) {
    .hero,
    .section-grid,
    .featured-link,
    .artifact-row {
        grid-template-columns: 1fr;
    }

    .home {
        padding-top: 28px;
    }

    .archive-page,
    .artifact-page {
        padding-top: 24px;
    }

    .hero-copy,
    .hero-panel,
    .panel {
        padding: 22px;
    }

    .featured-link img {
        width: min(180px, 100%);
        height: auto;
    }

    .footer {
        flex-direction: column;
    }
}
