:root {
    --bg: #ffffff;
    --line: #e7e2d8;
    --text: #181511;
    --muted: #6f6658;
    --accent: #a87e3f;
    --font-sans: "Poppins", "Segoe UI", sans-serif;
    --font-display: "Poppins", "Segoe UI", sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    width: 100%;
    height: 100%;
    scroll-behavior: smooth;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    overflow: hidden;
}

h1,
h2,
h3,
.section-kicker,
.hero-nav,
.hero-tagline,
.service-number {
    font-family: var(--font-display);
}

a {
    color: inherit;
    text-decoration: none;
}

button {
    font: inherit;
}

.snap-wrapper {
    height: 100vh;
    overflow-y: auto;
    scroll-snap-type: y mandatory;
}

.page {
    min-height: 100vh;
    height: 100vh;
    width: 100%;
    padding: clamp(1.25rem, 3vw, 3rem);
    scroll-snap-align: start;
    scroll-snap-stop: always;
    position: relative;
    display: flex;
    flex-direction: column;
}

.section-head {
    display: grid;
    gap: 0.7rem;
    margin-bottom: clamp(1.5rem, 3vw, 2.5rem);
}

.section-kicker {
    font-size: 0.75rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--muted);
}

.section-head h2 {
    font-size: clamp(1.6rem, 3.2vw, 2.8rem);
    font-weight: 500;
    line-height: 1.1;
} 

.page-home {
    justify-content: center;
    align-items: center;
    background: #ffffff;
    overflow: hidden;
}

.hero-bg,
.hero-overlay {
    position: absolute;
    inset: 0;
}

.hero-bg {
    z-index: 1;
}

.hero-slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.06);
    transition: opacity 1.2s ease, transform 8s linear;
}

.hero-slide.active {
    opacity: 1;
    transform: scale(1);
}

.hero-overlay {
    z-index: 2;
    background:
    linear-gradient(160deg, rgba(255, 255, 255, 0.52) 0%, rgba(255, 255, 255, 0.4) 45%, rgba(255, 255, 255, 0.48) 100%),
    radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.2), transparent 56%);
}

.lang-switcher {
    position: absolute;
    top: clamp(1rem, 2vw, 2rem);
    right: clamp(1rem, 2.2vw, 2.4rem);
    z-index: 4;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    color: #6b6358;
    font-size: 0.82rem;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.lang-btn {
    border: 0;
    background: transparent;
    color: #8b8071;
    cursor: pointer;
    letter-spacing: inherit;
}

.lang-btn.active {
    color: #26211b;
}

.hero-center {
    position: relative;
    z-index: 3;
    width: min(1180px, 94vw);
    display: grid;
    gap: clamp(1.6rem, 3vw, 3rem);
}

.hero-nav-row {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: clamp(0.8rem, 2vw, 2.8rem);
}

.hero-nav {
    display: flex;
    gap: clamp(0.8rem, 2vw, 2rem);
    font-size: clamp(0.78rem, 1vw, 0.95rem);
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.hero-nav-left {
    justify-content: flex-end;
}

.hero-nav-right {
    justify-content: flex-start;
}

.hero-nav a {
    padding-bottom: 0.35rem;
    border-bottom: 1px solid transparent;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.hero-nav a:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.hero-logo {
    height: clamp(68px, 10vw, 132px);
    width: auto;
    display: block;
}

.hero-tagline {
    text-align: center;
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: #3d362c;
    font-size: clamp(0.72rem, 1vw, 0.9rem);
}

.scroll-hint {
    position: absolute;
    z-index: 3;
    bottom: clamp(1.2rem, 3vw, 2.6rem);
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.72rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: #3d362c;
    opacity: 0.88;
}

.scroll-hint span {
    border-bottom: 1px solid #3d362c;
    padding-bottom: 0.35rem;
}

.page-about,
.page-services,
.page-portfolio,
.page-contacts {
    background: #ffffff;
}

.team-grid,
.services-list {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: clamp(1rem, 2vw, 1.5rem);
}

.about-story-wrap {
    flex: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
    gap: clamp(1.6rem, 4vw, 3.6rem);
    align-items: center;
}

.about-story-text h3 {
    font-size: clamp(1.1rem, 2vw, 1.7rem);
    margin-bottom: 0.85rem;
    letter-spacing: 0.02em;
}

.about-story-text p {
    max-width: 70ch;
    line-height: 1.85;
    font-size: clamp(0.95rem, 1.05vw, 1.06rem);
    color: #3b352c;
}

.about-portraits {
    height: min(66vh, 580px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1rem, 2.5vw, 2.5rem);
    flex-wrap: nowrap;
}

.portrait {
    margin: 0;
    width: clamp(200px, 28vw, 340px);
    flex: 1 1 0;
    min-width: 0;
}

.portrait:focus {
    outline: none;
}

.portrait img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 50%;
    filter: grayscale(1) contrast(1.04);
    display: block;
}

.portrait figcaption {
    margin-top: 0.45rem;
    text-align: center;
    font-size: 0.82rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #595046;
}

.portrait-back,
.portrait-front {
    transform: none;
}

.team-card,
.service-item {
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.72);
}

.team-card {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.team-card img {
    width: 100%;
    height: clamp(180px, 33vh, 360px);
    object-fit: cover;
    border-bottom: 1px solid var(--line);
}

.team-card-info {
    padding: clamp(0.9rem, 1.5vw, 1.2rem);
    display: grid;
    gap: 0.7rem;
}

.team-card-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 0.8rem;
}

.team-card h3,
.service-item h3 {
    font-size: clamp(0.9rem, 1.35vw, 1.2rem);
    font-weight: 500;
}

.team-card p,
.service-item p {
    color: var(--muted);
    font-size: clamp(0.82rem, 1vw, 0.95rem);
    line-height: 1.5;
}

.team-card a {
    width: 26px;
    height: 26px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #4f473d;
}

.team-card a:hover {
    color: var(--accent);
}

.team-card svg {
    width: 100%;
    height: 100%;
}

.service-item {
    position: relative;
    padding: clamp(1.1rem, 2vw, 1.8rem) clamp(0.2rem, 1.1vw, 0.7rem) clamp(1.15rem, 2vw, 1.8rem) clamp(1rem, 1.8vw, 1.5rem);
    display: grid;
    align-content: start;
    gap: 0.9rem;
    border: 0;
    background: transparent;
}

.services-list {
    gap: clamp(1.2rem, 2.2vw, 2.1rem);
}

.service-item::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0.15rem;
    bottom: 0.15rem;
    width: 1px;
    background: linear-gradient(180deg, rgba(120, 120, 120, 0.45) 0%, rgba(120, 120, 120, 0.12) 72%, rgba(120, 120, 120, 0) 100%);
}
 

.page-services {
    justify-content: flex-start;
}

.service-number {
    font-size: 0.82rem;
    letter-spacing: 0.22em;
    color: #6b6358;
    text-transform: uppercase;
}

.service-item h3 {
    font-size: clamp(1rem, 1.45vw, 1.32rem);
}

.service-target {
    color: #3f392f;
    max-width: 30ch;
}

.service-subtitle {
    font-size: 0.74rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: #5f574a;
}

.service-bullets,
.service-steps {
    margin-left: 1.05rem;
    display: grid;
    gap: 0.35rem;
}

.service-bullets li,
.service-steps li {
    color: #464036;
    font-size: 0.86rem;
    line-height: 1.45;
}

.service-subline {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    font-size: 0.86rem;
    color: #4a443a;
}

.service-subline span:first-child {
    color: #28231d;
}

.service-extra {
    margin-top: 0.8rem;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem;
}

.service-extra-item {
    border: 1px solid #111111;
    padding: 0.95rem;
    background: #ffffff;
    display: grid;
    gap: 0.45rem;
}

.service-extra-item h3 {
    font-size: 0.92rem;
    font-weight: 600;
    color: #1f1b15;
}

.service-extra-item p {
    color: #4a443a;
    font-size: 0.82rem;
    line-height: 1.45;
}

.page-portfolio {
    justify-content: flex-start;
}

.portfolio-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(1rem, 1.8vw, 1.6rem);
    align-content: start;
    overflow-y: auto;
    padding-right: 0.2rem;
}

.portfolio-card {
    position: relative;
    overflow: visible;
}

.zoom-image {
    border: 0;
    background: transparent;
    width: 100%;
    display: block;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}

.zoom-image img {
    width: 100%;
    aspect-ratio: 1 / 1;
    height: auto;
    object-fit: cover;
    display: block;
    transform: scale(1.001);
    transition: transform 0.45s ease;
}

.portfolio-hover {
    position: static;
    margin-top: 1.1rem;
    padding: 0.1rem 0.1rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: transparent;
    opacity: 1;
    pointer-events: auto;
}

.portfolio-hover p {
    color: #2f2a22;
    font-size: 1rem;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 0.6rem;
}

.zoom-image::after {
    content: "\f16d";
    font-family: "Font Awesome 6 Brands";
    font-weight: 400;
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -42%);
    color: #ffffff;
    font-size: 2rem;
    opacity: 0;
    transition: opacity 0.22s ease, transform 0.22s ease;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.45);
    pointer-events: none;
    z-index: 3;
}

.zoom-image::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.38);
    opacity: 0;
    transition: opacity 0.22s ease;
    z-index: 2;
    pointer-events: none;
}

.portfolio-card:hover .zoom-image::after {
    opacity: 1;
    transform: translate(-50%, -50%);
}

.portfolio-card:hover .zoom-image::before {
    opacity: 1;
}

.portfolio-card:hover .zoom-image img {
    transform: scale(1.04);
}

.page-contacts {
    justify-content: center;
    gap: 2rem;
}

.contact-main {
    display: grid;
    gap: 0.8rem;
}

.contact-primary {
    font-size: clamp(1.1rem, 2vw, 2rem);
    font-weight: 500;
    letter-spacing: 0.03em;
    width: fit-content;
    border-bottom: 1px solid transparent;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.contact-primary:hover {
    color: var(--accent);
    border-color: var(--accent);
}

.contact-socials {
    display: flex;
    gap: 1.1rem;
    flex-wrap: wrap;
}

.contact-socials a {
    border: 1px solid #111111;
    padding: 0.7rem 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    color: #111111;
    background: #ffffff;
    transition: color 0.25s ease, border-color 0.25s ease;
}

.contact-socials a:hover {
    color: var(--accent);
    border-color: #111111;
}

.contact-socials svg {
    width: 18px;
    height: 18px;
}

@media (max-width: 1400px) and (min-width: 1025px) {
    .about-story-wrap {
        grid-template-columns: minmax(0, 1.1fr) minmax(280px, 0.9fr);
        gap: clamp(1rem, 2vw, 2rem);
    }

    .about-story-text p {
        max-width: 58ch;
        font-size: clamp(0.84rem, 0.78vw, 0.98rem);
        line-height: 1.68;
    }

    .about-portraits {
        height: min(58vh, 500px);
    }

    .portrait {
        width: clamp(220px, 22vw, 300px);
    }

    .portrait-back,
    .portrait-front {
        transform: none;
    }
}

@media (max-height: 820px) and (min-width: 1025px) {
    .about-story-text p {
        font-size: 0.86rem;
        line-height: 1.58;
    }

    .about-portraits {
        height: min(54vh, 440px);
    }

    .portrait {
        width: clamp(200px, 20vw, 270px);
    }
}

@media (max-width: 1024px) {
    body {
        overflow: auto;
    }

    .snap-wrapper {
        scroll-snap-type: none;
        height: auto;
    }

    .page {
        height: auto;
        min-height: 100vh;
        padding: 1.2rem;
    }

    .hero-nav-row {
        grid-template-columns: 1fr;
        justify-items: center;
    }

    .hero-nav {
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero-nav-left,
    .hero-nav-right {
        justify-content: center;
    }

    .about-story-wrap,
    .team-grid,
    .services-list,
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .about-portraits {
        height: auto;
        margin-top: 0.8rem;
        display: flex;
        justify-content: center;
        align-items: flex-start;
        flex-wrap: nowrap;
        gap: 0.7rem;
    }

    .portrait {
        position: static;
        width: clamp(120px, 42vw, 240px);
        left: auto;
        transform: none;
        flex: 1 1 0;
        min-width: 0;
    }

    .portrait-back {
        transform: none;
    }

    .portrait-front {
        transform: none;
    }

    .service-extra {
        grid-template-columns: 1fr;
        gap: 0.7rem;
    }

    .portfolio-grid {
        gap: 1.2rem;
        overflow-y: visible;
    }

    .service-item {
        gap: 0.8rem;
        padding: 1rem 0.1rem 1.1rem 0.95rem;
    }

    .service-item::after {
        width: 74px;
        height: 74px;
    }

    .team-card img,
    .zoom-image img {
        height: 240px;
    }

    .page-contacts {
        justify-content: flex-start;
    }

}