/* About page */

.header__nav a.is-active {
    color: var(--text-main);
}

.about-page {
    background: var(--bg-dark);
    padding: 150px 0 105px;
}

.about-page__container {
    width: min(100% - 40px, 760px);
}

.about-page__head {
    margin-bottom: 66px;
}

.about-page__head h1 {
    color: var(--text-main);
    font-size: var(--title-size);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.03em;
}

.about-hero-photo {
    overflow: hidden;
    width: 100%;
    margin-bottom: 72px;
    border-radius: 8px;
}

.about-hero-photo img {
    width: 100%;
    aspect-ratio: 2.35 / 1;
    object-fit: cover;
    object-position: center;
    border-radius: 8px;
    transition: transform 0.4s ease, filter 0.4s ease;
}

.about-hero-photo:hover img {
    transform: scale(1.025);
    filter: brightness(1.05);
}

.about-text-block {
    margin-bottom: 66px;
}

.about-text-block h2,
.about-gallery-section h2 {
    margin-bottom: 28px;
    color: var(--text-main);
    font-size: 32px;
    font-weight: 700;
    line-height: 1.15;
    letter-spacing: -0.03em;
}

.about-text-block p {
    max-width: 760px;
    margin-bottom: 22px;
    color: var(--text-muted);
    font-size: 16px;
    font-weight: 400;
    line-height: 1.45;
}

.about-gallery-section {
    margin-top: 76px;
}

/* Фотоальбом — сетка как визуальный дневник на главной */

.about-gallery {
    display: grid;
    grid-template-columns: repeat(12, 1fr);
    gap: 20px;
    width: 100%;
    margin: 0 auto;
}

.about-gallery__item {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    background: var(--bg-main);
    transition: transform 0.55s ease;
}

.about-gallery__item::after {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    background-image:
        radial-gradient(circle at 20% 30%, rgba(255, 255, 255, 0.18) 0 1px, transparent 1px),
        radial-gradient(circle at 80% 70%, rgba(0, 0, 0, 0.22) 0 1px, transparent 1px),
        repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.04) 0 1px, transparent 1px 3px);
    background-size: 9px 9px, 7px 7px, 100% 4px;
    mix-blend-mode: overlay;
    transition: opacity 0.55s ease;
}

.about-gallery__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 8px;
    transition:
        transform 0.65s ease,
        filter 0.65s ease;
}

.about-gallery__item:hover {
    transform: translateY(-2px);
}

.about-gallery__item:hover img {
    transform: scale(1.025);
    filter: grayscale(0.72) contrast(1.08) brightness(0.82);
}

.about-gallery__item:hover::after {
    opacity: 0.75;
}

.about-gallery__item--top-left {
    grid-column: 1 / 8;
    aspect-ratio: 1.45 / 1;
}

.about-gallery__item--top-right {
    grid-column: 8 / 13;
    aspect-ratio: 1.02 / 1;
}

.about-gallery__item--small-1 {
    grid-column: 1 / 5;
    aspect-ratio: 1 / 1;
}

.about-gallery__item--small-2 {
    grid-column: 5 / 9;
    aspect-ratio: 1 / 1;
}

.about-gallery__item--small-3 {
    grid-column: 9 / 13;
    aspect-ratio: 1 / 1;
}

/* Adaptive */

@media (max-width: 820px) {
    .about-page {
        padding: 130px 0 76px;
    }

    .about-page__container {
        width: min(100% - 28px, 760px);
    }

    .about-page__head {
        margin-bottom: 48px;
    }

    .about-page__head h1 {
        font-size: 38px;
    }

    .about-hero-photo {
        margin-bottom: 56px;
    }

    .about-hero-photo img {
        aspect-ratio: 1.8 / 1;
    }

    .about-text-block {
        margin-bottom: 54px;
    }

    .about-text-block h2,
    .about-gallery-section h2 {
        font-size: 28px;
    }

    .about-text-block p {
        font-size: 16px;
    }

    .about-gallery {
        grid-template-columns: repeat(2, 1fr);
        gap: 14px;
    }

    .about-gallery__item--top-left,
    .about-gallery__item--top-right,
    .about-gallery__item--small-1,
    .about-gallery__item--small-2,
    .about-gallery__item--small-3 {
        grid-column: auto;
        aspect-ratio: 1.25 / 1;
    }
}

@media (max-width: 520px) {
    .about-page {
        padding: 110px 0 64px;
    }

    .about-page__head h1 {
        font-size: 34px;
    }

    .about-hero-photo img {
        aspect-ratio: 1.35 / 1;
    }

    .about-text-block h2,
    .about-gallery-section h2 {
        font-size: 24px;
    }

    .about-text-block p {
        font-size: 15px;
    }

    .about-gallery {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .about-gallery__item--top-left,
    .about-gallery__item--top-right,
    .about-gallery__item--small-1,
    .about-gallery__item--small-2,
    .about-gallery__item--small-3 {
        grid-column: auto;
        aspect-ratio: 1.35 / 1;
    }
}
