:root {
  color-scheme: light;
  --ink: #172218;
  --muted: #607064;
  --line: #dce5dc;
  --paper: #fffef9;
  --canvas: #eef4ec;
  --green: #2f6d45;
  --green-dark: #214f32;
  --green-soft: #dcebdd;
  --red: #a13b32;
  --shadow: 0 30px 80px rgba(33, 79, 50, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-width: 320px;
  background:
    radial-gradient(circle at 15% 12%, rgba(117, 167, 117, 0.24), transparent 30rem),
    radial-gradient(circle at 90% 85%, rgba(226, 188, 120, 0.18), transparent 28rem),
    var(--canvas);
  color: var(--ink);
  font-family:
    Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI",
    sans-serif;
}

button {
  font: inherit;
}

.page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 20px;
}

.card {
  width: min(820px, 100%);
  padding: clamp(32px, 7vw, 72px);
  overflow: hidden;
  position: relative;
  background: color-mix(in srgb, var(--paper) 95%, transparent);
  border: 1px solid rgba(47, 109, 69, 0.12);
  border-radius: 32px;
  box-shadow: var(--shadow);
}

.card::after {
  content: "";
  position: absolute;
  width: 240px;
  height: 240px;
  right: -100px;
  top: -120px;
  border-radius: 50%;
  background: var(--green-soft);
  opacity: 0.7;
  pointer-events: none;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.1rem;
  font-weight: 750;
  letter-spacing: -0.02em;
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--green);
  color: white;
  font-family: Georgia, serif;
  font-size: 1.35rem;
  font-style: italic;
}

.eyebrow {
  margin: 72px 0 14px;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1 {
  max-width: 700px;
  margin: 0;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3rem, 8vw, 6.1rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.93;
}

.summary {
  max-width: 670px;
  margin: 28px 0 0;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.75;
}

.status-card {
  margin-top: 44px;
  padding: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.58);
}

.status-title {
  margin: 0 0 5px;
  font-weight: 750;
}

.status-copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.5;
}

#test-api {
  flex: 0 0 auto;
  min-height: 46px;
  padding: 0 20px;
  border: 0;
  border-radius: 999px;
  background: var(--green);
  color: white;
  cursor: pointer;
  font-weight: 750;
  transition:
    background 160ms ease,
    transform 160ms ease;
}

#test-api:hover {
  background: var(--green-dark);
  transform: translateY(-1px);
}

#test-api:focus-visible {
  outline: 3px solid rgba(47, 109, 69, 0.28);
  outline-offset: 3px;
}

#test-api:disabled {
  cursor: wait;
  opacity: 0.72;
  transform: none;
}

.result {
  min-height: 24px;
  margin: 16px 4px 0;
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--muted);
  font-size: 0.93rem;
}

.result-dot {
  width: 9px;
  height: 9px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #a9b4aa;
}

.result-loading .result-dot {
  animation: pulse 800ms ease-in-out infinite alternate;
  background: #c58b31;
}

.result-success {
  color: var(--green-dark);
}

.result-success .result-dot {
  background: #36a15d;
  box-shadow: 0 0 0 5px rgba(54, 161, 93, 0.12);
}

.result-error {
  color: var(--red);
}

.result-error .result-dot {
  background: var(--red);
}

.footnote {
  margin: 54px 0 0;
  color: var(--muted);
  font-size: 0.88rem;
}

@keyframes pulse {
  to {
    opacity: 0.35;
  }
}

@media (max-width: 620px) {
  .page {
    padding: 16px;
  }

  .card {
    padding: 28px 22px;
    border-radius: 24px;
  }

  .eyebrow {
    margin-top: 54px;
  }

  .status-card {
    align-items: stretch;
    flex-direction: column;
  }

  #test-api {
    width: 100%;
  }
}

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