:root {
  --bg: #f4efe4;
  --surface: rgba(255, 255, 255, 0.72);
  --text: #1f1f1f;
  --accent: #0f7b6c;
  --accent-2: #da4f2f;
  --border: rgba(31, 31, 31, 0.14);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 15% 15%, #f8d8b4 0%, transparent 33%),
    radial-gradient(circle at 85% 85%, #c6e9e2 0%, transparent 35%),
    var(--bg);
  position: relative;
  overflow-x: hidden;
}

.bg-shape {
  position: fixed;
  border-radius: 999px;
  filter: blur(50px);
  opacity: 0.35;
  pointer-events: none;
}

.bg-a {
  width: 320px;
  height: 320px;
  background: #ff8f5a;
  top: -80px;
  right: -100px;
}

.bg-b {
  width: 320px;
  height: 320px;
  background: #39a99d;
  bottom: -100px;
  left: -100px;
}

.shell {
  width: min(980px, 92vw);
  margin: 36px auto 60px;
  display: grid;
  gap: 16px;
}

.hero {
  background: linear-gradient(130deg, #faf5ec 0%, #fff7ed 45%, #ecfff8 100%);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  animation: slide-in 450ms ease;
}

.eyebrow {
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.12em;
  margin: 0;
}

h1 {
  margin: 6px 0 8px;
  font-size: clamp(30px, 5vw, 46px);
  font-family: "Instrument Serif", serif;
  font-weight: 400;
}

.subtitle {
  margin: 0;
  max-width: 760px;
  line-height: 1.45;
}

h2 {
  margin: 0 0 12px;
  font-size: 20px;
}

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 18px;
  backdrop-filter: blur(6px);
  animation: slide-in 520ms ease both;
}

.panel:nth-of-type(2) {
  animation-delay: 90ms;
}

.panel:nth-of-type(3) {
  animation-delay: 140ms;
}

.panel:nth-of-type(4) {
  animation-delay: 200ms;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn {
  border: 0;
  border-radius: 12px;
  background: var(--accent);
  color: white;
  padding: 10px 14px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  cursor: pointer;
  transition: transform 120ms ease, filter 120ms ease;
}

.btn:hover {
  transform: translateY(-1px);
  filter: brightness(0.95);
}

.btn.secondary {
  background: var(--accent-2);
}

.btn.ghost {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.grid {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin-bottom: 12px;
}

label {
  display: grid;
  gap: 8px;
  font-size: 14px;
}

select {
  width: 100%;
  background: white;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 9px 10px;
}

.hint {
  margin: 10px 0 0;
  font-size: 13px;
}

.stat-grid {
  margin-top: 12px;
  display: grid;
  gap: 10px;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
}

.stat {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.66);
}

.stat .label {
  font-size: 12px;
  opacity: 0.75;
}

.stat .value {
  font-size: 20px;
  font-weight: 700;
}

.logs {
  display: grid;
  gap: 8px;
  max-height: 280px;
  overflow: auto;
}

.log {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  background: rgba(255, 255, 255, 0.78);
  font-size: 13px;
}

.log strong {
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.08em;
  margin-right: 8px;
}

@keyframes slide-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .shell {
    margin-top: 20px;
  }

  .hero,
  .panel {
    border-radius: 14px;
    padding: 14px;
  }
}
