/*
  Detail pages: the "about this product" section, tutorial articles, and a founder's page.
  The look: gold-on-black like the 3D hive, soft glass cards, hexagon ornaments, and a gentle reveal.
*/

/* ---------------------------------------------------------------- ornaments */
.detail-orn { display: inline-grid; place-items: center; width: 44px; height: 50px; color: var(--gold); filter: drop-shadow(0 0 12px rgba(212, 166, 52, 0.6)); }
.detail-orn svg { width: 100%; height: 100%; fill: rgba(212, 166, 52, 0.1); stroke: currentColor; stroke-width: 2.4; stroke-linejoin: round; }
.detail-orn svg path + path { fill: none; stroke-width: 1.6; opacity: 0.6; }
.detail-orn.is-small { width: 22px; height: 25px; filter: none; vertical-align: middle; }

/* ---------------------------------------------------------------- product: about section */
.detail { margin-top: clamp(48px, 7vw, 90px); scroll-margin-top: calc(var(--header-h) + 20px); }
.detail-head { display: grid; justify-items: center; gap: 8px; margin-bottom: clamp(26px, 4vw, 44px); text-align: center; }
.detail-head h2 { margin: 0; font-size: clamp(1.5rem, 1.1rem + 1.6vw, 2.3rem); }
.detail-head p { margin: 0; color: var(--muted); }
.detail-head::after {
  content: "";
  width: 120px;
  height: 3px;
  margin-top: 10px;
  border-radius: 3px;
  background: linear-gradient(90deg, transparent, #f3d27a, #d4a634, transparent);
}
.detail-grid { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(20px, 3vw, 40px); align-items: start; }
.detail-body {
  padding: clamp(20px, 3.2vw, 40px);
  border: 1px solid rgba(212, 166, 52, 0.28);
  border-radius: 28px;
  background:
    radial-gradient(90% 40% at 100% 0%, rgba(212, 166, 52, 0.12), transparent 70%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01));
}
.detail-side { position: sticky; top: calc(var(--header-h) + 20px); }
.detail-card {
  display: grid;
  gap: 14px;
  padding: 24px 22px;
  border: 1px solid rgba(212, 166, 52, 0.55);
  border-radius: 24px;
  background: linear-gradient(160deg, rgba(212, 166, 52, 0.2), rgba(212, 166, 52, 0.04) 55%, rgba(0, 0, 0, 0.3));
  box-shadow: 0 24px 60px -28px rgba(212, 166, 52, 0.6);
}
.detail-card-title { font-size: 1.15rem; }
.detail-price { margin: 0; color: var(--gold-hi); font-size: 1.6rem; font-weight: 900; }
.detail-price span { color: var(--muted); font-size: 0.9rem; font-weight: 500; }
.detail-points { display: grid; gap: 9px; margin: 0; padding: 0; list-style: none; color: var(--muted); font-size: 0.92rem; line-height: 1.7; }
.detail-points li { position: relative; padding-inline-start: 26px; }
.detail-points li::before {
  content: "";
  position: absolute;
  inset-inline-start: 4px;
  top: 0.45em;
  width: 6px;
  height: 11px;
  border-right: 2px solid var(--gold-hi);
  border-bottom: 2px solid var(--gold-hi);
  transform: rotate(45deg);
}
.detail-ask { color: var(--gold-hi); font-size: 0.88rem; text-align: center; }

/* ---------------------------------------------------------------- the article blocks (product details, tutorials) */
.blocks { display: grid; gap: clamp(18px, 2.4vw, 30px); }
.block-text { font-size: 1.04rem; line-height: 2.15; color: #e7dfcb; }
.block-text > :first-child { margin-top: 0; }
.block-text > :last-child { margin-bottom: 0; }
.block-text p { margin: 0 0 1.1em; }
.block-text h2,
.block-text h3,
.block-text h4 { position: relative; margin: 1.6em 0 0.6em; color: #fff; line-height: 1.6; }
.block-text h2 { padding-inline-start: 22px; font-size: clamp(1.35rem, 1.1rem + 1vw, 1.8rem); }
.block-text h2::before {
  content: "";
  position: absolute;
  inset-inline-start: 0;
  top: 0.5em;
  width: 12px;
  height: 14px;
  background: linear-gradient(135deg, #f7dc8d, #d4a634);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  box-shadow: 0 0 14px rgba(212, 166, 52, 0.8);
}
.block-text h2::after { content: ""; display: block; width: 90px; height: 2px; margin-top: 8px; background: linear-gradient(90deg, #d4a634, transparent); }
.block-text h3 { color: var(--gold-hi); font-size: 1.2rem; }
.block-text strong { color: #fff; }
.block-text a { color: var(--gold-hi); text-decoration-color: rgba(243, 210, 122, 0.4); text-underline-offset: 4px; }
.block-text ul,
.block-text ol { display: grid; gap: 10px; margin: 0 0 1.2em; padding: 0; list-style: none; counter-reset: li; }
.block-text li { position: relative; padding-inline-start: 34px; }
.block-text ul li::before {
  content: "";
  position: absolute;
  inset-inline-start: 4px;
  top: 0.78em;
  width: 11px;
  height: 12px;
  background: linear-gradient(135deg, #f7dc8d, #d4a634);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
}
.block-text ol li { counter-increment: li; }
.block-text ol li::before {
  content: counter(li, persian);
  position: absolute;
  inset-inline-start: 0;
  top: 0.35em;
  display: grid;
  place-items: center;
  width: 26px;
  height: 28px;
  background: linear-gradient(135deg, #f7dc8d, #d4a634);
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
  color: #1a1203;
  font-size: 0.78rem;
  font-weight: 800;
}
.block-text blockquote {
  position: relative;
  margin: 1.4em 0;
  padding: 18px 26px;
  border: 1px solid rgba(212, 166, 52, 0.4);
  border-inline-start: 4px solid var(--gold);
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(212, 166, 52, 0.14), rgba(212, 166, 52, 0.03));
  color: #fff3cf;
  font-size: 1.12rem;
}
.block-text hr { height: 1px; margin: 2em 0; border: 0; background: linear-gradient(90deg, transparent, rgba(212, 166, 52, 0.6), transparent); }
.block-image,
.block-video { margin: 0; }
.block-image img,
.block-video video {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid rgba(212, 166, 52, 0.4);
  border-radius: 22px;
  background: #0a0806;
  box-shadow: 0 26px 60px -30px #000, 0 0 40px -18px rgba(212, 166, 52, 0.5);
  transition: transform 0.5s cubic-bezier(0.2, 0.8, 0.2, 1), box-shadow 0.5s ease;
}
.block-image:hover img { transform: translateY(-3px) scale(1.01); box-shadow: 0 34px 70px -30px #000, 0 0 54px -14px rgba(212, 166, 52, 0.7); }
.block-image figcaption,
.block-video figcaption { margin-top: 10px; color: var(--muted); font-size: 0.88rem; text-align: center; }
.block-image figcaption::before,
.block-video figcaption::before { content: "◆ "; color: var(--gold); font-size: 0.7em; }
.block-video .embed-frame { overflow: hidden; border: 1px solid rgba(212, 166, 52, 0.4); border-radius: 22px; box-shadow: 0 26px 60px -30px #000; }

/* ---------------------------------------------------------------- founder page */
.fnd-hero {
  position: relative;
  padding: clamp(56px, 9vw, 110px) 0 clamp(34px, 5vw, 56px);
  text-align: center;
  background:
    radial-gradient(60% 70% at 50% 0%, rgba(212, 166, 52, 0.22), transparent 70%),
    linear-gradient(180deg, rgba(212, 166, 52, 0.05), transparent);
  overflow: hidden;
}
.fnd-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: url("/img/hex-pattern.svg") center / 220px repeat;
  opacity: 0.1;
  mask-image: radial-gradient(60% 80% at 50% 30%, #000, transparent 75%);
  pointer-events: none;
}
.fnd-hero-inner { position: relative; display: grid; justify-items: center; gap: 14px; }
.fnd-hero .crumbs { justify-self: center; }
.fnd-portrait { position: relative; width: clamp(150px, 19vw, 196px); aspect-ratio: 0.866; margin-top: 8px; animation: fnd-in 0.9s cubic-bezier(0.2, 0.9, 0.3, 1.1) both; }
.fnd-ring,
.fnd-photo {
  position: absolute;
  clip-path: polygon(50% 0, 100% 25%, 100% 75%, 50% 100%, 0 75%, 0 25%);
}
.fnd-ring { inset: -5px; background: conic-gradient(from 20deg, #f7dc8d, #d4a634, #8f6a14, #f7dc8d, #d4a634, #f7dc8d); animation: fnd-spin 14s linear infinite; }
.fnd-portrait::after { content: ""; position: absolute; inset: 14% 8%; border-radius: 50%; box-shadow: 0 0 70px 20px rgba(212, 166, 52, 0.35); z-index: -1; }
.fnd-photo { inset: 0; display: grid; place-items: center; background: #14110d; }
.fnd-photo img { width: 100%; height: 100%; object-fit: cover; }
.fnd-photo b { color: var(--gold-hi); font-size: 4rem; }
@keyframes fnd-spin { to { transform: rotate(360deg); } }
@keyframes fnd-in { from { opacity: 0; transform: translateY(18px) scale(0.92); } to { opacity: 1; transform: none; } }
.fnd-name { margin: 6px 0 0; font-size: clamp(1.9rem, 1.3rem + 2.6vw, 3.1rem); background: var(--gold-grad); -webkit-background-clip: text; background-clip: text; color: transparent; animation: fnd-in 0.9s 0.1s both; }
.fnd-role { margin: 0; animation: fnd-in 0.9s 0.2s both; }
.fnd-role span { display: inline-block; padding: 5px 20px; border: 1px solid rgba(212, 166, 52, 0.5); border-radius: 999px; background: rgba(212, 166, 52, 0.1); color: var(--gold-hi); font-weight: 700; }
.fnd-quote {
  position: relative;
  max-width: 640px;
  margin: 10px 0 0;
  padding: 0 34px;
  color: #efe6cf;
  font-size: clamp(1.02rem, 0.95rem + 0.5vw, 1.25rem);
  line-height: 2;
  animation: fnd-in 0.9s 0.3s both;
}
.fnd-quote::before,
.fnd-quote::after { position: absolute; color: rgba(212, 166, 52, 0.55); font-size: 2.6rem; line-height: 1; }
.fnd-quote::before { content: "”"; inset-inline-start: 0; top: -4px; }
.fnd-quote::after { content: "“"; inset-inline-end: 0; bottom: -22px; }
.fnd-body { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: clamp(20px, 3vw, 40px); align-items: start; }
.fnd-card {
  padding: clamp(22px, 3.4vw, 44px);
  border: 1px solid rgba(212, 166, 52, 0.3);
  border-radius: 28px;
  background: radial-gradient(90% 40% at 100% 0%, rgba(212, 166, 52, 0.12), transparent 70%), linear-gradient(180deg, rgba(255, 255, 255, 0.035), rgba(255, 255, 255, 0.01));
}
.fnd-card-title { display: flex; align-items: center; gap: 12px; margin: 0 0 18px; font-size: clamp(1.25rem, 1.05rem + 0.9vw, 1.65rem); }
.fnd-bio { font-size: 1.06rem; line-height: 2.2; color: #e7dfcb; }
.fnd-bio p { margin: 0 0 1.1em; }
.fnd-bio p.cap::first-letter { float: inline-start; margin-inline-end: 10px; color: var(--gold-hi); font-size: 3.2em; font-weight: 900; line-height: 0.95; }
.fnd-card .btn { margin-top: 10px; }
.fnd-side { position: sticky; top: calc(var(--header-h) + 20px); padding: 22px; border: 1px solid var(--line); border-radius: 24px; background: rgba(255, 255, 255, 0.03); }
.fnd-side-title { margin: 0 0 14px; font-size: 1.05rem; color: var(--gold-hi); }
.fnd-side ul { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.fnd-mini { display: flex; align-items: center; gap: 12px; padding: 10px; border: 1px solid transparent; border-radius: 16px; color: inherit; text-decoration: none; transition: border-color 0.25s, background 0.25s, transform 0.25s; }
.fnd-mini:hover { border-color: rgba(212, 166, 52, 0.5); background: rgba(212, 166, 52, 0.08); transform: translateX(-3px); }
.fnd-mini-photo { display: grid; flex: none; place-items: center; width: 56px; height: 56px; overflow: hidden; border: 2px solid rgba(212, 166, 52, 0.6); border-radius: 50%; background: #14110d; color: var(--gold-hi); font-weight: 800; }
.fnd-mini-photo img { width: 100%; height: 100%; object-fit: cover; }
.fnd-mini b,
.fnd-mini small { display: block; }
.fnd-mini small { color: var(--muted); }

@media (max-width: 920px) {
  .detail-grid,
  .fnd-body { grid-template-columns: minmax(0, 1fr); }
  .detail-side,
  .fnd-side { position: static; }
  .detail-side { order: -1; }
}
@media (prefers-reduced-motion: reduce) {
  .fnd-ring,
  .fnd-portrait,
  .fnd-name,
  .fnd-role,
  .fnd-quote { animation: none; }
  .block-image img { transition: none; }
}

html[dir="ltr"] .block-text ol li::before { content: counter(li, decimal); }
