/* Backorder Platform storefront page (docs/storefront.md). Same-origin assets only. */
@font-face { font-family: "IRANSans"; font-weight: 400; font-style: normal; font-display: swap; src: url("fonts/IRANSansWeb.woff") format("woff"); }
@font-face { font-family: "IRANSans"; font-weight: 500; font-style: normal; font-display: swap; src: url("fonts/IRANSansWeb_Medium.woff") format("woff"); }
@font-face { font-family: "IRANSans"; font-weight: 700; font-style: normal; font-display: swap; src: url("fonts/IRANSansWeb_Bold.woff") format("woff"); }

:root {
  --ink: #13233f;         /* hero, headings */
  --ink-2: #1e3459;       /* hero surfaces */
  --saffron: #e3a008;     /* the one primary action */
  --saffron-ink: #1d1500;
  --teal: #0e7c86;        /* links, focus */
  --fog: #f2f4f7;         /* page */
  --paper: #ffffff;       /* surfaces */
  --slate: #4a5568;       /* secondary text */
  --line: #dde2ea;
  --ok: #16794a;
  --err: #b42318;
  --radius: 12px;
  --space: 8px;
  --font: "IRANSans", Tahoma, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--fog);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.85;
  letter-spacing: 0;
}
a { color: var(--teal); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; border-radius: 6px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ltr { direction: ltr; unicode-bidi: isolate; }
.wrap { max-width: 1120px; margin-inline: auto; padding-inline: 20px; }
.icon { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---- hero: the name as an address bar -------------------------------------------------------- */
.hero { background: var(--ink); color: #fff; padding-block: 40px 72px; }
.hero .lead { margin: 0 0 16px; color: #c9d3e3; font-size: 16px; }
.address {
  display: flex; align-items: center; gap: 14px;
  direction: ltr;
  background: var(--paper); color: var(--ink);
  border-radius: 999px;
  padding: 14px 28px;
  box-shadow: 0 0 0 6px rgba(255, 255, 255, 0.08);
  width: fit-content;
  max-width: 100%;
}
.address .icon { width: 26px; height: 26px; color: var(--ok); stroke-width: 2; }
.address h1 {
  margin: 0;
  font-size: clamp(30px, 6.4vw, 72px);
  line-height: 1.15;
  font-weight: 700;
  overflow-wrap: anywhere;
}
.hero .say { margin: 18px 0 0; font-size: 18px; color: #c9d3e3; }
.hero .say strong { color: #fff; font-weight: 700; font-size: 22px; }
.hero .meaning { margin: 6px 0 0; color: #c9d3e3; max-width: 64ch; line-height: 1.9; }
.hero .headline { margin: 20px 0 8px; font-size: clamp(20px, 2.6vw, 28px); line-height: 1.45; font-weight: 700; max-width: 34ch; }
.hero .category { margin: 0; color: #c9d3e3; font-size: 15px; }
.hero .category a { color: #fff; }

/* ---- layout ---------------------------------------------------------------------------------- */
.layout { display: grid; gap: 24px; margin-top: -40px; padding-bottom: 96px; }
@media (min-width: 960px) {
  .layout { grid-template-columns: minmax(0, 1fr) 380px; align-items: start; gap: 32px; }
  .aside { position: sticky; top: 24px; grid-column: 2; grid-row: 1 / span 2; }
  .main { grid-column: 1; grid-row: 1; }
}
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.main { display: grid; gap: 24px; }
.main section h2 { font-size: 22px; line-height: 1.4; margin: 0 0 12px; }
.main section p { margin: 0 0 12px; color: var(--ink); }
.muted { color: var(--slate); }

/* ---- offer card --------------------------------------------------------------------------------- */
.offer { box-shadow: 0 12px 32px rgba(19, 35, 63, 0.12); border-color: transparent; }
.offer .price-label { margin: 0; color: var(--slate); font-size: 15px; }
.offer .price { margin: 0 0 4px; font-size: 30px; line-height: 1.3; font-weight: 700; font-variant-numeric: tabular-nums; }
.offer .price-note { margin: 0 0 20px; color: var(--slate); font-size: 14px; }
.kind { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 0 16px; padding: 0; border: 0; }
.kind label {
  display: flex; align-items: center; justify-content: center; min-height: 44px;
  border: 1px solid var(--line); border-radius: 10px; cursor: pointer; font-weight: 600; font-size: 15px;
}
.kind input { position: absolute; opacity: 0; pointer-events: none; }
.kind input:checked + span { color: var(--ink); }
.kind label:has(input:checked) { border-color: var(--ink); background: var(--fog); }
.kind label:has(input:focus-visible) { outline: 3px solid var(--teal); outline-offset: 2px; }
.field { margin-bottom: 14px; }
.field label { display: block; margin-bottom: 6px; font-size: 15px; font-weight: 600; }
.field input, .field textarea {
  width: 100%; min-height: 48px; padding: 10px 14px;
  border: 1px solid #c3cbd8; border-radius: 10px; background: var(--paper);
  font: inherit; font-size: 16px; color: var(--ink);
}
.field textarea { min-height: 88px; resize: vertical; }
.field input[dir="ltr"] { text-align: right; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(14, 124, 134, 0.2); }
.field [aria-invalid="true"] { border-color: var(--err); }
.field .hint { margin: 6px 0 0; font-size: 14px; color: var(--slate); }
.field .error { margin: 6px 0 0; font-size: 14px; color: var(--err); font-weight: 600; }
.hp { position: absolute; inset-inline-start: -9999px; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 0 22px; border-radius: 10px; border: 1px solid transparent;
  font: inherit; font-size: 16px; font-weight: 700; text-decoration: none; cursor: pointer;
  transition: background-color 150ms ease, border-color 150ms ease;
}
.btn-primary { background: var(--saffron); color: var(--saffron-ink); width: 100%; }
.btn-primary:hover { background: #c98d05; color: var(--saffron-ink); }
.btn-line { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-line:hover { border-color: var(--ink); color: var(--ink); }
.trust { display: flex; gap: 8px; margin: 14px 0 0; font-size: 14px; color: var(--slate); }
.trust .icon { color: var(--ok); width: 18px; height: 18px; margin-top: 3px; }
.notice { border-radius: 10px; padding: 16px; background: #e8f5ee; color: #0f5132; font-weight: 600; margin: 0; }
.notice.err { background: #fdecea; color: var(--err); margin-bottom: 16px; }

/* ---- uses ------------------------------------------------------------------------------------- */
.uses { list-style: none; margin: 16px 0 0; padding: 0; display: grid; gap: 10px; }
@media (min-width: 640px) { .uses { grid-template-columns: 1fr 1fr; } }
.uses li { display: flex; gap: 10px; align-items: flex-start; }
.uses .icon { color: var(--teal); margin-top: 4px; }
.not-for { margin-top: 20px; padding: 14px 16px; border-inline-start: 4px solid var(--line); background: var(--fog); border-radius: 8px; color: var(--slate); }
.not-for strong { color: var(--ink); }

/* ---- facts ------------------------------------------------------------------------------------- */
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 16px; margin: 0; }
.facts div { border-top: 1px solid var(--line); padding-top: 10px; }
.facts dt { color: var(--slate); font-size: 14px; }
.facts dd { margin: 2px 0 0; font-weight: 700; font-size: 17px; }

/* ---- steps ------------------------------------------------------------------------------------- */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 18px; }
.steps li { counter-increment: step; display: grid; grid-template-columns: 40px 1fr; gap: 14px; }
.steps li::before {
  content: counter(step, persian);
  display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%;
  background: var(--ink); color: #fff; font-weight: 700;
}
.steps strong { display: block; }

/* ---- faq --------------------------------------------------------------------------------------- */
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; padding: 14px 0; font-weight: 700; display: flex; justify-content: space-between; gap: 12px; min-height: 44px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary .icon { transition: transform 200ms ease; }
.faq details[open] summary .icon { transform: rotate(180deg); }
.faq details p { margin: 0 0 16px; color: var(--slate); }

/* ---- contacts ---------------------------------------------------------------------------------- */
.contacts { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
@media (min-width: 640px) { .contacts { grid-template-columns: 1fr 1fr; } }
.contacts a {
  display: flex; align-items: center; gap: 12px; min-height: 52px; padding: 8px 14px;
  border: 1px solid var(--line); border-radius: 10px; color: var(--ink); text-decoration: none;
}
.contacts a:hover { border-color: var(--teal); }
.contacts .icon { color: var(--teal); }
.contacts small { display: block; color: var(--slate); font-size: 13px; line-height: 1.4; }
.contacts span.value { font-weight: 700; }
.hours { margin: 12px 0 0; color: var(--slate); display: flex; gap: 8px; align-items: center; }

/* ---- related ----------------------------------------------------------------------------------- */
.related { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.related li a { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: none; color: var(--ink); min-height: 44px; }
.related li a:hover .name { color: var(--teal); }
.related .name { font-weight: 700; }
.related .tag { color: var(--slate); font-size: 15px; }

/* ---- all-domains page ------------------------------------------------------------------------ */
.hero-sm { padding-block: 32px 64px; }
.list-title { margin: 0; font-size: clamp(26px, 4vw, 40px); line-height: 1.3; font-weight: 700; }
.hero-link { color: #fff; }
.list-page { margin-top: -40px; padding-bottom: 48px; display: grid; gap: 20px; }
.list-page > *, .filters { min-width: 0; }
.filters label { display: block; font-weight: 700; margin-bottom: 8px; }
.search { position: relative; }
.search .icon { position: absolute; inset-inline-start: 14px; top: 50%; transform: translateY(-50%); color: var(--slate); }
.search input {
  width: 100%; min-height: 52px; padding-block: 10px; padding-inline: 46px 14px;
  border: 1px solid #c3cbd8; border-radius: 10px; font: inherit; font-size: 16px; color: var(--ink); background: var(--paper);
}
.search input:focus { outline: none; border-color: var(--teal); box-shadow: 0 0 0 3px rgba(14, 124, 134, 0.2); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
@media (max-width: 640px) {
  /* one swipeable row on phones so the results stay near the top */
  .chips { flex-wrap: nowrap; overflow-x: auto; padding: 2px 0 6px; scrollbar-width: none; }
  .chips::-webkit-scrollbar { display: none; }
  .chip { flex: none; }
}
.chip {
  display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 999px; color: var(--ink); text-decoration: none; font-size: 15px; background: var(--paper);
}
.chip span { color: var(--slate); font-size: 13px; }
.chip:hover { border-color: var(--ink); color: var(--ink); }
.chip.is-on { background: var(--ink); border-color: var(--ink); color: #fff; }
.chip.is-on span { color: #c9d3e3; }
.cards { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.cards a {
  display: grid; gap: 4px; height: 100%; padding: 18px 20px; background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); color: var(--ink); text-decoration: none;
}
.cards a:hover { border-color: var(--teal); }
.cards .name { font-size: 20px; font-weight: 700; line-height: 1.4; text-align: end; }
.cards .say { color: var(--slate); font-size: 15px; }
.cards .cat { color: var(--teal); font-size: 14px; font-weight: 500; }
.cards .brand-flag { justify-self: start; font-size: 13px; color: #8a5a00; background: #fff4d6; border-radius: 999px; padding: 0 10px; }
.cards .bundle-flag { justify-self: start; font-size: 13px; color: var(--ink); background: #e3eef0; border-radius: 999px; padding: 0 10px; }
.hero .bundle-line { margin: 10px 0 0; padding: 10px 14px; background: rgba(255, 255, 255, 0.08); border-radius: 10px; color: #fff; max-width: 64ch; }
.hero .bundle-line a { color: var(--saffron); }
.brand-note { margin: 0 0 14px; padding: 12px 14px; border-radius: 10px; background: #fff4d6; color: #5c3d00; }
.cards .line { color: var(--slate); font-size: 15px; line-height: 1.7; }
.cards .tag { margin-top: 6px; font-weight: 700; }
.empty { margin: 0; padding: 24px; text-align: center; color: var(--slate); background: var(--paper); border-radius: var(--radius); }
.result-count { margin: 0; color: var(--slate); font-size: 14px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.section-head a { font-weight: 500; white-space: nowrap; }
.all-link { margin: 16px 0 0; }
.all-link .btn { width: 100%; }

/* ---- hub list ---------------------------------------------------------------------------------- */
.hub h2 { margin: 28px 0 8px; font-size: 20px; }
.hub h2:first-child { margin-top: 0; }

/* ---- footer and mobile action bar -------------------------------------------------------------- */
/* contact channels in a bar at the top of every page */
.contact-bar { background: #0c1830; color: #c9d3e3; font-size: 14px; }
.contact-bar .wrap { display: flex; align-items: center; gap: 8px 16px; min-height: 48px; flex-wrap: wrap; padding-block: 6px; }
.contact-bar .cb-label { color: #9fb0c8; }
.contact-bar ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; }
.contact-bar a { display: inline-flex; align-items: center; gap: 6px; min-height: 36px; color: #fff; text-decoration: none; font-weight: 500; }
.contact-bar a:hover { color: var(--saffron); }
.contact-bar .icon { width: 18px; height: 18px; color: var(--saffron); }
.contact-bar .cb-hours { display: inline-flex; align-items: center; gap: 6px; margin-inline-start: auto; color: #9fb0c8; }
.contact-bar .cb-hours .icon { width: 16px; height: 16px; color: #9fb0c8; }
@media (max-width: 640px) { .contact-bar .cb-label, .contact-bar .cb-hours { display: none; } }
.foot-space { height: 96px; }
@media (min-width: 960px) { .foot-space { height: 32px; } }
.hero .meaning.alt { color: #f3d58a; }
.bar {
  position: fixed; inset-inline: 0; bottom: 0; z-index: 10;
  display: flex; align-items: center; gap: 12px; padding: 12px 20px calc(12px + env(safe-area-inset-bottom));
  background: var(--paper); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(19, 35, 63, 0.08);
  transition: transform 200ms ease;
}
.bar .bar-price { flex: 1; min-width: 0; font-weight: 700; line-height: 1.3; }
.bar .bar-price small { display: block; font-weight: 500; color: var(--slate); font-size: 13px; }
.bar .btn-primary { width: auto; }
.bar.is-hidden { transform: translateY(110%); }
@media (min-width: 960px) { .bar { display: none; } }

@media (max-width: 480px) {
  .wrap { padding-inline: 16px; }
  .panel { padding: 20px; }
  .address { padding: 12px 18px; gap: 10px; }
  .address .icon { width: 20px; height: 20px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
