
/* =========================================================
   CONTACT PAGE
========================================================= */

main:has(.contact-page) {
    background: #f5f5f5;
}

/* =========================================================
   CONTACT PAGE SELECTOR
========================================================= */

.contact-selector {
    width: min(1600px, calc(100% - 48px));
    margin: 0 auto 16px;
}

.contact-selector-inner {
    display: flex;
    align-items: center;
    gap: 24px;
    width: 100%;
}

.contact-selector-options {
    display: flex;
    justify-content: center;
    gap: 16px;
    width: 100%;
}

.contact-option {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 180px;
    max-width: 180px;
    height: 32px;
    margin: 24px;
    padding: 0 16px;
    border: 1px solid #d8d8d8;
    background: #fff;
    color: #171717;
    font-family: inherit;
    font-size: 13px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    white-space: nowrap;
    cursor: pointer;
    box-sizing: border-box;
    transition:
        background 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease;
}

.contact-option:hover {
    border-color: #171717;
}

.contact-option.active {
    border-color: #171717;
    background: #171717;
    color: #fff;
}

.contact-label {
    display: block;
}

/* =========================================================
   CONTACT CONTENT SWITCHING
========================================================= */

[data-contact-content] {
    display: none;
}

[data-contact-content].is-active {
    display: block;
}

/* =========================================================
   CONTACT PAGE CONTAINER
========================================================= */

.contact-page {
    width: 100%;
    max-width: none;
    margin: 0;
    padding: 0 0 64px;
    background: #f5f5f5;
    color: #171717;
    font-family: "Inter", sans-serif;
    box-sizing: border-box;
}

.contact-page *,
.contact-page *::before,
.contact-page *::after {
    box-sizing: border-box;
}

/* =========================================================
   HERO
========================================================= */

.contact-header {
    width: min(1200px, calc(100% - 48px));
    margin: 0 auto 48px;
    padding: 32px 0 0;
    text-align: center;
}

.contact-header-brand {
    max-width: 900px;
    margin: 0 auto 32px;
    color: #444;
    font-family: "Instrument Serif", serif;
    font-size: 24px;
    font-weight: 400;
    line-height: 1.2;
    letter-spacing: 0;
}

.contact-title {
    max-width: 900px;
    margin: 0 auto;
    color: #171717;
    font-family: "Inter", sans-serif;
    font-size: clamp(32px, 5vw, 64px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.02em;
    text-align: center;
    transform: scaleY(1.125);
    transform-origin: center;
}

.contact-intro {
    max-width: 700px;
    margin: 24px auto 0;
    color: #666;
    font-family: "Inter", sans-serif;
    font-size: 15px;
    font-weight: 400;
    line-height: 1.8;
    text-align: center;
}

/* =========================================================
   FORM SECTION
========================================================= */

.contact-form-section {
    width: min(1200px, calc(100% - 48px));
    margin: 0 auto;
    padding: 60px 48px;
    background: #fff;
    border: 1px solid #e2e2e2;
    border-radius: 18px;
    box-shadow: 0 4px 18px rgba(0, 0, 0, 0.04);
}

.contact-form-inner {
    width: 100%;
    max-width: 760px;
    margin: 0 auto;
}

/* =========================================================
   STATUS MESSAGE
========================================================= */

.contact-status {
    display: none;
    margin: 0 0 28px;
    padding: 16px 18px;
    border: 1px solid #b7dfc4;
    background: #f0faf3;
    color: #27633a;
    font-size: 14px;
    line-height: 1.5;
}

.contact-status.is-visible {
    display: block;
}

/* =========================================================
   FORM
========================================================= */

.contact-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
    width: 100%;
}

.contact-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    width: 100%;
}

.contact-field {
    display: flex;
    flex-direction: column;
    gap: 9px;
    min-width: 0;
}

.contact-field label {
    margin: 0;
    color: #171717;
    font-family: "Inter", sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
}

/* =========================================================
   INPUTS
========================================================= */

.contact-field input,
.contact-field textarea {
    display: block;
    width: 100%;
    margin: 0;
    padding: 13px 14px;
    border: 1px solid #d7d7d7;
    border-radius: 6px;
    background: #fff;
    color: #171717;
    font-family: "Inter", sans-serif;
    font-size: 15px;
    font-weight: 400;
    line-height: 1.5;
    outline: none;
    box-sizing: border-box;
    transition:
        border-color 0.15s ease,
        box-shadow 0.15s ease;
}

.contact-field input {
    height: 48px;
}

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

.contact-field input:hover,
.contact-field textarea:hover {
    border-color: #a9a9a9;
}

.contact-field input:focus,
.contact-field textarea:focus {
    border-color: #20e1ff;
    box-shadow: 0 0 0 3px rgba(32, 225, 255, 0.14);
}

.contact-field input:focus-visible,
.contact-field textarea:focus-visible {
    outline: none;
}

/* =========================================================
   SUBMIT BUTTON
========================================================= */

.contact-submit-row {
    display: flex;
    justify-content: flex-end;
    margin-top: 4px;
}

.contact-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 12px 28px;
    border: 1px solid #171717;
    border-radius: 6px;
    background: #171717;
    color: #fff;
    font-family: "Inter", sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.4;
    text-align: center;
    cursor: pointer;
    transition:
        background-color 0.2s ease,
        border-color 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.contact-submit:hover {
    border-color: #20e1ff;
    background: #20e1ff;
    color: #171717;
    transform: translateY(-1px);
}

.contact-submit:active {
    transform: translateY(0);
}

.contact-submit:focus-visible {
    outline: 3px solid rgba(32, 225, 255, 0.5);
    outline-offset: 3px;
}

/* =========================================================
   TABLET
========================================================= */

@media (max-width: 900px) {

    .contact-selector-options {
        gap: 12px;
    }

    .contact-option {
        margin: 16px 8px;
    }

    .contact-header {
        width: min(700px, calc(100% - 32px));
        margin-bottom: 32px;
        padding: 24px 0 0;
    }

    .contact-form-section {
        width: calc(100% - 32px);
        padding: 48px 40px;
    }

}

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 600px) {

    .contact-selector-options {
        flex-direction: column;
        align-items: center;
        gap: 0;
    }

    .contact-option {
        width: 100%;
        max-width: 180px;
        margin: 8px 0;
    }

    .contact-page {
        padding-bottom: 48px;
    }

    .contact-header {
        width: calc(100% - 24px);
        margin-bottom: 24px;
        padding: 16px 0 0;
    }

    .contact-header-brand {
        margin-bottom: 16px;
        font-size: 20px;
    }

    .contact-title {
        font-size: clamp(32px, 9vw, 52px);
    }

    .contact-intro {
        margin-top: 20px;
        font-size: 13px;
        line-height: 1.7;
    }

    .contact-form-section {
        width: calc(100% - 24px);
        padding: 35px 25px;
        border-radius: 14px;
    }

    .contact-form {
        gap: 22px;
    }

    .contact-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .contact-field textarea {
        min-height: 160px;
    }

    .contact-submit-row {
        justify-content: stretch;
    }

    .contact-submit {
        width: 100%;
    }

}

/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 400px) {

    .contact-form-section {
        padding: 28px 20px;
    }

}

/* =========================================================
   REDUCED MOTION
========================================================= */

@media (prefers-reduced-motion: reduce) {

    .contact-submit,
    .contact-field input,
    .contact-field textarea {
        transition-duration: 0.01ms;
    }

}
