.opportunity-page {
    padding: 34px 0 70px;
}

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

.opportunity-heading h1 {
    margin: 6px 0 8px;
    color: #102a43;
    font-size: clamp(22px, 2.1vw, 30px);
}

.opportunity-heading p {
    margin: 0;
    color: #62758a;
    font-size: 14px;
    line-height: 1.9;
}

.opportunity-filter-card,
.opportunity-form-card,
.opportunity-detail,
.opportunity-apply-card,
.opportunity-submit-card,
.opportunity-owner-card,
.opportunity-application-card,
.opportunity-history,
.opportunity-empty {
    border: 1px solid #dce6f1;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(18, 52, 86, .07);
}

.opportunity-filter-card,
.opportunity-form-card {
    padding: 22px;
    margin-bottom: 24px;
}

.opportunity-filter-grid,
.opportunity-form-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
}

.opportunity-form-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.opportunity-field {
    display: flex;
    flex-direction: column;
    gap: 7px;
    color: #273e55;
    font-size: 13px;
    font-weight: 800;
}

.opportunity-field--wide {
    grid-column: 1 / -1;
}

.opportunity-field span {
    display: inline-flex;
    align-items: baseline;
    gap: 6px;
}

.opportunity-field small {
    color: #7b8da0;
    font-weight: 500;
    line-height: 1.7;
}

.opportunity-field input,
.opportunity-field select,
.opportunity-field textarea {
    width: 100%;
    min-height: 44px;
    padding: 10px 12px;
    border: 1px solid #cbd9e8;
    border-radius: 11px;
    background: #fff;
    color: #17324d;
    font: inherit;
    font-weight: 500;
    outline: none;
}

.opportunity-field select[multiple] {
    min-height: 180px;
}

.opportunity-field textarea {
    resize: vertical;
    line-height: 1.9;
}

.opportunity-field input:focus,
.opportunity-field select:focus,
.opportunity-field textarea:focus {
    border-color: #2e6db2;
    box-shadow: 0 0 0 3px rgba(46, 109, 178, .1);
}

.opportunity-filter-actions,
.opportunity-form-actions,
.opportunity-owner-card__actions,
.opportunity-application-card__actions,
.opportunity-application-card__links {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}

.opportunity-result-meta {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin: 18px 0;
    color: #65798e;
}

.opportunity-result-meta strong {
    color: #163d67;
    font-size: 22px;
}

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

.opportunity-card {
    display: flex;
    min-height: 100%;
    flex-direction: column;
    gap: 14px;
    padding: 20px;
    border: 1px solid #dce6f1;
    border-radius: 17px;
    background: #fff;
    box-shadow: 0 10px 28px rgba(18, 52, 86, .06);
}

.opportunity-card__top,
.opportunity-detail__top,
.opportunity-owner-card__badges,
.opportunity-application-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.opportunity-badge,
.opportunity-status-pill {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    min-height: 30px;
    padding: 4px 10px;
    border-radius: 999px;
    background: #eaf3ff;
    color: #1d5b9e;
    font-size: 12px;
    font-weight: 900;
}

.opportunity-status-pill.is-muted {
    background: #eef1f5;
    color: #64778a;
}

.opportunity-card__date,
.opportunity-card__publisher,
.opportunity-card__meta,
.opportunity-owner-card__meta,
.opportunity-apply-card__meta {
    color: #718397;
    font-size: 12px;
    line-height: 1.8;
}

.opportunity-card__publisher span {
    display: block;
}

.opportunity-card__title {
    margin: 0;
    color: #173b62;
    font-size: 19px;
    line-height: 1.7;
}

.opportunity-card__title a {
    color: inherit;
}

.opportunity-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 7px 14px;
}

.opportunity-chip-row {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.opportunity-chip {
    display: inline-flex;
    align-items: center;
    min-height: 28px;
    padding: 4px 9px;
    border: 1px solid #d7e1ec;
    border-radius: 999px;
    background: #f8fafc;
    color: #4e6479;
    font-size: 11px;
    font-weight: 700;
}

.opportunity-chip.is-primary {
    border-color: #bad3ef;
    background: #edf5ff;
    color: #1e5f9f;
}

.opportunity-card__link {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 42px;
    margin-top: auto;
    border: 1px solid #2366aa;
    border-radius: 11px;
    color: #2366aa;
    font-weight: 900;
}

.opportunity-card__link:hover {
    background: #2366aa;
    color: #fff;
}

.opportunity-empty {
    padding: 50px 24px;
    text-align: center;
}

.opportunity-empty h2 {
    margin: 0 0 10px;
    color: #173b62;
}

.opportunity-empty p {
    margin: 0 0 18px;
    color: #718397;
}

.opportunity-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 22px;
    align-items: start;
}

.opportunity-detail,
.opportunity-apply-card {
    padding: 24px;
}

.opportunity-detail h1 {
    margin: 18px 0;
    color: #102f50;
    font-size: clamp(25px, 3vw, 34px);
    line-height: 1.6;
}

.opportunity-detail__publisher {
    padding: 14px 16px;
    border-radius: 12px;
    background: #f6f9fc;
    color: #465f77;
    line-height: 2;
}

.opportunity-detail__publisher small {
    display: block;
    color: #8a5a18;
}

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

.opportunity-detail__facts > div {
    padding: 13px;
    border: 1px solid #e1e8f0;
    border-radius: 12px;
    background: #fbfcfe;
}

.opportunity-detail__facts span,
.opportunity-detail__facts strong {
    display: block;
}

.opportunity-detail__facts span {
    margin-bottom: 4px;
    color: #7a8b9e;
    font-size: 11px;
}

.opportunity-detail__facts strong {
    color: #253f59;
    font-size: 13px;
}

.opportunity-detail__section {
    margin-top: 26px;
}

.opportunity-detail__section h2,
.opportunity-apply-card h2,
.opportunity-history h2 {
    margin: 0 0 12px;
    color: #173b62;
    font-size: 18px;
}

.opportunity-prose {
    color: #40576d;
    line-height: 2.05;
    overflow-wrap: anywhere;
}

.opportunity-apply-card {
    position: sticky;
    top: 90px;
}

.opportunity-apply-card p {
    color: #61768a;
    line-height: 1.9;
}

.opportunity-full-button {
    width: 100%;
    margin-top: 12px;
}

.opportunity-apply-card__meta {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 18px;
    padding-top: 14px;
    border-top: 1px solid #e5ebf2;
}

.opportunity-alert {
    padding: 13px 16px;
    margin-bottom: 18px;
    border-radius: 12px;
    line-height: 1.9;
}

.opportunity-alert.is-success {
    border: 1px solid #b7dfc7;
    background: #effaf3;
    color: #216a3f;
}

.opportunity-alert.is-error {
    border: 1px solid #efc0c0;
    background: #fff3f3;
    color: #9c3131;
}

.opportunity-alert.is-warning {
    border: 1px solid #f1d5a7;
    background: #fff8eb;
    color: #8b5a15;
}

.opportunity-form-shell {
    max-width: 1080px;
}

.opportunity-submit-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    padding: 20px 22px;
}

.opportunity-submit-card p {
    margin: 5px 0 0;
    color: #6d8093;
}

.opportunity-owner-list,
.opportunity-application-list {
    display: grid;
    gap: 14px;
}

.opportunity-owner-card,
.opportunity-application-card {
    padding: 20px;
}

.opportunity-owner-card {
    display: flex;
    justify-content: space-between;
    gap: 22px;
}

.opportunity-owner-card h2,
.opportunity-application-card h2 {
    margin: 9px 0 6px;
    color: #193e64;
    font-size: 18px;
}

.opportunity-owner-card__meta {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 16px;
}

.opportunity-owner-card__feedback {
    margin-top: 12px;
    padding: 10px 12px;
    border-radius: 10px;
    background: #fff8eb;
    color: #785017;
    line-height: 1.8;
}

.opportunity-owner-card__actions {
    justify-content: flex-end;
    min-width: 250px;
    margin-top: 0;
}

.opportunity-application-card__header {
    align-items: flex-start;
    margin-bottom: 14px;
}

.opportunity-application-card__header p {
    margin: 0;
    color: #718397;
}

.opportunity-admin-stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
    margin-bottom: 18px;
}

.opportunity-admin-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px;
    border: 1px solid #dce6f1;
    border-radius: 12px;
    background: #fff;
    color: #455e76;
}

.opportunity-admin-stat strong {
    color: #1d5b9e;
    font-size: 20px;
}

.opportunity-admin-table-wrap {
    overflow-x: auto;
    border: 1px solid #dce6f1;
    border-radius: 16px;
    background: #fff;
}

.opportunity-admin-table {
    width: 100%;
    border-collapse: collapse;
    min-width: 920px;
}

.opportunity-admin-table th,
.opportunity-admin-table td {
    padding: 13px 14px;
    border-bottom: 1px solid #e7edf4;
    text-align: right;
    vertical-align: middle;
}

.opportunity-admin-table th {
    background: #f6f9fc;
    color: #49637c;
    font-size: 12px;
}

.opportunity-admin-table td {
    color: #304a62;
    font-size: 13px;
}

.opportunity-admin-table td small {
    display: block;
    margin-top: 4px;
    color: #8292a3;
}

.opportunity-admin-decision {
    display: grid;
    gap: 10px;
}

.opportunity-history {
    margin-top: 22px;
    padding: 22px;
}

.opportunity-history__item {
    padding: 12px 0;
    border-bottom: 1px solid #e7edf4;
    color: #526a81;
}

.opportunity-history__item:last-child {
    border-bottom: 0;
}

.opportunity-history__item strong,
.opportunity-history__item span,
.opportunity-history__item small {
    display: block;
}

.opportunity-history__item p {
    margin: 6px 0;
    line-height: 1.8;
}

.opportunity-pagination {
    margin-top: 24px;
}

.expert-search-empty__opportunity {
    margin-top: 18px;
}

.home-opportunity-section {
    margin-top: 0;
}

@media (max-width: 1050px) {
    .opportunity-grid,
    .opportunity-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .opportunity-admin-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 820px) {
    .opportunity-heading,
    .opportunity-owner-card,
    .opportunity-submit-card,
    .opportunity-application-card__header {
        align-items: stretch;
        flex-direction: column;
    }

    .opportunity-detail-layout {
        grid-template-columns: 1fr;
    }

    .opportunity-apply-card {
        position: static;
    }

    .opportunity-detail__facts,
    .opportunity-form-grid {
        grid-template-columns: 1fr;
    }

    .opportunity-owner-card__actions {
        justify-content: flex-start;
        min-width: 0;
    }
}

@media (max-width: 640px) {
    .opportunity-page {
        padding-top: 22px;
    }

    .opportunity-grid,
    .opportunity-filter-grid,
    .opportunity-admin-stats {
        grid-template-columns: 1fr;
    }

    .opportunity-filter-card,
    .opportunity-form-card,
    .opportunity-detail,
    .opportunity-apply-card,
    .opportunity-owner-card,
    .opportunity-application-card {
        padding: 16px;
    }
}

.opportunity-pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 24px;
}

.opportunity-page-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 40px;
    padding: 8px 14px;
    border: 1px solid #d3dfeb;
    border-radius: 10px;
    background: #fff;
    color: #244c73;
    font-size: 13px;
    font-weight: 800;
}

.opportunity-page-link.is-current {
    background: #f6f9fc;
}

.opportunity-page-link.is-disabled {
    color: #9aa8b7;
    background: #eef1f5;
}

/* EX-060 taxonomy/date alignment */
.opportunity-heading--boxed {
    align-items: center;
    padding: 24px 26px;
    border: 1px solid #dce6f1;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 34px rgba(18, 52, 86, .07);
}

.opportunity-expertise-picker {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr)) auto;
    gap: 12px;
    align-items: end;
    margin-top: 4px;
}

.opportunity-expertise-picker__action {
    display: flex;
    align-items: end;
    min-height: 44px;
}

.opportunity-expertise-picker__action .btn {
    min-height: 44px;
    white-space: nowrap;
}

.opportunity-selected-expertise {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    min-height: 12px;
    margin-top: 12px;
}

.opportunity-selected-expertise__item {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-height: 34px;
    padding: 5px 10px;
    border: 1px solid #bad3ef;
    border-radius: 999px;
    background: #edf5ff;
    color: #1e5f9f;
    font-size: 12px;
    font-weight: 800;
}

.opportunity-selected-expertise__item button {
    width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: #6b7f93;
    font: inherit;
    font-size: 16px;
    line-height: 1;
    cursor: pointer;
}

@media (max-width: 900px) {
    .opportunity-expertise-picker {
        grid-template-columns: 1fr;
    }

    .opportunity-expertise-picker__action .btn {
        width: 100%;
    }
}


/* EX-060 related company autocomplete */
.opportunity-company-autocomplete {
    position: relative;
}

.opportunity-company-suggestions {
    position: absolute;
    z-index: 40;
    top: calc(100% + 6px);
    right: 0;
    left: 0;
    max-height: 280px;
    overflow-y: auto;
    padding: 6px;
    border: 1px solid #cbd9e8;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 16px 36px rgba(18, 52, 86, .16);
}

.opportunity-company-suggestions__item {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding: 10px 12px;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: #17324d;
    text-align: right;
    cursor: pointer;
}

.opportunity-company-suggestions__item:hover,
.opportunity-company-suggestions__item:focus {
    background: #edf5ff;
    outline: none;
}

.opportunity-company-suggestions__item strong {
    font-size: 13px;
}

.opportunity-company-suggestions__item small,
.opportunity-company-suggestions__empty {
    color: #718397;
    font-size: 11px;
    font-weight: 500;
}

.opportunity-company-suggestions__empty {
    padding: 10px 12px;
}

.opportunity-heading--boxed {
    margin-bottom: 24px;
}


/* EX-060 page toolbar alignment with /experts v1 */
.opportunity-heading.experts-page-toolbar {
    align-items: center;
    gap: 18px;
    min-height: 78px;
    margin-bottom: 16px !important;
    padding: 13px 18px;
    border: 1px solid #dce4ed;
    border-radius: 13px;
    background: rgba(255, 255, 255, .97);
    box-shadow: 0 4px 16px rgba(20, 43, 72, .055);
}

.opportunity-heading.experts-page-toolbar .section-eyebrow--block {
    margin-bottom: 2px !important;
    color: #ff8c42;
    font-size: 11px !important;
    font-weight: 900;
    line-height: 1.5 !important;
}

@media (max-width: 700px) {
    .opportunity-heading.experts-page-toolbar {
        align-items: flex-start;
        gap: 9px;
    }
}
