/* ============================================================
   EasyPay Finance — Merchant Enrollment
   Brand design system: EasyPay Blue #1F5577 (headings),
   EasyPay Green #1AC668 (web CTAs), EasyPay Teal #1BCEAC (accents/links)
   ============================================================ */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Brand tokens */
    --ep-blue: #1F5577;
    --ep-blue-light: #2A6B94;
    --ep-green: #1AC668;
    --ep-green-hover: #15A857;
    --ep-teal: #1BCEAC;
    --ep-link: #0FA98C;            /* darker teal for text links (contrast) */
    --charcoal: #1A1A2E;
    --dark-text: #2C3E50;
    --gray-text: #6B7280;
    --light-gray: #F8F9FA;
    --border-gray: #E9ECEF;
    --white: #FFFFFF;
    --mint: #F0FDF9;
    --seafoam: #E6FFFA;
    --pale-green: #E8F9F0;
    --amber-bg: #FFF3CD;
    --amber-text: #856404;
    --gold: #FFC107;
    --success: #1AC668;
    --error: #DC3545;
    --shadow: 0 2px 12px rgba(31, 85, 119, 0.08);
    --shadow-hover: 0 6px 20px rgba(31, 85, 119, 0.14);

    /* Legacy aliases (inline styles in markup still reference these) */
    --primary-green: var(--ep-link);
    --primary-green-hover: var(--ep-green-hover);
}

body {
    font-family: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
    line-height: 1.6;
    color: var(--dark-text);
    background: linear-gradient(180deg, #EEF3F6 0%, var(--light-gray) 320px);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    flex: 1;
}

/* ===== Site header ===== */
.site-header {
    background: linear-gradient(135deg, #1F5577 0%, #2A6B94 100%);
    padding: 18px 24px;
}

.site-header-inner {
    max-width: 720px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.site-logo {
    height: 44px;
    width: auto;
    display: block;
    filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.25));
}

.site-header-title {
    color: var(--white);
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    opacity: 0.95;
    text-align: right;
}

.header-accent {
    height: 4px;
    background: linear-gradient(90deg, var(--ep-green), var(--ep-teal));
}

.container {
    max-width: 720px;
    margin: 0 auto;
    padding: 36px 20px 48px;
}

.card {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(31, 85, 119, 0.06);
    padding: 36px;
    margin-bottom: 24px;
}

.card.compact {
    padding: 28px;
}

.logo {
    text-align: center;
    margin-bottom: 24px;
}

.logo img {
    height: 55px;
    width: auto;
}

h2 {
    color: var(--ep-blue);
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.3px;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 14px;
}

h2::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 56px;
    height: 4px;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--ep-green), var(--ep-teal));
}

h3 {
    color: var(--ep-blue);
    font-size: 22px;
    font-weight: 700;
    letter-spacing: -0.2px;
    margin-bottom: 20px;
}

h4 {
    color: var(--dark-text);
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 16px;
    margin-top: 28px;
}

.subtitle {
    color: var(--gray-text);
    margin-bottom: 24px;
    font-size: 16px;
    line-height: 1.5;
}

.info-box {
    background: linear-gradient(135deg, var(--mint) 0%, var(--seafoam) 100%);
    border-left: 4px solid var(--ep-teal);
    padding: 16px 18px;
    margin-bottom: 24px;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.6;
}

.info-box strong {
    color: var(--ep-blue);
}

/* ===== Progress ===== */
.progress-container {
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(31, 85, 119, 0.06);
    padding: 18px 32px 14px;
    margin-bottom: 24px;
    display: none;
}

.progress-container.active {
    display: block;
    position: sticky;
    top: 12px;
    z-index: 100;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin-bottom: 8px;
}

.progress-step {
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 1;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.progress-step:hover {
    opacity: 0.85;
}

.progress-step-number {
    width: 34px;
    height: 34px;
    background: var(--white);
    border: 2px solid var(--border-gray);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 8px;
    font-weight: 600;
    font-size: 14px;
    color: var(--gray-text);
    transition: all 0.3s ease;
}

.progress-step.active .progress-step-number {
    background: var(--ep-green);
    border-color: var(--ep-green);
    color: var(--white);
    transform: scale(1.12);
    box-shadow: 0 0 0 5px rgba(26, 198, 104, 0.15);
}

.progress-step.completed .progress-step-number {
    background: var(--ep-teal);
    border-color: var(--ep-teal);
    color: var(--white);
    font-size: 0;
}

.progress-step.completed .progress-step-number::after {
    content: '\2713';
    font-size: 15px;
    font-weight: 700;
}

.progress-step-label {
    font-size: 12px;
    font-weight: 500;
    color: var(--gray-text);
}

.progress-step.active .progress-step-label {
    color: var(--ep-blue);
    font-weight: 600;
}

.progress-line {
    position: absolute;
    top: 17px;
    left: 0;
    right: 0;
    height: 3px;
    border-radius: 2px;
    background: var(--border-gray);
    z-index: 0;
}

.progress-line-fill {
    height: 100%;
    border-radius: 2px;
    background: linear-gradient(90deg, var(--ep-green), var(--ep-teal));
    transition: width 0.3s ease;
}

/* ===== Steps & forms ===== */
.form-section {
    display: none;
}

.form-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.form-group {
    margin-bottom: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-row-thirds {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 16px;
}

.form-row-address {
    display: grid;
    grid-template-columns: 3fr 2fr 1fr 1fr;
    gap: 16px;
}

@media (max-width: 600px) {
    .form-row, .form-row-thirds, .form-row-address {
        grid-template-columns: 1fr;
    }
}

label {
    display: block;
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
    color: var(--dark-text);
}

h4 .tooltip-wrapper {
    vertical-align: baseline;
}

.required::after {
    content: ' *';
    color: var(--error);
}

input, select, textarea {
    width: 100%;
    padding: 11px 14px;
    border: 1.5px solid var(--border-gray);
    border-radius: 8px;
    font-size: 15px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: var(--white);
    color: var(--dark-text);
    font-family: inherit;
}

input:hover:not(:focus):not([readonly]), select:hover:not(:focus), textarea:hover:not(:focus) {
    border-color: #D3DCE3;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--ep-teal);
    box-shadow: 0 0 0 3px rgba(27, 206, 172, 0.15);
}

input[readonly] {
    background: var(--light-gray);
    color: var(--gray-text);
}

input:disabled, select:disabled {
    background: var(--light-gray);
    color: var(--gray-text);
    cursor: not-allowed;
    opacity: 0.65;
}

.input-hint {
    font-size: 13px;
    color: var(--gray-text);
    margin-top: 6px;
    line-height: 1.4;
}

/* ===== Tooltips ===== */
.tooltip-wrapper {
    display: inline-block;
    position: relative;
    margin-left: 6px;
    vertical-align: middle;
}

.tooltip-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--gray-text);
    color: var(--white);
    font-size: 12px;
    font-weight: 600;
    cursor: help;
    transition: background 0.2s ease;
}

.tooltip-icon:hover {
    background: var(--ep-teal);
}

.tooltip-text {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--ep-blue);
    color: var(--white);
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.4;
    white-space: normal;
    width: 280px;
    z-index: 1000;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    box-shadow: 0 4px 12px rgba(31, 85, 119, 0.3);
}

.tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--ep-blue);
}

.tooltip-wrapper:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Tooltip in collapsible header should appear below */
.collapsible-header .tooltip-text {
    bottom: auto;
    top: 125%;
}

.collapsible-header .tooltip-text::after {
    top: auto;
    bottom: 100%;
    border-top-color: transparent;
    border-bottom-color: var(--ep-blue);
}

@media (max-width: 600px) {
    .tooltip-text {
        width: 220px;
        left: auto;
        right: 0;
        transform: none;
    }

    .tooltip-text::after {
        left: auto;
        right: 10px;
        transform: none;
    }
}

/* ===== Radio cards & checkboxes ===== */
.radio-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 12px;
}

.radio-card {
    position: relative;
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
}

.radio-card label {
    display: block;
    padding: 12px 16px;
    border: 2px solid var(--border-gray);
    border-radius: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 0;
    background: var(--white);
    font-size: 14px;
}

.radio-card input[type="radio"]:checked + label {
    border-color: var(--ep-green);
    background: var(--pale-green);
    color: var(--ep-blue);
    font-weight: 600;
}

.radio-card label:hover {
    border-color: var(--ep-teal);
    background: var(--mint);
}

.radio-card input[type="radio"]:focus-visible + label {
    box-shadow: 0 0 0 3px rgba(27, 206, 172, 0.25);
}

.checkbox-wrapper {
    margin-bottom: 16px;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    padding: 12px 14px;
    background: var(--light-gray);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s ease;
}

.checkbox-group:hover {
    background: var(--mint);
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
    accent-color: var(--ep-green);
}

.checkbox-group label {
    margin-bottom: 0;
    font-weight: 400;
    cursor: pointer;
    flex: 1;
    font-size: 14px;
    line-height: 1.5;
}

.use-same-checkbox {
    background: var(--mint);
    border: 2px solid var(--ep-teal);
}

.divider {
    height: 1px;
    background: var(--border-gray);
    margin: 32px 0;
}

/* ===== Buttons ===== */
.button-group {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    margin-top: 32px;
    padding-top: 24px;
    border-top: 1px solid var(--border-gray);
}

.btn {
    padding: 14px 32px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.2s ease;
    min-width: 120px;
    text-align: center;
}

.btn-primary {
    background: var(--ep-green);
    color: var(--white);
    flex: 1;
    box-shadow: 0 2px 8px rgba(26, 198, 104, 0.25);
}

.btn-primary:hover {
    background: var(--ep-green-hover);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(26, 198, 104, 0.35);
}

.btn-secondary {
    background: var(--white);
    color: var(--gray-text);
    border: 2px solid var(--border-gray);
}

.btn-secondary:hover {
    background: var(--light-gray);
    border-color: var(--ep-teal);
    color: var(--ep-blue);
}

.btn-add {
    background: var(--white);
    color: var(--ep-link);
    border: 2px dashed var(--ep-teal);
    padding: 12px 24px;
    margin-top: 16px;
}

.btn-add:hover {
    background: var(--mint);
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-full {
    width: 100%;
}

/* ===== Owner / store cards ===== */
.owner-card, .store-card {
    background: var(--light-gray);
    border: 1.5px solid var(--border-gray);
    border-radius: 12px;
    padding: 22px;
    margin-bottom: 16px;
    position: relative;
}

.owner-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.owner-card-title {
    font-weight: 600;
    font-size: 16px;
    color: var(--ep-blue);
}

.store-card > h4:first-child {
    margin-top: 0;
    color: var(--ep-blue);
}

.btn-remove {
    background: none;
    border: none;
    color: var(--error);
    cursor: pointer;
    padding: 4px 8px;
    font-size: 14px;
    font-family: inherit;
    text-decoration: underline;
}

.btn-remove:hover {
    color: #c82333;
}

.owner-select {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.owner-select-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border: 2px solid var(--border-gray);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: var(--white);
}

.owner-select-item:hover {
    border-color: var(--ep-teal);
    background: var(--mint);
}

.owner-select-item.selected {
    border-color: var(--ep-green);
    background: var(--pale-green);
}

.owner-select-item input[type="radio"] {
    width: 20px;
    height: 20px;
    margin: 0;
    padding: 0;
    flex-shrink: 0;
    accent-color: var(--ep-green);
    cursor: pointer;
}

.owner-select-item label {
    flex: 1;
    margin: 0;
    cursor: pointer;
}

.owner-name {
    font-weight: 600;
    color: var(--dark-text);
}

.owner-title {
    color: var(--gray-text);
    font-size: 14px;
}

/* ===== Success screen ===== */
.success-container {
    text-align: center;
    padding: 32px 16px;
}

.success-container h2::after {
    left: 50%;
    transform: translateX(-50%);
}

.success-icon {
    width: 84px;
    height: 84px;
    background: linear-gradient(135deg, var(--pale-green), var(--seafoam));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.success-icon svg {
    width: 40px;
    height: 40px;
    fill: var(--ep-green);
}

.success-title {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--ep-blue);
}

.success-message {
    color: var(--gray-text);
    margin-bottom: 32px;
    line-height: 1.6;
    font-size: 16px;
}

.contact-info {
    background: linear-gradient(135deg, var(--mint) 0%, var(--seafoam) 100%);
    border-radius: 12px;
    padding: 24px;
    margin-top: 32px;
}

.contact-info h4 {
    margin-top: 0;
    margin-bottom: 16px;
    color: var(--ep-blue);
}

.contact-info p {
    margin-bottom: 8px;
    color: var(--gray-text);
}

.contact-info a {
    color: var(--ep-link);
    text-decoration: none;
    font-weight: 600;
}

.contact-info a:hover {
    text-decoration: underline;
}

/* ===== Collapsible sections ===== */
.collapsible-section {
    border: 1.5px solid var(--border-gray);
    border-radius: 12px;
    margin-bottom: 20px;
    overflow: visible;
    transition: border-color 0.3s ease;
}

.collapsible-section.expanded {
    border-color: var(--ep-teal);
}

.collapsible-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--light-gray);
    border-radius: 10px;
    cursor: pointer;
    user-select: none;
    transition: background 0.2s ease;
}

.collapsible-header:hover {
    background: var(--mint);
}

.collapsible-section.expanded .collapsible-header {
    background: var(--mint);
    border-radius: 10px 10px 0 0;
    border-bottom: 1px solid var(--border-gray);
}

.collapsible-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--ep-blue);
    display: flex;
    align-items: center;
    gap: 8px;
}

.collapsible-title .tooltip-wrapper {
    margin-left: 0;
}

.completion-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-left: 12px;
}

.completion-badge.incomplete {
    background: var(--amber-bg);
    color: var(--amber-text);
}

.completion-badge.complete {
    background: var(--pale-green);
    color: #0E7C43;
}

.collapsible-arrow {
    width: 24px;
    height: 24px;
    transition: transform 0.3s ease;
    fill: var(--gray-text);
    flex-shrink: 0;
}

.collapsible-section.expanded .collapsible-arrow {
    transform: rotate(180deg);
    fill: var(--ep-teal);
}

.collapsible-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.collapsible-section.expanded .collapsible-content {
    max-height: 2000px;
    overflow: visible;
}

.collapsible-inner {
    padding: 24px 20px;
}

/* ===== Loading ===== */
.loading-spinner {
    display: none;
    text-align: center;
    padding: 60px 20px;
}

.loading-spinner.active {
    display: block;
}

.spinner {
    border: 4px solid var(--border-gray);
    border-top: 4px solid var(--ep-green);
    border-right: 4px solid var(--ep-teal);
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin: 0 auto 24px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ===== Welcome screen ===== */
.timer-indicator {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    padding: 16px;
    background: linear-gradient(135deg, #F8FAFE 0%, #E6F3FF 100%);
    border-radius: 10px;
}

.timer-icon {
    width: 48px;
    height: 48px;
    background: var(--white);
    border-radius: 50%;
    box-shadow: var(--shadow);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.timer-icon svg {
    width: 24px;
    height: 24px;
    fill: var(--ep-blue);
}

.timer-text {
    flex: 1;
    line-height: 1.5;
}

.timer-text span {
    font-weight: 700;
    color: var(--ep-blue);
}

.requirements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 24px;
    margin: 32px 0;
}

.requirement-item {
    text-align: center;
}

.requirement-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 12px;
    background: linear-gradient(135deg, var(--mint), var(--seafoam));
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.requirement-icon svg {
    width: 32px;
    height: 32px;
    fill: var(--ep-blue);
}

.requirement-text {
    font-size: 14px;
    color: var(--gray-text);
    line-height: 1.4;
}

@media (max-width: 768px) {
    .container {
        padding: 20px 16px 40px;
    }

    .card {
        padding: 24px 20px;
    }

    .requirements-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .site-header {
        padding: 14px 16px;
    }

    .site-logo {
        height: 38px;
    }

    .site-header-title {
        font-size: 11px;
    }
}

/* ===== Validation states ===== */
input.input-error,
select.input-error,
textarea.input-error {
    border-color: var(--error) !important;
    background: #fff8f8;
}

.radio-group.input-error,
.owner-select.input-error {
    outline: 1px solid var(--error);
    outline-offset: 4px;
    border-radius: 8px;
}

.field-error {
    color: var(--error);
    font-size: 13px;
    margin-top: 6px;
}

.field-hint {
    color: var(--gray-text);
    font-size: 13px;
    margin-top: 6px;
    line-height: 1.4;
}

.field-warn {
    color: #856404;
    background: #FFF3CD;
    border-left: 3px solid #FFC107;
    border-radius: 4px;
    padding: 8px 10px;
    font-size: 13px;
    font-weight: 500;
    margin-top: 8px;
    line-height: 1.4;
}

.form-banner-error {
    background: #fdecea;
    border-left: 4px solid var(--error);
    color: #a3262f;
    padding: 12px 16px;
    border-radius: 6px;
    margin-bottom: 20px;
    font-size: 14px;
    line-height: 1.5;
}

/* ===== Review & Sign ===== */
.review-group {
    margin-bottom: 20px;
}

.review-group h5 {
    color: var(--ep-blue);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-bottom: 8px;
    padding-bottom: 6px;
    border-bottom: 2px solid var(--seafoam);
}

.review-row {
    display: flex;
    font-size: 14px;
    padding: 3px 0;
}

.review-row .rk {
    color: var(--gray-text);
    width: 42%;
    padding-right: 12px;
}

.review-row .rv {
    color: var(--dark-text);
    width: 58%;
    font-weight: 500;
    word-break: break-word;
}

.review-edit {
    background: none;
    border: none;
    color: var(--ep-link);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
}

.agreement-box {
    max-height: 240px;
    overflow-y: auto;
    border: 1.5px solid var(--border-gray);
    border-radius: 10px;
    padding: 16px 18px;
    background: var(--light-gray);
    font-size: 13px;
    line-height: 1.6;
    color: #495057;
    margin-bottom: 20px;
}

.agreement-box h5 {
    color: var(--ep-blue);
    font-size: 14px;
    font-weight: 700;
    margin: 14px 0 4px;
}

.agreement-box h5:first-child {
    margin-top: 0;
}

.agreement-box .ack-list {
    margin: 8px 0 4px;
}

.agreement-box .ack-list p {
    margin: 0 0 8px;
    padding-left: 20px;
    text-indent: -20px;
}

.sig-pad-wrap {
    position: relative;
    border: 2px dashed #C7D4DD;
    border-radius: 10px;
    background: #fff;
    transition: border-color 0.2s ease;
}

.sig-pad-wrap.signed {
    border-style: solid;
    border-color: var(--ep-green);
}

canvas.sig-pad {
    width: 100%;
    height: 180px;
    display: block;
    border-radius: 10px;
    touch-action: none;
    cursor: crosshair;
}

.sig-placeholder {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--gray-text);
    font-size: 14px;
    pointer-events: none;
    text-align: center;
}

.sig-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 8px 0 4px;
}

.sig-hint {
    color: var(--gray-text);
    font-size: 13px;
}

.sig-clear {
    background: none;
    border: none;
    color: var(--ep-link);
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
}

/* localhost-only demo autofill button (hidden in production) */
#demoFillBtn {
    position: fixed;
    top: 12px;
    right: 12px;
    z-index: 9999;
    background: var(--charcoal);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 10px 14px;
    font-size: 13px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    box-shadow: var(--shadow-hover);
}

#demoFillBtn:hover {
    opacity: 0.9;
}

/* ===== Welcome split-hero screen ===== */
.welcome-card {
    padding: 0;
    overflow: hidden;
}

.welcome-split {
    display: grid;
    grid-template-columns: 11fr 13fr;
}

.welcome-hero {
    position: relative;
    overflow: hidden;
    background: linear-gradient(160deg, #1F5577 0%, #17415C 55%, #122F44 100%);
    color: var(--white);
    padding: 40px 32px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* Decorative concentric rings echoing the EasyPay "e" mark */
.welcome-hero::before,
.welcome-hero::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}

.welcome-hero::before {
    width: 340px;
    height: 340px;
    right: -140px;
    bottom: -140px;
    border: 44px solid rgba(27, 206, 172, 0.12);
}

.welcome-hero::after {
    width: 190px;
    height: 190px;
    right: -55px;
    bottom: -55px;
    border: 30px solid rgba(26, 198, 104, 0.16);
}

.hero-eyebrow {
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.6px;
    text-transform: uppercase;
    color: var(--ep-teal);
    margin-bottom: 12px;
}

.hero-title {
    font-size: 26px;
    font-weight: 800;
    line-height: 1.25;
    letter-spacing: -0.3px;
    margin-bottom: 12px;
}

.hero-sub {
    font-size: 14.5px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 24px;
}

.hero-points {
    list-style: none;
    position: relative;
    z-index: 1;
}

.hero-points li {
    position: relative;
    padding-left: 34px;
    margin: 13px 0;
    font-size: 14px;
    font-weight: 500;
}

.hero-points li::before {
    content: '\2713';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--ep-green), var(--ep-teal));
    color: var(--white);
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.welcome-body {
    padding: 34px 32px;
}

.welcome-body h3 {
    margin-bottom: 16px;
}

.need-heading {
    margin-top: 24px;
    margin-bottom: 12px;
}

.need-list {
    list-style: none;
    margin-bottom: 28px;
}

.need-list li {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 14px;
    color: var(--dark-text);
    padding: 7px 0;
}

.need-ico {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
    border-radius: 9px;
    background: linear-gradient(135deg, var(--mint), var(--seafoam));
    display: flex;
    align-items: center;
    justify-content: center;
}

.need-ico svg {
    width: 18px;
    height: 18px;
    fill: var(--ep-blue);
}

@media (max-width: 700px) {
    .welcome-split {
        grid-template-columns: 1fr;
    }

    .welcome-hero {
        padding: 30px 24px;
    }

    .hero-title {
        font-size: 22px;
    }

    .welcome-body {
        padding: 26px 20px;
    }
}

/* ===== Step slide transitions ===== */
.form-section.active.slide-forward {
    animation: slideForward 0.35s ease;
}

.form-section.active.slide-back {
    animation: slideBack 0.35s ease;
}

@keyframes slideForward {
    from {
        opacity: 0;
        transform: translateX(48px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes slideBack {
    from {
        opacity: 0;
        transform: translateX(-48px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .form-section.active,
    .form-section.active.slide-forward,
    .form-section.active.slide-back {
        animation: none;
    }
}

/* ===== DocuSign return (pre-JS): no welcome-screen flash ===== */
.ds-return #preApplication {
    display: none !important;
}

.ds-return #loadingScreen {
    display: block;
}

/* ===== Routing-number verification ===== */
.bank-status {
    font-size: 13px;
    font-weight: 500;
    margin-top: 6px;
    line-height: 1.4;
    display: none;
}

.bank-status.ok {
    display: block;
    color: #0E7C43;
}

.bank-status.bad {
    display: block;
    color: var(--error);
}

.bank-status .bank-name {
    font-weight: 700;
}

/* ===== Site footer ===== */
.site-footer {
    background: var(--ep-blue);
    color: #BDC3C7;
    padding: 28px 24px;
    margin-top: 24px;
}

.site-footer-inner {
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
    font-size: 13px;
    line-height: 1.7;
}

.footer-brand {
    color: var(--white);
    font-weight: 700;
    font-size: 15px;
    margin-bottom: 6px;
}

.site-footer a {
    color: var(--ep-teal);
    text-decoration: none;
    font-weight: 600;
}

.site-footer a:hover {
    text-decoration: underline;
}

.footer-legal {
    margin-top: 10px;
    font-size: 11.5px;
    opacity: 0.8;
}
