@font-face {
  font-family: "IRANYekanX";
  src: url("fonts/iranyekanx-400.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "IRANYekanX";
  src: url("fonts/iranyekanx-700.woff2") format("woff2");
  font-weight: 700;
  font-display: swap;
}
@font-face {
  font-family: "IRANYekanX";
  src: url("fonts/iranyekanx-900.woff2") format("woff2");
  font-weight: 900;
  font-display: swap;
}

:root {
  --gold: #d4af37;
  --gold-light: #ebd58a;
  --brown: #7c4025;   /* هم‌رنگِ پس‌زمینهٔ لوگو/اپ */
  --brown-d: #5e2f1b;
  --dark: #1c1b17;
  --dark2: #26241d;
  --cream: #f7f4ec;
  --text: #2a2720;
  --muted: #8a857a;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: "IRANYekanX", Tahoma, sans-serif;
  direction: rtl;
  background: var(--cream);
  color: var(--text);
  line-height: 1.9;
}

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

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* Header */
header {
  background: var(--brown);
  color: var(--gold-light);
  position: sticky;
  top: 0;
  z-index: 50;
  box-shadow: 0 2px 12px rgba(0,0,0,.2);
}
.logo { display: flex; align-items: center; gap: 9px; }
.logo img { width: 34px; height: 34px; border-radius: 8px; }
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}
.logo { font-weight: 900; font-size: 24px; color: var(--gold); letter-spacing: .5px; }
.logo span { color: #fff; }
.nav-links { display: flex; gap: 26px; font-size: 15px; }
.nav-links a:hover { color: var(--gold); }

/* Hero */
.hero {
  background: linear-gradient(160deg, var(--dark) 0%, var(--dark2) 100%);
  color: #fff;
  padding: 70px 0 90px;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  left: -120px; top: -120px;
  width: 360px; height: 360px;
  background: radial-gradient(circle, rgba(212,175,55,.25), transparent 70%);
  border-radius: 50%;
}
.hero-grid { display: flex; align-items: center; gap: 50px; flex-wrap: wrap; }
.hero-text { flex: 1; min-width: 300px; }
.badge {
  display: inline-block;
  background: rgba(212,175,55,.15);
  color: var(--gold-light);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  margin-bottom: 18px;
}
.hero h1 { font-size: 42px; font-weight: 900; line-height: 1.4; margin-bottom: 16px; }
.hero h1 b { color: var(--gold); }
.hero p { font-size: 18px; color: #cfcabb; margin-bottom: 30px; }
.btns { display: flex; gap: 14px; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 14px 26px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 16px;
  transition: transform .15s, box-shadow .15s;
}
.btn:hover { transform: translateY(-2px); }
.btn-gold { background: var(--gold); color: var(--dark); box-shadow: 0 6px 18px rgba(212,175,55,.35); }
.btn-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255,255,255,.3); }

/* Phone mockup */
.phone {
  width: 250px; height: 510px;
  background: #000;
  border-radius: 36px;
  padding: 12px;
  box-shadow: 0 24px 60px rgba(0,0,0,.4);
  flex-shrink: 0;
  margin: 0 auto;
}
.phone-screen {
  width: 100%; height: 100%;
  background: var(--cream);
  border-radius: 26px;
  overflow: hidden;
  display: flex; flex-direction: column;
}
.ps-top { background: var(--dark); color: var(--gold-light); padding: 18px 14px; }
.ps-top .big { font-size: 22px; font-weight: 900; color: #fff; }
.ps-top .lbl { font-size: 12px; }
.ps-row { display: flex; justify-content: space-between; padding: 12px 14px; border-bottom: 1px solid #eee; font-size: 14px; }
.ps-row .v { font-weight: 700; }
.up { color: #2e7d52; } .down { color: #d33; }

/* Sections */
section { padding: 70px 0; }
.section-title { text-align: center; font-size: 30px; font-weight: 900; margin-bottom: 14px; }
.section-sub { text-align: center; color: #777; margin-bottom: 46px; font-size: 16px; }

.features { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 20px; }
.card {
  background: #fff;
  border: 1px solid rgba(0,0,0,.06);
  border-radius: 18px;
  padding: 26px;
  transition: transform .15s, box-shadow .15s;
}
.card:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0,0,0,.08); }
.card .ico { font-size: 30px; margin-bottom: 12px; }
.card h3 { font-size: 18px; margin-bottom: 8px; }
.card p { font-size: 14px; color: #666; }

/* Highlight */
.highlight { background: var(--dark); color: #fff; }
.highlight .section-title { color: var(--gold); }
.hl-box {
  background: rgba(212,175,55,.1);
  border: 1px solid rgba(212,175,55,.3);
  border-radius: 18px;
  padding: 30px;
  text-align: center;
  font-size: 18px;
  max-width: 720px;
  margin: 0 auto;
}
.hl-box b { color: var(--gold-light); font-size: 22px; }

/* Privacy strip */
.privacy-strip { background: #eaf4ee; }
.privacy-strip .container { display: flex; gap: 30px; align-items: center; flex-wrap: wrap; }
.privacy-strip .ico { font-size: 60px; }
.privacy-strip h2 { font-size: 26px; margin-bottom: 10px; }
.privacy-strip p { color: #444; }

/* Download */
.download { text-align: center; }
.download .btns { justify-content: center; }

/* Footer */
footer { background: var(--dark); color: #aaa; padding: 36px 0; text-align: center; font-size: 14px; }
footer a { color: var(--gold-light); }
footer .links { margin-bottom: 12px; display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }
.footer-brand { display: inline-flex; align-items: center; gap: 12px; margin: 0 auto 20px; padding: 12px 22px;
  background: rgba(255,255,255,.05); border: 1px solid rgba(212,175,55,.35); border-radius: 14px; }
.footer-brand img { width: 44px; height: 44px; border-radius: 10px; }
.footer-brand .fb-text { display: flex; flex-direction: column; align-items: flex-start; line-height: 1.5; }
.footer-brand .fb-name { color: var(--gold-light); font-weight: 800; font-size: 18px; }
.footer-brand .fb-text a { font-size: 13px; direction: ltr; }

@media (max-width: 640px) {
  .hero h1 { font-size: 32px; }
  .nav-links { display: none; }
}

/* ── Web app ── */
.webapp { padding: 26px 20px 60px; min-height: 70vh; }
.tabs { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.tab {
  border: none; background: #fff; color: #444;
  padding: 10px 20px; border-radius: 12px; font-family: inherit;
  font-size: 15px; font-weight: 700; cursor: pointer;
  border: 1px solid rgba(0,0,0,.07);
}
.tab.active { background: var(--gold); color: var(--dark); }
.updated-line { text-align: center; color: #999; font-size: 13px; margin-bottom: 18px; }
.tabpanel { display: none; }
.tabpanel.active { display: block; }
.muted { color: #888; font-size: 14px; margin-bottom: 16px; }

.cat-title { font-size: 18px; font-weight: 800; margin: 22px 6px 10px; }
.price-card { background: #fff; border: 1px solid rgba(0,0,0,.06); border-radius: 16px; overflow: hidden; }
.price-row { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid #f0f0f0; }
.price-row:last-child { border-bottom: none; }
.price-row .pn { font-weight: 600; }
.price-row .pv { font-weight: 800; }
.price-row .pv small { font-weight: 600; font-size: 12px; margin-right: 6px; }
.up { color: #2e7d52; } .down { color: #d33; }

.calc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 18px; }
.calc h3 { margin-bottom: 14px; font-size: 17px; }
.calc label { display: block; font-size: 13px; color: #555; margin-bottom: 12px; }
.calc input, .calc select {
  width: 100%; margin-top: 5px; padding: 11px 12px;
  border: 1px solid #ddd; border-radius: 10px; font-family: inherit; font-size: 15px;
}
.calc .row2 { display: flex; gap: 12px; }
.calc .row2 label { flex: 1; }
.calc button, .webapp button {
  background: var(--gold); color: var(--dark); border: none;
  padding: 12px 22px; border-radius: 10px; font-family: inherit;
  font-weight: 700; font-size: 15px; cursor: pointer; width: 100%;
}
.calc button:hover { filter: brightness(.96); }
.res { margin-top: 16px; background: rgba(212,175,55,.1); border-radius: 10px; padding: 14px; font-size: 15px; line-height: 2; }
.res:empty { display: none; }
.res hr { border: none; border-top: 1px solid rgba(0,0,0,.1); margin: 8px 0; }

.stats-body { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px,1fr)); gap: 18px; }
.stats-body .card h3 { margin-bottom: 10px; border-bottom: 1px solid #eee; padding-bottom: 8px; }
.srow { display: flex; justify-content: space-between; padding: 7px 0; font-size: 14px; }

#tab-lookup .card { max-width: 560px; }

/* Article (privacy page) */
.article { background: #fff; max-width: 820px; margin: 40px auto; padding: 40px; border-radius: 18px; box-shadow: 0 8px 30px rgba(0,0,0,.06); }
.article h1 { font-size: 30px; margin-bottom: 8px; }
.article h2 { font-size: 21px; margin: 28px 0 10px; color: var(--dark); }
.article p, .article li { color: #444; }
.article ul { padding-right: 22px; margin: 8px 0; }
.article .updated { color: #999; font-size: 14px; margin-bottom: 20px; }

/* ── سایتِ چندصفحه‌ایِ PHP ── */
.nav-links a.on { color: var(--gold); font-weight: 800; }
.nav-links a.dl { background: var(--gold); color: var(--brown-d); padding: 7px 15px; border-radius: 10px; font-weight: 800; }
.nav-links a.dl:hover { filter: brightness(1.05); color: var(--brown-d); }

main.page { padding: 24px 20px 64px; min-height: 72vh; }

.hero-mini { background: linear-gradient(150deg, var(--brown), var(--brown-d)); color: #fff; border-radius: 18px; padding: 26px 26px; margin-bottom: 22px; }
.hero-mini h1 { font-size: 25px; font-weight: 900; margin-bottom: 8px; }
.hero-mini p { color: #f1e6da; font-size: 15px; margin-bottom: 16px; line-height: 1.9; }

.page-h1 { font-size: 24px; font-weight: 900; margin: 2px 0 6px; }
.sub-h { font-size: 17px; font-weight: 800; margin: 24px 4px 10px; }
.small { font-size: 12px; }
.muted { color: #8a857a; }
.updated-line { text-align: center; color: #999; font-size: 13px; margin: 4px 0 18px; }

a.price-row { color: inherit; cursor: pointer; }
a.price-row:hover { background: #faf7ef; }
.price-row .pv { display: flex; align-items: center; gap: 8px; }
.price-row .pv .chev { color: #cbb9a6; font-weight: 700; }
.chg { font-size: 12px; font-weight: 700; }
.up { color: #2e7d52; } .down { color: #d33; }

.bubble-box { background: rgba(46,125,82,.1); border: 1px solid rgba(46,125,82,.25); border-radius: 14px; padding: 16px; margin-top: 20px; text-align: center; font-size: 15px; }

.bubble-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px,1fr)); gap: 14px; }
.bubble-card { padding: 16px; }
.bc-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 8px; gap: 8px; }
.bc-name { font-weight: 800; font-size: 15px; }
.bc-badge { padding: 5px 12px; border-radius: 20px; font-size: 13px; font-weight: 800; white-space: nowrap; }
.bc-badge.up { color: #2e7d52; background: rgba(46,125,82,.12); }
.bc-badge.down { color: #d33; background: rgba(221,51,51,.12); }
.bc-rows { border-top: 1px solid #eee; padding-top: 8px; }

.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 16px; }
.stats-grid .card h3 { margin-bottom: 10px; border-bottom: 1px solid #eee; padding-bottom: 8px; font-size: 16px; }
.srow { display: flex; justify-content: space-between; padding: 7px 0; font-size: 14px; }

.lookup-form { padding: 22px; max-width: 560px; }
.lookup-form label { display: block; font-size: 13px; color: #555; margin-bottom: 14px; }
.lookup-form select, .lookup-form input { width: 100%; margin-top: 5px; padding: 11px 12px; border: 1px solid #ddd; border-radius: 10px; font-family: inherit; font-size: 15px; background: #fff; }
.row3 { display: flex; gap: 10px; } .row3 label { flex: 1; }
.lookup-form button, .calc button { background: var(--gold); color: var(--brown-d); border: none; padding: 12px 22px; border-radius: 10px; font-family: inherit; font-weight: 800; font-size: 15px; cursor: pointer; width: 100%; }
.lookup-form button:hover, .calc button:hover { filter: brightness(.97); }

.res-box { background: rgba(212,175,55,.12); border: 1px solid rgba(212,175,55,.3); border-radius: 14px; padding: 22px; margin-top: 18px; text-align: center; font-size: 15px; }
.res-box .big { font-size: 25px; font-weight: 900; color: var(--brown-d); margin: 6px 0; }

/* نتیجه‌ی لوکاپِ تاریخی — مبلغ کنارِ تاریخ، چسبیده به فرم */
.res-inline { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 18px; padding: 16px 18px; background: rgba(212,175,55,.14); border: 1px solid rgba(212,175,55,.35); border-radius: 12px; font-size: 15px; }
.res-inline .amount { font-size: 22px; font-weight: 900; color: var(--brown-d); white-space: nowrap; }

.cur-box { display: flex; align-items: center; gap: 12px; margin: 4px 0 14px; }
.cur-box .big { font-size: 28px; font-weight: 900; }
.spark { width: 100%; height: 130px; display: block; background: #fff; border: 1px solid rgba(0,0,0,.06); border-radius: 14px; }
.spark-cap { display: flex; justify-content: space-between; font-size: 11px; color: #999; margin: 5px 8px 0; }
/* محورِ تاریخِ شمسی زیرِ نمودار (چپ=قدیمی، راست=جدید مثلِ خودِ نمودار) */
.spark-axis { display: flex; direction: ltr; justify-content: space-between; margin: 6px 10px 0; font-size: 10px; color: #999; }
.spark-axis span { flex: 1; text-align: center; }
.back-link { display: inline-block; color: var(--brown); font-weight: 700; margin-bottom: 4px; }
.btn-ghost-dark { display: inline-block; margin-top: 20px; padding: 13px 24px; border: 1.5px solid var(--brown); color: var(--brown); border-radius: 12px; font-weight: 700; }
.btn-ghost-dark:hover { background: var(--brown); color: #fff; }

.aico { vertical-align: middle; object-fit: contain; border-radius: 4px; }
.aemoji { display: inline-block; }
.usdt-badge { display: inline-flex; align-items: center; justify-content: center; background: #26A17B; color: #fff; border-radius: 50%; font-weight: 800; vertical-align: middle; line-height: 1; }

/* بنرِ تبلیغ (کاسپین) — تا پر نشود مخفی است */
.ad-banner { display: none; margin: 16px 0; }
.ad-banner a { display: block; width: 100%; }
.ad-banner .ad-text { display: block; text-align: center; padding: 14px 20px; background: var(--brown); color: #fff; border-radius: 12px; font-weight: 700; }

/* تصویرِ سکهٔ پارسیان با مقادیرِ روی آن */
.pars-img { position: relative; max-width: 520px; margin: 10px auto 8px; }
.pars-img img { width: 100%; display: block; border-radius: 10px; box-shadow: 0 6px 20px rgba(0,0,0,.08); }
.pars-cell { position: absolute; left: 4.5%; width: 25%; text-align: center; transform: translateY(-50%); font-weight: 800; color: #4a3a00; font-size: clamp(12px, 3.1vw, 17px); white-space: nowrap; }
.pars-cell.pc-price { font-size: clamp(10px, 2.5vw, 14px); }

@media (max-width: 720px) {
  .nav { height: auto; flex-direction: column; gap: 10px; padding: 12px 16px; }
  .nav-links { display: flex !important; flex-wrap: wrap; gap: 10px 16px; font-size: 14px; justify-content: center; }
  .hero-mini h1 { font-size: 21px; }
}

/* ── گالریِ تصاویر ── */
.ver-note { display:inline-block; margin-right:12px; font-size:13px; color:var(--muted); }
.gallery-grid {
  display:grid; grid-template-columns:repeat(auto-fill,minmax(150px,1fr));
  gap:14px; margin:14px 0 26px;
}
.gthumb {
  display:flex; flex-direction:column; background:var(--card,#fff);
  border:1px solid rgba(0,0,0,.08); border-radius:12px; overflow:hidden;
  text-decoration:none; transition:transform .15s, box-shadow .15s;
}
.gthumb:hover { transform:translateY(-3px); box-shadow:0 8px 22px rgba(0,0,0,.14); }
.gthumb img { width:100%; height:300px; object-fit:cover; object-position:top; display:block; background:#0e0e0e; }
.gcap { padding:8px 10px; font-size:12.5px; color:var(--muted); text-align:center; line-height:1.5; }
.dl-cta { text-align:center; margin:30px 0 10px; }

/* لایت‌باکس */
.lightbox {
  position:fixed; inset:0; z-index:9999; background:rgba(0,0,0,.9);
  display:flex; flex-direction:column; align-items:center; justify-content:center; padding:24px;
}
.lightbox[hidden] { display:none; }
.lightbox img { max-width:92vw; max-height:82vh; border-radius:10px; box-shadow:0 10px 40px rgba(0,0,0,.6); }
.lb-cap { color:#eee; margin-top:14px; font-size:14px; text-align:center; }
.lb-close { position:absolute; top:16px; left:22px; color:#fff; font-size:40px; line-height:1; cursor:pointer; font-weight:300; }
@media (max-width:600px){
  .gallery-grid { grid-template-columns:repeat(auto-fill,minmax(130px,1fr)); gap:10px; }
  .gthumb img { height:240px; }
}
.cat-desc { margin:2px 2px 12px; font-size:13.5px; line-height:1.9; color:var(--muted); }
