body.modal-open {
    overflow: hidden;
}

.contact-actions {
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
    margin-top: 14px;
}

.contact-modal {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: grid;
    place-items: center;
    padding: 24px;
}

.contact-modal[hidden] {
    display: none;
}

.contact-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 25, 33, 0.42);
    backdrop-filter: blur(12px);
}

.contact-modal__panel {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(280px, 0.9fr) minmax(0, 1.1fr);
    width: min(1040px, 100%);
    max-height: min(88vh, 920px);
    overflow: auto;
    border: 1px solid rgba(22, 33, 44, 0.12);
    border-radius: 32px;
    background:
        radial-gradient(circle at 15% 10%, rgba(184, 100, 43, 0.12), transparent 26%),
        linear-gradient(180deg, rgba(255, 251, 246, 0.98), rgba(244, 236, 226, 0.96));
    box-shadow: 0 36px 80px rgba(28, 24, 19, 0.24);
}

.contact-modal__intro,
.contact-modal__content {
    padding: 32px;
}

.contact-modal__intro {
    display: grid;
    align-content: start;
    gap: 18px;
    color: var(--ink);
    background:
        linear-gradient(180deg, rgba(24, 76, 86, 0.08), transparent 34%),
        linear-gradient(180deg, rgba(255, 255, 255, 0.62), rgba(247, 239, 229, 0.78));
    border-right: 1px solid rgba(22, 33, 44, 0.1);
}

.contact-modal__intro h2 {
    margin: 0;
    font-family: "Newsreader", Georgia, serif;
    font-size: clamp(2.2rem, 5vw, 3.5rem);
    line-height: 0.96;
}

.contact-modal__intro p,
.contact-modal__highlights,
.contact-modal__details a {
    color: var(--ink-soft);
}

.contact-modal__highlights {
    display: grid;
    gap: 12px;
    padding: 0;
    margin: 2px 0 0;
    list-style: none;
}

.contact-modal__highlights li {
    position: relative;
    padding-left: 18px;
    line-height: 1.7;
}

.contact-modal__highlights li::before {
    content: "";
    position: absolute;
    top: 0.72rem;
    left: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: linear-gradient(145deg, var(--accent), var(--teal));
}

.contact-modal__details {
    display: grid;
    gap: 14px;
    margin-top: 6px;
    padding-top: 18px;
    border-top: 1px solid rgba(22, 33, 44, 0.1);
}

.contact-modal__details div {
    display: grid;
    gap: 6px;
}

.contact-modal__details span,
.contact-modal__kicker {
    color: var(--teal);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.contact-modal__content {
    display: grid;
    gap: 24px;
}

.contact-modal__content-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.contact-modal__close {
    min-height: 42px;
}

.contact-form {
    display: grid;
    gap: 18px;
}

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

.contact-form__field {
    display: grid;
    gap: 8px;
}

.contact-form__field-full {
    grid-column: 1 / -1;
}

.contact-form__field span {
    color: var(--ink);
    font-size: 0.92rem;
    font-weight: 600;
}

.contact-form__field input,
.contact-form__field textarea {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid rgba(22, 33, 44, 0.12);
    border-radius: 18px;
    color: var(--ink);
    background: rgba(255, 255, 255, 0.78);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.46);
    transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.contact-form__field textarea {
    min-height: 180px;
    resize: vertical;
}

.contact-form__field input:focus,
.contact-form__field textarea:focus {
    outline: none;
    border-color: rgba(184, 100, 43, 0.56);
    box-shadow: 0 0 0 4px rgba(184, 100, 43, 0.14);
}

.contact-form__honeypot {
    position: absolute;
    left: -9999px;
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.contact-form__status {
    margin: 0;
    padding: 14px 16px;
    border-radius: 18px;
    line-height: 1.6;
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(22, 33, 44, 0.08);
}

.contact-form__status[data-state="ready"] {
    color: var(--teal);
}

.contact-form__status[data-state="working"] {
    color: var(--ink);
}

.contact-form__status[data-state="success"] {
    color: #17583f;
    background: rgba(226, 246, 236, 0.92);
    border-color: rgba(23, 88, 63, 0.18);
}

.contact-form__status[data-state="error"] {
    color: #8a2f26;
    background: rgba(255, 235, 232, 0.92);
    border-color: rgba(138, 47, 38, 0.18);
}

.contact-form__footer {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
    flex-wrap: wrap;
}

.contact-form__security {
    display: grid;
    gap: 10px;
}

.contact-form__security p {
    margin: 0;
    color: var(--ink-soft);
    line-height: 1.6;
}

.contact-form__turnstile {
    min-height: 66px;
}

.contact-form__submit {
    min-width: 180px;
}

@media (max-width: 900px) {
    .contact-modal {
        padding: 16px;
    }

    .contact-modal__panel {
        grid-template-columns: 1fr;
        max-height: 92vh;
    }

    .contact-modal__intro {
        border-right: 0;
        border-bottom: 1px solid rgba(22, 33, 44, 0.1);
    }
}

@media (max-width: 640px) {
    .contact-actions,
    .contact-form__grid,
    .contact-form__footer {
        grid-template-columns: 1fr;
    }

    .contact-actions,
    .contact-form__footer {
        display: grid;
    }

    .contact-modal__intro,
    .contact-modal__content {
        padding: 22px;
    }

    .contact-modal__content-head {
        align-items: start;
        flex-direction: column;
    }

    .contact-modal__close,
    .contact-form__submit {
        width: 100%;
    }
}
