/* KAVIR V36.5.83 — Homepage articles & contact redesign.
   Scoped to the homepage sections only; no API, data, payment or admin changes. */
html body #homeScreen #articles,
html body #homeScreen #contact{
  --kv83-bg:#1c1729;
  --kv83-surface:#241d36;
  --kv83-card:#211c36;
  --kv83-ink:#fff8f2;
  --kv83-muted:#c4b9cc;
  --kv83-line:rgba(255,255,255,.13);
  --kv83-accent:#ff9958;
  --kv83-accent2:#e1e52a;
  --kv83-glow:rgba(255,145,78,.13);
  --kv83-shadow:0 22px 60px rgba(0,0,0,.22);
  box-sizing:border-box!important;
  position:relative!important;
  isolation:isolate;
  width:calc(100% - 48px)!important;
  max-width:1240px!important;
  margin:22px auto!important;
  padding:28px 30px!important;
  border:1px solid var(--kv83-line)!important;
  border-radius:28px!important;
  overflow:hidden!important;
  color:var(--kv83-ink)!important;
  background:
    radial-gradient(ellipse at 8% 12%,var(--kv83-glow),transparent 38%),
    linear-gradient(125deg,#2c2036 0%,var(--kv83-bg) 62%,#21172e 100%)!important;
  box-shadow:var(--kv83-shadow)!important;
}
html[data-theme="light"] body #homeScreen #articles,
html[data-theme="light"] body #homeScreen #contact{
  --kv83-bg:#fffaf6;
  --kv83-surface:#fff1e7;
  --kv83-card:#fff;
  --kv83-ink:#241a2c;
  --kv83-muted:#726878;
  --kv83-line:rgba(65,42,60,.13);
  --kv83-accent:#ef7438;
  --kv83-accent2:#d8a71d;
  --kv83-glow:rgba(239,116,56,.10);
  --kv83-shadow:0 18px 48px rgba(73,43,42,.08);
  background:
    radial-gradient(ellipse at 8% 12%,var(--kv83-glow),transparent 40%),
    linear-gradient(125deg,#fff 0%,var(--kv83-bg) 65%,#fff2e9 100%)!important;
}
html body #homeScreen :is(#articles,#contact) :is(.section-head,.contact-panel,.contact-copy){
  opacity:1!important;transform:none!important;animation:none!important;
}
html body #homeScreen :is(#articles,#contact) :is(h2,h3,p,strong,span,b,a){
  font-family:Pinar,Tahoma,sans-serif;
}
html body #homeScreen :is(#articles,#contact) .eyebrow{
  display:inline-flex!important;align-items:center!important;gap:9px!important;
  color:var(--kv83-accent2)!important;font-size:10px!important;font-weight:900!important;
  letter-spacing:.09em!important;direction:ltr!important;margin:0 0 7px!important;
}
html body #homeScreen :is(#articles,#contact) .eyebrow-line{
  display:inline-block!important;width:25px!important;height:1px!important;
  background:var(--kv83-accent)!important;
}
html body #homeScreen :is(#articles,#contact) h2{
  margin:8px 0!important;color:var(--kv83-ink)!important;
  font-size:clamp(25px,3vw,38px)!important;line-height:1.55!important;
  font-weight:900!important;letter-spacing:-.035em!important;
}
html body #homeScreen :is(#articles,#contact) h2 em{
  color:var(--kv83-accent)!important;font-style:normal!important;
}
html body #homeScreen :is(#articles,#contact) p{
  margin:0!important;color:var(--kv83-muted)!important;
  font-size:13px!important;line-height:2.15!important;font-weight:400!important;
}
html body #homeScreen #articles .section-head{
  display:grid!important;grid-template-columns:minmax(0,1fr) 250px!important;
  gap:26px!important;align-items:center!important;margin:0 0 22px!important;
  padding:0!important;
}
html body #homeScreen #articles .section-head>div:first-child{min-width:0!important;text-align:right!important}
html body #homeScreen #articles .section-head .kv51-intro{max-width:700px!important;margin:0!important}
html body #homeScreen #articles .kv51-art{
  height:155px!important;min-height:0!important;max-height:none!important;
  display:flex!important;align-items:center!important;justify-content:center!important;
  overflow:visible!important;background:transparent!important;position:relative!important;
}
html body #homeScreen #articles .kv51-art img{
  display:block!important;width:auto!important;height:auto!important;max-width:100%!important;
  max-height:100%!important;object-fit:contain!important;opacity:1!important;
  filter:drop-shadow(0 12px 24px rgba(0,0,0,.14))!important;mask-image:none!important;
}
html body #homeScreen #articles .kv51-art img.kv51-light,
html body #homeScreen #contact .kv51-art img.kv51-light{display:none!important}
html[data-theme="light"] body #homeScreen #articles .kv51-art img.kv51-light,
html[data-theme="light"] body #homeScreen #contact .kv51-art img.kv51-light{display:block!important}
html[data-theme="light"] body #homeScreen #articles .kv51-art img.kv51-dark,
html[data-theme="light"] body #homeScreen #contact .kv51-art img.kv51-dark{display:none!important}

/* Article carousel: four posts per slide, two columns on narrow screens. */
html body #homeScreen #articles #articleGrid{
  display:block!important;width:100%!important;max-width:none!important;
  margin:0!important;padding:0!important;overflow:hidden!important;
  background:transparent!important;gap:0!important;
}
html body #homeScreen #articles .kv83-slider-viewport{width:100%;overflow:hidden;position:relative}
html body #homeScreen #articles .kv83-slider-track{
  display:flex!important;direction:ltr!important;width:100%;
  transition:transform .55s cubic-bezier(.2,.75,.25,1);
  will-change:transform;
}
html body #homeScreen #articles .kv83-slide{
  flex:0 0 100%!important;width:100%!important;min-width:100%!important;
  display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr))!important;
  gap:13px!important;align-items:stretch!important;direction:rtl!important;
}
html body #homeScreen #articles #articleGrid .article-card{
  box-sizing:border-box!important;min-width:0!important;min-height:318px!important;
  height:auto!important;max-width:none!important;margin:0!important;padding:10px!important;
  display:flex!important;flex-direction:column!important;align-items:stretch!important;
  gap:0!important;position:relative!important;overflow:hidden!important;
  border:1px solid var(--kv83-line)!important;border-radius:19px!important;
  background:var(--kv83-card)!important;color:var(--kv83-ink)!important;
  box-shadow:0 8px 24px rgba(0,0,0,.08)!important;text-decoration:none!important;
  opacity:1!important;transform:none!important;transition:translate .22s,border-color .22s,box-shadow .22s!important;
}
html body #homeScreen #articles #articleGrid .article-card:before,
html body #homeScreen #articles #articleGrid .article-card:after{content:none!important;display:none!important}
html body #homeScreen #articles #articleGrid .article-card .article-art{
  order:1!important;display:block!important;position:relative!important;
  width:100%!important;height:145px!important;min-height:145px!important;max-height:145px!important;
  margin:0!important;padding:0!important;overflow:hidden!important;border-radius:13px!important;
  background:linear-gradient(140deg,#30234a,#15162d)!important;
}
html body #homeScreen #articles #articleGrid .article-art:before,
html body #homeScreen #articles #articleGrid .article-art:after{content:none!important;display:none!important}
html body #homeScreen #articles #articleGrid .article-art img{
  display:block!important;position:absolute!important;inset:0!important;
  width:100%!important;height:100%!important;max-width:none!important;max-height:none!important;
  object-fit:cover!important;opacity:1!important;mask-image:none!important;
}
html body #homeScreen #articles #articleGrid .article-art-fallback{
  position:absolute;inset:0;display:grid;place-items:center;color:#ffb16c;
  background:radial-gradient(circle at 70% 30%,rgba(255,169,86,.38),transparent 28%),linear-gradient(135deg,#38264e,#161a37);
}
html body #homeScreen #articles #articleGrid .article-art-fallback svg{width:58px;height:58px;fill:none;stroke:currentColor;stroke-width:1.5}
html body #homeScreen #articles #articleGrid .article-meta{
  order:2!important;display:flex!important;justify-content:space-between!important;
  align-items:center!important;gap:8px!important;margin:10px 1px 8px!important;
  padding:0!important;color:var(--kv83-muted)!important;font-size:10px!important;line-height:1.7!important;
}
html body #homeScreen #articles #articleGrid .article-meta span{color:inherit!important;font-size:inherit!important}
html body #homeScreen #articles #articleGrid .article-tag-list{
  order:3!important;display:flex!important;flex-wrap:wrap!important;gap:6px!important;
  margin:0 0 8px!important;padding:0!important;
}
html body #homeScreen #articles #articleGrid .article-tag{
  display:inline-flex!important;align-items:center!important;align-self:flex-start!important;
  padding:4px 9px!important;border-radius:999px!important;
  border:1px solid var(--kv83-line)!important;background:var(--kv83-surface)!important;
  color:var(--kv83-accent2)!important;font-size:9px!important;line-height:1.5!important;
}
html body #homeScreen #articles #articleGrid .article-card h3{
  order:4!important;display:-webkit-box!important;-webkit-box-orient:vertical!important;
  -webkit-line-clamp:2!important;overflow:hidden!important;min-height:51px!important;
  margin:0 0 7px!important;padding:0!important;color:var(--kv83-ink)!important;
  font-size:14px!important;line-height:1.85!important;font-weight:900!important;
}
html body #homeScreen #articles #articleGrid .article-card p{
  order:5!important;display:-webkit-box!important;-webkit-box-orient:vertical!important;
  -webkit-line-clamp:2!important;overflow:hidden!important;min-height:42px!important;
  margin:0 0 12px!important;padding:0!important;color:var(--kv83-muted)!important;
  font-size:11px!important;line-height:1.9!important;
}
html body #homeScreen #articles #articleGrid .article-card p:empty{display:none!important}
html body #homeScreen #articles #articleGrid .article-card .text-link{
  order:6!important;display:flex!important;justify-content:space-between!important;
  align-items:center!important;gap:8px!important;margin-top:auto!important;padding:9px 0 0!important;
  min-height:0!important;border-top:1px solid var(--kv83-line)!important;
  color:var(--kv83-accent)!important;font-size:11px!important;font-weight:900!important;
}
html body #homeScreen #articles #articleGrid .article-card .text-link span{color:inherit!important}
html body #homeScreen #articles .articles-empty{
  display:block!important;margin:0!important;padding:20px!important;text-align:center!important;
  color:var(--kv83-muted)!important;font-size:13px!important;line-height:2!important;
}
html body #homeScreen #articles .kv83-slider-footer{
  display:flex!important;align-items:center!important;justify-content:space-between!important;
  flex-wrap:wrap!important;gap:14px!important;margin-top:17px!important;
}
html body #homeScreen #articles .kv83-slider-nav{
  display:flex!important;align-items:center!important;gap:10px!important;
  margin:0!important;padding:0!important;
}
html body #homeScreen #articles .kv83-slider-arrows{display:flex;gap:7px;direction:ltr}
html body #homeScreen #articles .kv83-slider-arrows button{
  width:34px!important;height:34px!important;display:grid!important;place-items:center!important;
  padding:0!important;border:1px solid var(--kv83-line)!important;border-radius:11px!important;
  background:var(--kv83-card)!important;color:var(--kv83-ink)!important;font-size:17px!important;cursor:pointer!important;
}
html body #homeScreen #articles .kv83-slider-dots{display:flex;align-items:center;gap:7px}
html body #homeScreen #articles .kv83-dot{
  width:8px!important;height:8px!important;min-width:8px!important;padding:0!important;
  border:0!important;border-radius:99px!important;background:var(--kv83-muted)!important;
  opacity:.35!important;cursor:pointer!important;
}
html body #homeScreen #articles .kv83-dot.is-active{
  width:23px!important;background:var(--kv83-accent)!important;opacity:1!important;
}
html body #homeScreen #articles .center-action{
  display:flex!important;justify-content:flex-start!important;align-items:center!important;
  margin:0!important;padding:0!important;
}
html body #homeScreen #articles .center-action>a{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;
  min-height:42px!important;padding:10px 17px!important;border:1px solid var(--kv83-accent)!important;
  border-radius:13px!important;background:var(--kv83-accent)!important;color:#21120c!important;
  font-size:11px!important;font-weight:1000!important;text-decoration:none!important;box-shadow:0 8px 20px rgba(239,116,56,.16)!important;
}
html body #homeScreen #articles .center-action>a span{color:inherit!important}

/* Contact panel: copy on the right, illustration on the left, compact contact tiles. */
html body #homeScreen #contact .contact-panel{
  display:grid!important;grid-template-columns:minmax(0,1.35fr) minmax(230px,.78fr)!important;
  grid-template-areas:"copy art" "links art" "action art"!important;
  gap:12px 30px!important;align-items:center!important;
  margin:0!important;padding:0!important;min-height:0!important;
  border:0!important;border-radius:0!important;background:transparent!important;box-shadow:none!important;
  direction:rtl!important;
}
html body #homeScreen #contact .contact-copy{grid-area:copy!important;min-width:0!important;padding:0!important;text-align:right!important}
html body #homeScreen #contact .contact-copy h2{max-width:700px!important}
html body #homeScreen #contact .contact-copy p{max-width:700px!important}
html body #homeScreen #contact .kv51-art{
  grid-area:art!important;display:flex!important;align-items:center!important;justify-content:center!important;
  position:relative!important;min-width:0!important;min-height:280px!important;height:100%!important;
  max-height:320px!important;margin:0!important;padding:0!important;overflow:visible!important;background:transparent!important;
}
html body #homeScreen #contact .kv51-art:before{
  content:""!important;position:absolute!important;width:240px!important;height:240px!important;
  border-radius:50%!important;background:radial-gradient(circle,var(--kv83-glow),transparent 70%)!important;pointer-events:none!important;
}
html body #homeScreen #contact .kv51-art img{
  position:relative!important;display:block!important;width:min(100%,270px)!important;height:auto!important;
  max-width:100%!important;max-height:285px!important;object-fit:contain!important;
  filter:drop-shadow(0 18px 24px rgba(0,0,0,.20))!important;mask-image:none!important;
}
html body #homeScreen #contact .contact-list{
  grid-area:links!important;display:grid!important;grid-template-columns:repeat(2,minmax(0,1fr))!important;
  gap:10px!important;margin:0!important;padding:0!important;min-width:0!important;
}
html body #homeScreen #contact .contact-list>a{
  box-sizing:border-box!important;min-width:0!important;min-height:64px!important;height:auto!important;
  display:flex!important;flex-direction:row!important;align-items:center!important;gap:11px!important;
  margin:0!important;padding:12px 14px!important;border:1px solid var(--kv83-line)!important;
  border-radius:15px!important;background:var(--kv83-card)!important;color:var(--kv83-ink)!important;
  box-shadow:none!important;text-decoration:none!important;position:relative!important;
  transform:none!important;transition:border-color .22s,translate .22s!important;
}
html body #homeScreen #contact .contact-list>a .kv51-icon{
  flex:0 0 38px!important;width:38px!important;height:38px!important;display:grid!important;place-items:center!important;
  border-radius:12px!important;background:var(--kv83-surface)!important;color:var(--kv83-accent)!important;
}
html body #homeScreen #contact .contact-list>a .kv51-icon svg{
  width:19px!important;height:19px!important;fill:none!important;stroke:currentColor!important;
  stroke-width:1.8!important;stroke-linecap:round!important;stroke-linejoin:round!important;
}
html body #homeScreen #contact .contact-list>a>span:not(.kv51-icon){
  display:block!important;min-width:0!important;margin:0!important;padding:0!important;
  color:var(--kv83-muted)!important;font-size:10px!important;line-height:1.5!important;
}
html body #homeScreen #contact .contact-list>a>strong{
  display:block!important;min-width:0!important;margin:0!important;padding:0!important;
  color:var(--kv83-ink)!important;font-size:13px!important;font-weight:900!important;
  line-height:1.5!important;direction:ltr!important;text-align:right!important;
  white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;
}
html body #homeScreen #contact .contact-list>a>b{
  display:block!important;margin-right:auto!important;position:static!important;
  color:var(--kv83-accent)!important;font-size:15px!important;flex:0 0 auto!important;
}
html body #homeScreen #contact .kv51-actions{
  grid-area:action!important;display:flex!important;align-items:center!important;gap:13px!important;
  flex-wrap:wrap!important;margin:0!important;padding:0!important;
}
html body #homeScreen #contact .kv51-actions>a{
  display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:9px!important;
  min-height:44px!important;margin:0!important;padding:12px 18px!important;
  border:1px solid var(--kv83-accent)!important;border-radius:13px!important;
  background:var(--kv83-accent)!important;color:#21120c!important;
  font-size:12px!important;font-weight:1000!important;text-decoration:none!important;box-shadow:none!important;
}
html body #homeScreen #contact .kv51-actions>a span{color:inherit!important}
html body #homeScreen #contact .kv51-actions:after{
  content:"پاسخ‌گویی برای همراهی در مسیر آزمون شما";display:block;color:var(--kv83-muted);
  font-size:10px;line-height:1.8;
}
html body #homeScreen :is(#articles,#contact) a:focus-visible,
html body #homeScreen #articles button:focus-visible{
  outline:3px solid var(--kv83-accent2)!important;outline-offset:3px!important;
}
@media(hover:hover) and (pointer:fine){
  html body #homeScreen #articles #articleGrid .article-card:hover{
    translate:0 -4px!important;border-color:var(--kv83-accent)!important;
    box-shadow:0 14px 28px rgba(0,0,0,.13)!important;
  }
  html body #homeScreen #contact .contact-list>a:hover{
    translate:0 -2px!important;border-color:var(--kv83-accent)!important;
  }
}
@media(max-width:1000px){
  html body #homeScreen :is(#articles,#contact){width:calc(100% - 32px)!important;padding:22px!important}
  html body #homeScreen #articles .kv83-slide{grid-template-columns:repeat(2,minmax(0,1fr))!important}
  html body #homeScreen #articles #articleGrid .article-card{min-height:300px!important}
  html body #homeScreen #contact .contact-panel{
    grid-template-columns:minmax(0,1.2fr) minmax(190px,.7fr)!important;gap:12px 20px!important;
  }
  html body #homeScreen #contact .contact-list{grid-template-columns:repeat(2,minmax(0,1fr))!important}
}
@media(max-width:620px){
  html body #homeScreen :is(#articles,#contact){
    width:calc(100% - 20px)!important;margin:16px auto!important;padding:19px 14px!important;border-radius:22px!important;
  }
  html body #homeScreen :is(#articles,#contact) h2{font-size:25px!important;line-height:1.55!important}
  html body #homeScreen :is(#articles,#contact) p{font-size:12px!important;line-height:2.05!important}
  html body #homeScreen #articles .section-head{
    grid-template-columns:1fr!important;gap:6px!important;margin-bottom:15px!important;
  }
  html body #homeScreen #articles .kv51-art{
    height:100px!important;justify-content:flex-start!important;margin:0!important;
  }
  html body #homeScreen #articles .kv51-art img{max-width:175px!important}
  html body #homeScreen #articles .kv83-slide{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:8px!important}
  html body #homeScreen #articles #articleGrid .article-card{
    min-height:0!important;padding:8px!important;border-radius:15px!important;
  }
  html body #homeScreen #articles #articleGrid .article-card .article-art{
    height:94px!important;min-height:94px!important;max-height:94px!important;border-radius:11px!important;
  }
  html body #homeScreen #articles #articleGrid .article-meta{font-size:9px!important;margin:7px 0!important}
  html body #homeScreen #articles #articleGrid .article-tag{font-size:8px!important;padding:3px 7px!important}
  html body #homeScreen #articles #articleGrid .article-card h3{
    min-height:44px!important;font-size:11px!important;line-height:1.75!important;
  }
  html body #homeScreen #articles #articleGrid .article-card p{
    min-height:38px!important;font-size:9px!important;line-height:1.75!important;
  }
  html body #homeScreen #articles #articleGrid .article-card .text-link{font-size:9px!important;padding-top:7px!important}
  html body #homeScreen #articles .kv83-slider-footer{gap:12px!important;margin-top:13px!important}
  html body #homeScreen #articles .center-action>a{font-size:10px!important;padding:10px 12px!important}
  html body #homeScreen #articles .kv83-slider-arrows button{width:31px!important;height:31px!important}
  html body #homeScreen #contact .contact-panel{
    grid-template-columns:1fr!important;grid-template-areas:"copy" "art" "links" "action"!important;gap:12px!important;
  }
  html body #homeScreen #contact .kv51-art{
    min-height:140px!important;height:140px!important;max-height:160px!important;
  }
  html body #homeScreen #contact .kv51-art img{width:180px!important;max-height:155px!important}
  html body #homeScreen #contact .contact-list{grid-template-columns:1fr!important;gap:8px!important}
  html body #homeScreen #contact .contact-list>a{min-height:60px!important;padding:10px 11px!important}
  html body #homeScreen #contact .kv51-actions{display:block!important}
  html body #homeScreen #contact .kv51-actions>a{width:100%!important;justify-content:center!important}
  html body #homeScreen #contact .kv51-actions:after{width:100%;text-align:center;margin-top:7px}
}
@media(max-width:360px){
  html body #homeScreen #articles .kv83-slide{grid-template-columns:1fr!important}
}
@media(prefers-reduced-motion:reduce){
  html body #homeScreen #articles .kv83-slider-track,
  html body #homeScreen :is(#articles,#contact) a{transition:none!important}
}
