/*
 * Month Input Component Styles
 * 
 * This file contains styles for making month input fields more user-friendly
 * by making the entire input area clickable to open the date picker.
 */

/* Month input clickable styling */
.month-input-clickable {
    cursor: pointer;
    position: relative;
    background-color: var(--input-bg, #fff);
    border: 1px solid var(--border-color, #ced4da);
    border-radius: 0.375rem;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    line-height: 1.5;
    color: var(--text-color, #212529);
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
    min-height: 38px;
}

.month-input-clickable:focus {
    border-color: #86b7fe;
    outline: 0;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.month-input-clickable:hover {
    border-color: #b0b0b0;
}

/* Make the entire input clickable by expanding the calendar picker indicator */
.month-input-clickable::-webkit-calendar-picker-indicator {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    cursor: pointer;
    opacity: 0; /* Hide the default icon but keep it functional */
    background: transparent;
}

/* Firefox support */
.month-input-clickable::-moz-calendar-picker-indicator {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    cursor: pointer;
    opacity: 0; /* Hide the default icon but keep it functional */
    background: transparent;
}

/* Add a custom calendar icon on the right side */
.month-input-clickable::after {
    content: '\1F4C5'; /* Calendar emoji */
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: var(--text-muted, #6c757d);
    font-size: 0.875rem;
}

/* Alternative: Use Font Awesome icon if available */
.month-input-clickable.fa-calendar::after {
    content: '\f073'; /* Font Awesome calendar icon */
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
}

/* Dark mode adjustments */
html[data-theme="dark"] .month-input-clickable {
    background-color: #2d3748;
    border-color: #4a5568;
    color: #fff;
}

html[data-theme="dark"] .month-input-clickable:focus {
    border-color: #3182ce;
    box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.1);
}

html[data-theme="dark"] .month-input-clickable:hover {
    border-color: #3182ce;
    background-color: #374151;
}

html[data-theme="dark"] .month-input-clickable::after {
    color: #a0aec0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .month-input-clickable {
        font-size: 16px; /* Prevent zoom on iOS */
    }
}