/* יומן אירועים - עיצוב לאתר תיירות */
.ec-calendar-wrapper {
    font-family: 'Heebo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    direction: rtl;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 30px 0;
    box-sizing: border-box;
}

/* כותרת ונווט */
.ec-calendar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 25px;
    border-bottom: 2px solid #e8f4f8;
}

.ec-view-switcher {
    display: flex;
    gap: 8px;
    background: #f0f7fa;
    padding: 6px;
    border-radius: 12px;
}

.ec-view-btn {
    padding: 12px 24px;
    background: transparent;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    color: #5a7184;
    transition: all 0.3s ease;
    font-weight: 600;
    font-size: 14px;
}

.ec-view-btn:hover {
    background: rgba(255,255,255,0.8);
    color: #799e36;
}

.ec-view-btn.active {
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(121, 158, 54, 0.3);
}

.ec-navigation {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-direction: row-reverse;
}

.ec-nav-btn {
    width: 45px;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    color: white;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    text-decoration: none;
    font-size: 24px;
    font-weight: bold;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(121, 158, 54, 0.25);
}

.ec-nav-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(121, 158, 54, 0.35);
}

.ec-nav-btn span {
    margin: -5px 0 0;
}

.ec-current-date {
    font-size: 22px;
    font-weight: 700;
    color: #222;
    min-width: 220px;
    text-align: center;
    letter-spacing: -0.5px;
}

/* תצוגה יומית */
.ec-day-view {
    padding: 25px;
}

.ec-day-view h2 {
    color: #222;
    margin-bottom: 25px;
    font-size: 26px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 12px;
}

.ec-day-view h2::before {
    content: '📅';
    font-size: 28px;
}

.ec-events-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.ec-event-item {
    display: flex;
    gap: 20px;
    padding: 0;
    background: #ffffff;
    border-radius: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    border: 1px solid #e8f4f8;
    overflow: hidden;
}

.ec-event-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.1);
}

.ec-event-image {
    flex-shrink: 0;
    width: 120px;
}

.ec-event-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ec-event-details {
    flex: 1;
    display: flex;
    flex-direction: row;
    align-items: center;
    padding: 20px;
    gap: 20px;
}

.ec-event-content {
    flex: 1;
}

.ec-event-time {
    font-weight: 700;
    color: #799e36;
    font-size: 18px;
    min-width: 90px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #f0f5e8 0%, #f5f8ed 100%);
    border-radius: 10px;
    text-align: center;
    height: fit-content;
}

.ec-event-content {
    flex: 1;
}

.ec-event-content .ec-event-title {
    margin: 0 0 10px;
    font-size: 18px;
    font-weight: 600;
    color: #222;
}

.ec-event-description {
    margin: 0 0 15px 0;
    color: #5a7184;
    line-height: 1.7;
    font-size: 14px;
}

.ec-event-link {
    color: #fff;
    text-decoration: none;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    padding: 10px 24px;
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    border-radius: 25px;
    font-size: 14px;
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(121, 158, 54, 0.3);
    white-space: nowrap;
}

.ec-event-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(121, 158, 54, 0.4);
    background: linear-gradient(135deg, #5a7528 0%, #3d4f1c 100%);
    color: white;
}

.ec-no-events {
    text-align: center;
    padding: 60px 40px;
    color: #a0aec0;
    font-size: 18px;
    background: #f8fafc;
    border-radius: 16px;
}

.ec-no-events::before {
    content: '🌴';
    display: block;
    font-size: 48px;
    margin-bottom: 15px;
}

/* תצוגה שבועית */
.ec-week-view {
    padding: 25px;
}

.ec-week-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 12px;
}

.ec-week-day {
    background: #ffffff;
    border-radius: 16px;
    overflow: visible;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
    border: 1px solid #e8f4f8;
    transition: all 0.3s ease;
}

.ec-week-day:hover {
    box-shadow: 0 8px 25px rgba(0,0,0,0.08);
    transform: translateY(-2px);
}

/* יום שעבר בתצוגה שבועית */
.ec-week-day.ec-past-day {
    opacity: 0.5;
}

.ec-week-day.ec-past-day .ec-day-header {
    background: linear-gradient(135deg, #999 0%, #777 100%);
}

.ec-week-day.ec-past-day:hover {
    transform: none;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.ec-day-header {
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    color: white;
    padding: 16px 12px;
    text-align: center;
}

.ec-day-name {
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ec-day-number {
    font-size: 13px;
    opacity: 0.9;
}

.ec-day-events {
    min-height: 150px;
    padding: 10px;
}

.ec-mini-event {
    padding: 10px 12px;
    background: white;
    border-radius: 10px;
    margin-bottom: 8px;
    font-size: 13px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-decoration: none;
    transition: all 0.2s ease;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05);
}

.ec-mini-event:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.ec-mini-event .ec-event-time {
    font-size: 11px;
    color: #799e36;
    font-weight: 600;
    background: transparent;
    padding: 0;
    min-width: auto;
}

.ec-mini-event .ec-event-title {
    color: #222;
    font-weight: 400;
    font-size: 13px;
    line-height: 1.2;
}

.ec-more-events {
    display: block;
    text-align: center;
    padding: 10px;
    background: linear-gradient(135deg, #f0f5e8 0%, #f5f8ed 100%);
    color: #799e36;
    text-decoration: none;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.ec-more-events:hover {
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    color: white;
}

/* תצוגה חודשית */
.ec-month-view {
    padding: 25px 0;
    width: 100%;
    box-sizing: border-box;
}

.ec-month-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 3px;
    background: #e8f4f8;
    border-radius: 16px;
    width: 100%;
    box-sizing: border-box;
    overflow: visible;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
}

.ec-weekday-header {
    background: linear-gradient(135deg, #799e36 0%, #5a7528 100%);
    color: white;
    padding: 16px;
    text-align: center;
    font-weight: 700;
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.ec-month-day {
    background: white;
    min-height: 120px;
    padding: 12px;
    position: relative;
    transition: all 0.2s ease;
    box-sizing: border-box;
    min-width: 0;
}

.ec-month-day:hover {
    background: #f8fafc;
}

.ec-month-day.ec-empty-day {
    background: #f8fafc;
}

.ec-month-day.ec-today {
    background: #f5f5f5;
}

/* ימים שעברו - אפורים ולא פעילים */
.ec-month-day.ec-past-day {
    background: #f8f8f8;
    opacity: 0.6;
}

.ec-month-day.ec-past-day .ec-day-number {
    color: #999;
}

.ec-month-day.ec-past-day:hover {
    background: #f8f8f8;
}

/* אירועים שעברו */
.ec-past-event {
    cursor: default;
    opacity: 0.7;
}

.ec-past-event:hover {
    transform: none !important;
    box-shadow: 0 1px 4px rgba(0,0,0,0.05) !important;
}

.ec-past-event .ec-event-title {
    color: #888 !important;
}

.ec-month-day .ec-day-number {
    font-weight: 700;
    color: #222;
    margin-bottom: 10px;
    font-size: 16px;
}

.ec-month-day.ec-today .ec-day-number {
    color: #799e36;
    font-size: 20px;
    position: relative;
}

.ec-month-day.ec-today .ec-day-number::after {
    content: '•';
    color: #799e36;
    margin-right: 5px;
}

.ec-month-day .ec-day-events {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.ec-month-day .ec-mini-event {
    padding: 6px 10px;
    background: #f0f9ff;
    border-radius: 8px;
    font-size: 12px;
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.ec-month-day .ec-mini-event:hover {
    transform: scale(1.02);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.ec-month-day .ec-mini-event .ec-event-title {
    color: #222;
    flex: 1;
}

.ec-more-link {
    display: block;
    text-align: center;
    padding: 6px;
    color: #799e36;
    text-decoration: none;
    font-size: 12px;
    font-weight: 600;
    margin-top: 6px;
    background: #f0f5e8;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.ec-more-link:hover {
    background: #799e36;
    color: white;
}

/* Tooltip מותאם עם תמונה */
.ec-has-tooltip {
    position: relative;
}

.ec-has-tooltip:hover {
    z-index: 100;
}

.ec-month-day:has(.ec-has-tooltip:hover),
.ec-week-day:has(.ec-has-tooltip:hover) {
    z-index: 100;
}

.ec-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 5px);
    right: 50%;
    transform: translateX(50%);
    width: 150px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    border: 1px solid #e0e0e0;
    z-index: 1000;
    overflow: hidden;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.ec-has-tooltip:hover .ec-tooltip {
    display: block;
    opacity: 1;
}

.ec-tooltip img {
    width: 100%;
    height: auto;
    display: block;
}

.ec-tooltip-content {
    padding: 12px;
    background: #ffffff;
}

.ec-tooltip-content strong {
    display: block;
    font-size: 13px;
    color: #1a1a1a;
    margin-bottom: 6px;
    line-height: 1.4;
    font-weight: 600;
}

.ec-tooltip-content p {
    font-size: 12px;
    color: #444444;
    margin: 0;
    line-height: 1.5;
}

.ec-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: white;
}

/* מודל פרטי אירוע */
.ec-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    right: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
}

.ec-modal-content {
    background: white;
    margin: 50px auto;
    padding: 30px;
    border-radius: 8px;
    max-width: 600px;
    position: relative;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.ec-modal-close {
    position: absolute;
    left: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    color: #999;
    cursor: pointer;
    transition: color 0.3s;
}

.ec-modal-close:hover {
    color: #333;
}

.ec-modal-title {
    color: #799e36;
    margin-bottom: 15px;
    font-size: 24px;
}

.ec-modal-date {
    color: #666;
    margin-bottom: 20px;
    font-size: 16px;
}

.ec-modal-description {
    color: #333;
    line-height: 1.8;
    font-size: 16px;
}

/* רספונסיבי - טאבלט */
@media (max-width: 1024px) {
    .ec-week-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .ec-month-grid {
        grid-template-columns: repeat(7, 1fr);
    }
}

/* רספונסיבי - מובייל גדול */
@media (max-width: 768px) {
    .ec-calendar-wrapper {
        padding: 15px;
        border-radius: 0;
        box-shadow: none;
    }

    .ec-calendar-header {
        flex-direction: column;
        gap: 15px;
        padding-bottom: 15px;
        margin-bottom: 20px;
    }

    .ec-view-switcher {
        width: 100%;
        justify-content: center;
        order: 2;
    }

    .ec-view-btn {
        flex: 1;
        text-align: center;
        padding: 12px 10px;
        font-size: 14px;
    }

    .ec-navigation {
        width: 100%;
        justify-content: space-between;
        order: 1;
    }

    .ec-current-date {
        font-size: 16px;
        min-width: auto;
    }

    .ec-nav-btn {
        padding: 10px 15px;
        font-size: 16px;
    }

    /* תצוגה שבועית - 2 עמודות */
    .ec-week-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }

    .ec-week-day {
        border-radius: 10px;
    }

    .ec-day-header {
        padding: 12px 8px;
    }

    .ec-day-name {
        font-size: 13px;
    }

    .ec-day-events {
        padding: 8px;
        min-height: 100px;
    }

    .ec-mini-event {
        padding: 10px;
        font-size: 13px;
        border-radius: 6px;
    }

    /* תצוגה חודשית - רשימה אנכית */
    .ec-month-view {
        padding: 10px;
    }

    .ec-month-grid {
        display: flex;
        flex-direction: column;
        gap: 2px;
        background: transparent;
        border: none;
    }

    .ec-weekday-header {
        display: none;
    }

    .ec-month-day {
        min-height: auto;
        padding: 12px 15px;
        border-radius: 8px;
        margin-bottom: 5px;
        border: 1px solid #e0e0e0;
        display: flex;
        align-items: flex-start;
        gap: 15px;
    }

    .ec-month-day.ec-empty-day {
        display: none;
    }

    .ec-month-day .ec-day-number {
        min-width: 45px;
        font-size: 18px;
        font-weight: 700;
        color: #799e36;
        margin-bottom: 0;
    }

    .ec-month-day .ec-day-number::after {
        content: attr(data-weekday);
        display: block;
        font-size: 11px;
        font-weight: 400;
        color: #666;
    }

    .ec-month-day.ec-today {
        background: #f0f5e8;
        border-color: #799e36;
    }

    /* ימים שעברו במובייל */
    .ec-month-day.ec-past-day {
        background: #f5f5f5;
        border-color: #e0e0e0;
        opacity: 0.5;
    }

    .ec-month-day.ec-past-day .ec-day-number {
        color: #aaa;
    }

    .ec-month-day .ec-day-events {
        flex: 1;
        padding: 0;
        min-height: auto;
        gap: 6px;
    }

    .ec-month-day .ec-mini-event {
        padding: 8px 10px;
        font-size: 13px;
        background: #f5f5f5;
        border-radius: 6px;
    }

    .ec-month-day .ec-mini-event .ec-event-title {
        white-space: normal;
    }

    /* תצוגה יומית */
    .ec-day-view {
        padding: 10px;
    }

    .ec-day-view h2 {
        font-size: 20px;
        text-align: center;
    }

    .ec-event-item {
        flex-direction: column;
        gap: 10px;
        padding: 15px;
    }

    .ec-event-time {
        font-size: 14px;
        min-width: auto;
    }

    .ec-event-title {
        font-size: 16px !important;
    }

    .ec-event-description {
        font-size: 14px;
    }

    .ec-no-events {
        font-size: 16px;
        padding: 30px;
    }
}

/* רספונסיבי - מובייל קטן */
@media (max-width: 480px) {
    .ec-calendar-wrapper {
        padding: 10px;
    }

    .ec-view-switcher {
        gap: 5px;
    }

    .ec-view-btn {
        padding: 10px 8px;
        font-size: 13px;
    }

    .ec-nav-btn {
        padding: 8px 12px;
        font-size: 14px;
    }

    .ec-current-date {
        font-size: 14px;
    }

    /* תצוגה שבועית - עמודה אחת */
    .ec-week-grid {
        grid-template-columns: 1fr;
    }

    .ec-week-day {
        display: flex;
        flex-direction: row;
        align-items: stretch;
    }

    .ec-day-header {
        writing-mode: horizontal-tb;
        min-width: 80px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
    }

    .ec-day-events {
        flex: 1;
        min-height: 80px;
    }

    .ec-month-day {
        padding: 10px 12px;
    }

    .ec-month-day .ec-day-number {
        min-width: 40px;
        font-size: 16px;
    }

    .ec-month-day .ec-mini-event {
        padding: 6px 8px;
        font-size: 12px;
    }

    .ec-event-item {
        padding: 12px;
    }

    .ec-event-title {
        font-size: 15px !important;
    }
}

/* התאמות למובייל - ביטול tooltip */
@media (max-width: 768px) {
    .ec-tooltip {
        display: none !important;
    }
}

/* שם סוג האירוע */
a.ec-event-type-label,
.ec-event-type-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
    text-decoration: none;
    transition: opacity 0.2s;
}
a.ec-event-type-label:hover {
    opacity: 0.7;
    text-decoration: underline;
}

.ec-event-type-mini {
    display: block;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-bottom: 2px;
    opacity: 0.9;
}

.ec-tooltip-type {
    display: block;
    font-size: 11px;
    font-weight: 600;
    margin-bottom: 4px;
}

/* תוכן אירוע בפוסט */
.ec-post-event-content {
    background: linear-gradient(135deg, #f8fdf5 0%, #e8f4e8 100%);
    border-right: 4px solid #799e36;
    padding: 20px 25px;
    margin-bottom: 30px;
    border-radius: 0 12px 12px 0;
    box-shadow: 0 2px 10px rgba(121, 158, 54, 0.1);
}

.ec-post-event-content .ec-event-type-badge {
    display: inline-block;
    background: #799e36;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 10px;
}

.ec-post-event-content .ec-event-time-badge {
    display: inline-block;
    background: rgba(121, 158, 54, 0.15);
    color: #5a7528;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    margin-right: 8px;
    margin-bottom: 10px;
}

.ec-post-event-content .ec-event-description-content {
    font-size: 16px;
    line-height: 1.7;
    color: #333;
}

.ec-post-event-content .ec-event-description-content img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin: 15px 0;
}

.ec-post-event-content .ec-event-custom-title {
    font-size: 22px;
    font-weight: 700;
    color: #333;
    margin: 12px 0 10px;
    line-height: 1.3;
}

/* אנימציית טעינה */
#ec-loader-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.85);
    z-index: 9999;
}

.ec-loader-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.ec-loader-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #e8f4f8;
    border-top: 4px solid #799e36;
    border-radius: 50%;
    animation: ec-spin 0.8s linear infinite;
    margin: 0 auto 15px;
}

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

.ec-loader-text {
    color: #5a7184;
    font-size: 16px;
    font-weight: 600;
}

/* ===== רשימת סוגי אירועים ===== */
.ec-event-types-list {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    padding: 20px 0;
}

.ec-event-type-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 25px;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.ec-event-type-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

.ec-type-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    flex-shrink: 0;
}

.ec-type-name {
    font-size: 14px;
}

.ec-type-count {
    font-size: 12px;
    color: #888;
    margin-right: 4px;
}
