@font-face {
    font-family: "vazir";
    src: url("../fonts/vazir.ttf") format("truetype");
    font-display: swap;
}

:root {
    --cream: #f5eccb;
    --cream-light: #fffaf0;
    --paper: #fffdf7;
    --sage: #b7d58a;
    --sage-dark: #7f9f59;
    --sage-deep: #60794a;
    --forest: #43583b;
    --forest-soft: #53694a;
    --clay: #c88968;
    --gold: #d7af61;
    --ink: #263022;
    --muted: #757d6d;
    --line: rgba(79, 103, 55, 0.16);
    --white-line: rgba(255, 255, 255, 0.68);
    --surface: rgba(255, 253, 247, 0.82);
    --shadow-soft: 0 18px 55px rgba(54, 66, 41, 0.10);
    --shadow-card: 0 22px 60px rgba(54, 66, 41, 0.16);
    --shadow-green: 0 18px 34px rgba(112, 143, 78, 0.20);
    --radius-sm: 14px;
    --radius-md: 22px;
    --radius-lg: 32px;
    --radius-xl: 42px;
    --ease: 260ms cubic-bezier(0.2, 0.75, 0.25, 1);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: "vazir", sans-serif !important;
}

html {
    scroll-behavior: smooth;
}

body {
    min-height: 100vh;
    overflow-x: hidden;
    color: var(--ink);
    background:
        radial-gradient(circle at 9% 18%, rgba(255, 255, 255, 0.72), transparent 24rem),
        radial-gradient(circle at 94% 42%, rgba(183, 213, 138, 0.16), transparent 26rem),
        linear-gradient(180deg, #f7efcf 0%, #f4e8c5 48%, #fbf5df 100%) !important;
}

body.modal-open {
    overflow: hidden;
}

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

img {
    display: block;
    max-width: 100%;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

.page-texture {
    position: fixed;
    z-index: -1;
    inset: 0;
    pointer-events: none;
    opacity: 0.24;
    background-image:
        radial-gradient(circle at 2px 2px, rgba(75, 89, 58, 0.11) 1px, transparent 0);
    background-size: 28px 28px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.55), transparent 90%);
}

/* =========================
   Premium header
========================= */

.site-header {
    position: sticky;
    z-index: 1000;
    top: 0;
    min-height: 104px;
    padding: 15px 22px 12px;
    overflow: hidden;
    isolation: isolate;
    background:
        linear-gradient(180deg, rgba(245, 236, 203, 0.96), rgba(245, 236, 203, 0.78));
    border-bottom: 1px solid rgba(111, 139, 66, 0.12);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

.site-header::after {
    content: "";
    position: absolute;
    z-index: -2;
    right: 0;
    bottom: -1px;
    left: 0;
    height: 38px;
    background: linear-gradient(180deg, transparent, rgba(255, 255, 255, 0.25));
}

#navbar {
    position: relative;
    z-index: 4;
    width: min(1240px, 100%);
    min-height: 72px;
    margin: 0 auto;
    padding: 10px 22px !important;
    border: 1px solid rgba(255, 255, 255, 0.86);
    border-radius: 24px;
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.90), rgba(255, 252, 240, 0.74)) !important;
    box-shadow:
        0 17px 50px rgba(61, 75, 45, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(18px);
    -webkit-backdrop-filter: blur(18px);
}

#navbar .container,
#navbar .container-fluid {
    padding-inline: 0;
}

#navbar .navbar-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--forest) !important;
    font-weight: 900;
}

#navbar .navbar-brand img,
#navbar .logo,
#navbar img {
    object-fit: contain;
    filter: drop-shadow(0 8px 14px rgba(42, 59, 32, 0.12));
}

#navbar .navbar-nav {
    gap: 6px;
}

#navbar .nav-link,
#navbar .navbar-nav a {
    position: relative;
    padding: 10px 14px !important;
    color: #4f5949 !important;
    border-radius: 12px;
    font-size: 0.92rem;
    font-weight: 750;
    transition: color var(--ease), background var(--ease), transform var(--ease);
}

#navbar .nav-link::after,
#navbar .navbar-nav a::after {
    content: "";
    position: absolute;
    right: 18px;
    bottom: 5px;
    left: 18px;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--sage), var(--gold));
    transform: scaleX(0);
    transition: transform var(--ease);
}

#navbar .nav-link:hover,
#navbar .navbar-nav a:hover,
#navbar .nav-link.active {
    color: var(--forest) !important;
    background: rgba(183, 213, 138, 0.14);
    transform: translateY(-1px);
}

#navbar .nav-link:hover::after,
#navbar .navbar-nav a:hover::after,
#navbar .nav-link.active::after {
    transform: scaleX(1);
}

#navbar button,
#navbar .btn {
    border-radius: 13px !important;
}

#navbar .navbar-toggler {
    padding: 8px 10px;
    border: 1px solid rgba(111, 139, 66, 0.22);
    background: rgba(183, 213, 138, 0.14);
    box-shadow: none !important;
}

#navbar input,
#navbar .form-control {
    border: 1px solid rgba(111, 139, 66, 0.18);
    border-radius: 13px;
    background: rgba(255, 255, 255, 0.68);
    box-shadow: none;
}

#navbar input:focus,
#navbar .form-control:focus {
    border-color: var(--sage);
    box-shadow: 0 0 0 4px rgba(183, 213, 138, 0.16);
}

.header-thread {
    position: absolute;
    z-index: 1;
    inset: auto 0 -6px;
    width: 100%;
    height: 112px;
    fill: none;
    stroke: rgba(111, 139, 66, 0.25);
    stroke-width: 2;
    stroke-linecap: round;
}

.header-thread circle {
    fill: var(--clay);
    stroke: rgba(255, 255, 255, 0.65);
    stroke-width: 3;
}

.header-glow {
    position: absolute;
    z-index: -1;
    border-radius: 50%;
    filter: blur(4px);
    pointer-events: none;
}

.header-glow-one {
    top: -80px;
    right: 4%;
    width: 220px;
    height: 220px;
    background: rgba(150, 185, 94, 0.20);
}

.header-glow-two {
    bottom: -90px;
    left: 6%;
    width: 180px;
    height: 180px;
    background: rgba(200, 137, 104, 0.12);
}

/* =========================
   Main layout
========================= */

.site-main {
    position: relative;
    z-index: 2;
    padding: 38px 0 80px;
}

.catalog-section {
    position: relative;
    padding: 38px 0;
}

.section-heading {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;
}

.section-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    color: var(--sage-dark);
    font-size: 0.82rem;
    font-weight: 800;
    letter-spacing: -0.01em;
}

.section-kicker::before {
    content: "";
    width: 20px;
    height: 2px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--sage-dark), var(--gold));
}

.section-heading h1,
.section-heading h2 {
    margin: 0;
    color: var(--forest);
    font-size: clamp(1.48rem, 2.7vw, 2.25rem);
    font-weight: 950;
    line-height: 1.35;
    letter-spacing: -0.045em;
}

.heading-decoration {
    display: flex;
    align-items: center;
    gap: 7px;
    min-height: 32px;
}

.heading-decoration span {
    display: block;
    border-radius: 50%;
    background: var(--sage);
    box-shadow: 0 5px 12px rgba(111, 139, 66, 0.22);
}

.heading-decoration span:nth-child(1) {
    width: 8px;
    height: 8px;
    background: var(--clay);
}

.heading-decoration span:nth-child(2) {
    width: 14px;
    height: 14px;
    background: var(--gold);
}

.heading-decoration span:nth-child(3) {
    width: 21px;
    height: 21px;
}

.section-divider {
    position: relative;
    height: 20px;
    margin-top: 12px;
}

.section-divider::before {
    content: "";
    position: absolute;
    top: 50%;
    right: 0;
    left: 0;
    height: 1px;
    background:
        linear-gradient(90deg, transparent, rgba(111, 139, 66, 0.36) 16%, rgba(111, 139, 66, 0.13) 78%, transparent);
}

.divider-dot {
    position: absolute;
    z-index: 1;
    top: 50%;
    right: 12%;
    width: 10px;
    height: 10px;
    border: 2px solid var(--cream-light);
    border-radius: 50%;
    background: var(--clay);
    box-shadow: 0 0 0 1px rgba(200, 137, 104, 0.24);
    transform: translateY(-50%);
}

/* =========================
   Categories
========================= */

.categories-wrapper {
    position: relative;
    margin-top: 25px;
    padding: clamp(25px, 4vw, 48px);
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.82);
    border-radius: var(--radius-xl);
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.62), rgba(255, 250, 236, 0.42));
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(7px);
    -webkit-backdrop-filter: blur(7px);
}

.categories-wrapper::before {
    content: "";
    position: absolute;
    top: -90px;
    right: -90px;
    width: 250px;
    height: 250px;
    border: 1px dashed rgba(111, 139, 66, 0.20);
    border-radius: 50%;
}

.categories-wrapper::after {
    content: "";
    position: absolute;
    bottom: -120px;
    left: -80px;
    width: 290px;
    height: 290px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(200, 137, 104, 0.10), transparent 65%);
}

.category-row {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(22px, 3vw, 42px);
}

.category-row + .category-row {
    margin-top: clamp(22px, 3vw, 42px);
}

.category-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: clamp(14px, 2vw, 24px);
}

.category-item {
    min-width: 0;
}

.category-item > a {
    display: block;
    height: 100%;
    outline: none;
}

.category_frame {
    position: relative;
    display: grid;
    place-items: center;
    width: 100%;
    aspect-ratio: 1.2 / 1;
    min-height: 142px;
    padding: 24px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.92);
    border-radius: 27px;
    background:
        linear-gradient(145deg, rgba(255, 255, 255, 0.94), rgba(250, 246, 232, 0.74));
    box-shadow:
        0 15px 34px rgba(60, 72, 47, 0.10),
        inset 0 1px 0 rgba(255, 255, 255, 0.88);
    transition:
        transform var(--ease),
        box-shadow var(--ease),
        border-color var(--ease);
}

.category_frame::before {
    content: "";
    position: absolute;
    top: 15px;
    right: 15px;
    width: 10px;
    height: 10px;
    border: 2px solid rgba(111, 139, 66, 0.26);
    border-radius: 50%;
}

.category_frame::after {
    content: "";
    position: absolute;
    bottom: 18px;
    left: 17px;
    width: 34px;
    height: 10px;
    border-bottom: 2px solid rgba(200, 137, 104, 0.26);
    border-radius: 50%;
    transform: rotate(-14deg);
}

.category-shine {
    position: absolute;
    top: -45%;
    right: -32%;
    width: 80%;
    height: 170%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.48), transparent);
    transform: rotate(25deg) translateX(120%);
    transition: transform 720ms ease;
}

.category_icons {
    position: relative;
    z-index: 2;
    width: clamp(72px, 7vw, 102px);
    height: clamp(72px, 7vw, 102px);
    object-fit: contain;
    filter: drop-shadow(0 12px 14px rgba(66, 85, 45, 0.13));
    transition: transform var(--ease), filter var(--ease);
}

.category-name {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 12px;
    padding: 0 7px;
}

.category-name span {
    color: var(--forest);
    font-size: 0.97rem;
    font-weight: 900;
}

.category-name small {
    color: var(--muted);
    font-size: 0.70rem;
    font-weight: 650;
    transition: color var(--ease), transform var(--ease);
}

.category-item:hover .category_frame {
    border-color: rgba(151, 184, 101, 0.38);
    box-shadow: var(--shadow-card);
    transform: translateY(-8px) rotate(-0.35deg);
}

.category-item:hover .category-shine {
    transform: rotate(25deg) translateX(-250%);
}

.category-item:hover .category_icons {
    filter: drop-shadow(0 15px 18px rgba(66, 85, 45, 0.18));
    transform: scale(1.07) rotate(2deg);
}

.category-item:hover .category-name small {
    color: var(--sage-dark);
    transform: translateX(-3px);
}

.category-item > a:focus-visible .category_frame {
    outline: 4px solid rgba(150, 185, 94, 0.20);
    outline-offset: 3px;
}

.craft-orbit {
    position: absolute;
    z-index: 1;
    border: 1px dashed rgba(111, 139, 66, 0.17);
    border-radius: 50%;
    pointer-events: none;
}

.craft-orbit-one {
    top: 22%;
    left: 2%;
    width: 84px;
    height: 84px;
}

.craft-orbit-two {
    right: 3%;
    bottom: 18%;
    width: 58px;
    height: 58px;
    border-color: rgba(200, 137, 104, 0.20);
}

/* =========================
   Product area
========================= */

.products-section {
    padding-top: 52px;
}

.product-heading {
    align-items: center;
}

.handmade-mark {
    display: grid;
    place-items: center;
    width: 62px;
    height: 62px;
    color: var(--sage-dark);
    border: 1px solid rgba(255, 255, 255, 0.84);
    border-radius: 21px;
    background: rgba(255, 255, 255, 0.52);
    box-shadow: var(--shadow-soft);
    transform: rotate(-4deg);
}

.handmade-mark svg {
    width: 37px;
    height: 37px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.product-stage {
    position: relative;
    margin-top: 22px;
    padding: clamp(18px, 3vw, 34px);
    overflow: hidden;
    border-radius: var(--radius-xl);
    background:
        linear-gradient(145deg, rgba(113, 139, 91, 0.97), rgba(72, 96, 64, 0.98));
    box-shadow:
        0 30px 80px rgba(72, 96, 64, 0.18),
        inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.product-stage::before {
    content: "";
    position: absolute;
    top: -140px;
    left: -80px;
    width: 310px;
    height: 310px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(150, 185, 94, 0.22), transparent 68%);
}

.product-stage::after {
    content: "";
    position: absolute;
    right: 32px;
    bottom: 22px;
    width: 110px;
    height: 58px;
    opacity: 0.18;
    background-image: radial-gradient(circle, #fff 2px, transparent 2.5px);
    background-size: 16px 16px;
}

.stage-thread {
    position: absolute;
    z-index: 1;
    top: 28px;
    right: 26px;
    width: 160px;
    height: 70px;
    border-top: 2px solid rgba(215, 175, 97, 0.22);
    border-radius: 50%;
    transform: rotate(6deg);
}

.products-scroll {
    position: relative;
    z-index: 2;
    display: flex;
    gap: 18px;
    padding: 12px 4px 24px;
    overflow-x: auto;
    overflow-y: hidden;
    direction: rtl;
    scroll-snap-type: x proximity;
    scrollbar-width: thin;
    scrollbar-color: rgba(215, 175, 97, 0.55) rgba(255, 255, 255, 0.08);
}

.second-product-row {
    padding-top: 3px;
}

.products-scroll::-webkit-scrollbar {
    height: 7px;
}

.products-scroll::-webkit-scrollbar-track {
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.07);
}

.products-scroll::-webkit-scrollbar-thumb {
    border-radius: 999px;
    background: linear-gradient(90deg, rgba(150, 185, 94, 0.74), rgba(215, 175, 97, 0.74));
}

.card.product-card {
    position: relative;
    flex: 0 0 252px;
    min-width: 252px !important;
    min-height: 370px !important;
    padding: 10px;
    overflow: hidden;
    scroll-snap-align: start;
    white-space: normal;
    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 29px;
    background: rgba(255, 253, 247, 0.96);
    box-shadow: 0 18px 40px rgba(12, 19, 11, 0.24);
    transition: transform var(--ease), box-shadow var(--ease), border-color var(--ease);
}

.card.product-card::before {
    content: "";
    position: absolute;
    z-index: 0;
    right: -36px;
    bottom: -34px;
    width: 100px;
    height: 100px;
    border: 1px dashed rgba(111, 139, 66, 0.13);
    border-radius: 50%;
}

.card.product-card:hover {
    border-color: rgba(215, 175, 97, 0.50);
    box-shadow: 0 25px 52px rgba(8, 15, 8, 0.31);
    transform: translateY(-8px);
}

.handmade-badge {
    display: none !important;

    position: absolute;
    z-index: 4;
    top: 19px;
    right: 19px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 9px;
    color: #fffdf5;
    border: 1px solid rgba(255, 255, 255, 0.24);
    border-radius: 999px;
    background: rgba(83, 105, 74, 0.82);
    box-shadow: 0 8px 18px rgba(26, 36, 23, 0.18);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    font-size: 0.68rem;
    font-weight: 800;
}

.handmade-badge::before {
    content: "";
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--gold);
    box-shadow: 0 0 0 3px rgba(215, 175, 97, 0.18);
}

.product-media {
    position: relative;
    z-index: 1;
    display: grid;
    order: 1;
    place-items: center;
    height: 205px;
    overflow: hidden;
    border-radius: 22px;
    background: linear-gradient(145deg, #f5f4ea, #fffaf0);
}

.product-media::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(180deg, transparent 60%, rgba(32, 46, 28, 0.12));
}

.product-image {
    width: 100%;
    height: 100%;
    padding: 0 !important;
    object-fit: cover;
    border-radius: 0;
    transition: transform 520ms ease, filter 520ms ease;
}

.product-card:hover .product-image {
    filter: saturate(1.06) contrast(1.02);
    transform: scale(1.055);
}

.product-card-body {
    position: relative;
    z-index: 2;
    display: flex;
    order: 2;
    flex-direction: column;
    min-height: 145px;
    padding: 16px 8px 7px;
}

.product-title {
    display: -webkit-box;
    min-height: 48px;
    margin: 0;
    overflow: hidden;
    color: var(--forest);
    font-size: 0.98rem;
    font-weight: 900;
    line-height: 1.75;
    text-align: right;
    white-space: normal;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.product-meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 8px;
}

.price-display {
    display: flex;
    align-items: baseline;
    gap: 5px;
    direction: rtl;
}

.price-value {
    color: var(--sage-dark);
    font-size: 1.04rem;
    font-weight: 950;
}

.currency {
    color: var(--muted);
    font-size: 0.71rem;
    font-weight: 700;
}

.product-dot-mark {
    display: flex;
    gap: 4px;
}

.product-dot-mark span {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--sage);
}

.product-dot-mark span:nth-child(2) {
    background: var(--gold);
}

.product-dot-mark span:nth-child(3) {
    background: var(--clay);
}

.see-btn {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    min-height: 44px;
    gap: 8px;
    margin-top: 14px;
    padding: 9px 15px;
    color: #fff;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--sage), var(--sage-dark));
    box-shadow: var(--shadow-green);
    font-size: 0.86rem;
    font-weight: 850;
    text-decoration: none;
    transition: transform var(--ease), box-shadow var(--ease), filter var(--ease);
}

.see-btn svg {
    width: 18px;
    height: 18px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
    transition: transform var(--ease);
}

.see-btn:hover {
    color: #fff;
    filter: saturate(1.08);
    box-shadow: 0 15px 28px rgba(86, 112, 55, 0.30);
    transform: translateY(-2px);
}

.see-btn:hover svg {
    transform: translateX(-3px);
}

.product-image-fallback,
.products-empty-state {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 10px;
}

.product-image-fallback {
    color: var(--muted);
}

.product-image-fallback svg {
    width: 52px;
    height: 52px;
    fill: none;
    stroke: var(--sage-dark);
    stroke-width: 1.5;
}

.products-empty-state {
    width: 100%;
    min-height: 190px;
    margin: 8px 0;
    padding: 28px;
    color: rgba(255, 255, 255, 0.76);
    border: 1px dashed rgba(255, 255, 255, 0.20);
    border-radius: 24px;
    background: rgba(255, 255, 255, 0.05);
    text-align: center;
}

.products-empty-state svg {
    width: 44px;
    height: 44px;
    fill: none;
    stroke: var(--gold);
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* skeleton */
.product-skeleton {
    flex: 0 0 252px;
    min-width: 252px;
    min-height: 370px;
    padding: 10px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.13);
    border-radius: 29px;
    background: rgba(255, 255, 255, 0.07);
}

.skeleton-image,
.skeleton-line,
.skeleton-button {
    position: relative;
    overflow: hidden;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.10);
}

.skeleton-image::after,
.skeleton-line::after,
.skeleton-button::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.18), transparent);
    transform: translateX(100%);
    animation: skeletonMove 1.4s infinite;
}

.skeleton-image {
    height: 205px;
    border-radius: 22px;
}

.skeleton-line {
    height: 13px;
    margin-right: 8px;
}

.skeleton-title {
    width: 72%;
    margin-top: 25px;
}

.skeleton-price {
    width: 42%;
    margin-top: 18px;
}

.skeleton-button {
    height: 44px;
    margin: 22px 8px 0;
}

@keyframes skeletonMove {
    to {
        transform: translateX(-100%);
    }
}

/* =========================
   Premium footer
========================= */

.site-footer-shell {
    position: relative;
    z-index: 3;
    padding-top: 72px;
    overflow: hidden;
    color: #fff;
    background:
        radial-gradient(circle at 12% 35%, rgba(183, 213, 138, 0.22), transparent 23rem),
        radial-gradient(circle at 88% 64%, rgba(200, 137, 104, 0.13), transparent 20rem),
        linear-gradient(145deg, #637b57, #40553b 72%);
}

.site-footer-shell::before {
    content: "";
    position: absolute;
    inset: 0;
    opacity: 0.16;
    background-image:
        linear-gradient(45deg, transparent 47%, rgba(255, 255, 255, 0.12) 49%, transparent 51%),
        linear-gradient(-45deg, transparent 47%, rgba(255, 255, 255, 0.08) 49%, transparent 51%);
    background-size: 34px 34px;
}

.footer-wave {
    position: absolute;
    top: -1px;
    right: 0;
    left: 0;
    width: 100%;
    height: 82px;
    fill: #fbf5df;
}

.footer {
    position: relative;
    z-index: 3;
    width: min(1240px, calc(100% - 32px));
    min-height: 320px;
    height: auto !important;
    margin: 0 auto;
    padding: 30px 24px 55px;
    gap: 24px;
    color: rgba(255, 255, 255, 0.80);
    background: transparent !important;
}

.footer > .container,
.footer .logo-box,
.footer .htext-box,
.footer .social-box {
    position: relative;
    z-index: 2;
    padding: 24px;
    border: 1px solid rgba(255, 255, 255, 0.09);
    border-radius: 26px;
    background: rgba(255, 255, 255, 0.045);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.045);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.footer h1,
.footer h2,
.footer h3,
.footer h4,
.footer h5,
.footer strong,
.footer b {
    color: #fffdf7 !important;
}

.footer h3,
.footer h4 {
    position: relative;
    margin-bottom: 16px;
    font-weight: 900;
}

.footer h3::after,
.footer h4::after {
    content: "";
    display: block;
    width: 36px;
    height: 3px;
    margin-top: 9px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--sage), var(--gold));
}

.footer p,
.footer span,
.footer li {
    color: rgba(255, 255, 255, 0.70) !important;
    line-height: 1.95;
}

.footer a {
    color: rgba(255, 255, 255, 0.77) !important;
    transition: color var(--ease), transform var(--ease);
}

.footer a:hover {
    color: #fff !important;
}

.logo-footer {
    width: 205px;
    height: 205px;
    padding: 16px;
    object-fit: contain;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 30px;
    background: rgba(255, 255, 255, 0.06);
    filter: drop-shadow(0 22px 28px rgba(0, 0, 0, 0.18));
}

.social-containers {
    width: fit-content;
    height: fit-content;
}

.socials {
    width: 46px;
    height: 46px;
    padding: 9px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 15px;
    background: rgba(255, 255, 255, 0.07);
    transition: transform var(--ease), background var(--ease), border-color var(--ease);
}

.socials:hover {
    border-color: rgba(215, 175, 97, 0.46);
    background: rgba(255, 255, 255, 0.12);
    transform: translateY(-4px) rotate(-2deg);
}

.footer-art {
    position: absolute;
    z-index: 1;
    border-radius: 50%;
    pointer-events: none;
}

.footer-art-one {
    top: 120px;
    right: -130px;
    width: 330px;
    height: 330px;
    border: 1px dashed rgba(215, 175, 97, 0.16);
}

.footer-art-two {
    bottom: -100px;
    left: -80px;
    width: 250px;
    height: 250px;
    border: 1px solid rgba(183, 213, 138, 0.16);
    box-shadow: 0 0 0 28px rgba(150, 185, 94, 0.025), 0 0 0 56px rgba(150, 185, 94, 0.018);
}

.footer-stitch {
    position: relative;
    z-index: 2;
    height: 22px;
    border-top: 1px dashed rgba(255, 255, 255, 0.13);
}


/* =========================
   Enamad / trust seal
   The seal is injected by footer.js and must stay visible.
========================= */

.footer a[href*="enamad.ir"],
.footer a[href*="trustseal.enamad.ir"],
.footer .enamad,
.footer .enamad-box,
.footer #enamad,
.footer [class*="enamad"],
.footer [id*="enamad"] {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;

    min-width: 112px;
    min-height: 124px;

    padding: 10px;

    overflow: visible !important;

    border: 1px solid rgba(255, 255, 255, 0.72);
    border-radius: 20px;

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

    box-shadow:
        0 14px 32px rgba(45, 63, 39, 0.17),
        inset 0 1px 0 rgba(255, 255, 255, 0.95);

    opacity: 1 !important;
    visibility: visible !important;

    transition:
        transform var(--ease),
        box-shadow var(--ease);
}

.footer a[href*="enamad.ir"]:hover,
.footer a[href*="trustseal.enamad.ir"]:hover,
.footer .enamad:hover,
.footer .enamad-box:hover,
.footer #enamad:hover {
    transform: translateY(-4px);

    box-shadow:
        0 19px 39px rgba(45, 63, 39, 0.23),
        inset 0 1px 0 rgba(255, 255, 255, 0.95);
}

.footer a[href*="enamad.ir"]::after,
.footer a[href*="trustseal.enamad.ir"]::after {
    display: none !important;
}

.footer a[href*="enamad.ir"] img,
.footer a[href*="trustseal.enamad.ir"] img,
.footer img[src*="enamad"],
.footer img[src*="trustseal"],
.footer img[alt*="اینماد"],
.footer img[alt*="نماد اعتماد"] {
    display: block !important;

    width: auto !important;
    max-width: 92px !important;
    height: auto !important;
    max-height: 105px !important;

    margin: 0 auto !important;
    padding: 0 !important;

    object-fit: contain;

    border: 0 !important;
    border-radius: 0 !important;

    background: transparent !important;

    filter: none !important;

    opacity: 1 !important;
    visibility: visible !important;
}

/* =========================
   Modal replacing alert
========================= */

.art-modal-overlay {
    position: fixed;
    z-index: 9999;
    inset: 0;
    display: grid;
    place-items: center;
    padding: 20px;
    visibility: hidden;
    background: rgba(52, 70, 47, 0.48);
    opacity: 0;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    transition: opacity var(--ease), visibility var(--ease);
}

.art-modal-overlay.is-visible {
    visibility: visible;
    opacity: 1;
}

.art-modal {
    position: relative;
    width: min(100%, 440px);
    padding: 34px 29px 25px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.86);
    border-radius: 31px;
    background: rgba(255, 253, 247, 0.97);
    box-shadow: 0 30px 90px rgba(18, 28, 17, 0.30);
    text-align: center;
    transform: translateY(20px) scale(0.96);
    transition: transform var(--ease);
}

.art-modal::before {
    content: "";
    position: absolute;
    top: -110px;
    right: -80px;
    width: 240px;
    height: 240px;
    border: 1px dashed rgba(111, 139, 66, 0.17);
    border-radius: 50%;
}

.art-modal-overlay.is-visible .art-modal {
    transform: translateY(0) scale(1);
}

.art-modal-close {
    position: absolute;
    z-index: 3;
    top: 14px;
    left: 14px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    padding: 0;
    color: var(--muted);
    border: 0;
    border-radius: 50%;
    background: rgba(111, 139, 66, 0.09);
    cursor: pointer;
}

.art-modal-close svg {
    width: 19px;
    height: 19px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
}

.art-modal-icon {
    position: relative;
    display: grid;
    place-items: center;
    width: 76px;
    height: 76px;
    margin: 0 auto 18px;
    color: var(--sage-dark);
    border-radius: 25px;
    background: rgba(150, 185, 94, 0.15);
    transform: rotate(-3deg);
}

.art-modal-icon svg {
    width: 38px;
    height: 38px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.art-modal-content {
    position: relative;
    z-index: 2;
}

.art-modal-content h3 {
    margin-bottom: 10px;
    color: var(--forest);
    font-size: 1.24rem;
    font-weight: 950;
}

.art-modal-content p {
    margin: 0;
    color: var(--muted);
    font-size: 0.92rem;
    line-height: 1.95;
}

.art-modal-action {
    position: relative;
    z-index: 2;
    width: 100%;
    min-height: 47px;
    margin-top: 24px;
    padding: 10px 18px;
    color: #fff;
    border: 0;
    border-radius: 15px;
    background: linear-gradient(135deg, var(--sage), var(--sage-dark));
    box-shadow: var(--shadow-green);
    font-weight: 850;
    cursor: pointer;
}

.art-modal-overlay[data-type="warning"] .art-modal-icon {
    color: #9e772e;
    background: rgba(215, 175, 97, 0.16);
}

.art-modal-overlay[data-type="error"] .art-modal-icon {
    color: #a45546;
    background: rgba(200, 137, 104, 0.15);
}

.art-modal-overlay[data-type="success"] .art-modal-icon {
    color: #547d35;
    background: rgba(150, 185, 94, 0.16);
}

/* =========================
   Responsive
========================= */

@media (max-width: 991px) {
    .site-header {
        padding-inline: 14px;
    }

    #navbar {
        padding-inline: 16px !important;
    }

    #navbar .navbar-collapse {
        margin-top: 12px;
        padding: 13px;
        border: 1px solid rgba(111, 139, 66, 0.12);
        border-radius: 17px;
        background: rgba(255, 255, 255, 0.46);
    }

    .category-row {
        grid-template-columns: 1fr;
    }

    .category-row + .category-row {
        margin-top: 22px;
    }

    .footer {
        flex-direction: column !important;
        gap: 18px;
        text-align: center;
    }

    .footer h3::after,
    .footer h4::after {
        margin-inline: auto;
    }

    .footer .container,
    .footer .logo-box,
    .footer .htext-box,
    .footer .social-box {
        width: 100%;
    }

    .social-containers {
        justify-content: center;
        margin-inline: auto;
    }
}

@media (max-width: 575px) {
    .site-header {
        min-height: 88px;
        padding: 10px 10px 8px;
    }

    #navbar {
        min-height: 64px;
        padding: 8px 13px !important;
        border-radius: 19px;
    }

    .site-main {
        padding-top: 14px;
    }

    .catalog-section {
        padding: 30px 0;
    }

    .section-heading {
        align-items: center;
    }

    .section-heading h1,
    .section-heading h2 {
        font-size: 1.48rem;
    }

    .heading-decoration {
        display: none;
    }

    .categories-wrapper {
        width: calc(100% - 20px);
        padding: 18px 12px;
        border-radius: 31px;
    }

    .category-group {
        gap: 11px;
    }

    .category_frame {
        min-height: 122px;
        padding: 17px;
        border-radius: 22px;
    }

    .category_icons {
        width: 68px;
        height: 68px;
    }

    .category-name {
        display: block;
        padding-inline: 2px;
        text-align: center;
    }

    .category-name span {
        display: block;
        font-size: 0.87rem;
    }

    .category-name small {
        display: none;
    }

    .handmade-mark {
        width: 52px;
        height: 52px;
        border-radius: 18px;
    }

    .product-stage {
        width: calc(100% - 20px);
        padding: 15px 11px;
        border-radius: 30px;
    }

    .products-scroll {
        gap: 12px;
    }

    .card.product-card,
    .product-skeleton {
        flex-basis: 224px;
        min-width: 224px !important;
    }

    .product-media,
    .skeleton-image {
        height: 178px;
    }

    .site-footer-shell {
        padding-top: 58px;
    }

    .footer {
        width: calc(100% - 20px);
        padding-inline: 0;
    }

    .footer > .container,
    .footer .logo-box,
    .footer .htext-box,
    .footer .social-box {
        padding: 20px 15px;
        border-radius: 22px;
    }

    .logo-footer {
        width: 130px !important;
        height: 130px !important;
    }

    .socials {
        width: 40px;
        height: 40px;
    }

    .art-modal {
        padding: 32px 20px 21px;
        border-radius: 26px;
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* =========================================================
   Lightweight redesign
   Keeps the Verta palette while avoiding expensive painting.
========================================================= */

:root {
    --shadow-soft: 0 6px 20px rgba(54, 66, 41, 0.08) !important;
    --shadow-card: 0 8px 24px rgba(54, 66, 41, 0.10) !important;
    --shadow-green: 0 7px 18px rgba(112, 143, 78, 0.14) !important;
    --ease: 90ms ease-out !important;
}

html {
    scroll-behavior: auto !important;
}

*,
*::before,
*::after {
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}

a,
button,
input,
textarea,
select,
.card,
.category_frame,
.product-image,
.product-img,
[class*="modal"] {
    transition: none !important;
}

#navbar,
.categories-wrapper,
.product-stage,
.card.product-card,
.category-products-stage,
#category .card,
.product-detail-card,
.product-order-card,
.product-content-card,
.comments-card,
.basket-products-card,
.basket-summary-card,
.login-shell,
.register-shell,
.bill-card,
.art-modal,
.category-modal,
.product-modal,
.basket-modal,
.login-modal,
.register-modal {
    box-shadow: 0 7px 22px rgba(54, 66, 41, 0.09) !important;
}

.site-header {
    box-shadow: 0 1px 0 rgba(79, 103, 55, 0.10) !important;
}

#navbar {
    border-radius: 20px !important;
}

.header-glow,
.header-thread,
.craft-orbit,
.category-shine,
.categories-wrapper::before,
.categories-wrapper::after,
.product-stage::before,
.product-stage::after,
.stage-thread,
.product-detail-decoration,
.category-stage-decoration,
.category-stage-thread,
.basket-products-card::before,
.basket-products-card::after,
.bill-decoration,
.footer-art {
    display: none !important;
}

#navbar img,
.category_icons,
.product-image,
.product-img,
#category .card-img-top,
.see-btn,
.add-to-basket-button,
#add_basket,
.comment-submit-button {
    filter: none !important;
}

.category-item:hover .category_frame,
.card.product-card:hover,
#category .card:hover,
.product-image-frame:hover .product-img,
.product-card:hover .product-image,
.see-btn:hover,
.add-to-basket-button:hover,
#add_basket:hover,
.comment-submit-button:hover {
    transform: none !important;
}

.basket-art-handle,
.product-skeleton,
.skeleton-button::after {
    animation: none !important;
}

.page-texture,
.login-page-texture,
.register-page-texture,
.bill-page-texture {
    opacity: 0.10 !important;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}
