.dark-section {
    background: #17191b;
    color: var(--cream);
}

.portfolio.dark-section,
.footer.dark-section {
    background: var(--cream);
    color: var(--ink);
}

.light-section {
    background: var(--cream);
    color: var(--ink);
}

.hero {
    position: relative;
    isolation: isolate;
    display: flex;
    align-items: center;
    min-height: max(820px, 70.654vw);
    padding: 190px 7% 110px;
    overflow: hidden;
    background-color: #09275f;
    background-image: linear-gradient(rgba(7, 10, 25, 0.34), rgba(7, 10, 25, 0.34)),url("../images/hero-image.webp");
    background-size: 100% auto;
    background-position: center top;
    background-repeat: no-repeat;
    color: #ffffff;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 850px;
    transform: translateY(-80px);
}

.eyebrow {
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
}

.hero h1,
.portfolio-heading h2,
.about-copy h2,
.contact-copy h2 {
    margin: 24px 0;
    font-family: "Space Grotesk", sans-serif;
    font-size: clamp(3.5rem, 8vw, 7.4rem);
    font-weight: 500;
    letter-spacing: -0.08em;
    line-height: 0.98;
}

.hero h1 em,
.portfolio-heading h2 em,
.about-copy h2 em,
.contact-copy h2 em {
    color: var(--blue);
    font-style: normal;
}

.hero-copy {
    max-width: 550px;
    color: #5d6065;
    font-size: 1.1rem;
    line-height: 1.7;
}

.text-link {
    display: inline-block;
    margin-top: 28px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--blue);
    font-weight: 600;
}

.text-link span {
    margin-left: 12px;
    color: var(--blue);
}

.hero-index,
.hero-note {
    position: absolute;
    bottom: 45px;
    color: #777a79;
    font-size: 0.72rem;
    letter-spacing: 0.12em;
}

.hero-index {
    left: 7%;
}

.hero-index span {
    color: var(--blue);
}

.hero-note {
    right: 7%;
}

.section-pad {
    padding: 110px 7%;
}

.section-kicker {
    margin-bottom: 55px;
    color: var(--muted);
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.14em;
}

.section-kicker span {
    color: var(--blue);
}

.about-grid,
.contact-grid {
    display: grid;
    grid-template-columns: minmax(250px, 0.8fr) minmax(0, 1.2fr);
    gap: 9%;
    align-items: center;
}

.about-photo {
    position: relative;
}

.about-photo img {
    display: block;
    width: 100%;
    max-height: 560px;
    object-fit: cover;
}

.photo-caption {
    display: block;
    margin-top: 12px;
    color: var(--muted);
    font-size: 0.65rem;
    letter-spacing: 0.13em;
}

.about-copy h2,
.contact-copy h2 {
    font-size: clamp(3rem, 5vw, 4.75rem);
}

.eyebrow.blue {
    color: var(--blue);
}

.about-copy p,
.contact-copy p {
    max-width: 650px;
    color: #5d6065;
    line-height: 1.8;
}

.about-copy .lead,
.contact-copy .lead {
    color: var(--ink);
    font-size: 1.15rem;
}

.skills {
    display: flex;
    flex-wrap: wrap;
    gap: 9px;
    margin-top: 30px;
}

.skills span {
    padding: 9px 13px;
    border: 1px solid rgba(23, 25, 27, 0.17);
    border-radius: 30px;
    color: #55595f;
    font-size: 0.78rem;
}

.portfolio-heading {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 40px;
    margin-bottom: 55px;
}

.portfolio-heading h2 {
    margin-bottom: 0;
    font-size: clamp(3rem, 6vw, 4.75rem);
}

.portfolio-intro {
    max-width: 330px;
    color: #5d6065;
    line-height: 1.7;
}

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

.work-card {
    position: relative;
    min-height: 320px;
    overflow: hidden;
    background: #292c30;
}

.work-card img,
.work-shade {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.work-card img {
    object-fit: cover;
    transition: transform 0.5s ease;
}

.work-card:hover img {
    transform: scale(1.04);
}

.work-shade {
    background: linear-gradient(0deg, rgba(10, 12, 14, 0.85), rgba(10, 12, 14, 0.08));
}

.work-number,
.work-label,
.work-arrow {
    position: absolute;
    z-index: 1;
    color: white;
}

.work-number {
    top: 22px;
    left: 24px;
    font-size: 0.72rem;
}

.work-label {
    bottom: 24px;
    left: 24px;
    display: flex;
    flex-direction: column;
    gap: 7px;
}

.work-label small {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.65rem;
    letter-spacing: 0.12em;
}

.work-label strong {
    font-family: "Space Grotesk", sans-serif;
    font-size: 2rem;
    font-weight: 500;
}

.work-arrow {
    right: 24px;
    bottom: 27px;
    font-size: 1.4rem;
}

.portfolio-footnote {
    margin-top: 24px;
    color: #777a79;
    font-size: 0.8rem;
}

.contact-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin-top: 35px;
}

.contact-details div {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.contact-details small {
    color: var(--muted);
    font-size: 0.65rem;
    letter-spacing: 0.12em;
}

.contact-details strong,
.contact-details a,
.contact-details span {
    font-size: 0.88rem;
}

.contact-details span {
    color: var(--muted);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.contact-form label {
    margin-top: 8px;
    font-size: 0.8rem;
    font-weight: 600;
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 15px;
    border: 1px solid rgba(23, 25, 27, 0.2);
    border-radius: 0;
    background: transparent;
    color: var(--ink);
    font: inherit;
}

.contact-form textarea {
    resize: vertical;
}

.submit-button {
    align-self: flex-start;
    margin-top: 10px;
    padding: 14px 20px;
    border: 0;
    background: var(--ink);
    color: white;
    font: inherit;
    cursor: pointer;
}

.submit-button span {
    margin-left: 15px;
    color: var(--blue);
}

.form-note {
    color: var(--muted);
    font-size: 0.75rem;
}

.footer {
    min-height: 100px;
    padding: 25px 7%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.footer p,
.footer .back-top {
    color: #777a79;
    font-size: 0.75rem;
}

.back-top {
    font-weight: 700;
    letter-spacing: 0.08em;
}

@media (max-width: 800px) {
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .portfolio-heading {
        display: block;
    }

    .portfolio-intro {
        margin-top: 25px;
    }

}

@media (max-width: 600px) {
    .site-header {
        min-height: 70px;
        padding: 0 6%;
    }

    .navigation {
        gap: 13px;
    }

    .navigation a {
        font-size: 0.72rem;
    }

    .hero,
    .section-pad {
        padding-left: 6%;
        padding-right: 6%;
    }

    .hero {
        padding-top: 160px;
    }

    .work-grid,
    .contact-details {
        grid-template-columns: 1fr;
    }

    .work-card {
        min-height: 260px;
    }

    .footer {
        padding: 25px 6%;
        flex-wrap: wrap;
    }

    .hero-content {
        transform: translateY(-25px);
    }

}

/* Hero typography and contrast */
.hero h1 {
    color: #ffffff;
}

.hero h1 em {
    color: var(--blue);
}

.hero .eyebrow,
.hero .hero-copy,
.hero .text-link,
.hero .hero-index,
.hero .hero-note {
    color: #ffffff;
}

.hero .eyebrow-line {
    background: var(--blue);
}

.hero .hero-index span,
.hero .text-link span {
    color: var(--blue);
}

.hero .text-link {
    border-color: var(--blue);
}

/* Homepage section backgrounds */
.about.light-section,
.contact.light-section {
    background: var(--paper-deep);
    color: var(--ink);
}

/* Responsive hero background */
@media (max-width: 1159px) {
    .hero {
        min-height: 820px;
        background-image: linear-gradient(rgba(7, 10, 25, 0.30), rgba(7, 10, 25, 0.38)),
            url("../images/category-blue-bg.webp");
        background-size: cover;
        background-position: center;
    }

    .hero-content {
        transform: translateY(-55px);
    }
}
