/* Modern, responsive styles for the contact forms */
:root {
    --contact-card-radius: clamp(18px, 4vw, 28px);
    --contact-shadow: 0 20px 45px rgba(15, 23, 42, 0.12);
    --contact-shadow-dark: 0 24px 60px rgba(0, 0, 0, 0.55);
}

.contact-page {
    max-width: min(960px, 100%);
    margin: 0 auto;
    padding: clamp(2rem, 5vw, 3.5rem) clamp(1rem, 4vw, 2.5rem);
    display: flex;
    flex-direction: column;
    gap: clamp(1.5rem, 4vw, 2.5rem);
}

.contact-page > h1 {
    text-align: center;
    margin-bottom: 0.75rem;
}

.contact-intro {
    align-self: flex-start;
    text-align: left;
    font-size: clamp(1rem, 2.2vw, 1.15rem);
    color: var(--neutral-gray);
    max-width: 58ch;
    margin: 0;
}

html.dark-mode .contact-intro {
    color: var(--neutral-gray);
    color: color-mix(in srgb, var(--neutral-gray) 65%, #ffffff 35%);
}

.contact-card {
    background: rgba(255, 255, 255, 0.88);
    border-radius: var(--contact-card-radius);
    padding: clamp(1.75rem, 4vw, 3rem);
    box-shadow: var(--contact-shadow);
    border: 1px solid rgba(13, 172, 219, 0.15);
    display: flex;
    flex-direction: column;
    gap: clamp(1.25rem, 3vw, 2rem);
}

.contact-card p {
    text-align: left;
}

html.dark-mode .contact-card {
    background: rgba(15, 23, 42, 0.92);
    border: 1px solid rgba(13, 172, 219, 0.28);
    box-shadow: var(--contact-shadow-dark);
}

.contact-form {
    display: grid;
    gap: clamp(1rem, 3vw, 1.5rem);
}

.contact-form__group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.contact-form__label {
    font-weight: 600;
    font-size: 1rem;
    color: var(--color-text);
    text-align: left;
}

.contact-form__label span {
    font-weight: 400;
    color: var(--neutral-gray);
    margin-left: 0.35rem;
    font-size: 0.9rem;
}

html.dark-mode .contact-form__label span {
    color: var(--neutral-gray);
    color: color-mix(in srgb, var(--neutral-gray) 70%, #ffffff 30%);
}

.contact-form__help {
    font-size: 0.92rem;
    line-height: 1.4;
    color: var(--neutral-gray);
}

html.dark-mode .contact-form__help {
    color: var(--neutral-gray);
    color: color-mix(in srgb, var(--neutral-gray) 60%, #ffffff 40%);
}

.contact-form__input,
.contact-form__textarea {
    width: 100%;
    border-radius: 16px;
    border: 1px solid var(--color-input-border);
    background: var(--color-input-bg);
    color: var(--color-input-text);
    padding: 0.85rem 1rem;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.contact-form__textarea {
    min-height: clamp(180px, 30vw, 240px);
    resize: vertical;
}

.contact-form__input:focus,
.contact-form__textarea:focus {
    outline: none;
    border-color: var(--color-accent);
    box-shadow: 0 0 0 3px rgba(13, 172, 219, 0.18);
}

html.dark-mode .contact-form__input:focus,
html.dark-mode .contact-form__textarea:focus {
    box-shadow: 0 0 0 3px rgba(13, 172, 219, 0.32);
}

.contact-form__input--error,
.contact-form__textarea--error {
    border-color: var(--red-accent);
    box-shadow: 0 0 0 3px rgba(175, 0, 0, 0.18);
}

html.dark-mode .contact-form__input--error,
html.dark-mode .contact-form__textarea--error {
    box-shadow: 0 0 0 3px rgba(255, 95, 175, 0.3);
}

.contact-form__error {
    color: var(--red-accent);
    font-size: 0.9rem;
}

.contact-form__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: center;
    justify-content: flex-start;
}

.contact-form__actions .btn {
    padding: 0.85rem 1.6rem;
    font-size: 1rem;
}

.contact-form__privacy {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--neutral-gray);
}

.contact-form__privacy a {
    color: var(--color-accent);
    text-decoration: underline;
}

html.dark-mode .contact-form__privacy {
    color: var(--neutral-gray);
    color: color-mix(in srgb, var(--neutral-gray) 65%, #ffffff 35%);
}

.form-alert {
    border-radius: 16px;
    padding: 1rem 1.25rem;
    border-left: 4px solid var(--color-accent);
    background: rgba(13, 172, 219, 0.12);
    color: var(--color-text);
}

html.dark-mode .form-alert {
    background: rgba(13, 172, 219, 0.18);
}

.form-alert--error {
    border-left-color: var(--red-accent);
    background: rgba(175, 0, 0, 0.12);
}

html.dark-mode .form-alert--error {
    background: rgba(255, 95, 175, 0.18);
}

.form-alert ul {
    margin-top: 0.5rem;
    padding-left: 1.2rem;
    list-style: disc;
}

.contact-security-note {
    font-size: 0.9rem;
    color: var(--neutral-gray);
}

html.dark-mode .contact-security-note {
    color: var(--neutral-gray);
    color: color-mix(in srgb, var(--neutral-gray) 60%, #ffffff 40%);
}

.contact-form__turnstile {
    display: flex;
    justify-content: flex-start;
}

.contact-success {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    align-items: center;
}

.contact-success__icon {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-accent), var(--steel-blue));
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 2rem;
    box-shadow: 0 12px 30px rgba(13, 172, 219, 0.35);
}

html.dark-mode .contact-success__icon {
    box-shadow: 0 12px 30px rgba(13, 172, 219, 0.55);
}

.contact-success__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

@media (max-width: 640px) {
    .contact-card {
        padding: clamp(1.5rem, 6vw, 2.25rem);
    }

    .contact-form__actions {
        justify-content: center;
    }
}
