:root {
  --bg: #e8f3e3;
  --fairway: #d6eacc;
  --card: #ffffff;
  --text: #1d2a1a;
  --muted: #56674f;
  --accent: #2e7d32;
  --accent-text: #ffffff;
  --shadow: 0 6px 24px rgba(29, 42, 26, 0.12);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1a0e;
    --fairway: #142315;
    --card: #1c2b1d;
    --text: #e6efe3;
    --muted: #9db098;
    --accent: #66bb6a;
    --accent-text: #0f1a0e;
    --shadow: 0 6px 24px rgba(0, 0, 0, 0.4);
  }
}

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

html {
  /* mown-fairway stripes */
  background: repeating-linear-gradient(90deg, var(--bg) 0 60px, var(--fairway) 60px 120px);
  min-height: 100%;
}

body {
  margin: 0 auto;
  max-width: 42rem;
  padding: 3rem 1rem 2rem;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  color: var(--text);
}

a { color: var(--accent); }

header { text-align: center; margin-bottom: 2rem; }
h1 { font-size: clamp(2.5rem, 8vw, 4rem); margin: 0; letter-spacing: -0.02em; line-height: 1.1; }
.tagline { color: var(--muted); margin: 0.5rem 0 0; }

.card {
  background: var(--card);
  border-radius: 1rem;
  padding: 2rem 1.5rem;
  box-shadow: var(--shadow);
  min-height: 12rem;
}
.label {
  margin: 0 0 0.75rem;
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent);
}
.content { margin: 0; font-size: 1.35rem; line-height: 1.5; }

.actions { text-align: center; margin-top: 1.5rem; }

button, .button {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.8rem 1.5rem;
  border: 0;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-text);
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  box-shadow: var(--shadow);
  transition: transform 0.1s ease;
}
button:hover, .button:hover { transform: translateY(-2px); }
button:active { transform: translateY(1px); }
button:focus-visible, .button:focus-visible { outline: 3px solid var(--text); outline-offset: 3px; }

.ball {
  width: 1.1rem;
  height: 1.1rem;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #ffffff, #dddddd 70%, #b5b5b5);
  box-shadow: inset -1px -1px 2px rgba(0, 0, 0, 0.25);
}
.swinging .ball { animation: fly 0.6s ease-out; }
@keyframes fly {
  0%   { transform: translate(0, 0); }
  40%  { transform: translate(14px, -22px) rotate(180deg); }
  100% { transform: translate(0, 0) rotate(360deg); }
}
@media (prefers-reduced-motion: reduce) {
  .swinging .ball { animation: none; }
}

.counter { text-align: center; color: var(--muted); font-size: 0.9rem; min-height: 1.5em; }

footer { margin-top: 4rem; text-align: center; color: var(--muted); font-size: 0.85rem; }
