/* css/style.css  */
/* עיצוב כללי */



/* עיצוב ראש הטופס */
.form-intro {
    width: 80%;
    margin: 0 auto 30px auto;
    padding: 15px;
    background-color: #fdfefe ; /* רקע אפור עדין */
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.form-intro h2 {
    color: #1f618d; /* צבע הפונט שביקשת */
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.4;
}

.intro-notes {
    color: #333;
    line-height: 1.6;
}

.intro-notes p {
    margin-bottom: 15px;
}

.intro-notes ol {
    margin-right: 20px;
    padding-right: 0;
}

.intro-notes li {
    margin-bottom: 12px;
}

.intro-notes strong {
    color: #1f618d;
}


/* תיקון יישור כללי */
.rent-tax-calculator-form {
    text-align: right;
    direction: rtl;
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
    font-family: 'David', 'Alef', Arial, sans-serif;
}


.form-section {
    text-align: right;
    direction: rtl;
    background-color: #f8f9f9;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
}
.form-section h3 {
    text-align: right;
    margin-right: 0;
    margin-left: auto;
}

/* תיקון לקבוצות טופס */
.form-group {
    display: flex;
    flex-direction: row; /* השאר כ-row */
    justify-content: flex-start; /* בסדר לשימוש ב-RTL */
    align-items: center;
    margin-bottom: 20px;
    width: 100%;
    flex-wrap: wrap;
    
    
      background: #fff;
      border-radius: 12px;
      
    
   
    padding-right: 10px; 
}


.form-group label {
    display: inline-block;
    margin-left: 15px;
    width: 45%; /* הגדלה מ-30% ל-45% */
    
   
    position: relative;
    order: -1;
     font-weight: 700;
    font-size: 18px; /* הגדלה ל-18px מ-16px */
    color: #14548A;
}




/* תיקון שדות קלט */
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.radio-group,
.checkbox-group,
.image-radio-group {
    width: 50%;
    max-width: 50%;
   display: flex;
    align-items: flex-start;
        transition: border-color 0.3s, box-shadow 0.3s;
    font-family: 'David', 'Alef', Arial, sans-serif;
}



/* סימון הערה */
.info-icon {
    display: inline-block;
    width: 18px;
    height: 18px;
    background-color: #3498db;
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 18px;
    font-size: 12px;
    
    cursor: help;
    font-family: 'David', 'Alef', Arial, sans-serif;
    
     margin-right: 5px;
    margin-left: 0;
    order: 0; /* יבוא לפני התווית */
}

/* הערות (טולטיפ) */
.tooltip-text {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    max-width: 500px;
    background-color: #333;
    color: #fff;
    text-align: center;
    border-radius: 6px;
    padding: 15px;
    z-index: 1000;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    font-family: 'David', 'Alef', Arial, sans-serif;
}

.tooltip-text.show {
    display: block;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}






.form-group input:focus,
.form-group select:focus {
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
    outline: none;
}

/* סימון שדות חובה */
.required {
    color: #e74c3c;
    margin-right: 5px;
}



.radio-group label,
.checkbox-group label,
.image-radio label {
    margin-left: 20px;
    display: flex;
    align-items: center;
    cursor: pointer;
    width: auto;
    font-weight: normal;
}


/*
.image-radio {
    display: inline-flex;
    align-items: center;
    margin-left: 20px;
    padding: 10px;
    border: 2px solid transparent;
    border-radius: 5px;
    transition: all 0.3s;
}
*/

/* עיצוב חדש ומודרני לטבלאות */
.monthly-rent-table,
.monthly-all-rent-table,
.monthly-exemption-table {
    width: 60%; /* רוחב 60% במסך רגיל */
    margin: 30px auto; /* מרכז את הטבלה ומוסיף מרווח מעל ומתחת */
    border-collapse: collapse;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1); /* צל עדין */
    border-radius: 8px;
    overflow: hidden; /* שומר על הפינות המעוגלות */
}

/* כותרות הטבלה */
.monthly-rent-table th,
.monthly-all-rent-table th,
.monthly-exemption-table th {
    background-color: #14548A;
    color: white;
    text-align: center; /* מרכז את הטקסט */
    padding: 15px 20px;
    font-weight: bold;
}

/* תאי הטבלה */
.monthly-rent-table td,
.monthly-all-rent-table td,
.monthly-exemption-table td {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
    text-align: center; /* מרכז את התוכן */
}

/* שדות קלט בטבלה - תיקון למרכוז וגודל מלא */
.monthly-rent-table input,
.monthly-all-rent-table input,
.monthly-exemption-table input {
    width: 100%; /* 100% מהרוחב */
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    text-align: center; /* מרכז את הטקסט בתוך השדה */
    font-size: 16px;
    display: block; /* חשוב כדי לוודא שהאינפוט תופס את כל הרוחב */
    margin: 0 auto; /* מרכז את האינפוט בתוך התא */
    box-sizing: border-box; /* כולל את הפדינג ברוחב */
}

.total-row {
    background-color: #eaf6fe !important;
    font-weight: bold;
}

.total-row td {
    border-top: 2px solid #ccc;
}



/* מקרה מיוחד - תיבת סימון של "זהה בכל החודשים" */

.same-rent-checkbox label {
    font-weight: bold;
    color: #148f77;
    display: flex;
   font-size: 14px;
    width: 100%;
}

.same-rent-checkbox .checkmark {
    margin-left: 8px;
    
}

.same-rent-checkbox small {
    
    width: 100%;
    margin-top: 3px;
    color: #148f77;
}




/* ריווח אנכי טוב יותר בין שאלות מותנות */
.israel-only .form-group,
.multiple-apartments-only .form-group,
.other-apartment-only .form-group {
    margin-bottom: 30px; /* מרווח גדול יותר בין שאלות באזורים מותנים */
    padding-top: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eaeaea; /* קו הפרדה קל בין השאלות */
}

/* ריווח מיוחד לאזור כתובות דירות נוספות */
.multiple-apartments-only,
.other-apartment-only,
.israel-only {
    margin-top: 25px;
    
    background-color: #f4f6f6; /* רקע קל לאזור המותנה */
    border-radius: 8px;
}

/* כותרת מובלטת באזורים מותנים */
.israel-only h4,
.multiple-apartments-only h4,
.other-apartment-only h4 {
    color: #14548A;
    font-size: 17px;
    margin-bottom: 20px;
    border-bottom: 1px dashed #ccc;
    padding-bottom: 10px;
}


/* שינוי סידור תיבות הסימון לאנכי באזור האחרון */
.elderly-resident-only .checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 15px; /* מרווח בין האפשרויות */
}

.elderly-resident-only .checkbox-group label {
    width: 100%;
    margin-bottom: 10px;
    display: flex;
    align-items: flex-start;
}

/* וודא שהצ'קבוקסים מיושרים יפה */
.elderly-resident-only .checkbox-group input[type="checkbox"] {
    margin-left: 10px;
    margin-top: 3px; /* יישור אנכי עם הטקסט */
}




/* התאמה למסכי נייד */
@media (max-width: 768px)
{
.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="number"],
.form-group input[type="date"],
.form-group select,
.radio-group,
.checkbox-group,
.image-radio-group {
    width: 100%;
    max-width: 100%;
   display: flex;
    align-items: flex-start;
    transition: border-color 0.3s, box-shadow 0.3s;
    font-family: 'David', 'Alef', Arial, sans-serif;}

.form-group label {
    display: inline-block;
    margin-left: 10px;
    width: 100%; 
    position: relative;
    order: -1;
    font-weight: 700;
    font-size: 16px; /* הגדלה ל-18px מ-16px */
    color: #14548A;
}

.form-section {
    text-align: right;
    direction: rtl;
    background-color: #f8f9f9;
    padding: 5px;
    border-radius: 12px;
    margin-bottom: 20px;
}
.form-section h3 {
    text-align: right;
    margin-right: 0;
    margin-left: auto;
}



.same-rent-checkbox label {
    font-weight: bold;
    color: #148f77;
    display: flex;
   font-size: 14px;
    width: 100%;
}

    .monthly-rent-table,
    .monthly-all-rent-table,
    .monthly-exemption-table {
        width: 95%; /* רוחב 90% במסך נייד */
    }
    
    .monthly-rent-table th,
    .monthly-all-rent-table th,
    .monthly-exemption-table th,
    .monthly-rent-table td,
    .monthly-all-rent-table td,
    .monthly-exemption-table td {
        padding: 5px; /* פחות ריפוד במסכים קטנים */
    }
    
    .form-intro {
        width: 100%;
        padding: 5px;
    }
    
    .form-intro h2 {
        font-size: 22px;
    }
    
}






/* כפתורים בסוף הטופס */
.form-actions {
    margin-top: 30px;
    text-align: center;
}

.button {
    display: inline-block;
    padding: 12px 24px;
    margin: 0 10px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: background-color 0.3s, transform 0.1s;
    font-family: 'David', 'Alef', Arial, sans-serif;
}

.button-primary {
    background-color: #3498db;
    color: white;
}

.button-primary:hover {
    background-color: #2980b9;
}

.button:not(.button-primary) {
    background-color: #ecf0f1;
    color: #7f8c8d;
}

.button:not(.button-primary):hover {
    background-color: #dfe4e6;
}

.button:active {
    transform: scale(0.98);
}
