/* Sticky Header */
.site-header {
    position: sticky;
    top: 0;
    background: var(--theme-bg-primary);
    z-index: 100;
}

/* Search Modal CSS */
.search-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--theme-bg-modal);
    z-index: 1000;
    overflow-y: auto;
}
.search-modal.active {
    display: block;
}
.search-modal-content {
    max-width: 700px;
    margin: 2rem auto;
    padding: 1.5rem;
    background: var(--theme-bg-card);
    border-radius: 8px;
    border: 1px solid var(--theme-border);
}
.search-modal-close {
    float: right;
    background: none;
    border: none;
    color: var(--theme-text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}
.search-modal-close:hover {
    color: var(--theme-accent);
}
.search-input {
    width: 100%;
    background: var(--theme-bg-primary);
    border: 1px solid var(--theme-border-light);
    border-radius: 4px;
    padding: 0.75rem 1rem;
    color: var(--theme-text-primary);
    font-size: 1rem;
    margin-bottom: 1rem;
}
.search-input:focus {
    outline: none;
    border-color: var(--theme-accent);
}
.search-input::placeholder {
    color: var(--theme-text-muted);
}
.filter-section {
    margin-bottom: 0.75rem;
}
.filter-label {
    color: var(--theme-text-secondary);
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    display: block;
}
.filter-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}
.filter-btn {
    background: var(--theme-bg-tertiary);
    border: 1px solid var(--theme-border-light);
    border-radius: 4px;
    padding: 0.4rem 0.8rem;
    color: var(--theme-text-secondary);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}
.filter-btn:hover {
    border-color: var(--theme-accent);
    color: var(--theme-text-primary);
}
.filter-btn.active {
    background: var(--theme-accent);
    border-color: var(--theme-accent);
    color: var(--theme-accent-text);
}
.clear-filters {
    background: transparent;
    border: 1px solid var(--theme-text-muted);
    border-radius: 4px;
    padding: 0.4rem 0.8rem;
    color: var(--theme-text-muted);
    font-size: 0.85rem;
    cursor: pointer;
}
.clear-filters:hover {
    border-color: var(--theme-accent);
    color: var(--theme-accent);
}
.search-results-info {
    color: var(--theme-text-muted);
    font-size: 0.85rem;
    margin: 1rem 0 0.5rem;
}
.search-results {
    max-height: 50vh;
    overflow-y: auto;
}
.search-result-item {
    display: block;
    padding: 0.75rem;
    border-bottom: 1px solid var(--theme-border);
    text-decoration: none;
    color: var(--theme-text-primary);
}
.search-result-item:hover {
    background: var(--theme-bg-tertiary);
}
.result-date {
    color: var(--theme-text-secondary);
    font-size: 0.8rem;
    margin-right: 0.5rem;
}
.result-title {
    color: var(--theme-text-primary);
}
.result-category {
    color: var(--theme-accent);
    font-size: 0.8rem;
    margin-left: 0.5rem;
}
.no-results {
    text-align: center;
    color: var(--theme-text-muted);
    padding: 2rem;
}

/* Calendar Picker */
.calendar-section {
    margin-bottom: 1rem;
}
.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}
.calendar-header .filter-label {
    margin-bottom: 0;
}
.calendar-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.calendar-nav button {
    background: var(--theme-bg-tertiary);
    border: 1px solid var(--theme-border-light);
    border-radius: 4px;
    color: var(--theme-text-secondary);
    width: 28px;
    height: 28px;
    cursor: pointer;
    font-size: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
}
.calendar-nav button:hover {
    border-color: var(--theme-accent);
    color: var(--theme-accent);
}
.calendar-nav button:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}
.calendar-month-label {
    color: var(--theme-text-primary);
    font-size: 0.9rem;
    min-width: 100px;
    text-align: center;
}
.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 2px;
}
.calendar-weekday {
    text-align: center;
    color: var(--theme-text-muted);
    font-size: 0.75rem;
    padding: 0.25rem;
}
.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    border-radius: 4px;
    cursor: default;
    color: var(--theme-border-light);
}
.calendar-day.has-articles {
    background: var(--theme-bg-tertiary);
    color: var(--theme-accent);
    cursor: pointer;
    border: 1px solid var(--theme-border-light);
}
.calendar-day.has-articles:hover {
    background: var(--theme-bg-secondary);
    border-color: var(--theme-accent);
}
.calendar-day.selected {
    background: var(--theme-accent);
    color: var(--theme-accent-text);
    font-weight: bold;
}
.calendar-day.selected:hover {
    background: var(--theme-accent-hover);
}
.calendar-day.empty {
    visibility: hidden;
}
