/* ==========================================================================
   Colosian Markets — Research
   Private intelligence / research terminal
   ========================================================================== */

.research-page {
    --research-border: rgba(255, 255, 255, 0.075);
    --research-border-strong: rgba(255, 255, 255, 0.12);

    --research-surface: rgba(17, 19, 21, 0.86);
    --research-surface-raised: rgba(23, 25, 28, 0.94);
    --research-surface-soft: rgba(255, 255, 255, 0.025);

    --research-text: rgba(255, 255, 255, 0.94);
    --research-text-secondary: rgba(255, 255, 255, 0.62);
    --research-text-muted: rgba(255, 255, 255, 0.38);

    --research-positive: #20c997;
    --research-negative: #ff6b6b;

    width: 100%;
    min-width: 0;
    min-height: 100%;

    color: var(--research-text);
}


/* ==========================================================================
   Page header
   ========================================================================== */

.research-page__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 28px;

    margin-bottom: 18px;
    padding: 2px 2px 16px;

    border-bottom: 1px solid var(--research-border);
}

.research-page__eyebrow {
    margin-bottom: 7px;

    color: var(--research-text-muted);

    font-size: 10px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.research-page__title-row {
    display: flex;
    align-items: center;
    gap: 12px;
}

.research-page__title {
    margin: 0;

    color: var(--research-text);

    font-size: clamp(26px, 2.4vw, 38px);
    font-weight: 620;
    line-height: 1;
    letter-spacing: -0.035em;
}

.research-page__status {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 23px;
    padding: 0 8px;

    border: 1px solid rgba(32, 201, 151, 0.22);
    border-radius: 4px;

    background: rgba(32, 201, 151, 0.07);
    color: rgba(93, 222, 181, 0.92);

    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.12em;
}

.research-page__header-metrics {
    display: flex;
    align-items: stretch;

    border: 1px solid var(--research-border);
    border-radius: 7px;

    overflow: hidden;

    background: rgba(255, 255, 255, 0.015);
}

.research-page__metric {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;

    min-width: 86px;
    padding: 9px 13px;
}

.research-page__metric+.research-page__metric {
    border-left: 1px solid var(--research-border);
}

.research-page__metric span {
    color: var(--research-text-muted);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.14em;
}

.research-page__metric strong {
    color: var(--research-text);

    font-size: 15px;
    font-weight: 650;
    line-height: 1;
}


/* ==========================================================================
   Main workspace
   ========================================================================== */

.research-page__workspace {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 14px;

    width: 100%;
    min-width: 0;
}

.research-page--drawer-open .research-page__workspace {
    grid-template-columns:
        minmax(0, 1fr) minmax(390px, 31vw);
}

.research-page__main {
    min-width: 0;
}


/* ==========================================================================
   Research library
   ========================================================================== */

.research-library {
    min-width: 0;

    border: 1px solid var(--research-border);
    border-radius: 8px;

    background:
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.018),
            rgba(255, 255, 255, 0.006)),
        var(--research-surface);

    overflow: hidden;
}

.research-library__toolbar {
    display: grid;
    grid-template-columns:
        minmax(240px, 460px) minmax(0, 1fr);
    align-items: center;
    gap: 12px;

    min-height: 58px;
    padding: 10px 12px;

    border-bottom: 1px solid var(--research-border);
}

.research-library__toolbar-right {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;

    min-width: 0;
}

.research-library__count {
    flex: 0 0 auto;

    color: var(--research-text-muted);

    font-size: 9px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.09em;
    white-space: nowrap;
}

.research-library__count span {
    color: var(--research-text-secondary);
}

.research-library__workspace {
    width: 100%;
    min-width: 0;
    min-height: 0;
}


/* ==========================================================================
   Search
   ========================================================================== */

.research-search {
    display: flex;
    align-items: center;

    min-width: 0;
    height: 36px;

    border: 1px solid var(--research-border);
    border-radius: 5px;

    background: rgba(0, 0, 0, 0.18);

    transition:
        border-color 150ms ease,
        background 150ms ease;
}

.research-search:focus-within {
    border-color: rgba(255, 255, 255, 0.18);
    background: rgba(0, 0, 0, 0.28);
}

.research-search__icon {
    flex: 0 0 auto;

    padding-left: 11px;

    color: var(--research-text-muted);

    font-size: 17px;
    line-height: 1;
}

.research-search__input {
    width: 100%;
    min-width: 0;
    height: 100%;

    padding: 0 11px;

    border: 0;
    outline: 0;

    background: transparent;
    color: var(--research-text);

    font: inherit;
    font-size: 12px;
}

.research-search__input::placeholder {
    color: rgba(255, 255, 255, 0.28);
}


/* ==========================================================================
   Board / List switch
   ========================================================================== */

.research-view-switch {
    display: inline-flex;
    align-items: center;

    flex: 0 0 auto;

    min-height: 34px;
    padding: 3px;

    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 5px;

    background: rgba(0, 0, 0, 0.18);
}

.research-view-switch__button {
    appearance: none;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 60px;
    min-height: 26px;
    padding: 0 10px;

    border: 0;
    border-radius: 3px;

    background: transparent;
    color: rgba(255, 255, 255, 0.36);

    cursor: pointer;

    font: inherit;
    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.11em;
    text-transform: uppercase;

    transition:
        background 140ms ease,
        color 140ms ease;
}

.research-view-switch__button:hover {
    color: rgba(255, 255, 255, 0.72);
}

.research-view-switch__button.is-active {
    background: rgba(255, 255, 255, 0.075);
    color: rgba(255, 255, 255, 0.94);
}


/* ==========================================================================
   Category navigation
   ========================================================================== */

.research-category-strip {
    display: flex;
    align-items: center;
    gap: 3px;

    min-width: 0;
    padding: 7px 9px;

    border-bottom: 1px solid var(--research-border);

    overflow-x: auto;
    scrollbar-width: none;

    background: rgba(0, 0, 0, 0.08);
}

.research-category-strip::-webkit-scrollbar {
    display: none;
}

.research-category-tab {
    appearance: none;

    flex: 0 0 auto;

    min-height: 28px;
    padding: 0 10px;

    border: 1px solid transparent;
    border-radius: 4px;

    background: transparent;
    color: var(--research-text-muted);

    cursor: pointer;

    font: inherit;
    font-size: 9px;
    font-weight: 750;
    line-height: 1;
    letter-spacing: 0.075em;
    text-transform: uppercase;

    transition:
        color 140ms ease,
        background 140ms ease,
        border-color 140ms ease;
}

.research-category-tab:hover {
    color: var(--research-text-secondary);
    background: rgba(255, 255, 255, 0.025);
}

.research-category-tab.is-active {
    border-color: rgba(255, 255, 255, 0.09);

    background: rgba(255, 255, 255, 0.055);
    color: rgba(255, 255, 255, 0.9);
}


/* ==========================================================================
   Research board
   ========================================================================== */

.research-board {
    display: grid;
    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    align-items: stretch;

    width: 100%;
    min-width: 0;

    background: rgba(255, 255, 255, 0.045);
}


/* ==========================================================================
   Board lane
   ========================================================================== */

.research-board-lane {
    min-width: 0;
    min-height: 260px;

    border-right: 1px solid rgba(255, 255, 255, 0.055);
    border-bottom: 1px solid rgba(255, 255, 255, 0.055);

    background:
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.012),
            transparent 130px),
        rgba(14, 16, 18, 0.98);
}

.research-board-lane:nth-child(4n) {
    border-right: 0;
}

.research-board-lane__header {
    display: flex;
    align-items: center;
    justify-content: space-between;

    gap: 10px;

    min-height: 42px;
    padding: 0 12px;

    border-bottom: 1px solid rgba(255, 255, 255, 0.065);

    background:
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.025),
            rgba(255, 255, 255, 0.008)),
        rgba(17, 19, 21, 0.98);
}

.research-board-lane__identity {
    display: flex;
    align-items: center;
    gap: 8px;

    min-width: 0;
}

.research-board-lane__indicator {
    display: block;

    flex: 0 0 auto;

    width: 3px;
    height: 13px;

    border-radius: 999px;

    background: rgba(255, 255, 255, 0.26);
}

.research-board-lane__title {
    overflow: hidden;

    color: rgba(255, 255, 255, 0.68);

    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.12em;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.research-board-lane__count {
    flex: 0 0 auto;

    color: rgba(255, 255, 255, 0.28);

    font-size: 9px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.08em;
}


/* ==========================================================================
   Board category indicators
   ========================================================================== */

.research-board-lane__indicator[data-category="competitors"] {
    background: rgba(255, 107, 107, 0.88);
}

.research-board-lane__indicator[data-category="sector"] {
    background: rgba(255, 255, 255, 0.4);
}

.research-board-lane__indicator[data-category="companies"] {
    background: rgba(77, 171, 247, 0.88);
}

.research-board-lane__indicator[data-category="platforms"] {
    background: rgba(99, 202, 181, 0.88);
}

.research-board-lane__indicator[data-category="deals"] {
    background: rgba(32, 201, 151, 0.92);
}

.research-board-lane__indicator[data-category="finance"] {
    background: rgba(77, 171, 247, 0.92);
}

.research-board-lane__indicator[data-category="regulation"] {
    background: rgba(240, 180, 41, 0.9);
}

.research-board-lane__indicator[data-category="technology"] {
    background: rgba(91, 177, 210, 0.9);
}

.research-board-lane__indicator[data-category="useful"] {
    background: rgba(255, 255, 255, 0.3);
}


/* ==========================================================================
   Board lane records
   ========================================================================== */

.research-board-lane__records {
    display: flex;
    flex-direction: column;

    min-width: 0;
}


/* ==========================================================================
   Board research record
   ========================================================================== */

.research-board-card {
    appearance: none;

    position: relative;

    display: flex;
    flex-direction: column;

    width: 100%;
    min-width: 0;

    padding: 13px 12px;

    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);

    background: transparent;
    color: inherit;

    cursor: pointer;
    text-align: left;

    font: inherit;

    transition:
        background 130ms ease,
        box-shadow 130ms ease;
}

.research-board-card::before {
    content: "";

    position: absolute;
    inset: 0 auto 0 0;

    width: 2px;

    background: transparent;

    transition:
        background 130ms ease;
}

.research-board-card:hover {
    background:
        linear-gradient(90deg,
            rgba(255, 255, 255, 0.032),
            rgba(255, 255, 255, 0.008));
}

.research-board-card:hover::before {
    background: rgba(255, 255, 255, 0.24);
}

.research-board-card.is-selected {
    background:
        linear-gradient(90deg,
            rgba(32, 201, 151, 0.08),
            rgba(32, 201, 151, 0.015) 70%,
            transparent);

    box-shadow:
        inset 0 0 0 1px rgba(32, 201, 151, 0.055);
}

.research-board-card.is-selected::before {
    background: var(--research-positive);
}


/* ==========================================================================
   Board record metadata
   ========================================================================== */

.research-board-card__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    width: 100%;

    margin-bottom: 8px;
}

.research-board-card__type {
    color: rgba(93, 222, 181, 0.7);

    font-size: 7px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.14em;
}

.research-board-card__date {
    color: rgba(255, 255, 255, 0.25);

    font-size: 8px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0.06em;
    white-space: nowrap;
}


/* ==========================================================================
   Board record content
   ========================================================================== */

.research-board-card__title {
    display: -webkit-box;

    overflow: hidden;

    margin-bottom: 6px;

    color: rgba(255, 255, 255, 0.9);

    font-size: 12px;
    font-weight: 650;
    line-height: 1.35;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.research-board-card__context {
    display: -webkit-box;

    overflow: hidden;

    margin-bottom: 9px;

    color: rgba(255, 255, 255, 0.36);

    font-size: 9px;
    line-height: 1.5;

    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}


/* ==========================================================================
   Board symbols
   ========================================================================== */

.research-board-card__symbols {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;

    margin-bottom: 9px;
}

.research-board-card__symbols .research-symbol {
    min-height: 18px;
    padding: 0 5px;

    color: rgba(255, 255, 255, 0.5);

    font-size: 7px;
}


/* ==========================================================================
   Board record footer
   ========================================================================== */

.research-board-card__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    width: 100%;

    margin-top: auto;
}

.research-board-card__source {
    overflow: hidden;

    min-width: 0;

    color: rgba(255, 255, 255, 0.3);

    font-size: 8px;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-board-card__arrow {
    flex: 0 0 auto;

    color: rgba(255, 255, 255, 0.2);

    font-size: 15px;
    font-weight: 300;
    line-height: 1;

    transition:
        color 130ms ease,
        transform 130ms ease;
}

.research-board-card:hover .research-board-card__arrow {
    color: rgba(255, 255, 255, 0.68);

    transform: translateX(2px);
}


/* ==========================================================================
   Empty board lane
   ========================================================================== */

.research-board-lane__empty {
    display: flex;
    align-items: center;
    justify-content: center;

    min-height: 94px;
    padding: 18px;

    color: rgba(255, 255, 255, 0.16);

    font-size: 8px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}


/* ==========================================================================
   Board global state
   ========================================================================== */

.research-board-state {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;

    min-height: 320px;
    padding: 40px;

    background:
        linear-gradient(135deg,
            rgba(255, 255, 255, 0.014),
            transparent 46%),
        rgba(14, 16, 18, 0.76);
}

.research-board-state>span {
    margin-bottom: 10px;

    color: rgba(93, 222, 181, 0.72);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.15em;
}

.research-board-state>strong {
    max-width: 560px;

    color: rgba(255, 255, 255, 0.88);

    font-size: 18px;
    font-weight: 620;
    line-height: 1.3;
}

.research-board-state>p {
    max-width: 560px;

    margin: 8px 0 18px;

    color: rgba(255, 255, 255, 0.36);

    font-size: 10px;
    line-height: 1.6;
}


/* ==========================================================================
   Focused board category
   ========================================================================== */

.research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) {
    grid-template-columns: minmax(0, 1fr);
}

.research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-lane {
    min-height: 320px;
}

.research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
    display: grid;
    grid-template-columns:
        repeat(4, minmax(0, 1fr));

    align-items: stretch;
}

.research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-card {
    border-right: 1px solid rgba(255, 255, 255, 0.05);
}


/* ==========================================================================
   Board with research drawer open
   ========================================================================== */

.research-page--drawer-open .research-board {
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
}

.research-page--drawer-open .research-board-lane:nth-child(4n) {
    border-right: 1px solid rgba(255, 255, 255, 0.055);
}

.research-page--drawer-open .research-board-lane:nth-child(2n) {
    border-right: 0;
}

.research-page--drawer-open .research-board:has(.research-board-lane:only-child) {
    grid-template-columns: 1fr;
}

.research-page--drawer-open .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
    grid-template-columns:
        repeat(2, minmax(0, 1fr));
}


/* ==========================================================================
   Research table
   ========================================================================== */

.research-table {
    min-width: 0;
}

.research-table__header,
.research-row {
    display: grid;

    grid-template-columns:
        78px 108px minmax(250px, 1fr) minmax(100px, 150px) minmax(90px, 130px) 66px 20px;

    align-items: center;
    gap: 12px;
}

.research-table__header {
    min-height: 32px;
    padding: 0 12px;

    border-bottom: 1px solid var(--research-border);

    background: rgba(255, 255, 255, 0.014);
}

.research-table__header>div {
    color: rgba(255, 255, 255, 0.31);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.12em;
}

.research-table__body {
    min-width: 0;
}

.research-row {
    appearance: none;

    width: 100%;
    min-width: 0;
    min-height: 68px;

    padding: 8px 12px;

    border: 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.045);

    background: transparent;
    color: inherit;

    cursor: pointer;
    text-align: left;

    font: inherit;

    transition:
        background 120ms ease,
        box-shadow 120ms ease;
}

.research-row:last-child {
    border-bottom: 0;
}

.research-row:hover {
    background: rgba(255, 255, 255, 0.026);
}

.research-row.is-selected {
    background:
        linear-gradient(90deg,
            rgba(32, 201, 151, 0.065),
            rgba(32, 201, 151, 0.012));

    box-shadow:
        inset 2px 0 0 rgba(32, 201, 151, 0.68);
}

.research-row__date {
    color: var(--research-text-muted);

    font-size: 10px;
    font-variant-numeric: tabular-nums;
    white-space: nowrap;
}

.research-row__category {
    min-width: 0;
}

.research-category-badge {
    display: inline-flex;
    align-items: center;

    max-width: 100%;
    min-height: 22px;
    padding: 0 7px;

    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 3px;

    background: rgba(255, 255, 255, 0.025);
    color: rgba(255, 255, 255, 0.56);

    overflow: hidden;

    font-size: 8px;
    font-weight: 800;
    letter-spacing: 0.075em;
    text-overflow: ellipsis;
    text-transform: uppercase;
    white-space: nowrap;
}

.research-category-badge[data-category="competitors"] {
    border-color: rgba(255, 107, 107, 0.18);
    background: rgba(255, 107, 107, 0.055);
    color: rgba(255, 139, 139, 0.9);
}

.research-category-badge[data-category="deals"] {
    border-color: rgba(32, 201, 151, 0.18);
    background: rgba(32, 201, 151, 0.055);
    color: rgba(93, 222, 181, 0.9);
}

.research-category-badge[data-category="finance"] {
    border-color: rgba(77, 171, 247, 0.2);
    background: rgba(77, 171, 247, 0.06);
    color: rgba(116, 192, 252, 0.92);
}

.research-category-badge[data-category="regulation"] {
    border-color: rgba(240, 180, 41, 0.18);
    background: rgba(240, 180, 41, 0.05);
    color: rgba(244, 198, 90, 0.9);
}

.research-row__main {
    min-width: 0;
}

.research-row__title {
    margin-bottom: 5px;

    overflow: hidden;

    color: rgba(255, 255, 255, 0.9);

    font-size: 12px;
    font-weight: 650;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-row__context {
    overflow: hidden;

    color: rgba(255, 255, 255, 0.37);

    font-size: 10px;
    line-height: 1.35;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-row__source {
    overflow: hidden;

    color: var(--research-text-secondary);

    font-size: 10px;
    line-height: 1.25;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-row__symbols {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;

    min-width: 0;
}

.research-symbol {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 20px;
    padding: 0 6px;

    border: 1px solid rgba(255, 255, 255, 0.075);
    border-radius: 3px;

    background: rgba(255, 255, 255, 0.025);
    color: rgba(255, 255, 255, 0.72);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.06em;
}

.research-row__muted {
    color: var(--research-text-muted);
}

.research-row__type {
    color: rgba(255, 255, 255, 0.31);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.08em;
}

.research-row__chevron {
    color: rgba(255, 255, 255, 0.25);

    font-size: 18px;
    line-height: 1;
    text-align: right;
}

.research-row:hover .research-row__chevron {
    color: rgba(255, 255, 255, 0.7);
}


/* ==========================================================================
   Empty state
   ========================================================================== */

.research-empty-state {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: center;

    min-height: 360px;
    max-width: 620px;

    padding: 46px;
}

.research-empty-state__eyebrow {
    margin-bottom: 12px;

    color: var(--research-text-muted);

    font-size: 9px;
    font-weight: 800;
    letter-spacing: 0.15em;
}

.research-empty-state__title {
    margin-bottom: 9px;

    color: var(--research-text);

    font-size: 22px;
    font-weight: 620;
    letter-spacing: -0.025em;
}

.research-empty-state__copy {
    max-width: 520px;
    margin-bottom: 22px;

    color: var(--research-text-secondary);

    font-size: 12px;
    line-height: 1.65;
}


/* ==========================================================================
   Buttons
   ========================================================================== */

.research-button {
    appearance: none;

    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-height: 34px;
    padding: 0 13px;

    border-radius: 4px;

    cursor: pointer;

    font: inherit;
    font-size: 9px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.075em;
    text-transform: uppercase;

    transition:
        background 140ms ease,
        border-color 140ms ease,
        opacity 140ms ease,
        transform 140ms ease;
}

.research-button:hover:not(:disabled) {
    transform: translateY(-1px);
}

.research-button:disabled {
    cursor: not-allowed;
    opacity: 0.48;
}

.research-button--primary {
    border: 1px solid rgba(255, 255, 255, 0.16);

    background: rgba(255, 255, 255, 0.92);
    color: #111315;
}

.research-button--primary:hover:not(:disabled) {
    background: #ffffff;
}

.research-button--secondary {
    border: 1px solid var(--research-border-strong);

    background: rgba(255, 255, 255, 0.035);
    color: rgba(255, 255, 255, 0.76);
}

.research-button--secondary:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.065);
}

.research-button--danger {
    border: 1px solid rgba(255, 107, 107, 0.18);

    background: rgba(255, 107, 107, 0.055);
    color: rgba(255, 128, 128, 0.88);
}

.research-button--danger:hover:not(:disabled) {
    border-color: rgba(255, 107, 107, 0.3);
    background: rgba(255, 107, 107, 0.09);
}


/* ==========================================================================
   Research drawer
   ========================================================================== */

.research-drawer {
    display: flex;
    flex-direction: column;

    min-width: 0;
    min-height: 620px;

    border: 1px solid var(--research-border);
    border-radius: 8px;

    background:
        linear-gradient(180deg,
            rgba(255, 255, 255, 0.022),
            rgba(255, 255, 255, 0.006)),
        var(--research-surface-raised);

    overflow: hidden;
}

.research-drawer__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;

    padding: 17px 18px;

    border-bottom: 1px solid var(--research-border);
}

.research-drawer__eyebrow {
    margin-bottom: 7px;

    color: var(--research-text-muted);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.research-drawer__title {
    margin: 0;

    color: rgba(255, 255, 255, 0.92);

    font-size: 16px;
    font-weight: 650;
    line-height: 1.3;
    letter-spacing: -0.015em;
}

.research-drawer__close {
    appearance: none;

    display: flex;
    align-items: center;
    justify-content: center;

    flex: 0 0 28px;
    width: 28px;
    height: 28px;

    padding: 0;

    border: 1px solid var(--research-border);
    border-radius: 4px;

    background: rgba(255, 255, 255, 0.02);
    color: var(--research-text-muted);

    cursor: pointer;

    font: inherit;
    font-size: 17px;
    line-height: 1;
}

.research-drawer__close:hover {
    border-color: var(--research-border-strong);
    background: rgba(255, 255, 255, 0.05);
    color: var(--research-text);
}

.research-drawer__footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    margin-top: auto;
    padding: 12px 16px;

    border-top: 1px solid var(--research-border);

    background: rgba(0, 0, 0, 0.08);
}


/* ==========================================================================
   Editor
   ========================================================================== */

.research-editor {
    display: flex;
    flex-direction: column;
    gap: 15px;

    min-height: 0;
    padding: 17px 18px;
}

.research-editor__grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.research-field {
    display: flex;
    flex-direction: column;
    gap: 7px;

    min-width: 0;
}

.research-field__label {
    color: var(--research-text-muted);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.12em;
}

.research-field__input,
.research-field__textarea {
    width: 100%;

    border: 1px solid var(--research-border);
    border-radius: 4px;
    outline: 0;

    background: rgba(0, 0, 0, 0.2);
    color: var(--research-text);

    font: inherit;
    font-size: 11px;

    transition:
        border-color 140ms ease,
        background 140ms ease;
}

.research-field__input {
    height: 36px;
    padding: 0 10px;
}

.research-field__textarea {
    min-height: 230px;
    padding: 11px;

    resize: vertical;

    line-height: 1.55;
}

.research-field__input:focus,
.research-field__textarea:focus {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.28);
}

.research-field__input::placeholder,
.research-field__textarea::placeholder {
    color: rgba(255, 255, 255, 0.24);
}

.research-field__select {
    color-scheme: dark;
}

.research-field--context {
    flex: 1;
}

.research-editor__footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;

    padding-top: 2px;
}


/* ==========================================================================
   Detail view
   ========================================================================== */

.research-detail {
    flex: 1;

    min-height: 0;

    overflow-y: auto;
}

.research-detail__terminal-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));

    border-bottom: 1px solid var(--research-border);
}

.research-detail__metric {
    display: flex;
    flex-direction: column;
    gap: 6px;

    min-width: 0;
    padding: 12px 14px;
}

.research-detail__metric+.research-detail__metric {
    border-left: 1px solid var(--research-border);
}

.research-detail__metric span {
    color: var(--research-text-muted);

    font-size: 7px;
    font-weight: 800;
    letter-spacing: 0.12em;
}

.research-detail__metric strong {
    overflow: hidden;

    color: rgba(255, 255, 255, 0.78);

    font-size: 10px;
    font-weight: 650;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-detail__symbols {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;

    padding: 12px 16px;

    border-bottom: 1px solid var(--research-border);
}

.research-detail__section {
    padding: 17px 18px;

    border-bottom: 1px solid var(--research-border);
}

.research-detail__label {
    margin-bottom: 10px;

    color: var(--research-text-muted);

    font-size: 8px;
    font-weight: 800;
    line-height: 1;
    letter-spacing: 0.13em;
}

.research-detail__context {
    color: rgba(255, 255, 255, 0.7);

    font-size: 11px;
    line-height: 1.7;
}

.research-detail__url {
    display: block;

    overflow: hidden;

    color: rgba(255, 255, 255, 0.66);

    font-size: 10px;
    line-height: 1.45;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.research-detail__url:hover {
    color: rgba(255, 255, 255, 0.94);
    text-decoration: underline;
}

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

.research-detail__metadata>div {
    display: flex;
    flex-direction: column;
    gap: 5px;

    min-width: 0;
}

.research-detail__metadata span {
    color: rgba(255, 255, 255, 0.28);

    font-size: 7px;
    font-weight: 800;
    letter-spacing: 0.1em;
}

.research-detail__metadata strong {
    color: rgba(255, 255, 255, 0.62);

    font-size: 9px;
    font-weight: 600;
    line-height: 1.35;
}


/* ==========================================================================
   Error
   ========================================================================== */

.research-error {
    margin: 0 18px 14px;
    padding: 10px 11px;

    border: 1px solid rgba(255, 107, 107, 0.18);
    border-radius: 4px;

    background: rgba(255, 107, 107, 0.055);
    color: rgba(255, 150, 150, 0.9);

    font-size: 10px;
    line-height: 1.45;
}


/* ==========================================================================
   Scrollbars
   ========================================================================== */

.research-detail,
.research-field__textarea {
    scrollbar-width: thin;
    scrollbar-color:
        rgba(255, 255, 255, 0.15) transparent;
}

.research-detail::-webkit-scrollbar,
.research-field__textarea::-webkit-scrollbar {
    width: 7px;
}

.research-detail::-webkit-scrollbar-track,
.research-field__textarea::-webkit-scrollbar-track {
    background: transparent;
}

.research-detail::-webkit-scrollbar-thumb,
.research-field__textarea::-webkit-scrollbar-thumb {
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.13);
}


/* ==========================================================================
   Responsive — large
   ========================================================================== */

@media (max-width: 1280px) {

    .research-page--drawer-open .research-page__workspace {
        grid-template-columns:
            minmax(0, 1fr) minmax(350px, 38vw);
    }

    .research-board {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }

    .research-board-lane:nth-child(4n) {
        border-right:
            1px solid rgba(255, 255, 255, 0.055);
    }

    .research-board-lane:nth-child(3n) {
        border-right: 0;
    }

    .research-page--drawer-open .research-board {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .research-page--drawer-open .research-board-lane:nth-child(3n) {
        border-right:
            1px solid rgba(255, 255, 255, 0.055);
    }

    .research-page--drawer-open .research-board-lane:nth-child(2n) {
        border-right: 0;
    }

    .research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
        grid-template-columns:
            repeat(3, minmax(0, 1fr));
    }

    .research-page--drawer-open .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .research-table__header,
    .research-row {
        grid-template-columns:
            72px 100px minmax(220px, 1fr) minmax(90px, 120px) 90px 20px;
    }

    .research-table__header> :nth-child(6),
    .research-row__type {
        display: none;
    }
}


/* ==========================================================================
   Responsive — medium
   ========================================================================== */

@media (max-width: 1020px) {

    .research-page--drawer-open .research-page__workspace {
        grid-template-columns: minmax(0, 1fr);
    }

    .research-drawer {
        min-height: 0;
    }

    .research-library__toolbar {
        grid-template-columns: minmax(0, 1fr);
    }

    .research-library__toolbar-right {
        justify-content: space-between;
    }

    .research-board,
    .research-page--drawer-open .research-board {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .research-board-lane:nth-child(3n),
    .research-page--drawer-open .research-board-lane:nth-child(3n) {
        border-right:
            1px solid rgba(255, 255, 255, 0.055);
    }

    .research-board-lane:nth-child(2n),
    .research-page--drawer-open .research-board-lane:nth-child(2n) {
        border-right: 0;
    }

    .research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
        grid-template-columns:
            repeat(2, minmax(0, 1fr));
    }

    .research-table__header,
    .research-row {
        grid-template-columns:
            72px 100px minmax(220px, 1fr) minmax(90px, 120px) 20px;
    }

    .research-table__header> :nth-child(5),
    .research-row__symbols {
        display: none;
    }
}


/* ==========================================================================
   Responsive — small
   ========================================================================== */

@media (max-width: 760px) {

    .research-page__header {
        align-items: flex-start;
        flex-direction: column;
    }

    .research-page__header-metrics {
        width: 100%;
    }

    .research-page__metric {
        flex: 1;
    }

    .research-library__toolbar-right {
        flex-wrap: wrap;
    }

    .research-library__count {
        display: none;
    }

    .research-view-switch {
        margin-left: 0;
    }

    .research-board,
    .research-page--drawer-open .research-board {
        grid-template-columns: minmax(0, 1fr);
    }

    .research-board-lane,
    .research-board-lane:nth-child(2n),
    .research-board-lane:nth-child(3n),
    .research-board-lane:nth-child(4n),
    .research-page--drawer-open .research-board-lane:nth-child(2n),
    .research-page--drawer-open .research-board-lane:nth-child(3n) {
        border-right: 0;
    }

    .research-page[data-research-page-view="board"] .research-board:has(.research-board-lane:only-child) .research-board-lane__records,
    .research-page--drawer-open .research-board:has(.research-board-lane:only-child) .research-board-lane__records {
        grid-template-columns: minmax(0, 1fr);
    }

    .research-table__header {
        display: none;
    }

    .research-row {
        grid-template-columns:
            70px minmax(0, 1fr) 18px;

        gap: 10px;

        min-height: 72px;
    }

    .research-row__category,
    .research-row__source,
    .research-row__symbols,
    .research-row__type {
        display: none;
    }

    .research-editor__grid {
        grid-template-columns: 1fr;
    }

    .research-detail__terminal-strip {
        grid-template-columns: 1fr;
    }

    .research-detail__metric+.research-detail__metric {
        border-top: 1px solid var(--research-border);
        border-left: 0;
    }

    .research-detail__metadata {
        grid-template-columns: 1fr;
    }
}