/* ── RESPONSIVE / MEDIA QUERIES ─────────────────────────────────────────── */

/* Large Tablets & Small Laptops */
@media (max-width: 1200px) {
    :root {
        --section-y: 72px;
    }

    .w_nav {
        width: calc(100% - 32px);
    }

    .w_nav .w_nav_logo_name {
        display: none;
    }

    .w_nav_links {
        display: none;
    }

    .w_mobile_toggle {
        display: flex;
    }

    .w_nav_actions .btn_nav_auth,
    .w_nav_actions .btn_nav_login {
        display: none;
    }

    .w_shop_layout {
        grid-template-columns: 220px 1fr;
        gap: 20px;
    }

    .w_product_layout {
        gap: 36px;
    }

    .w_footer_grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
        gap: 28px;
    }

    .w_footer_brand_col {
        grid-column: 1 / -1;
        display: flex;
        flex-direction: column;
        gap: 0;
        align-items: flex-start;
    }

    .w_footer_brand_desc {
        max-width: 520px;
    }

    .wpc_grid_4 {
        grid-template-columns: repeat(3, 1fr);
    }

    .w_newsletter_section_inner {
        gap: 32px;
    }

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

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

    .w_steps_grid::before {
        display: none;
    }

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

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

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

    .w_footer_cta {
        padding: 32px;
    }

    .w_footer_cta_text h2 {
        font-size: clamp(30px, 6vw, 54px);
        margin: 1.5rem auto;
    }

    .w_hero_visual {
        flex: 0 0 300px;
        width: 300px;
        height: 300px;
    }

    .w_hero_brand_chip {
        padding: 8px 14px 8px 11px;
    }

    .w_hero_brand_name {
        font-size: 12px;
    }
}

/* Tablets */
@media (max-width: 1024px) {
    :root {
        --section-y: 60px;
    }

    .w_nav {
        width: calc(100% - 24px);
    }

    .w_mobile_menu {
        width: calc(100% - 24px);
    }

    .w_auth,
    .w_auth_page {
        grid-template-columns: 1fr;
    }

    .w_auth_brand {
        display: none;
    }

    .w_auth_form_side {
        min-height: 100vh;
        padding: 40px 32px;
    }

    .w_contact_layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .w_cart_layout {
        grid-template-columns: 1fr;
        margin-top: 0;
    }

    .w_cart_summary {
        position: static;
    }

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

    .w_checkout_summary_col {
        position: static;
    }

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

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

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

    .w_order_view_aside {
        position: static;
    }

    .w_profile_dashboard,
    .w_profile_main_grid {
        grid-template-columns: 1fr;
    }

    .w_profile_aside {
        position: static;
    }

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

    .w_product_layout {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .w_product_gallery {
        position: static;
        overflow: hidden;
    }

    .w_product_main_img {
        border-radius: var(--r-lg);
    }

    .w_product_title {
        font-size: clamp(21px, 2.5vw, 30px);
    }

    .w_pd_spec_row {
        gap: 30px;
        padding: 10px 0;
    }

    .w_related_section {
        margin-top: 1.5rem;
        padding-top: 1rem;
    }

    .w_footer_grid {
        grid-template-columns: 1fr 1fr;
        gap: 32px;
    }

    .w_footer_brand_col {
        grid-column: 1 / -1;
        display: flex;
        flex-direction: column;
        padding-inline-end: 0;
    }

    .w_footer_social {
        margin-bottom: 0;
    }

    .w_footer_cta {
        flex-direction: column;
        align-items: flex-start;
    }

    .w_footer_social {
        margin-inline-start: 0;
    }

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

    .w_hero_deco_circle_1,
    .w_hero_deco_circle_2 {
        display: none;
    }

    .w_hero .w_hero_arrows {
        bottom: 20px;
        right: 20px;
    }

    .w_hero_visual {
        display: none;
    }

    .w_newsletter_section_inner {
        grid-template-columns: 1fr;
        gap: 32px;
        text-align: center;
        padding: 26px 22px;
    }

    .w_newsletter_section_text p {
        max-width: 100%;
    }

    .w_newsletter_section_form {
        padding: 18px;
    }

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

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

    .w_perk_item:nth-child(3) {
        border-inline-start: none;
        border-top: 1px solid var(--c-border);
    }

    .w_perk_item:nth-child(4) {
        border-top: 1px solid var(--c-border);
    }

    .w_stats_grid,
    .w_brand_wall,
    .w_condition_grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Mobile */
@media (max-width: 768px) {
    :root {
        --section-y: 48px;
        --nav-height: 56px;
    }

    .w_nav_lang_trigger {
        padding: 0 5px;
    }

    .btn_logout {
        display: none;
    }

    /* The currency trigger sits close to the nav's start edge on mobile, so a
       menu anchored to its own end (growing toward the start/left in LTR)
       runs off the edge of the screen. Anchor to the start instead so it
       grows toward the middle of the screen, where there's actually room. */
    .w_nav_lang_menu {
        inset-inline-start: 0;
        inset-inline-end: auto;
        min-width: 11rem;
        max-width: calc(100vw - 32px);
    }

    .w_cart_badge {
        width: 16px;
        height: 16px;
        font-size: 12px;
    }

    .w_nav {
        top: 10px;
        width: calc(100% - 20px);
        height: 54px;
        border-radius: 30px;
    }

    .w_shopnav_inner {
        padding: 0 0.5rem;
    }

    .w_mobile_menu {
        width: calc(100% - 20px);
    }

    .w_container {
        padding: 12px 16px;
        margin-top: 0.5rem;
    }

    .w_pd_sticky_bar {
        display: flex;
        position: fixed;
        left: 0;
        right: 0;
        bottom: 0;
        z-index: 900;
        align-items: center;
        gap: 12px;
        padding: 10px 16px;
        background: var(--c-white);
        border-top: 1px solid var(--c-border);
        box-shadow: 0 -12px 30px rgba(13, 27, 42, .1);
        transform: translateY(100%);
        pointer-events: none;
        transition: transform .3s ease;
    }

    .w_pd_sticky_bar.visible {
        transform: translateY(0);
        pointer-events: auto;
    }

    .w_pd_sticky_info {
        flex: 1 1 auto;
        min-width: 0;
    }

    .w_pd_sticky_name {
        font-size: 12px;
        color: var(--c-text-muted);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .w_pd_sticky_price {
        display: flex;
        align-items: baseline;
        gap: 6px;
    }

    .w_pd_sticky_price_main {
        font-size: 16px;
        font-weight: 700;
        color: var(--c-text);
    }

    .w_pd_sticky_price_original {
        font-size: 12px;
        color: var(--c-text-light);
        text-decoration: line-through;
    }

    .w_pd_sticky_actions {
        display: flex;
        align-items: center;
        gap: 8px;
        flex-shrink: 0;
    }

    .w_pd_sticky_actions .w_pd_share_btn,
    .w_pd_sticky_actions .w_pd_consult_btn {
        width: 40px;
        height: 40px;
        padding: 0;
        justify-content: center;
        flex-shrink: 0;
    }

    .w_pd_sticky_add_btn {
        height: 40px;
        padding: 0 18px;
        font-size: 13px;
    }

    .w_hero {
        height: 90vh;
        max-height: 700px;
    }

    .w_hero_title {
        font-size: clamp(30px, 8vw, 48px);
    }

    .w_hero_subtitle {
        font-size: 14px;
    }

    .w_hero_actions .btn_outline {
        display: none;
    }

    .w_hero_dots {
        bottom: 16px;
    }

    .w_hero_arrows {
        bottom: 16px;
        right: 16px;
    }

    .w_hero_arrow {
        width: 38px;
        height: 38px;
    }

    .w_cats_grid {
        grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
        gap: 12px;
    }

    .wpc_grid,
    .wpc_grid_4 {
        grid-template-columns: minmax(0, 1fr);
        gap: 16px;
    }

    /* Cards go horizontal on mobile (image left, details right) so a row of
       the shop grid uses the screen's width instead of stacking everything
       vertically and forcing a long scroll. */
    .wpc_card {
        flex-direction: row;
        align-items: flex-start;
        height: auto;
    }

    .wpc_card:hover {
        transform: none;
    }

    .wpc_card_img_wrap {
        display: flex;
        flex-direction: column;
        flex: 0 0 104px;
        width: 104px;
        aspect-ratio: auto;
        max-height: none;
        margin-block: 14px;
        margin-inline: 14px 0;
        border-radius: 14px;
    }

    .wpc_card_img_wrap img,
    .wpc_card_img_placeholder {
        flex: 0 0 104px;
        height: 104px;
    }

    .wpc_card_badges {
        top: 0px;
        inset-inline-start: 0px;
        gap: 4px;
    }

    .wpc_card_badge {
        padding: 3px 7px;
        font-size: 9.5px;
    }

    .wpc_card_dots {
        position: static;
        flex: 0 0 auto;
        margin-top: 6px;
    }

    .wpc_card_name {
        font-size: 14.5px;
        min-height: unset;
        -webkit-line-clamp: 5;
        line-clamp: 5;
    }

    .wpc_card_price_main {
        font-size: 14px;
    }

    .wpc_card_body {
        padding-block: 14px;
        padding-inline: 12px 14px;
        gap: 6px;
        position: relative;
    }

    .wpc_card_cart_btn {
        display: none;
    }

    .w_pd_card_body {
        width: 100%;
    }

    .w_section_header {
        margin-bottom: 28px;
    }

    .w_section_header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .w_page_body_full,
    .w_shop_layout,
    .w_shop_content_area,
    .w_shop_grid_wrap {
        min-width: 0;
        overflow-x: clip;
    }

    .w_shop_toolbar_strip {
        flex-wrap: nowrap;
        justify-content: flex-start;
        gap: 10px;
        overflow-x: auto;
        overflow-y: hidden;
        scrollbar-width: none;
        -ms-overflow-style: none;
        overscroll-behavior-x: contain;
        scroll-snap-type: x proximity;
        margin-inline: -16px;
        padding: 10px 16px 12px;
        width: auto;
        /* A sticky element that also owns horizontal scroll/snap makes mobile
           browsers recompute its position every scroll frame, showing up as a
           1px up/down jiggle. Animating `top` makes that jiggle visible as
           motion, so drop the transition here and pin the element to its own
           compositor layer to stop the recalculation. */
        transition: none;
        transform: translateZ(0);
        -webkit-transform: translateZ(0);
        will-change: transform;
    }

    .w_shop_toolbar_strip::-webkit-scrollbar {
        display: none;
    }

    .w_shop_search_wrap {
        width: 100%;
    }

    .w_shop_search {
        padding-right: 108px;
    }

    .w_shop_search_btn {
        padding: 0 14px;
    }

    .w_shop_toolbar_strip>*,
    .w_filter_pill_wrap,
    .w_filter_pill,
    .w_shop_filter_btn,
    .w_shop_sort_mobile_btn {
        flex: 0 0 auto;
        scroll-snap-align: start;
    }

    .w_filter_price_dropdown {
        inset-inline-start: auto;
        inset-inline-end: 0;
    }

    .w_shop_layout {
        padding: 20px 16px;
    }

    .w_shop_filter_pills {
        flex-wrap: nowrap;
        width: max-content;
    }

    .w_shop_sort_select {
        display: none;
    }

    .w_shop_sort_mobile_btn {
        display: inline-flex;
    }

    .w_shop_cats_bar {
        flex-wrap: nowrap;
        width: max-content;
        margin-inline: 0;
        padding: 0 16px 8px;
        overscroll-behavior-x: contain;
        scroll-snap-type: x proximity;
    }

    .w_shop_cats_bar>* {
        scroll-snap-align: start;
    }

    .w_filter_dropdown {
        display: none !important;
    }

    .w_mobile_sheet {
        display: block;
    }

    .w_shop_active_filters {
        justify-content: flex-start;
    }

    .w_product_layout {
        padding: 4px 0;
    }


    .w_ai_feedback_answer {
        min-height: 560px;
    }

    .w_ai_feedback_chat_scroll {
        max-height: 360px;
    }

    .w_ai_chat_bubble {
        max-width: 100%;
    }

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

    .w_ai_chat_bar button {
        min-height: 48px;
    }

    .w_ai_feedback_products .w_ai_product_card {
        grid-template-columns: 78px minmax(0, 1fr);
        gap: 12px;
        padding: 10px;
    }

    .w_ai_feedback_products .w_ai_product_body h3 {
        font-size: 16px;
    }

    .w_product_cart_section {
        flex-direction: column;
    }

    .w_product_price_main {
        font-size: 20px;
    }

    .btn_add_to_cart {
        height: 48px;
        font-size: 14px;
        padding: 1rem;
        width: 100%;
    }

    .w_product_qty {
        width: 100%;
    }

    .w_product_qty_input {
        flex: 1;
    }

    .w_cart_page {
        padding: 24px 16px;
    }

    .w_cart_item {
        flex-wrap: wrap;
        gap: 12px;
        padding: 14px;
    }

    .w_cart_item_img {
        width: 64px;
        height: 64px;
    }

    .w_cart_item_controls {
        flex: none;
        width: 100%;
        justify-content: space-between;
        padding-top: 8px;
        border-top: 1px solid var(--c-border);
        margin-top: 4px;
    }

    .w_profile_shell {
        padding: 24px 0 56px;
    }

    .w_profile_identity {
        align-items: flex-start;
    }

    .w_profile_avatar {
        width: 64px;
        height: 64px;
        font-size: 22px;
    }

    .w_profile_stat_strip {
        flex-direction: column;
    }

    .w_profile_stat_strip_divider {
        width: auto;
        height: 1px;
        margin: 0 20px;
        background: repeating-linear-gradient(90deg, rgba(15, 34, 55, .16) 0 6px, transparent 6px 12px);
    }

    .w_profile_aside_card,
    .w_profile_overview_card,
    .w_profile_panel,
    .w_profile_quick_card,
    .w_profile_info_card {
        border-radius: 24px;
    }

    .w_profile_aside_card,
    .w_profile_overview_card {
        padding: 22px 18px;
    }

    .w_profile_panel {
        padding: 22px 18px;
    }

    .w_profile_panel_head {
        flex-direction: column;
    }

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

    .w_profile_nav {
        margin-top: 20px;
    }

    .w_profile_nav_link {
        min-height: 50px;
    }

    .w_profile_actions .btn_auth_submit {
        width: 100%;
        justify-content: center;
    }

    .w_profile_info_row {
        flex-direction: column;
        align-items: flex-start;
    }

    .w_profile_info_row strong {
        text-align: start;
    }

    .w_contact_form_card {
        padding: 24px 20px;
    }

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

    .w_auth_form_side {
        padding: 32px 20px;
    }

    .w_footer_grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .w_footer_brand_col {
        grid-column: auto;
    }

    .w_footer_main {
        padding: 36px 0 28px;
    }

    .w_footer_cta_wrap {
        padding-top: 28px;
    }

    .w_footer_cta {
        padding: 28px 24px;
        border-radius: 28px;
        text-align: center;
        align-items: center;
    }

    .w_footer_cta_actions {
        width: 100%;
        justify-content: center;
    }

    .w_footer_cta .btn_primary {
        width: 100%;
    }

    .w_footer_logo_name {
        font-size: 28px;
    }

    .w_footer_brand_desc {
        max-width: 100%;
        font-size: 15px;
    }

    .w_cta_inner {
        flex-direction: column;
        text-align: center;
    }

    .w_cta_actions {
        justify-content: center;
    }

    .w_newsletter_section {
        padding: 56px 0;
    }

    .w_newsletter_section_inner {
        grid-template-columns: 1fr;
        gap: 24px;
        text-align: center;
        padding: 24px 20px;
        border-radius: 26px;
    }

    .w_newsletter_section_text p {
        max-width: 100%;
    }

    .w_newsletter_section_form {
        padding: 18px;
        border-radius: 22px;
    }

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

    .btn_newsletter_section {
        width: 100%;
        min-width: 0;
    }

    .w_footer_bottom_inner {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .w_footer_social {
        justify-content: center;
        margin-inline-start: 0;
    }

    .fp_card {
        height: 320px;
    }

    .fp_card_title {
        font-size: 17px;
    }

    .fp_card_price {
        font-size: 18px;
    }

    .w_perk_item {
        border-inline-start: none;
        border-top: 1px solid var(--c-border);
        flex-direction: column;
        text-align: center;
        padding: 0.75rem !important;
    }

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

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

    .w_stats_grid,
    .w_brand_wall,
    .w_condition_grid {
        grid-template-columns: 1fr;
    }

    .w_section_stats {
        display: none;
    }

    .w_fixed_tools {
        right: 14px;
        bottom: 22px;
    }

    [dir="rtl"] .w_fixed_tools {
        right: auto;
        left: 14px;
    }

    .w_fixed_ai_btn,
    .w_fixed_cart_btn {
        width: 52px;
        height: 52px;
    }

    .w_ai_sheet {
        width: calc(100vw - 12px);
        padding: 16px 14px 20px;
        border-radius: 26px 26px 0 0;
    }

    .w_ai_sheet_head h3 {
        font-size: 24px;
    }

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

    .w_ai_sheet_bar button[type="submit"] {
        width: 100%;
    }

    .w_order_card_body {
        flex-direction: column;
        align-items: flex-start;
    }

    .w_order_item_row {
        flex-wrap: wrap;
        gap: 10px;
    }

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

/* Small Mobile */
@media (max-width: 480px) {

    .wpc_grid,
    .wpc_grid_4 {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .w_auth_form_side {
        padding: 24px 16px;
    }

    .w_contact_form_card {
        padding: 20px 16px;
    }

    .w_hero {
        height: 85vh;
    }

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

    .w_steps_grid::before {
        display: none;
    }
}

@media (max-width: 640px) {
    .w_filter_sidebar {
        width: 100%;
        max-width: none;
    }
}

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

    .pv_name {
        font-size: 1.2rem;
    }
}
