﻿@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@400;600;700;800&family=Source+Sans+3:ital,wght@0,400;0,600;1,400&display=swap');

:root {
    --navy: #1b3a6b;
    --navy-dark: #142d54;
    --blue: #2563a8;
    --blue-light: #e8f0fb;
    --red: #d93025;
    --red-bg: #fce8e6;
    --green: #1a7f4e;
    --green-bg: #e6f4ed;
    --orange-bg: #fff8e1;
    --orange: #b45309;
    --gray: #6b7280;
    --gray-light: #f3f4f6;
    --border: #d1d5db;
    --text: #1f2937;
    --text-light: #6b7280;
    --white: #ffffff;
    --shadow: 0 2px 12px rgba(27,58,107,.10);
    --shadow-lg: 0 8px 32px rgba(27,58,107,.15);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Source Sans 3', sans-serif;
    background: #f0f4fa;
    color: var(--text);
    min-height: 100vh;
    font-size: 15px;
    line-height: 1.6;
}

/* ── Pending / Blue Notice Box ── */
.notice-blue {
    background: #e8f0fb;
    border: 1px solid #2563a8;
    border-left: 4px solid #2563a8;
    border-radius: 8px;
    padding: 14px 18px;
    margin: 16px 0 8px;
    color: #1a3a6b;
    font-size: 14px;
    line-height: 1.6;
}

    .notice-blue strong {
        display: flex;
        align-items: center;
        gap: 6px;
        margin-bottom: 6px;
        font-size: 14.5px;
        font-family: 'Nunito', sans-serif;
    }

    .notice-blue p {
        margin: 0;
        color: #1a3a6b;
    }

/* Pending badge on success page */
.pending-badge {
    background: #e8f0fb !important;
    color: #1b3a6b !important;
}

/* NAV */
.top-nav {
    background: var(--white);
    border-bottom: 1px solid var(--border);
    padding: 0 32px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 70px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
}

.logo-circle {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: var(--navy);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 17px;
}

.logo-text {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: var(--navy);
    font-size: 20px;
}

.nav-actions {
    display: flex;
    gap: 8px;
}

.btn-nav {
    padding: 8px 18px;
    border-radius: 6px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
    border: none;
    letter-spacing: .4px;
    transition: all .2s;
}

.btn-nav-primary {
    background: var(--navy);
    color: var(--white);
}

    .btn-nav-primary:hover {
        background: var(--navy-dark);
    }

.btn-nav-outline {
    background: transparent;
    color: var(--navy);
    border: 2px solid var(--navy);
}

    .btn-nav-outline:hover {
        background: var(--blue-light);
    }

/* PAGE HEADER */
.page-header {
    background: linear-gradient(135deg, var(--navy) 0%, var(--blue) 100%);
    color: var(--white);
    text-align: center;
    padding: 40px 24px 32px;
}

    .page-header h1 {
        font-family: 'Nunito', sans-serif;
        font-weight: 800;
        font-size: clamp(22px, 4vw, 34px);
        margin: 0;
    }

/* CONTAINER */
.main-container {
    max-width: 780px;
    margin: 0 auto;
    padding: 28px 16px 60px;
}

/* INTRO BOX */
.intro-box {
    background: var(--white);
    border-left: 4px solid var(--blue);
    border-radius: 10px;
    padding: 20px 24px;
    margin-bottom: 24px;
    box-shadow: var(--shadow);
}

    .intro-box p {
        margin-bottom: 6px;
    }

        .intro-box p:last-child {
            margin-bottom: 0;
        }

    .intro-box a {
        color: var(--blue);
        font-weight: 600;
    }

    .intro-box .note {
        font-style: italic;
        color: var(--text-light);
        font-size: 13.5px;
    }

/* PROGRESS */
.progress-wrap {
    background: var(--white);
    border-radius: 10px;
    padding: 18px 22px;
    margin-bottom: 22px;
    box-shadow: var(--shadow);
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.progress-label {
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    color: var(--navy);
    font-size: 14px;
}

.progress-count {
    font-size: 13px;
    color: var(--text-light);
}

.progress-bar {
    background: var(--gray-light);
    border-radius: 100px;
    height: 8px;
    overflow: hidden;
}

.progress-fill {
    background: linear-gradient(90deg, var(--blue), #42a5f5);
    height: 100%;
    border-radius: 100px;
    transition: width .4s cubic-bezier(.4,0,.2,1);
}

.steps-dots {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
}

.step-dot {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    flex: 1;
}

.step-dot-circle {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 11px;
    background: var(--gray-light);
    color: var(--gray);
    transition: all .25s;
}

.step-dot.done .step-dot-circle {
    background: var(--green);
    color: var(--white);
}

.step-dot.active .step-dot-circle {
    background: var(--navy);
    color: var(--white);
    box-shadow: 0 0 0 3px rgba(37,99,168,.2);
}

.step-dot-label {
    font-size: 10px;
    color: var(--text-light);
    text-align: center;
    display: none;
}

@media (min-width: 560px) {
    .step-dot-label {
        display: block;
    }
}

/* ── Page 1 conditional groups ── */
.agpal-existing-msg {
    background: #e6f4ed;
    border: 1.5px solid #a7f3d0;
    border-radius: 10px;
    padding: 24px 28px;
    margin-bottom: 20px;
    text-align: left;
}

.agpal-existing-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #1a7f4e;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    margin-bottom: 14px;
}

.agpal-existing-msg h3 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 18px;
    color: #1a7f4e;
    margin-bottom: 10px;
}

.agpal-existing-msg p {
    font-size: 15px;
    color: #1f2937;
    line-height: 1.7;
}

.agpal-existing-msg a {
    color: #1b3a6b;
    font-weight: 700;
    text-decoration: none;
}

    .agpal-existing-msg a:hover {
        text-decoration: underline;
    }

/* ── Submit button variant for page 1 yes-agpal path ── */
.btn-submit-agpal {
    background: #1a7f4e;
    color: #fff;
    padding: 10px 26px;
    border-radius: 7px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: background 0.2s;
}

    .btn-submit-agpal:hover {
        background: #145f3a;
    }

/* FORM CARD */
.form-card {
    background: var(--white);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.section-header {
    background: var(--navy);
    color: var(--white);
    text-align: center;
    padding: 16px 24px;
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    font-size: 16px;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* STEP VISIBILITY — JS adds/removes .active */
.step-page {
    display: none;
}

    .step-page.active {
        display: block;
    }

/* FORM BODY */
.form-body {
    padding: 30px 34px;
}

@media (max-width: 560px) {
    .form-body {
        padding: 20px 16px;
    }
}

/* FIELDS */
.field-group {
    margin-bottom: 20px;
}

.field-label {
    display: block;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    color: var(--navy);
    margin-bottom: 5px;
}

.required-star {
    color: var(--red);
    margin-left: 1px;
}

.field-input,
.field-select {
    width: 100%;
    padding: 9px 13px;
    border: 1.5px solid var(--border);
    border-radius: 7px;
    font-family: 'Source Sans 3', sans-serif;
    font-size: 15px;
    color: var(--text);
    background: var(--white);
    outline: none;
    transition: border-color .2s, box-shadow .2s;
    -webkit-appearance: none;
    appearance: none;
}

.field-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='7'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 13px center;
    padding-right: 34px;
    cursor: pointer;
}

    .field-input:focus, .field-select:focus {
        border-color: var(--blue);
        box-shadow: 0 0 0 3px rgba(37,99,168,.12);
    }

.field-hint {
    font-size: 12.5px;
    color: var(--text-light);
    margin-top: 4px;
    line-height: 1.5;
}

/* ERROR MESSAGE — .visible class shows it */
.error-msg {
    display: none;
    align-items: center;
    gap: 6px;
    background: var(--red-bg);
    border: 1px solid #fca5a5;
    color: var(--red);
    font-size: 13px;
    font-weight: 600;
    padding: 7px 11px;
    border-radius: 6px;
    margin-bottom: 6px;
}

    .error-msg.visible {
        display: flex;
    }

/* LAYOUTS */
.row-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.row-3 {
    display: grid;
    grid-template-columns: 1fr 2fr 1fr;
    gap: 10px;
}

.row-name {
    display: grid;
    grid-template-columns: 90px 1fr 1fr;
    gap: 10px;
}

@media (max-width: 520px) {
    .row-2 {
        grid-template-columns: 1fr;
    }

    .row-3 {
        grid-template-columns: 1fr 1fr;
    }

    .row-name {
        grid-template-columns: 80px 1fr;
    }
}

.col-label {
    font-size: 11px;
    color: var(--text-light);
    margin-top: 3px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .4px;
}

/* RADIO */
.radio-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.radio-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 13px;
    border-radius: 7px;
    border: 1.5px solid var(--border);
    cursor: pointer;
    transition: border-color .15s, background .15s;
    font-size: 15px;
}

    .radio-item:hover {
        border-color: var(--blue);
        background: var(--blue-light);
    }

    .radio-item input[type=radio] {
        accent-color: var(--navy);
        width: 15px;
        height: 15px;
        flex-shrink: 0;
    }

    .radio-item.selected {
        border-color: var(--navy);
        background: var(--blue-light);
    }

/* CHECKBOXES */
.check-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 11px 13px;
    border-radius: 7px;
    border: 1.5px solid var(--border);
    margin-bottom: 10px;
    cursor: pointer;
    transition: border-color .15s, background .15s;
    font-size: 14px;
    line-height: 1.5;
}

    .check-item:hover {
        border-color: var(--blue);
        background: var(--blue-light);
    }

    .check-item input[type=checkbox] {
        accent-color: var(--navy);
        width: 15px;
        height: 15px;
        margin-top: 2px;
        flex-shrink: 0;
    }

    .check-item.checked {
        border-color: var(--navy);
        background: var(--blue-light);
    }

/* INFO BOXES */
.info-box {
    background: var(--blue-light);
    border-left: 4px solid var(--blue);
    border-radius: 0 7px 7px 0;
    padding: 13px 15px;
    font-size: 14px;
    color: #1e3a6e;
    line-height: 1.65;
    margin-bottom: 18px;
}

    .info-box strong {
        display: block;
        font-family: 'Nunito', sans-serif;
        margin-bottom: 3px;
    }

.info-box-warning {
    background: var(--orange-bg);
    border-left: 4px solid #f59e0b;
    border-radius: 0 7px 7px 0;
    padding: 13px 15px;
    font-size: 13.5px;
    color: var(--orange);
    line-height: 1.65;
    margin-bottom: 18px;
}

    .info-box-warning strong {
        display: block;
        font-family: 'Nunito', sans-serif;
        margin-bottom: 3px;
    }

.link-doc {
    color: var(--blue);
    font-weight: 600;
    font-style: italic;
    text-decoration: underline;
    font-size: 14px;
    cursor: pointer;
}

/* FEE TABLE */
.fee-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 14px;
}

    .fee-table td {
        padding: 8px 3px;
        font-size: 15px;
        border-bottom: 1px solid var(--gray-light);
    }

        .fee-table td:last-child {
            text-align: right;
            font-weight: 600;
        }

.fee-total td {
    font-family: 'Nunito', sans-serif;
    font-weight: 800 !important;
    font-size: 16px !important;
    color: var(--navy) !important;
}

/* SAVE BUTTON */
.btn-save {
    width: 100%;
    padding: 11px;
    border-radius: 7px;
    margin-top: 14px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    background: var(--gray-light);
    color: var(--gray);
    border: 1.5px solid var(--border);
    transition: all .2s;
}

    .btn-save:hover {
        border-color: var(--navy);
        color: var(--navy);
        background: var(--blue-light);
    }

/* FOOTER */
.form-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 34px;
    border-top: 1px solid var(--gray-light);
    background: var(--gray-light);
}

@media (max-width: 560px) {
    .form-footer {
        padding: 14px 16px;
    }
}

.page-indicator {
    font-size: 14px;
    color: var(--text-light);
    font-weight: 600;
}

.btn {
    padding: 10px 26px;
    border-radius: 7px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    border: none;
    transition: all .2s;
}

.btn-primary {
    background: var(--navy);
    color: var(--white);
}

    .btn-primary:hover {
        background: var(--navy-dark);
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(27,58,107,.22);
    }

.btn-secondary {
    background: var(--white);
    color: var(--navy);
    border: 2px solid var(--navy);
}

    .btn-secondary:hover {
        background: var(--blue-light);
    }

.btn-submit {
    background: linear-gradient(135deg, var(--navy), var(--blue));
    color: var(--white);
    padding: 13px 34px;
    font-size: 15px;
    border-radius: 8px;
}

    .btn-submit:hover {
        box-shadow: 0 6px 18px rgba(27,58,107,.32);
        transform: translateY(-2px);
    }

/* LEAD CARD */
.lead-card {
    background: var(--green-bg);
    border: 1.5px solid #a7f3d0;
    border-radius: 10px;
    padding: 18px 22px;
    margin-top: 22px;
    display: none;
}

    .lead-card h4 {
        font-family: 'Nunito', sans-serif;
        font-weight: 800;
        color: var(--green);
        font-size: 15px;
        margin-bottom: 12px;
    }

.lead-card-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 22px;
    font-size: 13.5px;
}

.lead-card-row span:first-child {
    color: var(--text-light);
    font-size: 11.5px;
    text-transform: uppercase;
    letter-spacing: .4px;
    display: block;
}

.lead-card-row span:last-child {
    color: var(--text);
    font-weight: 600;
}

/* SUCCESS PAGE */
.success-box {
    text-align: center;
    padding: 44px 24px;
}

.success-icon {
    width: 70px;
    height: 70px;
    background: var(--green-bg);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    margin: 0 auto 18px;
}

.success-box h2 {
    font-family: 'Nunito', sans-serif;
    font-weight: 800;
    color: var(--navy);
    font-size: 24px;
    margin-bottom: 10px;
}

.success-box p {
    color: var(--text-light);
    font-size: 15px;
    line-height: 1.7;
    max-width: 460px;
    margin: 0 auto 20px;
}

.lead-created-badge {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    background: var(--green-bg);
    color: var(--green);
    border: 1px solid #a7f3d0;
    border-radius: 100px;
    padding: 7px 18px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 13.5px;
    margin-bottom: 10px;
}

/* TOAST */
.toast {
    position: fixed;
    bottom: 22px;
    right: 22px;
    background: var(--navy);
    color: var(--white);
    padding: 13px 18px;
    border-radius: 10px;
    font-family: 'Nunito', sans-serif;
    font-weight: 700;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 9px;
    box-shadow: var(--shadow-lg);
    z-index: 9999;
    transform: translateY(80px);
    opacity: 0;
    transition: all .35s cubic-bezier(.4,0,.2,1);
    pointer-events: none;
}

    .toast.show {
        transform: translateY(0);
        opacity: 1;
    }
