/* Modern /services specialty picker — aligned with marketplace / advice filters */
.sp-page {
  --sp-ink: #121218;
  --sp-text: #1c1c24;
  --sp-muted: #6b7280;
  --sp-line: rgba(18, 18, 24, 0.1);
  --sp-soft: #f4f4f7;
  --sp-surface: #ffffff;
  --sp-accent: #840484;
  --sp-accent-soft: rgba(132, 4, 132, 0.1);
  --sp-radius: 18px;
  --sp-shadow: 0 18px 40px rgba(10, 10, 18, 0.1);
  background: #ececf1;
  color: var(--sp-text);
  font-family: IRANSans, Tahoma, sans-serif;
  min-height: 70vh;
  padding: 28px 16px 56px;
}

.sp-shell {
  background: var(--sp-surface);
  border: 1px solid var(--sp-line);
  border-radius: 24px;
  box-shadow: var(--sp-shadow);
  margin: 0 auto;
  max-width: 860px;
  overflow: hidden;
}

.sp-head {
  background:
    radial-gradient(circle at 90% 0%, rgba(192, 32, 104, 0.18), transparent 42%),
    linear-gradient(165deg, #1a1224 0%, #121218 100%);
  color: #f7f5fb;
  padding: 28px 22px 24px;
}

.sp-eyebrow {
  color: rgba(255, 255, 255, 0.7);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
  margin: 0 0 10px;
}

.sp-title {
  font-size: clamp(22px, 4vw, 30px);
  font-weight: 800;
  line-height: 1.4;
  margin: 0 0 8px;
}

.sp-desc {
  color: rgba(255, 255, 255, 0.72);
  font-size: 14px;
  line-height: 1.8;
  margin: 0;
  max-width: 36em;
}

.sp-body {
  padding: 18px 18px 22px;
}

.sp-search {
  position: relative;
  margin-bottom: 14px;
}

.sp-search__icon {
  color: var(--sp-muted);
  pointer-events: none;
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
}

.sp-search__input {
  width: 100%;
  height: 52px;
  border: 1px solid var(--sp-line);
  border-radius: 14px;
  background: var(--sp-soft);
  padding: 0 46px 0 44px;
  font-size: 14px;
  color: var(--sp-text);
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.sp-search__input:focus {
  background: #fff;
  border-color: var(--sp-accent);
  box-shadow: 0 0 0 3px var(--sp-accent-soft);
}

.sp-search__clear {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 999px;
  background: #e8e8ee;
  color: var(--sp-ink);
  cursor: pointer;
  line-height: 1;
  font-size: 16px;
}

.sp-search__clear[hidden] {
  display: none !important;
}

.sp-crumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-bottom: 14px;
  min-height: 28px;
}

.sp-crumb {
  border: 0;
  background: transparent;
  color: var(--sp-accent);
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  padding: 0;
}

.sp-crumb:disabled {
  color: var(--sp-muted);
  cursor: default;
  font-weight: 600;
}

.sp-crumb-sep {
  color: var(--sp-muted);
  font-size: 12px;
}

.sp-meta {
  color: var(--sp-muted);
  font-size: 12px;
  margin: 0 0 12px;
}

.sp-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 640px) {
  .sp-grid {
    grid-template-columns: 1fr;
  }
}

.sp-card {
  appearance: none;
  border: 1px solid var(--sp-line);
  border-radius: 14px;
  background: #fff;
  color: inherit;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 14px;
  text-align: right;
  transition: border-color 160ms ease, box-shadow 160ms ease, transform 160ms ease, background 160ms ease;
  width: 100%;
}

.sp-card:hover,
.sp-card:focus {
  border-color: #d8cce6;
  box-shadow: 0 10px 24px rgba(10, 10, 18, 0.08);
  transform: translateY(-1px);
  outline: none;
}

.sp-card.is-active {
  background: var(--sp-accent-soft);
  border-color: #c9add8;
}

.sp-card__title {
  font-size: 14px;
  font-weight: 800;
  color: var(--sp-ink);
  line-height: 1.5;
}

.sp-card__meta {
  color: var(--sp-muted);
  font-size: 11px;
  margin-top: 4px;
}

.sp-card__chev {
  color: var(--sp-muted);
  flex: 0 0 auto;
  font-size: 18px;
  line-height: 1;
}

.sp-subjects {
  display: grid;
  gap: 8px;
  margin-top: 8px;
}

.sp-subject {
  display: block;
  border: 1px solid var(--sp-line);
  border-radius: 12px;
  background: var(--sp-soft);
  color: var(--sp-ink) !important;
  font-size: 13px;
  font-weight: 700;
  padding: 12px 14px;
  text-decoration: none !important;
  transition: background 140ms ease, border-color 140ms ease;
}

.sp-subject:hover {
  background: #fff;
  border-color: #d8cce6;
}

.sp-empty {
  border: 1px dashed var(--sp-line);
  border-radius: 14px;
  color: var(--sp-muted);
  font-size: 13px;
  padding: 28px 16px;
  text-align: center;
}

.sp-actions {
  display: flex;
  justify-content: flex-start;
  margin-top: 16px;
}

.sp-btn {
  border: 0;
  border-radius: 14px;
  background: var(--sp-ink);
  color: #fff;
  cursor: pointer;
  font-size: 14px;
  font-weight: 800;
  min-height: 48px;
  padding: 12px 20px;
  transition: transform 160ms ease, opacity 160ms ease;
}

.sp-btn:hover {
  transform: translateY(-1px);
}

.sp-btn:disabled {
  cursor: not-allowed;
  opacity: 0.45;
  transform: none;
}

.sp-legacy {
  display: none;
}
