/* Shared workspace, wizard and dialog styles. */
:root   {
    --cf-ink:#17243b;
    --cf-muted:#64748b;
    --cf-border:#e2e8f0;
    --cf-accent:#285bd4;
}

.creation-shell,.directory-shell   {
    max-width:1040px;
    margin:30px auto 70px;
    color:var(--cf-ink);
}

.muted   {
    color:var(--cf-muted);
}

.creation-shell h1,.directory-shell h1   {
    font-size:clamp(1.8rem,3vw,2.3rem);
    font-weight:700;
    letter-spacing:-.035em;
}

.wizard-heading   {
    margin:40px 0 30px;
}

.wizard-heading .eyebrow   {
    color:var(--cf-accent);
    font-size:.75rem;
    font-weight:700;
    text-transform:uppercase;
    letter-spacing:.12em;
}

.wizard-heading>p:last-child   {
    max-width:690px;
    line-height:1.65;
}

.wizard-steps   {
    display:flex;
    list-style:none;
    padding:0 0 24px;
    margin:0;
    border-bottom:1px solid var(--cf-border);
    gap:22px;
}

.wizard-steps li   {
    flex:1;
    display:flex;
    align-items:center;
    gap:10px;
    color:#64748b;
    font-size:.9rem;
}

.step-number   {
    display:grid;
    place-items:center;
    width:30px;
    height:30px;
    border:1px solid #cbd5e1;
    border-radius:50%;
    flex-shrink:0;
    font-size:.8rem;
}

.wizard-steps .current   {
    color:var(--cf-accent);
    font-weight:650;
}

.current .step-number   {
    background:var(--cf-accent);
    color:white;
    border-color:var(--cf-accent);
}

.complete .step-number   {
    color:#16734a;
    background:#e9f7f0;
    border-color:#c9e8d8;
}

.company-types   {
    display:grid;
    grid-template-columns:repeat(3,1fr);
    gap:20px;
}

.company-type   {
    display:flex;
    flex-direction:column;
    text-align:left;
    padding:28px;
    min-height:250px;
    border:1px solid var(--cf-border);
    border-radius:16px;
    background:white;
    color:var(--cf-ink);
    gap:12px;
}

.company-type strong   {
    font-size:2rem;
    letter-spacing:-.04em;
}

.company-type .type-badge   {
    align-self:flex-start;
    font-size:.72rem;
    border-radius:20px;
    padding:4px 9px;
    background:#eef4ff;
    color:#285bd4;
    font-weight:650;
}

.company-type .type-action   {
    margin-top:auto;
    color:var(--cf-accent);
    font-weight:600;
    font-size:.9rem;
}

.active-type   {
    border:2px solid var(--cf-accent);
    box-shadow:0 6px 24px #285bd40c;
}

.active-type:hover   {
    background:#f7faff;
    transform:translateY(-2px);
}

.company-type:disabled   {
    background:#f7f8fa;
    color:#7e8795;
    cursor:not-allowed;
}

.company-type:disabled .type-badge   {
    color:#677489;
    background:#e9edf2;
}

.wizard-panel   {
    background:white;
    border:1px solid var(--cf-border);
    border-radius:16px;
    padding:30px;
    box-shadow:0 3px 12px #17243b03;
}

.field-label,.form-field label   {
    display:block;
    font-weight:600;
    font-size:.9rem;
    margin-bottom:8px;
}

.name-panel   {
    max-width:780px;
}

.name-input-wrap   {
    position:relative;
}

.name-input-wrap input   {
    padding:16px 76px 16px 16px;
    font-size:1.1rem;
}

.name-suffix   {
    position:absolute;
    right:18px;
    top:17px;
    color:var(--cf-muted);
}

.name-feedback   {
    min-height:48px;
    padding:12px 0;
    font-size:.9rem;
}

.name-feedback b   {
    margin-right:6px;
}

.name-available   {
    color:#147547;
}

.name-unavailable   {
    color:#b42335;
}

.name-preview   {
    display:flex;
    flex-direction:column;
    gap:8px;
    padding:20px;
    border-radius:10px;
    background:#f5f8fc;
    margin-top:16px;
    overflow-wrap:anywhere;
}

.name-preview>span   {
    font-size:.78rem;
    color:var(--cf-muted);
}

.name-preview strong   {
    font-size:1.3rem;
}

.registry-notice   {
    margin:16px 0 0;
}

.step-navigation   {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:20px;
    padding-top:28px;
    margin-top:12px;
    border-top:1px solid var(--cf-border);
}

.back-button   {
    border:0;
    background:transparent;
    color:var(--cf-muted);
    padding:12px 0;
    text-align:left;
    font-size:.9rem;
}

.back-button:hover   {
    color:var(--cf-ink);
}

.next-button   {
    padding:12px 22px;
    border-radius:9px;
}

.next-button span   {
    margin-left:14px;
}

.section-heading,.directory-heading-new   {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:24px;
}

.directory-heading-new   {
    margin-bottom:30px;
    align-items:flex-start;
}

.section-heading h2   {
    font-size:1.15rem;
    margin:0 0 6px;
    overflow-wrap:anywhere;
}

.section-heading p   {
    margin:0;
    font-size:.85rem;
}

.member-list   {
    padding:0;
    list-style:none;
    margin:24px 0 0;
}

.member-list li   {
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:15px;
    border-top:1px solid var(--cf-border);
    padding:18px 0;
}

.member-list li:last-child   {
    padding-bottom:0;
}

.member-summary   {
    border:0;
    background:none;
    padding:0;
    display:flex;
    text-align:left;
    align-items:center;
    gap:14px;
    min-width:0;
}

.member-summary strong   {
    display:block;
    overflow-wrap:anywhere;
}

.member-summary small   {
    display:block;
    margin-top:3px;
    color:var(--cf-muted);
}

.member-avatar   {
    display:grid;
    place-items:center;
    width:44px;
    height:44px;
    flex-shrink:0;
    background:#eef3fc;
    color:#496286;
    border-radius:12px;
    font-size:.75rem;
    font-weight:700;
}

.wizard-empty   {
    padding:50px 20px;
    text-align:center;
    color:var(--cf-muted);
}

.wizard-empty h3,.wizard-empty h2   {
    font-size:1.05rem;
    color:var(--cf-ink);
}

.wizard-empty p   {
    font-size:.9rem;
}

.empty-symbol   {
    display:block;
    font-size:2rem;
    color:#8b9bb2;
    margin-bottom:14px;
}

.member-requirement   {
    margin-top:16px;
}

.cf-dialog   {
    border:1px solid var(--cf-border);
    border-radius:18px;
    padding:28px;
    width:min(620px,calc(100vw - 32px));
    max-height:calc(100dvh - 40px);
    color:var(--cf-ink);
    box-shadow:0 25px 100px #10233d30;
}

.cf-dialog::backdrop   {
    background:#0c1b38a0;
    backdrop-filter:blur(3px);
}

.dialog-heading   {
    display:flex;
    justify-content:space-between;
    align-items:center;
    margin-bottom:24px;
    gap:15px;
}

.dialog-heading h2   {
    font-size:1.3rem;
    font-weight:700;
    margin:0;
}

.icon-button   {
    background:#f0f3f8;
    border:0;
    border-radius:8px;
    width:32px;
    height:32px;
    font-size:1.4rem;
    color:var(--cf-muted);
    flex-shrink:0;
}

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

.form-field .form-control,.form-field .form-select   {
    min-height:44px;
    border-radius:8px;
}

.field-grid   {
    display:grid;
    grid-template-columns:1fr 1fr;
    gap:18px;
}

.dialog-actions   {
    display:flex;
    justify-content:flex-end;
    gap:12px;
    padding-top:20px;
    margin-top:20px;
    border-top:1px solid var(--cf-border);
}

.capital-placeholder   {
    text-align:center;
    padding:56px 30px;
}

.capital-placeholder h2   {
    font-size:1.3rem;
    margin:20px 0 12px;
}

.capital-icon   {
    display:inline-grid;
    place-items:center;
    width:64px;
    height:64px;
    background:#eef3fc;
    color:var(--cf-accent);
    border-radius:18px;
    font-size:1.5rem;
    font-weight:700;
}

.capital-summary   {
    display:flex;
    flex-direction:column;
    gap:6px;
    padding-top:24px;
    margin-top:28px;
    border-top:1px solid var(--cf-border);
}

.capital-summary span   {
    color:var(--cf-muted);
    font-size:.9rem;
}

.directory-list   {
    padding:12px 24px;
}

.directory-list table   {
    margin:0;
}

.directory-list th   {
    color:var(--cf-muted);
    font-size:.8rem;
    font-weight:500;
    padding:18px 12px;
}

.directory-list td   {
    padding:20px 12px;
}

.directory-list tr:last-child td   {
    border-bottom:0;
}

.company-name-link   {
    border:0;
    background:transparent;
    padding:0;
    color:var(--cf-ink);
    font-weight:600;
    text-align:left;
}

.company-name-link:hover   {
    color:var(--cf-accent);
}

.status-pill   {
    display:inline-block;
    padding:4px 9px;
    border-radius:20px;
    color:#596981;
    background:#f1f4f9;
    font-size:.75rem;
    white-space:nowrap;
}

.company-details dt   {
    color:var(--cf-muted);
    font-size:.8rem;
    font-weight:500;
}

.company-details dd   {
    margin:5px 0 20px;
}

.nav-add   {
    width:2rem;
    font-size:1.5rem;
}

@media(max-width:700px)   {
    .creation-shell,.directory-shell   {
        margin-top:16px;
    }

    .wizard-steps   {
        gap:8px;
    }

    .wizard-steps li   {
        flex-direction:column;
        text-align:center;
        gap:7px;
        font-size:.7rem;
    }

    .company-types   {
        grid-template-columns:1fr;
        gap:12px;
    }

    .company-type   {
        min-height:165px;
        padding:22px;
    }

    .company-type:disabled   {
        min-height:130px;
    }

    .wizard-panel   {
        padding:22px;
    }

    .section-heading   {
        align-items:flex-start;
        flex-direction:column;
    }

    .step-navigation   {
        flex-direction:column-reverse;
        align-items:stretch;
    }

    .next-button   {
        width:100%;
    }

    .field-grid   {
        grid-template-columns:1fr;
        gap:0;
    }

    .cf-dialog   {
        padding:22px;
    }

    .directory-list   {
        padding:6px 12px;
    }

}

.capital-member, .capital-totals   {
    margin-top: 20px;
}

.capital-member h2, .capital-totals h2   {
    font-size: 1.15rem;
    margin-bottom: 24px;
}

.capital-tools   {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.share-grid   {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.share-grid small   {
    display: block;
    margin-top: 8px;
    color: #285bd4;
    font-weight: 600;
}

.share-grid input[readonly]   {
    background: #f5f8fc;
}

.share-grid dt   {
    font-size: .8rem;
    color: #64748b;
    font-weight: 500;
}

.share-grid dd   {
    font-weight: 700;
    font-size: 1.2rem;
    margin-top: 8px;
}

@media (max-width: 800px)   {
    .share-grid   {
        grid-template-columns: 1fr;
        gap: 4px;
    }

}

.location-card {
    display: flex;
    flex-direction: column;
    gap: .4rem;
    width: 100%;
    padding: 1.25rem;
    text-align: left;
    background: #f8fafc;
    border: 1px solid #dbe4ef;
    border-radius: 12px;
    color: #1c2d4a;
}

.location-card:hover, .review-section:hover {
    border-color: #316bdb;
    background: #f4f8ff;
}

.location-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 1rem;
}

.review-scroll {
    max-height: 68vh;
    overflow-y: auto;
    padding: .25rem .75rem .25rem .25rem;
    scrollbar-gutter: stable;
}

.review-section {
    display: flex;
    flex-direction: column;
    gap: .65rem;
    width: 100%;
    margin-bottom: 1rem;
    padding: 1.5rem;
    border: 1px solid #dbe4ef;
    border-radius: 14px;
    background: white;
    color: #1c2d4a;
    text-align: left;
    overflow-wrap: anywhere;
}

.review-heading {
    display: flex;
    justify-content: space-between;
    font-size: 1.15rem;
    font-weight: 700;
}

.review-item {
    display: flex;
    flex-direction: column;
    gap: .35rem;
    border-top: 1px solid #e7edf5;
    padding-top: 1rem;
    margin-top: .4rem;
}

.confirmation-warning {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    padding: 1rem;
    margin-bottom: 1.5rem;
    background: #fff7ed;
    border-radius: 12px;
    color: #864619;
}

.confirmation-symbol {
    display: grid;
    place-items: center;
    flex: 0 0 2rem;
    height: 2rem;
    border: 2px solid currentColor;
    border-radius: 50%;
    font-weight: 800;
}

@media (max-width: 640px) {
    .location-row { flex-direction: column; align-items: stretch; }
    .review-section { padding: 1rem; }
}
