:root {
    --paper: #F7EEEE;
    --ink: #AC0404;
    --shadow: #D89997;
    --sky: #9E2116;
    --c1: #F1DFDF;
    --c2: #E5BEBE;
    --c3: #E39595;
    --c4: #D27676;
    --c5: #EA4444;
    --c6: #FA2727;
    --star0: #E5BEBE;
    --star1: #E39595;
    --star2: #D27676;
    --star3: #F1DFDF;
    --hi: #E39595;
    --bg: color-mix(in srgb, var(--sky) var(--sky-t, 0%), var(--paper));
    --head: "futura-100-cyrillic", "Noto Sans SC", sans-serif;
    --body: "futura-100-cyrillic-book", "futura-100-cyrillic", "Noto Sans SC", sans-serif;
}

html, body {
    background: var(--bg);
}

body {
    position: relative;
    color: var(--ink);
    font: 400 17px/1.5 var(--body);
}

body > nav, body > section, body > footer {
    position: relative;
    z-index: 1;
}

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

a:hover {
    color: var(--c6);
}

a[href="query.html"] {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.content {
    color: inherit;
}

b, strong {
    font-family: var(--head);
    font-weight: 600;
    color: var(--ink);
}

em {
    font-style: italic;
}

h1.title, h2, .card-header-title, .content strong {
    font-family: var(--head);
}

.hero-body {
    padding-top: 0;
    padding-bottom: 0;
}

.hero h1.title {
    margin-bottom: .4em;
    color: var(--ink);
    font-size: clamp(3rem, 12vw, 5rem);
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0;
    text-shadow: -.05em -.05em 0 var(--paper), .035em .035em 0 var(--shadow);
}

#rotating-name {
    display: inline-block;
}

.intro, .footer p {
    paint-order: stroke fill;
    -webkit-text-stroke: 6px var(--paper);
}

h2, .content strong {
    color: var(--ink);
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 3px;
    text-transform: uppercase;
}

h2.has-text-centered {
    display: flex;
    align-items: center;
    gap: 10px;
}

h2.has-text-centered::before, h2.has-text-centered::after {
    content: "";
    flex: 1;
    height: 1px;
    background: var(--ink);
    box-shadow: 0 3px 0 var(--c3), 0 6px 0 var(--c2);
}

.navbar {
    background: none;
}

body > nav.navbar {
    padding: 0 1.5rem;
}

@media (min-width: 769px) {
    body > nav.navbar {
        padding: 0 3rem;
    }
}

.navbar > .container {
    position: relative;
}

.navbar-brand {
    margin-left: 0;
}

.navbar-start .navbar-item:first-child {
    padding-left: 0;
}

.navbar .navbar-item:hover {
    background: none;
}

.navbar-burger span {
    background: var(--ink);
}

.card {
    margin: 0 20px 20px 0;
    border: 2px solid var(--ink);
    background: #fff;
    box-shadow: 5px 5px 0 var(--c6), 10px 10px 0 var(--c3);
    transition: transform .15s, box-shadow .15s;
}

.card:hover {
    transform: translate(-4px, -4px);
    box-shadow:
        5px 5px 0 var(--c6),
        10px 10px 0 var(--c5),
        15px 15px 0 var(--c4),
        20px 20px 0 var(--c3),
        25px 25px 0 var(--c2),
        30px 30px 0 var(--c1);
}

.card, .card > * {
    border-radius: 0;
}

.card-header {
    background: var(--ink);
    box-shadow: none;
}

.card-header-title {
    color: var(--paper);
    font-size: 1.2em;
    font-weight: 600;
    line-height: 1.2;
    text-shadow: 2px 2px 0 color-mix(in srgb, var(--ink) 55%, #000);
}

.card-content em:last-of-type, .card-content em:has(+ em:last-of-type) {
    font-family: var(--head);
    font-style: normal;
}

.card-footer, .card-footer-item {
    border-color: var(--ink);
}

.card-footer:hover a {
    background: var(--ink);
    color: var(--paper);
}

.footer {
    background: none;
}

.footer, .footer a {
    color: var(--paper);
}

.footer a:hover {
    color: var(--hi);
}

.footer p {
    -webkit-text-stroke-color: var(--bg);
}

.stars {
    position: fixed;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.stars div {
    position: absolute;
    inset: -100% 0 0;
}

.stars i, .stars b {
    position: absolute;
    display: block;
}

.skyline {
    --sk-bg: var(--bg);
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    pointer-events: none;
    color: var(--ink);
    line-height: 0;
    filter: drop-shadow(2px 2px 0 var(--paper));
}

.skyline svg {
    display: block;
}

.rocket {
    position: fixed;
    top: 50px;
    right: 10px;
    width: 36px;
    height: 36px;
    pointer-events: none;
    filter: drop-shadow(2px 2px 0 var(--paper));
}

.rocket svg {
    width: 100%;
    height: 100%;
    overflow: visible;
    fill: var(--ink);
    transform: rotate(-45deg);
}

.rocket .window {
    fill: var(--paper);
}

.rocket .flame {
    transform-box: fill-box;
    transform-origin: 100% 0;
    animation: flicker .35s ease-in-out infinite alternate;
}

@keyframes flicker {
    from { transform: translate(2px, 2px) scale(.97); }
    to { transform: translate(-6px, 10px) scale(1.03); }
}

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

.palette-picker {
    position: absolute;
    top: 0;
    right: 0;
    z-index: 2;
    display: flex;
    align-items: center;
    height: 3.25rem;
}

@media (max-width: 1023px) {
    .palette-picker {
        right: 3.25rem;
    }
}

.palette-picker button {
    display: block;
    margin: 0;
    padding: 0;
    border: 0;
    background: none;
    cursor: pointer;
}

.palette-picker button:focus-visible {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}

.swatch {
    display: flex;
    border: 2px solid var(--ink);
}

.swatch i {
    display: block;
    width: 7px;
    height: 14px;
}

.palette-current i:nth-child(1) { background: var(--paper); }
.palette-current i:nth-child(2) { background: var(--shadow); }
.palette-current i:nth-child(3) { background: var(--c5); }
.palette-current i:nth-child(4) { background: var(--c6); }
.palette-current i:nth-child(5) { background: var(--ink); }

.palette-menu {
    position: absolute;
    top: calc(100% - 8px);
    right: 0;
    display: grid;
    grid-template-columns: repeat(2, auto);
    gap: 8px;
    padding: 8px;
    border: 2px solid var(--ink);
    background: var(--paper);
    box-shadow: 4px 4px 0 var(--ink);
}

.palette-menu[hidden] {
    display: none;
}

.palette-menu [aria-current="true"] .swatch {
    outline: 2px solid var(--ink);
    outline-offset: 2px;
}
