/* changelog.css (28 Oct 2026, Matt: a changelog "beside the feedback button", as a pop-up "like how ...
   when you click an index card on ship codex, that whole pop-up menu fills most of your screen", with "a
   marker to show that something's new ... but nothing too annoying"). The Changelog button in the side
   menu, its big pop-up, and the /changelog page. Loaded by nav.php on every page (and by the page itself),
   so it has its own copy of the page's width rules: see "one content width" in root.css. Theme tokens only. */

/* ------------------------------------------------- the button, beside Feedback */
.rail-fb-row {
    display: flex;
    gap: 0.5rem;
}

.rail-fb-row > .rail-fb {
    flex: 1 1 auto;
}

.rail-fb-row > .rail-fb.rail-cl {
    position: relative;
    flex: 0 0 44px;
    padding: 0;
}

.rail-fb-row.is-cl-only > .rail-fb.rail-cl {
    flex: 1 1 auto;
    padding: 0 0.9rem;
}

/* The "new" marker: a small dot in the corner, nothing more. */
.rail-cl-dot {
    position: absolute;
    top: 5px;
    right: 5px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--accent);
    box-shadow: 0 0 0 2px var(--console, #0b0e14);
    pointer-events: none;
}

.rail-cl-dot[hidden] {
    display: none;
}

.rail-fb.rail-cl:hover .rail-cl-dot,
.rail-fb.rail-cl[aria-current="page"] .rail-cl-dot {
    background: #07090C;
}

@media (min-width: 901px) {
    html.rail-min .rail-fb-row {
        flex-direction: column;
        align-items: center;
    }

    html.rail-min .rail-fb-row > .rail-fb,
    html.rail-min .rail-fb-row > .rail-fb.rail-cl {
        flex: 0 0 auto;
        width: 42px;
        padding: 0;
    }

    html.rail-min .rail-fb-row .rail-txt {
        display: none;
    }
}

/* ------------------------------------------------- the pop-up */
.cl-backdrop {
    position: fixed;
    inset: 0;
    z-index: 1100;          /* above the side menu (1000), like the Ship Codex card */
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 3vh 1rem;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: rgba(5, 6, 8, 0.6);
}

.cl-backdrop[hidden] {
    display: none;
}

body.cl-modal-open {
    overflow: hidden;
}

.cl-modal {
    position: relative;
    width: min(1100px, 100%);
    min-height: 88vh;
    margin: auto;
    background: var(--pop, var(--sheet));
    color: var(--ink);
    border: 1px solid var(--rule);
    border-radius: 0;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.35);
    animation: cl-modal-in 0.18s ease-out;
    overscroll-behavior: contain;
}

/* The stripe band along the top, like the Ship Codex card. */
.cl-modal::before {
    content: "";
    display: block;
    height: 12px;
    background: var(--stripes-h);
    border-bottom: 1px solid var(--rule);
}

@keyframes cl-modal-in {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    .cl-modal { animation: none; }
}

.cl-modal-close {
    position: absolute;
    top: 1.6rem;
    right: 1rem;
    z-index: 2;
    width: 2.6rem;
    height: 2.6rem;
    padding: 0;
    background: var(--pop, var(--sheet));
    color: var(--ink);
    border: 1px solid var(--rule);
    border-radius: 0;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
}

.cl-modal-close:hover,
.cl-modal-close:focus-visible {
    background: var(--solid);
    color: var(--on-solid);
}

.cl-modal-inner {
    padding: 1.4rem clamp(1rem, 3vw, 2.2rem) 2rem;
}

.cl-modal-inner > h2 {
    margin: 0 3.2rem 0.3rem 0;
}

.cl-modal-sub {
    margin: 0 0 1rem;
    color: var(--ink-2);
}

.cl-modal-sub a {
    color: var(--link, var(--accent));
}

.cl-loading {
    color: var(--ink-2);
}

/* ------------------------------------------------- the list (pop-up and page) */
.cl-note {
    margin: 0 0 1rem;
    color: var(--ink-2);
}

.cl-note a {
    color: var(--link, var(--accent));
}

.cl-rel {
    padding: 1.1rem 0 0.6rem;
    border-top: 1px solid var(--rule);
}

.cl-rel:first-of-type {
    border-top: 0;
}

.cl-rel-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.4rem 0.8rem;
}

.cl-ver {
    display: inline-block;
    padding: 0.1rem 0.5rem;
    border: 1px solid var(--accent);
    color: var(--ink);
    font-family: var(--font-mono, monospace);
    font-size: 0.85rem;
    font-weight: 700;
}

.cl-date {
    color: var(--ink-2);
    font-size: 0.92rem;
}

.cl-title {
    flex: 1 1 100%;
    margin: 0.2rem 0 0;
    font-size: 1.15rem;
}

.cl-new {
    display: inline-block;
    padding: 0.05rem 0.45rem;
    background: var(--accent);
    color: var(--on-accent, #07090C);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.cl-items {
    margin: 0.6rem 0 0;
    padding: 0;
    list-style: none;
}

.cl-item {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 0.25rem 0.5rem;
    padding: 0.35rem 0;
    line-height: 1.5;
}

.cl-tag {
    display: inline-block;
    min-width: 4.8rem;
    padding: 0.05rem 0.4rem;
    border: 1px solid var(--rule);
    color: var(--ink-2);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    text-align: center;
    text-transform: uppercase;
}

.cl-tag.is-members {
    border-color: var(--accent);
    color: var(--ink);
}

.cl-tag.is-admin {
    border-color: var(--warn, var(--accent));
    color: var(--ink);
}

.cl-area {
    font-weight: 700;
}

.cl-text {
    flex: 1 1 18rem;
    color: var(--ink);
}

/* ------------------------------------------------- the /changelog page: one content width and one
   starting line, as root.css gives every page (copied here too, so a browser holding an older copy of
   root.css still lays it out right). */
main.site-content.changelog-page {
    box-sizing: border-box;     /* full width includes the gutters (no sideways scroll) */
    padding-left: var(--gutter);
    padding-right: var(--gutter);
}

main.changelog-page > :not(.os-back-bar) {
    box-sizing: border-box;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

main.changelog-page > :is(h1, h1 + p) {
    width: 100%;
    padding-left: 0;
    padding-right: 0;
}

main.changelog-page .cl-list {
    padding: 0.2rem 0 1rem;
}

/* Themes with gilded, shimmering headings (Origin) paint the words with a moving gradient: across a long
   release title it would leave the end of the words see-through. Repeated, it always covers them. */
.cl-title,
.cl-modal-inner > h2 {
    background-repeat: repeat-x !important;
}
