:root {
    --bg: #f4f2ee;
    --surface: rgba(255, 255, 255, 0.9);
    --surface-strong: #ffffff;
    --text: #13171f;
    --muted: #505867;
    --accent: #24415f;
    --accent-soft: #4e6c89;
    --line: rgba(19, 23, 31, 0.12);
    --danger: #b43f3f;
    --ok: #29603c;
    --radius-lg: 24px;
    --radius-md: 16px;
    --radius-sm: 10px;
    --shadow: 0 24px 60px rgba(20, 29, 43, 0.12);
    --container: 1160px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    color: var(--text);
    font-family: "IBM Plex Sans", "Segoe UI", sans-serif;
    background:
        radial-gradient(circle at 85% 0%, rgba(36, 65, 95, 0.15), transparent 28%),
        radial-gradient(circle at 0% 40%, rgba(111, 125, 146, 0.14), transparent 34%),
        linear-gradient(180deg, #ebe8e1 0%, #f5f3ef 36%, #efebe3 100%);
    min-height: 100vh;
    background-size: 100% 100%, 100% 100%, 100% 100%;
    animation: pageGlow 16s ease-in-out infinite;
}

@keyframes pageGlow {
    0% {
        background-position: 0% 0%, 100% 40%, 0% 0%;
    }
    50% {
        background-position: 6% 0%, 94% 44%, 0% 14%;
    }
    100% {
        background-position: 0% 0%, 100% 40%, 0% 0%;
    }
}

.page-bg {
    position: fixed;
    inset: 0;
    pointer-events: none;
    background-image: linear-gradient(rgba(20, 29, 43, 0.025) 1px, transparent 1px), linear-gradient(90deg, rgba(20, 29, 43, 0.025) 1px, transparent 1px);
    background-size: 26px 26px;
    mask-image: radial-gradient(circle at center, black 30%, transparent 95%);
    z-index: -1;
}

.shell {
    width: min(calc(100% - 40px), var(--container));
    margin: 0 auto;
}

.topbar {
    padding: 24px 0 18px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: var(--text);
}

.brand-mark {
    width: 44px;
    height: 44px;
    border-radius: 13px;
    display: grid;
    place-items: center;
    background: var(--accent);
    color: #ffffff;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.brand-text {
    font-size: 15px;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    font-weight: 600;
}

.nav {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 14px;
}

.nav a {
    text-decoration: none;
    color: var(--muted);
    font-size: 14px;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: color 0.2s ease;
}

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

.hero {
    padding: 42px clamp(20px, 4vw, 46px);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    background: linear-gradient(130deg, rgba(255, 255, 255, 0.9), rgba(243, 240, 234, 0.95));
    box-shadow: var(--shadow);
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 18px;
    align-items: center;
}

.hero-photo-wrap {
    justify-self: center;
    animation: floatPhoto 5s ease-in-out infinite;
    width: clamp(240px, 28vw, 360px);
    position: relative;
}

.hero-photo-wrap::after {
    content: "";
    position: absolute;
    inset: auto 8% -14px 8%;
    height: 18px;
    background: radial-gradient(circle, rgba(20, 29, 43, 0.25) 0%, rgba(20, 29, 43, 0) 70%);
    filter: blur(6px);
    z-index: -1;
}

.hero-photo {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: center top;
    border-radius: 18px;
    border: 1px solid var(--line);
    box-shadow: 0 18px 32px rgba(35, 50, 71, 0.16);
}

@keyframes floatPhoto {
    0% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
    100% { transform: translateY(0); }
}

.eyebrow {
    margin: 0;
    display: inline-block;
    padding: 8px 12px;
    border-radius: 999px;
    border: 1px solid var(--line);
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 12px;
    font-weight: 600;
}

h1,
h2,
h3,
p {
    margin: 0;
}

h1 {
    margin-top: 18px;
    max-width: 16ch;
    font-family: "Prata", "Times New Roman", serif;
    font-weight: 400;
    letter-spacing: 0.01em;
    line-height: 1.08;
    font-size: clamp(34px, 5vw, 66px);
}

.lead {
    margin-top: 20px;
    color: var(--muted);
    font-size: clamp(17px, 2vw, 20px);
    line-height: 1.6;
    max-width: 60ch;
}

.hero-actions {
    margin-top: 30px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.button {
    min-height: 50px;
    padding: 0 22px;
    border-radius: 999px;
    border: 1px solid transparent;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
}

.button:hover {
    transform: translateY(-1px);
}

.button-primary {
    background: var(--accent);
    color: #ffffff;
    box-shadow: 0 12px 22px rgba(36, 65, 95, 0.24);
}

.button-primary:hover {
    background: #1d3650;
}

.button-ghost {
    border-color: var(--line);
    color: var(--text);
    background: rgba(255, 255, 255, 0.7);
}

.section {
    margin-top: 28px;
    padding: 34px clamp(18px, 4vw, 36px);
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.section-head {
    display: grid;
    gap: 10px;
    margin-bottom: 20px;
}

.section-body {
    display: block;
}

.section.is-disabled {
    display: none;
}

.nav a.is-hidden {
    display: none;
}

.section-head h2 {
    font-family: "Prata", "Times New Roman", serif;
    font-size: clamp(30px, 4vw, 44px);
    letter-spacing: 0.02em;
    font-weight: 400;
}

.section-head p {
    color: var(--muted);
    line-height: 1.55;
}

.about-grid,
.priority-grid,
.reports-grid {
    display: grid;
    gap: 16px;
}

.about-grid,
.priority-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

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

.metrics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
    gap: 12px;
}

.metric-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface-strong);
    padding: 18px;
    display: grid;
    gap: 8px;
}

.metric-value {
    margin: 0;
    font-family: "Prata", "Times New Roman", serif;
    font-size: clamp(24px, 2.4vw, 38px);
    line-height: 1.12;
    color: #1f3f66;
    overflow-wrap: anywhere;
}

.metric-card h3 {
    font-size: 19px;
    margin: 0;
}

.metric-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.before-after {
    display: grid;
    gap: 10px;
}

.before-after-media {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid var(--line);
    background: #e7ebf1;
    min-height: 280px;
}

.before-after-media img {
    width: 100%;
    height: clamp(280px, 42vw, 520px);
    object-fit: cover;
    display: block;
}

.after-layer {
    position: absolute;
    inset: 0 auto 0 0;
    width: 50%;
    overflow: hidden;
    border-right: 2px solid rgba(255, 255, 255, 0.9);
}

.after-layer .after-image {
    width: clamp(520px, 100vw, 1200px);
    max-width: none;
}

.before-after-range {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: ew-resize;
}

.before-after-handle {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 36px;
    height: 36px;
    border-radius: 999px;
    border: 2px solid rgba(255, 255, 255, 0.96);
    background: rgba(36, 65, 95, 0.88);
    transform: translate(-50%, -50%);
    box-shadow: 0 6px 16px rgba(19, 23, 31, 0.32);
    pointer-events: none;
}

.before-after-handle::before,
.before-after-handle::after {
    content: "";
    position: absolute;
    top: 50%;
    width: 8px;
    height: 8px;
    border-top: 2px solid #ffffff;
    border-right: 2px solid #ffffff;
}

.before-after-handle::before {
    left: 9px;
    transform: translateY(-50%) rotate(-135deg);
}

.before-after-handle::after {
    right: 9px;
    transform: translateY(-50%) rotate(45deg);
}

.before-after-labels {
    display: flex;
    justify-content: space-between;
    color: var(--muted);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 12px;
    font-weight: 700;
}

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

.schedule-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: linear-gradient(180deg, #ffffff, #f7f4ef);
    padding: 16px;
    display: grid;
    gap: 8px;
}

.schedule-card time {
    color: #21466f;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-weight: 700;
}

.schedule-card h3 {
    margin: 0;
    font-size: 20px;
}

.schedule-card p {
    margin: 0;
    color: var(--muted);
    line-height: 1.5;
}

.schedule-link {
    justify-self: start;
    text-decoration: none;
    border-radius: 999px;
    padding: 8px 12px;
    color: #18426e;
    border: 1px solid rgba(24, 66, 110, 0.26);
    background: rgba(24, 66, 110, 0.07);
    font-weight: 600;
    font-size: 14px;
}

.schedule-link:hover {
    background: rgba(24, 66, 110, 0.14);
}

.post-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.post-filter {
    border: 1px solid rgba(26, 53, 84, 0.18);
    background: rgba(255, 255, 255, 0.75);
    color: #25486a;
    border-radius: 999px;
    padding: 7px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.post-filter:hover {
    transform: translateY(-1px);
    border-color: rgba(26, 53, 84, 0.35);
}

.post-filter.is-active {
    color: #ffffff;
    background: #234767;
    border-color: #234767;
}

.posts-stack {
    display: grid;
    gap: 16px;
}

.max-post {
    padding-top: 12px;
}

.max-post.is-hidden {
    display: none;
}

.post-head {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.post-source {
    margin: 0;
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--accent-soft);
}

.post-title {
    margin: 0 0 8px;
    font-family: "Prata", "Times New Roman", serif;
    font-weight: 400;
    font-size: clamp(25px, 3.5vw, 38px);
    line-height: 1.2;
}

.post-tags {
    margin-top: 8px;
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.post-tag {
    border-radius: 999px;
    border: 1px solid rgba(78, 108, 137, 0.25);
    color: #2c4b6a;
    font-size: 12px;
    padding: 4px 9px;
    background: rgba(78, 108, 137, 0.08);
}

.card,
.priority-item,
.report-card {
    border: 1px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--surface-strong);
}

.card {
    padding: 22px;
}

.card h3,
.priority-item h3,
.report-card h3 {
    margin-bottom: 10px;
    font-size: 21px;
    font-weight: 600;
}

.card p,
.priority-item p,
.report-card p {
    color: var(--muted);
    line-height: 1.6;
}

.priority-item {
    padding: 24px;
}

.priority-num {
    display: inline-flex;
    margin-bottom: 14px;
    color: var(--accent-soft);
    font-size: 14px;
    letter-spacing: 0.12em;
    font-weight: 600;
}

.report-card {
    padding: 22px;
}

.report-card time {
    display: inline-block;
    margin-bottom: 12px;
    color: var(--accent-soft);
    font-size: 13px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.flag-post {
    overflow: hidden;
    position: relative;
}

.flag-post::before {
    content: "";
    position: absolute;
    left: -20%;
    right: -20%;
    top: 0;
    height: 8px;
    background: linear-gradient(90deg, #ffffff 0 33.33%, #2552a1 33.33% 66.66%, #cc3030 66.66% 100%);
    transform: skewX(-18deg) translateX(0);
    animation: flagRibbon 7s ease-in-out infinite;
}

@keyframes flagRibbon {
    0% {
        transform: skewX(-18deg) translateX(-6%);
    }
    50% {
        transform: skewX(-18deg) translateX(6%);
    }
    100% {
        transform: skewX(-18deg) translateX(-6%);
    }
}

.post-card {
    margin-top: 4px;
    padding: 18px;
    border-radius: var(--radius-md);
    border: 1px solid var(--line);
    background: linear-gradient(180deg, #ffffff, #f9f6f0);
    display: grid;
    gap: 10px;
}

.post-card p {
    line-height: 1.7;
    color: #2e3541;
    font-size: 17px;
}

.post-label {
    justify-self: start;
    border-radius: 999px;
    padding: 6px 12px;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-size: 12px;
    font-weight: 700;
    color: #0b2f64;
    border: 1px solid rgba(37, 82, 161, 0.25);
    background: rgba(37, 82, 161, 0.08);
}

.post-gallery {
    margin-top: 10px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.post-gallery-item {
    min-height: 146px;
    border-radius: var(--radius-md);
    border: 1px dashed rgba(37, 82, 161, 0.35);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.8), rgba(235, 240, 251, 0.9)),
        repeating-linear-gradient(45deg, rgba(37, 82, 161, 0.05), rgba(37, 82, 161, 0.05) 10px, rgba(255, 255, 255, 0.35) 10px, rgba(255, 255, 255, 0.35) 20px);
    padding: 10px;
    display: grid;
    align-content: start;
    gap: 6px;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    overflow: hidden;
}

.post-gallery-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(27, 50, 92, 0.12);
}

.post-gallery-item h3 {
    margin: 0;
    font-size: 18px;
}

.post-gallery-item p {
    margin: 0;
    color: var(--muted);
}

.post-gallery-photo {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    object-position: center;
    border-radius: 10px;
    border: 1px solid rgba(37, 82, 161, 0.2);
    opacity: 0;
    transform: scale(1.02);
    transition: opacity 0.35s ease, transform 0.35s ease;
    pointer-events: none;
}

.post-gallery-item.is-ready .post-gallery-photo {
    opacity: 1;
    transform: scale(1);
    pointer-events: auto;
    cursor: zoom-in;
}

.post-gallery-placeholder {
    min-height: 110px;
    border-radius: 10px;
    border: 1px dashed rgba(37, 82, 161, 0.45);
    background: rgba(255, 255, 255, 0.7);
    display: grid;
    align-content: center;
    justify-items: center;
    gap: 6px;
    text-align: center;
    padding: 10px;
}

.post-gallery-placeholder h3 {
    font-size: 18px;
}

.post-gallery-placeholder p {
    font-size: 13px;
    line-height: 1.4;
}

.post-gallery-item.is-ready .post-gallery-placeholder {
    display: none;
}

.post-gallery-item figcaption {
    margin-top: 0;
    color: #3a4557;
    line-height: 1.35;
    font-size: 13px;
}

.post-gallery-item figcaption:empty {
    display: none;
}

body.lightbox-open {
    overflow: hidden;
}

.lightbox {
    position: fixed;
    inset: 0;
    z-index: 30;
    display: none;
}

.lightbox.is-open {
    display: block;
}

.lightbox-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(8, 14, 24, 0.82);
    backdrop-filter: blur(4px);
}

.lightbox-dialog {
    position: relative;
    width: min(calc(100% - 26px), 1120px);
    margin: min(5vh, 32px) auto;
    max-height: 90vh;
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(13, 21, 33, 0.9);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.45);
    padding: 14px 50px 12px;
    touch-action: pan-y;
}

.lightbox-figure {
    margin: 0;
}

.lightbox-image {
    width: 100%;
    max-height: 74vh;
    display: block;
    object-fit: contain;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.04);
}

.lightbox-caption {
    margin-top: 10px;
    color: rgba(240, 245, 255, 0.9);
    font-size: 15px;
    line-height: 1.5;
}

.lightbox-counter {
    margin: 8px 0 2px;
    text-align: center;
    color: rgba(220, 231, 250, 0.82);
    font-size: 13px;
    letter-spacing: 0.08em;
}

.lightbox-thumbs {
    margin-top: 8px;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 82px;
    gap: 8px;
    overflow-x: auto;
    padding: 2px 2px 6px;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.35) transparent;
}

.lightbox-thumbs::-webkit-scrollbar {
    height: 6px;
}

.lightbox-thumbs::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.35);
    border-radius: 999px;
}

.lightbox-thumb {
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 0;
    background: rgba(255, 255, 255, 0.06);
    cursor: pointer;
    overflow: hidden;
    opacity: 0.72;
    transform: scale(0.96);
    transition: opacity 0.2s ease, transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.lightbox-thumb:hover {
    opacity: 0.95;
    transform: scale(0.99);
}

.lightbox-thumb.is-active {
    opacity: 1;
    transform: scale(1);
    border-color: rgba(145, 193, 255, 0.95);
    box-shadow: 0 0 0 2px rgba(115, 176, 255, 0.25);
}

.lightbox-thumb img {
    width: 100%;
    height: 62px;
    display: block;
    object-fit: cover;
}

.lightbox-close,
.lightbox-nav {
    position: absolute;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.14);
    color: #ffffff;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.2s ease;
}

.lightbox-close:hover,
.lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.24);
    transform: translateY(-1px);
}

.lightbox-close {
    top: 10px;
    right: 10px;
    font-size: 28px;
    line-height: 1;
}

.lightbox-nav {
    top: 50%;
    transform: translateY(-50%);
    font-size: 30px;
    line-height: 1;
}

.lightbox-nav-prev {
    left: 8px;
}

.lightbox-nav-next {
    right: 8px;
}

.post-gallery-hint {
    margin-top: 8px;
    font-size: 13px;
    color: var(--muted);
}

.reception-grid {
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 16px;
}

.reception-note ul {
    margin: 0;
    padding-left: 18px;
    display: grid;
    gap: 8px;
    color: var(--muted);
}

.footer {
    margin-top: 22px;
    margin-bottom: 32px;
    padding: 24px clamp(18px, 4vw, 36px);
    border-radius: var(--radius-lg);
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.8);
    color: var(--muted);
    display: grid;
    gap: 6px;
}

[data-reveal] {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

[data-reveal].is-visible {
    opacity: 1;
    transform: translateY(0);
}

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

    [data-reveal] {
        opacity: 1;
        transform: none;
    }
}

@media (max-width: 1020px) {
    .about-grid,
    .priority-grid,
    .reports-grid {
        grid-template-columns: 1fr 1fr;
    }

    .metrics-grid,
    .schedule-grid {
        grid-template-columns: 1fr 1fr;
    }

    .post-gallery {
        grid-template-columns: 1fr 1fr;
    }

    .post-card {
        padding: 16px;
    }

    .reception-grid,
    .hero {
        grid-template-columns: 1fr;
    }

    .hero-photo-wrap {
        justify-self: flex-start;
    }
}

@media (max-width: 700px) {
    .topbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .nav {
        justify-content: flex-start;
    }

    .about-grid,
    .priority-grid,
    .reports-grid,
    .metrics-grid,
    .schedule-grid,
    .post-gallery {
        grid-template-columns: 1fr;
    }

    .post-gallery {
        gap: 8px;
    }

    .post-gallery-item {
        padding: 8px;
    }

    .hero {
        padding: 34px 18px;
    }

    .section {
        padding: 26px 16px;
    }

    .lightbox-dialog {
        padding: 12px 10px 12px;
        width: calc(100% - 14px);
    }

    .lightbox-image {
        max-height: 80vh;
    }

    .lightbox-nav {
        width: 36px;
        height: 36px;
    }

    .lightbox-nav-prev {
        left: 6px;
    }

    .lightbox-nav-next {
        right: 6px;
    }

    .lightbox-thumbs {
        grid-auto-columns: 68px;
        gap: 6px;
    }

    .lightbox-thumb img {
        height: 52px;
    }
}
