/* css/publications.css */

.filter-controls {
    margin-bottom: 40px;
}

.filter-group {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #ddd;
}

.filter-group:last-child {
    border-bottom: none;
}

.filter-group .controls {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    /* This is needed to align the new input box */
}

.filter-btn.active {
    background-color: #333;
    color: #fff;
    border-color: #333;
}

/* --- Publication List Item Styling (RESTORED TO ORIGINAL) --- */
#publications-list {
    padding: 0;
    margin: 0;
    line-height: 1;
}

#publications-list li {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 10px;
    margin-bottom: 15px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.pub-number {
    font-size: 1.2rem;
    font-weight: bold;
    color: #aaa;
    padding-top: 0px;
}

.pub-content {
    flex-grow: 1;
}

.pub-title,
.pub-authors {
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.pub-title {
    color: #111;
    font-weight: 700;
    font-size: 1rem;
    letter-spacing: -0.25px;
}

.pub-authors {
    font-style: italic;
    color: #555;
    margin: 5px 0;
    font-size: 1rem;
}

.pub-journal {
    color: #777;
    font-size: 0.9rem;
}

.pub-doi a {
    color: #333;
    font-weight: bold;
    font-size: 0.8rem;
    line-height: 2;
}

/* --- NEW STYLES for the year input component --- */
.year-input-container {
    position: relative;
    display: flex;
    align-items: center;
}

.year-input-box {
    padding: 8px 60px 8px 18px;
    /* Add padding on the right for the button */
    border: 1px solid #ccc;
    background-color: #fff;
    color: #555;
    font-size: 0.9rem;
    border-radius: 20px;
    font-family: inherit;
    width: 180px;
    transition: border-color 0.2s ease-in-out;
    line-height: 1.5;
}

.year-input-box:focus {
    outline: none;
    border-color: #0056b3;
    /* Use site's blue color for focus */
}

.year-submit-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    padding: 5px 15px;
    font-size: 0.8rem;
    font-weight: bold;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.2s ease-in-out;

    /* Default state: Matches other unclicked buttons */
    background-color: #fff;
    color: #555;
    border: 1px solid #ccc;
}

/* Hover/Focus state: Becomes black with white text */
.year-input-container:hover .year-submit-btn,
.year-input-box:focus+.year-submit-btn,
.year-submit-btn:hover {
    background-color: #333;
    color: #fff;
    border-color: #333;
}

/* Removes arrows from number input */
.year-input-box::-webkit-outer-spin-button,
.year-input-box::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.year-input-box[type=number] {
    -moz-appearance: textfield;
}