/* ================================================
   YearPicker Custom Theme (Matches DatePicker)
   ================================================ */

/* Year picker dropdown */
.year-picker-dropdown {
    position: absolute;
    z-index: 20;
    padding-top: 4px;
    background-color: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    display: none;
    min-width: 280px;
}

.dark .year-picker-dropdown {
    background-color: #1f2937;
    border-color: #374151;
}

/* Header (controls) with decade navigation */
.year-picker-controls {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    background-color: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
    border-radius: 0.5rem 0.5rem 0 0;
    gap: 0.5rem;
}

.dark .year-picker-controls {
    background-color: #111827;
    border-bottom-color: #374151;
}

/* Navigation buttons */
.year-picker-prev,
.year-picker-next {
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0.5rem 0.25rem;
    color: #111827;
    transition: all 0.2s;
    border-radius: 0.25rem;
    outline: none;
    font-size: 0.875rem;
    font-weight: 600;
    flex: 0 0 auto;
    min-width: 2rem;
    height: 2rem;
    display: flex;
    align-items: center;
    justify-content: center;
}

.year-picker-prev:hover,
.year-picker-next:hover {
    background-color: #e5e7eb;
    color: #3b82f6;
}

.dark .year-picker-prev,
.dark .year-picker-next {
    color: #f9fafb;
}

.dark .year-picker-prev:hover,
.dark .year-picker-next:hover {
    background-color: #374151;
    color: #60a5fa;
}

/* Decade title */
.year-picker-title {
    flex: 1;
    text-align: center;
    color: #111827;
    font-weight: 600;
    font-size: 0.875rem;
}

.dark .year-picker-title {
    color: #f9fafb;
}

/* Main container */
.year-picker-main {
    padding: 0.5rem;
}

/* Year grid container - 5 columns for decade display */
.year-picker-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    justify-content: center;
}

/* Year picker cells - 5 columns (2 rows of 5 for a decade) */
.year-picker-cell {
    flex: 0 0 auto;
    width: calc(20% - 0.2rem);
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #111827;
    transition: all 0.2s;
    cursor: pointer;
    border-radius: 0.25rem;
    border: none;
    background: transparent;
    outline: none;
    font-weight: 500;
    font-size: 0.875rem;
}

.year-picker-cell:hover {
    background-color: #eff6ff;
    color: #3b82f6;
}

.dark .year-picker-cell {
    color: #f9fafb;
}

.dark .year-picker-cell:hover {
    background-color: rgba(30, 58, 138, 0.3);
    color: #60a5fa;
}

/* Selected year */
.year-picker-cell.selected,
.year-picker-cell.selected:hover {
    background-color: #3b82f6 !important;
    color: #ffffff !important;
    font-weight: 600;
}

.dark .year-picker-cell.selected,
.dark .year-picker-cell.selected:hover {
    background-color: #2563eb !important;
}

/* Current year (today equivalent) */
.year-picker-cell.today {
    background-color: #dbeafe;
    color: #1e40af;
    font-weight: 600;
}

.year-picker-cell.today:hover {
    background-color: #bfdbfe;
}

.dark .year-picker-cell.today {
    background-color: rgba(30, 58, 138, 0.5);
    color: #93c5fd;
}

.dark .year-picker-cell.today:hover {
    background-color: rgba(30, 58, 138, 0.7);
}
