/*
 * Tela Network v2 — forum post search.
 */

.v2-search-page {
    padding-bottom: 4rem;
}


/* Page header */

.v2-search-header {
    border-bottom: 1px solid var(--v2-rule);
    padding-bottom: 2.5rem;
}

@media (min-width: 768px) {
    .v2-search-header {
        padding-bottom: 3rem;
    }
}

.v2-search-title {
    font-size: 1.875rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    line-height: 1.15;
    margin: 0;
}

@media (min-width: 640px) {
    .v2-search-title {
        font-size: 2.25rem;
    }
}

.v2-search-intro {
    font-size: 1.0625rem;
    line-height: 1.625;
    margin: 0.75rem 0 0;
    max-width: 36rem;
}

.v2-search-form {
    margin-top: 1.5rem;
    max-width: 42rem;
}

.v2-search-form-row {
    align-items: stretch;
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.v2-search-textarea {
    background-color: var(--v2-paper);
    border: 1px solid var(--v2-input);
    color: var(--v2-foreground);
    flex: 1 1 12rem;
    font-family: var(--v2-font-sans);
    font-size: 0.875rem;
    line-height: 1.5;
    min-height: 5.5rem;
    min-width: 0;
    padding: 0.75rem 0.875rem;
    resize: vertical;
    width: 100%;
}

.v2-search-textarea:focus {
    border-color: color-mix(in oklch, var(--v2-foreground) 50%, var(--v2-input));
    outline: none;
}

.v2-search-textarea::placeholder {
    color: var(--v2-muted-foreground);
    font-size: 0.875rem;
    font-weight: 500;
    opacity: 1;
}

.v2-search-submit {
    align-items: center;
    align-self: stretch;
    display: inline-flex;
    flex-shrink: 0;
    justify-content: center;
    text-align: center;
}


/* Rate limit */

.v2-search-rate-limit {
    border: 1px solid var(--v2-border);
    margin-top: 1.5rem;
    max-width: 42rem;
    padding: 1rem;
}

.v2-search-rate-limit-lead {
    font-size: var(--v2-text-base);
    line-height: 1.625;
    margin: 0;
}

.v2-search-rate-limit-copy {
    font-size: var(--v2-text-sm);
    line-height: 1.625;
    margin: 0.75rem 0 0;
}


/* Results */

.v2-search-results {
    padding-top: 2rem;
}

.v2-search-fallback,
.v2-search-results-count,
.v2-search-empty {
    font-size: var(--v2-text-base);
    line-height: 1.625;
    margin: 0;
    max-width: 42rem;
}

.v2-search-fallback,
.v2-search-results-count {
    margin-bottom: 0.75rem;
}

.v2-search-empty {
    margin-top: 1.5rem;
}

.v2-search-results-list .v2-log-eyebrow a {
    text-decoration: none;
}

.v2-search-results-list .v2-log-eyebrow a:hover {
    text-decoration: underline;
}


/* Search hit highlights */

.v2-search-page .search-hit {
    background: transparent;
    border: 2px solid color-mix(in oklch, var(--v2-accent) 35%, transparent);
    border-radius: 4px;
    color: inherit;
    padding: 0 2px;
}


/* Pagination */

.v2-search-pagination {
    align-items: center;
    display: flex;
    gap: 0.75rem;
    justify-content: space-between;
    margin-top: 1rem;
}

.v2-search-pagination-form {
    margin: 0;
}

.v2-search-pagination-disabled {
    cursor: default;
    opacity: 0.45;
    pointer-events: none;
}
