:root {
  --brand-primary: #030213;
  --brand-primary-strong: #000000;
  --brand-accent: #37b478;
  --brand-ink: #16171a;
  --brand-ink-soft: #4f5560;
  --page-background: #f7f8fa;
  --surface: rgba(255, 255, 255, 0.94);
  --surface-border: rgba(3, 2, 19, 0.12);
  --shadow-soft: 0 22px 45px rgba(3, 2, 19, 0.12);
}

html,
body {
  min-height: 100%;
}

body {
  font-family: "Vazirmatn", "Tahoma", sans-serif;
  background: radial-gradient(circle at 100% 0%, rgba(55, 180, 120, 0.14) 0%, transparent 43%),
    radial-gradient(circle at 0% 88%, rgba(3, 2, 19, 0.1) 0%, transparent 41%),
    var(--page-background);
  color: var(--brand-ink);
  position: relative;
  overflow-x: hidden;
}

.service-shell {
  position: relative;
  z-index: 2;
}

.page-aura {
  position: fixed;
  width: 22rem;
  height: 22rem;
  border-radius: 999px;
  filter: blur(14px);
  z-index: 1;
  opacity: 0.36;
  pointer-events: none;
}

.page-aura-top {
  top: -10rem;
  left: -4rem;
  background: linear-gradient(145deg, rgba(3, 2, 19, 0.4), rgba(55, 180, 120, 0.28));
}

.page-aura-bottom {
  bottom: -9rem;
  right: -5rem;
  background: linear-gradient(145deg, rgba(3, 2, 19, 0.3), rgba(55, 180, 120, 0.18));
}

.hero-banner {
  background: linear-gradient(128deg, #000000 0%, #06070d 56%, #173929 100%);
  border-radius: 1.6rem;
  padding: 1.4rem 1.3rem 1.5rem;
  box-shadow: var(--shadow-soft);
  color: #eef9f6;
  position: relative;
  isolation: isolate;
}

.hero-banner::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.07), rgba(55, 180, 120, 0.06));
  z-index: -1;
}

.hero-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.72rem;
}

.hero-logo-img {
  width: 3rem;
  height: 2.35rem;
  object-fit: contain;
  border-radius: 999px;
  background: #fff;
  border: 1px solid rgba(255, 255, 255, 0.68);
  padding: 0.25rem 0.32rem;
}

.hero-brand-en {
  font-family: "Manrope", sans-serif;
  font-size: 0.82rem;
  letter-spacing: 0.26em;
  font-weight: 700;
  color: #fff;
  opacity: 0.95;
}

.hero-chip {
  border-radius: 999px;
  padding: 0.43rem 0.85rem;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.35);
  font-size: 0.77rem;
  white-space: nowrap;
}

.lang-switch-group .lang-switch-btn {
  border-color: rgba(255, 255, 255, 0.62);
  color: #fff;
  font-size: 0.8rem;
  min-width: 4.4rem;
}

.lang-switch-group .lang-switch-btn:hover,
.lang-switch-group .lang-switch-btn:focus-visible {
  background: rgba(255, 255, 255, 0.2) !important;
  border-color: #fff !important;
  color: #fff !important;
}

.lang-switch-group .lang-switch-btn.active {
  background: rgba(255, 255, 255, 0.26);
  border-color: #fff;
}

.theme-btn.btn-outline-secondary {
  border-color: rgba(255, 255, 255, 0.62);
  color: #fff;
  background: transparent;
  font-size: 0.86rem;
}

.theme-btn.btn-outline-secondary:hover,
.theme-btn.btn-outline-secondary:focus-visible,
.theme-btn.btn-outline-secondary:active {
  background: rgba(255, 255, 255, 0.2) !important;
  border-color: #fff !important;
  color: #fff !important;
}

.back-services-btn {
  border-color: rgba(255, 255, 255, 0.62);
  color: #fff;
  border-radius: 999px;
  font-size: 0.84rem;
}

.back-services-btn:hover,
.back-services-btn:focus-visible,
.back-services-btn:active {
  background: rgba(255, 255, 255, 0.2) !important;
  border-color: #fff !important;
  color: #fff !important;
}

.hero-title {
  font-size: clamp(1.45rem, 2.2vw, 2rem);
  font-weight: 800;
  line-height: 1.28;
}

.hero-subtitle {
  max-width: 44rem;
  color: rgba(245, 255, 252, 0.92);
}

.service-card {
  border: 1px solid var(--surface-border);
  border-radius: 1.25rem;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(8px);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.service-option-card {
  position: relative;
  border: 1px solid var(--surface-border);
  border-radius: 1.25rem;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  padding: 1.2rem;
  text-decoration: none;
  color: inherit;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.service-option-card:hover,
.service-option-card:focus-visible {
  transform: translateY(-3px);
  border-color: rgba(55, 180, 120, 0.42);
  box-shadow: 0 18px 33px rgba(3, 2, 19, 0.18);
}

.service-option-title {
  margin-top: 0.8rem;
  margin-bottom: 0.35rem;
  font-size: 1.08rem;
  font-weight: 800;
  color: var(--brand-ink);
}

.service-option-text {
  color: var(--brand-ink-soft);
  font-size: 0.9rem;
  line-height: 1.5;
}

.service-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.28rem 0.6rem;
  font-size: 0.72rem;
  font-weight: 700;
}

.service-pill.ready {
  background: rgba(55, 180, 120, 0.16);
  color: #1f8f5c;
}

.service-pill.soon {
  background: rgba(18, 52, 78, 0.1);
  color: var(--brand-ink-soft);
}

.section-title {
  color: var(--brand-ink);
  font-size: 1.03rem;
  font-weight: 800;
}

.input-label {
  color: var(--brand-ink-soft);
  font-size: 0.88rem;
  font-weight: 600;
}

.branded-control {
  border-radius: 0.82rem;
  border: 1px solid rgba(18, 52, 78, 0.16);
  min-height: 2.8rem;
  background: rgba(255, 255, 255, 0.92);
  font-size: 0.92rem;
}

.branded-control:focus {
  box-shadow: 0 0 0 0.18rem rgba(15, 140, 116, 0.2);
  border-color: rgba(15, 140, 116, 0.6);
}

.add-interview-btn {
  border-radius: 999px;
  font-weight: 700;
  border-color: rgba(55, 180, 120, 0.48);
  color: var(--brand-primary-strong);
}

.add-interview-btn:hover,
.add-interview-btn:focus-visible,
.add-interview-btn:active {
  background: rgba(55, 180, 120, 0.13) !important;
  color: var(--brand-primary-strong) !important;
  border-color: rgba(55, 180, 120, 0.62) !important;
}

.interview-item {
  border: 1px solid rgba(18, 52, 78, 0.12);
  border-radius: 0.95rem;
  background: rgba(255, 255, 255, 0.72);
}

.interview-item-title {
  color: var(--brand-ink-soft);
  font-weight: 800;
}

.interview-remove-btn {
  border-radius: 999px;
}

.submit-btn.btn-primary {
  border: none;
  border-radius: 0.9rem;
  background: linear-gradient(132deg, var(--brand-primary) 0%, var(--brand-accent) 100%);
  box-shadow: 0 13px 26px rgba(3, 2, 19, 0.28);
  font-weight: 700;
  letter-spacing: 0.01em;
}

.submit-btn.btn-primary:hover,
.submit-btn.btn-primary:focus-visible,
.submit-btn.btn-primary:active {
  background: linear-gradient(132deg, var(--brand-primary-strong) 0%, #2e9e67 100%) !important;
}

.status-badge.badge {
  border-radius: 999px;
  font-size: 0.74rem;
  padding: 0.5rem 0.8rem;
}

.live-strip {
  background: rgba(55, 180, 120, 0.1);
  border: 1px solid rgba(55, 180, 120, 0.24);
  border-radius: 0.85rem;
  padding: 0.78rem 0.85rem;
}

.progress-overview {
  border: 1px solid rgba(18, 52, 78, 0.12);
  border-radius: 0.92rem;
  background: rgba(255, 255, 255, 0.78);
  padding: 0.78rem 0.86rem;
}

.progress-overview-label {
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--brand-ink-soft);
}

.progress-shell {
  height: 0.65rem;
  border-radius: 999px;
  background: rgba(55, 180, 120, 0.14);
}

.progress-shell .progress-bar {
  border-radius: inherit;
}

#stepsList {
  border-color: rgba(18, 52, 78, 0.12) !important;
  border-radius: 0.95rem !important;
}

#stepsList .list-group-item {
  background-color: transparent;
  border-color: rgba(18, 52, 78, 0.07);
}

.step-line {
  min-height: 56px;
}

.step-main {
  display: flex;
  align-items: flex-start;
  gap: 0.64rem;
}

.step-bullet {
  margin-top: 0.18rem;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  background: rgba(18, 52, 78, 0.28);
  flex-shrink: 0;
}

.step-state-running .step-bullet {
  background: #0d6efd;
  box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

.step-state-completed .step-bullet {
  background: #198754;
}

.step-state-failed .step-bullet {
  background: #dc3545;
}

.step-message {
  font-size: 0.83rem;
}

#emptyState,
#traceEmptyState {
  border-color: rgba(18, 52, 78, 0.14) !important;
  border-radius: 0.95rem !important;
  background: rgba(255, 255, 255, 0.63);
}

.trace-heading {
  color: var(--brand-ink-soft);
}

.trace-list {
  max-height: 34rem;
  overflow-y: auto;
  padding-left: 0.15rem;
}

.trace-item {
  border-radius: 0.9rem !important;
  overflow: hidden;
  border: 1px solid rgba(18, 52, 78, 0.08) !important;
}

.trace-item summary {
  cursor: pointer;
  list-style: none;
  background: linear-gradient(100deg, rgba(15, 140, 116, 0.07), rgba(255, 255, 255, 0.38));
}

.trace-item summary::-webkit-details-marker {
  display: none;
}

.trace-title {
  font-size: 0.9rem;
}

.trace-content {
  max-height: 18rem;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 0.8rem;
  line-height: 1.45;
  background: rgba(18, 52, 78, 0.04);
}

.download-btn.btn-success {
  border-radius: 0.85rem;
  border: none;
  font-weight: 700;
  background: linear-gradient(132deg, #179f67 0%, #2dc67f 100%);
  box-shadow: 0 12px 24px rgba(23, 159, 103, 0.22);
}

.view-online-btn {
  border-radius: 0.85rem;
  font-weight: 700;
  border-color: rgba(55, 180, 120, 0.5);
  color: var(--brand-primary-strong);
}

.view-online-btn:hover,
.view-online-btn:focus-visible {
  background: rgba(55, 180, 120, 0.12);
  border-color: rgba(55, 180, 120, 0.62);
  color: var(--brand-primary-strong);
}

#errorArea {
  border-radius: 0.85rem;
}

.trace-list::-webkit-scrollbar,
.trace-content::-webkit-scrollbar {
  width: 0.56rem;
  height: 0.56rem;
}

.trace-list::-webkit-scrollbar-thumb,
.trace-content::-webkit-scrollbar-thumb {
  background: rgba(18, 52, 78, 0.22);
  border-radius: 999px;
}

[data-bs-theme="dark"] {
  --page-background: #050507;
  --surface: rgba(11, 11, 14, 0.88);
  --surface-border: rgba(55, 180, 120, 0.22);
  --brand-ink: #f0f2f4;
  --brand-ink-soft: #b0b5be;
  --shadow-soft: 0 24px 46px rgba(0, 0, 0, 0.35);
}

[data-bs-theme="dark"] body {
  background: radial-gradient(circle at 100% 0%, rgba(55, 180, 120, 0.17) 0%, transparent 40%),
    radial-gradient(circle at 0% 94%, rgba(255, 255, 255, 0.06) 0%, transparent 44%),
    #050507;
  color: var(--brand-ink);
}

[data-bs-theme="dark"] .hero-banner {
  background: linear-gradient(128deg, #000000 0%, #090a0d 58%, #173629 100%);
}

[data-bs-theme="dark"] .hero-chip {
  background: rgba(0, 0, 0, 0.17);
}

[data-bs-theme="dark"] .service-option-card {
  border-color: rgba(55, 180, 120, 0.24);
}

[data-bs-theme="dark"] .service-option-card:hover,
[data-bs-theme="dark"] .service-option-card:focus-visible {
  border-color: rgba(55, 180, 120, 0.42);
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.38);
}

[data-bs-theme="dark"] .service-pill.ready {
  background: rgba(55, 180, 120, 0.22);
  color: #9ddbbd;
}

[data-bs-theme="dark"] .service-pill.soon {
  background: rgba(154, 196, 209, 0.18);
  color: #c0dce7;
}

[data-bs-theme="dark"] .branded-control {
  background: rgba(8, 9, 11, 0.92);
  border-color: rgba(55, 180, 120, 0.28);
  color: #e8ebee;
}

[data-bs-theme="dark"] .branded-control::placeholder {
  color: rgba(200, 206, 214, 0.52);
}

[data-bs-theme="dark"] .add-interview-btn {
  border-color: rgba(55, 180, 120, 0.42);
  color: #b3dec6;
}

[data-bs-theme="dark"] .add-interview-btn:hover,
[data-bs-theme="dark"] .add-interview-btn:focus-visible,
[data-bs-theme="dark"] .add-interview-btn:active {
  background: rgba(55, 180, 120, 0.2) !important;
  color: #dcf4e8 !important;
}

[data-bs-theme="dark"] .interview-item {
  background: rgba(8, 8, 10, 0.68);
  border-color: rgba(55, 180, 120, 0.2);
}

[data-bs-theme="dark"] .progress-overview {
  border-color: rgba(55, 180, 120, 0.2);
  background: rgba(8, 8, 10, 0.7);
}

[data-bs-theme="dark"] .progress-overview-label {
  color: #b7c5bb;
}

[data-bs-theme="dark"] .progress-shell {
  background: rgba(55, 180, 120, 0.18);
}

[data-bs-theme="dark"] #stepsList .list-group-item {
  border-color: rgba(55, 180, 120, 0.2);
}

[data-bs-theme="dark"] .live-strip {
  background: rgba(55, 180, 120, 0.15);
  border-color: rgba(55, 180, 120, 0.32);
}

[data-bs-theme="dark"] .trace-item {
  border-color: rgba(55, 180, 120, 0.2) !important;
}

[data-bs-theme="dark"] .trace-item summary {
  background: linear-gradient(100deg, rgba(55, 180, 120, 0.24), rgba(5, 5, 7, 0.25));
}

[data-bs-theme="dark"] .trace-content {
  background: rgba(240, 242, 244, 0.08);
}

[data-bs-theme="dark"] .step-bullet {
  background: rgba(166, 211, 223, 0.38);
}

[data-bs-theme="dark"] .view-online-btn {
  border-color: rgba(55, 180, 120, 0.42);
  color: #b8e8ce;
}

[data-bs-theme="dark"] .view-online-btn:hover,
[data-bs-theme="dark"] .view-online-btn:focus-visible {
  background: rgba(55, 180, 120, 0.2);
  border-color: rgba(55, 180, 120, 0.52);
  color: #daf8ea;
}

[data-bs-theme="dark"] #emptyState,
[data-bs-theme="dark"] #traceEmptyState {
  background: rgba(8, 8, 10, 0.74);
  border-color: rgba(55, 180, 120, 0.24) !important;
}

[data-bs-theme="dark"] .trace-list::-webkit-scrollbar-thumb,
[data-bs-theme="dark"] .trace-content::-webkit-scrollbar-thumb {
  background: rgba(170, 178, 188, 0.36);
}

@media (min-width: 992px) {
  .hero-banner {
    padding: 1.8rem 2rem 1.9rem;
  }
}

@media (max-width: 767px) {
  .hero-banner {
    border-radius: 1.2rem;
    padding: 1.15rem 1rem 1.2rem;
  }

  .hero-chip {
    display: none;
  }

  .theme-btn {
    font-size: 0.78rem;
    padding: 0.45rem 0.62rem;
  }

  .service-card .card-body {
    padding: 1.1rem !important;
  }
}
