/* ==========================================================
   کدینگو – صفحهٔ تعرفه‌ها (/pricing/)
   بعد از style.css و blog.css بارگذاری می‌شود
   ========================================================== */

/* ---------- سرتیتر ---------- */
.pr-hero {
  position: relative; isolation: isolate; overflow: hidden; color: #fff;
  padding-block: clamp(28px, 4vw, 48px) clamp(120px, 12vw, 160px);
}
.pr-hero::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(45% 70% at 100% 0%, rgba(7, 173, 126, .24), transparent 70%),
    radial-gradient(45% 70% at 0% 100%, rgba(60, 120, 230, .24), transparent 70%),
    linear-gradient(180deg, var(--navy) 0%, #061a3b 100%);
}
.pr-hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 44px 44px;
  -webkit-mask-image: radial-gradient(70% 70% at 50% 30%, #000 0%, transparent 75%);
          mask-image: radial-gradient(70% 70% at 50% 30%, #000 0%, transparent 75%);
}
.pr-hero-in { max-width: 46rem; margin-inline: auto; text-align: center; }
.pr-hero .crumbs ol { justify-content: center; }
.pr-hero h1 { font-size: clamp(1.9rem, 4.2vw, 3rem); font-weight: 800; line-height: 1.55; }
.pr-hero h1 .hl {
  color: var(--green-bright); padding-inline: 4px;
  background: linear-gradient(transparent 66%, rgba(7, 173, 126, .22) 66%, rgba(7, 173, 126, .22) 92%, transparent 92%);
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.pr-hero-in > p { margin-top: 16px; color: #c3cfe4; font-size: 1.05rem; line-height: 2.05; }

.pr-trust { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 28px; }
.pr-trust li {
  display: inline-flex; align-items: center; gap: 8px; padding: 6px 16px 6px 12px; border-radius: 999px;
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12);
  color: #e3eaf6; font-size: .9rem; font-weight: 600; line-height: 1.8;
}
.pr-trust svg { color: var(--green-bright); flex: none; }

/* ---------- کارت‌ها ---------- */
.pr-plans { position: relative; margin-top: clamp(-110px, -9vw, -80px); padding-bottom: clamp(56px, 7vw, 90px); }
.pr-plans-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  margin-bottom: 22px; padding: 14px 18px; border-radius: 20px;
  background: rgba(255, 255, 255, .96); border: 1px solid #e3e9f2;
  box-shadow: 0 20px 44px -28px rgba(7, 31, 69, .45);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
}
.pr-plans-head h2 { font-size: 1.15rem; font-weight: 800; color: var(--navy); }
.pr-chips { margin-bottom: 0; }

.pr-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.pr-card {
  position: relative; display: flex; flex-direction: column; gap: 16px;
  padding: 24px 22px 22px; border-radius: 24px; background: #fff;
  border: 1px solid #e3e9f2;
  box-shadow: 0 1px 2px rgba(7, 31, 69, .04), 0 18px 40px -30px rgba(7, 31, 69, .4);
  transition: transform .35s cubic-bezier(.2, .7, .2, 1), box-shadow .35s ease, border-color .35s ease, opacity .35s ease;
  animation: pr-in .6s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 60ms);
}
@keyframes pr-in { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
.pr-card[hidden] { display: none; }
.pr-card:hover {
  transform: translateY(-6px); border-color: #bfe3d3;
  box-shadow: 0 1px 2px rgba(7, 31, 69, .05), 0 30px 60px -30px rgba(7, 31, 69, .5);
}
.pr-card::before {               /* خط گرادیانی بالا */
  content: ""; position: absolute; inset-inline: 22px; top: 0; height: 3px; border-radius: 0 0 3px 3px;
  background: linear-gradient(90deg, var(--green-bright), #3c78e6);
  transform: scaleX(0); transform-origin: right center; transition: transform .45s ease;
}
.pr-card:hover::before { transform: scaleX(1); }

.pr-card-top { display: flex; align-items: center; gap: 14px; }
.pr-ico {
  flex: none; display: grid; place-items: center; width: 52px; height: 52px; border-radius: 16px;
  color: var(--green-bright); background: linear-gradient(145deg, var(--navy-2), var(--navy));
  box-shadow: 0 12px 22px -12px rgba(7, 31, 69, .7), inset 0 1px 0 rgba(255, 255, 255, .12);
  transition: transform .35s cubic-bezier(.3, 1.4, .5, 1);
}
.pr-card:hover .pr-ico { transform: rotate(-6deg) scale(1.06); }
.pr-card h3 { font-size: 1.06rem; font-weight: 800; color: var(--navy); line-height: 1.7; }

.pr-price { display: flex; align-items: baseline; gap: 8px; flex-wrap: wrap; }
.pr-price strong {
  font-size: 2.1rem; font-weight: 800; line-height: 1.2; letter-spacing: -.01em;
  background: linear-gradient(135deg, var(--navy), var(--green));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.pr-price span { color: var(--muted); font-size: .88rem; font-weight: 600; }

/* نوار بازهٔ قیمت روی مقیاس ۰ تا ۸۰ میلیون */
.pr-range { position: relative; height: 8px; border-radius: 999px; background: var(--paper); border: 1px solid #e6ecf4; overflow: hidden; }
.pr-range i {
  position: absolute; top: 0; bottom: 0; inset-inline-start: var(--l); width: var(--w); border-radius: inherit;
  background: linear-gradient(90deg, #3c78e6, var(--green-bright));
  box-shadow: 0 0 10px rgba(7, 173, 126, .5);
  transform-origin: right center; animation: pr-bar 1s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * 60ms + 250ms);
}
.pr-range i.is-open { -webkit-mask-image: linear-gradient(90deg, transparent 0, #000 40%); mask-image: linear-gradient(90deg, transparent 0, #000 40%); }
@keyframes pr-bar { from { transform: scaleX(0); } to { transform: scaleX(1); } }

.pr-for { display: grid; gap: 8px; flex: 1; }
.pr-for li { display: flex; align-items: center; gap: 9px; color: #34445f; font-size: .93rem; line-height: 1.8; }
.pr-for svg { flex: none; width: 22px; height: 22px; padding: 4px; border-radius: 50%; background: var(--mint); color: var(--green); }

.pr-cta { margin-top: 4px; }

/* کارت پرطرفدار */
.pr-card.is-popular {
  color: #fff; border-color: transparent;
  background:
    radial-gradient(70% 60% at 100% 0%, rgba(7, 173, 126, .4), transparent 70%),
    radial-gradient(60% 60% at 0% 100%, rgba(60, 120, 230, .34), transparent 70%),
    linear-gradient(160deg, var(--navy-2), var(--navy));
  box-shadow: 0 30px 60px -28px rgba(7, 31, 69, .8), 0 0 0 1px rgba(7, 173, 126, .4);
}
.pr-card.is-popular h3 { color: #fff; }
.pr-card.is-popular .pr-ico { background: linear-gradient(145deg, #0bc48f, var(--green)); color: #fff; }
.pr-card.is-popular .pr-price strong { background: linear-gradient(135deg, #fff, #9ff3d4); -webkit-background-clip: text; background-clip: text; }
.pr-card.is-popular .pr-price span { color: #b9c6df; }
.pr-card.is-popular .pr-range { background: rgba(255, 255, 255, .08); border-color: rgba(255, 255, 255, .12); }
.pr-card.is-popular .pr-for li { color: #d5def0; }
.pr-card.is-popular .pr-for svg { background: rgba(7, 173, 126, .2); color: var(--green-bright); }
.pr-badge {
  position: absolute; top: -12px; inset-inline-end: 20px; z-index: 2;
  padding: 3px 14px; border-radius: 999px; font-size: .8rem; font-weight: 800; line-height: 1.9;
  background: var(--green-bright); color: var(--navy);
  box-shadow: 0 10px 22px -8px rgba(7, 173, 126, .9);
}

/* کارت سفارشی */
.pr-custom {
  justify-content: space-between; border: 1.5px dashed #9fd9c1;
  background: linear-gradient(180deg, var(--mint) 0%, #fff 100%);
}
.pr-custom p { color: #3a4a66; font-size: .95rem; line-height: 2; flex: 1; }
.pr-custom .pr-ico { background: linear-gradient(145deg, #0bc48f, var(--green)); color: #fff; }

/* کارت سفارشی تمام‌عرض در ردیف آخر */
.pr-grid > .pr-custom { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 24px; }
.pr-custom .pr-card-top { flex: none; width: 260px; }
.pr-custom .pr-cta { flex: none; width: auto; margin: 0; padding-inline: 26px; }

.pr-note { margin-top: 22px; text-align: center; color: var(--muted); font-size: .88rem; }

/* ---------- برآورد ترکیبی ---------- */
.pr-calc {
  position: relative; isolation: isolate; overflow: hidden; color: #fff;
  padding-block: clamp(56px, 7vw, 96px);
  background:
    radial-gradient(45% 60% at 100% 0%, rgba(7, 173, 126, .2), transparent 70%),
    radial-gradient(45% 60% at 0% 100%, rgba(60, 120, 230, .2), transparent 70%),
    linear-gradient(180deg, var(--navy), #061a3b);
}
.pr-calc-in { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, .75fr); gap: clamp(28px, 5vw, 56px); align-items: start; }
.pr-calc h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); font-weight: 800; line-height: 1.6; }
.pr-calc-form > p { margin-top: 8px; color: #b9c6df; }

.pr-opts { border: 0; padding: 0; margin: 26px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.pr-opts legend { grid-column: 1 / -1; padding: 0; margin-bottom: 10px; font-weight: 800; color: #fff; font-size: .98rem; }
.pr-opt { position: relative; cursor: pointer; }
.pr-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.pr-opt span {
  display: flex; align-items: center; gap: 10px; min-height: 56px; padding: 10px 14px; border-radius: 16px;
  background: rgba(255, 255, 255, .05); border: 1.5px solid rgba(255, 255, 255, .12);
  color: #d5def0; font-size: .9rem; font-weight: 600; line-height: 1.6;
  transition: background-color .2s, border-color .2s, color .2s, transform .2s;
}
.pr-opt span svg { flex: none; color: var(--green-bright); }
.pr-opt span small { margin-inline-start: auto; color: #93a3c2; font-size: .76rem; font-weight: 500; white-space: nowrap; }
.pr-opt:hover span { border-color: rgba(7, 173, 126, .5); }
.pr-opt input:checked + span { background: rgba(7, 173, 126, .16); border-color: var(--green-bright); color: #fff; }
.pr-opt input:focus-visible + span { outline: 3px solid var(--green-bright); outline-offset: 2px; }
.pr-toggle span::after {          /* سوییچ */
  content: ""; flex: none; width: 34px; height: 20px; border-radius: 999px; margin-inline-start: 8px;
  background: rgba(255, 255, 255, .18) radial-gradient(circle at calc(100% - 10px) 50%, #fff 6px, transparent 6.5px);
  transition: background .25s;
}
.pr-toggle input:checked + span::after { background: var(--green-bright) radial-gradient(circle at 10px 50%, #fff 6px, transparent 6.5px); }

.pr-result {
  position: sticky; top: calc(var(--header-h) + 24px);
  padding: 28px 24px; border-radius: 26px; text-align: center; color: var(--navy);
  background: #fff; box-shadow: 0 40px 80px -40px rgba(0, 0, 0, .7), 0 0 0 8px rgba(255, 255, 255, .06);
}
.pr-result-label { display: block; font-size: .9rem; font-weight: 700; color: var(--muted); }
.pr-result-num { display: flex; align-items: baseline; justify-content: center; gap: 10px; margin-top: 10px; }
.pr-result-num strong {
  font-size: clamp(2.6rem, 5vw, 3.4rem); font-weight: 800; line-height: 1.1;
  background: linear-gradient(135deg, var(--navy), var(--green)); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.pr-result-num strong.is-bump { animation: pr-bump .4s ease; }
@keyframes pr-bump { 50% { transform: scale(1.12); } }
.pr-result-sep { color: var(--muted); font-weight: 700; }
.pr-result-unit { display: block; margin-top: 4px; font-weight: 700; color: var(--green-dark); }
.pr-result p { margin: 14px 0 18px; color: var(--muted); font-size: .86rem; line-height: 1.95; }
.pr-result .btn-accent { box-shadow: 0 16px 30px -14px rgba(7, 173, 126, .8); }

/* ---------- عوامل قیمت ---------- */
.pr-factors { background: var(--paper); }
.pr-factor-list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; counter-reset: none; }
.pr-factor-list li {
  padding: 24px 22px; border-radius: 22px; background: #fff; border: 1px solid #e3e9f2;
  box-shadow: 0 14px 30px -26px rgba(7, 31, 69, .4);
}
.pr-factor-n {
  display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px;
  font-weight: 800; font-size: 1.1rem; color: var(--green-bright);
  background: linear-gradient(145deg, var(--navy-2), var(--navy));
}
.pr-factor-list h3 { margin-top: 14px; font-size: 1.05rem; font-weight: 800; color: var(--navy); }
.pr-factor-list p { margin-top: 6px; color: var(--muted); font-size: .93rem; line-height: 1.95; }

/* ---------- واکنش‌گرا ---------- */
@media (max-width: 1024px) {
  .pr-grid { grid-template-columns: 1fr 1fr; }
  .pr-calc-in { grid-template-columns: 1fr; }
  .pr-result { position: static; }
  .pr-factor-list { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .pr-hero { padding-top: calc(var(--header-h) + 20px); }
}
@media (max-width: 760px) {
  .pr-hero { padding-bottom: 110px; }
  .pr-grid > .pr-custom { flex-direction: column; align-items: stretch; gap: 14px; }
  .pr-custom .pr-card-top { width: auto; }
  .pr-custom .pr-cta { width: 100%; }
  .pr-hero h1 { font-size: 1.75rem; }
  .pr-hero-in > p { font-size: .98rem; }
  .pr-trust li { font-size: .82rem; }
  .pr-plans { margin-top: -78px; }
  .pr-plans-head { padding: 12px; }
  .pr-plans-head h2 { width: 100%; text-align: center; }
  .pr-chips { width: 100%; margin-inline: 0; padding-inline: 0; }
  .pr-grid { grid-template-columns: 1fr; gap: 16px; }
  .pr-card { padding: 22px 18px 18px; }
  .pr-card:hover { transform: none; }
  .pr-price strong { font-size: 1.9rem; }
  .pr-opts { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  .pr-card, .pr-range i { animation: none; }
}
