.download-page {
    --download-ink: #f5ead3;
    --download-muted: #c8b89e;
    --download-line: rgba(209, 168, 99, .32);
    --download-gold: #d7ab63;
    --download-gold-bright: #f1d59a;
    min-height: 80vh;
    color: var(--download-ink);
    font-family: Georgia, 'Times New Roman', serif;
    background:
        radial-gradient(circle at 85% 3%, rgba(159, 94, 45, .15), transparent 27rem),
        linear-gradient(180deg, rgba(8, 8, 8, .18), rgba(8, 8, 8, .68));
}

.download-shell {
    width: min(100% - 2rem, 92rem);
    margin-inline: auto;
}

.download-hero {
    position: relative;
    overflow: hidden;
    padding: clamp(2.5rem, 5vw, 4.5rem) 0 clamp(2rem, 4vw, 3rem);
    border-bottom: 1px solid var(--download-line);
    background:
        linear-gradient(110deg, rgba(13, 15, 17, .96), rgba(37, 27, 20, .78)),
        url('../images/map_good.jpg') center 43% / cover;
    isolation: isolate;
}

.download-hero::before,
.download-hero::after {
    position: absolute;
    content: '';
    pointer-events: none;
}

.download-hero::before {
    inset: 0;
    z-index: -1;
    opacity: .22;
    background-image: repeating-linear-gradient(115deg, transparent 0 19px, rgba(255, 239, 198, .06) 20px 21px);
}

.download-hero::after {
    right: -7rem;
    bottom: -12rem;
    width: 34rem;
    height: 34rem;
    border: 1px solid rgba(215, 171, 99, .22);
    border-radius: 50%;
    box-shadow: 0 0 0 3rem rgba(215, 171, 99, .04), 0 0 0 7rem rgba(215, 171, 99, .025);
}

.download-eyebrow {
    margin: 0 0 .75rem;
    color: var(--download-gold-bright);
    font: 700 .75rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    letter-spacing: .19em;
    text-transform: uppercase;
}

.download-hero-grid {
    display: grid;
    gap: 2rem;
    align-items: end;
}

.download-title {
    max-width: 18ch;
    margin: 0;
    font-family: 'MyCustomFont', Georgia, serif;
    font-size: clamp(2.65rem, 7vw, 6.3rem);
    font-weight: 400;
    line-height: .92;
    text-wrap: balance;
    text-shadow: 0 4px 26px #000;
}

.download-intro {
    max-width: 52rem;
    margin: 1.35rem 0 0;
    color: #dfd2be;
    font-size: clamp(1rem, 2vw, 1.25rem);
    line-height: 1.65;
}

.download-ledger {
    display: flex;
    width: fit-content;
    min-width: 10rem;
    padding: 1rem 1.25rem;
    flex-direction: column;
    border: 1px solid rgba(238, 205, 148, .35);
    border-radius: .25rem;
    background: rgba(12, 12, 12, .5);
    box-shadow: inset 0 0 0 3px rgba(0, 0, 0, .22);
}

.download-ledger-number {
    color: var(--download-gold-bright);
    font-family: 'MyCustomFont', Georgia, serif;
    font-size: 2.9rem;
    line-height: 1;
}

.download-ledger-label {
    margin-top: .35rem;
    color: var(--download-muted);
    font-size: .8rem;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.download-layout {
    padding-block: 1.5rem 5rem;
}

.download-steps {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.4rem;
    align-items: stretch;
}

.download-card {
    position: relative;
    display: flex;
    min-width: 0;
    gap: 1.5rem;
    padding: clamp(1.25rem, 2.5vw, 2rem);
    border: 1px solid var(--download-line);
    border-top: 3px solid rgba(215, 171, 99, .72);
    border-radius: .45rem;
    background: radial-gradient(circle at 36% 0, rgba(215, 171, 99, .01), transparent 16%), linear-gradient(45deg, rgba(29, 36, 48, 0.3), rgba(26, 23, 21, .45));
    box-shadow: 0 .9rem 2.5rem rgba(0, 0, 0, .2);
}

.download-card-wide {
    grid-column: auto;
}

#download-game {
    grid-column: 1 / -1;
    min-height: clamp(20rem, 31vw, 27rem);
    align-items: center;
    border-color: rgba(238, 205, 148, .55);
    border-top-color: var(--download-gold-bright);
    background:
        linear-gradient(90deg, #171411 0%, rgba(23, 20, 17, .97) 30%, rgba(23, 20, 17, .55) 67%, rgba(23, 20, 17, .14) 100%),
        url('../images/download_page.jpg') center 52% / cover;
    box-shadow: 0 1.2rem 3rem rgba(0, 0, 0, .33), inset 0 0 0 4px rgba(0, 0, 0, .28);
}

#download-game .download-card-body {
    max-width: 36rem;
}

#download-game .download-step-number {
    position: absolute;
    top: 1.25rem;
    left: 1.5rem;
    padding: .35rem .55rem;
    border: 1px solid rgba(238, 205, 148, .5);
    border-radius: .2rem;
    background: rgba(14, 12, 11, .72);
    font-size: 1.55rem;
}

#download-game h2 {
    font-size: clamp(2.2rem, 4vw, 3.7rem);
}

#download-game p {
    color: #e9dcc5;
    font-size: clamp(1rem, 1.5vw, 1.18rem);
}

#download-game .download-action {
    min-height: 3.35rem;
    padding-inline: 1.5rem;
    font-size: 1.1rem;
}

.download-step-number {
    flex: 0 0 auto;
    color: var(--download-gold-bright);
    font: 400 clamp(2rem, 3vw, 3rem)/1 'MyCustomFont', Georgia, serif;
    text-shadow: 0 2px 14px rgba(0, 0, 0, .6);
}

.download-card-body {
    min-width: 0;
    width: 100%;
}

.download-card h2 {
    margin: 0 0 .9rem;
    color: #fff5df;
    font-family: 'MyCustomFont', Georgia, serif;
    font-size: clamp(1.5rem, 2.2vw, 2.1rem);
    font-weight: 400;
    line-height: 1.13;
    text-wrap: balance;
}

.download-card p,
.download-checklist {
    max-width: 66rem;
    margin: 0 0 1.3rem;
    color: var(--download-muted);
    font-size: 1rem;
    line-height: 1.65;
    overflow-wrap: anywhere;
}

.download-card p a {
    color: var(--download-gold-bright);
    text-decoration: underline;
    text-underline-offset: .2em;
}

.download-checklist {
    display: grid;
    gap: .55rem;
    padding-left: 1.25rem;
    list-style: disc;
}

.download-checklist li::marker {
    color: var(--download-gold);
}

.download-action {
    display: inline-flex;
    max-width: 100%;
    min-height: 2.85rem;
    padding: .7rem 1.1rem;
    align-items: center;
    justify-content: center;
    gap: .65rem;
    border: 1px solid #e8bd79;
    border-radius: .3rem;
    color: #201811;
    background: var(--download-gold);
    font-size: .98rem;
    font-weight: 700;
    line-height: 1.25;
    text-align: center;
    text-decoration: none;
    overflow-wrap: anywhere;
    transition: background 150ms ease, transform 150ms ease;
}

.download-action:hover,
.download-action:focus-visible {
    color: #17120e;
    background: var(--download-gold-bright);
    transform: translateY(-2px);
}

.download-action:focus-visible,
.download-patch summary:focus-visible,
.download-patch-list summary:focus-visible {
    outline: 2px solid var(--download-gold-bright);
    outline-offset: 3px;
}

.download-action-small {
    min-height: 2.4rem;
    padding: .5rem .8rem;
    font-size: .87rem;
}

.download-action-outline {
    border-color: var(--download-line);
    color: var(--download-gold-bright);
    background: rgba(215, 171, 99, .08);
}

.download-mirror-actions {
    display: flex;
    flex-wrap: wrap;
    gap: .65rem;
}

.download-card .download-note {
    padding: .8rem 1rem;
    border-left: 2px solid var(--download-gold);
    background: rgba(215, 171, 99, .06);
}

.download-patch-list {
    min-width: 0;
    border: 1px solid var(--download-line);
    border-radius: .35rem;
    background: rgba(14, 13, 12, .56);
}

.download-patch-list summary {
    cursor: pointer;
    list-style: none;
}

.download-patch-list summary::-webkit-details-marker {
    display: none;
}

.download-patch-list-summary,
.download-patch-summary {
    display: flex;
    min-width: 0;
    padding: .85rem 1rem;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    color: var(--download-gold-bright);
}

.download-patch-list-summary {
    font-size: 1.12rem;
    font-weight: 700;
}

.download-patch-list-summary:hover,
.download-patch-summary:hover {
    background: rgba(215, 171, 99, .08);
}

.download-chevron {
    flex: 0 0 auto;
    font: 1.45rem/1 Georgia, serif;
    transition: transform 150ms ease;
}

.download-patch-list[open]>summary .download-chevron,
.download-patch[open]>summary .download-chevron {
    transform: rotate(180deg);
}

.download-patch-list-body {
    max-height: min(70vh, 42rem);
    overflow-y: auto;
    border-top: 1px solid var(--download-line);
}

.download-patch {
    border-bottom: 1px solid rgba(209, 168, 99, .16);
}

.download-patch:last-child {
    border-bottom: 0;
}

.download-patch-summary {
    color: var(--download-ink);
    font-size: 1rem;
}

.download-patch-version {
    min-width: 0;
    overflow-wrap: anywhere;
}

.download-patch-content {
    min-width: 0;
    padding: .2rem 1rem 1.15rem;
}

.download-archive-name {
    min-width: 0;
    overflow-wrap: anywhere;
}

.download-patch-content .patch-text {
    margin-top: .9rem;
    color: var(--download-muted);
    font-size: .94rem;
    line-height: 1.6;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}

.download-patch-content .patch-text:empty {
    display: none;
}

@media (min-width: 768px) {
    .download-hero-grid {
        grid-template-columns: minmax(0, 1fr) auto;
    }
}

@media (max-width: 760px) {
    .download-steps {
        grid-template-columns: minmax(0, 1fr);
    }

    .download-card-wide {
        grid-column: auto;
    }

    #download-game {
        grid-column: auto;
        min-height: 25rem;
        align-items: flex-end;
        background:
            linear-gradient(0deg, #171411 0%, rgba(23, 20, 17, .93) 33%, rgba(23, 20, 17, .2) 100%),
            url('../images/download_page.jpg') 52% center / cover;
    }
}

@media (max-width: 420px) {
    .download-card {
        gap: .8rem;
    }

    .download-mirror-actions .download-action {
        width: 100%;
    }
}