@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

:root {
    --bg: #e9edf1;
    --surface: #f8fafc;
    --surface-strong: #ffffff;
    --text: #18212b;
    --muted: #4e5b68;
    --line: rgba(24, 33, 43, 0.14);
    --accent: #8f3d2e;
    --accent-hover: #6f2f24;
    --accent-soft: #e8d7d2;
    --shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
    --radius: 20px;
    --content-width: 1200px;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
    font-size: 1rem;
    line-height: 1.65;
    color: var(--text);
    background:
            linear-gradient(180deg, #dfe6ec 0%, #e9edf1 38%, #f3f5f7 100%);
}

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

/* ---------- PAGE LAYOUT ---------- */

.page-grid {
    width: min(100%, var(--content-width));
    margin: 0 auto;
    padding: 16px;
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    min-height: 100vh;
}

/* ---------- HEADER ---------- */

.site-header {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(245, 248, 250, 0.94));
    border: 1px solid var(--line);
    border-radius: 24px;
    box-shadow: var(--shadow);
    padding: 24px 18px 18px;
}

.header-inner {
    max-width: 820px;
    margin: 0 auto 18px;
    text-align: center;
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.site-header h1 {
    margin: 0 0 10px;
    font-size: clamp(2rem, 7vw, 3.8rem);
    line-height: 1.05;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.site-subtitle {
    margin: 0;
    color: var(--muted);
    font-size: clamp(1rem, 3vw, 1.2rem);
    font-weight: 500;
    line-height: 1.5;
}

/* ---------- NAV ---------- */

.site-nav {
    background-color: rgba(255, 255, 255, 0.88);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 12px;
}

.nav-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nav-list li {
    margin: 0;
    padding: 0;
}

.nav-list a {
    display: block;
    padding: 12px 14px;
    border-radius: 999px;
    font-size: 0.98rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    color: var(--accent);
    background-color: transparent;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-list a:visited {
    color: var(--accent);
}

.nav-list a:hover {
    color: #ffffff;
    background-color: var(--accent-hover);
}

.nav-list a:active {
    color: #ffffff;
    background-color: #53231b;
}

.nav-list a:focus,
.nav-list a:focus-visible {
    outline: 3px solid #111111;
    outline-offset: 3px;
    background-color: var(--accent-soft);
}

.nav-list a[aria-current="page"] {
    background-color: var(--text);
    color: #ffffff;
}

/* ---------- MAIN GRID ---------- */

.about-main-content,
.about-article,
.about-sidebar {
    gap: 24px;
}

/* ---------- SHARED CARD STYLES ---------- */

.about-intro,
.timeline-section,
.context-section,
.context-list,
.about-image-card,
.gallery-section,
.site-footer {
    background-color: rgba(255, 255, 255, 0.9);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 20px;
}

.about-intro h2,
.timeline-section h2,
.context-section h2,
.context-list h2,
.about-image-card h2,
.gallery-section h2 {
    margin-top: 0;
    margin-bottom: 14px;
    font-size: 1.35rem;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.about-intro p,
.context-section p,
.context-list li,
.timeline-list p,
.gallery-item figcaption,
.about-figure figcaption,
.site-footer p {
    color: var(--text);
}

.timeline-list h3 {
    color: #5c2f26;
}

.about-intro p,
.context-section p {
    margin-top: 0;
    margin-bottom: 16px;
}

.about-intro p:last-child,
.context-section p:last-child {
    margin-bottom: 0;
}

/* ---------- TIMELINE ---------- */

.timeline-list {
    margin: 0;
    padding-left: 22px;
    display: grid;
    gap: 16px;
}

.timeline-list li {
    padding-left: 4px;
}

.timeline-list h3 {
    margin: 0 0 8px;
    font-size: 1.08rem;
    line-height: 1.25;
}

.timeline-list p {
    margin: 0;
    font-size: 1rem;
}

/* ---------- QUICK FACTS ---------- */

.context-list ul {
    margin: 0;
    padding-left: 20px;
}

.context-list li {
    margin-bottom: 10px;
}

.context-list li:last-child {
    margin-bottom: 0;
}

/* ---------- SIDEBAR IMAGE ---------- */

.about-figure {
    margin: 0;
    display: grid;
    gap: 10px;
}

.about-figure img {
    border-radius: 16px;
    object-fit: cover;
    min-height: 220px;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);
}

.about-figure figcaption {
    font-size: 0.92rem;
    line-height: 1.45;
    color: var(--muted);
    text-align: center;
}

/* ---------- GALLERY ---------- */

.gallery-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

.gallery-item {
    margin: 0;
    display: grid;
    gap: 8px;
}

.gallery-item a {
    display: block;
    overflow: hidden;
    border-radius: 16px;
    background-color: #d9dee3;
}

.gallery-item a:focus,
.gallery-item a:focus-visible {
    outline: 3px solid #111111;
    outline-offset: 4px;
}

.gallery-item img {
    height: 240px;
    object-fit: cover;
    transition: transform 0.22s ease, opacity 0.22s ease;
}

.gallery-item a:hover img {
    transform: scale(1.02);
    opacity: 1;
}

.gallery-item-featured img {
    min-height: 280px;
}

.gallery-item figcaption {
    font-size: 0.92rem;
    line-height: 1.45;
    color: var(--muted);
}

/* ---------- FOOTER ---------- */

.site-footer {
    text-align: center;
    background-color: var(--surface-strong);
}

.site-footer p {
    margin: 4px 0;
    font-size: 0.95rem;
    color: var(--muted);
}

/* ---------- TABLET ---------- */

@media (min-width: 700px) {
    .page-grid {
        padding: 20px;
        gap: 20px;
    }

    .site-header {
        padding: 32px 26px 24px;
    }

    .site-nav {
        border-radius: 999px;
        padding: 10px 16px;
    }

    .nav-list {
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: center;
        gap: 10px 14px;
    }

    .nav-list a {
        display: inline-block;
        width: auto;
        min-width: 0;
    }

    .about-intro,
    .timeline-section,
    .context-section,
    .context-list,
    .about-image-card,
    .gallery-section,
    .site-footer {
        padding: 24px;
    }

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

    .gallery-item-featured {
        grid-column: span 2;
    }

    .gallery-item-featured img {
        min-height: 340px;
    }
}

/* ---------- DESKTOP ---------- */

@media (min-width: 980px) {
    .page-grid {
        padding: 24px;
    }

    .about-main-content {
        grid-template-columns: minmax(0, 2.1fr) minmax(260px, 0.9fr);
        gap: 24px;
    }

    .about-article,
    .about-sidebar {
        gap: 24px;
    }

    .gallery-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 18px;
    }

    .gallery-item-featured {
        grid-column: span 1;
        grid-row: span 1;
    }

    .gallery-item img,
    .gallery-item-featured img {
        height: 240px;
        min-height: 0;
    }
}

a:focus,
a:focus-visible {
    outline: 3px solid #111111;
    outline-offset: 3px;
}