/* קובץ: style-forms.css */
/* תיאור: סגנונות עבור טפסים, שדות קלט, לוח שנה ומודאל */

/* קונטיינר כניסה */
.login-container {
    max-width: 300px;
    margin: 20px auto;
    padding: 15px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid #e0e0e0;
    direction: rtl;
    text-align: center;
}

/* מידע משתמש */
.user-info p {
    font-weight: 500;
    color: #fff;
    background: linear-gradient(90deg, #2c3e50, #4a6278);
    display: inline-block;
    padding: 8px 15px;
    border-radius: 20px;
    margin-bottom: 15px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

/* שדות טופס */
label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    text-align: center;
    color: #34495e;
}

input, select {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: none;
    border-radius: 8px;
    background: #f5f5f5;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    text-align: center;
    color: #2c3e50;
    transition: all 0.3s ease;
}

input:focus, select:focus {
    outline: none;
    background: #ffffff;
    box-shadow: 0 4px 20px rgba(52, 152, 219, 0.3);
}

/* קונטיינר לימים */
.days-input-container {
    margin-bottom: 10px;
}

/* קונטיינר לצ'קבוקס */
.checkbox-container {
    display: flex;
    align-items: center;
    justify-content: center;
    direction: rtl;
    gap: 8px;
    margin-bottom: 30px;
    white-space: nowrap;
}

.checkbox-container input {
    width: 16px;
    height: 16px;
    accent-color: #3498db;
}

/* קונטיינר להוספה ליומן */
.calendar-option {
    display: flex;
    align-items: center;
    justify-content: center;
    direction: rtl;
    gap: 8px;
    margin-bottom: 10px;
    margin-top: 20px;
    white-space: nowrap;
}

.calendar-option input {
    width: 16px;
    height: 16px;
    accent-color: #3498db;
}

/* כפתורים */
.btn {
    display: block;
    width: 100%;
    padding: 10px;
    margin-bottom: 10px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    text-align: center;
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.4), 0 2px 4px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
    position: relative;
    top: 0;
}

.btn:hover {
    background: linear-gradient(135deg, #2980b9, #1f6391);
    box-shadow: 0 8px 20px rgba(52, 152, 219, 0.6);
    top: -2px;
}

.btn:active {
    box-shadow: 0 2px 5px rgba(52, 152, 219, 0.2);
    top: 2px;
}

.logout-btn {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.logout-btn:hover {
    background: linear-gradient(135deg, #c0392b, #962d22);
}

.menu-btn {
    background: linear-gradient(135deg, #95a5a6, #7f8c8d);
}

.menu-btn:hover {
    background: linear-gradient(135deg, #7f8c8d, #6c757d);
}

/* תוצאות */
.result-section {
    margin-top: 15px;
    padding: 10px;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

#resultContainer {
    margin-top: 8px;
    font-weight: 500;
}

/* שגיאות */
.error {
    color: #e74c3c;
    text-align: center;
    margin-top: 5px;
    font-weight: 500;
    background: rgba(231, 76, 60, 0.1);
    padding: 5px 10px;
    border-radius: 4px;
}

/* לוח שנה */
.date-picker {
    position: relative;
    display: inline-block;
    width: 100%;
}

.calendar {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #ffffff;
    border: none;
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    padding: 10px;
    z-index: 1000;
    width: 100%;
    min-width: 300px;
}

.calendar.active {
    display: block;
}

.calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.month-year {
    font-weight: 500;
    color: #2c3e50;
}

.calendar button {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.2em;
    color: #3498db;
    transition: color 0.3s ease;
}

.calendar button:hover {
    color: #2980b9;
}

.days {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 6px;
    text-align: center;
}

.day {
    padding: 6px;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 35px;
}

.day:hover {
    background: rgba(52, 152, 219, 0.2);
}

.day.current {
    background: #3498db;
    color: #fff;
}

.day.selected {
    background: #2c3e50;
    color: #fff;
}

.day.other-month {
    color: #bdc3c7;
}

.day.recess-day {
    background: #e74c3c;
    color: #fff;
}

.day.saturday, .day.friday {
    background: #8e44ad;
    color: #fff;
}

.day.holiday-day {
    background: #f39c12;
    color: #fff;
}

.holiday-label {
    font-size: 0.6em;
    color: #2c3e50;
    position: absolute;
    bottom: -10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.calendar-legend {
    margin-top: 10px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    font-size: 0.8em;
    color: #2c3e50;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 5px;
}

.legend-color {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.legend-color.recess {
    background: #e74c3c;
}

.legend-color.holiday {
    background: #f39c12;
}

.legend-color.friday-saturday {
    background: #8e44ad;
}

.reset-date {
    display: block;
    margin: 8px auto 0;
    padding: 6px 12px;
    background: linear-gradient(135deg, #bdc3c7, #95a5a6);
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9em;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.reset-date:hover {
    background: linear-gradient(135deg, #95a5a6, #7f8c8d);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.2);
}

/* מודאל */
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background-color: #fff;
    margin: 15% auto;
    padding: 15px;
    border: 1px solid #888;
    width: 80%;
    max-width: 400px;
    text-align: center;
    direction: rtl;
}

.modal-content h3 {
    margin-bottom: 15px;
}

.modal-content p {
    margin: 10px 0;
}

.modal-content button {
    margin: 8px;
    padding: 8px 15px;
    cursor: pointer;
}

.confirm-btn {
    background-color: #4CAF50;
    color: white;
    border: none;
}

.cancel-btn {
    background-color: #f44336;
    color: white;
    border: none;
}

.remove-btn {
    background-color: #ff9800;
    color: white;
    border: none;
    padding: 5px 8px;
    margin: 5px;
    cursor: pointer;
}

.appendix-list {
    list-style: none;
    padding: 0;
    margin: 8px 0;
}

.appendix-list li {
    background: #f5f5f5;
    padding: 8px;
    margin-bottom: 5px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    cursor: move;
    transition: background 0.3s ease;
}

.appendix-list li.dragging {
    opacity: 0.5;
    background: rgba(52, 152, 219, 0.2);
}

#modalContent p {
    margin: 10px 0;
}