/* Сброс стилей и базовые настройки */
.glav_photo_container * {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

.glav_photo_container {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background:;
    color: #333333;
    min-height:;
    padding: 3px 3px 3px 3px;
    margin-top: 40px;
    padding: 1px 5px 1px 5px;
}

.glav_photo_wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    background: #fff;
}

.glav_photo_header {
    text-align: center;
}

.glav_photo_header h2 {
    color: #333333;
    font-size: 36px;
    margin-bottom: 10px;
    text-transform: uppercase;
    -webkit-font-smoothing: antialiased;
    line-height: 1.2;
}

.glav_photo_header p {
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.5;
    color: #888888;
    -webkit-font-smoothing: antialiased;
}

.glav_photo_search-container {
    max-width: 700px;
    margin: 0 auto 20px;
    position: relative;
    display: flex;
}

.glav_photo_search-box {
    width: 100%;
    padding: 15px 50px 15px 20px;
    border: 3px solid #3f9f31;
    border-radius: 10px;
    font-size: 16px;
    transition: all 0.3s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.glav_photo_search-box:focus {
    outline: none;
    border-color: #32af37;
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.1);
}

.glav_photo_search-icon {
    position: absolute;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    color: #00719d;
    font-size: 20px;
}

.glav_photo_grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 22px;
    margin-bottom: 40px;
}

.glav_photo_card {
    background: #ffffff;
    border-radius: 15px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow:;
    border: 1px solid #f0f0f0;
}

.glav_photo_card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.glav_photo_image {
    width: 100%;
    height: 180px;
    object-fit: contain;
    display: block;
}

.glav_photo_info {
    padding: 20px;
}

.glav_photo_title {
    font-size: 18px;
    font-weight: 650;
    color: #333333;
    margin-bottom: 8px;
}

.glav_photo_category {
    /* ВЫПАДАЮЩИЙ СПИСОК ВМЕСТО КНОПОК 
	font-size: 15px;
    color: #b74f58;
    margin-bottom: 12px;
    font-weight: 800;*/
	/*  
	font-size: 18px;
    color: #1d950c;
    margin-bottom: 12px;
    font-weight: 800;
    background: #3a5c33;
    color: #ffffff;
    padding: 2px 8px 6px 10px;
    border-radius: 12px;
    text-align: center;*/
	/* */
	font-size: 16px;
    color: #1d950c;
    margin-bottom: 5px;
    font-weight: 600;
    background: #efefef;
    color: #000000;
    padding: 2px 8px 6px 10px;
    border-radius: 12px;
    text-align: center;
	margin-top: auto; 
 
	
}
	
}

.glav_photo_tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.glav_photo_tag {
    background: #eaf4e8;
    color: #66b15c;
    padding: 2px 8px 6px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
}

.glav_photo_results-info {
    margin-bottom: 20px;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.5;
    color: #888888;
    text-align: center;
    -webkit-font-smoothing: antialiased;
}

.glav_photo_no-results {
    text-align: center;
    padding: 40px;
    color: #888888;
    font-size: 18px;
    grid-column: 1 / -1;
}

/* ВЫПАДАЮЩИЙ СПИСОК ВМЕСТО КНОПОК */
.glav_photo_controls {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

/* Стиль самого селекта (видимая кнопка) */
.glav_photo_category_select {
    display: inline-block;
    width: auto;
    min-width: 240px;
    padding: 12px 40px 12px 24px;
    font-family: 'Segoe UI', 'Montserrat', sans-serif;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    color: #00719d;
    background-color: #ffffff;
    border: 2px solid #00719d;
    border-radius: 40px;
    cursor: pointer;
    transition: all 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    text-align: left;
    /* Стрелка (data:image) */
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="%2300719d" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
    background-repeat: no-repeat;
    background-position: right 18px center;
    background-size: 16px;
}

/* Состояние при наведении/фокусе */
.glav_photo_category_select:hover,
.glav_photo_category_select:focus {
    background-color: #00719d;
    color: #ffffff;
    border-color: #00719d;
    background-image: url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="%23ffffff" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polyline points="6 9 12 15 18 9"></polyline></svg>');
    outline: none;
}

/* Стили для каждого пункта выпадающего списка (option) */
.glav_photo_category_select option {
    font-family: 'Segoe UI', 'Montserrat', sans-serif;
    font-size: 15px;
    font-weight: 500;
    line-height: 2.2;          /* вертикальное расстояние между пунктами */
    padding: 6px 16px;         /* внутренние отступы (работает в Chrome/Edge) */
    background-color: #ffffff;
    color: #333333;
    border: none;
    transition: background 0.1s;
}

/* Эффект при наведении на пункт */
.glav_photo_category_select option:hover {
    background-color: #e6f4f7 !important;
    color: #00719d;
    cursor: pointer;
}

.glav_photo_footer {
    text-align: center;
    color: #666666;
    padding: 20px;
    margin-top: 40px;
    font-size: 14px;
}

@media (max-width: 768px) {
    .glav_photo_grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }
    
    .glav_photo_header h2 {
        font-size: 28px;
    }
    
    .glav_photo_image {
        height: 150px;
    }
    
    .glav_photo_category_select {
        min-width: 200px;
        padding: 10px 36px 10px 18px;
        font-size: 14px;
        background-position: right 14px center;
    }
    .glav_photo_category_select option {
        font-size: 14px;
        line-height: 2;
        padding: 4px 12px;
    }
}

/* Анимация появления карточек */
@keyframes glav_photo_fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.glav_photo_card {
    animation: glav_photo_fadeIn 0.5s ease forwards;
}

/* Модальное окно для просмотра фото */
.glav_photo_modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.glav_photo_modal.glav_photo_show {
    display: flex;
    opacity: 1;
}

.glav_photo_modal-content {
    max-width: 90%;
    max-height: 99%;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.glav_photo_modal-image {
    max-width: 100%;
    max-height: 80vh;
    display: block;
}

.glav_photo_modal-info {
    background: #ffffff;
    padding: 20px;
    color: #333333;
}

.glav_photo_modal-title {
    font-size: 24px;
    margin-bottom: 10px;
}

.glav_photo_modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(255, 255, 255, 0.8);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    font-size: 20px;
    color: #333333;
    transition: all 0.3s;
}

.glav_photo_modal-close:hover {
    background: #ffffff;
    transform: rotate(90deg);
}

/* Скрытие скролла при открытом модальном окне */
.glav_photo_no-scroll {
    overflow: hidden;
}

/* Базовые стили для пагинации */
.glav_photo_pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 30px 0 20px;
    flex-wrap: wrap;
}
.glav_photo_page-btn {
    display: inline-block;
    min-width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    border: 1px solid #dee2e6;
    background: white;
    color: #00719d;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px;
    padding: 0 5px;
}
.glav_photo_page-btn:hover {
    background: #00719d;
    color: white;
    border-color: #00719d;
}
.glav_photo_page-btn.active {
    background: #00719d;
    color: white;
    border-color: #00719d;
}
.glav_photo_page-arrow {
    font-size: 20px;
    line-height: 38px;
}
.glav_photo_page-dots {
    color: #666;
    font-weight: bold;
    margin: 0 5px;
}

/* Ссылка-обёртка занимает всю высоту ячейки сетки */
.glav_photo_card_link {
    display: block;
    text-decoration: none;
    color: inherit;
    height: 100%;
}

/* Карточка внутри ссылки тоже на всю высоту и выравнивание по колонке */
.glav_photo_card {
    height: 100%;
    display: flex;
    flex-direction: column;
    background: white;
    border: 1px solid #eeeeee;
    border-radius: 8px;
    overflow: hidden;
}

/* Изображение фиксированной высоты */
.glav_photo_image {
    height: 240px;
    width: 100%;
    object-fit: contain;
    border-bottom: 1px solid #dee2e6;
}

/* Блок с информацией занимает оставшееся пространство */
.glav_photo_info {
    flex: 1;
    padding: 10px;
    display: flex;
    flex-direction: column;
}

/* Теги прижимаются к низу */
.glav_photo_tags {
    margin-top: ;
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
	margin-bottom: 9px;
}

/* Кнопка-ссылка */
.search_top_button {
    background-color: #212121;
    border: 2px solid #32af37;
    border-radius: 10px;
    margin: 0px 0px 0px 0px;
    height: 50px;
    width: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    text-decoration: none;
    cursor: pointer;
}

/* Иконка лупы */
.search_top_icon {
    color: #fff;
    width: 42px;
    height: 42px;
    display: block;
    transform: translateY(-1px);
}

.search_top_button2 {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
}

.search_top_icon2 {
    width: 42px;
    height: 42px;
    color: #32af37;
}

/* для мобильных устройств до 480px - две колонки */
@media (max-width: 480px) {
    .glav_photo_grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    
    .glav_photo_wrapper {
        padding: 0px;
    }

    .glav_photo_image {
        height: 150px;
        width: 100%;
        object-fit: contain;
        border-bottom: 1px solid #dee2e6;
    }
    
    .glav_photo_title {
        font-size: 14px;
        font-weight: 650;
        color: #333333;
        margin-bottom: 8px;
    }
}


	
	/* ===== КАСТОМНЫЙ ВЫПАДАЮЩИЙ СПИСОК КАТЕГОРИЙ ===== */
.glav_photo_controls {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.custom-dropdown {
    position: relative;
    display: inline-block;
    min-width: 320px;
}

.custom-dropdown-toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    padding: 12px 20px;
    font-family: 'Segoe UI', 'Montserrat', sans-serif;
    font-size: 16px;
    font-weight: 600;
    color: #333333;
    background-color: #ffffff;
    border: 2px solid #3f9f31;
    border-radius: 40px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
    white-space: nowrap;
}

.custom-dropdown-toggle:hover,
.custom-dropdown-toggle.active {
    background-color: #3f9f31;
    color: #ffffff;
    border-color: #3f9f31;
}

.dropdown-arrow {
    transition: transform 0.2s;
}

.custom-dropdown-toggle.active .dropdown-arrow {
    transform: rotate(180deg);
}

.custom-dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #58ab5b;
    border-radius: 16px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    max-height: 320px;
    overflow-y: auto;
    z-index: 100;
    display: none;
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.2s, transform 0.2s;
}

.custom-dropdown-menu.show {
    display: block;
    opacity: 1;
    transform: translateY(0);
}

.category-list {
    list-style: none;
    margin: 0;
    padding: 8px 0;
}

.category-item {
    padding: 0;
    border-bottom: 1px solid #eaeaea;
}

.category-item:last-child {
    border-bottom: none;
}

.category-btn {
    display: block;
    width: 100%;
    padding: 12px 20px;
    font-family: 'Segoe UI', 'Montserrat', sans-serif;
    font-size: 15px;
    font-weight: 500;
    text-align: left;
    background: none;
    border: none;
    cursor: pointer;
    transition: all 0.1s;
    color: #333333;
}

.category-btn:hover {
    background-color: #7ecd73;
    color: #fff;
}

.category-btn.active-category {
    background-color: #7ecd73;
    color: #ffffff;
    font-weight: 600;
}

/* Адаптация для мобильных устройств */
@media (max-width: 768px) {
    .custom-dropdown {
        min-width: 310px;
    }
    .custom-dropdown-toggle {
        padding: 10px 16px;
        font-size: 14px;
    }
    .category-btn {
        padding: 10px 16px;
        font-size: 14px;
    }
}

