:root {
  --bg: #f4f2ec;
  --paper: #fffdfa;
  --ink: #1f2f2a;
  --muted: #56655f;
  --accent: #0f766e;
  --accent-soft: #d9efe8;
  --warm: #f59e0b;
  --line: #d8ded8;
  --shadow: 0 20px 45px rgba(15, 28, 24, 0.12);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: "Space Grotesk", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at 15% 0%, #fff5d6 0%, transparent 30%),
    radial-gradient(circle at 80% 10%, #dcefe7 0%, transparent 35%),
    var(--bg);
}

.app-shell {
  max-width: 1180px;
  margin: 0 auto;
  padding: 2.5rem 1rem 3rem;
}

.hero {
  margin-bottom: 1.5rem;
}

.kicker {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.72rem;
  color: var(--muted);
}

h1,
h2,
h3 {
  margin-top: 0;
  font-family: "Literata", serif;
}

h1 {
  margin: 0.35rem 0 0.7rem;
  font-size: clamp(1.6rem, 3.5vw, 2.5rem);
}

.subtitle {
  margin: 0;
  max-width: 900px;
  color: var(--muted);
}

.card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--paper);
  box-shadow: var(--shadow);
  padding: 1rem;
}

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

.input-group label {
  display: block;
  margin-bottom: 0.3rem;
  font-weight: 600;
  font-size: 0.88rem;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid #bbc8c2;
  border-radius: 10px;
  padding: 0.62rem 0.75rem;
  font: inherit;
  color: var(--ink);
  background: #ffffff;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
  outline: 2px solid color-mix(in srgb, var(--accent) 22%, transparent);
  outline-offset: 1px;
}

.layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.75fr) minmax(300px, 1.25fr);
  gap: 1rem;
  margin-bottom: 1rem;
}

.helper {
  margin-top: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.results {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 0.6rem;
  max-height: 70vh;
  overflow: auto;
}

.results button {
  width: 100%;
  text-align: left;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.7rem;
  background: #fff;
  color: inherit;
  cursor: pointer;
}

.results button:hover {
  border-color: var(--accent);
  background: #f7fcfb;
}

.results button.active {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--accent) 25%, transparent);
  background: var(--accent-soft);
}

.result-line {
  display: block;
  font-size: 0.86rem;
  color: var(--muted);
  margin-top: 0.2rem;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-bottom: 0.9rem;
}

.pill {
  display: inline-flex;
  align-items: center;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  font-size: 0.8rem;
  border: 1px solid #b9c7c0;
  background: #f2f8f5;
}

.pill.stance-champion {
  background: #d8f4e8;
  border-color: #58b283;
}

.pill.stance-open {
  background: #eef7ff;
  border-color: #6fa0da;
}

.pill.stance-unknown {
  background: #fff4dd;
  border-color: #d4aa53;
}

.talking-points {
  margin: 0;
  padding-left: 1.1rem;
}

.talking-points li {
  margin-bottom: 0.65rem;
}

textarea {
  min-height: 100px;
}

.row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  align-items: start;
  margin-top: 1rem;
}

button.cta {
  border: none;
  background: var(--accent);
  color: #fff;
  padding: 0.65rem 0.95rem;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
}

button.cta:hover {
  filter: brightness(1.06);
}

.agenda-panel ul {
  margin-top: 0.4rem;
  margin-bottom: 0.4rem;
}

.import-panel {
  border-style: dashed;
}

@media (max-width: 930px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .results {
    max-height: 38vh;
  }

  .row {
    grid-template-columns: 1fr;
  }
}
