.page-blog {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background: #fff;
}

.page-blog .nav {
    padding: 0 1.4rem;
    height: 120px;
}

.page-blog .site-header {
    height: 120px;
}

.page-blog .nav__toggle-bar {
    background: var(--orange);
}

.page-blog .nav__menu {
    color: #f0b27a;
    font-weight: 500;
}

.page-blog .nav__menu a:hover {
    color: var(--orange);
    opacity: 1;
}

.page-blog .nav__cart {
    background: transparent;
    color: var(--orange);
    border: 1.6px solid var(--orange);
    box-shadow: none;
    border-radius: 8px;
    position: relative;
}

.page-blog .nav__cart-count {
    background: var(--orange);
    color: #fff;
}

.blog-hero {
    max-width: 1120px;
    margin: 0 auto;
    padding: 40px 1.4rem 2.4rem 30px;
    display: grid;
    grid-template-columns: 0.9fr 1.1fr;
    gap: 2rem 3rem;
    align-items: center;
}

.blog-hero__product {
    display: flex;
    justify-content: center;
}

.blog-hero__product img {
    width: min(220px, 100%);
    filter: drop-shadow(0 18px 28px rgba(80, 40, 0, 0.18));
}

.blog-hero__copy h1 {
    margin: 0 0 1rem;
    color: var(--orange);
    font-size: clamp(1.8rem, 3.6vw, 2.55rem);
    font-weight: 700;
    line-height: 1.15;
}

.blog-hero__copy p {
    margin: 0;
    max-width: 38ch;
    color: #333;
    font-size: 1.02rem;
    line-height: 1.55;
}

.blog-grid {
    max-width: 1120px;
    margin: 0 auto;
    padding: 0 1.4rem 1.4rem;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.5rem 1.25rem;
}

.blog-card {
    background: #fff;
    border-radius: 22px;
    box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
    padding: 1.05rem 1.05rem 0.9rem;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.blog-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.12);
}

.blog-card:focus-visible {
    outline: 2px solid var(--orange);
    outline-offset: 3px;
}

.blog-card h2 {
    margin: 0 0 0.75rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: #1d1d1d;
    line-height: 1.25;
    min-height: 2.5em;
}

.blog-card__media {
    position: relative;
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 5 / 4;
    background: #eee;
}

.blog-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center center;
    display: block;
}

.blog-card__media p {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    margin: 0;
    padding: 2.6rem 0.95rem 0.9rem;
    color: #fff;
    font-size: 0.8rem;
    line-height: 1.35;
    background: linear-gradient(180deg, rgba(238, 125, 4, 0) 0%, rgba(238, 125, 4, 0.88) 38%, #EE7D04 72%);
}

.blog-card__more {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    margin-top: 0.75rem;
    color: #6b63e8;
    font-size: 0.92rem;
    font-weight: 500;
}

.blog-card__more:hover {
    text-decoration: underline;
}

.blog-cta {
    display: flex;
    justify-content: center;
    padding: 1.4rem 1rem 2.8rem;
}

.blog-cta__btn {
    font-size: 1.45rem;
    padding: 0.85rem 1.5rem;
    border-radius: 8px;
}

@media (max-width: 980px) {
    .blog-hero {
        grid-template-columns: 1fr 1fr;
        gap: 1.2rem;
    }

    .blog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .page-blog .nav__menu {
        color: var(--text);
    }

    .page-blog .nav__cart {
        color: var(--orange);
        justify-content: center;
    }

    .blog-hero {
        grid-template-columns: 1fr;
        text-align: center;
        padding-top: 0.4rem;
    }

    .blog-hero__copy p {
        max-width: none;
        margin: 0 auto;
    }

    .blog-hero__product img {
        width: min(240px, 70vw);
    }
}

@media (max-width: 560px) {
    .blog-grid {
        grid-template-columns: 1fr;
        max-width: 420px;
        margin-left: auto;
        margin-right: auto;
    }

    .blog-card h2 {
        min-height: 0;
    }
}

body.blog-modal-open {
    overflow: hidden;
}

.blog-modal {
    position: fixed;
    inset: 0;
    z-index: 200;
    display: none;
    place-items: center;
    padding: 1.2rem;
    background: rgba(40, 32, 28, 0.55);
    pointer-events: none;
}

.blog-modal.is-open {
    display: grid;
    pointer-events: auto;
}

.blog-modal[hidden] {
    display: none !important;
    pointer-events: none !important;
}

.blog-modal__dialog {
    width: min(780px, 100%);
    max-height: min(88vh, 820px);
    background: #fff;
    border-radius: 28px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.22);
}

.blog-modal__hero {
    position: relative;
    min-height: 240px;
    height: 42vh;
    max-height: 380px;
    flex-shrink: 0;
}

.blog-modal__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 20%;
    display: block;
}

.blog-modal__back {
    position: absolute;
    top: 1.1rem;
    left: 1.2rem;
    z-index: 2;
    border: 0;
    background: transparent;
    color: #fff;
    font-family: inherit;
    font-size: 1.5rem;
    font-weight: 700;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
}

.blog-modal__title {
    position: absolute;
    left: 1.2rem;
    right: 1.2rem;
    bottom: 0;
    margin: 0;
    padding: 3.2rem 0.5rem 1.55rem;
    color: #fff;
    text-align: center;
    font-size: clamp(2rem, 4.6vw, 3rem);
    font-weight: 700;
    line-height: 1.12;
    background: linear-gradient(180deg, rgba(238, 125, 4, 0) 0%, rgba(238, 125, 4, 0.55) 38%, rgba(238, 125, 4, 0.92) 72%, #EE7D04 100%);
}

.blog-modal__panel {
    background: #fff;
    margin-top: -18px;
    position: relative;
    border-radius: 0 0 28px 28px;
    min-height: 180px;
    flex: 1;
    display: flex;
}

.blog-modal__scroll {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem 2rem 1.8rem 1.8rem;
    margin: 0.2rem 0.55rem 0.7rem 0;
    max-height: min(42vh, 340px);
    scrollbar-gutter: stable;
    scrollbar-width: thin;
    scrollbar-color: #EE7D04 transparent;
}

.blog-modal__scroll::-webkit-scrollbar {
    width: 7px;
}

.blog-modal__scroll::-webkit-scrollbar-track {
    background: transparent;
}

.blog-modal__scroll::-webkit-scrollbar-thumb {
    background: #EE7D04;
    border-radius: 99px;
}

.blog-modal__scroll p {
    margin: 0 0 1.1rem;
    color: #222;
    font-size: 1.12rem;
    line-height: 1.5;
}

.blog-modal__scroll p:last-child {
    margin-bottom: 0;
}

@media (max-width: 640px) {
    .blog-modal {
        padding: 0.6rem;
        align-items: end;
    }

    .blog-modal__dialog {
        max-height: 92vh;
        border-radius: 22px;
    }

    .blog-modal__hero {
        height: 28vh;
        min-height: 180px;
    }

    .blog-modal__title {
        font-size: 1.55rem;
        padding-bottom: 1.3rem;
    }

    .blog-modal__scroll {
        padding: 1.15rem 1.2rem 1.4rem 1.15rem;
        font-size: 1rem;
        max-height: 46vh;
    }
}
