/* =========================================================
   AMAMIRI HERBAL SHOP
   Modern Herbal / Natural E-Commerce Theme
   ========================================================= */

* {
    box-sizing: border-box;
}

:root {
    --green-950: #17352b;
    --green-900: #1f493a;
    --green-800: #285c49;
    --green-700: #34735a;
    --green-600: #43866a;
    --green-100: #e8f1eb;
    --green-50: #f3f8f4;

    --cream: #faf8f2;
    --cream-dark: #f1eee5;
    --white: #ffffff;

    --gold: #c99b3b;
    --gold-light: #e7cf91;

    --text: #26352f;
    --text-light: #6c7771;
    --border: #e5e9e4;

    --danger: #d9534f;

    --shadow-sm: 0 4px 16px rgba(25, 55, 43, 0.06);
    --shadow-md: 0 10px 30px rgba(25, 55, 43, 0.10);
    --shadow-lg: 0 18px 45px rgba(25, 55, 43, 0.14);

    --radius-sm: 10px;
    --radius-md: 16px;
    --radius-lg: 24px;

    --container: 1250px;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;

    direction: rtl;

    font-family:
        Tahoma,
        "Segoe UI",
        Arial,
        sans-serif;

    background:
        linear-gradient(
            180deg,
            var(--cream) 0%,
            #ffffff 55%,
            var(--cream) 100%
        );

    color: var(--text);

    line-height: 1.8;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input {
    font-family: inherit;
}


/* =========================================================
   HEADER
   ========================================================= */

.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;

    padding: 14px 25px;

    background: rgba(255, 255, 255, 0.96);

    border-bottom: 1px solid rgba(39, 92, 73, 0.08);

    box-shadow:
        0 4px 20px rgba(23, 53, 43, 0.06);

    backdrop-filter: blur(12px);
}

.header-inner {
    width: 100%;
    max-width: var(--container);

    margin: auto;

    display: flex;
    align-items: center;

    gap: 24px;
}


/* لوگو */

.site-header .logo {
    flex-shrink: 0;

    color: var(--green-900);

    font-size: 24px;
    font-weight: 900;

    white-space: nowrap;

    position: relative;

    padding-right: 32px;
}

.site-header .logo::before {
    content: "🌿";

    position: absolute;

    right: 0;
    top: 50%;

    transform: translateY(-50%);

    font-size: 25px;
}

/* =========================================================
   ZHIVA BRAND LOGO
   ========================================================= */

.brand-logo {
    display: flex;
    align-items: center;
    justify-content: center;

    flex-shrink: 0;

    text-decoration: none;

    line-height: 0;

    transition:
        transform 0.25s ease,
        filter 0.25s ease;
}

.brand-logo img {
    display: block;

    width: 185px;
    height: auto;

    max-height: 75px;

    object-fit: contain;
}

.brand-logo:hover {
    transform: translateY(-2px);
}

.brand-logo:hover img {
    filter: drop-shadow(0 5px 10px rgba(0, 0, 0, 0.12));
}


/* جستجو */

.search-box {
    flex: 1;

    max-width: 520px;

    height: 48px;

    display: flex;

    background: var(--green-50);

    border: 1px solid var(--border);

    border-radius: 30px;

    overflow: hidden;

    transition:
        border-color 0.25s ease,
        box-shadow 0.25s ease;
}

.search-box:focus-within {
    border-color: var(--green-600);

    box-shadow:
        0 0 0 4px rgba(67, 134, 106, 0.10);
}

.search-box input {
    flex: 1;

    min-width: 0;

    border: 0;
    outline: 0;

    background: transparent;

    color: var(--text);

    padding:
        0 20px;

    font-size: 14px;
}

.search-box input::placeholder {
    color: #98a39d;
}

.search-box button {
    width: 58px;

    border: 0;

    background: var(--green-800);

    color: white;

    cursor: pointer;

    font-size: 18px;

    transition:
        background 0.25s ease;
}

.search-box button:hover {
    background: var(--green-950);
}


/* منوی هدر */

.site-header nav {
    display: flex;

    align-items: center;

    gap: 8px;

    white-space: nowrap;
}

.site-header nav a,
.user-welcome {
    display: inline-flex;

    align-items: center;

    min-height: 40px;

    padding: 7px 12px;

    border-radius: 10px;

    font-size: 13px;

    transition:
        background 0.2s ease,
        color 0.2s ease,
        transform 0.2s ease;
}

.site-header nav a:hover {
    background: var(--green-50);

    color: var(--green-800);

    transform: translateY(-1px);
}

.user-welcome {
    color: var(--green-800);

    font-weight: bold;

    background: var(--green-50);
}


/* سبد خرید */

.cart-icon {
    background: var(--green-800) !important;

    color: white !important;

    padding:
        8px 16px !important;

    border-radius: 12px !important;

    font-weight: bold;

    box-shadow:
        0 5px 15px rgba(40, 92, 73, 0.18);
}

.cart-icon:hover {
    background: var(--green-950) !important;

    transform: translateY(-2px);
}

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

.hero-slider {
    position: relative;
    width: 100%;
    height: 270px;
    overflow: hidden;
    background: var(--green-950);
}

.hero-slide {
    position: absolute;
    inset: 0;

    width: 100%;
    height: 270px;

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

    opacity: 0;
    visibility: hidden;

    transition:
        opacity 0.7s ease,
        visibility 0.7s ease;

    pointer-events: none;
}

.hero-slide.active {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.hero-slide img {
    display: block;

    width: 100%;
    height: 270px;

    object-fit: cover;
    object-position: center;

    margin: 0;
}


/* =========================================================
   SLIDES
   ========================================================= */

.hero-slide {
    position: absolute;

    inset: 0;

    display: flex;

    align-items: center;

    justify-content: center;

    opacity: 0;

    visibility: hidden;

    pointer-events: none;

    transition:
        opacity 0.65s ease,
        transform 0.65s ease;

    transform: scale(1.02);
}


.hero-slide.active {
    opacity: 1;

    visibility: visible;

    pointer-events: auto;

    transform: scale(1);
}


/* تصویر */

.hero-slide img {
    width: 100%;

    height: 100%;

    display: block;

    object-fit: cover;

    object-position: center;
}


/* =========================================================
   HOTSPOT
   ========================================================= */

.hero-hotspot {
    position: absolute;

    z-index: 5;

    display: inline-flex;

    align-items: center;

    gap: 9px;

    padding: 12px 20px;

    border-radius: 14px;

    text-decoration: none;

    color: #fff;

    background: rgba(23, 53, 43, 0.88);

    border: 1px solid rgba(255, 255, 255, 0.35);

    box-shadow:
        0 8px 25px rgba(0, 0, 0, 0.20);

    backdrop-filter: blur(8px);

    -webkit-backdrop-filter: blur(8px);

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


/* افکت موس */

.hero-hotspot:hover {
    transform: scale(1.08);

    background: rgba(23, 53, 43, 0.96);

    box-shadow:
        0 14px 35px rgba(0, 0, 0, 0.30);
}


/* افکت لمس موبایل */

.hero-hotspot:active {
    transform: scale(1.12);
}


.hotspot-icon {
    font-size: 20px;

    line-height: 1;
}


.hotspot-text {
    font-size: 14px;

    font-weight: 800;

    white-space: nowrap;
}


/* =========================================================
   موقعیت لینک‌های Hero
   ========================================================= */

/*
   اینجا مهم‌ترین قسمت برای توست.

   right = فاصله از سمت راست
   top   = فاصله از بالا

   مقادیر را با درصد تغییر بده.
*/


/* Hero 1 */

.hotspot-cart {
    right: 12%;

    top: 68%;
}


/* Hero 2 */

.hotspot-products {
    right: 12%;

    top: 68%;
}


/* Hero 3 */

.hotspot-buy {
    right: 12%;

    top: 68%;
}


/* =========================================================
   فلش‌های اسلایدر
   ========================================================= */

.hero-arrow {
    position: absolute;

    top: 50%;

    transform: translateY(-50%);

    z-index: 10;

    width: 42px;

    height: 42px;

    display: flex;

    align-items: center;

    justify-content: center;

    border: 0;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.82);

    color: var(--green-950);

    font-size: 32px;

    line-height: 1;

    cursor: pointer;

    box-shadow:
        0 6px 20px rgba(0, 0, 0, 0.15);

    transition:
        transform 0.2s ease,
        background 0.2s ease;
}


.hero-arrow:hover {
    transform: translateY(-50%) scale(1.12);

    background: #fff;
}


.hero-prev {
    left: 18px;
}


.hero-next {
    right: 18px;
}


/* =========================================================
   DOTS
   ========================================================= */

.hero-dots {
    position: absolute;

    bottom: 14px;

    left: 50%;

    transform: translateX(-50%);

    z-index: 15;

    display: flex;

    align-items: center;

    gap: 8px;
}


.hero-dots span {
    width: 9px;

    height: 9px;

    border-radius: 50%;

    background: rgba(255, 255, 255, 0.60);

    cursor: pointer;

    transition:
        width 0.25s ease,
        background 0.25s ease,
        transform 0.25s ease;
}


.hero-dots span:hover {
    transform: scale(1.25);
}


.hero-dots span.active {
    width: 26px;

    border-radius: 20px;

    background: var(--gold);
}


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

@media (max-width: 768px) {

    .hero-slider {
        height: 200px;
    }

    .hero-slide {
        height: 200px;
    }

    .hero-slide img {
        width: 100%;
        height: 200px;
        object-fit: cover;
    }

    .hero-dots {
        bottom: 10px;
    }

 .brand-logo img {
        width: 145px;
        max-height: 60px;
    }

}


@media (max-width: 480px) {

    .hero-slider {
        height: 170px;
    }

    .hero-slide {
        height: 170px;
    }

    .hero-slide img {
        width: 100%;
        height: 170px;
        object-fit: cover;
    }

    .hero-dots {
        bottom: 8px;
    }

.brand-logo img {
        width: 125px;
        max-height: 52px;
    }

}




/* =========================================================
   CATEGORY SHOWCASE
   ========================================================= */


.category-showcase {
    width: min(100% - 40px, var(--container));

    margin: 35px auto 10px;

    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(140px, 1fr));

    gap: 16px;
}

.category-card {
    min-height: 130px;

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    gap: 8px;

    padding: 20px 12px;

    background: rgba(255, 255, 255, 0.9);

    border:
        1px solid var(--border);

    border-radius: var(--radius-md);

    box-shadow: var(--shadow-sm);

    color: var(--green-900);

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

.category-card:hover {
    transform: translateY(-6px);

    border-color:
        rgba(67, 134, 106, 0.35);

    box-shadow: var(--shadow-md);
}

.category-card .icon {
    width: 58px;
    height: 58px;

    display: flex;

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

    border-radius: 50%;

    background: var(--green-50);

    font-size: 30px;
}

.category-card span {
    font-size: 14px;

    font-weight: bold;
}


/* =========================================================
   CATEGORY FILTER
   ========================================================= */

.categories {
    width: min(100% - 40px, var(--container));

    margin: 25px auto;

    padding: 0;

    display: flex;

    gap: 10px;

    flex-wrap: wrap;

    justify-content: center;
}

.category-pill {
    padding: 9px 18px;

    background: white;

    border:
        1px solid var(--border);

    border-radius: 30px;

    color: var(--text-light);

    font-size: 13px;

    transition:
        all 0.2s ease;
}

.category-pill:hover {
    border-color: var(--green-600);

    color: var(--green-800);

    background: var(--green-50);
}

.category-pill.active {
    background: var(--green-800);

    border-color: var(--green-800);

    color: white;

    box-shadow:
        0 5px 15px rgba(40, 92, 73, 0.18);
}


/* =========================================================
   SEARCH RESULT MESSAGE
   ========================================================= */

#products + * {
    font-size: 14px;
}


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

.products-grid {
    width: min(100% - 40px, var(--container));

    margin: 10px auto 70px;

    display: grid;

    grid-template-columns:
        repeat(auto-fill, minmax(235px, 1fr));

    gap: 22px;
}

.product-card {
    position: relative;

    overflow: hidden;

    display: flex;

    flex-direction: column;

    background: white;

    border:
        1px solid var(--border);

    border-radius: var(--radius-md);

    box-shadow: var(--shadow-sm);

    transition:
        transform 0.3s ease,
        box-shadow 0.3s ease,
        border-color 0.3s ease;
}

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

    border-color:
        rgba(67, 134, 106, 0.25);

    box-shadow: var(--shadow-lg);
}


/* تصویر محصول */

.product-card .img-wrap {
    position: relative;

    overflow: hidden;

    background:
        linear-gradient(
            135deg,
            #f5f7f3,
            #eaf0eb
        );
}

.product-card img {
    width: 100%;

    height: 230px;

    display: block;

    object-fit: cover;

    transition:
        transform 0.45s ease;
}

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


/* تخفیف */

.discount-badge {
    position: absolute;

    top: 12px;
    right: 12px;

    z-index: 3;

    padding: 5px 10px;

    border-radius: 8px;

    background: var(--danger);

    color: white;

    font-size: 12px;

    font-weight: bold;

    box-shadow:
        0 4px 12px rgba(217, 83, 79, 0.25);
}


/* اطلاعات */

.product-card .info {
    display: flex;

    flex-direction: column;

    flex: 1;

    padding: 17px;
}

.product-card .brand {
    margin-bottom: 5px;

    color: var(--green-600);

    font-size: 11px;

    font-weight: bold;
}

.product-card h3 {
    margin: 0 0 7px;

    min-height: 48px;

    color: var(--text);

    font-size: 15px;

    line-height: 1.8;
}

.stars {
    margin-bottom: 8px;

    color: var(--gold);

    font-size: 13px;
}

.stars .empty {
    color: #dfe3df;
}


/* قیمت */

.product-card .price {
    color: var(--green-800);

    font-size: 17px;

    font-weight: 900;
}

.product-card .old-price {
    margin-right: 8px;

    color: #a2aaa5;

    font-size: 12px;

    text-decoration: line-through;
}


/* دکمه */

.product-card form {
    margin-top: auto;
}

.product-card button {
    width: 100%;

    margin-top: 14px;

    padding: 11px;

    border: 0;

    border-radius: 11px;

    background: var(--green-800);

    color: white;

    font-size: 13px;

    font-weight: bold;

    cursor: pointer;

    transition:
        background 0.25s ease,
        transform 0.2s ease;
}

.product-card button:hover {
    background: var(--green-950);

    transform: translateY(-2px);
}


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

.site-footer {
    margin-top: 40px;

    background:
        linear-gradient(
            145deg,
            var(--green-950),
            var(--green-900)
        );

    color: #dce8e1;

    text-align: right;
}

.footer-columns {
    width: min(100% - 40px, var(--container));

    margin: auto;

    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(210px, 1fr));

    gap: 45px;

    padding: 55px 0;
}

.footer-columns h4 {
    margin:
        0 0 17px;

    color: var(--gold-light);

    font-size: 16px;
}

.footer-columns p {
    color: #c6d5cd;

    font-size: 13px;

    line-height: 2;
}

.footer-columns ul {
    list-style: none;

    padding: 0;

    margin: 0;
}

.footer-columns li {
    margin-bottom: 10px;

    color: #c6d5cd;

    font-size: 13px;
}

.footer-columns a {
    color: #c6d5cd;

    transition:
        color 0.2s ease,
        padding-right 0.2s ease;
}

.footer-columns a:hover {
    padding-right: 5px;

    color: white;
}

.footer-bottom {
    padding: 18px 20px;

    background:
        rgba(0, 0, 0, 0.15);

    color: #b7c8bf;

    text-align: center;

    font-size: 12px;
}


/* =========================================================
   GENERAL FORMS
   ========================================================= */

.box {
    width: min(90%, 420px);

    margin: 70px auto;

    padding: 35px;

    background: white;

    border:
        1px solid var(--border);

    border-radius: var(--radius-lg);

    box-shadow: var(--shadow-md);

    text-align: center;
}

.box input {
    width: 100%;

    padding: 12px 14px;

    margin: 8px 0;

    border:
        1px solid var(--border);

    border-radius: 10px;

    outline: none;

    transition:
        border-color 0.2s ease,
        box-shadow 0.2s ease;
}

.box input:focus {
    border-color: var(--green-600);

    box-shadow:
        0 0 0 4px rgba(67, 134, 106, 0.10);
}

.box button {
    width: 100%;

    padding: 12px;

    margin-top: 8px;

    border: 0;

    border-radius: 10px;

    background: var(--green-800);

    color: white;

    cursor: pointer;

    font-weight: bold;
}

.error {
    color: var(--danger);

    font-size: 13px;
}


/* =========================================================
   RESPONSIVE
   ========================================================= */

@media (max-width: 1000px) {

    .header-inner {
        gap: 12px;
    }

    .site-header nav {
        gap: 2px;
    }

    .site-header nav a,
    .user-welcome {
        padding: 6px 8px;

        font-size: 12px;
    }

    .search-box {
        max-width: 400px;
    }
}


@media (max-width: 768px) {

    .site-header {
        position: relative;

        padding:
            14px 15px;
    }

    .header-inner {
        flex-wrap: wrap;

        justify-content: center;
    }

    .site-header .logo {
        width: 100%;

        text-align: center;

        padding-right: 0;

        font-size: 22px;
    }

    .site-header .logo::before {
        position: static;

        display: inline-block;

        margin-left: 7px;

        transform: none;
    }

    .search-box {
        order: 3;

        width: 100%;

        max-width: none;
    }

    .site-header nav {
        width: 100%;

        justify-content: center;

        flex-wrap: wrap;
    }

    .site-header nav a,
    .user-welcome {
        font-size: 12px;
    }


    .hero-slider {
        height: 390px;
    }

    .hero-slide h2 {
        font-size: 28px;
    }

    .hero-slide p {
        font-size: 14px;
    }


    .category-showcase {
        width: min(100% - 30px, var(--container));

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

        gap: 10px;
    }

    .category-card {
        min-height: 110px;

        padding: 14px 7px;
    }

    .category-card .icon {
        width: 48px;
        height: 48px;

        font-size: 24px;
    }

    .category-card span {
        font-size: 12px;
    }


    .categories {
        width: min(100% - 30px, var(--container));

        justify-content: flex-start;

        overflow-x: auto;

        flex-wrap: nowrap;

        padding-bottom: 5px;

        scrollbar-width: thin;
    }

    .category-pill {
        flex-shrink: 0;
    }


    .products-grid {
        width: min(100% - 30px, var(--container));

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

        gap: 12px;

        margin-bottom: 45px;
    }

    .product-card img {
        height: 175px;
    }

    .product-card .info {
        padding: 12px;
    }

    .product-card h3 {
        font-size: 13px;

        min-height: 45px;
    }

    .product-card .price {
        font-size: 14px;
    }

    .product-card button {
        padding: 10px 6px;

        font-size: 12px;
    }


    .footer-columns {
        width: min(100% - 30px, var(--container));

        grid-template-columns:
            repeat(2, 1fr);

        gap: 25px;

        padding: 40px 0;
    }
}


@media (max-width: 480px) {

    .hero-slider {
        height: 350px;
    }

    .hero-slide h2 {
        font-size: 24px;
    }

    .hero-slide p {
        font-size: 13px;

        padding: 0 10px;
    }

    .hero-slide a.btn-hero {
        min-width: 150px;

        padding: 11px 20px;
    }


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


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

        gap: 10px;
    }

    .product-card img {
        height: 145px;
    }

    .discount-badge {
        top: 7px;
        right: 7px;

        padding: 4px 7px;

        font-size: 10px;
    }

    .product-card .brand {
        font-size: 10px;
    }

    .product-card h3 {
        font-size: 12px;

        min-height: 42px;
    }

    .product-card .price {
        font-size: 13px;
    }


    .footer-columns {
        grid-template-columns: 1fr;

        gap: 25px;
    }
}
