:root {
  --blue: #1565c0;
  --blue-dark: #0d47a1;
  --blue-soft: #e3f0fb;
  --blue-mid: #90caf9;
  --ink: #1a2332;
  --muted: #5a6a7a;
  --line: #d7e3ef;
  --bg: #f7fafc;
  --surface: #ffffff;
  --warn: #b45309;
  --warn-bg: #fff7ed;
  --ok: #0f766e;
  --radius: 16px;
  --shadow: 0 12px 40px rgba(21, 101, 192, 0.08);
  --font: "IranYekan", Tahoma, sans-serif;
}

@font-face {
  font-family: "IranYekan";
  src: url("../assets/fonts/IRANYekanXFaNum-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IranYekan";
  src: url("../assets/fonts/IRANYekanXFaNum-Medium.ttf") format("truetype");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IranYekan";
  src: url("../assets/fonts/IRANYekanXFaNum-DemiBold.ttf") format("truetype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IranYekan";
  src: url("../assets/fonts/IRANYekanXFaNum-Bold.ttf") format("truetype");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.7;
  direction: rtl;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--blue);
  text-decoration: none;
}

a:hover {
  color: var(--blue-dark);
}

.container {
  width: min(1120px, calc(100% - 2rem));
  margin-inline: auto;
}

/* —— Nav —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--ink);
  font-weight: 700;
  font-size: 1.15rem;
}

.brand img {
  width: 36px;
  height: 36px;
  border-radius: 9px;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  display: inline-block;
  padding: 0.45rem 0.85rem;
  color: var(--muted);
  border-radius: 999px;
  font-size: 0.95rem;
  font-weight: 500;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--blue);
  background: var(--blue-soft);
}

.nav-cta {
  background: var(--blue) !important;
  color: #fff !important;
}

.nav-cta:hover {
  background: var(--blue-dark) !important;
}

.nav-toggle {
  display: none;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 10px;
  padding: 0.45rem 0.7rem;
  cursor: pointer;
  font-family: inherit;
}

/* —— Hero —— */
.hero {
  position: relative;
  min-height: clamp(360px, 62vh, 560px);
  display: grid;
  align-items: end;
  color: #fff;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 15% 20%, rgba(144, 202, 249, 0.35), transparent 55%),
    radial-gradient(ellipse 70% 50% at 90% 80%, rgba(13, 71, 161, 0.45), transparent 50%),
    linear-gradient(135deg, #0d47a1 0%, #1565c0 48%, #1976d2 100%);
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top, rgba(7, 32, 70, 0.55), transparent 45%),
    url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding: 4.5rem 0 3.5rem;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  margin-bottom: 1.25rem;
}

.hero-brand img {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.hero-brand span {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.hero h1 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.35rem, 2.6vw, 1.85rem);
  font-weight: 600;
  max-width: 34ch;
  line-height: 1.45;
}

.hero p {
  margin: 0 0 1.75rem;
  max-width: 42ch;
  font-size: 1.05rem;
  opacity: 0.92;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: none;
  border-radius: 12px;
  padding: 0.75rem 1.35rem;
  font-family: inherit;
  font-size: 0.98rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: #fff;
  color: var(--blue-dark);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.btn-primary:hover {
  background: #f0f7ff;
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.35);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.2);
}

.btn-blue {
  background: var(--blue);
  color: #fff;
}

.btn-blue:hover {
  background: var(--blue-dark);
}

.btn-outline {
  background: #fff;
  color: var(--blue);
  border: 1px solid var(--line);
}

.btn-outline:hover {
  border-color: var(--blue-mid);
  background: var(--blue-soft);
}

/* —— Sections —— */
.section {
  padding: 4.25rem 0;
}

.section-alt {
  background: var(--surface);
  border-block: 1px solid var(--line);
}

.section-head {
  max-width: 40rem;
  margin-bottom: 2rem;
}

.section-eyebrow {
  color: var(--blue);
  font-weight: 700;
  font-size: 0.9rem;
  margin: 0 0 0.4rem;
}

.section-head h2 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.45rem, 2.4vw, 1.9rem);
  line-height: 1.35;
}

.section-head p {
  margin: 0;
  color: var(--muted);
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.35rem 1.25rem;
  box-shadow: var(--shadow);
}

.feature-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  background: var(--blue-soft);
  color: var(--blue);
  display: grid;
  place-items: center;
  font-weight: 700;
  margin-bottom: 0.9rem;
}

.feature h3 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
}

.feature p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* —— Wizard —— */
.wizard-shell {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 22px;
  box-shadow: var(--shadow);
  overflow: hidden;
  overflow-anchor: none;
}

.wizard-progress {
  padding: 1.15rem 1.35rem 0.85rem;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #fbfdff, #fff);
}

.wizard-progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 0.65rem;
  font-size: 0.9rem;
}

.wizard-progress-meta strong {
  color: var(--blue);
}

.wizard-progress-meta span {
  color: var(--muted);
}

.progress-bar {
  height: 6px;
  border-radius: 99px;
  background: rgba(21, 101, 192, 0.12);
  overflow: hidden;
}

.progress-bar > i {
  display: block;
  height: 100%;
  width: 12.5%;
  background: var(--blue);
  border-radius: 99px;
  transition: width 0.28s ease;
}

.wizard-body {
  padding: 1.5rem 1.35rem 1.25rem;
  min-height: 420px;
  overflow-anchor: none;
}

.question h3 {
  margin: 0 0 0.55rem;
  font-size: 1.15rem;
  line-height: 1.45;
}

.question p {
  margin: 0;
  color: var(--muted);
  white-space: pre-line;
  font-size: 0.95rem;
}

.field-stack {
  display: grid;
  gap: 0.95rem;
  margin-top: 1.25rem;
}

label.field {
  display: grid;
  gap: 0.35rem;
  font-size: 0.92rem;
  font-weight: 600;
}

label.field span.hint {
  font-weight: 400;
  color: var(--muted);
  font-size: 0.85rem;
}

input[type="text"],
input[type="number"] {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem 0.9rem;
  font-family: inherit;
  font-size: 1rem;
  background: #fff;
  color: var(--ink);
  direction: ltr;
  text-align: left;
}

input:focus {
  outline: 2px solid rgba(21, 101, 192, 0.25);
  border-color: var(--blue);
}

.yesno {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.yesno button {
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 14px;
  padding: 0.95rem 1rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  color: var(--ink);
}

.yesno button.is-on {
  border-color: var(--blue);
  background: var(--blue-soft);
  color: var(--blue-dark);
}

.switch-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
  border-top: 1px solid var(--line);
  margin-top: 0.5rem;
}

.switch-row strong {
  display: block;
  margin-bottom: 0.2rem;
}

.switch-row p {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 400;
}

.switch {
  position: relative;
  width: 48px;
  height: 28px;
  flex-shrink: 0;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch i {
  position: absolute;
  inset: 0;
  background: #c5d3e0;
  border-radius: 99px;
  cursor: pointer;
  transition: background 0.2s;
}

.switch i::before {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  top: 3px;
  right: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.2s;
}

.switch input:checked + i {
  background: var(--blue);
}

.switch input:checked + i::before {
  transform: translateX(-20px);
}

.wizard-error {
  margin-top: 1rem;
  padding: 0.75rem 0.9rem;
  border-radius: 12px;
  background: #fef2f2;
  color: #b91c1c;
  font-size: 0.92rem;
  display: none;
}

.wizard-error.is-visible {
  display: block;
}

.wizard-footer {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 1rem 1.35rem 1.25rem;
  border-top: 1px solid var(--line);
  background: #fbfdff;
}

.review-list {
  display: grid;
  gap: 0.55rem;
  margin-top: 1.1rem;
}

.review-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0.9rem;
  background: rgba(227, 240, 251, 0.45);
  border-radius: 12px;
  font-size: 0.92rem;
}

.review-row span:last-child {
  font-weight: 600;
  direction: ltr;
}

/* —— Result —— */
.result-panel {
  display: none;
  margin-top: 1.5rem;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
  overflow-anchor: none;
}

.result-panel.is-visible {
  display: block;
}

.result-hero {
  padding: 1.5rem 1.35rem;
  background: linear-gradient(135deg, #0d47a1, #1565c0);
  color: #fff;
}

.result-hero .label {
  opacity: 0.85;
  font-size: 0.9rem;
}

.result-hero .value {
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  font-weight: 700;
  margin: 0.25rem 0;
  direction: ltr;
  display: inline-block;
}

.result-hero .sub {
  opacity: 0.9;
  font-size: 0.92rem;
  margin: 0;
}

.result-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
  padding: 1.25rem 1.35rem;
}

.result-stat {
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 0.9rem 1rem;
  background: #fbfdff;
}

.result-stat .k {
  color: var(--muted);
  font-size: 0.85rem;
  margin-bottom: 0.25rem;
}

.result-stat .v {
  font-weight: 700;
  font-size: 1.05rem;
  direction: ltr;
  display: inline-block;
}

.result-stat .s {
  color: var(--muted);
  font-size: 0.82rem;
  margin-top: 0.25rem;
}

.warn-banner {
  margin: 0 1.35rem 1.1rem;
  padding: 0.85rem 1rem;
  border-radius: 12px;
  background: var(--warn-bg);
  color: var(--warn);
  font-size: 0.92rem;
}

.schedule-wrap {
  padding: 0 1.35rem 1.35rem;
  overflow-x: auto;
}

.schedule-wrap table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.88rem;
  min-width: 520px;
}

.schedule-wrap th,
.schedule-wrap td {
  padding: 0.55rem 0.45rem;
  border-bottom: 1px solid var(--line);
  text-align: center;
  direction: ltr;
}

.schedule-wrap th {
  color: var(--muted);
  font-weight: 600;
  background: #f8fbff;
}

/* —— FAQ —— */
.faq-list {
  display: grid;
  gap: 0.7rem;
}

.faq-item {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
  overflow: hidden;
}

.faq-item summary {
  cursor: pointer;
  padding: 1rem 1.15rem;
  font-weight: 600;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: left;
  color: var(--blue);
  font-weight: 700;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-item p {
  margin: 0;
  padding: 0 1.15rem 1.1rem;
  color: var(--muted);
}

/* —— Footer —— */
.site-footer {
  background: #0b2748;
  color: rgba(255, 255, 255, 0.82);
  padding: 2.5rem 0 1.5rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}

.site-footer h3 {
  color: #fff;
  margin: 0 0 0.7rem;
  font-size: 1rem;
}

.site-footer p,
.site-footer li {
  font-size: 0.92rem;
  margin: 0 0 0.4rem;
}

.site-footer ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-footer a {
  color: rgba(255, 255, 255, 0.82);
}

.site-footer a:hover {
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding-top: 1rem;
  font-size: 0.85rem;
  opacity: 0.75;
}

@media (max-width: 860px) {
  .feature-grid,
  .result-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav-links {
    display: none;
    position: absolute;
    inset-inline: 1rem;
    top: 68px;
    flex-direction: column;
    align-items: stretch;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 14px;
    padding: 0.5rem;
    box-shadow: var(--shadow);
  }

  .nav-links.is-open {
    display: flex;
  }
}

@media (max-width: 560px) {
  .yesno {
    grid-template-columns: 1fr;
  }

  .wizard-footer {
    flex-direction: column-reverse;
  }

  .wizard-footer .btn {
    width: 100%;
  }
}
