@media (max-width: 768px) {
    .school-banner {
        position: relative;
        width: 100%;
        min-height: 450px;
        background: linear-gradient(145deg, #0a2f6c 0%, #041a3b 100%);
        overflow: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
        border-radius: 20px;
        margin: 20px 0;
        box-shadow: 0 8px 20px rgba(0,0,0,0.2);
		gap: 0px;
		flex-direction: column;
    }}
    /* Базовые стили для баннера */
@media (min-width: 768px) {
    .school-banner {
        position: relative;
        width: 100%;
        min-height: 450px;
        background: linear-gradient(145deg, #0a2f6c 0%, #041a3b 100%);
        overflow: hidden;
        display: flex;

        
        border-radius: 20px;
        margin: 20px 0;
        box-shadow: 0 8px 20px rgba(0,0,0,0.2);
		gap: 0px;
    }}
@media (min-width: 768px) {
    .banner-content {
        position: relative;
        z-index: 20;
        text-align: center;
        color: #000000;
        /*text-shadow: 0 2px 10px rgba(0,0,0,0.5);*/
        padding: 30px;
        background-color: rgb(255 255 255 / 61%);
        border-radius: 20px;
        backdrop-filter: blur(5px);
        max-width: 80%;
		margin: 20px 20px;
    }}
@media (min-width: 1620px) {
    .banner-content {
		width: 20%;
    }}
@media (min-width: 768px) and (max-width: 1620px)  {
    .banner-content {
		width: 300px;
    }}
@media (max-width: 768px) {
    .banner-content {
        position: relative;
        z-index: 20;
        text-align: center;
        color: #000000;
        /*text-shadow: 0 2px 10px rgba(0,0,0,0.5);*/
        padding: 30px;
        background-color: rgb(255 255 255 / 61%);
        border-radius: 20px;
        backdrop-filter: blur(5px);
        max-width: 100%;
		margin: 30px 20px;
        width: -webkit-fill-available;
    }}
    .banner-content-kvant {
        position: relative;
        z-index: 20;
        text-align: center;
        color: white;
        text-shadow: 0 2px 10px rgba(0,0,0,0.5);
        padding: 20px;
        background-color: rgb(255 255 255 / 30%);
        border-radius: 20px;
        backdrop-filter: blur(5px);
		margin-bottom: 30px;
		display: flex;
    align-items: center;
		gap: 10px;
		margin: 20px 20px;
    }
@media (max-width: 768px) {
.banner-content-kvant-blok {
	width: 100%;
	margin: 0px 0px;
}}
@media (min-width: 768px) {
.banner-content-kvant-blok {
	width: 250px;
	margin: 30px 0px;
}}
.banner-content-kvant-baner {
    position: relative;
    z-index: 20;
    text-align: center;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    padding: 30px;
    background-color: rgb(255 255 255 / 70%);
    border-radius: 20px;
    backdrop-filter: blur(5px);
    max-width: 100%;
    display: flex;
    align-items: center;
	height: fit-content;
}
@media (min-width: 1200px) {
.banner-content-kvant-baner {
margin: 20px 20px 20px 0px;
width: 70%;
}
.kvantorium-item-teacher {
        white-space: nowrap;
}}
@media (min-width: 1350px) and (max-width: 1700px) {
.news-excerpt {
		display: none;
}}
@media (min-width: 768px) and (max-width: 1200px) {
	.kvantorium-item-teacher {
		white-space: nowrap;
	}
	.schedule-list li {
        white-space: normal !important;
    }
	.top-actions {
		display: none;
	}
	.right-sidebar {
		width: 230px !important;
	}
	.link-card {
		padding: 8px 15px;
		line-height: 20px;
	}
.banner-content-kvant-baner {
margin: 0px 20px 20px 20px;
	width: 45%;
}
	.school-banner {
		flex-wrap: wrap;
	}
	.banerrrr {
		width: 58%;
	}}
@media (max-width: 768px) {
.banner-content-kvant-baner {
margin: 0px 20px 20px 20px;


}}
.banner-content h1 {
    font-size: 2rem;
    margin: 20px 0 10px;
    color: #000000;
	white-space: nowrap;
	
}
.school-logo {
    height: auto;
    margin-bottom: 15px;
    filter: drop-shadow(0 2px 5px rgba(0,0,0,0.3));
}
@media (min-width: 768px) {
.school-logo {
    max-width: 80%;
}}
@media (max-width: 768px) {
.school-logo {
    max-width: 60%;
}}
.school-logo-kvant {
	max-width: 50px;
        height: auto;
        margin-bottom: 0px;
        filter: drop-shadow(0 2px 5px rgba(0,0,0,0.3));
}
@media (min-width: 768px) {
.school-logo-kvant-baner {
	max-width: 100%;
        height: auto;
        margin-bottom: 0px;
        filter: drop-shadow(0 2px 5px rgba(0,0,0,0.3));
}}
@media (max-width: 768px) {
.school-logo-kvant-baner {
	max-width: 100%;;
        height: auto;
        margin-bottom: 0px;
        filter: drop-shadow(0 2px 5px rgba(0,0,0,0.3));
}}
@media (min-width: 768px) {
.flag-russia-css {
	    width: 200px;
        height: 120px;
}}
@media (max-width: 768px) {
.flag-russia-css {
	width: 90%;
    height: 200px;
	top: 100px !important;
}}
.flag-russia-css {
        position: absolute;
        left: 5%;
        top: 20%;
        filter: drop-shadow(0 10px 15px rgba(0,0,0,0.4));
        animation: floatFlag 7s ease-in-out infinite;
        z-index: 5;
}
    .flag-stripe {
        width: 100%;
        height: 33.333%;
    }
    .white-stripe { background-color: #FFFFFF; }
    .blue-stripe { background-color: #0039A6; }
    .red-stripe { background-color: #D52B1E; }
/* === ПРАВЫЙ УЗКИЙ БЛОК === */
.two-column-layout {
    display: flex;
    gap: 30px;
    align-items: flex-start; /* чтобы блоки не растягивались по высоте */
    margin: 40px 0;
}
@media (min-width: 768px) {
.two-column-layout {
    padding-left: 5%;
    padding-right: 5%;
}}
@media (max-width: 768px) {
.two-column-layout {
    padding-left: 2%;
    padding-right: 2%;
}}
.left-blocks {
    flex: 1; /* занимает оставшееся пространство */
    min-width: 0;
}
@media (max-width: 768px) {
.left-blocks {
 width: 100%;
}}
.right-sidebar {
    width: 300px;  /* фиксированная узкая ширина */
    flex-shrink: 0;
    position: relative;
    border-radius: 30px;
    background: linear-gradient(135deg, #616161 0%, #35495c 100%);
    padding: 20px 15px;
    overflow: hidden; 
    overflow-y: auto;         /* вертикальная прокрутка на десктопе */
}
.right-sidebar-inner {
    position: relative;
    z-index: 2;
}
@media (min-width: 768px) {
.right-sidebar-inner {
	padding: 0% 5%;
}}
.right-sidebar .info-title {
    font-size: 22px;
    margin-bottom: 15px;
    border-bottom: 2px solid rgba(255,255,255,0.3);
    display: inline-block;
    padding-bottom: 5px;
	color: aliceblue;
}

/* Карточки внутри правого блока (вертикальная стопка) */
.horizontal-scroll-wrapper {
    display: flex;
    flex-direction: column;   /* вертикально */
    gap: 15px;
}
.scroll-card {
    background: rgba(255,255,255,0.12);
    backdrop-filter: blur(24px);
    border-radius: 16px;
    padding-top: 15px;
    transition: 0.2s;
}
.scroll-card:hover {
    background: rgba(255,255,255,0.25);
    transform: translateX(3px);
}
.scroll-card-date {
    font-size: 15px;
    opacity: 0.7;
    margin-bottom: 5px;
	color: #000000;
}
.scroll-card-title {
    font-size: 1.2rem;
    font-weight: 400;
    padding: 8px 0px;
    color: aliceblue;
    width: 100%;
    text-align: center;
    background: #383939;
    border-radius: 0px 0px 15px 15px;
    margin-top: -5px;
}
.scroll-card-text {
    font-size: 13px;
    line-height: 1.4;
    opacity: 0.9;
}

/* Скрываем вертикальный скролл на десктопе (но он работает) */
.right-sidebar::-webkit-scrollbar {
    width: 4px;
}
.right-sidebar::-webkit-scrollbar-track {
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
}
.right-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.4);
    border-radius: 10px;
}

/* === АДАПТИВ: мобилки === */
@media (max-width: 768px) {
    .two-column-layout {
        flex-direction: column;
    }
    .right-sidebar {
        order: -1;
        width: 100%;
        max-height: none;      /* убираем ограничение высоты */
        overflow-y: visible;
        margin-bottom: 30px;
        padding: 0px;
    }
    /* На мобилках горизонтальный скролл */
    .horizontal-scroll-wrapper {
        flex-direction: row;
        overflow-x: auto;
        gap: 15px;
        padding-bottom: 15px;
        
        -webkit-overflow-scrolling: touch;
		padding: 20px;
    }
    .scroll-card {
        flex: 0 0 260px;
        scroll-snap-align: start;
        height: fit-content;
    }
    .right-sidebar .info-title {
        font-size: 24px;
		margin: 20px;
    }
}
/* Новости с картинками */
.news-item {
    display: flex;
    gap: 15px;
    align-items: center;
    text-decoration: none;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px;
    transition: all 0.2s ease;
    margin-bottom: 10px;
	flex-direction: row;
}
.news-item-ac {
    display: flex;
    gap: 0px;
    align-items: center;
    text-decoration: none;
    border-radius: 16px;
    flex-direction: column;
}
.news-thumb {
    width: 85%;
    height: 200px;
    margin-top: 15px;
    object-fit: cover;
    border-radius: 12px;
    background: rgba(0,0,0,0.2);
    opacity: 0.9;
}
.news-thumb-ac {
    width: 180px;
	height: 180px;
    object-fit: contain;
    border-radius: 12px;
    background: rgba(0,0,0,0.2);
    opacity: 0.9;
}
.news-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
	padding: 20px !important;
}
.news-date {
    display: block;
    font-size: 12px;
    opacity: 0.7;
    margin-bottom: 4px;
}
.news-text {
    font-size: 14px;
    line-height: 1.3;
}
/* Блоки информации (новости + ссылки) */
.info-block {
    padding: 20px 0;
    margin: 30px 0;
    border-radius: 30px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}
.info-block-blue {
    background: linear-gradient(135deg, #335083 0%, #041a3d 100%);
    color: #fff;
}
.info-block-inner {
    display: flex;
    gap: 40px;
    flex-wrap: wrap;
}
/* Адаптивность */
@media (max-width: 768px) {
    .info-block-inner {
        flex-direction: column;
        gap: 30px;
		padding-left: 2%;
		padding-right: 2%;
    }
    .links-grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    }
    .info-title {
        font-size: 24px;
    }
}
/* Блок 3 - серо-голубой оттенок */
.info-block {
    position: relative;
    overflow: hidden;
}
/* Анимированные слои (будут позади контента) */
.animated-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}
/* ========== БЛОК 1 (СИНИЙ) — ДВИЖУЩАЯСЯ СЕТКА ========== */
.info-block-blue .animated-bg {
    background-image: 
        linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 40px 40px;
    animation: moveGrid 20s linear infinite;
}
@keyframes moveGrid {
    0% { transform: translate(0, 0); }
    100% { transform: translate(40px, 40px); }
}
/* ========== БЛОК 2 (ФИОЛЕТОВЫЙ) — ПЛАВАЮЩИЕ КРУГИ ========== */
/* ========== БЛОК 3 (СЕРЫЙ) — МЕРЦАЮЩИЕ ТОЧКИ ========== */
/* Фоновый канвас для синего блока */
.info-block-blue {
    position: relative;
    overflow: hidden;
}
.animated-bg-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none; /* чтобы не мешать кликам по кнопкам */
}
.info-left, .info-right {
    flex: 1;
    min-width: 250px;
}
@media (max-width: 768px) {
.info-left {
width: 100%;
}}
.info-title {
    font-size: 28px;
    margin-bottom: 25px;
    font-weight: 600;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
    border-bottom: 3px solid rgba(255,255,255,0.3);
	line-height: 25px;
}
/* Новости (список) */
@media (min-width: 768px) {
.news-list {
    display: flex;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    gap: 15px;
    margin-bottom: 0px;
    flex-wrap: wrap;
    flex-direction: row;
}}
@media (max-width: 768px) {
.news-list {
    display: -webkit-box;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    gap: 15px;
    margin-bottom: 0px;
    margin-right: -20px;
    margin-left: -20px;
    padding-left: 20px;
    padding-right: 20px;
}}
.news-item {
    display: flex;
    gap: 0px;
    padding: 0px 0px !important;
    background: #3c5175 !important;
    border-radius: 12px;
    transition: all 0.3s ease;
    text-decoration: none;
    color: #ffffff;
    align-items: center;
    flex-direction: column;
    height: auto;
}
@media (min-width: 1860px) {
.news-item {
	width: 46%;
	min-width: 260px;
}}
@media (min-width: 1675px) and (max-width: 1860px) {
.news-item {
	width: 46%;
	min-width: 260px;
}}
@media (min-width: 1470px) and (max-width: 1675px) {
.news-item {
	width: 46%;
	min-width: 220px;
}}
@media (min-width: 1350px) and (max-width: 1470px) {
.news-item {
	width: 46%;
	min-width: 180px;
}}
@media (min-width: 768px) and (max-width: 1350px) {
.news-item {
	width: 100%;
}}
@media (max-width: 768px) {
.news-item {
	width: 250px;
	margin-right: 20px;
}}
.news-date {
    font-size: 13px;
    background: rgb(27 52 95);
    color: aliceblue;
    padding: 3px 8px 0px 8px;
    border-radius: 20px;
    white-space: nowrap;
}
.news-text {
    font-size: 16px;
    line-height: 1.3;
}
.all-news-link {
    display: inline-block;
    margin-top: 10px;
    color: #ffd966;
    text-decoration: none;
    font-weight: 500;
    transition: 0.2s;
}
.all-news-link:hover {
    color: #fff;
    text-decoration: underline;
}
/* Сетка важных ссылок (плитки) */
.links-grid {
	display: flex;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
    flex-direction: row;
    flex-wrap: wrap;
}
.link-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(4px);
    padding: 14px 12px;
    border-radius: 16px;
    text-align: left;
    text-decoration: none;
    color: #fff;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid rgba(255, 255, 255, 0.2);
}
.link-card:hover {
    background: rgba(255,255,255,0.3);
    transform: translateY(-3px);
    box-shadow: 0 5px 12px rgba(0,0,0,0.2);
}
/* Сетка плашек (4 штуки) */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 10px;
}
.info-card {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(4px);
    border-radius: 20px;
    padding: 20px 15px;
    text-decoration: none;
    color: #fff;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.2);
    text-align: center;
}
.info-card:hover {
    background: rgba(255,255,255,0.25);
    transform: translateY(-5px);
}
.card-icon {
    font-size: 40px;
    margin-bottom: 12px;
}
.card-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 10px;
}
.card-desc {
    font-size: 13px;
    line-height: 1.4;
    opacity: 0.9;
}
/* Плашка СВО (можно выделить цветом) */
.info-card-svo {
    background: rgba(220, 53, 69, 0.2);
    border-color: rgba(255, 100, 100, 0.5);
}
/* Список внешних ссылок */
.external-links {
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.external-links a {
    display: block;
    padding: 12px 15px;
    background: rgba(255,255,255,0.1);
    border-radius: 12px;
    text-decoration: none;
    color: #fff;
    transition: all 0.2s;
    border-left: 4px solid #ffd966;
}

.external-links a:hover {
    background: rgba(255,255,255,0.25);
    transform: translateX(5px);
}
/* Адаптивность для планшетов и мобилок */
@media (max-width: 768px) {
    .cards-grid {
        grid-template-columns: 1fr;
    }
}
    /* Контент поверх анимации */
    /* CSS Флаг России */
    /* Анимация пархающего флага */
    @keyframes floatFlag {
        0% { transform: translateY(0px) translateX(0px) rotate(0deg); }
        25% { transform: translateY(-15px) translateX(10px) rotate(3deg); }
        50% { transform: translateY(0px) translateX(-10px) rotate(-3deg); }
        75% { transform: translateY(15px) translateX(5px) rotate(2deg); }
        100% { transform: translateY(0px) translateX(0px) rotate(0deg); }
    }

    /* Стили для фоновых звёзд (мерцают, не падают) - УВЕЛИЧЕННЫЕ */
    .bg-star {
        position: absolute;
        background-color: #fff;
        border-radius: 50%;
        opacity: 0;
        animation: twinkle ease-in-out infinite alternate;
        z-index: 2;
        pointer-events: none;
        box-shadow: 0 0 6px rgba(255,255,255,0.6);
    }

    @keyframes twinkle {
        0% { opacity: 0; transform: scale(0.8); }
        50% { opacity: 1; transform: scale(1.4); }
        100% { opacity: 0.4; transform: scale(1); }
    }

    /* Стили для падающих звёзд */
    .shooting-star {
        position: absolute;
        z-index: 3;
        pointer-events: none;
    }

    /* Яркая звезда (крупный шарик) */
    .shooting-star-core {
        position: absolute;
        width: 10px;
        height: 10px;
        background-color: #fff;
        border-radius: 50%;
        box-shadow: 0 0 20px rgba(255, 255, 255, 1), 0 0 30px rgba(255, 200, 100, 0.8);
        z-index: 4;
    }

    /* Хвост звезды (тянется за шариком, яркий у основания) */
    .shooting-star-tail {
    }

    @keyframes shoot {
        0% {
            opacity: 0;
            transform: translateX(0) translateY(0) scale(0.8);
        }
        5% {
            opacity: 1;
            transform: translateX(0) translateY(0) scale(1);
        }
        100% {
            opacity: 0;
            transform: translateX(-300px) translateY(150px) scale(0.6);
        }
    }
.cards-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 20px;
    justify-content: space-between;
}

.info-card {
    flex: 1;
    min-width: 250px;
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.2s, box-shadow 0.2s;
    text-decoration: none;
    color: #333;
}

/* На мобильных устройствах карточки будут в колонку */
@media (max-width: 768px) {
    .cards-grid {
        flex-direction: column;
    }
    .info-card {
        flex: auto;
    }
}




#js-show-iframe-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-width: 293px;
    max-width: 100%;
    background: linear-gradient(138.4deg, #38bafe 26.49%, #2d73bc 79.45%);
    color: #fff;
    cursor: pointer;
	border-radius: 20px;
}
#js-show-iframe-wrapper .pos-banner-fluid * {
    box-sizing: border-box;
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2 {
    display: block;
    width: 240px;
    min-height: 56px;
    font-size: 18px;
    line-height: 24px;
    cursor: pointer;
    background: #0d4cd3;
    color: #fff;
    border: none;
    border-radius: 8px;
    outline: 0;
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:hover {
    background: #1d5deb;
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:focus {
    background: #2a63ad;
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:active {
    background: #2a63ad;
}
@-webkit-keyframes fadeInFromNone {
    0% { display: none; opacity: 0; }
    1% { display: block; opacity: 0; }
    100% { display: block; opacity: 1; }
}
@keyframes fadeInFromNone {
    0% { display: none; opacity: 0; }
    1% { display: block; opacity: 0; }
    100% { display: block; opacity: 1; }
}

#js-show-iframe-wrapper {
    background: var(--pos-banner-fluid-18__background);
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2 {
    width: 100%;
    min-height: 52px;
    background: #fff;
    color: #0b1f33;
    font-size: 16px;
    font-family: 'MyCustomFont2';
    font-weight: 400;
    padding: 0;
    line-height: 1.2;
}
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:active,
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:focus,
#js-show-iframe-wrapper .pos-banner-fluid .pos-banner-btn_2:hover {
    background: #e4ecfd;
}
#js-show-iframe-wrapper .bf-18 {
    position: relative;
    display: grid;
    grid-template-columns: var(--pos-banner-fluid-18__grid-template-columns);
    grid-template-rows: var(--pos-banner-fluid-18__grid-template-rows);
    width: 100%;
    max-width: var(--pos-banner-fluid-18__max-width);
    box-sizing: border-box;
    grid-auto-flow: row dense;
}
#js-show-iframe-wrapper .bf-18__decor {
    background: var(--pos-banner-fluid-18__bg-url) var(--pos-banner-fluid-18__bg-url-position) no-repeat;
    background-size: cover;
    background-color: #f8efec;
    position: relative;
	border-radius: 20px;
}
#js-show-iframe-wrapper .bf-18__content {
    display: flex;
    flex-direction: column;
    padding: var(--pos-banner-fluid-18__content-padding);
    grid-row: var(--pos-banner-fluid-18__content-grid-row);
    justify-content: center;
}
#js-show-iframe-wrapper .bf-18__text {
    margin: var(--pos-banner-fluid-18__text-margin);
    font-size: 1.3rem;
    line-height: 1.4;
    font-family: 'MyCustomFont2';
    font-weight: 700;
    color: #0b1f33;
}
#js-show-iframe-wrapper .bf-18__bottom-wrap {
    display: flex;
    flex-direction: row;
    align-items: center;
}
#js-show-iframe-wrapper .bf-18__logo-wrap {
    position: absolute;
    top: var(--pos-banner-fluid-18__logo-wrap-top);
    left: var(--pos-banner-fluid-18__logo-wrap-left);
    padding: var(--pos-banner-fluid-18__logo-wrap-padding);
    background: #fff;
    border-radius: 0 0 8px 0;
}
#js-show-iframe-wrapper .bf-18__logo {
    width: var(--pos-banner-fluid-18__logo-width);
    margin-left: 1px;
}
#js-show-iframe-wrapper .bf-18__slogan {
    font-family: LatoWeb, sans-serif;
    font-weight: 700;
    font-size: var(--pos-banner-fluid-18__slogan-font-size);
    line-height: 1.2;
    color: #005ca9;
}
#js-show-iframe-wrapper .bf-18__btn-wrap {
    width: 100%;
    max-width: var(--pos-banner-fluid-18__button-wrap-max-width);
}
@media (min-width: 768px) {
.vertical-news-list {
	display: flex;
    gap: 20px;
    flex-direction: column;
}}
@media (max-width: 768px) {
.vertical-news-list {
	display: flex;
    gap: 20px;
    flex-direction: row;
    padding: 20px;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
}}


.schedule-widget {
    background: rgb(59 89 139);
    border-radius: 16px;
    padding: 12px 20px;
    margin: 0px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
	margin-right: 0px;
}
@media (max-width: 768px) {
.schedule-widget {
width: inherit;
}}
@media (min-width: 768px) {
.schedule-widget {

	margin: 20px;
	margin-left: 0px;
}}
.clock-container {
    text-align: center;
    min-width: 140px;
}
.current-time {
    font-size: 2rem;
    font-weight: 700;
    font-family: 'MyCustomFont2';
    color: #aec3ff;
    line-height: 1.2;
}
.current-date {
    font-size: 1rem;
    color: #ffffff;
}
.schedule-info {
    flex: 1;
    text-align: left;
}
.schedule-status {
    font-size: 1.3rem;
    font-weight: 700;
    color: #e7ffa1;
	line-height: 20px;
}
.schedule-timing {
    font-size: 1.2rem;
    color: #b0d1ff;
    margin-top: 4px;
}
@media (max-width: 768px) {
.banerrrr {
	width: 100%;
    padding: 5%;
}}
@media (max-width: 768px) {
.banerrrr {
    z-index: 100;
	gap: 20px;
		margin-top: -30px;
}}
/* На мобильных устройствах скрываем краткое описание новостей */
@media (max-width: 768px) {
    .news-excerpt {
        display: none;
    }
}
/* Новый виджет с расписанием */
.schedule-widget-lessons {
    min-width: 280px;
    background: rgb(59 89 139);
    border-radius: 20px;
    padding: 15px;
	color: #ffffff;
}
@media (max-width: 768px) {
.schedule-widget-lessons {

}}
@media (min-width: 768px) {
.schedule-widget-lessons {
	width: auto;
	display: block;
}
	.schedule-widget {
		max-width: max-content;
		min-width: 390px;
	}}
.schedule-widget-wrapper {
    width: 100%;
}
@media (min-width: 768px) {
.schedule-widget-wrapper {
	display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    gap: 0px;
	padding-top: 20px;
}}
@media (max-width: 768px) {
.schedule-widget-wrapper {

}}

.schedule-filters {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 0px;
}

.filter-group {
    display: flex;
    flex-direction: column;
}

.filter-group label {
    font-size: 1.1rem;
    font-weight: bold;
    margin-bottom: 2px;
    color: #ffffff;
    text-transform: uppercase;
}

.filter-group select {
    padding: 5px 8px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 1.3rem;
    background: white;
	font-family: 'MyCustomFont2';
}

.schedule-show-btn {
    padding: 8px 16px;
    background: #0073aa;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 13px;
    font-weight: bold;
    margin-top: 5px;
    transition: background 0.3s;
}

.schedule-show-btn:hover {
    background: #005a87;
}
@media (min-width: 768px) {
.schedule-result {
    margin-top: 0px;
	padding: 0px 5px 20px 20px;
	font-family: 'MyCustomFont2';
}}
@media (max-width: 768px) {
.schedule-result {
    margin: 0px;
	font-family: 'MyCustomFont2';
}}
.schedule-list {
    list-style: none;
    padding: 0;
    margin: 0;
	min-width: fit-content;
}

.schedule-list li {
    font-size: 1.2rem;
    border-bottom: 1px solid #eee;
    color: #ffffff;
	line-height: 25px;
}
@media (min-width: 768px) {
.schedule-list li {
    white-space: nowrap;
}}
@media (max-width: 768px) {
.schedule-list li {
    
}}
.lesson-num {
    font-weight: 400;
    color: #b0d1ff;
    margin-right: 5px;
}
@media (min-width: 768px) {
.lesson-num {
}}
@media (max-width: 768px) {
.lesson-num {
    margin-bottom: -10px;
}}
.schedule-placeholder,
.schedule-loading {
    text-align: center;
    color: #052049;
    font-size: 1.0rem;
    font-style: normal;
    padding: 10px;
    border: solid 1px #052049;
    border-radius: 20px;
	cursor: default;
	white-space: nowrap;
}

.schedule-error {
    text-align: center;
    color: #d63638;
    font-size: 13px;
}

/* Чтобы оба виджета были в одной линии */
.banerrrr {
    display: flex;
    flex-wrap: wrap;
    flex-direction: row;
    align-content: flex-start;
	align-items: flex-start;
}
@media (max-width: 768px) {
.banerrrr2 {
	display: flex;
    flex-direction: column;
    gap: 20px;
	z-index: 100;
}}
@media (min-width: 768px) {
.banerrrr2 {
}}

/* «красная булавка» --------------------------------------------------------------*/
.link-card.pinned {
    position: relative;
    overflow: visible; /* чтобы булавка не обрезалась */
}
.link-card.pinned::before {
    content: '';
    position: absolute;
    top: -10px;
    right: -10px;
    width: 22px;
    height: 22px;
    background: #d32f2f;
    border-radius: 50% 50% 50% 0;
    transform: rotate(355deg);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    z-index: 3;
}
.link-card.pinned::after {
    content: '';
    position: absolute;
    top: 10px;
    right: 11px;
    width: 2px;
    height: 8px;
    background: white;
    transform: rotate(37deg);
    z-index: 4;
}
/*-------------------------------------------------------------------------------------*/
@media (max-width: 768px) {
    .hide-mobile { display: none !important; }
}
@media (min-width: 769px) {
    .hide-desktop { display: none !important; }
}
/*-------------------------------------------------------------------------------------*/
/* Контейнер фильтров */
.schedule-widget-wrapper .schedule-filters {
    display: flex;
    flex-direction: column;
    gap: 0px;              /* расстояние между группами фильтров */
	justify-content: center;
}

/* Группа: label + select */
.schedule-widget-wrapper .filter-group {
    display: flex;
    flex-direction: column;
	width: -webkit-fill-available;
}

/* Подпись фильтра */
.schedule-widget-wrapper .filter-group label {
    white-space: nowrap;        /* не переносить */
    overflow: hidden;
    text-overflow: ellipsis;    /* многоточие, если текст слишком длинный */
}

/* Стилизация выпадающих меню */
.schedule-widget-wrapper .filter-group select {
    
    padding: 10px 14px;
    border: 1px solid #00000000;
    border-radius: 20px;
    background-color: #052049;
    color: #ffffff;
    appearance: auto;           /* стандартная стрелка браузера */
    box-sizing: border-box;
    transition: border-color 0.2s;

    /* Обрезаем длинный текст в закрытом состоянии */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
@media (min-width: 768px) {
.schedule-widget-wrapper .filter-group select {
	width: 100%;
}}
@media (max-width: 768px) {
.schedule-widget-wrapper .filter-group select {
	width: 100%;
}}
/* При фокусе */
.schedule-widget-wrapper .filter-group select:focus {
    border-color: #0073aa;
    outline: none;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.15);
}

/* Для мобильных устройств – чуть уменьшаем */
@media (max-width: 480px) {
    .schedule-widget-wrapper {
        padding: 0px;
    }
    .schedule-widget-wrapper .filter-group select {
        padding: 14px 16px;
    }
}
/* Ограничение ширины для длинных названий в селектах */
.schedule-widget-wrapper .filter-group select {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
	margin-bottom: 20px;
}
@media (min-width: 768px) {
.schedule-filter {
	max-width: 275px;
	min-width: 150px;
}}
@media (max-width: 768px) {
.schedule-filter {
	max-width: 100%;
	min-width: 150px;
}}
/* Для опций внутри селекта можно задать ограничение (работает не везде) */
.schedule-widget-wrapper .filter-group select option {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 300px; /* ограничение для выпадающего списка */
}
.kvantorium-item {
    word-wrap: break-word;
    overflow-wrap: break-word;
}
/* ===== КВАНТОРИУМ: РАСПИСАНИЕ ===== */

/* Заголовок */
.kvantorium-schedule-title {
    font-size: 1.4rem;
    font-weight: 400;
    color: #fff;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #e0e0e0;
}

/* Карточка занятия */
.kvantorium-item {
    border-bottom: 1px solid #eee;
    padding: 12px 0;
}
.kvantorium-item:last-child {
    border-bottom: none;
}

/* Время проведения */
.kvantorium-item-time {
    font-size: 1.3rem;
    font-weight: 400;
    color: #fff;
    margin-bottom: 0px;
	white-space: nowrap;
}

/* Преподаватель */
.kvantorium-item-teacher {
    font-size: 1.3rem;
    color: #fff;
    margin-top: 0px;
}

/* Кабинет */
.kvantorium-item-room {
    font-size: 1.4rem;
    color: #83d7ff;
    margin-top: 3px;
}

/* ===== СООБЩЕНИЕ ОБ ОТСУТСТВИИ РАСПИСАНИЯ ===== */

/* Блок сообщения */
.kvantorium-no-lessons {
    padding: 10px 0;
}

/* Основной текст */
.kvantorium-no-lessons-text {
    font-size: 14px;
    color: #856404;
    background: #fff3cd;
    padding: 10px 14px;
    border-radius: 6px;
    margin-bottom: 10px;
}

/* Подсказка с доступными днями */
.kvantorium-available-days {
    font-size: 1.3rem;
    color: #fff;
    border-radius: 6px;
}
.schedule-meta {
	font-size: 1.3rem;
    color: #ffffff;
    margin-bottom: 7px;
    border-left: solid 2px #e7ffa1;
    padding-left: 7px;
}
.schedule-title {
	font-size: 1.3rem;
    color: #ffffff;
    border-left: solid 2px #e7ffa1;
    padding-left: 7px;
    font-weight: 400;
    margin-bottom: -10px;
}
.kvantorium-item-subject {
	font-size: 1.3rem;
}
@media (min-width: 1100px) {
.kvantorium-item-subject {
	white-space: nowrap;
}}
.additional-schedule {
	margin-top: 20px;
}
@media (min-width: 768px) {
.additional-item-time {
	white-space: nowrap;
}}
.additional-item {
	border-bottom: solid 1px;
    padding: 10px 0px;
}
.additional-item div {
	line-height: 25px;
}
.additional-item-time {
	color: #88ff96;
}

@media (max-width: 768px) {
	/* Фиксируем высоту баннера, чтобы виджеты не сдвигали макет при загрузке */
.banerrrr {
    min-height: 280px;  /* примерно, подберите под ваш контент */
}

/* Блок фильтров всегда занимает хотя бы столько */
.schedule-filters {
    min-height: 200px;
}
	.school-logo-kvant-baner {
        min-width: 250px;
        height: auto;
        aspect-ratio: 330 / 100;
}
	.banner-content p {
    line-height: 1.4;
    min-height: 2.8em;  /* на случай, если текст может переноситься */
}
}
/* Очень большие экраны (≥1700px) – только 2 последние записи */
@media (min-width: 1700px) {
    .news-list .news-item:nth-child(n+3) {
        display: none;
    }
}

/* Ноутбуки и десктопы среднего размера (1350–1699px) – 4 записи */
@media (min-width: 1350px) and (max-width: 1699px) {
    .news-list .news-item:nth-child(n+5) {
        display: none;
    }
}

/* Планшеты и небольшие ноутбуки (900–1349px) – 2 записи */
@media (min-width: 900px) and (max-width: 1349px) {
    .news-list .news-item:nth-child(n+3) {
        display: none;
    }
}

.block-baner-kvant-storis {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
}
/* ========== STORIES WIDGET ========== */
@media (min-width: 768px) {
.storis {
    width: 100%;
    display: flex;
    padding-right: 20px;
}}
@media (max-width: 768px) {
.storis {
    width: 100%;
    display: flex;
}}
@media (min-width: 768px) and (max-width: 1200px)  {
.storis {
padding-left: 1%;
}}
@media (min-width: 768px) {
.stories-widget {
}}
.story-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    z-index: 999;
}
@media (min-width: 1600px) {
.story-item {
    width: 20%;
}}
@media (min-width: 1200px) and (max-width: 1600px) {
.story-item {
    width: 30%;
}}
@media (min-width: 768px) and (max-width: 1200px) {
.story-item {
    width: 20%;
}}
@media (max-width: 768px) {
.story-item {
    width: 60%;
}}
.stories-list {
    justify-content: flex-start !important;
}
@media (max-width: 768px) {
.story-item {
    height: 237px;
}}
.story-label {
    color: #ffffff !important;
    font-size: 1.2rem !important;
    max-width: 100% !important;
}
.story-circle {
    width: 90% !important;
    height: 80% !important;
    border-radius: 50% !important;
}
@media (min-width: 768px) {
.stories-list {
    display: flex;
    flex-wrap: nowrap !important;
    flex-direction: row;
    width: 100%;
    gap: 0px !important;
}}
@media (max-width: 768px) {
.stories-list {
    display: -webkit-box !important;
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    margin-bottom: 0px;
    margin-right: -20px;
    margin-left: -20px;
    padding-left: 2%;
    padding-right: 2%;
}}
@media (max-width: 768px) {
.stories-widget {
    padding: 15px 20px !important;
}}
.story-circle-inner {
    height: 100% !important;
    width: auto !important;
    background: #000000 !important;
}
.story-circle-inner video {
    width: 100% !important;
    height: 100% !important;
    border-radius: 40% !important;
}
.story-modal {
}
@media (max-width: 768px) {
.story-modal video {
    max-width: 100% !important;
}}
@media (min-width: 768px) {
.story-modal video {
    max-width: 100% !important;
}}
.story-modal {
    align-items:center; 
    padding-top: 100px;
}
.story-item:hover { transform:scale(1.05); }

.story-circle.viewed { 
    background:#888 !important; 
    animation:none !important; }
@keyframes gradientShift {
    0%{
        background-position:0% 50%} 
    50%{
        background-position:100% 50%} 
    100%{
        background-position:0% 50%}
    }
.story-circle-inner video {
    object-fit:cover; 
    }
.story-play-icon {
    position:absolute; 
    top:50%; 
    left:50%; 
    transform:translate(-50%,-50%);
    font-size:22px; 
    color:white; 
    text-shadow:0 0 4px rgba(0,0,0,0.6);
    }
.story-label { 
    display:block; 
    margin-top:5px; 
    font-size:12px; 
    color:#555; 
    max-width:90px; 
    overflow:hidden; 
    text-overflow:ellipsis; 
    white-space:nowrap; }

        /* Модальное окно */
        
.story-modal.active { 
    display:flex; 
}
.story-modal video {
    max-width:100%; 
    max-height:80vh; 
    border-radius:8px;
}
@media (max-width:768px) {
    .story-modal video { 
        max-height:65vh; 
        
    }
    }
.story-modal-title {
    color:white; 
    font-size:18px; 
    margin-top:15px; 
    text-align:center; 
    padding:0 20px;
    }
.story-modal {
    height: 100vh !important;
    padding-bottom: 140px;
}
@media (min-width:768px) {
.story-modal-bottom {
    padding: 0% 25% !important;
}}
.story-modal.active {
    overflow-x: visible !important;
}
.story-modal-bottom {
    overflow-y: visible !important;
}
.story-modal-nav {
    display:flex; 
    gap:20px; 
    margin-top:20px; 
    flex-wrap:wrap; 
    justify-content:flex-start;
    padding: 20px;
}
@media (min-width:768px) {
.story-modal-nav-item {
    width:150px; 
    height:150px; 
    border-radius:50%; 
    overflow:hidden; 
    cursor:pointer;
    border:2px solid transparent; 
    transition:0.2s;
  }  }
@media (max-width:768px) {
.story-modal-nav-item {
    width: 100%;
    height: 180px;
    border-radius:50%; 
    overflow:hidden; 
    cursor:pointer;
    border:2px solid transparent; 
    transition:0.2s;
   } }
.story-modal-nav-item.active { 
    border-color:#fff; 
}
.story-modal-nav-item video {
    width:100%; 
    height:100%; 
    object-fit:cover; 
    border-radius:50%;
    }
/* Навигация в модальном окне Stories */
.story-modal-nav {
    display: flex !important;
    gap: 20px !important;
    margin-top: 20px !important;
    justify-content: center !important;
    z-index: 1000001 !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important; /* Firefox */
    -ms-overflow-style: none !important;  /* IE/Edge */
    max-width: 90vw !important;
    padding-bottom: 10px !important;
    flex-wrap: nowrap !important; /* ← важно: не переносить на новую строку */
}

.story-modal-nav::-webkit-scrollbar {
    display: none !important; /* Chrome/Safari */
}

/* Обёртка для каждого элемента навигации */
.story-modal-nav > div {
    flex-shrink: 0 !important;
    min-width: 80px !important;
    max-width: 45vw !important;
}

.story-modal-nav-item {
    width: 80px !important;
    height: 80px !important;
    min-width: 80px !important;
    min-height: 80px !important;
    border-radius: 50% !important;
    overflow: hidden !important;
    cursor: pointer !important;
    border: 2px solid transparent !important;
    transition: 0.2s !important;
}
#story-video-player {
    max-width: 90vw;
    max-height: 50vh;
    border-radius: 8px;
}
.story-modal-meta {
    padding: 10px 20px;
    color: white;
    text-align: center;
    flex-shrink: 0;
}
.story-modal-title {
    font-size: 18px;
}
.story-modal-views {
    font-size: 14px;
    color: #ccc;
}
.story-modal-bottom {
    -webkit-overflow-scrolling: touch;
}

.story-modal { 
    flex-direction: column;
    overflow-x: hidden;         /* ← запрещаем горизонтальную */
    -webkit-overflow-scrolling: touch;
}
@media (max-width:768px) {
.story-hscroll {
    margin-left: -20px;
    margin-right: -20px;
    padding-left: 40px;
    padding-right: 40px;
}}

.stories-widget .stories-list .story-circle {
    background: linear-gradient(45deg, #009dff, #00ff4e, #ff4000, #0dff00, #ff0707) !important;
    background-size: 300% 300% !important;
    animation: gradientShift 3s infinite !important;
    padding: 0px !important;
    z-index: 999;
}
.stories-widget .stories-list .story-circle.viewed {
    background: #888 !important;
    animation: none !important;
}
@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}