/* Native forms — markdown-managed formularze przenoszone z NEXForms/VFB. */

.native-form {
    margin-block: var(--s-8);
    padding: clamp(var(--s-5), 3vw, var(--s-8));
    border: 1px solid var(--border);
    border-radius: var(--r-card);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
}

.native-form__head {
    max-width: 760px;
    margin-bottom: var(--s-5);
}

.native-form__kicker {
    margin: 0 0 var(--s-2);
    color: var(--accent-warm-600, var(--green-700));
    font-size: .78rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.native-form__head h2,
.native-form__success h2 {
    margin: 0 0 var(--s-3);
    color: var(--green-900);
    font-size: clamp(1.45rem, 2.4vw, 2rem);
    line-height: 1.2;
}

.native-form__head p,
.native-form__success p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.65;
}

.native-form__form {
    display: grid;
    gap: var(--s-4);
}

.native-form__field {
    display: grid;
    gap: var(--s-2);
}

.native-form__field fieldset {
    display: grid;
    gap: var(--s-3);
    min-width: 0;
    margin: 0;
    padding: 0;
    border: 0;
}

.native-form__field label {
    color: var(--green-900);
    font-weight: 650;
}

.native-form__field legend {
    color: var(--green-900);
    font-weight: 650;
}

.native-form__field label span,
.native-form__field legend span {
    color: var(--accent-warm-600, var(--green-700));
}

.native-form__field input,
.native-form__field textarea,
.native-form__field select {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font: inherit;
}

.native-form__field textarea {
    min-height: 180px;
    resize: vertical;
    line-height: 1.55;
}

.native-form__field input:focus,
.native-form__field textarea:focus,
.native-form__field select:focus {
    border-color: var(--accent-warm-600, var(--green-700));
    outline: 3px solid color-mix(in srgb, var(--accent-warm-600, var(--green-700)) 20%, transparent);
}

.native-form__field--invalid input,
.native-form__field--invalid textarea,
.native-form__field--invalid select {
    border-color: #b42318;
}

.native-form__help {
    margin: calc(var(--s-2) * -1) 0 0;
    color: var(--text-muted);
    font-size: .92rem;
    line-height: 1.5;
}

.native-form__choices {
    display: grid;
    gap: var(--s-2);
}

.native-form__choice {
    display: grid;
    grid-template-columns: 22px 1fr;
    gap: var(--s-3);
    align-items: start;
    padding: var(--s-3);
    border: 1px solid var(--green-100, var(--border));
    border-radius: 8px;
    background: #fff;
    color: var(--text);
    font-weight: 500;
    line-height: 1.5;
}

.native-form__choice input {
    width: 18px;
    min-height: 18px;
    height: 18px;
    margin: 3px 0 0;
    padding: 0;
    accent-color: var(--green-700);
}

.native-form__choice span {
    color: var(--text);
}

.native-form__choice strong {
    color: var(--accent-warm-600, var(--green-700));
}

.native-form__choice:has(input:checked) {
    border-color: var(--green-300, var(--green-700));
    background: var(--green-50);
}

.native-form__field-error,
.native-form__error {
    margin: 0;
    color: #b42318;
    font-size: .92rem;
    line-height: 1.5;
}

.native-form__error {
    margin-bottom: var(--s-4);
    padding: var(--s-3) var(--s-4);
    border: 1px solid #fecdca;
    border-radius: 8px;
    background: #fff3f2;
}

.native-form__privacy {
    margin: var(--s-1) 0 0;
    padding: var(--s-4);
    border: 1px solid var(--green-100, var(--border));
    border-radius: 8px;
    background: var(--green-50);
    color: var(--text-muted);
    font-size: .92rem;
    line-height: 1.55;
}

.native-form__submit {
    justify-self: start;
    min-height: 48px;
    padding: 0 var(--s-6);
    border: 0;
    border-radius: 999px;
    background: var(--accent-warm-600, var(--green-700));
    color: #fff;
    cursor: pointer;
    font: inherit;
    font-weight: 700;
}

.native-form__submit:hover,
.native-form__submit:focus-visible {
    background: var(--green-800);
}

.native-form__submit:focus-visible {
    outline: 3px solid var(--accent-gold-500, var(--green-700));
    outline-offset: 3px;
}

.native-form__success {
    padding: var(--s-5);
    border: 1px solid var(--green-200, var(--border));
    border-left: 4px solid var(--green-700);
    border-radius: 8px;
    background: var(--green-50);
}

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

@media (max-width: 600px) {
    .native-form {
        margin-inline: calc(var(--s-4) * -1);
        border-inline: 0;
        border-radius: 0;
    }

    .native-form__submit {
        width: 100%;
    }
}
