@import url("./mj-theme.css?v=9");
@import url("./mj-effects.css?v=8");

/* =========================================================
   MJ Kit — base
   Host: /wp-content/uploads/mj-kit/mj-base.css
   Scope: .mj-root (+ page slug e.g. .mj-apps)
   Theme follows homepage / DESIGN.md (2026-10-18)
========================================================= */

/* Font URLs relative to this CSS file → works on host and local preview */
@font-face {
  font-family: "YekanBakh";
  src: url("fonts/yekanbakh/400-YekanBakh-Regular.woff") format("woff");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "YekanBakh";
  src: url("fonts/yekanbakh/600-YekanBakh-Bold.woff") format("woff");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "YekanBakh";
  src: url("fonts/yekanbakh/700-YekanBakh-ExtraBold.woff") format("woff");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "YekanBakh";
  src: url("fonts/yekanbakh/800-YekanBakh-Black.woff") format("woff");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}

/* Never put scroll-snap-type on html — Elementor header/footer lock. */

/* ---------- Root shell ---------- */
/* .mj-root.mj-root beats Elementor section/kit rules (same values; higher specificity). */

.mj-root.mj-root {
  position: relative;
  overflow: hidden;
  overflow: clip;
  direction: rtl;
  color: var(--text);
  font-family: "YekanBakh", Tahoma, sans-serif;
  font-weight: 400;
  font-synthesis: none;
  line-height: 1.85;
  background: var(--bg);
}
.mj-root {
  padding: 110px 24px 130px;
}

/* Elementor kit sets IRANYekanX on h1/h2/p/… — inheritance from .mj-root loses. */
.mj-root.mj-root :is(
  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  p,
  a,
  button,
  li,
  span,
  strong,
  b,
  em,
  small,
  bdi
) {
  font-family: "YekanBakh", Tahoma, sans-serif !important;
}

.mj-root *,
.mj-root *::before,
.mj-root *::after {
  box-sizing: border-box;
}
.mj-root a {
  color: inherit;
}
.mj-root :is(a, button, input, select, textarea):focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
.mj-root :is(.mj-wrap, .mj-stat, .mj-card) {
  min-width: 0;
  overflow-wrap: anywhere;
}
.mj-root button,
.mj-root a {
  -webkit-tap-highlight-color: transparent;
  font-family: inherit;
}

/* Kill WP/Elementor theme button paints inside widgets (hover often injects primary/red). */
.mj-root.mj-root button,
.mj-root.mj-root button:hover,
.mj-root.mj-root button:focus,
.mj-root.mj-root button:active {
  -webkit-appearance: none;
  appearance: none;
  background: transparent;
  background-color: transparent;
  border: 0;
  box-shadow: none;
  color: inherit;
}

.mj-root::before,
.mj-root::after { display: none; }

.mj-wrap {
  position: relative;
  z-index: 1;
  width: min(1180px, 100%);
  margin: 0 auto;
}

/* ---------- Snap section (vh) ---------- */

.mj-snap-section {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
}

/* ---------- Eyebrow ---------- */

.mj-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  background: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.045);
  color: var(--accent);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  box-shadow: 0 0 30px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.05);
}

.mj-eyebrow::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 12px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.8);
  animation: mjPulseDot 2s ease-in-out infinite;
}

/* ---------- Dual-tone titles ---------- */

.mj-root h2.mj-display,
.mj-root .mj-display {
  margin: 24px auto 0;
  max-width: 850px;
  color: var(--mj-ink, #fff);
  font-family: "YekanBakh", Tahoma, sans-serif;
  font-size: clamp(34px, 5.4vw, 66px);
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.mj-root h2.mj-display em,
.mj-root .mj-display em,
.mj-root h3.mj-headline bdi,
.mj-root .mj-headline bdi {
  color: var(--accent);
  font-style: normal;
  font-weight: 800;
  text-shadow: 0 0 45px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.24);
}

.mj-root h3.mj-headline,
.mj-root .mj-headline {
  margin: 18px 0 14px;
  color: var(--mj-ink, #fff);
  font-size: clamp(28px, 3.2vw, 42px);
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.02em;
}

.mj-lead {
  margin-bottom: 18px;
  color: var(--text-2);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.85;
}

.mj-muted {
  color: var(--muted);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.95;
}

/* ---------- Tag ---------- */

.mj-tag {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 12px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.18);
  border-radius: 999px;
  background: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.055);
  color: var(--accent);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.mj-tag.mj-soon {
  border-color: rgba(255, 189, 105, 0.28);
  background: rgba(255, 189, 105, 0.06);
  color: var(--amber);
}

/* ---------- Button ---------- */

.mj-root a.mj-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  margin-top: 28px;
  min-height: 48px;
  padding: 0 21px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.42);
  border-radius: 6px;
  overflow: hidden;
  color: var(--accent-dark);
  background: var(--accent);
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  transition:
    color 0.35s ease,
    border-color 0.35s ease,
    transform 0.35s ease,
    box-shadow 0.35s ease;
}

.mj-root a.mj-btn::before {
  display: none;
}

.mj-root a.mj-btn:hover {
  color: var(--accent-dark);
  background: var(--accent-soft);
  border-color: var(--accent-soft);
  transform: translateY(-2px);
  box-shadow: 0 14px 40px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.17);
}

.mj-root a.mj-btn:hover::before {
  transform: none;
}

.mj-btn svg {
  width: 17px;
  height: 17px;
  transition: transform 0.35s ease;
}

.mj-btn:hover svg {
  transform: translateX(-5px);
}

.mj-root a.mj-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 5px;
}

/* ---------- Window mock ---------- */

.mj-win {
  position: relative;
  direction: ltr;
  overflow: hidden;
  min-height: 325px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.16);
  border-radius: 8px;
  background: var(--surface);
  box-shadow:
    0 35px 90px rgba(var(--mj-shadow-rgb, 0, 0, 0), calc(0.48 * var(--mj-shadow-strength, 1))),
    0 0 0 1px rgba(var(--mj-wash-rgb, 255, 255, 255), 0.025) inset,
    0 0 80px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.045);
  transform-style: preserve-3d;
  transition:
    box-shadow 0.5s ease,
    border-color 0.5s ease;
}

.mj-win:hover {
  border-color: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.3);
  box-shadow:
    0 42px 100px rgba(var(--mj-shadow-rgb, 0, 0, 0), calc(0.56 * var(--mj-shadow-strength, 1))),
    0 0 100px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.1),
    0 0 0 1px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.05) inset;
}

.mj-win::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    125deg,
    rgba(var(--mj-wash-rgb, 255, 255, 255), 0.045),
    transparent 25%,
    transparent 70%,
    rgba(var(--mj-accent-rgb, 70, 204, 227), 0.025)
  );
}

.mj-bar {
  display: flex;
  align-items: center;
  gap: 7px;
  height: 48px;
  padding: 0 18px;
  border-bottom: 1px solid rgba(var(--mj-wash-rgb, 255, 255, 255), 0.06);
  background: rgba(var(--mj-shadow-rgb, 0, 0, 0), calc(0.12 * var(--mj-shadow-strength, 1)));
}

.mj-bar i {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #36706d;
  opacity: 0.7;
}

.mj-bar i:first-child {
  background: var(--accent);
  box-shadow: 0 0 9px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.6);
}

.mj-root.mj-root .mj-bar span {
  margin-left: auto;
  color: var(--mj-muted, #62848b);
  font-family: monospace !important;
  font-size: 10px;
  letter-spacing: 0.03em;
}

.mj-body {
  position: relative;
  z-index: 1;
  padding: 27px;
  direction: rtl;
}

/* ---------- Chip ---------- */

.mj-chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 7px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.14);
  border-radius: 999px;
  background: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.06);
  color: var(--mj-secondary, #9ec4c9);
  font-size: 9px;
  font-weight: 600;
  line-height: 1.4;
  white-space: nowrap;
}

.mj-chip.is-done {
  border-color: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.35);
  background: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.14);
  color: var(--accent);
}

.mj-chip.is-warn {
  border-color: rgba(232, 176, 74, 0.35);
  background: rgba(232, 176, 74, 0.1);
  color: var(--mj-warning, #e8b04a);
}

/* ---------- Card ---------- */

.mj-card {
  padding: 10px;
  margin-bottom: 8px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.1);
  border-radius: 10px;
  background: rgba(var(--mj-wash-rgb, 255, 255, 255), 0.025);
  color: var(--mj-secondary, #c5d9dc);
  font-size: 10px;
  font-weight: 600;
}

.mj-card small {
  display: block;
  margin-top: 3px;
  color: var(--mj-muted, #66878e);
  font-size: 9px;
  font-weight: 400;
}

.mj-card.hot {
  border-color: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.4);
  box-shadow: 0 0 25px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.08);
  animation: mjHot 2.5s ease-in-out infinite;
}

/* ---------- Stat ---------- */

.mj-stat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.mj-stat {
  padding: 14px 10px;
  border: 1px solid rgba(var(--mj-accent-rgb, 70, 204, 227), 0.11);
  border-radius: 13px;
  background: rgba(var(--mj-accent-rgb, 70, 204, 227), 0.035);
  text-align: center;
}

.mj-stat strong {
  display: block;
  color: var(--accent);
  font-size: 20px;
  font-weight: 800;
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.mj-stat span {
  display: block;
  margin-top: 4px;
  color: var(--mj-muted, #6e9198);
  font-size: 10px;
  font-weight: 400;
}

/* ---------- Motion keyframes + JS states ---------- */

@keyframes mjPulseDot {
  50% {
    opacity: 0.35;
    transform: scale(0.75);
  }
}

/* mjReveal is shared through mj-effects.css. */

@keyframes mjHot {
  50% {
    box-shadow: 0 0 35px rgba(var(--mj-accent-rgb, 70, 204, 227), 0.16);
  }
}

.mj-root.js [data-mj-snap] {
  opacity: 0;
  transform: translateY(24px);
}

.mj-root.js [data-mj-snap].is-visible {
  animation: mjReveal 0.8s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
}
.mj-root [data-mj-snap]:not(.live) :is(.mj-eyebrow, .mj-card.hot),
.mj-root [data-mj-snap]:not(.live) .mj-eyebrow::before {
  animation-play-state: paused;
}

.mj-root.mj-snap-busy {
  overscroll-behavior-y: contain;
}

@media (max-width: 600px) {
  .mj-root.mj-snap-busy {
    overscroll-behavior-y: auto;
  }
}

/* ---------- Responsive base ---------- */

.mj-win,
.mj-body {
  min-width: 0;
  max-width: 100%;
}

.mj-bar span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

@media (min-width: 1440px) {
  .mj-wrap {
    width: min(1280px, 100%);
  }
}

@media (max-width: 1180px) {
  .mj-body {
    padding: 22px;
  }
}

@media (max-width: 960px) {
  .mj-root {
    padding: 85px 20px 100px;
  }
  .mj-snap-section {
    min-height: 100vh;
    min-height: 100dvh;
  }
  .mj-win {
    min-height: 300px;
  }
}

@media (max-width: 600px) {
  .mj-root {
    padding: 65px 15px 80px;
  }
  .mj-snap-section {
    min-height: 100vh;
    min-height: 100dvh;
  }
  .mj-eyebrow {
    font-size: 10px;
    padding: 6px 12px;
  }
  .mj-root h2.mj-display,
  .mj-root .mj-display {
    font-size: clamp(28px, 9vw, 34px);
    letter-spacing: -0.03em;
    line-height: 1.35;
  }
  .mj-root h3.mj-headline,
  .mj-root .mj-headline {
    font-size: clamp(24px, 7.4vw, 28px);
    line-height: 1.45;
  }
  .mj-root a.mj-btn {
    width: 100%;
    margin-top: 22px;
    padding: 10px 18px;
    text-align: center;
    line-height: 1.7;
  }
  .mj-win {
    min-height: 0;
    border-radius: 17px;
  }
  .mj-bar {
    height: 40px;
    padding: 0 13px;
  }
  .mj-body {
    padding: 16px;
  }
}

@media (max-width: 380px) {
  .mj-root {
    padding: 56px 12px 70px;
  }
  .mj-body {
    padding: 13px;
  }
}

@media (max-height: 640px) {
  .mj-snap-section {
    min-height: 100vh;
    min-height: 100dvh;
  }
}

@media (prefers-reduced-motion: reduce) {
  .mj-root *,
  .mj-root *::before,
  .mj-root *::after {
    animation: none !important;
    transition: none !important;
  }
  .mj-root.js [data-mj-snap] {
    opacity: 1 !important;
    transform: none !important;
  }
}
