/* ==========================================================================
   Jaroška — main stylesheet
   ========================================================================== */

/* Fonts ------------------------------------------------------------------- */

/* Kapitan has a single weight (Medium). The range maps every requested weight
   to it, so browsers never fake a bold. */
@font-face {
    font-family: "Kapitan";
    src: url("../fonts/kapitan-500.woff2") format("woff2");
    font-weight: 400 700;
    font-display: swap;
}
@font-face {
    font-family: "Clear Sans";
    src: url("../fonts/clear-sans-400.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: "Clear Sans";
    src: url("../fonts/clear-sans-400i.woff2") format("woff2");
    font-weight: 400;
    font-style: italic;
    font-display: swap;
}
@font-face {
    font-family: "Clear Sans";
    src: url("../fonts/clear-sans-500.woff2") format("woff2");
    font-weight: 500;
    font-display: swap;
}
@font-face {
    font-family: "Clear Sans";
    src: url("../fonts/clear-sans-700.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}

/* Tokens ------------------------------------------------------------------ */

:root {
    --red: #d22238;
    --red-dark: #a8172b;
    --ink: #232323;
    --text: #4d4d4d;
    --muted: #6b6b6b;
    --bg: #f0f0f0;
    --card: #f1f1f1;
    --white: #fff;
    --dark: #444;
    --black: #050505;

    --font-display: "Kapitan", Georgia, "Times New Roman", serif;
    --font-body: "Clear Sans", "Segoe UI", system-ui, sans-serif;
    --font-cloud: "Helvetica Neue", Helvetica, Arial, sans-serif;

    --radius: 12px;
    --radius-sm: 7px;
    --shadow: 0 10px 30px rgb(0 0 0 / 0.18);
    --shadow-sm: 0 6px 16px rgb(0 0 0 / 0.16);

    --container: 1240px;
    --gutter: clamp(1rem, 3vw, 1.75rem);
    --header-top: clamp(0.5rem, 1.2vw, 1rem);
    --header-h: 3.6rem;
    /* How far the intro cards reach up into the hero. */
    --overlap: clamp(9rem, 26svh, 17rem);
}

/* Base -------------------------------------------------------------------- */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-padding-top: calc(var(--header-h) + 2rem);
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 1rem;
    line-height: 1.55;
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: var(--red);
}

h1, h2, h3, h4 {
    color: var(--ink);
    line-height: 1.15;
}

:focus-visible {
    outline: 3px solid var(--red);
    outline-offset: 2px;
}

.container {
    width: 100%;
    max-width: calc(var(--container) + 2 * var(--gutter));
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.container--narrow {
    max-width: calc(860px + 2 * var(--gutter));
}

.screen-reader-text {
    position: absolute !important;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.skip-link:focus {
    position: fixed !important;
    top: 1rem;
    left: 1rem;
    z-index: 100;
    width: auto;
    height: auto;
    clip: auto;
    padding: 0.75rem 1rem;
    background: var(--white);
    border-radius: var(--radius-sm);
}

.section-title {
    margin: 0;
    font-family: var(--font-display);
    font-weight: 400;
    color: var(--red);
    font-size: clamp(2rem, 3vw, 2.6rem);
    letter-spacing: -0.01em;
}

/* Header ------------------------------------------------------------------ */

.site-header {
    position: fixed;
    inset: var(--header-top) 0 auto;
    z-index: 50;
    padding-inline: var(--gutter);
    pointer-events: none;
}

.site-header__bar {
    pointer-events: auto;
    max-width: var(--container);
    min-height: var(--header-h);
    margin-inline: auto;
    padding: 0.4rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: rgb(241 241 241 / 0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: var(--radius);
    box-shadow: 0 2px 12px rgb(0 0 0 / 0.08);
    transition: box-shadow 0.2s;
}

.site-header.is-scrolled .site-header__bar {
    box-shadow: var(--shadow);
}

.brand {
    display: flex;
    align-items: center;
    flex: none;
    text-decoration: none;
}

.brand__logo {
    width: auto;
    height: 2rem;
    max-width: none;
    aspect-ratio: 2045 / 284;
    object-fit: contain;
}

.site-header__menu {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.5rem;
}

.site-nav {
    flex: 1;
    display: flex;
    justify-content: center;
}

.site-nav .menu,
.site-nav .sub-menu,
.quick-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.site-nav .menu {
    display: flex;
    gap: clamp(0.25rem, 2.2vw, 2.25rem);
}

.site-nav .menu > li {
    position: relative;
}

/* Parent item without a target (inc/navigation.php): a button styled like the links. */
.site-nav .menu-parent {
    margin: 0;
    font: inherit;
    background: none;
    border: 0;
    cursor: pointer;
}

.site-nav .menu > li > :is(a, .menu-parent) {
    display: block;
    padding: 0.55rem 0.5rem;
    color: #444;
    font-weight: 700;
    font-size: 1.08rem;
    letter-spacing: 0.01em;
    text-decoration: none;
    white-space: nowrap;
    border-bottom: 2px solid transparent;
}

.site-nav .menu > li:hover > :is(a, .menu-parent),
.site-nav .menu > li:focus-within > :is(a, .menu-parent),
.site-nav .menu > .current-menu-item > a,
.site-nav .menu > .current-menu-ancestor > :is(a, .menu-parent) {
    color: var(--red);
    border-bottom-color: var(--red);
}

.site-nav .sub-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    min-width: 15rem;
    padding: 0.6rem;
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow);
    opacity: 0;
    visibility: hidden;
    transform: translate(-50%, 0.4rem);
    transition: opacity 0.15s, transform 0.15s, visibility 0.15s;
}

.site-nav .sub-menu::before {
    /* Hover bridge between the item and its dropdown. */
    content: "";
    position: absolute;
    inset: -0.75rem 0 100%;
}

.site-nav .menu > li:hover > .sub-menu,
.site-nav .menu > li:focus-within > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, 0.25rem);
}

.site-nav .sub-menu a {
    display: block;
    padding: 0.45rem 0.75rem;
    border-radius: 5px;
    color: var(--ink);
    font-size: 0.93rem;
    text-decoration: none;
}

.site-nav .sub-menu a:hover,
.site-nav .sub-menu a:focus-visible {
    background: var(--bg);
    color: var(--red);
}

.submenu-toggle {
    display: none;
}

.quick-links {
    display: flex;
    gap: 0.6rem;
}

.quick-links a {
    display: grid;
    place-items: center;
    width: 1.3rem;
    height: 1.3rem;
    transition: transform 0.15s;
}

.quick-links a:hover {
    transform: translateY(-1px);
}

.quick-links .icon {
    width: 100%;
    height: 100%;
    background: var(--red);
    -webkit-mask: var(--icon) center / contain no-repeat;
    mask: var(--icon) center / contain no-repeat;
    transition: background 0.15s;
}

.quick-links a:hover .icon {
    background: var(--red-dark);
}

.quick-links--light .icon {
    background: var(--white);
}

.quick-links--light a:hover .icon {
    background: var(--red);
}

.nav-toggle {
    display: none;
}

/* Mobile header */
@media (max-width: 1060px) {
    :root {
        --header-h: 3.4rem;
    }

    .site-header__bar {
        flex-wrap: wrap;
        padding: 0.35rem 1rem;
        max-height: calc(100svh - 2 * var(--header-top));
        overflow-y: auto;
    }

    .nav-toggle {
        display: grid;
        place-items: center;
        margin-left: auto;
        width: 2.75rem;
        height: 2.75rem;
        padding: 0;
        border: 0;
        border-radius: var(--radius-sm);
        background: transparent;
        cursor: pointer;
    }

    .nav-toggle__bars,
    .nav-toggle__bars::before,
    .nav-toggle__bars::after {
        display: block;
        width: 1.5rem;
        height: 2px;
        background: var(--ink);
        transition: transform 0.2s, background 0.2s;
    }

    .nav-toggle__bars {
        position: relative;
    }

    .nav-toggle__bars::before,
    .nav-toggle__bars::after {
        content: "";
        position: absolute;
        left: 0;
    }

    .nav-toggle__bars::before { top: -7px; }
    .nav-toggle__bars::after { top: 7px; }

    .nav-toggle[aria-expanded="true"] .nav-toggle__bars { background: transparent; }
    .nav-toggle[aria-expanded="true"] .nav-toggle__bars::before { transform: translateY(7px) rotate(45deg); }
    .nav-toggle[aria-expanded="true"] .nav-toggle__bars::after { transform: translateY(-7px) rotate(-45deg); }

    .site-header__menu {
        display: none;
        flex-basis: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
        padding: 0.5rem 0 0.75rem;
    }

    .site-header.is-open .site-header__menu {
        display: flex;
    }

    .site-nav {
        justify-content: stretch;
    }

    .site-nav .menu {
        flex-direction: column;
        gap: 0;
        width: 100%;
    }

    .site-nav .menu > li {
        display: flex;
        flex-wrap: wrap;
        border-top: 1px solid rgb(0 0 0 / 0.08);
    }

    .site-nav .menu > li > :is(a, .menu-parent) {
        flex: 1;
        padding: 0.8rem 0.25rem;
        border: 0;
    }

    /* The parent button spans the row and carries the same chevron as .submenu-toggle. */
    .site-nav .menu > li > .menu-parent {
        display: flex;
        align-items: center;
        justify-content: space-between;
        text-align: left;
        color: #444;
    }

    .site-nav .menu-parent::after {
        content: "";
        width: 0.55rem;
        height: 0.55rem;
        margin-right: 1.1rem;
        border: solid var(--ink);
        border-width: 0 2px 2px 0;
        transform: rotate(45deg) translateY(-2px);
        transition: transform 0.2s;
    }

    .site-nav .menu-parent[aria-expanded="true"]::after {
        transform: rotate(-135deg) translateY(-2px);
    }

    .submenu-toggle {
        display: grid;
        place-items: center;
        width: 2.75rem;
        border: 0;
        background: none;
        color: var(--ink);
        cursor: pointer;
    }

    .submenu-toggle::before {
        content: "";
        width: 0.55rem;
        height: 0.55rem;
        border: solid currentColor;
        border-width: 0 2px 2px 0;
        transform: rotate(45deg) translateY(-2px);
        transition: transform 0.2s;
    }

    .submenu-toggle[aria-expanded="true"]::before {
        transform: rotate(-135deg) translateY(-2px);
    }

    .site-nav .sub-menu,
    .site-nav .menu > li:hover > .sub-menu,
    .site-nav .menu > li:focus-within > .sub-menu {
        position: static;
        flex-basis: 100%;
        display: none;
        min-width: 0;
        padding: 0 0 0.6rem 0.5rem;
        box-shadow: none;
        background: none;
        opacity: 1;
        visibility: visible;
        transform: none;
    }

    .site-nav .sub-menu::before {
        display: none;
    }

    .site-nav li.is-open > .sub-menu {
        display: block;
    }

    .quick-links {
        align-self: flex-start;
        padding: 0;
    }

    .quick-links a {
        width: 2rem;
        height: 2rem;
    }
}

/* Main offset for pages without the hero */
body:not(.home) .site-main {
    padding-top: calc(var(--header-top) + var(--header-h));
}

/* Hero slider -------------------------------------------------------------- */

.hero {
    position: relative;
    height: min(100svh, 76vw);
    min-height: 34rem;
    overflow: hidden;
    background: var(--black);
    color: var(--white);
}

.hero__slides,
.hero__slide {
    position: absolute;
    inset: 0;
    margin: 0;
}

.hero__slide {
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.9s ease, visibility 0.9s;
}

.hero__slide.is-active {
    opacity: 1;
    visibility: visible;
}

.hero__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hero__slide::after {
    /* Long, eased fade into the black band; it completes behind the cards. */
    content: "";
    position: absolute;
    inset: auto 0 0;
    height: calc(var(--overlap) + 20rem);
    background: linear-gradient(
        to bottom,
        rgb(5 5 5 / 0) 0%,
        rgb(5 5 5 / 0.08) 18%,
        rgb(5 5 5 / 0.22) 34%,
        rgb(5 5 5 / 0.42) 48%,
        rgb(5 5 5 / 0.64) 60%,
        rgb(5 5 5 / 0.84) 72%,
        rgb(5 5 5 / 0.96) 84%,
        rgb(5 5 5) 100%
    );
    pointer-events: none;
}

.hero__caption {
    position: absolute;
    z-index: 1;
    left: 50%;
    bottom: calc(var(--overlap) + 5rem);
    width: min(90%, 44rem);
    transform: translateX(-50%);
    text-align: center;
    text-shadow: 0 1px 12px rgb(0 0 0 / 0.55);
}

.hero__slide.is-active .hero__caption {
    animation: caption-in 0.9s ease both;
}

@keyframes caption-in {
    from { opacity: 0; transform: translate(-50%, 0.75rem); }
}

.hero__title {
    display: block;
    font-size: clamp(1.6rem, 2.6vw, 2.1rem);
    font-weight: 700;
    line-height: 1.1;
}

.hero__text {
    display: block;
    margin-top: 0.2rem;
    font-size: clamp(1rem, 1.4vw, 1.2rem);
}

.hero__dots {
    position: absolute;
    z-index: 2;
    left: 50%;
    bottom: calc(var(--overlap) + 1.75rem);
    transform: translateX(-50%);
    display: flex;
    gap: 0.9rem;
}

.hero__dot {
    width: 1.15rem;
    height: 1.15rem;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgb(190 190 190 / 0.75);
    cursor: pointer;
    transition: background 0.2s, transform 0.2s;
}

.hero__dot:hover {
    transform: scale(1.12);
}

.hero__dot.is-active {
    background: var(--white);
}

/* Intro cards -------------------------------------------------------------- */

.intro {
    /* flow-root stops the cards' negative margin from collapsing into this
       section, which would drag the black band up over the hero. */
    display: flow-root;
    position: relative;
    background: var(--black);
    padding-bottom: 3rem;
}

.intro__grid {
    position: relative;
    z-index: 3;
    margin-top: calc(-1 * var(--overlap));
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
    align-items: stretch;
}

.intro-card {
    padding: 2.6rem 1.4rem 2rem 1.25rem;
    background: var(--card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.intro-card__title {
    margin: 0 0 1.2rem;
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2rem, 2.9vw, 2.6rem);
    line-height: 1.05;
    color: var(--red);
    letter-spacing: -0.01em;
}

.point + .point {
    margin-top: 1.4rem;
}

.point__title {
    margin: 0;
    padding-left: 1.1rem;
    border-left: 3px solid var(--red);
    font-family: var(--font-body);
    font-weight: 700;
    font-size: 1.22rem;
    line-height: 1.25;
    letter-spacing: 0.025em;
    color: var(--ink);
}

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

.point__title a:hover {
    color: var(--red);
}

.point__text {
    margin: 0.55rem 0 0 1.4rem;
    color: var(--text);
    font-size: 1rem;
    line-height: 1.45;
}

.tracks {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0 2.5rem;
    margin: 0.55rem 0 0 1.4rem;
    color: var(--text);
    line-height: 1.6;
}

.tracks__label {
    color: var(--muted);
}

.tracks__list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.tracks__list li::before {
    content: "●";
    margin-right: 0.45em;
    font-size: 0.55em;
    vertical-align: 0.2em;
    color: var(--muted);
}

.levels {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.75rem;
    margin: 0.9rem 0 0;
    font-size: 0.98rem;
    line-height: 1.5;
}

.levels__list {
    margin: 0;
    text-align: right;
}

.levels dt,
.levels dd {
    display: inline;
    margin: 0;
}

.levels dt {
    color: var(--red);
}

/* Život na Jarošce ------------------------------------------------------- */

.life {
    padding-block: clamp(3rem, 6vw, 4.5rem) 2rem;
}

.life__grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-flow: row dense;
    gap: 2.5rem 1.6rem;
    align-items: start;
}

.life__head {
    grid-column: 1 / span 2;
    padding: 1.4rem 2rem 1.6rem;
    background: var(--white);
    border-radius: var(--radius);
    text-align: center;
}

.pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.5rem;
    margin: 1.1rem 0 0;
    padding: 0;
    list-style: none;
}

.pill {
    display: inline-block;
    padding: 0.35rem 0.9rem;
    border: 1px solid #ddd;
    border-radius: 999px;
    color: var(--ink);
    font-size: 0.9rem;
    text-decoration: none;
    transition: border-color 0.15s, color 0.15s, background 0.15s;
}

.pill:hover {
    border-color: var(--red);
    color: var(--red);
}

.pill--all {
    border-color: var(--red);
    background: var(--red);
    color: var(--white);
}

.pill--all:hover {
    background: var(--red-dark);
    color: var(--white);
}

.tag-cloud {
    grid-column: 3;
    grid-row: 1 / span 3;
    padding: 1.1rem 1.1rem 1.4rem;
    background: var(--dark);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    font-family: var(--font-cloud);
    font-weight: 700;
    line-height: 1.75;
}

.tag-cloud a {
    color: var(--white);
    text-decoration: none;
    margin-right: 0.15em;
    white-space: nowrap;
}

.tag-cloud a:hover {
    color: #ff8c9b;
}

/* Post cards */

.post-card {
    display: flex;
    flex-direction: column;
}

.post-card__image {
    display: block;
    margin-bottom: 1.35rem;
    overflow: hidden;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
}

.post-card__image img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.post-card:hover .post-card__image img {
    transform: scale(1.03);
}

.post-card__title {
    margin: 0;
    font-family: var(--font-body);
    font-size: 1.3rem;
    font-weight: 500;
    line-height: 1.35;
}

.post-card__title a {
    color: var(--red);
    text-decoration: none;
}

.post-card__title a:hover {
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.post-card__excerpt {
    margin-top: 0.75rem;
    color: var(--text);
    font-size: 0.98rem;
    line-height: 1.65;
}

.post-card__excerpt p {
    margin: 0;
}

.post-card__date {
    margin-top: 1rem;
    color: var(--red);
    font-size: 0.85rem;
}

/* Partners ------------------------------------------------------------------ */

.partners {
    padding-block: 3rem;
}

.partners__box {
    padding: 1.25rem 1.5rem 2rem;
    background: var(--white);
    border-radius: var(--radius-sm);
}

.partners__title {
    margin: 0 0 1.25rem;
    text-align: center;
    font-size: 0.85rem;
    color: #444;
}

.partners__list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1.5rem 2.25rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.partners__list img {
    width: auto;
    max-width: 9.5rem;
    max-height: 5.5rem;
    object-fit: contain;
}

.partners__list a {
    display: block;
    transition: opacity 0.15s;
}

.partners__list a:hover {
    opacity: 0.75;
}

/* Footer ---------------------------------------------------------------------- */

.site-footer {
    background: #2e2e2e;
    color: #c9c9c9;
    font-size: 0.95rem;
}

.site-footer a {
    color: var(--white);
    text-decoration: none;
}

.site-footer a:hover {
    text-decoration: underline;
}

.site-footer__grid {
    display: grid;
    grid-template-columns: 1.4fr repeat(3, 1fr);
    gap: 2rem;
    padding-block: 3rem 2rem;
}

.site-footer__brand img {
    width: 10rem;
    height: auto;
}

.site-footer__brand p {
    margin: 0.9rem 0 1.25rem;
}

.site-footer__title {
    margin: 0 0 0.75rem;
    color: var(--white);
    font-size: 1rem;
}

.site-footer p {
    margin: 0 0 0.75rem;
}

.footer-nav ul {
    list-style: none;
    margin: 0 0 0.75rem;
    padding: 0;
}

.site-footer__bottom {
    padding-block: 1.25rem;
    border-top: 1px solid rgb(255 255 255 / 0.1);
    font-size: 0.85rem;
    color: #999;
}

.site-footer__bottom p {
    margin: 0;
}

/* Inner pages ------------------------------------------------------------- */

.page-head {
    padding-block: clamp(2.5rem, 5vw, 4rem) 1.5rem;
}

.page-head__title {
    margin: 0;
    font-family: var(--font-display);
    font-weight: 400;
    color: var(--red);
    font-size: clamp(2.1rem, 4vw, 3.1rem);
    letter-spacing: -0.01em;
}

.page-head__lead {
    margin-top: 0.75rem;
    max-width: 50rem;
}

.entry__meta {
    margin: 0 0 0.5rem;
    color: var(--muted);
    font-size: 0.9rem;
}

.entry__meta a {
    color: var(--red);
    text-decoration: none;
}

.entry__body {
    padding: clamp(1.5rem, 4vw, 2.75rem);
    background: var(--white);
    border-radius: var(--radius);
    margin-bottom: 2rem;
}

.entry__image {
    margin: 0 0 2rem;
}

.entry__image img {
    width: 100%;
    border-radius: var(--radius-sm);
}

.entry__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 2rem 0 0;
    padding: 0;
    list-style: none;
}

.entry__tags a {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: var(--bg);
    border-radius: 999px;
    color: var(--ink);
    font-size: 0.85rem;
    text-decoration: none;
}

.entry__tags a:hover {
    color: var(--red);
}

.entry__nav {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    margin-bottom: 2rem;
}

.entry__nav a {
    text-decoration: none;
    font-weight: 500;
}

.entry__nav > div:last-child {
    text-align: right;
}

.prose {
    color: #333;
    font-size: 1.05rem;
    line-height: 1.7;
    overflow-wrap: break-word;
}

.prose > :first-child { margin-top: 0; }
.prose > :last-child { margin-bottom: 0; }

.prose h2,
.prose h3 {
    margin: 2em 0 0.6em;
    font-family: var(--font-display);
    font-weight: 400;
    color: var(--red);
}

.prose h2 { font-size: 1.8rem; }
.prose h3 { font-size: 1.4rem; }

.prose img {
    border-radius: var(--radius-sm);
}

.prose figure {
    margin: 1.5em 0;
}

.prose figcaption {
    color: var(--muted);
    font-size: 0.88rem;
    margin-top: 0.4em;
}

.prose table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.95rem;
}

.prose th,
.prose td {
    padding: 0.5rem 0.6rem;
    border-bottom: 1px solid #e2e2e2;
    text-align: left;
    vertical-align: top;
}

.prose blockquote {
    margin: 1.5em 0;
    padding-left: 1.2rem;
    border-left: 3px solid var(--red);
    color: var(--muted);
}

.section {
    padding-bottom: 3rem;
}

.post-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 19rem), 1fr));
    gap: 2.5rem 1.6rem;
    align-items: start;
}

.pagination {
    margin-top: 3rem;
}

.pagination .nav-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.4rem;
}

.pagination .page-numbers {
    min-width: 2.5rem;
    padding: 0.45rem 0.8rem;
    border-radius: var(--radius-sm);
    background: var(--white);
    color: var(--ink);
    text-align: center;
    text-decoration: none;
}

.pagination .page-numbers.current,
.pagination a.page-numbers:hover {
    background: var(--red);
    color: var(--white);
}

.search-form {
    display: flex;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.search-form label {
    flex: 1;
}

.search-field {
    width: 100%;
    padding: 0.6rem 0.8rem;
    border: 1px solid #ccc;
    border-radius: var(--radius-sm);
    font: inherit;
}

.search-submit,
.button {
    display: inline-block;
    padding: 0.6rem 1.1rem;
    border: 0;
    border-radius: var(--radius-sm);
    background: var(--red);
    color: var(--white);
    font: inherit;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
}

/* Responsive ------------------------------------------------------------------ */

@media (max-width: 1060px) {
    .intro__grid {
        grid-template-columns: 1fr 1fr;
    }

    .intro-card:last-child {
        grid-column: 1 / -1;
    }

    .life__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .life__head {
        grid-column: 1 / -1;
    }

    .tag-cloud {
        grid-column: 1 / -1;
        grid-row: auto;
        order: 99;
    }

    .site-footer__grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 700px) {
    :root {
        --overlap: 6rem;
    }

    .hero {
        height: min(88svh, 170vw);
        min-height: 30rem;
    }

    .hero__image {
        object-position: 30% center !important;
    }

    .hero__caption {
        bottom: calc(var(--overlap) + 4.5rem);
    }

    .hero__dots {
        bottom: calc(var(--overlap) + 1.5rem);
    }

    .intro__grid {
        grid-template-columns: 1fr;
    }

    .intro-card {
        padding: 2rem 1.25rem 1.75rem;
    }

    .life__grid {
        grid-template-columns: 1fr;
    }

    .life__head {
        padding: 1.25rem 1rem;
    }

    .site-footer__grid {
        grid-template-columns: 1fr;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }
}
