/*
 * Company search / "add your company" widget, shared by the register page
 * (step 2 and the step 3 summary) and the /join-request waiting page.
 * Rows are built by public/assets/js/company-search.js.
 */

.reg-co-title {
    margin: 22px 0 4px;
    color: var(--sg-navy);
    font-size: 21px;
    font-weight: 700;
}

.reg-co-sub {
    margin: 0 0 14px;
    color: #64748b;
    font-size: 14.5px;
}

.reg-co-search {
    position: relative;
}

.reg-co-search > i {
    position: absolute;
    top: 50%;
    left: 15px;
    color: #94a3b8;
    transform: translateY(-50%);
    pointer-events: none;
}

.reg-co-search input {
    width: 100%;
    height: 48px;
    padding: 0 14px 0 42px;
    border: 1px solid #C6C6C6;
    border-radius: 10px;
    font-size: 16px;
}

.reg-co-search input:focus {
    border-color: var(--sg-blue);
    box-shadow: 0 0 0 3px rgba(var(--sg-blue-rgb), 0.15);
    outline: none;
}

.reg-co-status {
    min-height: 20px;
    margin: 10px 2px 0;
    color: #64748b;
    font-size: 14px;
}

.reg-co-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 8px 0 0;
    padding: 0;
    list-style: none;
}

.reg-co-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.reg-co-item.is-picked {
    background: #f5f9ff;
    border-color: var(--sg-navy);
}

.reg-co-icon {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    background: #eef4fb;
    border-radius: 10px;
    color: var(--sg-blue);
}

.reg-co-text {
    flex: 1 1 0; /* shrink beside the icon; on a phone the button wraps below */
    min-width: 0;
}

.reg-co-name {
    display: block;
    color: var(--sg-navy);
    font-size: 15.5px;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.reg-co-addr {
    display: block;
    color: #64748b;
    font-size: 13.5px;
    overflow-wrap: anywhere;
}

.reg-co-addr.is-missing {
    color: #94a3b8;
    font-style: italic;
}

.reg-co-pick,
.reg-co-add-btn {
    flex: 0 0 auto;
    padding: 8px 14px;
    background: #fff;
    border: 1px solid var(--sg-blue);
    border-radius: 9px;
    color: var(--sg-blue);
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
}

.reg-co-pick:hover,
.reg-co-pick:focus-visible,
.reg-co-add-btn:hover,
.reg-co-add-btn:focus-visible {
    background: var(--sg-blue);
    color: #fff;
    outline: none;
}

.reg-co-add {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 14px;
    margin-top: 16px;
    padding: 14px;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
}

.reg-co-add p {
    margin: 0;
    color: #475569;
    font-size: 14.5px;
}

.reg-co-new {
    margin-top: 16px;
    padding: 16px 16px 2px;
    background: #fbfdff;
    border: 1px solid var(--sg-blue-100);
    border-radius: 12px;
}

.reg-co-new-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.reg-co-new-head h3 {
    margin: 0 0 2px;
    color: var(--sg-navy);
    font-size: 17px;
    font-weight: 700;
}

.reg-co-new-head p {
    margin: 0;
    color: #64748b;
    font-size: 13.5px;
}

.reg-co-new .label-text {
    font-size: 16px;
}

.reg-co-new select.form-left {
    padding-left: 40px;
}

.reg-link-btn {
    flex: 0 0 auto;
    padding: 0;
    background: none;
    border: 0;
    color: var(--sg-blue);
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
}

.reg-link-btn:hover,
.reg-link-btn:focus-visible {
    text-decoration: underline;
}

.reg-co-dup {
    margin: 0 0 14px;
    padding: 12px 14px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 10px;
    color: #713f12;
    font-size: 14px;
}

.reg-co-dup label {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    margin-top: 8px;
    font-weight: 600;
    cursor: pointer;
}

.reg-co-dup input {
    margin-top: 4px;
}

.reg-step-actions {
    margin-top: 18px;
}

/* Step 3: what will happen to their company. */
.reg-co-summary {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 10px;
    padding: 12px 14px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}

.reg-co-summary .reg-chosen-text {
    gap: 1px;
}

.reg-co-summary-name {
    color: var(--sg-navy);
    font-size: 16px;
    font-weight: 700;
    overflow-wrap: anywhere;
}

.reg-co-summary-addr {
    color: #64748b;
    font-size: 13.5px;
    overflow-wrap: anywhere;
}

.reg-co-summary-note {
    margin-top: 4px;
    color: #475569;
    font-size: 13.5px;
}

.reg-co-summary-note i {
    color: var(--sg-blue);
}

#companyModeError {
    display: block;
}

@media (max-width: 575.98px) {
    .reg-co-item {
        flex-wrap: wrap;
    }

    .reg-co-pick,
    .reg-co-item form {
        width: 100%;
    }
}
