.sf {
    --sf-accent: #5bc8e0;
    --sf-accent-strong: #2fa9c6;
    --sf-text: #2b2b2b;
    --sf-muted: #8f8f8f;
    --sf-border: #4d4d4d;
    --sf-line: #b5b5b5;
    --sf-error: #c62828;
    --sf-container: 51rem;
    --sf-gutter: 1.25rem;

    display: block;
    margin: 0;
    color: var(--sf-text);
}

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

.sf .d-none {
    display: none !important;
}

.sf [hidden] {
    display: none !important;
}

.sf [data-sf-heading]:focus {
    outline: none;
}

.sf__container {
    max-width: calc(var(--sf-container) + 2 * var(--sf-gutter));
    margin: 0 auto;
    padding-left: var(--sf-gutter);
    padding-right: var(--sf-gutter);
}

.sf__bar {
    background: linear-gradient(to bottom, #fff 0%, #fff 45%, #ebebeb 100%);
    border-bottom: 1px solid #d0d0d0;
}

.sf__bar-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding-top: 2.5rem;
    padding-bottom: 1.6rem;
}

.sf__breadcrumb {
    margin: 0;
    font-size: 0.75rem;
    line-height: 1.4;
}

.sf__breadcrumb-separator {
    margin: 0 0.45em;
}

.sf__breadcrumb strong {
    font-weight: 700;
}

.sf-progress {
    display: flex;
    gap: 0.2rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sf-progress__dot {
    width: 0.875rem;
    height: 0.875rem;
    border: 1px solid var(--sf-border);
    border-radius: 50%;
}

.sf-progress__dot--done {
    background: var(--sf-accent);
    border-color: var(--sf-accent);
}

/* ---------- Card ---------- */

.sf__card {
    position: relative;
    background: #fff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.18);
}

.sf__card-inner {
    padding-top: 2.75rem;
    padding-bottom: 1.5rem;
}

.sf-step--tiles .sf-tiles--large {
    margin-bottom: 4rem;
}

/* ---------- Step head ---------- */

.sf-step__head {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 4rem;
}

.sf-icon {
    display: block;
    flex: none;
    height: 3.25rem;
    width: auto;
    color: var(--sf-accent);
}

.sf-step__question {
    margin: 0;
    font-size: 1.6rem;
    font-weight: 300;
    line-height: 1.25;
}

.sf-step__hint {
    margin: 1.75rem 0 0;
    font-size: 0.85rem;
    color: var(--sf-muted);
}

/* ---------- Intro (first step) ---------- */

.sf-step__intro {
    text-align: center;
}

.sf-step__icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: flex-end;
    gap: 1rem 1.75rem;
    max-width: 37rem;
    margin: 0 auto 1.75rem;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--sf-accent);
}

.sf-step__icons .sf-icon {
    height: 3rem;
}

.sf-step__headline {
    margin: 0 0 1.75rem;
    font-size: 2.1rem;
    font-weight: 400;
    line-height: 1.2;
}

.sf-step__text {
    max-width: 32rem;
    margin: 0 auto 3.5rem;
    line-height: 1.3;
}

.sf-step__formhint {
    margin: 0 0 1.75rem;
    font-weight: 700;
}

/* ---------- Plain fields (contact step) ---------- */

.sf-step__fields--intro,
.sf-step__fields--fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem 1.25rem;
}

.sf-step__fields--intro {
    max-width: 23.5rem;
    margin: 0 auto;
}

.sf-step__fields--fields {
    max-width: 32rem;
}

.sf-step__fields:empty {
    display: none;
}

.sf-step--intro .sf-step__text:last-child {
    margin-bottom: 1.5rem;
}

.sf-cell--full {
    grid-column: 1 / -1;
}

.sf-cell--hidden {
    display: none;
}

.sf .sf-step__fields input[type="text"],
.sf .sf-step__fields input[type="email"],
.sf .sf-step__fields input[type="tel"],
.sf .sf-step__fields input[type="number"],
.sf .sf-step__fields input[type="date"],
.sf .sf-step__fields select {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0.3rem 0;
    border: 0;
    border-bottom: 1px solid var(--sf-line);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    color: inherit;
    font: inherit;
    font-size: 0.8rem;
    transition: border-color 0.15s;
}

.sf .sf-step__fields select {
    -webkit-appearance: none;
    appearance: none;
    padding-right: 1.25rem;
    background: no-repeat right 0.15rem center / 0.6rem
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%234d4d4d' stroke-width='1.2'/%3E%3C/svg%3E");
    cursor: pointer;
}

.sf .sf-step__fields .select__wrap,
.sf .sf-step__fields .select__style-wrapper {
    position: relative;
    height: auto;
    min-height: 0;
}

.sf .sf-step__fields .select__field {
    position: static;
    height: auto;
    opacity: 1;
}

.sf .sf-step__fields input::placeholder {
    color: var(--sf-text);
    opacity: 1;
}

.sf .sf-step__fields input:focus,
.sf .sf-step__fields select:focus {
    outline: none;
    border-bottom-color: var(--sf-accent);
    box-shadow: 0 1px 0 var(--sf-accent);
}

/* Consent texts from HubSpot */
.sf .sf-cell--rte {
    font-size: 0.6rem;
    line-height: 1.45;
    color: #4d4d4d;
}

.sf .sf-cell--rte p {
    margin: 0 0 0.4em;
}

.sf .sf-cell--recaptchaV2 {
    margin-top: -0.75rem;
}

/* ---------- Tiles ---------- */

.sf-tiles {
    display: grid;
    grid-template-columns: repeat(var(--sf-cols, 4), minmax(0, 1fr));
    gap: 2rem;
}

.sf-tiles--wide {
    gap: 1rem 2rem;
}

.sf-tiles--square {
    grid-template-columns: repeat(var(--sf-cols, 4), minmax(0, 8.5rem));
    justify-content: center;
}

.sf-tile {
    position: relative;
}

/* Visually hidden but focusable; kept in place so browser validation bubbles point at the tile */
.sf-tile__input {
    position: absolute;
    left: 50%;
    bottom: 0;
    width: 1px;
    height: 1px;
    margin: 0;
    opacity: 0;
}

.sf-tile__label {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    min-height: 2.65rem;
    margin: 0;
    padding: 0.5rem 0.75rem;
    border: 1px solid var(--sf-border);
    background: #fff;
    color: #444;
    font-size: 1.05rem;
    line-height: 1.2;
    text-align: center;
    cursor: pointer;
    hyphens: auto;
    overflow-wrap: break-word;
    transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.sf-tiles--square .sf-tile__label {
    aspect-ratio: 1;
    font-size: 0.95rem;
}

.sf-tiles--large .sf-tile__label {
    min-height: 5.5rem;
    font-size: 1.4rem;
}

.sf-tile__label:hover {
    border-color: var(--sf-accent);
}

.sf-tile__input:checked + .sf-tile__label {
    background: var(--sf-accent);
    border-color: var(--sf-accent);
    color: #fff;
    font-weight: 700;
}

.sf-tile__input:focus-visible + .sf-tile__label {
    outline: 2px solid var(--sf-accent-strong);
    outline-offset: 3px;
}

/* ---------- Textarea step ---------- */

.sf-step__fields--text .sf-field {
    position: relative;
}

.sf-step__fields--text .textarea-label {
    position: absolute;
    top: 0.6rem;
    left: 1rem;
    font-size: 0.7rem;
    pointer-events: none;
}

.sf .sf-step__fields--text textarea {
    display: block;
    width: 100%;
    min-height: 13rem;
    margin: 0;
    padding: 0.75rem 1rem;
    border: 1px solid var(--sf-border);
    border-radius: 0;
    background: #fff;
    color: inherit;
    font: inherit;
    resize: vertical;
}

.sf .sf-step__fields--text .textarea-label ~ .textarea textarea {
    padding-top: 1.75rem;
}

.sf .sf-step__fields--text textarea:focus {
    outline: none;
    border-color: var(--sf-accent);
    box-shadow: 0 0 0 1px var(--sf-accent);
}

/* ---------- Errors ---------- */

.sf .form-error {
    display: block;
    margin-top: 0.4rem;
    color: var(--sf-error);
    font-size: 0.75rem;
}

.sf .sf-choice .form-error {
    margin-top: 1rem;
}

/* ---------- Navigation ---------- */

.sf__nav-wrap {
    background: linear-gradient(to bottom, #ececec 0%, #fff 3.5rem);
}

.sf-nav {
    display: flex;
    flex-direction: row-reverse;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding-top: 3.25rem;
    padding-bottom: 3rem;
}

.sf-btn {
    min-width: 6.25rem;
    margin: 0;
    padding: 0.4rem 1.4rem;
    border-radius: 0;
    background: #fff;
    font: inherit;
    font-size: 0.9rem;
    line-height: 1.3;
    white-space: nowrap;
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s;
}

.sf-btn--next {
    border: 2px solid var(--sf-accent);
    color: var(--sf-accent);
    font-weight: 700;
}

.sf-btn--next:hover,
.sf--intro .sf-btn--next {
    background: var(--sf-accent);
    color: #fff;
}

.sf--intro .sf-btn--next:hover {
    background: var(--sf-accent-strong);
    border-color: var(--sf-accent-strong);
}

.sf-btn--back {
    border: 1px solid #a3a3a3;
    color: var(--sf-muted);
}

.sf-btn--back:hover {
    border-color: var(--sf-border);
    color: var(--sf-text);
}

.sf-btn:focus-visible {
    outline: 2px solid var(--sf-accent-strong);
    outline-offset: 3px;
}

/* ---------- Mobile ---------- */

@media (max-width: 47.99rem) {
    .sf__bar-inner {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .sf-step__head {
        flex-direction: column;
        gap: 2rem;
        margin-bottom: 3rem;
        text-align: center;
    }

    .sf-step__head .sf-icon {
        height: 5rem;
    }

    .sf-step__question {
        font-size: 1.85rem;
    }

    .sf-step__icons {
        max-width: 13rem;
    }

    .sf-step__icons .sf-icon {
        height: 2.25rem;
    }

    .sf-step__headline {
        font-size: 1.85rem;
    }

    .sf-step__fields--intro,
    .sf-step__fields--fields {
        grid-template-columns: minmax(0, 1fr);
        max-width: none;
    }

    .sf-step__hint {
        text-align: center;
    }

    .sf-tiles,
    .sf-tiles--wide,
    .sf-tiles--large {
        grid-template-columns: minmax(0, 1fr);
        gap: 1rem;
        max-width: 18.5rem;
        margin: 0 auto;
    }

    .sf-tiles--large {
        gap: 2.75rem;
        max-width: 16.5rem;
    }

    .sf-tiles--square {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 1.5rem;
        max-width: 23rem;
    }

    .sf-nav {
        padding-top: 2.5rem;
    }

    .sf-btn {
        min-width: 0;
        padding-left: 1rem;
        padding-right: 1rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    .sf-tile__label,
    .sf-btn,
    .sf .sf-step__fields input,
    .sf .sf-step__fields select {
        transition: none;
    }
}
