/* Template 2: Single-column layout – form full-width, then steps; form on LEFT */

/* Form section: background image with form on the left */
.form-section {
    position: relative;
    min-height: 500px;
    overflow: hidden;
    display: flex;
    justify-content: flex-start;
}
.form-section .form-container {
    position: relative;
    z-index: 2;
    flex: 0 1 720px;
    max-width: 720px;
}
.form-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('https://res.cloudinary.com/dbtcg826q/image/upload/v1770135455/common/sp-buckets/img/waterfinances-bg.webp') center/cover no-repeat;
}
.form-background::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.5);
    pointer-events: none;
}

.steps-section .loading-container {
    text-align: center;
    padding: 2rem;
}

.steps-header {
    text-align: center !important;
    margin-bottom: 2rem;
}

.steps-section .steps-header {
    text-align: center !important;
}

.steps-main-title,
.steps-section .steps-main-title {
    font-size: 1.25rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.25rem 0;
    text-align: center !important;
}

.steps-subtitle,
.steps-section .steps-subtitle {
    font-size: 0.875rem;
    color: #475569;
    margin: 0 auto;
    line-height: 1.5;
    max-width: 560px;
    text-align: center !important;
}

/* Steps: mobile = single column; desktop = horizontal flow strip */
.steps-section .steps-container {
    display: flex !important;
    flex-direction: column !important;
    flex-wrap: nowrap !important;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    max-width: 100%;
    margin: 0 auto;
    overflow-x: visible;
    scroll-snap-type: none;
    padding: 0.5rem 1rem;
    grid-template-columns: none !important;
}

.steps-section .step {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: none;
    border-radius: 0;
    box-shadow: none;
    flex: none;
    min-width: 0;
    scroll-snap-align: none;
}

.steps-section .step:not(:last-child)::after {
    content: '\2193';
    display: block;
    flex-basis: 100%;
    width: 100%;
    text-align: center;
    margin: 0.15rem 0 0;
    color: var(--color-primary);
    font-size: 1.125rem;
}

.steps-section .step-icon {
    display: none !important;
}

.steps-section .step::before {
    content: attr(data-step);
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1;
    color: var(--color-primary);
}

.steps-section .step-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0;
}

.steps-section .step-description {
    display: none;
}

.loading-spinner {
    width: 36px;
    height: 36px;
    border: 2px solid var(--color-border);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 0.75rem;
}
.loading-text { color: #64748b; margin: 0; font-size: 0.875rem; }
@keyframes spin { to { transform: rotate(360deg); } }

.footer-content { max-width: var(--max-width); margin: 0 auto; text-align: center; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem 1rem; margin-bottom: 1rem; }
.footer-links a { color: #94a3b8; text-decoration: none; font-size: 0.875rem; }
.footer-links a:hover { color: #fff; }
.footer-info { margin-bottom: 0.5rem; }
.footer-info p { margin: 0.25rem 0; font-size: 0.875rem; }
.copyright { margin: 0; font-size: 0.8125rem; opacity: 0.9; }

.popup-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.5); z-index: 9999; align-items: center; justify-content: center; padding: 1rem; }
.popup-overlay[aria-hidden="false"] { display: flex; }
.popup-content { background: #fff; border-radius: 12px; max-width: 90vw; max-height: 90vh; overflow: auto; position: relative; padding: 2rem; }
.popup-close { position: absolute; top: 0.5rem; right: 0.5rem; background: none; border: none; font-size: 1.5rem; cursor: pointer; color: #64748b; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.disclaimer-content { max-width: var(--max-width); margin: 0 auto; }

@media (min-width: 768px) {
    .steps-section .steps-container {
        flex-direction: row !important;
        flex-wrap: wrap !important;
        align-items: center;
        gap: 0.75rem 0.5rem;
        padding: 1rem;
    }
    .steps-section .step {
        flex-wrap: nowrap;
    }
    .steps-section .step:not(:last-child)::after {
        content: '\2192';
        display: inline;
        flex-basis: auto;
        width: auto;
        margin: 0 0 0 0.25rem;
        color: var(--color-primary);
        font-size: 1.125rem;
    }
    .steps-section .step::before {
        font-size: 1.375rem;
    }
    .steps-section .step-title {
        font-size: 1rem;
    }
    .steps-main-title { font-size: 1.5rem; }
}

@media (min-width: 1024px) {
    .form-section .form-container {
        flex-basis: 820px;
        max-width: 820px;
        margin-left: clamp(1rem, 4vw, 4rem);
        box-sizing: border-box;
        background: #fff;
        border: 1px solid #e7e2ef;
        border-radius: 14px;
        box-shadow: 0 10px 28px rgba(37, 28, 56, 0.12);
        padding: 0.875rem;
        overflow: hidden;
    }
}
