/* Istalif Gallery — public site */
:root {
  --bg: #f3ede4;
  --bg-alt: #ebe2d5;
  --paper: #fbf8f3;
  --ink: #221a15;
  --ink-2: #4a3f36;
  --muted: #7a6e62;
  --line: #ddd1bf;
  --red: #8e2a1f;
  --red-d: #72201a;
  --navy: #1f2a44;
  --gold: #c9a46a;
  --wa: #1f7a4d;
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1200px;
  --r: 2px;
}
[dir="rtl"] { --serif: "Vazirmatn", Tahoma, sans-serif; --sans: "Vazirmatn", Tahoma, sans-serif; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.6 var(--sans); }
img { max-width: 100%; display: block; }
figure { margin: 0; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 500; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 680px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip { position: absolute; top: 0; left: 0; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.skip:focus { width: auto; height: auto; clip: auto; left: 12px; top: 12px; z-index: 99; background: var(--ink); color: #fff; padding: 8px 12px; }
.spacer { height: 72px; }
.icon { width: 18px; height: 18px; flex: none; vertical-align: -3px; }
[dir="rtl"] .icon--flip, [dir="rtl"] .link .icon { transform: scaleX(-1); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

/* Type */
.eyebrow { font: 600 11px/1.4 var(--sans); letter-spacing: .22em; text-transform: uppercase; color: var(--red); margin-bottom: 14px; }
.eyebrow--gold { color: var(--gold); }
.display { font: 500 clamp(40px, 6vw, 68px)/1.04 var(--serif); letter-spacing: -.01em; margin-bottom: 20px; }
.display--md { font-size: clamp(34px, 4.4vw, 48px); line-height: 1.08; }
.display--light { color: #f6efe4; }
.h2 { font: 500 clamp(28px, 3.4vw, 38px)/1.15 var(--serif); }
.h2--light { color: #f6efe4; margin-bottom: 18px; }
.h3 { font: 500 24px/1.2 var(--serif); margin: 28px 0 10px; }
.lead { font-size: 17px; color: var(--ink-2); max-width: 34em; }
[dir="rtl"] .display, [dir="rtl"] .h2, [dir="rtl"] .h3 { font-weight: 700; letter-spacing: 0; line-height: 1.35; }
[dir="rtl"] .eyebrow { letter-spacing: 0; }

/* Buttons & links */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 22px; border: 1px solid transparent; border-radius: var(--r); font: 500 14px/1.2 var(--sans); text-decoration: none; cursor: pointer; transition: background .15s, color .15s, border-color .15s; }
.btn--sm { padding: 9px 14px; font-size: 13px; }
.btn--block { width: 100%; }
.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #000; }
.btn--red { background: var(--red); color: #fff; }
.btn--red:hover { background: var(--red-d); }
.btn--wa { background: var(--wa); color: #fff; }
.btn--wa:hover { background: #17603c; }
.btn--line { border-color: var(--ink); background: transparent; }
.btn--line:hover { background: var(--ink); color: #fff; }
.btn[disabled] { opacity: .6; cursor: progress; }
.link { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; text-decoration: none; color: var(--ink-2); }
.link:hover { color: var(--red); }
.link--red { color: var(--red); font-weight: 500; }
.link--light { color: #f6efe4; border-bottom: 1px solid var(--gold); padding-bottom: 2px; }
.link--light:hover { color: var(--gold); }

/* Top bar & header */
.topbar { background: var(--ink); color: #e9dfd0; font-size: 12.5px; }
.topbar__in { display: flex; justify-content: space-between; align-items: center; min-height: 36px; gap: 12px; }
.lang { display: flex; gap: 12px; }
.lang a { text-decoration: none; opacity: .65; }
.lang a.is-on { opacity: 1; font-weight: 600; }
.header { background: var(--bg); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 30; }
.header__in { display: flex; align-items: center; gap: 28px; min-height: 76px; }
.logo { text-decoration: none; display: flex; flex-direction: column; line-height: 1; }
.logo__name { font: 500 26px/1 var(--serif); letter-spacing: .2em; }
[dir="rtl"] .logo__name { font-family: "Cormorant Garamond", Georgia, serif; }
.logo__sub { font-size: 9.5px; letter-spacing: .32em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.nav { display: flex; gap: 26px; margin-inline-start: auto; }
.nav a { text-decoration: none; font-size: 14px; padding: 6px 0; border-bottom: 1px solid transparent; }
.nav a:hover, .nav a.is-active { border-color: var(--red); }
.nav .nav__wa-mobile { display: none; }
.burger { display: none; background: none; border: 0; width: 40px; height: 40px; padding: 10px 8px; cursor: pointer; margin-inline-start: auto; }
.burger span { display: block; height: 2px; background: var(--ink); margin: 4px 0; transition: transform .2s; }

/* Notices */
.notice { margin: 18px 0; padding: 12px 16px; border-inline-start: 3px solid var(--gold); background: var(--paper); font-size: 14px; }
.notice--error { border-color: var(--red); color: var(--red-d); }
.notice--success { border-color: var(--wa); }

/* Hero */
.hero { padding: 64px 0 56px; }
.hero__grid { display: grid; grid-template-columns: 1fr 1.05fr; gap: 64px; align-items: center; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero__actions--center { justify-content: center; }
.hero__figure { margin: 0; }
.hero__figure figcaption { font-size: 12.5px; color: var(--muted); margin-top: 10px; }
.frame { position: relative; background: var(--bg-alt); padding: 14px; border: 1px solid var(--line); }
.frame img { width: 100%; aspect-ratio: 4 / 3.4; object-fit: cover; }
.frame--tall img { aspect-ratio: 4 / 4.4; }
.frame__cap { position: absolute; left: 26px; bottom: 26px; background: rgba(251, 248, 243, .92); padding: 4px 10px; font-size: 12px; }
[dir="rtl"] .frame__cap { left: auto; right: 26px; }

/* Promises */
.promises { background: var(--bg-alt); border-block: 1px solid var(--line); padding: 30px 0; }
.promises__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.promise { display: flex; gap: 14px; }
.promise__icon { color: var(--red); padding-top: 2px; }
.promise h3 { font: 600 14px/1.4 var(--sans); margin-bottom: 4px; }
.promise p { margin: 0; font-size: 13.5px; color: var(--muted); }

/* Sections & grids */
.section { padding: 72px 0; }
.section--tight { padding-top: 8px; }
.section--alt { background: var(--bg-alt); }
.section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 28px; }
.grid { display: grid; gap: 24px; }
.grid--4 { grid-template-columns: repeat(4, 1fr); }

.coll { text-decoration: none; display: block; }
.coll__media { overflow: hidden; background: var(--bg-alt); }
.coll__media img { width: 100%; aspect-ratio: 4 / 4.6; object-fit: cover; transition: transform .5s; }
.coll:hover .coll__media img { transform: scale(1.03); }
.coll__row { display: flex; justify-content: space-between; align-items: center; padding-top: 12px; }
.coll__row h3 { font: 500 24px/1.2 var(--serif); }
.coll:hover .link { color: var(--red); }

/* Product card */
.card { text-decoration: none; display: block; }
.card__media { position: relative; overflow: hidden; background: var(--bg-alt); margin-bottom: 12px; }
.card__media img { width: 100%; aspect-ratio: 4 / 4.4; object-fit: cover; transition: transform .5s; }
.card:hover .card__media img { transform: scale(1.03); }
.card--sold .card__media img { filter: grayscale(.5) opacity(.75); }
.card__code { font-size: 11px; letter-spacing: .14em; color: var(--muted); }
.card__title { font: 500 22px/1.2 var(--serif); margin: 4px 0; }
.card:hover .card__title { color: var(--red); }
.card__meta { font-size: 13px; color: var(--muted); }
.card__price { font-size: 14px; font-weight: 600; color: var(--red); margin-top: 4px; }
.tag { position: absolute; top: 10px; inset-inline-start: 10px; background: var(--paper); font: 600 10px/1 var(--sans); letter-spacing: .14em; text-transform: uppercase; padding: 6px 8px; }
.tag--static { position: static; display: inline-block; background: var(--ink); color: #fff; }
.tag--outline { position: static; display: inline-block; background: transparent; border: 1px solid var(--ink); }
.tag--gold { position: static; display: inline-block; background: var(--gold); }
.tags { display: flex; gap: 8px; margin-bottom: 18px; }
.stamp { position: absolute; top: 10px; inset-inline-end: 10px; border: 2px solid var(--red); color: var(--red); background: rgba(251, 248, 243, .9); font: 700 11px/1 var(--sans); letter-spacing: .2em; padding: 6px 10px; text-transform: uppercase; transform: rotate(-4deg); }
.stamp--soft { border-color: var(--gold); color: #8a6420; }
.stamp--lg { top: 28px; inset-inline-end: 28px; font-size: 15px; padding: 10px 16px; }

/* Story band */
.story-band { background: var(--navy); color: #d9d2c5; padding: 88px 0; }
.story-band__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.story-band .frame { background: #2a3555; border-color: #34406a; }
.story-band__text { color: #d9d2c5; max-width: 32em; }

/* Steps */
.steps { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.step { border-top: 1px solid var(--ink); padding-top: 18px; }
.step__n { font: 500 28px/1 var(--serif); color: var(--red); }
.step h3 { font: 600 15px/1.4 var(--sans); margin: 12px 0 6px; }
.step p { font-size: 14px; color: var(--muted); }

/* Visit block */
.visit { background: var(--bg-alt); padding: 72px 0; border-top: 1px solid var(--line); }
.visit__grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 56px; align-items: center; }
.visit__line { display: flex; gap: 10px; color: var(--ink-2); margin: 14px 0 0; }
.visit__line .icon { color: var(--red); margin-top: 3px; }
.map { background: #d9ccb6; min-height: 300px; border: 1px solid var(--line); }
.map iframe { width: 100%; height: 100%; min-height: 300px; border: 0; display: block; }
.map--wide iframe { min-height: 380px; }

/* Footer */
.footer { background: var(--ink); color: #c9bdad; padding: 56px 0 0; font-size: 14px; }
.footer__grid { display: grid; grid-template-columns: 1.4fr 1fr 1.2fr 1fr; gap: 32px; }
.footer h3 { font: 600 11px/1 var(--sans); letter-spacing: .2em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }
.footer a { display: block; text-decoration: none; margin-bottom: 8px; }
.footer a:hover { color: #fff; }
.footer__logo { font: 500 22px/1 "Cormorant Garamond", Georgia, serif; letter-spacing: .24em; color: #f6efe4; margin-bottom: 12px; }
.footer__tag { color: #9d9182; }
.footer__bottom { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 22px 24px; margin-top: 40px; border-top: 1px solid #3a2f27; font-size: 12.5px; color: #9d9182; }

.wa-float { position: fixed; bottom: 22px; inset-inline-end: 22px; width: 56px; height: 56px; border-radius: 50%; background: var(--wa); color: #fff; display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0, 0, 0, .22); z-index: 40; transition: transform .15s; }
.wa-float:hover { transform: scale(1.06); }
.wa-float .icon { width: 28px; height: 28px; }

/* Collection page */
.crumbs { font-size: 13px; color: var(--muted); padding: 22px 0 0; }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: var(--red); }
.crumbs--light { color: #a8a090; padding: 0 0 28px; }
.page-head { padding: 28px 0 10px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 20px; }
.chip { text-decoration: none; border: 1px solid var(--line); background: var(--paper); padding: 8px 14px; font-size: 13.5px; border-radius: 40px; }
.chip small { color: var(--muted); margin-inline-start: 4px; }
.chip.is-on { background: var(--ink); color: #fff; border-color: var(--ink); }
.chip.is-on small { color: #bbb; }
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px; padding: 18px; background: var(--paper); border: 1px solid var(--line); }
.filters label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--muted); }
.filters .filters__search { flex: 1 1 220px; }
.filters input[type=search], .filters select { border: 1px solid var(--line); background: #fff; padding: 9px 10px; border-radius: var(--r); font-size: 14px; color: var(--ink); min-width: 130px; }
.filters .check { flex-direction: row; align-items: center; gap: 6px; font-size: 13.5px; color: var(--ink); padding-bottom: 9px; }
.filters__btns { display: flex; gap: 8px; }
.count { margin: 18px 0; font-size: 14px; }
.empty { text-align: center; padding: 64px 16px; background: var(--paper); border: 1px dashed var(--line); }

/* Product page */
.pdp { display: grid; grid-template-columns: 1.25fr 1fr; gap: 56px; padding: 24px 0 72px; align-items: start; }
.pdp__gallery { position: sticky; top: 100px; }
.pdp__main img { aspect-ratio: 4 / 4.2; }
.thumbs { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin: 12px 0; }
.thumb { padding: 0; border: 2px solid transparent; background: var(--bg-alt); cursor: pointer; }
.thumb img { width: 100%; aspect-ratio: 1; object-fit: cover; }
.thumb.is-on { border-color: var(--red); }
.thumb--video { display: flex; align-items: center; justify-content: center; gap: 6px; text-decoration: none; font-size: 13px; aspect-ratio: 1; border: 1px solid var(--line); }
.pdp__price { margin: 0 0 22px; }
.pdp__price strong { color: var(--red); font-size: 20px; font-weight: 600; margin-inline-end: 8px; }
.pdp__info .btn--block { margin-top: 4px; }
.pdp__info .btn + .small { margin: 8px 0 16px; }
.specs { margin: 28px 0 0; border-top: 1px solid var(--line); }
.specs > div { display: flex; justify-content: space-between; gap: 20px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; text-align: end; }
.specs--contact > div { flex-direction: column; gap: 4px; }
.specs--contact dt { display: flex; gap: 8px; align-items: center; }
.specs--contact dd { text-align: start; }
.pdp__story { color: var(--ink-2); }
.trust { list-style: none; padding: 18px 20px; margin: 28px 0 0; background: var(--bg-alt); border: 1px solid var(--line); }
.trust li { display: flex; gap: 10px; align-items: center; font-size: 14px; padding: 6px 0; }
.trust .icon { color: var(--red); }

/* Story page */
.story-hero { background: var(--navy); padding: 28px 0 72px; }
.story-hero .display { max-width: 16em; }
.story { display: grid; grid-template-columns: 1fr 1.15fr; gap: 72px; align-items: start; }
.story__figure { margin: 0; position: sticky; top: 100px; }
.story__figure figcaption { font-size: 13px; color: var(--muted); margin-top: 10px; }
.story__text { font-size: 17px; color: var(--ink-2); }
.story__lead::first-letter { float: left; font: 500 76px/0.8 var(--serif); color: var(--red); padding: 8px 10px 0 0; }
[dir="rtl"] .story__lead::first-letter { float: none; font: inherit; color: inherit; padding: 0; }
.quote { margin: 40px 0; padding: 0 0 0 28px; border-inline-start: 3px solid var(--gold); font: italic 500 clamp(28px, 3.4vw, 38px)/1.2 var(--serif); color: var(--ink); }
[dir="rtl"] .quote { padding: 0 28px 0 0; font-style: normal; }
.story__since { margin-top: 36px; font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.story__since span { font: 500 40px/1 var(--serif); color: var(--red); letter-spacing: 0; margin-inline-end: 6px; }

/* Visit page */
.visit-page { display: grid; grid-template-columns: 1fr 1fr; gap: 64px; padding: 28px 0 48px; align-items: start; }

/* Order form */
.order { display: grid; grid-template-columns: 1.4fr 1fr; gap: 56px; padding: 28px 0; align-items: start; }
.form { margin-top: 24px; }
.form__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px 18px; margin-bottom: 24px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13.5px; }
.field > span, .field legend { font-weight: 500; }
.field em { color: var(--red); font-style: normal; }
.field--full { grid-column: 1 / -1; }
.field input, .field textarea { border: 1px solid var(--line); background: #fff; padding: 11px 12px; border-radius: var(--r); font-size: 15px; width: 100%; }
.field input:focus, .field textarea:focus { border-color: var(--ink); outline: none; }
.field.has-error input, .field.has-error textarea { border-color: var(--red); }
.field__err { color: var(--red); font-size: 12.5px; }
.radios { border: 0; padding: 0; margin: 0; display: flex; flex-direction: row; flex-wrap: wrap; gap: 18px; }
.radios legend { margin-bottom: 8px; padding: 0; }
.radios label { display: flex; gap: 6px; align-items: center; }
.check { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; flex-wrap: wrap; }
.check input { margin-top: 4px; }
.hp { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.order__side { position: sticky; top: 100px; }
.order__item { display: grid; grid-template-columns: 110px 1fr; gap: 16px; padding: 16px; background: var(--paper); border: 1px solid var(--line); }
.order__item img { width: 110px; aspect-ratio: 1; object-fit: cover; }
.order__item .h3 { margin: 0 0 6px; font-size: 22px; }
.order__item .eyebrow { margin-bottom: 4px; }
.order__item .pdp__price { margin: 0 0 4px; }
.order__item--plain { display: block; }
.order__wa { margin-top: 20px; padding: 18px 20px; border: 1px solid var(--line); }
.order__wa .h3 { margin: 0 0 12px; font-size: 20px; }
.order__wa .small { margin: 8px 0 0; }

.thanks { padding: 80px 24px 20px; }
.thanks__icon { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: var(--wa); color: #fff; margin-bottom: 18px; }
.thanks__icon .icon { width: 30px; height: 30px; }
.thanks .lead { margin: 0 auto; }

/* Responsive */
@media (max-width: 1080px) {
  .nav { gap: 18px; }
  .header__wa { display: none; }
}
@media (max-width: 900px) {
  .burger { display: block; }
  .nav { display: none; position: absolute; top: 100%; inset-inline: 0; flex-direction: column; gap: 0; background: var(--bg); border-bottom: 1px solid var(--line); padding: 8px 24px 20px; }
  .nav.is-open { display: flex; }
  .nav a { padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 16px; }
  .nav .nav__wa-mobile { display: inline-flex; margin-top: 14px; border: 0; }
  .hero__grid, .story-band__grid, .visit__grid, .pdp, .story, .visit-page, .order { grid-template-columns: 1fr; gap: 36px; }
  .grid--4 { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .promises__grid, .steps { grid-template-columns: 1fr; gap: 18px; }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .pdp__gallery, .story__figure, .order__side { position: static; }
  .hero { padding-top: 36px; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 16px; }
  .topbar__in > span:first-child { font-size: 11.5px; }
  .grid--4 { grid-template-columns: 1fr 1fr; gap: 14px; }
  .card__title, .coll__row h3 { font-size: 18px; }
  .form__grid { grid-template-columns: 1fr; }
  .footer__grid { grid-template-columns: 1fr; }
  .filters { padding: 14px; }
  .filters label:not(.filters__search):not(.check) { flex: 1 1 45%; }
  .filters select { min-width: 0; width: 100%; }
  .section, .story-band, .visit { padding: 52px 0; }
  .order__item { grid-template-columns: 80px 1fr; }
  .order__item img { width: 80px; }
}

/* Keep English values (sizes, ages, origins) readable inside Dari pages */
[dir="rtl"] .specs dd, [dir="rtl"] .card__meta, [dir="rtl"] .card__price, [dir="rtl"] .pdp__story, [dir="rtl"] .footer p { unicode-bidi: plaintext; }

/* Logo */
.logo { flex-direction: row; align-items: center; gap: 12px; }
.logo__mark { height: 48px; width: auto; }
.logo__text { display: flex; flex-direction: column; }
.footer__brand { display: inline-block; margin-bottom: 14px; }
.footer__logo { height: 110px; width: auto; }
.band-mark { height: 46px; width: auto; margin-bottom: 18px; opacity: .9; }
.story-hero { position: relative; overflow: hidden; }
.story-hero__mark { position: absolute; inset-inline-end: 4%; top: 50%; transform: translateY(-50%); height: 120%; width: auto; opacity: .07; pointer-events: none; }
.story__sign { height: 60px; width: auto; margin-top: 36px; opacity: .85; }
@media (max-width: 560px) {
  .logo__mark { height: 40px; }
  .logo__name { font-size: 22px; }
  .footer__logo { height: 90px; }
}
