:root {
  color: #17202a;
  font-family: Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  background: #f4f7f8;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
}

a {
  color: inherit;
}

button,
input,
select,
textarea {
  font: inherit;
}

.shell {
  width: min(1120px, calc(100vw - 32px));
  margin: 0 auto;
  padding: 28px 0;
}

.landing-page {
  min-height: 100vh;
  background:
    linear-gradient(120deg, rgba(13, 55, 49, 0.97), rgba(28, 48, 43, 0.95)),
    #122129;
  color: #f6fbfa;
  padding: 22px;
}

.landing-nav {
  align-items: center;
  display: flex;
  justify-content: space-between;
  margin: 0 auto;
  max-width: 1180px;
}

.landing-nav strong {
  display: block;
  font-size: 18px;
}

.landing-hero {
  align-items: center;
  display: grid;
  gap: 36px;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  margin: 64px auto 28px;
  max-width: 1180px;
}

.hero-copy h1 {
  font-size: clamp(34px, 5vw, 62px);
  line-height: 1.08;
  max-width: 820px;
}

.hero-copy p {
  color: #d9e8e5;
  font-size: 18px;
  line-height: 1.75;
  max-width: 760px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.link-button {
  display: inline-block;
  text-decoration: none;
}

.insight-panel {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 8px;
  padding: 24px;
}

.landing-match-image {
  aspect-ratio: 16 / 9;
  border: 1px solid rgba(255, 255, 255, 0.34);
  border-radius: 8px;
  display: block;
  margin-bottom: 20px;
  object-fit: cover;
  width: 100%;
}

.insight-panel h2 {
  color: #ffffff;
}

.insight-panel ul {
  display: grid;
  gap: 14px;
  line-height: 1.7;
  margin: 16px 0 0;
  padding-left: 20px;
}

.landing-steps {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 32px auto 0;
  max-width: 1180px;
}

.landing-steps article {
  background: rgba(255, 255, 255, 0.94);
  border-radius: 8px;
  color: #17202a;
  padding: 20px;
}

.landing-steps span {
  color: #1f7a68;
  font-weight: 700;
}

.landing-steps h3 {
  margin: 10px 0 8px;
}

.landing-steps p {
  color: #53636a;
  line-height: 1.6;
  margin: 0;
}

.project-card {
  display: grid;
  gap: 12px;
  align-content: start;
}

.project-card .project-select {
  justify-self: start;
  margin-top: 4px;
}

.panel {
  background: #ffffff;
  border: 1px solid #dce5e8;
  border-radius: 8px;
  padding: 22px;
  margin-bottom: 16px;
}

.intro {
  border-top: 5px solid #1f7a68;
}

.eyebrow {
  color: #1f7a68;
  font-weight: 700;
  margin: 0 0 6px;
}

h1,
h2 {
  margin: 0 0 12px;
}

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

label {
  display: grid;
  gap: 7px;
  font-weight: 700;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #b9c8cd;
  border-radius: 6px;
  padding: 11px 12px;
  background: #ffffff;
}

textarea {
  min-height: 88px;
  resize: vertical;
}

.primary,
.start-trial {
  border: 0;
  border-radius: 6px;
  background: #1f7a68;
  color: #ffffff;
  padding: 13px 18px;
  font-weight: 700;
  cursor: pointer;
}

.secondary,
.small-button,
.danger-button {
  border: 1px solid #9eb1b8;
  border-radius: 6px;
  background: #ffffff;
  color: #17202a;
  padding: 11px 14px;
  font-weight: 700;
  cursor: pointer;
}

.small-button {
  padding: 7px 10px;
}

.danger-button {
  border-color: #c55f55;
  color: #9b271c;
  padding: 7px 10px;
}

.danger-button:hover {
  background: #fde8e5;
}

.muted {
  color: #53636a;
}

.test-shell {
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  background: #101820;
  color: #ffffff;
}

.topbar {
  display: flex;
  justify-content: space-between;
  padding: 12px 18px;
  background: #17202a;
  font-weight: 700;
}

.stimulus-card {
  display: grid;
  place-items: center;
  padding: 14px;
}

.stimulus-card img {
  width: min(100%, 1180px);
  max-height: 72vh;
  object-fit: contain;
  border: 1px solid #3c4c55;
  background: #000000;
}

.stimulus-video {
  width: min(100%, 1180px);
  max-height: 72vh;
  object-fit: contain;
  border: 1px solid #3c4c55;
  background: #000000;
}

.options {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 14px;
  background: #17202a;
}

.options button {
  min-height: 62px;
  border: 1px solid #5e747e;
  border-radius: 8px;
  padding: 12px;
  text-align: left;
  background: #ffffff;
  color: #17202a;
  cursor: pointer;
}

.admin-shell {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  min-height: 100vh;
}

.admin-shell aside {
  background: #17202a;
  color: #ffffff;
  padding: 20px;
}

.admin-shell aside a {
  display: block;
  padding: 10px 0;
  color: #dce5e8;
}

.nav-link {
  width: 100%;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #dce5e8;
  display: block;
  margin: 6px 0;
  padding: 10px 12px;
  text-align: left;
  cursor: pointer;
}

.nav-link:hover,
.nav-link.active {
  background: #24414c;
  color: #ffffff;
}

.admin-main {
  padding: 28px;
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.admin-form {
  background: #ffffff;
  border: 1px solid #dce5e8;
  border-radius: 8px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 16px 0 22px;
  padding: 16px;
}

.admin-form.inline-form {
  grid-template-columns: repeat(4, minmax(0, 1fr)) auto;
  align-items: end;
}

.admin-form.question-form {
  margin-top: 0;
}

.compact-form {
  align-items: end;
}

.full-span {
  grid-column: 1 / -1;
}

.check-row {
  align-items: center;
  display: flex;
  gap: 10px;
  min-height: 44px;
}

.check-row input {
  width: auto;
}

.status-line {
  color: #8a3b12;
  font-weight: 700;
  margin: 8px 0 14px;
}

.data-toolbar {
  align-items: center;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  margin: 10px 0 16px;
}

.table-scroll {
  overflow-x: auto;
  margin-bottom: 22px;
}

.selected-row td {
  background: #edf8f4;
}

.result-correct,
.result-wrong,
.result-timeout {
  border-radius: 999px;
  display: inline-block;
  font-weight: 700;
  min-width: 46px;
  padding: 4px 8px;
  text-align: center;
}

.result-correct {
  background: #e4f5ea;
  color: #17613a;
}

.result-wrong {
  background: #fde8e5;
  color: #9b271c;
}

.result-timeout {
  background: #fff2d6;
  color: #7a4b00;
}

.split-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: start;
}

.split-grid.wide-left {
  grid-template-columns: minmax(0, 1.25fr) minmax(360px, 0.75fr);
}

.thumb {
  width: 96px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border: 1px solid #dce5e8;
  border-radius: 4px;
  background: #eaf2f4;
}

.url-cell {
  max-width: 220px;
  overflow-wrap: anywhere;
}

.metrics div {
  background: #ffffff;
  border: 1px solid #dce5e8;
  border-radius: 8px;
  padding: 16px;
}

.metrics strong {
  display: block;
  font-size: 24px;
}

.metrics span {
  color: #5c6d73;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: #ffffff;
  font-size: 14px;
}

th,
td {
  border: 1px solid #dce5e8;
  padding: 10px;
  text-align: left;
}

  th {
    background: #eaf2f4;
}

@media (max-width: 760px) {
  .form-grid,
  .options,
  .metrics,
  .landing-hero,
  .landing-steps,
  .admin-shell,
  .admin-form,
  .admin-form.inline-form,
  .split-grid,
  .split-grid.wide-left {
    grid-template-columns: 1fr;
  }

  .admin-shell aside {
    position: static;
  }

  .data-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .stimulus-card img,
  .stimulus-video {
    max-height: 60vh;
  }

  .landing-nav {
    gap: 12px;
  }

  .landing-nav .primary {
    padding: 11px 12px;
  }
}
