/* Home page — the wordmark and the side rail.
   The editor surface itself lives in editor.css. */

/* The wordmark is art, not text: it keeps its own tight leading so the
   glyphs touch, and JS scales it to whatever width is available, rounding
   this box to a whole number of grid rows. */
.banner-box {
    overflow: hidden;
    height: calc(var(--lh) * 5);
}

.doc pre.banner {
    color: var(--comment);
    font-size: 14px;
    line-height: 1.31;
    transform-origin: top left;
    user-select: none;
}

/* ---- side rail ---------------------------------------------------- */

/* The rail belongs to the content, not the chrome: it arrives with the doc. */
.doc.booting ~ .footer { opacity: 0; }

.footer {
    transition: opacity 0.5s ease;
    position: fixed;
    top: 20%;
    right: 0;
    height: 60%;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding-right: 80px;
    font-family: 'Times New Roman', Times, serif;
    z-index: 1000;
}

.footer-vertical {
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.footer-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    right: 53px;
    top: 50%;
    transform: translateY(-50%);
    gap: 20px;
}

.footer-links a {
    color: var(--rail);
    text-decoration: none;
    font-size: 12px;
    opacity: 0.7;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: opacity 0.2s;
}

.footer-links a:hover {
    opacity: 1;
    text-decoration: underline;
    color: var(--fg);
}

.footer-links a::before,
.footer-links a::after {
    content: '';
    width: 1px;
    height: 60px;
    border-left: 1px dashed rgb(255, 255, 255);
    opacity: 0.5;
}

.footer-links a::before { margin-bottom: 5px; }
.footer-links a::after  { margin-top: 5px; }

/* Below the width the fixed rail needs, it rejoins the document flow. */
@media (max-width: 1150px) {
    .footer {
        position: static;
        height: auto;
        padding: 0;
        display: block;
    }

    .footer-vertical { display: block; height: auto; }

    .footer-links {
        position: static;
        transform: none;
        flex-direction: row;
        gap: 26px;
        margin: calc(var(--lh) * 2) 0 0 160px;
    }

    .footer-links a { display: inline; }

    .footer-links a::before,
    .footer-links a::after { display: none; }
}

@media (max-width: 1000px) {
    .footer-links { margin-left: 56px; }
}

@media (max-width: 640px) {
    .footer-links {
        margin-left: 36px;
        gap: 20px;
    }
}
