/* صفحه‌ی محصول — فقط قواعدی که مخصوص این صفحه است. پایه‌ی مشترک در app.css */
/* =========================================================
   tokens (هماهنگ با صفحه‌ی اصلی)
   ========================================================= */
:root {
    --bg: #FDFBF8;
    --card: #F4EDE5;
    --sand: #EFE6DB;
    --clay: #C8A78D;
    --clay-d: #B08E73;
    --taupe: #816f5e;
    --ink: #1D1A17;
    --ink-soft: #6B6058;
    --line: rgba(29, 26, 23, .11);
    --line-soft: rgba(29, 26, 23, .06);
    --rad: 20px;
    --rad-lg: 26px;
    --rad-xl: 34px;
    --e: cubic-bezier(.16, .84, .34, 1);
}

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth
}

.h1 {
    font-size: clamp(30px, 4.4vw, 54px);
    font-weight: 200;
}

.h2 {
    font-size: clamp(24px, 3.2vw, 40px);
    font-weight: 200
}

.h3 {
    font-size: clamp(17px, 2vw, 22px)
}

section {
    padding: 96px 0
}

/* =========================================================
   cursor + progress
   ========================================================= */
.cursor {
    position: fixed;
    top: 0;
    left: 0;
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: var(--ink);
    z-index: 150;
    pointer-events: none;
    opacity: 0;
    mix-blend-mode: difference;
    transform: translate3d(var(--cx, 0), var(--cy, 0), 0);
    transition: width .35s var(--e), height .35s var(--e), opacity .3s, margin .35s var(--e), background .35s;
}

.cursor.is-large {
    width: 76px;
    height: 76px;
    margin: -33px 0 0 -33px;
    background: #fff
}

.progress {
    position: fixed;
    top: 0;
    right: 0;
    height: 2px;
    z-index: 120;
    background: var(--clay-d);
    width: var(--p, 0%);
    transition: width .1s linear
}

.menu {
    display: flex;
    align-items: center;
    gap: 30px;
    font-size: 14px;
    list-style: none
}

.menu a {
    color: var(--ink-soft);
    transition: color .3s;
    padding: 8px 0
}

/* =========================================================
   buttons
   ========================================================= */
.pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    white-space: nowrap;
    padding: 11px 22px;
    border-radius: 100px;
    font-size: 14.5px;
    background: var(--ink);
    color: var(--bg) !important;
    position: relative;
    overflow: hidden;
    transition: color .4s var(--e);
    z-index: 2;
}

.pill::before {
    content: "";
    position: absolute;
    inset: 0;
    background: var(--clay-d);
    border-radius: inherit;
    transform: translateY(101%);
    transition: transform .5s var(--e)
}

.pill--block {
    width: 100%
}

.pill--sm {
    padding: 12px 22px;
    font-size: 13px
}

/* =========================================================
   breadcrumb
   ========================================================= */
.pdp {
    padding-top: 118px
}

.crumbs {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 12.5px;
    color: var(--taupe);
    padding-bottom: 26px
}

.crumbs a {
    transition: color .3s
}

.crumbs a:hover {
    color: var(--ink)
}

.crumbs i {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: var(--line);
    display: block
}

/* =========================================================
   product layout
   ========================================================= */
.pdp-grid {
    display: grid;
    grid-template-columns:1.12fr .88fr;
    gap: 52px;
    align-items: start
}

/* --- gallery --- */
.pdp-gallery {
    display: grid;
    grid-template-columns:86px 1fr;
    gap: 14px
}

.thumbs {
    display: grid;
    gap: 10px;
    align-content: start
}

.thumb {
    position: relative;
    aspect-ratio: 4/5;
    border-radius: 14px;
    overflow: hidden;
    background: var(--card);
    opacity: .5;
    transition: opacity .45s var(--e), transform .45s var(--e);
}

.thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    border-radius: inherit;
    border: 1px solid transparent;
    transition: border-color .45s var(--e)
}

.thumb:hover {
    opacity: .85;
    transform: translateY(-2px)
}

.thumb.is-on {
    opacity: 1
}

.thumb.is-on::after {
    border-color: var(--ink)
}

.thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover
}

.stage {
    position: relative;
    border-radius: var(--rad-lg);
    overflow: hidden;
    background: var(--card);
    aspect-ratio: 4/5;
    cursor: zoom-in;
    --ox: 50%;
    --oy: 50%;
}

.stage img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transform: scale(1.05);
    transform-origin: var(--ox) var(--oy);
    transition: opacity .7s var(--e), transform 1.1s var(--e);
}

.stage img.is-on {
    opacity: 1;
    transform: scale(1)
}

.stage:hover img.is-on {
    transform: scale(1.28)
}

.stage-tag {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 3;
    background: rgba(253, 251, 248, .94);
    backdrop-filter: blur(6px);
    border-radius: 100px;
    padding: 8px 16px;
    font-size: 11.5px;
    letter-spacing: .06em;
    color: var(--ink-soft);
}

.stage-hint {
    position: absolute;
    bottom: 16px;
    left: 16px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(253, 251, 248, .94);
    backdrop-filter: blur(6px);
    border-radius: 100px;
    padding: 10px 16px;
    font-size: 12px;
    opacity: 0;
    transform: translateY(10px);
    transition: .45s var(--e);
}

.stage:hover .stage-hint {
    opacity: 1;
    transform: none
}

.stage-hint svg {
    stroke: currentColor;
    fill: none;
    stroke-width: 1.3
}

.stage-count {
    position: absolute;
    bottom: 16px;
    right: 16px;
    z-index: 3;
    font-size: 12px;
    letter-spacing: .14em;
    color: var(--ink-soft);
    background: rgba(253, 251, 248, .9);
    border-radius: 100px;
    padding: 8px 14px;
}

/* --- info --- */
.info {
    position: sticky;
    top: 100px
}

.info-title {
    margin: 14px 0 12px
}

.info-title *{
    font-size: var(--mega-title);
    font-weight: 300;
    line-height: 50px;
}

.sec-title {
    margin: 14px 0 26px
}

.fabric-title {
    margin: 14px 0
}

.info-lead {
    max-width: 44ch
}

.info-meta {
    display: flex;
    gap: 18px;
    flex-wrap: wrap;
    margin-top: 18px;
    font-size: 12.5px;
    color: var(--taupe)
}

.info-meta span {
    display: inline-flex;
    align-items: center;
    gap: 8px
}

.info-meta i {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--clay);
    display: block
}

.block {
    margin-top: 30px
}

.block-title {
    font-size: 11.5px;
    letter-spacing: .2em;
    color: var(--taupe);
    margin-bottom: 14px;
    display: flex;
    justify-content: space-between
}

.block-title b {
    font-weight: 400;
    color: var(--ink);
    letter-spacing: 0;
    font-size: 13.5px
}

.colors {
    display: flex;
    gap: 12px
}

.color {
    position: relative;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: var(--c);
    border: 1px solid rgba(0, 0, 0, .08);
    transition: transform .4s var(--e);
}

.color::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 1px solid var(--ink);
    opacity: 0;
    transform: scale(.82);
    transition: .45s var(--e);
}

.color:hover {
    transform: translateY(-3px)
}

.color.is-on::after {
    opacity: 1;
    transform: none
}

.sizes {
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.size {
    min-width: 52px;
    padding: 11px 16px;
    border: 1px solid var(--line);
    border-radius: 14px;
    font-size: 13.5px;
    color: var(--ink-soft);
    transition: .4s var(--e);
}

.size:hover {
    border-color: var(--clay);
    color: var(--ink)
}

.size.is-on {
    background: var(--ink);
    border-color: var(--ink);
    color: var(--bg)
}

.size.is-off {
    opacity: .35;
    text-decoration: line-through;
    cursor: not-allowed
}

.size-note {
    font-size: 12px;
    color: var(--taupe);
    margin-top: 10px
}

/* accordion */
.acc {
    margin-top: 30px;
    border-bottom: 1px solid var(--line)
}

.acc-item {
    border-top: 1px solid var(--line)
}

.acc-head {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    padding: 17px 0;
    font-size: 14.5px;
    text-align: right
}

.acc-sign {
    position: relative;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid var(--line);
    flex: none;
    transition: .45s var(--e)
}

.acc-sign::before, .acc-sign::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    width: 9px;
    height: 1px;
    background: var(--ink);
    transform: translate(-50%, -50%);
    transition: .45s var(--e)
}

.acc-sign::after {
    transform: translate(-50%, -50%) rotate(90deg)
}

.acc-item.is-open .acc-sign {
    background: var(--ink);
    border-color: var(--ink)
}

.acc-item.is-open .acc-sign::before, .acc-item.is-open .acc-sign::after {
    background: var(--bg)
}

.acc-item.is-open .acc-sign::after {
    transform: translate(-50%, -50%) rotate(0)
}

.acc-body {
    display: grid;
    grid-template-rows:0fr;
    transition: grid-template-rows .55s var(--e)
}

.acc-item.is-open .acc-body {
    grid-template-rows:1fr
}

.acc-body > div {
    overflow: hidden
}

.acc-inner {
    padding-bottom: 18px;
    font-size: 13.5px;
    color: var(--ink-soft)
}

.spec {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 9px 0;
    border-bottom: 1px dashed var(--line-soft);
    font-size: 13.5px
}

.spec:last-child {
    border-bottom: none
}

.actions {
    display: grid;
    gap: 10px;
    margin-top: 26px
}

.actions-row {
    display: grid;
    grid-template-columns:1fr auto;
    gap: 10px;
}

.ghost-icon {
    width: 54px;
    border: 1px solid var(--line);
    border-radius: 100px;
    display: grid;
    place-items: center;
    transition: .4s var(--e);
    padding: 15px;
}

.ghost-icon:hover {
    background: var(--ink);
    border-color: var(--ink);
}

.ghost-icon svg {
    stroke: var(--ink);
    fill: none;
    stroke-width: 1.3;
    transition: stroke .4s;
}

.ghost-icon:hover svg {
    stroke: var(--bg);
}

.ghost-icon.is-saved svg {
    fill: var(--clay-d);
    stroke: var(--clay-d);
}

.ghost-icon.is-saved:hover svg {
    fill: var(--bg);
    stroke: var(--bg);
}

.no-shop {
    margin-top: 16px;
    background: var(--card);
    border-radius: 16px;
    padding: 16px 18px;
    font-size: 12.5px;
    color: var(--ink-soft);
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.no-shop svg {
    flex: none;
    margin-top: 4px;
    stroke: var(--clay-d);
    fill: none;
    stroke-width: 1.2;
}

/* =========================================================
   feature strip
   ========================================================= */
.features {
    display: grid;
    grid-template-columns:repeat(3, 1fr);
    gap: 18px;
    margin-top: 74px
}

.feature {
    background: var(--sand);
    border-radius: var(--rad);
    padding: 26px 24px;
    position: relative;
    overflow: hidden;
    transition: transform .5s var(--e), background .5s var(--e);
}

.feature::before {
    content: "";
    position: absolute;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    left: -60px;
    bottom: -90px;
    background: radial-gradient(circle, rgba(200, 167, 141, .4), transparent 70%);
    opacity: 0;
    transition: opacity .6s var(--e);
}

.feature:hover {
    transform: translateY(-6px);
    background: #fff
}

.feature:hover::before {
    opacity: 1
}

.feature svg {
    stroke: var(--clay-d);
    fill: none;
    stroke-width: 1.2;
    position: relative
}

.feature h4 {
    font-size: 15px;
    font-weight: 400;
    margin: 12px 0 6px;
    position: relative
}

.feature p {
    font-size: 13px;
    color: var(--ink-soft);
    position: relative
}

/* =========================================================
   fabric section
   ========================================================= */
.fabric {
    background: var(--sand);
    border-radius: var(--rad-xl);
    overflow: hidden
}

.fabric-in {
    display: grid;
    grid-template-columns:1fr 1fr;
    gap: 52px;
    align-items: center;
    padding: 66px 52px
}

.fabric-media {
    position: relative;
    border-radius: var(--rad);
    overflow: hidden
}

.fabric-media img {
    width: 100%;
    height: clamp(300px, 44vh, 420px);
    object-fit: cover;
    transform: translateY(var(--fy, 0)) scale(1.08);
    transition: transform .3s linear
}

.fabric-list {
    margin-top: 26px
}

.fabric-list .spec {
    border-bottom: 1px solid var(--line)
}

.zoom-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: var(--bg);
    border-radius: 100px;
    padding: 9px 16px;
    font-size: 11.5px;
    display: flex;
    align-items: center;
    gap: 9px;
}

.zoom-badge i {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--clay);
    display: block;
    animation: pulse 2.4s infinite
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1)
    }
    50% {
        opacity: .35;
        transform: scale(1.5)
    }
}

/* =========================================================
   size table
   ========================================================= */
.table {
    border-radius: var(--rad);
    overflow: hidden;
    border: 1px solid var(--line)
}

.trow {
    display: grid;
    grid-template-columns:repeat(var(--cols,5),1fr);
    font-size: 13.5px
}

.trow > div {
    padding: 15px 14px;
    border-bottom: 1px solid var(--line-soft);
    text-align: center;
    transition: background .35s
}

.trow > div:first-child {
    text-align: right;
    color: var(--taupe)
}

.trow--head > div {
    background: var(--card);
    color: var(--ink);
    font-size: 12.5px;
    letter-spacing: .06em
}

.trow:last-child > div {
    border-bottom: none
}

.trow:not(.trow--head):hover > div {
    background: rgba(200, 167, 141, .12)
}

/* =========================================================
   related
   ========================================================= */
.rgrid {
    display: grid;
    grid-template-columns:repeat(4, 1fr);
    gap: 18px
}

.rcard {
    cursor: pointer
}

.rmedia {
    position: relative;
    overflow: hidden;
    border-radius: var(--rad);
    background: var(--card);
    aspect-ratio: 4/5
}

.rmedia img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1.1s var(--e)
}

.rcard:hover .rmedia img {
    transform: scale(1.07)
}

.rlabel {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(253, 251, 248, .92);
    padding: 6px 13px;
    border-radius: 100px;
    font-size: 11px;
    color: var(--ink-soft)
}

.rmore {
    position: absolute;
    inset: auto 12px 12px 12px;
    background: var(--ink);
    color: var(--bg);
    border-radius: 100px;
    padding: 11px;
    text-align: center;
    font-size: 12.5px;
    opacity: 0;
    transform: translateY(14px);
    transition: .45s var(--e)
}

.rcard:hover .rmore {
    opacity: 1;
    transform: none
}

.rbody {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 4px 0
}

.rbody h3 {
    font-size: 15px;
    font-weight: 400
}

.rbody p {
    font-size: 12.5px;
    color: var(--taupe)
}

/* =========================================================
   lightbox
   ========================================================= */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 140;
    display: grid;
    place-items: center;
    padding: 26px;
    opacity: 0;
    visibility: hidden;
    transition: .45s var(--e)
}

.lightbox.is-open {
    opacity: 1;
    visibility: visible
}

.lightbox-bg {
    position: absolute;
    inset: 0;
    background: rgba(29, 26, 23, .72);
    backdrop-filter: blur(8px)
}

.lightbox figure {
    position: relative;
    max-width: min(880px, 100%);
    max-height: 86vh;
    border-radius: var(--rad-lg);
    overflow: hidden;
    transform: scale(.96);
    transition: transform .5s var(--e)
}

.lightbox.is-open figure {
    transform: none
}

.lightbox img {
    max-height: 86vh;
    object-fit: contain;
    background: var(--card)
}

.lb-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 46px;
    height: 46px;
    border-radius: 50%;
    background: rgba(253, 251, 248, .92);
    display: grid;
    place-items: center;
    transition: .35s var(--e);
    z-index: 2
}

.lb-nav:hover {
    background: var(--bg);
    transform: translateY(-50%) scale(1.06)
}

.lb-prev {
    right: 16px
}

.lb-next {
    left: 16px
}

.lb-nav svg {
    stroke: var(--ink);
    fill: none;
    stroke-width: 1.4
}

.lb-close {
    position: absolute;
    top: 18px;
    left: 18px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(253, 251, 248, .92);
    display: grid;
    place-items: center;
    font-size: 19px;
    z-index: 3;
    transition: .3s
}

.lb-close:hover {
    background: #fff
}

.lb-count {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    background: rgba(253, 251, 248, .92);
    border-radius: 100px;
    padding: 7px 16px;
    font-size: 12px;
    letter-spacing: .12em
}

/* =========================================================
   mobile ask bar + menu
   ========================================================= */
.askbar {
    position: fixed;
    inset: auto 0 0 0;
    z-index: 90;
    background: rgba(253, 251, 248, .94);
    backdrop-filter: blur(14px);
    border-top: 1px solid var(--line-soft);
    padding: 12px 20px;
    display: none;
    gap: 10px;
    align-items: center;
    justify-content: space-between;
    transform: translateY(120%);
    transition: transform .5s var(--e);
}

.askbar.is-up {
    transform: none
}

.askbar b {
    font-size: 14px;
    font-weight: 400
}

.askbar span {
    display: block;
    font-size: 11.5px;
    color: var(--taupe)
}

/* =========================================================
   reveal
   ========================================================= */
.rv {
    opacity: 0;
    transform: translateY(26px);
    filter: blur(5px);
    transition: opacity .9s var(--e), transform .9s var(--e), filter .9s var(--e)
}

.sp:nth-child(2) i {
    transition-delay: .07s
}

.sp:nth-child(3) i {
    transition-delay: .14s
}

.sp:nth-child(4) i {
    transition-delay: .21s
}

/* =========================================================
   responsive
   ========================================================= */
@media (max-width: 1080px) {
    .pdp-grid {
        grid-template-columns:1fr;
        gap: 38px
    }

    .info {
        position: static
    }

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

    .fabric-in {
        grid-template-columns:1fr;
        padding: 44px 28px;
        gap: 32px
    }
}

@media (max-width: 900px) {
    .pdp-gallery {
        grid-template-columns:1fr
    }

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

    .features {
        grid-template-columns:1fr;
        margin-top: 54px
    }

    .askbar {
        display: flex
    }

    section {
        padding: 70px 0
    }

    .stage:hover img.is-on {
        transform: scale(1)
    }
}

@media (max-width: 620px) {

    .crumbs {
        padding-top: 85px;
        overflow: auto;
    }

    .crumbs a, .crumbs span {
        white-space: nowrap;
    }

    .rgrid {
        grid-template-columns:repeat(2, 1fr);
        gap: 12px
    }

    .trow {
        grid-template-columns:repeat(min(var(--cols,5),3),1fr);
        font-size: 12.5px
    }

    .trow > div:nth-child(n+4) {
        display: none
    }

    .pdp {
        padding-top: 96px
    }
}

@media (prefers-reduced-motion: reduce) {
    .rv {
        opacity: 1;
        transform: none;
        filter: none
    }
}
