/* Основные стили календаря */
        * {
            box-sizing: border-box;
            margin: 0;
            padding: 0;
        }

        body {
            font-family: Arial, sans-serif;
            line-height: 1.6;
            color: #333;
            background-color: #f5f5f5;
            padding: 20px;
        }

        .calendar-container {
            display: flex;
            flex-direction: column;
            max-width: 900px;
            margin: 0 auto;
            background: white;
            border-radius: 8px;
            box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
            overflow: hidden;
        }

        @media (min-width: 768px) {
            .calendar-container {
                flex-direction: row;
            }
        }

        /* Стили для календаря */
        .calendar-section {
            flex: 1;
            padding: 20px;
        }

        .calendar-header {
            display: flex;
            justify-content: space-between;
            align-items: center;
            margin-bottom: 20px;
        }

        .calendar-nav {
            display: flex;
            gap: 10px;
        }

        .calendar-nav button {
            background: #115883;
            color: white;
            border: none;
            padding: 8px 12px;
            border-radius: 4px;
            cursor: pointer;
            transition: background 0.3s;
        }

        .calendar-nav button:hover {
            background: #0d4a6a;
        }

        .month-year-selector {
            display: flex;
            gap: 10px;
            margin-bottom: 20px;
        }

        .month-year-selector select {
            padding: 8px;
            border: 1px solid #ddd;
            border-radius: 4px;
            background: white;
        }

        .calendar-grid {
            display: grid;
            grid-template-columns: repeat(7, 1fr);
            gap: 1px;
            background-color: #ddd;
            border: 1px solid #ddd;
        }

        .calendar-day-header {
            background: #f0f0f0;
            padding: 10px;
            text-align: center;
            font-weight: bold;
        }

        .calendar-day {
            background: white;
            padding: 10px;
            min-height: 5px;
            cursor: pointer;
            transition: background 0.2s;
        }

        .calendar-day:hover {
            background: #f9f9f9;
        }

        .calendar-day.empty {
            background: #f9f9f9;
            cursor: default;
        }

        .calendar-day.today {
            background: #e6f7ff;
            border: 1px solid #91d5ff;
        }

        .calendar-day.has-event {
            background: #fff2e8;
            border: 1px solid #ffbb96;
        }

        .calendar-day.selected {
            background: #d6e4ff;
            border: 1px solid #85a5ff;
        }

        .day-number {
            font-weight: bold;
            margin-bottom: 5px;
        }

        .event-indicator {
            height: 8px;
            width: 8px;
            background-color: #ff4d4f;
            border-radius: 50%;
            display: inline-block;
            margin-right: 2px;
        }

        /* Стили для панели анонсов */
        .announcements-section {
            flex: 0 0 300px;
            background: #f9f9f9;
            padding: 20px;
            border-left: 1px solid #eee;
        }

        .announcements-list {
            margin-bottom: 20px;
            max-height: 400px;
            overflow-y: auto;
        }

        .announcement-item {
            background: white;
            padding: 15px;
            margin-bottom: 10px;
            border-radius: 4px;
            box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
            cursor: pointer;
            transition: all 0.3s ease;
        }

        .announcement-item:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
        }

        .announcement-title {
            font-weight: bold;
            margin-bottom: 5px;
            color: #115883;
        }

        .announcement-date {
            font-size: 0.9em;
            color: #666;
            margin-bottom: 8px;
        }

        .announcement-theme {
            font-size: 0.9em;
            color: #888;
            margin-bottom: 5px;
        }

        .announcement-location {
            font-size: 0.9em;
            color: #666;
        }

        .no-events-message {
            text-align: center;
            color: #666;
            font-style: italic;
            padding: 20px;
        }

        .nearest-events-header {
            color: #ff4d4f;
            font-weight: bold;
            margin-bottom: 10px;
            border-bottom: 1px solid #eee;
            padding-bottom: 5px;
        }

        .all-announcements-btn {
            background: #115883;
            color: white;
            border: none;
            padding: 10px 15px;
            border-radius: 4px;
            cursor: pointer;
            width: 100%;
            text-align: center;
            display: block;
            text-decoration: none;
        }

        .all-announcements-btn:hover {
            background: #0d4a6a;
        }

        /* Стили для модального окна */
        .modal-anons {
            display: none;
            position: fixed;
            top: 0;
            right: 0;
            bottom: 0;
            left: 0;
            background-color: rgba(0, 0, 0, 0.65);
            z-index: 1000;
            overflow-y: auto;
        }

        .modal-anons.active {
            display: block;
        }

        .modal-anons-content {
            position: relative;
            width: 90%;
            max-width: 600px;
            margin: 5% auto;
            border: 1px solid #115883;
            border-radius: 8px;
            background-color: white;
            font-family: Arial, sans-serif;
            color: #151515;
            box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
        }

        .modal-anons-header {
            background-color: #115883;
            color: white;
            padding: 20px;
            font-size: 18px;
            font-weight: bold;
            border-radius: 8px 8px 0 0;
            text-align: center;
        }

        .modal-anons-body {
            padding: 20px;
            font-size: 14px;
            line-height: 1.5;
        }

        .modal-anons-section {
            margin-bottom: 20px;
            padding-bottom: 15px;
            border-bottom: 1px solid #eee;
            text-align: center;
        }

        .modal-anons-section:last-child {
            border-bottom: none;
            margin-bottom: 0;
            padding-bottom: 0;
        }

        .modal-anons-title {
            font-size: 20px;
            font-weight: bold;
            color: #115883;
            margin-bottom: 15px;
            text-align: center;
            line-height: 1.3;
        }

        .modal-anons-theme {
            font-size: 16px;
            font-weight: 500;
            color: #2d3748;
            margin-bottom: 15px;
            text-align: center;
            line-height: 1.4;
        }

        .modal-anons-text {
            color: #4a5568;
            line-height: 1.6;
            text-align: center;
        }

        .modal-anons-children {
            color: #2d6ba6;
            line-height: 1.6;
            text-align: center;
            font-style: italic;
        }

        .modal-anons-meta {
            font-size: 14px;
            color: #718096;
            background-color: #f8f9fa;
            padding: 15px;
            border-radius: 6px;
            margin-top: 15px;
            text-align: center;
        }

        .modal-anons-meta div {
            margin-bottom: 8px;
        }

        .modal-anons-meta div:last-child {
            margin-bottom: 0;
        }

        .modal-anons-meta strong {
            color: #115883;
        }

        .modal-anons-images {
            margin-top: 20px;
        }

        .close-anons {
            position: absolute;
            right: 15px;
            top: 15px;
            width: 24px;
            height: 24px;
            opacity: 0.8;
            cursor: pointer;
            z-index: 1001;
        }

        .close-anons:hover {
            opacity: 1;
        }

        .close-anons:before, .close-anons:after {
            position: absolute;
            left: 11px;
            top: 3px;
            content: ' ';
            height: 18px;
            width: 2px;
            background-color: white;
        }

        .close-anons:before {
            transform: rotate(45deg);
        }

        .close-anons:after {
            transform: rotate(-45deg);
        }

        .modal-anons-footer {
            padding: 15px 20px;
            background-color: #f8f9fa;
            border-top: 1px solid #eee;
            border-radius: 0 0 8px 8px;
            text-align: center;
            font-size: 12px;
            color: #6c757d;
        }

        /* Стили для загрузки изображений */
        .lazy-image {
            transition: opacity 0.3s ease;
        }

        .image-loading {
            color: white;
            font-size: 18px;
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
        }

        /* Индикатор загрузки для изображений */
        .image-wrapper {
            position: relative;
            border-radius: 6px;
            overflow: hidden;
            box-shadow: 0 2px 8px rgba(0,0,0,0.1);
            transition: transform 0.3s ease, box-shadow 0.3s ease;
            background: #f8f9fa;
            display: flex;
            align-items: center;
            justify-content: center;
        }

        .image-wrapper::before {
            content: '';
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            width: 40px;
            height: 40px;
            border: 3px solid #f3f3f3;
            border-top: 3px solid #115883;
            border-radius: 50%;
            animation: spin 1s linear infinite;
            opacity: 0.7;
        }

        .image-wrapper img.loaded {
            opacity: 1;
        }

        .image-wrapper:hover {
            transform: translateY(-2px);
            box-shadow: 0 4px 15px rgba(0,0,0,0.2);
        }

        .image-wrapper img {
            width: 100%;
            height: auto;
            display: block;
            cursor: pointer;
        }

        @keyframes spin {
            0% { transform: translate(-50%, -50%) rotate(0deg); }
            100% { transform: translate(-50%, -50%) rotate(360deg); }
        }

        .images-container {
            display: grid;
            gap: 15px;
        }

        .no-images-message {
            text-align: center;
            color: #999;
            padding: 20px;
            font-style: italic;
        }

        /* Стили для модального окна с увеличенным изображением */
        .image-modal {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0,0,0,0.95);
            display: flex;
            justify-content: center;
            align-items: center;
            z-index: 2000;
            cursor: zoom-out;
        }

        .image-modal img {
            max-width: 95%;
            max-height: 95%;
            object-fit: contain;
            border-radius: 8px;
            box-shadow: 0 10px 30px rgba(0,0,0,0.5);
            cursor: zoom-in;
            transition: transform 0.3s ease;
        }

        .image-modal img.zoomed {
            transform: scale(1.5);
            cursor: zoom-out;
        }

        /* Кнопка закрытия для модального окна с изображением */
        .image-modal-close {
            position: absolute;
            top: 20px;
            right: 20px;
            width: 40px;
            height: 40px;
            background: rgba(255,255,255,0.1);
            border: none;
            border-radius: 50%;
            color: white;
            font-size: 24px;
            cursor: pointer;
            display: flex;
            align-items: center;
            justify-content: center;
            backdrop-filter: blur(10px);
            transition: background 0.3s ease;
            z-index: 2001;
        }

        .image-modal-close:hover {
            background: rgba(255,255,255,0.2);
        }

        /* Адаптивность для мобильных устройств */
        @media (max-width: 768px) {
            .images-container {
                grid-template-columns: 1fr !important;
            }
            
            .modal-anons-content {
                width: 95%;
                margin: 10% auto;
            }
            
            .modal-anons-header {
                padding: 15px;
                font-size: 16px;
            }
            
            .modal-anons-body {
                padding: 15px;
            }
            
            .modal-anons-title {
                font-size: 18px;
            }
            
            .modal-anons-theme {
                font-size: 14px;
            }
            
            .image-modal img {
                max-width: 98%;
                max-height: 98%;
            }
            
            .image-modal-close {
                top: 10px;
                right: 10px;
                width: 35px;
                height: 35px;
                font-size: 20px;
            }
        }

        /* Оптимизация для больших изображений */
        @media (min-width: 1200px) {
            .images-container {
                grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)) !important;
            }
        }

        /* Стили для плавного появления */
        .fade-in {
            animation: fadeIn 0.5s ease-in;
        }

        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }