/* =========================================================
   3K PET SOLUTION - CUSTOMER PRODUCTS
========================================================= */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    color: #111827;
    background: #ffffff;
}




/* =========================================================
   MAIN
========================================================= */

.products-page {
    width: 100%;
}


/* =========================================================
   HERO
========================================================= */

.products-hero {
    min-height: 470px;

    display: flex;
    align-items: center;

    background:
        linear-gradient(
            rgba(255, 255, 255, 0.78),
            rgba(255, 255, 255, 0.88)
        );

    position: relative;
    overflow: hidden;
}

.products-hero::before {
    content: "";

    position: absolute;

    width: 600px;
    height: 600px;

    right: -180px;
    top: -220px;

    background: #f4c5f3;

    border-radius: 50%;

    opacity: 0.45;
}

.products-hero::after {
    content: "";

    position: absolute;

    width: 350px;
    height: 350px;

    left: -150px;
    top: 80px;

    background: #a8ddf4;

    transform: rotate(25deg);

    opacity: 0.55;
}

.products-hero-content {
    position: relative;
    z-index: 1;

    width: min(850px, calc(100% - 48px));

    margin: 0 auto;

    padding: 70px 0 110px;
}

.products-hero-content h1 {
    margin: 0 0 20px;

    font-size: clamp(38px, 5vw, 64px);
    line-height: 1.08;

    font-weight: 800;
}

.products-hero-content p {
    max-width: 650px;

    margin: 0;

    font-size: clamp(20px, 2.4vw, 30px);
    line-height: 1.45;

    color: #1f2937;
}


/* =========================================================
   PRODUCTS CONTENT
========================================================= */

.products-content {
    width: min(1120px, calc(100% - 48px));

    margin: 0 auto;

    padding: 55px 0 90px;
}


/* =========================================================
   SEARCH + CATEGORY
========================================================= */

.products-controls {
    display: flex;
    align-items: center;

    gap: 18px;

    width: 100%;

    margin-bottom: 38px;
}

.products-search {
    flex: 1;

    min-height: 58px;

    display: flex;
    align-items: center;

    gap: 12px;

    padding: 0 20px;

    border: 1px solid #d1d5db;
    border-radius: 30px;

    background: #ffffff;

    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.search-icon {
    flex-shrink: 0;

    font-size: 21px;
}

.products-search input {
    width: 100%;

    border: none;
    outline: none;

    background: transparent;

    font-size: 17px;
    color: #111827;
}

.products-search input::placeholder {
    color: #9ca3af;
}

.products-category {
    flex: 0 0 220px;
}

.products-category select {
    width: 100%;
    min-height: 58px;

    padding: 0 18px;

    border: 1px solid #d1d5db;
    border-radius: 12px;

    background: #ffffff;

    color: #111827;

    font-size: 16px;
    cursor: pointer;

    outline: none;
}

.products-category select:focus {
    border-color: #8b5cf6;

    box-shadow:
        0 0 0 3px rgba(139, 92, 246, 0.12);
}


/* =========================================================
   CATEGORY HEADING
========================================================= */

.products-heading {
    margin-bottom: 28px;
}

.products-heading h2 {
    margin: 0;

    font-size: 32px;
    font-weight: 800;

    color: #111827;
}


/* =========================================================
   PRODUCT GRID
========================================================= */

.products-grid {
    display: grid;

    grid-template-columns:
        repeat(3, minmax(0, 1fr));

    gap: 42px 32px;
}


/* =========================================================
   PRODUCT CARD
========================================================= */

.product-card {
    position: relative;

    min-width: 0;
    height: 430px;

    overflow: hidden;

    background: #ffffff;

    border: 2px solid #9d1c91;

    cursor: pointer;

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease;
}


/* ---------------------------------------------------------
   Decorative Shapes
--------------------------------------------------------- */

.product-card::before,
.product-card::after {
    display: none;
}

/* =========================================================
   PRODUCT IMAGE
========================================================= */

.product-card-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    background: #fff;
    z-index: 1;
    opacity: 1;
    transition: opacity .25s ease, transform .3s ease;
}

.product-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform .3s ease;
}


.product-no-image {
    width: 100%;
    height: 100%;

    display: flex;
    align-items: center;
    justify-content: center;

    color: #9ca3af;

    font-size: 14px;
}


/* =========================================================
   DESCRIPTION OVERLAY
========================================================= */

.product-card-description-overlay {
    position: absolute;

    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 80px 38px;

    background: #ffffff;

    z-index: 2;

    opacity: 0;

    visibility: hidden;

    transition:
        opacity 0.25s ease,
        visibility 0.25s ease;
}


.product-card-description-overlay p {
    margin: 0;

    max-width: 100%;

    color: #111827;

    font-size: 16px;
    line-height: 1.6;

    text-align: center;
}


/* =========================================================
   AVAILABILITY
========================================================= */

.product-card-footer {
    position: absolute;

    left: 0;
    right: 0;
    bottom: 18px;

    display: flex;
    justify-content: center;

    z-index: 5;

    pointer-events: none;
}


.product-availability {
    display: inline-flex;
    align-items: center;
    justify-content: center;

    min-width: 108px;
    min-height: 38px;

    padding: 7px 20px;

    border: 1.5px solid #9d1c91;
    border-radius: 22px;

    background: #ffffff;

    color: #111827;

    font-size: 14px;
    font-weight: 600;

    box-shadow:
        0 2px 6px rgba(0, 0, 0, 0.06);
}


.product-availability::before {
    content: "";

    width: 7px;
    height: 7px;

    margin-right: 7px;

    border-radius: 50%;

    background: #22c55e;
}


/* =========================================================
   DESKTOP HOVER
========================================================= */

@media (hover: hover) and (pointer: fine) {

    .product-card:hover {
        transform: translateY(-4px);

        box-shadow:
            0 12px 28px rgba(0, 0, 0, 0.10);
    }


    .product-card:hover .product-card-image {
        opacity: 0;
    }


    .product-card:hover .product-card-description-overlay {
        opacity: 1;

        visibility: visible;
    }

}


/* =========================================================
   EMPTY STATE
========================================================= */

.products-empty {
    width: 100%;

    padding: 60px 20px;

    text-align: center;

    border: 1px dashed #d1d5db;
    border-radius: 14px;

    background: #fafafa;
}

.products-empty h3 {
    margin: 0 0 8px;

    font-size: 20px;
}

.products-empty p {
    margin: 0;

    color: #6b7280;

    font-size: 14px;
}


/* =========================================================
   FOOTER
========================================================= */

.customer-footer {
    width: 100%;

    padding: 28px 20px;

    text-align: center;

    background:
        linear-gradient(
            90deg,
            #f7efff,
            #eafaff
        );

    border-top: 1px solid #e5e7eb;
}

.customer-footer p {
    margin: 0;

    font-size: 13px;

    color: #374151;
}




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

        gap: 30px 24px;
    }

    .products-hero {
        min-height: 390px;
    }

    .products-hero-content {
        padding: 60px 0 80px;
    }




/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 600px) {

   

   
    

    .products-hero-content {
        width: calc(100% - 32px);

        padding: 50px 0 70px;
    }

    .products-hero-content h1 {
        font-size: 36px;
    }

    .products-hero-content p {
        font-size: 19px;
    }

    .products-content {
        width: calc(100% - 32px);

        padding: 40px 0 60px;
    }

    .products-controls {
        flex-direction: column;
        align-items: stretch;

        gap: 12px;
    }

    .products-category {
        flex: none;
        width: 100%;
    }

    .products-heading h2 {
        font-size: 27px;
    }

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

        gap: 14px 10px;
    }

    .product-card {
        height: 230px;
        min-height: 230px;
        
    }

}

/* =========================================================
   MOBILE / TABLET TAP
========================================================= */

@media (hover: none), (pointer: coarse) {

    .product-card.is-active .product-card-image {
        opacity: 0;
    }

    .product-card.is-active .product-card-description-overlay {
        opacity: 1;
        visibility: visible;
    }

}

/* =========================================================
   MOBILE PRODUCTS FIX
========================================================= */

@media (max-width: 600px) {

    /* PRODUCT DESCRIPTION */
    .product-card-description-overlay {
        padding: 35px 16px 55px;
    }

    .product-card-description-overlay p {
        font-size: 12px;
        line-height: 1.35;
        max-width: 100%;
        text-align: center;

        display: -webkit-box;
        -webkit-box-orient: vertical;
        -webkit-line-clamp: 6;
        overflow: hidden;
    }

}


/* =========================================================
   SMALL MOBILE PROFILE MENU
========================================================= */

@media (max-width: 420px) {

    .profile-menu {
        width: 155px;
        max-width: calc(100vw - 24px);
        padding: 7px;
    }

    .profile-menu a {
        padding: 9px 10px;
        font-size: 12px;
    }

    .profile-name {
        padding: 8px 10px;
        font-size: 12px;
    }

}

/* =========================================================
   FORCE CONSISTENT FONT ON MOBILE
========================================================= */

@media (max-width: 768px) {

    .products-page,
    .products-page * {
        font-family: Arial, Helvetica, sans-serif !important;
    }

}


/* =========================================================
   MOBILE LONG PRODUCT DESCRIPTION
========================================================= */

@media (max-width: 600px) {

    .product-card-description-overlay {
        padding: 25px 18px 70px;
        overflow-y: auto;
        overflow-x: hidden;
        align-items: flex-start;
    }

    .product-card-description-overlay p {
        width: 100%;
        max-width: 100%;
        font-size: 14px;
        line-height: 1.55;
        text-align: center;
        white-space: normal;
        overflow: visible;
    }

}


/* =========================================================
   PRODUCTS PAGE - PREMIUM PASTEL REDESIGN
   Append at the bottom of products.css
========================================================= */

.products-page {
    background: #ffffff;
}

/* HERO */
.products-hero {
    min-height: 410px;
    display: flex;
    align-items: center;
    background:
        radial-gradient(
            circle at 85% 20%,
            rgba(219, 199, 255, 0.68),
            transparent 30%
        ),
        radial-gradient(
            circle at 12% 90%,
            rgba(183, 231, 255, 0.62),
            transparent 32%
        ),
        linear-gradient(135deg, #fbf8ff 0%, #f5fbff 55%, #fff8fd 100%);
}

.products-hero::before {
    width: 330px;
    height: 330px;
    right: -80px;
    top: -110px;
    background: rgba(201, 176, 255, 0.32);
}

.products-hero::after {
    width: 230px;
    height: 230px;
    left: -80px;
    top: auto;
    bottom: -100px;
    background: rgba(151, 218, 249, 0.35);
}

.products-hero-content {
    width: min(1120px, calc(100% - 48px));
    padding: 75px 0 85px;
}

.products-hero-content::before {
    content: "YOUR PET'S WELLNESS STARTS HERE";
    display: inline-flex;
    align-items: center;
    margin-bottom: 22px;
    padding: 10px 16px;
    border: 1px solid #e3d9fa;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.78);
    color: #7661b6;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.6px;
}

.products-hero-content h1 {
    max-width: 800px;
    margin-bottom: 20px;
    color: #28213f;
    font-size: clamp(38px, 5vw, 62px);
    line-height: 1.12;
    letter-spacing: -1.5px;
}

.products-hero-content p {
    max-width: 640px;
    color: #5e5b70;
    font-size: clamp(16px, 2vw, 21px);
    line-height: 1.8;
}

/* PRODUCTS AREA */
.products-content {
    width: min(1160px, calc(100% - 48px));
    padding: 60px 0 90px;
}

/* SEARCH + CATEGORY */
.products-controls {
    position: relative;
    gap: 14px;
    margin-bottom: 42px;
    padding: 16px;
    border: 1px solid #ece5fa;
    border-radius: 22px;
    background: linear-gradient(135deg, #fcfaff, #f5fbff);
    box-shadow: 0 8px 24px rgba(83, 68, 135, 0.06);
}

.products-search {
    min-height: 54px;
    padding: 0 18px;
    border: 1px solid #e3def0;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.products-search:focus-within {
    border-color: #9b88d8;
    box-shadow: 0 0 0 4px rgba(155, 136, 216, 0.12);
}

.search-icon {
    font-size: 17px;
}

.products-search input {
    min-width: 0;
    font-size: 15px;
}

.products-category {
    flex-basis: 230px;
}

.products-category select {
    min-height: 54px;
    border: 1px solid #e3def0;
    border-radius: 14px;
    background-color: #ffffff;
    font-size: 14px;
}

.products-category select:focus {
    border-color: #9b88d8;
    box-shadow: 0 0 0 4px rgba(155, 136, 216, 0.12);
}

/* CATEGORY HEADING */
.products-heading {
    display: flex;
    align-items: center;
    margin-bottom: 26px;
}

.products-heading h2 {
    position: relative;
    padding-bottom: 12px;
    color: #2b2541;
    font-size: clamp(25px, 3vw, 32px);
    letter-spacing: -0.5px;
}

.products-heading h2::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 58px;
    height: 4px;
    border-radius: 10px;
    background: linear-gradient(90deg, #8c79d2, #75c9eb);
}

/* PRODUCT GRID */
.products-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 28px 24px;
    align-items: stretch;
}

/* PRODUCT CARD */
.product-card {
    height: 390px;
    border: 1px solid #e8e0f4;
    border-radius: 22px;
    background: #ffffff;
    box-shadow: 0 7px 22px rgba(58, 48, 93, 0.07);
    isolation: isolate;
    transition:
        transform 0.28s ease,
        box-shadow 0.28s ease,
        border-color 0.28s ease;
}

.product-card-image {
    background: linear-gradient(145deg, #faf7ff, #f0f9ff);
}

.product-card-image img {
    object-fit: contain;
    padding: 18px;
    transition: transform 0.35s ease;
}

.product-no-image {
    color: #8a7bb2;
    background: linear-gradient(145deg, #faf7ff, #f0f9ff);
}

.product-card-description-overlay {
    padding: 28px 24px;
    background: linear-gradient(145deg, #ffffff, #faf7ff);
}

.product-card-description-overlay p {
    color: #56536a;
    font-size: 14px;
    line-height: 1.7;
}

/* AVAILABILITY PILL */
.product-card-footer {
    bottom: 14px;
    z-index: 6;
}

.product-availability {
    min-height: 34px;
    min-width: 0;
    padding: 7px 15px;
    border: 1px solid #ded5f0;
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.96);
    color: #4b4268;
    font-size: 12px;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(49, 40, 78, 0.09);
}

/* DESKTOP HOVER */
@media (hover: hover) and (pointer: fine) {
    .product-card:hover {
        transform: translateY(-6px);
        border-color: #c9b9ec;
        box-shadow: 0 17px 36px rgba(86, 68, 140, 0.15);
    }

    .product-card:hover .product-card-image img {
        transform: scale(1.04);
    }
}

/* EMPTY STATE */
.products-empty {
    padding: 65px 22px;
    border: 1px dashed #d8cbed;
    border-radius: 22px;
    background: linear-gradient(135deg, #fcfaff, #f5fbff);
}

.products-empty h3 {
    margin-bottom: 10px;
    color: #302746;
    font-size: 22px;
}

.products-empty p {
    color: #6e687f;
    line-height: 1.7;
}

/* TABLET */
@media (max-width: 900px) {
    .products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 22px;
    }

    .product-card {
        height: 360px;
    }
}

/* MOBILE */
@media (max-width: 600px) {
    .products-hero {
        min-height: auto;
    }

    .products-hero-content {
        width: calc(100% - 36px);
        padding: 48px 0 55px;
    }

    .products-hero-content::before {
        max-width: 100%;
        padding: 9px 12px;
        margin-bottom: 18px;
        font-size: 9px;
        letter-spacing: 1px;
    }

    .products-hero-content h1 {
        margin-bottom: 15px;
        font-size: clamp(30px, 8.5vw, 38px);
        letter-spacing: -0.8px;
    }

    .products-hero-content p {
        font-size: 15px;
        line-height: 1.7;
    }

    .products-content {
        width: calc(100% - 28px);
        padding: 32px 0 55px;
    }

    .products-controls {
        padding: 12px;
        gap: 10px;
        margin-bottom: 25px;
        border-radius: 18px;
    }

    .products-search {
        min-height: 35px;
        padding: 0 13px;
        border-radius: 12px;
    }

    .products-search input {
        font-size: 14px;
    }

    .products-category select {
        min-height: 48px;
        padding: 0 12px;
        font-size: 14px;
        border-radius: 12px;
    }

    .products-heading {
        margin-bottom: 22px;
    }

    .products-heading h2 {
        font-size: 24px;
    }

    .products-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 14px 10px;
    }

    .product-card {
        height: 245px;
        min-height: 245px;
        border-width: 1px;
        border-radius: 16px;
    }

    .product-card-image img {
        padding: 9px;
        object-fit: contain;
    }

    .product-card-description-overlay {
        padding: 15px 10px 57px;
        overflow-y: auto;
        align-items: flex-start;
    }

    .product-card-description-overlay p {
        font-size: 12px;
        line-height: 1.5;
        text-align: left;
    }

    .product-card-footer {
        bottom: 9px;
    }

    .product-availability {
        min-height: 29px;
        max-width: calc(100% - 12px);
        padding: 6px 9px;
        font-size: 10px;
    }

    .product-availability::before {
        flex-shrink: 0;
        width: 6px;
        height: 6px;
        margin-right: 5px;
    }

    .products-empty {
        padding: 45px 16px;
    }
}

/* REDUCED MOTION */
@media (prefers-reduced-motion: reduce) {
    .product-card,
    .product-card-image img,
    .products-search,
    .products-category select {
        transition: none !important;
    }

    .product-card:hover {
        transform: none;
    }
}


/* =========================================================
   PRODUCTS — CENTERED HERO + COMPACT MOBILE CONTROLS
========================================================= */

/* Center hero content like Services */
.products-hero {
    justify-content: center;
    text-align: center;
}

.products-hero-content {
    width: min(900px, calc(100% - 48px));
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 65px 0 80px;
}

.products-hero-content h1 {
    max-width: 850px;
    margin: 0 auto 18px;
}

.products-hero-content p {
    max-width: 700px;
    margin: 0 auto;
}

/* Search and filter container */
.products-controls {
    gap: 14px;
    padding: 14px;
    border: 1px solid #ece5fa;
    border-radius: 20px;
    background: linear-gradient(135deg, #fbf8ff, #f3fbff);
    box-shadow: 0 6px 20px rgba(58, 48, 93, 0.06);
}

.products-search {
    min-height: 50px;
    padding: 0 15px;
    border-color: #e3def0;
    border-radius: 13px;
    box-shadow: none;
}

.products-search input {
    min-width: 0;
    font-size: 15px;
}

.search-icon {
    font-size: 17px;
}

.products-category select {
    min-height: 50px;
    padding: 0 13px;
    border-color: #e3def0;
    border-radius: 13px;
    font-size: 14px;
}

/* Mobile */
@media (max-width: 600px) {
    .products-hero {
        min-height: 300px;
        padding: 35px 0;
    }

    .products-hero-content {
        width: calc(100% - 36px);
        padding: 35px 0;
    }

    .products-hero-content h1 {
        font-size: clamp(29px, 8vw, 36px);
        line-height: 1.15;
        margin-bottom: 14px;
    }

    .products-hero-content p {
        font-size: 15px;
        line-height: 1.6;
        max-width: 360px;
    }

    .products-content {
        width: calc(100% - 28px);
        padding: 26px 0 45px;
    }

    .products-controls {
        padding: 10px;
        gap: 9px;
        margin-bottom: 28px;
        border-radius: 15px;
    }

    .products-search {
        flex: none;
        width: 100%;
        min-height: 43px;
        gap: 9px;
        padding: 0 12px;
        border-radius: 11px;
    }

    .products-search input {
        font-size: 13px;
    }

    .search-icon {
        font-size: 15px;
    }

    .products-category {
        width: 100%;
    }

    .products-category select {
        width: 100%;
        min-height: 43px;
        padding: 0 12px;
        font-size: 13px;
        border-radius: 11px;
    }

    .products-heading {
        margin-bottom: 20px;
    }

    .products-heading h2 {
        font-size: 25px;
    }
}


/* =========================================================
   CUSTOM CATEGORY DROPDOWN
========================================================= */

.products-category {
    position: relative;
    flex: 0 0 220px;
    min-width: 0;
}

.category-trigger {
    width: 100%;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 15px;
    border: 1px solid #e3def0;
    border-radius: 13px;
    background: #fff;
    color: #40365f;
    font: inherit;
    font-size: 14px;
    cursor: pointer;
}

.category-trigger i {
    font-size: 12px;
    transition: transform .2s ease;
}

.category-trigger[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.category-trigger:focus-visible,
.category-option:focus-visible {
    outline: 2px solid #8c79d2;
    outline-offset: 3px;
}

.category-options {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    z-index: 100;
    padding: 6px;
    border: 1px solid #e9e1f5;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 12px 28px rgba(58, 48, 93, .15);
}

.category-options[hidden] {
    display: none !important;
}

.category-option {
    display: block;
    width: 100%;
    padding: 11px 12px;
    border: 0;
    border-radius: 9px;
    background: transparent;
    color: #4b4562;
    font: inherit;
    font-size: 14px;
    text-align: left;
    cursor: pointer;
}

.category-option:hover,
.category-option.is-selected {
    background: linear-gradient(90deg, #f2eaff, #edfaff);
    color: #57438e;
    font-weight: 700;
}

/* Hidden native select remains available to existing JS */
.category-native-select {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Compact mobile controls */
@media (max-width: 600px) {
    .products-controls {
        padding: 10px;
        gap: 9px;
        border-radius: 15px;
    }

    .products-search {
        min-height: 43px;
        padding: 0 12px;
    }

    .products-category {
        width: 100%;
        flex: none;
    }

    .category-trigger {
        min-height: 43px;
        padding: 0 12px;
        border-radius: 11px;
        font-size: 13px;
    }

    .category-options {
        top: calc(100% + 6px);
        padding: 5px;
        border-radius: 12px;
    }

    .category-option {
        padding: 10px 11px;
        font-size: 13px;
    }
}

