.htan-form-wrap {
    max-width: 1000px;
    margin-inline: auto;
}

.hsp-form-product-context {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: .25rem 1rem;
    margin-bottom: 1rem;
    padding: 1rem 1.2rem;
    border-inline-start: 4px solid var(--hsp-red, #d92d32);
    border-radius: 3px;
    background: var(--hsp-light, #f3f5f7);
}

.hsp-form-product-context span {
    grid-column: 1 / -1;
    color: var(--hsp-muted, #5f6872);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.hsp-form-product-context a {
    color: var(--hsp-dark-2, #24303b);
    font-size: .85rem;
    font-weight: 700;
}

.htan-rfq-form {
    display: grid;
    gap: 1.25rem;
}

.hsp-form-section {
    margin: 0;
    padding: clamp(1rem, 3vw, 1.75rem);
    border: 1px solid var(--hsp-border, #d6dbe1);
    border-radius: 4px;
    background: var(--hsp-white, #fff);
}

.hsp-form-section legend {
    padding: 0 .5rem;
    color: var(--hsp-dark, #111820);
    font-size: 1.05rem;
    font-weight: 800;
}

.hsp-form-section legend span {
    margin-inline-end: .4rem;
    color: var(--hsp-red, #d92d32);
    font-size: .72rem;
    letter-spacing: .08em;
}

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

.htan-form-field {
    display: grid;
    gap: .4rem;
}

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

.htan-form-field input:not([type="checkbox"]):not([type="file"]),
.htan-form-field textarea,
.htan-form-field select {
    width: 100%;
    border: 1px solid var(--hsp-border, #d6dbe1);
    min-height: 46px;
    border-radius: 3px;
    padding: .75rem .85rem;
    background: var(--hsp-white, #fff);
    color: inherit;
}

.htan-form-field input:focus,
.htan-form-field textarea:focus,
.htan-form-field select:focus {
    outline: 3px solid color-mix(in srgb, var(--hsp-red, #d92d32) 28%, transparent);
    outline-offset: 2px;
    border-color: var(--hsp-red, #d92d32);
}

.htan-form-field input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    border: 0;
    margin: -1px;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    overflow: hidden;
    white-space: nowrap;
}

.hsp-file-picker {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: center;
    border: 1px dashed var(--hsp-border-strong, #aeb6bf);
    border-radius: 3px;
    background: var(--hsp-light, #f3f5f7);
    cursor: pointer;
}

.hsp-file-picker__action {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    padding: .75rem 1rem;
    border-inline-end: 1px solid var(--hsp-border, #d6dbe1);
    background: var(--hsp-dark-2, #24303b);
    color: var(--hsp-white, #fff);
    font-size: .84rem;
    font-weight: 750;
}

.hsp-file-picker__name {
    min-width: 0;
    padding: .75rem 1rem;
    color: var(--hsp-muted, #5f6872);
    overflow-wrap: anywhere;
}

.htan-form-field input[type="file"]:focus-visible + .hsp-file-picker {
    outline: 3px solid color-mix(in srgb, var(--hsp-red, #d92d32) 28%, transparent);
    outline-offset: 2px;
    border-color: var(--hsp-red, #d92d32);
}

.htan-form-field label,
.htan-form-label {
    font-size: .84rem;
    font-weight: 720;
}

.htan-form-field small {
    color: var(--hsp-muted, #5f6872);
}

.htan-consent {
    padding-top: .3rem;
}

.htan-honeypot {
    position: absolute !important;
    left: -10000px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.htan-form-notice {
    padding: 1rem;
    margin-bottom: 1rem;
    border-inline-start: 4px solid;
}

.htan-form-success {
    background: var(--hsp-success-soft, #edf8f2);
    border-color: var(--hsp-success, #247a52);
}

.htan-form-error {
    background: var(--hsp-error-soft, #fff1f1);
    border-color: var(--hsp-error, #b91f25);
}

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

    .htan-form-field-wide {
        grid-column: auto;
    }

    .hsp-file-picker {
        grid-template-columns: 1fr;
    }

    .hsp-file-picker__action {
        justify-content: center;
        border-inline-end: 0;
        border-bottom: 1px solid var(--hsp-border, #d6dbe1);
    }
}
