:root {
  --eh-bg: #f6f7ff;
  --eh-bg-accent: rgba(70, 72, 212, 0.10);
  --eh-surface: #ffffff;
  --eh-surface-soft: #f7f8ff;
  --eh-line: rgba(25, 28, 30, 0.12);
  --eh-line-strong: rgba(25, 28, 30, 0.20);
  --eh-text: #191c1e;
  --eh-muted: #5d6070;
  --eh-primary: #4648d4;
  --eh-primary-soft: #eceeff;
  --eh-on-primary: #ffffff;
  --eh-focus: rgba(70, 72, 212, 0.28);
  --eh-success: #176b3a;
  --eh-radius: 20px;
}

:root[data-theme="dark"] {
  --eh-bg: #0b0d18;
  --eh-bg-accent: rgba(137, 140, 255, 0.12);
  --eh-surface: #141824;
  --eh-surface-soft: #191e2c;
  --eh-line: rgba(255, 255, 255, 0.12);
  --eh-line-strong: rgba(255, 255, 255, 0.22);
  --eh-text: #eef1ff;
  --eh-muted: #b4bbd3;
  --eh-primary: #b9bbff;
  --eh-primary-soft: #262b4a;
  --eh-on-primary: #161832;
  --eh-focus: rgba(185, 187, 255, 0.34);
  --eh-success: #9fe6b8;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--eh-bg);
}

body.eh-page {
  margin: 0;
  min-height: 100vh;
  color: var(--eh-text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background:
    radial-gradient(circle at 12% 0%, var(--eh-bg-accent), transparent 34rem),
    radial-gradient(circle at 92% 18%, var(--eh-bg-accent), transparent 30rem),
    var(--eh-bg);
  -webkit-font-smoothing: antialiased;
}

body.eh-page a {
  color: var(--eh-primary);
}

.eh-skip {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--eh-surface);
  color: var(--eh-text);
  transform: translateY(-160%);
  transition: transform 120ms ease;
}

.eh-skip:focus {
  transform: translateY(0);
  outline: 3px solid var(--eh-focus);
}

.eh-topbar {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 22px 0 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.eh-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--eh-text) !important;
  font-weight: 760;
  letter-spacing: -0.02em;
  text-decoration: none;
}

.eh-brand-mark {
  width: 34px;
  height: 34px;
  display: inline-grid;
  place-items: center;
  border-radius: 11px;
  color: #fff;
  background: linear-gradient(145deg, #6c6fff, #3b3dc6);
  box-shadow: 0 8px 20px rgba(70, 72, 212, 0.30);
}

.eh-top-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.eh-lang-wrap {
  display: inline-flex;
  align-items: center;
}

.eh-lang {
  min-height: 38px;
  max-width: 150px;
  padding: 0 30px 0 12px;
  border: 1px solid var(--eh-line);
  border-radius: 10px;
  background: var(--eh-surface);
  color: var(--eh-text);
  font: inherit;
  font-size: 13px;
}

.eh-top-link {
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.eh-main {
  width: min(1120px, calc(100% - 40px));
  margin: 0 auto;
  padding: 44px 0 54px;
}

.eh-intro {
  max-width: 760px;
  margin-bottom: 30px;
}

.eh-kicker {
  margin: 0 0 10px;
  color: var(--eh-primary);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.eh-intro h1 {
  margin: 0;
  font-size: clamp(34px, 5.2vw, 58px);
  line-height: 1.03;
  letter-spacing: -0.045em;
}

.eh-sub {
  max-width: 680px;
  margin: 16px 0 0;
  color: var(--eh-muted);
  font-size: 17px;
  line-height: 1.65;
}

.eh-query-card,
.eh-result-card,
.eh-support-card,
.eh-note-card {
  background: color-mix(in srgb, var(--eh-surface) 93%, transparent);
  border: 1px solid var(--eh-line);
  border-radius: var(--eh-radius);
  box-shadow: 0 18px 50px rgba(20, 24, 40, 0.08);
}

.eh-query-card {
  padding: 24px;
}

.eh-query-card h2,
.eh-result-card h2,
.eh-support-card h2,
.eh-note-card h2 {
  margin: 0;
  font-size: 19px;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.eh-query-form {
  margin-top: 14px;
}

.eh-field-label {
  display: block;
  margin-bottom: 8px;
  color: var(--eh-muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.eh-query-row {
  display: flex;
  gap: 10px;
}

.eh-input,
.eh-textarea {
  width: 100%;
  border: 1px solid var(--eh-line-strong);
  border-radius: 12px;
  background: var(--eh-surface-soft);
  color: var(--eh-text);
  font: inherit;
  font-size: 16px;
  outline: none;
  transition: border-color 120ms ease, box-shadow 120ms ease, background 120ms ease;
}

.eh-input {
  min-height: 48px;
  padding: 0 14px;
}

.eh-textarea {
  min-height: 128px;
  padding: 12px 14px;
  resize: vertical;
  line-height: 1.55;
}

.eh-input:focus,
.eh-textarea:focus,
.eh-lang:focus,
.eh-btn:focus-visible,
.eh-top-link:focus-visible,
.eh-text-link:focus-visible,
.eh-brand:focus-visible {
  border-color: var(--eh-primary);
  box-shadow: 0 0 0 3px var(--eh-focus);
  outline: none;
}

.eh-input::placeholder,
.eh-textarea::placeholder {
  color: var(--eh-muted);
  opacity: 0.8;
}

.eh-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 11px;
  font: inherit;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.2;
  cursor: pointer;
  text-decoration: none;
  transition: transform 120ms ease, background 120ms ease, border-color 120ms ease;
}

.eh-btn:active {
  transform: translateY(1px);
}

body.eh-page a.eh-btn-primary,
.eh-btn-primary {
  background: var(--eh-primary);
  color: var(--eh-on-primary);
}

body.eh-page a.eh-btn {
  text-decoration: none;
}

.eh-btn-primary:hover {
  filter: brightness(0.96);
}

.eh-btn-quiet {
  background: var(--eh-primary-soft);
  color: var(--eh-primary);
  border-color: transparent;
  white-space: nowrap;
}

.eh-btn-quiet:hover {
  border-color: var(--eh-primary);
}

.eh-btn:disabled {
  cursor: wait;
  opacity: 0.68;
}

.eh-hint {
  margin: 12px 0 0;
  color: var(--eh-muted);
  font-size: 12.5px;
  line-height: 1.55;
}

.eh-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.8fr);
  gap: 20px;
  margin-top: 20px;
  align-items: start;
}

.eh-result-card {
  padding: 26px;
  min-width: 0;
}

.eh-result-head {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--eh-line);
}

.eh-result-icon {
  flex: 0 0 42px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  background: var(--eh-primary-soft);
  color: var(--eh-primary);
  font-size: 20px;
  font-weight: 800;
}

.eh-result-head .eh-kicker {
  margin-bottom: 4px;
}

.eh-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  margin: 18px 0;
}

.eh-meta div {
  min-width: 0;
}

.eh-meta dt,
.eh-meta .eh-meta-label {
  margin: 0 0 4px;
  color: var(--eh-muted);
  font-size: 11px;
  font-weight: 750;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.eh-meta dd,
.eh-meta .eh-area {
  margin: 0;
}

.eh-meta code {
  display: inline-block;
  max-width: 100%;
  overflow-wrap: anywhere;
  padding: 5px 8px;
  border-radius: 7px;
  background: var(--eh-surface-soft);
  border: 1px solid var(--eh-line);
  color: var(--eh-text);
  font-family: 'JetBrains Mono', 'SFMono-Regular', Consolas, monospace;
  font-size: 12.5px;
}

.eh-summary {
  margin: 0 0 20px;
  font-size: 16px;
  line-height: 1.65;
}

.eh-steps-title {
  margin: 0 0 10px;
  font-size: 13px;
  letter-spacing: 0.01em;
}

.eh-steps {
  margin: 0 0 22px;
  padding-left: 20px;
  color: var(--eh-text);
}

.eh-steps li {
  margin: 0 0 8px;
  padding-left: 4px;
  line-height: 1.55;
}

.eh-steps li:last-child {
  margin-bottom: 0;
}

.eh-action-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--eh-line);
}

.eh-action-row p {
  margin: 0;
  color: var(--eh-muted);
  font-size: 13.5px;
  line-height: 1.55;
}

.eh-action-label {
  display: block;
  margin-bottom: 3px;
  color: var(--eh-text);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.eh-copy-status {
  min-height: 1.3em;
  margin: 10px 0 0;
  color: var(--eh-success);
  font-size: 12.5px;
}

.eh-side {
  display: grid;
  gap: 20px;
  min-width: 0;
}

.eh-support-card,
.eh-note-card {
  padding: 22px;
}

.eh-support-copy,
.eh-note-card p {
  margin: 12px 0 16px;
  color: var(--eh-muted);
  font-size: 13.5px;
  line-height: 1.6;
}

.eh-signin {
  width: 100%;
}

.eh-support-form {
  margin-top: 14px;
}

.eh-support-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-top: 12px;
}

.eh-support-actions .eh-copy-status {
  margin: 0;
}

.eh-note-card {
  background: color-mix(in srgb, var(--eh-surface-soft) 78%, transparent);
}

.eh-text-link,
.eh-footer a {
  font-size: 13px;
  font-weight: 650;
  text-decoration: none;
}

.eh-text-link:hover,
.eh-footer a:hover,
.eh-top-link:hover {
  text-decoration: underline;
}

.eh-footer {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 34px 0 0;
  color: var(--eh-muted);
  font-size: 12px;
}

.eh-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

[hidden] {
  display: none !important;
}

@media (max-width: 820px) {
  .eh-layout {
    grid-template-columns: minmax(0, 1fr);
  }

  .eh-main {
    padding-top: 28px;
  }

  .eh-intro {
    margin-bottom: 24px;
  }
}

@media (max-width: 560px) {
  .eh-topbar,
  .eh-main {
    width: min(100% - 28px, 1120px);
  }

  .eh-topbar {
    padding-top: 16px;
    align-items: flex-start;
  }

  .eh-top-actions {
    gap: 8px;
  }

  .eh-top-link {
    display: none;
  }

  .eh-lang {
    max-width: 126px;
  }

  .eh-query-card,
  .eh-result-card,
  .eh-support-card,
  .eh-note-card {
    padding: 18px;
    border-radius: 16px;
  }

  .eh-query-row {
    flex-direction: column;
  }

  .eh-query-row .eh-btn {
    width: 100%;
  }

  .eh-action-row {
    flex-direction: column;
  }

  .eh-action-row .eh-btn {
    width: 100%;
  }

  .eh-meta {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.001ms !important;
  }
}
