:root {
  color-scheme: light;
  --sm-bg: #f5f1e9;
  --sm-surface: rgba(255, 252, 246, 0.92);
  --sm-surface-strong: #fffaf2;
  --sm-ink: #191816;
  --sm-muted: #635d54;
  --sm-line: rgba(38, 31, 23, 0.12);
  --sm-accent: #d36f3f;
  --sm-accent-deep: #863a1a;
  --sm-blue: #0c4f6e;
  --sm-green: #277154;
  --sm-shadow: 0 18px 44px rgba(56, 41, 25, 0.11);
}

* {
  box-sizing: border-box;
}

.smartmatch-page {
  margin: 0;
  min-height: 100vh;
  font-family: Inter, "Segoe UI", Arial, sans-serif;
  color: var(--sm-ink);
  background:
    linear-gradient(115deg, rgba(211, 111, 63, 0.12), transparent 34%),
    linear-gradient(245deg, rgba(12, 79, 110, 0.12), transparent 38%),
    var(--sm-bg);
}

.smartmatch-page a {
  color: inherit;
}

.smartmatch-page .page-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 28px 0 48px;
}

.smartmatch-page .topbar,
.smartmatch-page .hero,
.smartmatch-page .panel,
.smartmatch-page .site-footer {
  margin-bottom: 22px;
}

.smartmatch-page .topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}

.smartmatch-page .logo-block {
  display: flex;
  align-items: center;
  gap: 12px;
}

.smartmatch-page .logo-mark {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  object-fit: contain;
  background: #fff;
  border: 1px solid var(--sm-line);
}

.smartmatch-page .logo-title {
  font-size: 1.1rem;
  font-weight: 850;
}

.smartmatch-page .eyebrow {
  margin: 0 0 10px;
  color: var(--sm-accent-deep);
  font-size: 0.78rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.smartmatch-page .language-switcher,
.smartmatch-page .language-modal__actions,
.smartmatch-page .panel-actions,
.smartmatch-page .hero-actions,
.smartmatch-page .rating-row,
.smartmatch-page .contact-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.smartmatch-page .language-switcher button,
.smartmatch-page .ghost-button,
.smartmatch-page .primary-button,
.smartmatch-page .rating-button {
  min-height: 44px;
  border-radius: 999px;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.smartmatch-page .language-switcher button {
  min-width: 48px;
  border: 1px solid var(--sm-line);
  background: rgba(255, 255, 255, 0.72);
  color: var(--sm-muted);
}

.smartmatch-page .language-switcher button.is-active {
  background: var(--sm-ink);
  color: #fff;
}

.smartmatch-page .hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(280px, 0.75fr);
  gap: 22px;
}

.smartmatch-page .hero-card,
.smartmatch-page .summary-card,
.smartmatch-page .panel,
.smartmatch-page .site-footer {
  background: var(--sm-surface);
  border: 1px solid var(--sm-line);
  border-radius: 22px;
  box-shadow: var(--sm-shadow);
}

.smartmatch-page .hero-card,
.smartmatch-page .summary-card,
.smartmatch-page .panel {
  padding: 28px;
}

.smartmatch-page h1,
.smartmatch-page h2,
.smartmatch-page h3,
.smartmatch-page p {
  overflow-wrap: anywhere;
}

.smartmatch-page h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(2.35rem, 6vw, 4.7rem);
  line-height: 0.98;
  letter-spacing: 0;
}

.smartmatch-page h2 {
  margin: 0;
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  line-height: 1.08;
  letter-spacing: 0;
}

.smartmatch-page h3 {
  margin: 0;
  line-height: 1.15;
}

.smartmatch-page .hero-card p,
.smartmatch-page .panel-header p,
.smartmatch-page .summary-list,
.smartmatch-page .site-footer p,
.smartmatch-page .result-block li {
  color: var(--sm-muted);
  line-height: 1.65;
}

.smartmatch-page .hero-card p {
  max-width: 68ch;
  margin: 18px 0 0;
  font-size: 1.06rem;
}

.smartmatch-page .hero-actions,
.smartmatch-page .panel-actions {
  margin-top: 22px;
  align-items: center;
}

.smartmatch-page .primary-button,
.smartmatch-page .ghost-button,
.smartmatch-page .rating-button {
  border: 1px solid var(--sm-line);
  padding: 12px 18px;
}

.smartmatch-page .primary-button {
  background: var(--sm-ink);
  color: #fff;
  box-shadow: 0 12px 24px rgba(25, 24, 22, 0.16);
}

.smartmatch-page .ghost-button,
.smartmatch-page .rating-button {
  background: #fff;
  color: var(--sm-ink);
}

.smartmatch-page .primary-button:disabled,
.smartmatch-page .ghost-button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.smartmatch-page .summary-card h2 {
  margin-bottom: 14px;
}

.smartmatch-page .summary-list {
  margin: 0;
  padding-left: 20px;
}

.smartmatch-page .summary-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 20px;
}

.smartmatch-page .stat {
  min-width: 0;
  padding: 12px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--sm-line);
}

.smartmatch-page .stat strong,
.smartmatch-page .stat span {
  display: block;
}

.smartmatch-page .stat strong {
  font-size: 1.2rem;
}

.smartmatch-page .stat span {
  color: var(--sm-muted);
  font-size: 0.86rem;
  line-height: 1.3;
}

.smartmatch-page .panel-header {
  margin-bottom: 20px;
}

.smartmatch-page .progress-bar {
  height: 10px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(38, 31, 23, 0.08);
  margin-bottom: 18px;
}

.smartmatch-page .progress-bar span {
  display: block;
  height: 100%;
  width: 0;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--sm-accent), var(--sm-blue));
  transition: width 180ms ease;
}

.smartmatch-page .progress-step-1 span {
  width: 12.5%;
}

.smartmatch-page .progress-step-2 span {
  width: 25%;
}

.smartmatch-page .progress-step-3 span {
  width: 37.5%;
}

.smartmatch-page .progress-step-4 span {
  width: 50%;
}

.smartmatch-page .progress-step-5 span {
  width: 62.5%;
}

.smartmatch-page .progress-step-6 span {
  width: 75%;
}

.smartmatch-page .progress-step-7 span {
  width: 87.5%;
}

.smartmatch-page .progress-step-8 span {
  width: 100%;
}

.smartmatch-page .question-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.smartmatch-page .question-card {
  min-height: 92px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--sm-line);
  border-radius: 18px;
  background: #fff;
  color: var(--sm-ink);
  text-align: left;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}

.smartmatch-page .question-card:hover,
.smartmatch-page .rating-button:hover,
.smartmatch-page .ghost-button:hover {
  border-color: rgba(211, 111, 63, 0.42);
}

.smartmatch-page .question-card.is-active,
.smartmatch-page .rating-button.is-active {
  background: #fff1e6;
  border-color: rgba(211, 111, 63, 0.62);
}

.smartmatch-page .question-card small {
  flex: none;
  color: var(--sm-accent-deep);
  font-size: 0.78rem;
}

.smartmatch-page .results-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.smartmatch-page .result-card {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 20px;
  border: 1px solid var(--sm-line);
  border-radius: 20px;
  background: var(--sm-surface-strong);
}

.smartmatch-page .result-card__top,
.smartmatch-page .result-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.smartmatch-page .result-card__top {
  justify-content: space-between;
  align-items: center;
}

.smartmatch-page .result-badge,
.smartmatch-page .score-pill,
.smartmatch-page .strength-pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 7px 10px;
  font-size: 0.8rem;
  font-weight: 850;
}

.smartmatch-page .result-badge {
  background: rgba(39, 113, 84, 0.12);
  color: var(--sm-green);
}

.smartmatch-page .score-pill,
.smartmatch-page .strength-pill {
  background: #fff;
  color: var(--sm-accent-deep);
  border: 1px solid var(--sm-line);
}

.smartmatch-page .result-meta__item {
  flex: 1 1 120px;
  padding: 10px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid var(--sm-line);
}

.smartmatch-page .result-meta__item strong,
.smartmatch-page .result-meta__item span {
  display: block;
}

.smartmatch-page .result-meta__item strong,
.smartmatch-page .result-block strong {
  margin-bottom: 5px;
  color: var(--sm-accent-deep);
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.smartmatch-page .result-block ul {
  margin: 8px 0 0;
  padding-left: 18px;
}

.smartmatch-page .strength-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.smartmatch-page .result-link {
  margin-top: auto;
  color: var(--sm-blue);
  font-weight: 850;
  text-decoration: none;
}

.smartmatch-page .form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.smartmatch-page .field {
  display: grid;
  gap: 8px;
  color: var(--sm-muted);
  font-weight: 800;
}

.smartmatch-page .field--full {
  grid-column: 1 / -1;
}

.smartmatch-page input,
.smartmatch-page textarea {
  width: 100%;
  border: 1px solid var(--sm-line);
  border-radius: 16px;
  background: #fff;
  color: var(--sm-ink);
  font: inherit;
  padding: 13px 14px;
}

.smartmatch-page textarea {
  resize: vertical;
}

.smartmatch-page .form-note {
  margin: 16px 0 0;
  font-weight: 800;
}

.smartmatch-page .form-note.is-success {
  color: var(--sm-green);
}

.smartmatch-page .form-note.is-error {
  color: #a83737;
}

.smartmatch-page .contact-links-wrap {
  margin-top: 22px;
}

.smartmatch-page .contact-links-wrap h3 {
  margin-bottom: 12px;
}

.smartmatch-page .site-footer {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.8fr;
  gap: 18px;
  padding: 24px;
}

.smartmatch-page .site-footer p {
  margin: 8px 0 0;
}

.smartmatch-page .language-modal {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(25, 24, 22, 0.4);
}

.smartmatch-page .language-modal[hidden] {
  display: none;
}

.smartmatch-page .language-modal__card {
  width: min(460px, 100%);
  padding: 24px;
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--sm-shadow);
}

@media (max-width: 900px) {
  .smartmatch-page .hero,
  .smartmatch-page .results-grid,
  .smartmatch-page .site-footer {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .smartmatch-page .page-shell {
    width: min(100% - 20px, 100%);
    padding-top: 18px;
  }

  .smartmatch-page .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .smartmatch-page .hero-card,
  .smartmatch-page .summary-card,
  .smartmatch-page .panel {
    padding: 20px;
    border-radius: 18px;
  }

  .smartmatch-page .question-grid,
  .smartmatch-page .summary-stats,
  .smartmatch-page .form-grid {
    grid-template-columns: 1fr;
  }

  .smartmatch-page .field--full {
    grid-column: auto;
  }
}
