/* =========================================================
   TufKo contact pages
   ========================================================= */

.contact-hero {
    background:
        radial-gradient(circle at 82% 40%,
            rgb(255 255 255 / 6%),
            transparent 30%),
        linear-gradient(135deg,
            var(--tufko-black),
            var(--tufko-grey-900) 68%,
            var(--tufko-steel-dark));
    color: var(--tufko-white);
}

.contact-hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(240px, 0.65fr);
    align-items: center;
    gap: clamp(3rem, 8vw, 7rem);
    min-height: 480px;
    padding-block: clamp(4.5rem, 9vw, 7rem);
}

.contact-hero__content {
    max-width: 820px;
}

.contact-hero h1 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(3rem, 6.5vw, 5.3rem);
    font-weight: 700;
    letter-spacing: -0.025em;
    line-height: 0.98;
}

.contact-hero__summary {
    max-width: 680px;
    margin: 1.75rem 0 0;
    color: var(--tufko-steel-light);
    font-size: clamp(1rem, 1.8vw, 1.2rem);
}

.contact-hero__mark {
    display: flex;
    justify-content: center;
}

.contact-hero__mark img {
    width: min(100%, 280px);
    height: auto;
    filter: drop-shadow(0 1.5rem 2.5rem rgb(0 0 0 / 40%));
}

/* Form page */

.contact-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.7fr);
    align-items: start;
    gap: clamp(3rem, 8vw, 7rem);
}

.contact-form-panel {
    max-width: 820px;
}

.contact-form-panel h2,
.contact-sidebar h2,
.contact-success h1 {
    margin: 0;
    font-family: var(--font-heading);
    font-size: clamp(2.1rem, 4.5vw, 3.5rem);
    line-height: 1.06;
}

.contact-form-introduction {
    max-width: 65ch;
    color: var(--tufko-grey-700);
    font-size: 1.05rem;
}

.contact-form {
    margin-top: 2.5rem;
}

.form-errors {
    margin-bottom: 2rem;
    padding: 1.25rem;
    background: #fff4ef;
    border: 1px solid var(--tufko-orange);
}

.form-errors h2 {
    margin: 0 0 0.5rem;
    font-size: 1.3rem;
}

.form-errors p {
    margin: 0;
}

.form-section {
    margin: 0 0 2.5rem;
    padding: 0;
    border: 0;
}

.form-section legend {
    width: 100%;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--tufko-grey-300);
    color: var(--tufko-grey-900);
    font-family: var(--font-heading);
    font-size: 1.4rem;
    font-weight: 700;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
}

.form-field {
    min-width: 0;
}

.form-field--full {
    grid-column: 1 / -1;
}

.form-field label,
.form-field__label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--tufko-grey-900);
    font-weight: 700;
}

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;
    min-height: 50px;
    padding: 0.9rem 1rem;
    background: var(--tufko-white);
    border: 2px solid var(--tufko-steel);
    border-radius: 0;
    box-shadow:
        inset 0 1px 2px rgb(0 0 0 / 5%),
        0 0 0 1px rgb(255 255 255 / 80%);
    color: var(--tufko-grey-900);
    font: inherit;
    transition:
        border-color var(--transition-fast),
        box-shadow var(--transition-fast),
        background-color var(--transition-fast);
}

.form-field input::placeholder,
.form-field textarea::placeholder {
    color: var(--tufko-grey-700);
    opacity: 0.72;
}

.form-field select {
    cursor: pointer;
}

.form-field:has([aria-invalid="true"]) {
    scroll-margin-top: 8rem;
}

.form-field textarea {
    min-height: 190px;
    resize: vertical;
}

.form-field input:hover,
.form-field select:hover,
.form-field textarea:hover {
    border-color: var(--tufko-steel-dark);
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    background: #fffdfb;
    border-color: var(--tufko-orange);
    box-shadow:
        0 0 0 4px rgb(232 74 0 / 16%),
        inset 0 1px 2px rgb(0 0 0 / 5%);
    outline: 0;
}

.form-field input[aria-invalid="true"],
.form-field select[aria-invalid="true"],
.form-field textarea[aria-invalid="true"] {
    border-color: #b42318;
}

.form-field textarea {
    min-height: 180px;
    resize: vertical;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    border-color: var(--tufko-orange);
    outline: 3px solid rgb(232 74 0 / 18%);
    outline-offset: 1px;
}

.form-field input[aria-invalid="true"],
.form-field select[aria-invalid="true"],
.form-field textarea[aria-invalid="true"] {
    border-color: #b42318;
}

.form-help {
    margin: 0.45rem 0 0;
    color: var(--tufko-grey-700);
    font-size: 0.88rem;
}

.form-field-errors {
    margin: 0.45rem 0 0;
    padding: 0;
    color: #9f1c12;
    font-size: 0.9rem;
    list-style: none;
}

.form-field-errors--advisory {
    margin-top: 0.75rem;
    padding: 1rem 1.1rem;
    background: rgb(232 74 0 / 7%);
    border-left: 4px solid var(--tufko-orange);
    color: var(--tufko-orange-dark);
    line-height: 1.55;
}

.form-radio-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem 1.75rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.form-radio-list label {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0;
    font-weight: 400;
}

.form-radio-list input {
    width: auto;
}

.form-consent {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 0.75rem;
    align-items: start;
}

.form-consent input {
    width: auto;
    margin-top: 0.25rem;
}

.form-consent label {
    margin: 0;
    font-weight: 400;
}

.form-consent a {
    color: var(--tufko-orange-dark);
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    margin-top: 2rem;
}

.form-actions p {
    max-width: 52ch;
    margin: 0;
    color: var(--tufko-grey-700);
    font-size: 0.88rem;
}

.form-honeypot {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0 0 0 0) !important;
    white-space: nowrap !important;
}

/* Sidebar */

.contact-sidebar {
    padding: 2rem;
    background: var(--tufko-grey-100);
    border-top: 4px solid var(--tufko-orange);
}

.contact-sidebar h2 {
    font-size: 1.7rem;
}

.contact-sidebar__steps {
    margin: 1.5rem 0 0;
    padding: 0;
    list-style: none;
}

.contact-sidebar__steps li {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 1rem;
    align-items: start;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--tufko-grey-300);
}

.contact-sidebar__steps li:last-child {
    border-bottom: 0;
}

.contact-step__marker {
    position: relative;
    display: block;
    width: 38px;
    height: 38px;
    background: var(--tufko-white);
    border: 2px solid var(--tufko-orange);
    transform: rotate(45deg);
}

.contact-step__marker::before,
.contact-step__marker::after {
    position: absolute;
    background: var(--tufko-orange);
    content: "";
    transform: rotate(-45deg);
    transform-origin: center;
}

.contact-step--received .contact-step__marker::before {
    top: 16px;
    left: 9px;
    width: 17px;
    height: 2px;
}

.contact-step--received .contact-step__marker::after {
    top: 10px;
    left: 17px;
    width: 2px;
    height: 14px;
}

.contact-step--review .contact-step__marker::before {
    top: 10px;
    left: 10px;
    width: 13px;
    height: 13px;
    background: transparent;
    border: 2px solid var(--tufko-orange);
    border-radius: 50%;
}

.contact-step--review .contact-step__marker::after {
    top: 23px;
    left: 22px;
    width: 10px;
    height: 2px;
}

.contact-step--discussion .contact-step__marker::before {
    top: 10px;
    left: 8px;
    width: 19px;
    height: 14px;
    background: transparent;
    border: 2px solid var(--tufko-orange);
}

.contact-step--discussion .contact-step__marker::after {
    top: 23px;
    left: 11px;
    width: 8px;
    height: 8px;
    clip-path: polygon(0 0, 100% 0, 0 100%);
}

.contact-step--confirmed .contact-step__marker::before {
    top: 17px;
    left: 8px;
    width: 10px;
    height: 2px;
}

.contact-step--confirmed .contact-step__marker::after {
    top: 12px;
    left: 15px;
    width: 17px;
    height: 2px;
}

.contact-sidebar__steps strong {
    display: block;
    margin-bottom: 0.35rem;
    font-family: var(--font-heading);
    font-size: 1.15rem;
}

.contact-sidebar__steps li>div>span {
    color: var(--tufko-grey-700);
    font-size: 0.93rem;
}

.contact-sidebar__steps strong {
    display: block;
    margin-bottom: 0.35rem;
    font-family: var(--font-heading);
    font-size: 1.15rem;
}

.contact-sidebar__steps span {
    color: var(--tufko-grey-700);
    font-size: 0.93rem;
}

.contact-sidebar__notice {
    margin: 1.5rem 0 0;
    padding-top: 1.5rem;
    border-top: 1px solid var(--tufko-grey-300);
    color: var(--tufko-grey-700);
    font-size: 0.9rem;
}

/* Success page */

.contact-success-section {
    min-height: 65vh;
    background: var(--tufko-grey-100);
}

.contact-success {
    max-width: 850px;
    padding: clamp(2rem, 6vw, 4rem);
    background: var(--tufko-white);
    border-top: 5px solid var(--tufko-orange);
}

.contact-success__mark {
    width: 78px;
    height: auto;
    margin-bottom: 1.75rem;
}

.contact-success p:not(.eyebrow) {
    max-width: 64ch;
    color: var(--tufko-grey-700);
    font-size: 1.05rem;
}

.contact-success__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 2rem;
}

/* Responsive */

@media (max-width: 900px) {

    .contact-hero__inner,
    .contact-layout {
        grid-template-columns: 1fr;
    }

    .contact-hero__mark img {
        width: min(55%, 250px);
    }
}

@media (max-width: 650px) {
    .form-grid {
        grid-template-columns: 1fr;
    }

    .form-field--full {
        grid-column: auto;
    }

    .form-radio-list {
        flex-direction: column;
        gap: 0.8rem;
    }

    .form-actions {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .contact-hero__inner {
        padding-block: 3.75rem;
    }

    .contact-hero h1 {
        font-size: clamp(2.7rem, 13vw, 4rem);
    }

    .contact-hero__mark img {
        width: min(72%, 220px);
    }

    .contact-sidebar,
    .contact-success {
        padding: 1.5rem;
    }
}
