/* ==========================================================================
   1. ПЕРЕМЕННЫЕ И БАЗОВЫЕ НАСТРОЙКИ
   ========================================================================== */
:root {
    --main-color: #003355;    /* Темно-синий */
    --accent-color: #e65c00;  /* Оранжевый */
    --bg-color: #ffffff;
    --light-gray: #f4f7f9;    /* Светлый холодный фон */
    --text-color: #333;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Montserrat', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ==========================================================================
   2. ШАПКА (HEADER) И НАВИГАЦИЯ
   ========================================================================== */
.header {
    background: #fff;
    border-bottom: 1px solid #eee;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img {
    height: 70px;
    width: auto;
    display: block;
    transition: var(--transition);
}

.logo-img:hover {
    transform: scale(1.05);
}

.nav ul {
    display: flex;
    list-style: none;
}

.nav ul li {
    margin: 0 15px;
}

.nav ul li a {
    text-decoration: none;
    color: var(--main-color);
    font-weight: 600;
    font-size: 14px;
    text-transform: uppercase;
    transition: var(--transition);
}

.nav ul li a:hover, .nav ul li a.active {
    color: var(--accent-color);
}

.search-box form {
    display: flex;
    border: 1px solid #ddd;
    border-radius: 20px;
    overflow: hidden;
}

.search-box input {
    border: none;
    padding: 5px 15px;
    outline: none;
    font-family: inherit;
}

.search-box button {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0 10px;
}

/* ==========================================================================
   3. ГЛАВНЫЙ БАННЕР (HERO) И CTA
   ========================================================================== */
.hero {
    height: 70vh;
    background: linear-gradient(rgba(0,0,0,0.4), rgba(0,0,0,0.4)), 
                url('images/3c3701d5-93d6-41a1-ba42-8d821685a4d8.jpg') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.hero-content h1 {
    font-family: 'Playfair Display', serif;
    font-size: 55px;
    margin-bottom: 10px;
}

.hero-content p {
    font-size: 20px;
    margin-bottom: 30px;
    font-weight: 300;
}

.btn {
    display: inline-block;
    padding: 12px 35px;
    background: var(--main-color);
    color: white !important;
    text-decoration: none;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 1px;
    font-weight: 600;
    transition: var(--transition);
    border: 2px solid var(--main-color);
    cursor: pointer;
    border-radius: 2px;
}

.btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

/* CTA Баннер */
.cta-banner {
    background: linear-gradient(135deg, #003355 0%, #005577 50%, #003355 100%);
    padding: 100px 0;
    text-align: center;
    color: white;
    margin: 60px 0;
}

.cta-content h2 {
    font-family: 'Playfair Display', serif;
    font-size: 36px;
    margin-bottom: 20px;
}

.cta-content p {
    font-size: 18px;
    margin-bottom: 30px;
    font-weight: 300;
    opacity: 0.9;
}

.btn-white {
    background: white !important;
    color: var(--main-color) !important;
    border: 2px solid white !important;
}

.btn-white:hover {
    background: transparent !important;
    color: white !important;
}

/* ==========================================================================
   4. СЕКЦИИ: ЦЕННОСТИ И АКТУАЛЬНОЕ (TRENDING)
   ========================================================================== */
.values {
    padding: 60px 0;
    background-color: var(--light-gray);
}

.values-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    text-align: center;
}

.value-item {
    padding: 30px;
    transition: var(--transition);
}

.value-icon {
    font-size: 40px;
    margin-bottom: 20px;
    display: block;
}

.value-item h3 {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    color: var(--main-color);
    margin-bottom: 15px;
}

.value-item p {
    font-size: 14px;
    color: #666;
    font-weight: 300;
}

.value-item:hover {
    transform: translateY(-10px);
}

.trending {
    padding: 80px 0;
    background-color: #fff;
}

.trending-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
}

.trending-item {
    display: flex;
    flex-direction: column;
}

.trend-date {
    display: block;
    font-size: 11px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 8px;
}

.trend-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    color: var(--main-color);
    margin-bottom: 15px;
}

.trending-img-wrapper {
    position: relative;
    width: 100%;
    height: 500px;
    overflow: hidden;
    border-radius: 4px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.05);
}

.trending-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    cursor: pointer;
}

.trending-item:hover .trending-img-wrapper img {
    transform: scale(1.08);
}

.trending-item .post-info {
    padding: 20px 0;
    background: transparent;
}

/* ==========================================================================
   5. ОСНОВНОЙ МАКЕТ (MAIN LAYOUT) И СЕТКА ПОСТОВ
   ========================================================================== */
.main-layout {
    display: grid;
    grid-template-columns: 3fr 1fr;
    gap: 40px;
    margin-top: -50px;
    position: relative;
    z-index: 10;
    padding-top: 60px;
    padding-bottom: 60px;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    margin-bottom: 30px;
    text-align: center;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    margin: 10px auto;
}

.posts-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 40px;
}

.post-card {
    background: var(--light-gray);
    border-radius: 15px;
    overflow: hidden;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    border-bottom: 4px solid transparent;
}

.post-card:hover {
    transform: translateY(-10px);
    border-bottom: 4px solid var(--accent-color);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.post-img {
    position: relative;
    overflow: hidden;
}

.post-img img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
}

.post-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.post-info h3 a {
    text-decoration: none;
    color: var(--main-color);
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    transition: var(--transition);
}

.post-info h3 a:hover {
    color: var(--accent-color);
}

.post-info p {
    font-size: 14px;
    color: #666;
    margin: 15px 0 20px;
    line-height: 1.5;
}

.read-more {
    text-decoration: none;
    color: var(--accent-color);
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
}

/* ==========================================================================
   6. САЙДБАР (SIDEBAR) И ПОПУЛЯРНОЕ
   ========================================================================== */
.sidebar-widget {
    background: var(--light-gray);
    padding: 25px;
    margin-bottom: 30px;
}

.sidebar-widget h2 {
    font-family: 'Playfair Display', serif;
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--main-color);
}

.subscribe-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.subscribe-form input {
    padding: 12px;
    border: 1px solid #ddd;
    outline: none;
}

.subscribe-form button {
    padding: 12px;
    background: var(--main-color);
    color: white;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-transform: uppercase;
    font-weight: 600;
}

.subscribe-form button:hover {
    background: var(--accent-color);
}

.categories-list {
    list-style: none;
}

.categories-list li {
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.categories-list li a {
    text-decoration: none;
    color: #666;
    font-size: 14px;
    transition: var(--transition);
}

.categories-list li a:hover {
    color: var(--accent-color);
    padding-left: 5px;
}

/* ==========================================================================
   ЦЕНТРИРОВАННЫЙ БЛОК "ПОПУЛЯРНОЕ"
   ========================================================================== */
#popular-posts {
    background-color: var(--light-gray);
    padding: 60px 40px;
    border-radius: 30px;
    max-width: 700px;
    margin: 60px auto;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
}

#popular-posts .section-title {
    text-align: center;
    margin-bottom: 40px;
    width: 100%;
}

#popular-posts .section-title::after {
    margin: 10px auto 0;
}

.popular-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.pop-item {
    display: flex;
    align-items: center;
    gap: 15px;
    text-align: left;
}

.pop-item img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--accent-color);
    flex-shrink: 0;
}

.pop-item a {
    text-decoration: none;
    color: var(--text-color);
    font-size: 16px;
    transition: var(--transition);
}

.pop-item a:hover {
    color: var(--accent-color);
}

/* ==========================================================================
   7. СТРАНИЦЫ СТАТЕЙ (POSTS)
   ========================================================================== */
.article-header {
    text-align: center;
    margin-bottom: 40px;
    padding: 40px 0;
}

.article-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 42px;
    color: var(--main-color);
    margin-bottom: 20px;
    line-height: 1.2;
}

.article-meta {
    font-size: 14px;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
}

.article-content {
    max-width: 800px;
    margin: 0 auto;
    font-size: 18px;
    line-height: 1.8;
    color: #444;
}

.article-content img {
    width: 100%;
    height: auto;
    border-radius: 15px;
    margin: 30px 0;
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.article-content h2 {
    font-family: 'Playfair Display', serif;
    margin: 40px 0 20px;
    color: var(--main-color);
    font-size: 28px;
}

.article-content ul {
    list-style: none;
    margin-bottom: 25px;
    padding-left: 20px;
}

.article-content ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 12px;
    font-size: 17px;
}

.article-content ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 50%;
}

/* ФОНОВОЕ ВИДЕО */
.video-hero {
    position: relative;
    width: 100%;
    height: 95vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.bg-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    z-index: -2;
}

.video-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: -1;
}

/* БЕЗОПАСНЫЕ ГАЛЕРЕИ В СТАТЬЯХ */
.article-gallery, .article-duo {
    display: grid;
    gap: 20px;
    margin: 30px 0;
    width: 100%;
}

.article-gallery { grid-template-columns: repeat(3, 1fr); }
.article-duo { grid-template-columns: repeat(2, 1fr); }

.article-gallery img, .article-duo img {
    width: 100%;
    aspect-ratio: 3 / 4;
    object-fit: cover;
    object-position: top;
    border-radius: 12px;
    transition: var(--transition);
    cursor: pointer;
    display: block;
}

.article-gallery img:hover, .article-duo img:hover {
    transform: scale(1.02);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.main-img-container {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-bottom: 40px;
}

.main-article-img {
    width: 100%;
    max-width: 1000px;
    height: 500px;
    object-fit: cover;
    border-radius: 15px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

/* ==========================================================================
   СТРАНИЦА "О НАС" (ABOUT PAGE)
   ========================================================================== */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
    margin-top: 80px;
    margin-bottom: 100px;
}

.about-image img {
    width: 100%;
    height: auto;
    border-radius: 20px;
    display: block;
    transition: var(--transition);
    box-shadow: 25px 25px 0 var(--accent-color);
}

.about-image img:hover {
    transform: translate(-10px, -10px);
    box-shadow: 35px 35px 0 var(--main-color);
}

.about-text {
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.about-text h2 {
    font-family: 'Playfair Display', serif;
    font-size: 38px;
    color: var(--main-color);
    margin-bottom: 25px;
}

.about-text p {
    font-size: 18px;
    color: #555;
    margin-bottom: 20px;
}

.about-text .btn {
    align-self: flex-start;
    margin-top: 30px;
}

/* ==========================================================================
   ИНТЕРАКТИВНЫЕ ЭЛЕМЕНТЫ (SAVE-BTN, LIKES, MODALS)
   ========================================================================== */
.save-btn {
    position: absolute;
    top: 15px;
    right: 15px;
    background: rgba(255, 255, 255, 0.7);
    border: none;
    border-radius: 50%;
    width: 35px;
    height: 35px;
    cursor: pointer;
    font-size: 18px;
    color: #aaa;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.save-btn.active {
    color: var(--accent-color);
    background: white;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.header-likes {
    display: flex;
    align-items: center;
    gap: 5px;
    background: var(--main-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-left: 15px;
    transition: var(--transition);
    cursor: pointer;
}

.header-likes:hover {
    background: var(--accent-color);
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 2000;
    backdrop-filter: blur(5px);
}

.modal-content {
    background: white;
    padding: 40px;
    border-radius: 15px;
    max-width: 600px;
    width: 90%;
    position: relative;
}

#scrollTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--main-color);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    z-index: 1000;
    font-size: 22px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: var(--transition);
}

#scrollTop:hover {
    background-color: var(--accent-color) !important;
    transform: translateY(-5px) scale(1.1);
}

/* ==========================================================================
   ФУТЕР
   ========================================================================== */
.footer {
    background: var(--main-color);
    color: white;
    text-align: center;
    padding: 50px 0;
    font-size: 14px;
}

.footer-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.social-links {
    display: flex;
    gap: 20px;
}

.social-links a {
    color: white;
    text-decoration: none;
    font-size: 13px;
    text-transform: uppercase;
    transition: var(--transition);
}

.social-links a:hover {
    color: var(--accent-color);
}

.page-content {
    flex: 1 0 auto;
}

/* ==========================================================================
   ГАЛЕРЕИ (PHOTO)
   ========================================================================== */
.photo-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 30px 0;
}

.photo-gallery img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    object-position: top;
    border-radius: 12px;
    transition: var(--transition);
    cursor: pointer;
    display: block;
}

.photo-duo {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin: 30px 0;
}

.photo-duo img {
    width: 100%;
    height: 700px;
    object-fit: cover;
    object-position: top;
    border-radius: 12px;
    transition: var(--transition);
    cursor: pointer;
    display: block;
}

.photo-gallery img:hover,
.photo-duo img:hover {
    transform: scale(1.02);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}

/* ==========================================================================
   ФОРМЫ И ЧЕКБОКСЫ
   ========================================================================== */
.form-consent {
    font-size: 13px;
    line-height: 1.35;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.form-consent input {
    margin-top: 2px;
}

.form-consent span {
    font-size: 13px;
    line-height: 1.35;
    color: #666;
}

.form-consent a {
    font-size: 13px;
}

.subscribe-form button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ==========================================================================
   ФИЛЬТР КАТЕГОРИЙ
   ========================================================================== */
.category-filter {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-bottom: 40px;
    flex-wrap: wrap;
    padding: 0 20px;
}

.filter-btn {
    padding: 8px 20px;
    font-size: 11px;
    background: #eee;
    color: #333;
    border: 1px solid #ddd;
    border-radius: 10px;
    text-transform: uppercase;
    cursor: pointer;
    transition: var(--transition);
    font-family: inherit;
    font-weight: 600;
}

.filter-btn.active {
    background-color: var(--main-color);
    color: white;
    border-color: var(--main-color);
}

.filter-btn:hover {
    background-color: #ddd;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.categories-list .filter-btn {
    display: inline;
    padding: 0;
    margin: 0;
    background: none;
    border: 0;
    border-radius: 0;
    font-size: 14px;
    color: #333;
    text-decoration: none;
    text-transform: none;
    font-weight: 400;
}

.categories-list .filter-btn:link,
.categories-list .filter-btn:visited {
    color: #333;
    text-decoration: none;
}

.categories-list .filter-btn:hover,
.categories-list .filter-btn:focus {
    color: var(--accent-color);
    text-decoration: none;
}

.categories-list .filter-btn.active {
    color: var(--accent-color);
    text-decoration: none;
    font-weight: 600;
}

.hidden { display: none; }

/* ==========================================================================
   МОДАЛЬНЫЕ ОКНА
   ========================================================================== */
.modal {
    position: fixed;
    inset: 0;
    display: none;
    z-index: 1000;
}

.modal.is-open { display: block; }

.modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
}

.modal__content {
    position: relative;
    z-index: 1;
    width: min(92vw, 460px);
    max-height: min(82vh, 680px);
    margin: 8vh auto;
    padding: 18px 16px;
    border-radius: 18px;
    background: #fff;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
    overflow: hidden;
}

.modal__body {
    max-height: calc(82vh - 110px);
    overflow: auto;
    font-size: 14px;
    line-height: 1.55;
    padding-right: 4px;
}

.modal__close {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 32px;
    height: 32px;
    border: 0;
    border-radius: 50%;
    background: #f2f2f2;
    font-size: 22px;
    line-height: 1;
    cursor: pointer;
}

body.modal-open { overflow: hidden; }

.large-image .post-img img {
    width: 100%;
    height: auto;
    max-width: 600px;
    max-height: 500px;
}


/* ==========================================================================
   БУРГЕР-МЕНЮ (все стили в одном месте)
   ========================================================================== */
.burger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 32px;
    height: 22px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1100;
}

.burger span {
    display: block;
    width: 100%;
    height: 3px;
    background: var(--main-color);
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.burger.active span:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
    background: var(--accent-color);
}

.burger.active span:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.burger.active span:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
    background: var(--accent-color);
}


/* ==========================================================================
   СТРАНИЦА ПОИСКА
   ========================================================================== */
.search-results-section {
    padding: 60px 0;
    min-height: 60vh;
    flex: 1 0 auto;
}

.search-title {
    font-family: 'Playfair Display', serif;
    font-size: 32px;
    color: var(--main-color);
    text-align: center;
    margin-bottom: 15px;
    word-break: break-word;
}

.search-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    margin: 15px auto 0;
}

.search-count {
    text-align: center;
    color: #666;
    margin-bottom: 40px;
    font-size: 15px;
}

.search-count strong {
    color: var(--accent-color);
    font-size: 18px;
}

.search-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 30px;
}

.search-card {
    background: var(--light-gray);
    border-radius: 15px;
    overflow: hidden;
    transition: var(--transition);
    border-bottom: 4px solid transparent;
}

.search-card:hover {
    transform: translateY(-10px);
    border-bottom: 4px solid var(--accent-color);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.search-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
}

.search-card-img {
    width: 100%;
    height: 250px;
    overflow: hidden;
    background: #ddd;
}

.search-card-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.search-card:hover .search-card-img img {
    transform: scale(1.08);
}

.search-card-info {
    padding: 20px;
}

.search-category {
    display: inline-block;
    font-size: 11px;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 600;
    margin-bottom: 10px;
}

.search-card-info h3 {
    font-family: 'Playfair Display', serif;
    font-size: 20px;
    color: var(--main-color);
    margin-bottom: 10px;
    line-height: 1.3;
}

.search-card-info p {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 15px;
}

.read-more-search {
    color: var(--accent-color);
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    transition: var(--transition);
}

.search-card:hover .read-more-search {
    padding-left: 5px;
}

.no-results {
    text-align: center;
    padding: 60px 20px;
    max-width: 500px;
    margin: 0 auto;
}

.no-results-icon {
    font-size: 70px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.no-results h2 {
    font-family: 'Playfair Display', serif;
    font-size: 28px;
    color: var(--main-color);
    margin-bottom: 15px;
}

.no-results p {
    color: #666;
    font-size: 15px;
    line-height: 1.6;
}

.no-results a {
    color: var(--accent-color);
    font-weight: 600;
    text-decoration: none;
}

/* ==========================================================================
   СООБЩЕНИЯ РАССЫЛКИ
   ========================================================================== */
.subscribe-message {
    padding: 12px 15px;
    margin-top: 12px;
    border-radius: 8px;
    font-size: 13px;
    text-align: center;
    transition: opacity 0.3s ease;
    line-height: 1.4;
}

.subscribe-message--success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.subscribe-message--error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.search-box input.error {
    animation: shake 0.3s ease;
    border-color: var(--accent-color) !important;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}


/* ==========================================================================
   АДАПТИВНОСТЬ (MOBILE & TABLET)
   ========================================================================== */

/* ПЛАНШЕТЫ (1024px) */
@media (max-width: 1024px) {
    .trending-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ПЛАНШЕТЫ (992px) */
@media (max-width: 992px) {
    .container { padding: 0 18px; }
    
    .hero-content h1 { font-size: 42px; }
    .hero-content p { font-size: 18px; }
    
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    .trending-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 30px;
    }
    
    .trending-img-wrapper { height: 450px; }
    .photo-gallery img { height: 450px; }
    .photo-duo img { height: 600px; }
    .post-img img { height: 220px; }
    
    .main-layout {
        grid-template-columns: 2fr 1fr;
        gap: 30px;
    }
    
    .posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    .article-header h1 { font-size: 36px; }
    .article-content { font-size: 17px; }
    .about-text h2 { font-size: 32px; }
    .about-text p { font-size: 16px; }
    
    .article-gallery { grid-template-columns: repeat(2, 1fr); }
    
    .nav ul li { margin: 0 10px; }
    .nav ul li a { font-size: 13px; }
    
    .header-likes { margin-left: 10px; }
    
    .search-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
}

/* МОБИЛЬНЫЕ (768px) — ГЛАВНЫЙ БРЕЙКПОИНТ */
@media (max-width: 768px) {
    
    /* === БУРГЕР === */
    .burger {
        display: flex !important;
        order: 3;
        margin-left: auto;
    }
    
    .header-container {
        flex-wrap: wrap !important;
        flex-direction: row !important;
    }
    
    .logo { order: 1; }
    
    .search-box {
        order: 2;
        margin-left: auto;
        margin-right: 10px;
    }
    
    .header-likes {
        order: 4;
        margin-left: 5px;
    }
    
    .nav {
        order: 5;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
        flex-basis: 100%;
    }
    
    .nav.active {
        max-height: 400px;
        margin-top: 15px;
        padding-top: 15px;
        border-top: 1px solid #eee;
    }
    
    .nav ul {
        flex-direction: column !important;
        background: #fff;
        border-radius: 8px;
        padding: 10px;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        width: 100%;
        gap: 0;
    }
    
    .nav ul li {
        margin: 0 !important;
        width: 100%;
        text-align: center;
        padding: 12px 0;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .nav ul li:last-child {
        border-bottom: none;
    }
    
    .nav ul li a {
        font-size: 14px;
        display: block;
        padding: 5px 0;
    }
    
    /* === ОСНОВНОЙ МАКЕТ === */
    .main-layout {
        grid-template-columns: 1fr !important;
        gap: 30px;
        padding: 40px 18px;
        margin-top: -30px;
    }
    
    /* === СЕКЦИИ === */
    .header { padding: 12px 0; }
    .logo-img { height: 55px; }
    
    .hero {
        height: 60vh;
        min-height: 350px;
        padding: 15px;
    }
    
    .hero-content h1 {
        font-size: 32px;
        margin-bottom: 15px;
    }
    
    .hero-content p {
        font-size: 16px;
        margin-bottom: 25px;
    }
    
    .values { padding: 40px 0; }
    
    .values-grid {
        grid-template-columns: 1fr !important;
        gap: 20px;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .value-item { padding: 25px 20px; }
    
    .trending { padding: 50px 0; }
    
    .trending-grid {
        grid-template-columns: 1fr !important;
        gap: 35px;
        max-width: 500px;
        margin: 0 auto;
    }
    
    /* === ПОСЛЕДНИЕ СТАТЬИ — ИСПРАВЛЕНО === */
    .posts-grid {
        grid-template-columns: 1fr !important;
        gap: 25px !important;
        margin-bottom: 50px !important;
        padding: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
    }
    
    .post-card {
        width: 100% !important;
        max-width: 100% !important;
        margin: 0 !important;
    }
    
    .post-img img {
        width: 100% !important;
        height: 280px !important;
        object-fit: cover !important;
    }
    
    .post-info {
        width: 100% !important;
        padding: 20px !important;
        box-sizing: border-box !important;
    }
    
    .post-info h3 a { font-size: 18px; }
    .post-info p { font-size: 13px; }
    
    /* === САЙДБАР === */
    .sidebar-widget { padding: 20px; }
    .sidebar-widget h2 { font-size: 20px; }
    
    /* === ПОПУЛЯРНОЕ === */
    #popular-posts {
        padding: 40px 25px;
        border-radius: 20px;
        margin: 40px 15px;
    }
    
    #popular-posts .section-title {
        font-size: 24px;
        margin-bottom: 30px;
    }
    
    .pop-item img {
        width: 50px;
        height: 50px;
    }
    
    .pop-item a { font-size: 14px; }
    
    /* === СТАТЬИ === */
    .article-header {
        padding: 30px 18px;
        margin-bottom: 30px;
    }
    
    .article-header h1 {
        font-size: 28px;
        margin-bottom: 15px;
    }
    
    .article-meta { font-size: 12px; }
    
    .article-content {
        font-size: 16px;
        line-height: 1.7;
        padding: 0 18px;
    }
    
    .article-content h2 {
        font-size: 22px;
        margin: 30px 0 15px;
    }
    
    .article-content ul li {
        font-size: 15px;
        margin-bottom: 10px;
    }
    
    .article-content img {
        border-radius: 10px;
        margin: 20px 0;
    }
    
    .article-gallery,
    .article-duo {
        grid-template-columns: 1fr !important;
        gap: 15px;
        margin: 20px 0;
    }
    
    .article-gallery img,
    .article-duo img {
        height: auto !important;
        aspect-ratio: 3 / 4 !important;
    }
    
    .main-article-img {
        height: 300px !important;
        border-radius: 10px;
    }
    
    /* === ВИДЕО HERO === */
    .video-hero { height: 70vh; min-height: 350px; }
    
    /* === О НАС === */
    .about-grid {
        grid-template-columns: 1fr !important;
        gap: 30px;
        text-align: center;
        margin-top: 40px;
        margin-bottom: 60px;
        padding: 0 18px;
    }
    
    .about-image img {
        max-width: 80%;
        margin: 0 auto;
        box-shadow: 15px 15px 0 var(--accent-color);
    }
    
    .about-image img:hover {
        transform: translate(-5px, -5px);
        box-shadow: 20px 20px 0 var(--main-color);
    }
    
    .about-text h2 { font-size: 26px; }
    .about-text p { font-size: 15px; }
    .about-text .btn { align-self: center; }
    
    /* === ГАЛЕРЕИ === */
    .photo-gallery,
    .photo-duo {
        grid-template-columns: 1fr !important;
        gap: 15px;
        margin: 20px 0;
    }
    
    .photo-gallery img,
    .photo-duo img {
        height: auto !important;
        aspect-ratio: 3 / 4 !important;
        object-fit: cover !important;
    }
    
    /* === CTA === */
    .cta-banner {
        padding: 60px 18px;
        margin: 40px 0;
    }
    
    .cta-content h2 { font-size: 26px; }
    .cta-content p { font-size: 15px; }
    
    /* === КНОПКИ ФИЛЬТРА === */
    .category-filter {
        gap: 8px;
        margin-bottom: 25px;
        padding: 0 10px;
    }
    
    .filter-btn {
        padding: 6px 14px;
        font-size: 10px;
    }
    
    /* === СОХРАНИТЬ === */
    .save-btn {
        width: 40px;
        height: 40px;
        font-size: 16px;
        top: 10px;
        right: 10px;
    }
    
    /* === SCROLL TOP === */
    #scrollTop {
        width: 44px;
        height: 44px;
        bottom: 20px;
        right: 20px;
        font-size: 18px;
    }
    
    /* === ФУТЕР === */
    .footer { padding: 35px 18px; }
    .social-links { gap: 15px; }
    .social-links a { font-size: 12px; }
    
    /* === ПОИСК === */
    .search-results-section {
        padding: 40px 0;
    }
    
    .search-title {
        font-size: 24px;
    }
    
    .search-grid {
        grid-template-columns: 1fr !important;
        gap: 20px;
    }
    
    .search-card-img {
        height: 220px;
    }
    
    .no-results-icon {
        font-size: 50px;
    }
    
    .no-results h2 {
        font-size: 22px;
    }
    
    /* === МОДАЛКИ === */
    .modal__content {
        width: 94vw;
        margin: 6vh auto;
        padding: 16px 14px;
        border-radius: 16px;
    }
    
    .modal__content h3 { font-size: 16px; }
    .modal__body { font-size: 13px; }
    
    .form-consent { font-size: 11px; line-height: 1.4; }
    .form-consent span { font-size: 11px; }
    .form-consent a { font-size: 11px; }
}

/* МАЛЕНЬКИЕ МОБИЛЬНЫЕ (650px) */
@media (max-width: 650px) {
    .trending-grid { grid-template-columns: 1fr; }
    .trending-img-wrapper { height: auto; }
    .trending-img-wrapper img { height: auto; object-fit: contain; }
}

/* МАЛЕНЬКИЕ МОБИЛЬНЫЕ (576px) */
@media (max-width: 576px) {
    
    .container { padding: 0 15px; }
    
    .header { padding: 10px 0; }
    .logo-img { height: 45px; }
    
    .search-box input {
        width: 100px;
        font-size: 12px;
        padding: 4px 10px;
    }
    
    .header-likes {
        padding: 4px 10px;
        font-size: 12px;
    }
    
    .hero {
        height: 55vh;
        min-height: 320px;
    }
    
    .hero-content h1 {
        font-size: 26px;
        line-height: 1.15;
    }
    
    .hero-content p {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    .btn {
        padding: 12px 25px;
        font-size: 10px;
        letter-spacing: 0.5px;
    }
    
    .values-grid { gap: 15px; }
    .value-item { padding: 20px 15px; }
    .value-item h3 { font-size: 18px; }
    .value-item p { font-size: 13px; }
    
    .trending { padding: 40px 0; }
    .section-title { font-size: 22px; }
    
    .main-layout {
        padding: 30px 15px;
        gap: 25px;
    }
    
    .post-card { border-radius: 10px; }
    .post-img img { height: 220px !important; }
    .post-info { padding: 18px; }
    .post-info h3 a { font-size: 16px; }
    
    .sidebar-widget { padding: 18px; }
    .sidebar-widget h2 { font-size: 18px; }
    
    #popular-posts {
        padding: 30px 20px;
        margin: 30px 10px;
        border-radius: 15px;
    }
    
    #popular-posts .section-title { font-size: 20px; }
    
    .pop-item img {
        width: 45px;
        height: 45px;
    }
    
    .pop-item a { font-size: 13px; }
    
    .article-header { padding: 25px 15px; }
    .article-header h1 { font-size: 24px; }
    
    .article-content {
        font-size: 15px;
        padding: 0 15px;
    }
    
    .article-content h2 { font-size: 20px; }
    
    .cta-banner {
        padding: 50px 15px;
    }
    
    .cta-content h2 { font-size: 22px; }
    .cta-content p { font-size: 14px; }
    
    .about-grid {
        margin-top: 30px;
        margin-bottom: 50px;
        padding: 0 15px;
    }
    
    .about-text h2 { font-size: 22px; }
    .about-text p { font-size: 14px; }
    
    .footer {
        padding: 30px 15px;
        font-size: 13px;
    }
    
    .social-links { gap: 12px; }
    .social-links a { font-size: 11px; }
    
    .search-title {
        font-size: 20px;
    }
    
    .search-count {
        font-size: 13px;
    }
    
    .search-card-info {
        padding: 18px;
    }
    
    .search-card-info h3 {
        font-size: 17px;
    }
    
    .category-filter {
        gap: 6px;
    }
    
    .filter-btn {
        padding: 6px 12px;
        font-size: 9px;
    }
}

/* ОЧЕНЬ МАЛЕНЬКИЕ ЭКРАНЫ (380px) */
@media (max-width: 380px) {
    
    .burger {
        width: 26px;
        height: 20px;
    }
    
    .burger span {
        height: 2.5px;
    }
    
    .burger.active span:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .burger.active span:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .hero-content h1 { font-size: 22px; }
    .hero-content p { font-size: 13px; }
    
    .section-title { font-size: 20px; }
    
    .post-info h3 a { font-size: 15px; }
    
    .article-header h1 { font-size: 20px; }
    
    .article-content { font-size: 14px; }
    
    .about-text h2 { font-size: 20px; }
    
    .cta-content h2 { font-size: 20px; }
    
    #popular-posts .section-title { font-size: 18px; }
    
    .header-likes { padding: 3px 8px; font-size: 11px; }
    .header-likes span:last-child { font-size: 11px; }
}

/* ЛАНДШАФТНАЯ ОРИЕНТАЦИЯ */
@media (max-height: 500px) and (orientation: landscape) {
    .hero {
        height: 100vh;
        min-height: 300px;
    }
    
    .hero-content h1 { font-size: 28px; }
    .hero-content p { font-size: 14px; margin-bottom: 15px; }
    
    .video-hero { height: 100vh; }
}

/* БЕЗОПАСНЫЕ ЗОНЫ ДЛЯ iOS */
@supports (padding: max(0px)) {
    .header {
        padding-top: max(15px, env(safe-area-inset-top));
    }
    
    .footer {
        padding-bottom: max(50px, env(safe-area-inset-bottom));
    }
    
    #scrollTop {
        bottom: max(30px, env(safe-area-inset-bottom));
        right: max(30px, env(safe-area-inset-right));
    }
}

/* ЗАЩИТА ОТ ПЕРЕПОЛНЕНИЯ */
html {
    overflow-x: hidden;
}

body {
    overflow-x: hidden;
    -webkit-text-size-adjust: 100%;
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   ПРИНУДИТЕЛЬНАЯ АДАПТАЦИЯ (если ничего не помогает)
   ========================================================================== */

@media (max-width: 768px) {
    /* ПОСЛЕДНИЕ СТАТЬИ — 1 колонка */
    .posts-grid,
    .trending-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 25px;
        width: 100%;
        max-width: 100%;
        padding: 0;
        margin: 0 auto 50px;
    }
    
    .post-card,
    .trending-item {
        width: 100%;
        max-width: 100%;
        margin: 0;
    }
    
    /* БУРГЕР — показываем */
    .burger {
        display: flex;
    }
    
    /* HEADER — в ряд */
    .header-container {
        flex-wrap: wrap;
        flex-direction: row;
    }
    
    /* NAV — выпадающее меню */
    .nav {
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
        flex-basis: 100%;
        order: 5;
    }
    
    .nav.active {
        max-height: 400px;
    }
    
    .nav ul {
        flex-direction: column;
    }
    
    .nav ul li {
        width: 100%;
        text-align: center;
    }
    
    /* MAIN LAYOUT — 1 колонка */
    .main-layout {
        grid-template-columns: 1fr;
    }
    
    /* VALUES — 1 колонка */
    .values-grid {
        grid-template-columns: 1fr;
    }
}
/**/
/* ==========================================================================
   ФИНАЛЬНАЯ АДАПТАЦИЯ ДЛЯ ТЕЛЕФОНА
   ========================================================================== */

/* ПЛАНШЕТЫ (768-992px) */
@media (max-width: 992px) {
    .container {
        padding: 0 15px;
    }
    
    .hero-content h1 {
        font-size: 36px;
    }
    
    .values-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .trending-grid,
    .posts-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }
    
    .trending-img-wrapper {
        height: 400px;
    }
    
    .main-layout {
        grid-template-columns: 1fr;
    }
}

/* ТЕЛЕФОНЫ (до 768px) */
@media (max-width: 768px) {
    
    /* === ШАПКА === */
    .header {
        padding: 10px 0;
    }
    
    .header-container {
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .logo-img {
        height: 45px;
    }
    
    /* БУРГЕР - ПОКАЗЫВАЕМ */
    .burger {
        display: flex;
        order: 99;
        margin-left: auto;
        width: 30px;
        height: 22px;
    }
    
    .burger span {
        height: 3px;
        background: #003355;
    }
    
    /* СКРЫВАЕМ ОБЫЧНОЕ МЕНЮ НА ТЕЛЕФОНЕ */
    .nav {
        order: 100;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease;
        flex-basis: 100%;
    }
    
    .nav.active {
        max-height: 500px;
        margin-top: 15px;
        padding-top: 15px;
        border-top: 1px solid #eee;
    }
    
    .nav ul {
        flex-direction: column;
        background: #fff;
        border-radius: 8px;
        padding: 10px;
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        width: 100%;
        gap: 0;
    }
    
    .nav ul li {
        margin: 0;
        width: 100%;
        text-align: center;
        padding: 12px 0;
        border-bottom: 1px solid #f0f0f0;
    }
    
    .nav ul li:last-child {
        border-bottom: none;
    }
    
    .nav ul li a {
        font-size: 14px;
        display: block;
        padding: 5px 0;
    }
    
    .header-likes {
        font-size: 11px;
        padding: 4px 8px;
        margin-left: auto;
    }
    
    .search-box input {
        width: 100px;
        font-size: 12px;
    }
    
    /* === HERO === */
    .hero {
        height: 50vh;
        min-height: 300px;
        padding: 20px;
    }
    
    .hero-content h1 {
        font-size: 26px;
        line-height: 1.2;
        margin-bottom: 10px;
    }
    
    .hero-content p {
        font-size: 14px;
        margin-bottom: 20px;
    }
    
    .btn {
        padding: 10px 25px;
        font-size: 11px;
    }
    
    /* === ЦЕННОСТИ === */
    .values {
        padding: 40px 0;
    }
    
    .values-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        max-width: 400px;
        margin: 0 auto;
    }
    
    .value-item {
        padding: 20px 15px;
    }
    
    /* === АКТУАЛЬНОЕ (TRENDING) === */
    .trending {
        padding: 40px 0;
    }
    
    .trending-grid {
        grid-template-columns: 1fr;
        gap: 30px;
        max-width: 500px;
        margin: 0 auto;
    }
    
    .trending-img-wrapper {
        height: auto;
        aspect-ratio: 3 / 4;
    }
    
    .trending-img-wrapper img {
        height: 100%;
        object-fit: cover;
    }
    
    /* === CTA === */
    .cta-banner {
        padding: 50px 20px;
        margin: 40px 0;
    }
    
    .cta-content h2 {
        font-size: 22px;
    }
    
    .cta-content p {
        font-size: 14px;
    }
    
    /* === ОСНОВНОЙ МАКЕТ === */
    .main-layout {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px 15px;
        margin-top: -20px;
    }
    
    .section-title {
        font-size: 22px;
        margin-bottom: 20px;
    }
    
    /* === ПОСЛЕДНИЕ СТАТЬИ - ГЛАВНОЕ ИСПРАВЛЕНИЕ === */
    .posts-grid {
        display: grid;
        grid-template-columns: 1fr;
        gap: 20px;
        margin-bottom: 40px;
        padding: 0;
        width: 100%;
        max-width: 100%;
    }
    
    .post-card {
        width: 100%;
        max-width: 100%;
        margin: 0;
    }
    
    .post-img {
        width: 100%;
    }
    
    .post-img img {
        width: 100%;
        height: 250px;
        object-fit: cover;
        display: block;
    }
    
    .post-info {
        width: 100%;
        padding: 15px;
        box-sizing: border-box;
    }
    
    .post-info h3 a {
        font-size: 16px;
    }
    
    .post-info p {
        font-size: 13px;
    }
    
    /* === САЙДБАР === */
    .sidebar-widget {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .sidebar-widget h2 {
        font-size: 18px;
    }
    
    /* === ПОПУЛЯРНОЕ === */
    #popular-posts {
        padding: 30px 20px;
        border-radius: 15px;
        margin: 30px 10px;
    }
    
    #popular-posts .section-title {
        font-size: 20px;
        margin-bottom: 25px;
    }
    
    .popular-list {
        gap: 15px;
    }
    
    .pop-item img {
        width: 45px;
        height: 45px;
    }
    
    .pop-item a {
        font-size: 13px;
    }
    
    /* === ФУТЕР === */
    .footer {
        padding: 30px 15px;
    }
    
    .footer p {
        font-size: 12px;
    }
    
    .social-links {
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .social-links a {
        font-size: 12px;
    }
    
    /* === КНОПКА SAVE === */
    .save-btn {
        width: 35px;
        height: 35px;
        font-size: 14px;
        top: 8px;
        right: 8px;
    }
    
    /* === SCROLL TOP === */
    #scrollTop {
        width: 40px;
        height: 40px;
        bottom: 15px;
        right: 15px;
        font-size: 18px;
    }
}

/* МАЛЕНЬКИЕ ТЕЛЕФОНЫ (до 480px) */
@media (max-width: 480px) {
    
    .container {
        padding: 0 12px;
    }
    
    .logo-img {
        height: 40px;
    }
    
    .burger {
        width: 26px;
        height: 18px;
    }
    
    .hero-content h1 {
        font-size: 22px;
    }
    
    .hero-content p {
        font-size: 13px;
    }
    
    .section-title {
        font-size: 20px;
    }
    
    .post-img img {
        height: 220px;
    }
    
    .post-info h3 a {
        font-size: 15px;
    }
    
    #popular-posts {
        margin: 20px 8px;
        padding: 25px 15px;
    }
    
    .cta-content h2 {
        font-size: 20px;
    }
    
    .search-box input {
        width: 90px;
    }
}
