/* GLOBAL RESPONSIVE RULES */

/* overflow-x sadece body'de (main.css); html'e clip vermek fixed elemanları bozabiliyor */
html {
    max-width: 100%;
}

body {
    max-width: 100%;
    overflow-x: hidden;
}

body.page-home .hero {
    width: 100%;
    min-height: 100svh;
    padding-top: 0;
    padding-bottom: 0;
}

body.page-home .hero__bg {
    inset: 0;
    background-size: cover;
    background-position: center center;
}

body.page-home .hero__content {
    width: min(1120px, calc(100% - 2rem));
}

@media (max-width: 1200px) {
    .site-header {
        padding: 1.15rem 2rem 0.9rem;
    }

    .site-footer {
        padding: 1.4rem 2rem 1.8rem;
    }

    .products {
        padding: 2.5rem 1.5rem 3.25rem;
    }

    .products__grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .products__hero-image {
        min-height: 460px;
    }

    .testimonials {
        background-attachment: scroll;
    }
}

@media (max-width: 992px) {
    :root {
        --site-head-offset: 96px;
    }

    .top-bar {
        font-size: 0.72rem;
        padding: 7px 0;
    }

    .site-header {
        padding: 1rem 1.2rem 0.8rem;
    }

    .site-header__logo {
        font-size: 1.2rem;
        letter-spacing: 0.18em;
    }

    .site-header__actions {
        gap: 0.7rem;
    }

    .site-drawer__panel,
    .site-cart-drawer__panel {
        width: min(94vw, 360px);
    }

    .hero {
        min-height: 84vh;
        padding-top: 6.5rem;
        padding-bottom: 2rem;
    }

    .hero__content {
        width: min(100%, calc(100% - 2rem));
        padding: 1.2rem;
    }

    .hero__layout {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .hero__right {
        grid-template-rows: none;
        grid-template-columns: 1fr 1fr;
    }

    .hero__features {
        grid-template-columns: 1fr;
    }

    .about-products {
        margin-top: 1rem;
        padding: 0;
    }

    /* Masaüstü ile aynı hiyerarşi: koyu şerit, sol üst görsel, ortada kartlar, altta model + dönen yazı */
    .about-products__cards-wrap {
        position: relative;
        margin-top: 1.25rem;
        min-height: clamp(620px, 165vw, 840px);
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        overflow: hidden;
        border-radius: 0;
        background-color: #656155 !important;
        display: block;
        align-items: stretch;
        justify-content: flex-start;
    }

    .about-products__left-cards {
        position: absolute;
        z-index: 6;
        left: 50%;
        top: 36%;
        transform: translate(-50%, -50%);
        width: min(92%, 420px);
        max-width: none;
        display: flex;
        flex-direction: column;
        gap: 0.7rem;
        box-sizing: border-box;
    }

    .about-products__left-card {
        flex: 1 1 auto;
        margin: 0;
        padding: 0.95rem 1rem;
        border-radius: 12px;
        background-color: rgba(18, 16, 12, 0.42);
        border: 1px solid rgba(255, 255, 255, 0.22);
        backdrop-filter: blur(1px);
    }

    .about-products__left-card-title {
        color: #fff;
        font-size: 0.82rem;
        margin-bottom: 0.35rem;
    }

    .about-products__left-card-text {
        color: rgba(255, 255, 255, 0.9);
        font-size: 0.82rem;
        line-height: 1.58;
    }

    /* Sol üst: geniş görsel (masaüstündeki --2) */
    .about-products__feature-img--2 {
        display: block !important;
        position: absolute;
        z-index: 4;
        left: 0;
        top: 0;
        right: auto;
        bottom: auto;
        width: min(40%, 190px);
        height: auto;
        max-height: 26%;
        object-fit: cover;
        transform: none;
    }

    /* Altta ortada model görseli */
    .about-products__feature-img:not(.about-products__feature-img--2) {
        display: block !important;
        position: absolute;
        z-index: 3;
        left: 50%;
        right: auto;
        bottom: 0;
        top: auto;
        width: min(54%, 250px);
        height: auto;
        max-height: 42%;
        object-fit: cover;
        transform: translateX(-50%);
        margin: 0;
    }

    .about-products__circle-text {
        display: flex !important;
        position: absolute;
        z-index: 2;
        inset: auto 0 6% 0;
        align-items: center;
        justify-content: center;
        pointer-events: none;
    }

    .about-products__circle-svg {
        display: block !important;
        position: relative;
        left: auto;
        right: auto;
        top: auto;
        transform: none;
        width: min(60vw, 230px);
        height: min(60vw, 230px);
        margin: 0 auto;
    }

    .testimonials {
        margin-top: 2.25rem;
        padding: 3rem 0;
        width: 100vw;
        margin-left: calc(50% - 50vw);
        margin-right: calc(50% - 50vw);
        background: none;
        overflow: hidden;
    }

    .testimonials::before {
        content: "";
        position: absolute;
        inset: -14% 0 -14% 0;
        background-image: url("../img/review.png");
        background-size: cover;
        background-position: center;
        background-repeat: no-repeat;
        transform: translate3d(0, var(--t-bg-shift, 0px), 0);
        will-change: transform;
        z-index: 0;
    }

    .testimonials__inner {
        position: relative;
        z-index: 1;
    }

    .testimonials__inner {
        padding: 0;
    }

    .testimonials__grid {
        display: flex;
        gap: 0.65rem;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
        padding: 0 0.7rem 0.25rem;
    }

    .testimonials__grid::-webkit-scrollbar {
        height: 6px;
    }

    .testimonials__grid > .testimonial-card {
        flex: 0 0 82vw;
        scroll-snap-align: start;
    }

    .testimonial-card {
        padding: 1rem 0.95rem;
        border-radius: 12px;
        gap: 0.75rem;
        min-height: auto;
    }

    .testimonial-card__text {
        font-size: 0.84rem;
        line-height: 1.55;
    }

    .testimonial-card__meta {
        font-size: 0.8rem;
    }
}


@media (max-width: 768px) {
    .auth-flash {
        font-size: 0.75rem;
        padding: 0.35rem 0.7rem;
    }

    .site-header__logo {
        font-size: 1.02rem;
        letter-spacing: 0.14em;
        max-width: 58vw;
        text-align: center;
        line-height: 1.2;
    }

    .site-header__icon-btn {
        font-size: 1rem;
    }

    body.page-home .hero {
        min-height: 100svh;
    }

    .hero__title {
        font-size: 1.5rem;
    }

    .hero__text {
        font-size: 0.9rem;
        line-height: 1.6;
    }

    .hero__right {
        grid-template-columns: 1fr;
    }

    .products {
        padding-inline: 1rem;
    }

    .products-grid__head,
    .video-strip__head {
        align-items: center;
        gap: 0.6rem;
    }

    .products-grid__title,
    .video-strip__title {
        font-size: 1rem;
        letter-spacing: 0.08em;
    }

    .products-grid__list {
        gap: 0.85rem;
    }

    .products-grid__list > .products-grid__card {
        flex-basis: calc((100% - 0.85rem) / 2);
        max-width: calc((100% - 0.85rem) / 2);
    }

    .video-strip__row {
        gap: 0.65rem;
    }

    .video-strip__row > .video-card {
        flex-basis: calc((100% - 0.65rem) / 2);
        max-width: calc((100% - 0.65rem) / 2);
    }

    .product-card {
        grid-template-columns: 1fr;
        padding: 0;
    }

    .product-card__thumb {
        min-height: 260px;
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }

    .product-card__content {
        border-left: none;
        border-top: 1px solid rgba(0, 0, 0, 0.08);
        padding: 1rem;
    }

    .site-footer {
        margin-top: 0;
        padding: 1.15rem 1rem 1.5rem;
    }

    .site-footer__inner {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 0.6rem;
        font-size: 0.74rem;
    }

    .site-footer__nav {
        flex-wrap: nowrap;
        gap: 0.6rem;
        white-space: nowrap;
    }

    .scroll-top-fab {
        right: 0.8rem;
        bottom: 1rem;
        width: 2.65rem;
        height: 2.65rem;
    }
}

@media (max-width: 576px) {
    :root {
        --site-head-offset: 88px;
    }

    .site-drawer__panel,
    .site-cart-drawer__panel {
        width: 100%;
    }

    .site-cart-drawer__item {
        grid-template-columns: 64px minmax(0, 1fr);
    }

    .site-cart-drawer__thumb,
    .site-cart-drawer__thumb-ph {
        width: 64px;
        height: 82px;
    }

    .site-cart-drawer__body {
        padding: 0.8rem;
    }

    body.page-home .hero {
        min-height: 100svh;
    }

    .hero__content {
        width: calc(100% - 1.1rem);
        padding: 1rem;
        border-radius: 1rem;
    }

    .hero__subtitle {
        font-size: 0.72rem;
    }

    .hero__title {
        font-size: 1.32rem;
        margin-top: 0.55rem;
    }

    .hero__cta {
        width: 100%;
        min-width: 0;
        padding: 0.78rem 1rem;
        font-size: 0.78rem;
    }

    .products-grid__list > .products-grid__card,
    .video-strip__row > .video-card {
        flex-basis: 86%;
        max-width: 86%;
    }

    .products-grid__image-wrap {
        aspect-ratio: 3 / 4.35;
        margin-bottom: 0.7rem;
    }

    .products-grid__image {
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center center;
    }

    .about-products__title {
        font-size: 1.1rem;
        letter-spacing: 0.1em;
        line-height: 1.3;
        margin-bottom: 0.45rem;
    }

    .about-products__lead {
        font-size: 0.9rem;
        line-height: 1.55;
        margin-bottom: 1rem;
    }

    .about-products__cards-wrap {
        min-height: clamp(600px, 165vw, 760px);
    }

    .about-products__left-cards {
        width: min(92%, 350px);
        top: 35%;
        gap: 0.55rem;
    }

    .about-products__left-card {
        padding: 0.85rem 0.9rem;
    }

    .about-products__left-card-title {
        font-size: 0.78rem;
        line-height: 1.3;
    }

    .about-products__left-card-text {
        font-size: 0.78rem;
        line-height: 1.5;
    }

    .about-products__feature-img--2 {
        width: min(40%, 160px);
        max-height: 24%;
        top: 0;
    }

    .about-products__feature-img:not(.about-products__feature-img--2) {
        width: min(52%, 210px);
        max-height: 39%;
    }

    .about-products__circle-text {
        inset: auto 0 6% 0;
    }

    .about-products__circle-svg {
        width: min(56vw, 190px);
        height: min(56vw, 190px);
    }

    .testimonial-card {
        padding: 1.25rem 1rem;
    }

    .testimonial-card__text {
        font-size: 0.9rem;
        line-height: 1.65;
    }
}

/* PAGE SPECIFIC FALLBACKS */
@media (max-width: 992px) {
    .shop-catalog {
        padding-top: 6rem;
    }

    .shop-catalog__shell,
    .product-detail__shell,
    .cart-page__shell,
    .checkout-page,
    .account-wrap {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .shop-grid {
        grid-template-columns: 1fr 1fr;
        gap: 1.1rem 0.85rem;
    }

    .product-detail {
        padding-top: 6rem;
    }

    .product-detail__layout--editorial {
        grid-template-columns: 1fr;
        gap: 1.2rem;
    }

    .product-detail__sticky {
        position: static;
        top: auto;
        padding: 0;
    }

    .product-detail__actions--split {
        grid-template-columns: 1fr;
    }

    .cart-page__footer {
        flex-direction: column;
    }

    .checkout-page {
        padding-top: 6rem;
    }

    .checkout-panel {
        padding: 1.1rem 1rem;
    }

    .checkout-steps {
        justify-content: flex-start;
        gap: 0.5rem 0.75rem;
        overflow-x: auto;
        flex-wrap: nowrap;
        padding-bottom: 0.35rem;
    }

    .checkout-steps__item {
        white-space: nowrap;
        flex: 0 0 auto;
    }

    .checkout-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .checkout-aside {
        position: static;
        top: auto;
    }

    .checkout-review-addr {
        grid-template-columns: 1fr;
    }

    .checkout-modal__panel,
    .account-address-modal__panel,
    .account-order-modal__panel {
        width: calc(100% - 1rem);
        margin: 0.5rem auto;
        max-height: calc(100vh - 1rem);
    }

    .account-wrap {
        grid-template-columns: 1fr;
        gap: 1rem;
        padding-top: 6.25rem;
    }

    .account-order-card {
        grid-template-columns: 56px minmax(0, 1fr);
        align-items: start;
    }

    .account-order-card__right {
        grid-column: 1 / -1;
        align-items: flex-start;
    }

    .shop-catalog__filters-toggle {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
        margin: 0 0 1rem;
        padding: 0.62rem 0.9rem;
        border: 1px solid var(--shop-border);
        border-radius: 0.25rem;
        background: #fff;
        color: var(--text-primary);
        font-family: "Poppins", sans-serif;
        font-size: 0.72rem;
        font-weight: 600;
        letter-spacing: 0.12em;
        text-transform: uppercase;
        cursor: pointer;
    }

    .shop-catalog__filters-drawer {
        position: fixed;
        inset: 0;
        z-index: 1200;
        pointer-events: none;
        visibility: hidden;
        opacity: 0;
        transition: opacity 0.2s ease;
    }

    .shop-catalog__filters-drawer.is-open {
        pointer-events: auto;
        visibility: visible;
        opacity: 1;
    }

    .shop-catalog__filters-backdrop {
        display: block;
        position: absolute;
        left: 0;
        right: 0;
        bottom: 0;
        top: var(--site-head-offset, 0px);
        background: rgba(0, 0, 0, 0.44);
    }

    .shop-catalog__filters-panel {
        position: absolute;
        top: var(--site-head-offset, 0px);
        left: 0;
        height: calc(100% - var(--site-head-offset, 0px));
        width: min(88vw, 360px);
        background: #fff;
        box-shadow: 8px 0 22px rgba(0, 0, 0, 0.15);
        transform: translateX(-100%);
        transition: transform 0.24s ease;
        padding: 0.95rem 0.9rem 1rem;
        overflow-y: auto;
    }

    .shop-catalog__filters-drawer.is-open .shop-catalog__filters-panel {
        transform: translateX(0);
    }

    .shop-catalog__filters-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding-bottom: 0.65rem;
        border-bottom: 1px solid var(--shop-border);
        margin-bottom: 0.8rem;
    }

    .shop-catalog__filters-title {
        margin: 0;
        font-size: 0.76rem;
        font-weight: 700;
        letter-spacing: 0.15em;
        text-transform: uppercase;
        color: var(--text-primary);
    }

    .shop-catalog__filters-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 34px;
        height: 34px;
        border: 1px solid var(--shop-border);
        border-radius: 0.2rem;
        background: #fff;
        color: var(--text-primary);
        cursor: pointer;
    }

    .shop-catalog__filters {
        margin-bottom: 0;
        padding-bottom: 0;
        border-bottom: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0.9rem;
    }

    .shop-catalog__filter-group {
        min-width: 0;
        width: 100%;
    }

    .shop-catalog__cat-select-desktop {
        display: none;
    }

    .shop-catalog__cat-dropdown-mobile {
        display: block;
    }

    .shop-catalog__cat-dropdown-mobile .shop-catalog__cat-toggle {
        display: none;
    }

    .shop-catalog__cat-dropdown-mobile .shop-catalog__cat-menu {
        margin-top: 0;
    }
}

@media (max-width: 520px) {
    .shop-grid {
        grid-template-columns: 1fr;
    }

    .product-detail__rail-grid > .product-detail__figure {
        flex-basis: 100%;
        max-width: 100%;
    }

    .checkout-btn,
    .cart-page__btn,
    .account-form__submit,
    .account-empty-cta {
        width: 100%;
        justify-content: center;
    }
}

body.shop-filters-open {
    overflow: hidden;
}
