html,
body {
    min-height: 100%;
}

body {
    background-color: #232b55;
}

/* Login */

.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #232f5a;
}

.login-page main {
    width: 100%;
}

.login-card {
    border: 0;
    border-radius: 0.75rem;
}

/* Top banner */

.top-banner {
    background-color: #94272e;
    border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}

.top-banner .navbar-brand {
    color: #ffffff;
    font-weight: 700;
}

.top-banner .navbar-brand:hover,
.top-banner .navbar-brand:focus {
    color: #ffffff;
}

/* Page heading */

.abstracts-header {
    color: #ffffff;
}

.abstracts-header p {
    color: rgba(255, 255, 255, 0.75);
}

.abstracts-list {
    max-width: 960px;
}

/* Abstract cards */

.abstract-card {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 0.8rem;
}

.abstract-title {
    font-weight: 600;
    line-height: 1.4;
}

.abstract-metadata dt {
    font-weight: 600;
}

.abstract-metadata dd {
    margin-bottom: 0.65rem;
}

/* Card badges */

.topic-badge,
.abstract-type-badge {
    color: #212529;
    border: 1px solid rgba(0, 0, 0, 0.18);
    font-weight: 600;
}

.topic-badge {
    white-space: normal;
    text-align: left;
    line-height: 1.35;
}

/* Summary: hidden by default */

.abstract-card .abstract-summary {
    display: none !important;
    margin-top: 0;
    line-height: 1.65;
    text-align: justify;
}

.abstract-card .abstract-summary.abstract-summary-expanded {
    display: block !important;
}

/* Card actions */

.abstract-actions {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    margin-top: 0.65rem;
}

.summary-toggle,
.download-abstract-link {
    appearance: none;
    border: 0;
    background: none;
    margin: 0;
    padding: 0;
    color: #0d6efd;
    font: inherit;
    font-weight: 600;
    line-height: 1.5;
    text-decoration: none;
    cursor: pointer;
}

.summary-toggle:hover,
.summary-toggle:focus,
.download-abstract-link:hover,
.download-abstract-link:focus {
    text-decoration: underline;
}

/* Filters */

.filter-panel {
    border: 0;
    border-radius: 0.8rem;
}

.filter-panel .form-label {
    font-weight: 600;
}

.filter-buttons {
    display: grid;
    gap: 1rem;
    padding-top: 2rem;
}

.filter-buttons .btn {
    width: 100%;
}

/* Corresponding author */

.corresponding-link {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 0.15em;
}

.corresponding-link:hover,
.corresponding-link:focus {
    color: var(--bs-primary);
}

/* Search highlights */

.author-highlight,
.keyword-highlight {
    background-color: #fa8f8d;
    color: inherit;
    padding: 0.05em 0.2em;
    border-radius: 0.2rem;
    font-weight: 600;
}

/* Topic colors */

.topic-synthesis {
    background-color: #ffd1dc;
}

.topic-structural {
    background-color: #ffdfba;
}

.topic-modelling {
    background-color: #ffffba;
}

.topic-defossilization {
    background-color: #baffc9;
}

.topic-adsorption {
    background-color: #bae1ff;
}

.topic-environmental {
    background-color: #e6b3ff;
}

.topic-natural {
    background-color: #ffb3e6;
}

.topic-challenges {
    background-color: #fff2cc;
}

.topic-default {
    background-color: #f8f9fa;
}

/* Contribution type colors */

.type-plenary {
    background-color: #d9e1f2;
}

.type-keynote {
    background-color: #d9ead3;
}

.type-invited {
    background-color: #fce5cd;
}

/* Pagination */

.pagination-panel {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 0.75rem;
    align-items: center;
    padding: 0.65rem 0.85rem;
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 0.65rem;
}

.pagination-summary {
    white-space: nowrap;
    font-size: 0.9rem;
}

.pagination-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
    justify-content: center;
}

.pagination-button {
    min-width: 4.9rem;
    padding: 0.3rem 0.65rem;
    font-size: 0.875rem;
}

.pagination-current {
    padding: 0 0.35rem;
    white-space: nowrap;
    font-size: 0.9rem;
    font-weight: 600;
}

.per-page-form {
    display: flex;
    gap: 0.5rem;
    align-items: center;
    white-space: nowrap;
    font-size: 0.9rem;
}

.per-page-form .form-select {
    width: auto;
    min-width: 4.5rem;
    padding-top: 0.25rem;
    padding-bottom: 0.25rem;
}

/* Responsive */

@media (max-width: 991.98px) {
    .pagination-panel {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .pagination-summary {
        white-space: normal;
    }

    .per-page-form {
        justify-content: center;
    }
}

@media (max-width: 767.98px) {
    .filter-buttons {
        padding-top: 0;
    }
}

@media (max-width: 575.98px) {
    .abstract-card .card-body {
        padding: 1.25rem !important;
    }

    .abstract-card .abstract-summary {
        text-align: left;
    }

    .abstract-actions {
        align-items: flex-start;
    }

    .pagination-controls {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .pagination-current {
        grid-column: 1 / -1;
        grid-row: 1;
    }

    .pagination-button {
        min-width: 0;
    }
}