/*
 * embedded_form_styles.css
 *
 * This file contains all the CSS for the embedded form,
 * including styles for light and dark themes.
 *
 * It is designed to be clean, elegant, and avoid conflicts.
 */

/* Import Heebo font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@300;400;500;600;700&display=swap');

/* Apply Heebo font to the entire body */
body {
    font-family: 'Heebo', Arial, sans-serif;
    padding-bottom: 1px;
    margin: 0;
}

/* General form styling */
.form-group {
    margin-bottom: 15px;
}

label {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
    font-weight: normal; /* Labels are no longer bold */
    justify-content: flex-start; /* Align content to the start (right for RTL, left for LTR) */
    color: #333; /* Default text color for labels */
}

/* Style for required asterisk */
.required-asterisk {
    color: #d9534f; /* Red color */
    font-size: 1.1em;
    vertical-align: middle;
    order: 1; /* Place asterisk after label text in LTR */
    margin-left: 5px; /* Space between text and asterisk in LTR */
}

/* Adjust for RTL: asterisk appears before label text */
html[dir="rtl"] .required-asterisk {
    order: 0; /* Place asterisk before label text in RTL */
    margin-right: 5px; /* Space between asterisk and text in RTL */
    margin-left: 0; /* Remove left margin for RTL */
}

input[type="text"],
input[type="tel"],
input[type="email"],
select {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
    font-size: 16px;
    color: #333; /* Default input text color */
    background-color: #fff; /* Default input background */
}

input[type="text"]:focus,
input[type="tel"]:focus,
input[type="email"]:focus,
select:focus {
    border-color: #007bff; /* Highlight on focus */
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

button[type="submit"] {
    background-color: #007bff;
    color: white;
    padding: 12px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 17px;
    width: 100%;
    margin-top: 20px;
    transition: background-color 0.3s ease, transform 0.1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

button[type="submit"]:hover {
    background-color: #0056b3;
    transform: translateY(-1px);
}

button[type="submit"]:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

.error-message {
    color: #d9534f;
    font-size: 0.9em;
    margin-top: 5px;
    display: block;
}

.logo-container {
    text-align: center;
    margin-bottom: 20px;
}

.logo-container img {
    max-width: 250px;
    height: auto;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.container {
    max-width: 660px;
    margin: auto;
    padding: 25px;
    border: 1px solid #ddd;
    border-radius: 8px;
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

@media (max-width: 600px) {
    .container {
        /* מבטל את הרוחב המקסימלי כדי שיתפוס 100% מהרוחב */
        max-width: 100%;

        /* מבטל את השוליים האוטומטיים */
        margin: 0;

        /* מבטל את עיגול הפינות כי הוא לא רלוונטי על כל המסך */
        border-radius: 0;

        /* מבטל את הגבולות (או לפחות את הצדדיים) */
        border: none;

        /* מבטל את הצל */
        box-shadow: none;

        /* אופציונלי: כדאי להתאים את הריפוד הפנימי למסך קטן יותר */
        padding: 20px 15px;
    }
}

h1 {
    text-align: center;
    color: #333;
    margin-bottom: 30px;
}

/* Style for the bank explanation paragraph */
.bank-explanation {
    background-color: #eaf5ff;
    border-left: 5px solid #007bff;
    padding: 10px 15px;
    margin-top: 10px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-size: 0.95em;
    color: #333;
    line-height: 1.4;
    text-align: justify;
}

/* --- Dropzone.js Minimal Custom Styles --- */
/* These rules ensure the remove button and progress bar are visible and functional */

.dropzone {
    border: 2px dashed #a0a0a0;
    border-radius: 8px;
    padding: 25px;
    min-height: 120px;
    text-align: center;
    background-color: #fcfcfc;
    color: #666;
    transition: border-color 0.3s ease, background-color 0.3s ease;
    cursor: pointer;
    position: relative; /* Needed for positioning dz-previews */
    overflow: hidden; /* Hide anything outside the dropzone area */
}

.dropzone:hover {
    border-color: #888;
    background-color: #f0f0f0;
}

/* Ensure dz-message is visible when no files, hidden when files are present */
.dropzone .dz-message {
    display: block;
    margin: 0;
    font-size: 1.1em;
    font-weight: 500;
    color: #555;
    line-height: 1.5;
}

.dropzone.dz-has-files .dz-message {
    display: none;
}

.dropzone .dz-message span {
    display: block;
    margin-top: 8px;
    font-size: 0.9em;
    color: #888;
}

/* Style for the remove button 'X' */
.dropzone .dz-remove {
    font-weight: normal;
    text-decoration: none;
    display: inline-block; /* Changed to inline-block for better flow with default preview */
    width: 20px; /* Make it a clickable square */
    height: 20px;
    line-height: 1; /* Center 'x' vertically */
    border-radius: 50%;
    background-color: transparent;
    border: none;
    color: #888; /* Grey 'X' */
    font-size: 1.2em; /* Slightly larger 'X' */
    transition: color 0.2s ease;
    cursor: pointer;
    text-align: center; /* Center 'x' horizontally */
    margin-left: 5px; /* Add some space to its left */
    margin-right: 0; /* Reset right margin */
}

html[dir="rtl"] .dropzone .dz-remove {
    margin-left: 0;
    margin-right: 5px; /* Add some space to its right for RTL */
}

.dropzone .dz-remove:hover {
    color: #d9534f; /* Red 'X' on hover */
}

/* Progress bar styles */
.dropzone .dz-preview .dz-progress {
    display: block; /* Ensure it's displayed */
    height: 4px; /* Thicker progress bar for visibility */
    background: #e0e0e0; /* Light grey background for the track */
    border-radius: 2px;
    margin-top: 5px; /* Space below filename */
}

.dropzone .dz-preview .dz-progress .dz-upload {
    display: block;
    height: 100%;
    background: #007bff; /* Primary color for progress */
    border-radius: 2px;
    transition: width 0.2s ease-in-out;
}

.dropzone .dz-preview.dz-success .dz-progress .dz-upload {
    background: #28a745; /* Green for success */
}

.dropzone .dz-preview.dz-error .dz-progress .dz-upload {
    background: #dc3545; /* Red for error */
}

.dropzone .dz-preview.dz-complete .dz-progress {
    opacity: 0;
    transition: opacity 0.5s ease-out;
}

/* ודא שהטוען מוסתר בהתחלה */
#submitLoader {
    display: none;
}

/* סגנון לכפתור במצב טעינה */
#submitButton {
    display: flex; /* מאפשר סידור פנימי גמיש */
    align-items: center; /* ממקם את הטקסט והטוען אנכית */
    justify-content: center; /* ממקם את התוכן במרכז הכפתור */
    gap: 8px; /* מוסיף רווח קטן בין הטקסט לטוען */
}

/* עיצוב בסיסי לטוען (loader) - החלף בעיצוב שלך אם יש */
.loader {
    border: 3px solid #f3f3f3; /* Light grey */
    border-top: 3px solid #3498db; /* Blue */
    border-radius: 50%;
    width: 16px;
    height: 16px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Message Box Styles */
#formMessage {
    margin-top: 15px;
    padding: 10px 15px;
    border-radius: 5px;
    font-weight: bold;
    text-align: center;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease-in-out;
}

#formMessage.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

#formMessage.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Legal Terms Styles */
.legal-terms-container {
    margin-top: 25px;
    margin-bottom: 15px;
    font-size: 0.85em;
    color: #555;
    line-height: 1.5;
    text-align: justify;
}

.legal-terms-content {
    overflow: hidden;
    position: relative;
    transition: max-height 0.3s ease-out; /* אנימציה נחמדה לפתיחה וסגירה */
    text-align: justify;
}

.legal-terms-fade {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2.5em;
    background: linear-gradient(to top, rgba(255,255,255,1), rgba(255,255,255,0));
    pointer-events: none;
}
/* בקובץ embedded_form_styles.css */

.legal-terms-toggle-btn {
    /* הסרת עיצוב ברירת מחדל של קישור */
    text-decoration: underline; /* בדרך כלל קו תחתון הוא סימן טוב לאינטראקטיביות */
    color: #007bff; /* צבע כחול סטנדרטי לקישורים, או צבע המותג שלך */
    background: none;
    border: none;
    padding: 0;

    /* מאפיינים נוספים */
    font-size: 0.85em; /* מעט קטן יותר מהטקסט הרגיל */
    font-weight: bold; /* הדגשה קלה */
    cursor: pointer; /* להראות שניתן ללחו 사진 */
    display: block; /* כדי שיהיה בשורה משלו */
    margin-top: 5px; /* ריווח קטן מהטקסט שמעליו */
    transition: color 0.2s;
}

.legal-terms-toggle-btn:hover {
    text-decoration: none; /* הסרת הקו התחתון במעבר עכבר - אפקט נחמד */
    color: #0056b3; /* צבע כהה יותר במעבר עכבר */
}
.smartnpv-link{
    border-top: 1px solid #e0e0e0;
    padding: 20px 0;
    font-size: 13px;
    color: #888;
    margin-top: 20px;
}
.smartnpv-link>span{
    float: right;
}
.smartnpv-link>a{
    color: #0c90e0;
    float: left;
}

/*.summary-card{*/
/*    background: aliceblue;*/
/*    padding: 20px;*/
/*    border-radius: 6px;*/
/*    margin: 10px;*/

/*}*/
/*.summary-card .tracks{*/
/*    display: flex;*/
/*    justify-content: space-around;*/
/*}*/
/*.track-item {*/
/*    display: flex;*/
/*    flex-direction: column;*/
/*    align-items: center;*/
/*    gap: 2px;*/
/*}*/
.text-muted{
    color: #2f2f2f;
}
.image-guide-container {
    display: flex;
    gap: 10px; /* רווח בין התמונות */
    margin-bottom: 15px; /* רווח מתיבת הבחירה */
    flex-wrap: wrap; /* יאפשר גלישה לשורה חדשה אם אין מקום */
}

.guide-thumbnail img {
    width: auto;  /* רוחב התמונה הממוזערת */
    height: 60px;
    border: 1px solid #ccc;
    border-radius: 5px;
    cursor: pointer;
    transition: transform 0.2s;
}

.guide-thumbnail img:hover {
    transform: scale(1.05); /* אפקט קטן במעבר עכבר */
    border-color: #337ab7;
}
/*
 * הגבלת גודל התמונה בתוך Fancybox
 */
.fancybox-image {
    /* מגדיר רוחב מקסימלי לתמונה.
       היא יכולה להיות קטנה יותר, אבל לא תעבור את 900px. */
    max-width: 900px !important;

    /* חשוב: מאפשר לתמונה להתכווץ במידת הצורך ושומר על הפרופורציות */
    height: auto;
}
/* --- Dark Theme Overrides (using body.dark class) --- */
body.dark {
    color: #eee;
}

body.dark .container {
    background-color: #333;
    border-color: #444;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

body.dark h1 {
    color: #eee;
}

body.dark label {
    color: #eee;
}

body.dark input[type="text"],
body.dark input[type="tel"],
body.dark input[type="email"],
body.dark select {
    background-color: #444;
    border-color: #555;
    color: #eee;
}

body.dark input[type="text"]:focus,
body.dark input[type="tel"]:focus,
body.dark input[type="email"]:focus,
body.dark select:focus {
    border-color: #00aaff;
    box-shadow: 0 0 0 2px rgba(0, 170, 255, 0.25);
}

body.dark button[type="submit"] {
    background-color: #00aaff;
}

body.dark button[type="submit"]:hover {
    background-color: #0088cc;
}

body.dark .error-message {
    color: #ff6666;
}

body.dark .bank-explanation {
    background-color: #444;
    border-left-color: #00aaff;
    color: #eee;
}

body.dark .dropzone {
    background-color: #2b2b2b;
    border-color: #555;
    color: #bbb;
}

body.dark .dropzone:hover {
    background-color: #3a3a3a;
    border-color: #777;
}

body.dark .dropzone .dz-message {
    color: #ddd;
}

body.dark .dropzone .dz-message span {
    color: #aaa;
}

/* Dark theme for remove button */
body.dark .dropzone .dz-remove {
    color: #bbb;
}
body.dark .dropzone .dz-remove:hover {
    color: #ff6666;
}

/* Dark theme for progress bar */
body.dark .dropzone .dz-preview .dz-progress {
    background: #555;
}
body.dark .dropzone .dz-preview .dz-progress .dz-upload {
    background: #00aaff;
}

body.dark .dropzone .dz-preview.dz-success .dz-progress .dz-upload {
    background: #28a745;
}

body.dark .dropzone .dz-preview.dz-error .dz-progress .dz-upload {
    background: #dc3545;
}

body.dark #formMessage.success {
    background-color: #28a745;
    color: #fff;
    border-color: #218838;
}

body.dark #formMessage.error {
    background-color: #dc3545;
    color: #fff;
    border-color: #c82333;
}

body.dark .legal-terms-container {
    color: #bbb;
}

body.dark .legal-terms-fade {
    background: linear-gradient(to top, rgba(51,51,51,1), rgba(51,51,51,0));
}

body.dark .legal-terms-toggle-btn {
    color: #4da3ff;
}

body.dark .legal-terms-toggle-btn:hover {
    color: #80bfff;
}

body.dark .smartnpv-link>a{
    color: #a9a9a9;
}
body.dark .text-muted{
    color: #b0b0b0;
}
