:root {
  --green: #2d5031;
  --green-dark: #1f3a23;
  --text: #1a1a1a;
  --muted: #6b6b6b;
  --card-bg: rgba(255, 255, 255, 0.92);
  --error: #b00020;
  --star-empty: #d0d0d0;
}

@import url('https://fonts.googleapis.com/css2?family=Allura&display=swap');

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: #000;
}

body.page-public,
body.page-admin {
  background-image: linear-gradient(rgba(0,0,0,0.3), rgba(0,0,0,0.3)), url('./assets/background.png');
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  min-height: 100vh;
  padding: 24px 12px;
}

.card {
  width: 100%;
  max-width: 480px;
  margin: 24px auto;
  background: var(--card-bg);
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
  padding: 28px 24px;
}

.card-wide { max-width: 960px; }

.club-name {
  margin: 0 0 8px;
  letter-spacing: 0.18em;
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  color: var(--green);
  text-transform: uppercase;
}

.thank-you {
  margin: 0;
  text-align: center;
  font-family: 'Allura', cursive;
  font-size: 64px;
  line-height: 1;
  color: var(--green);
}

.subtitle {
  margin: 8px 0 24px;
  text-align: center;
  color: var(--muted);
  font-size: 15px;
}

.rating-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid #eee;
}
.rating-row:last-of-type { border-bottom: none; }

.rating-label {
  font-weight: 600;
  font-size: 15px;
}

.stars {
  display: inline-flex;
  gap: 4px;
}

.star {
  width: 36px;
  height: 36px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  background: none;
  border: 0;
  padding: 0;
  color: var(--star-empty);
}

.star.filled { color: var(--green); }

.star svg { width: 28px; height: 28px; }

label.field {
  display: block;
  margin-top: 16px;
  font-size: 14px;
  color: var(--muted);
}

textarea, input[type="text"], input[type="password"], input[type="date"] {
  width: 100%;
  padding: 12px;
  margin-top: 6px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
}

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

.btn {
  display: block;
  width: 100%;
  margin-top: 20px;
  padding: 14px;
  font-size: 16px;
  font-weight: 600;
  color: white;
  background: var(--green);
  border: 0;
  border-radius: 8px;
  cursor: pointer;
}
.btn:hover:not(:disabled) { background: var(--green-dark); }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-secondary {
  background: white;
  color: var(--green);
  border: 1px solid var(--green);
}

.helper {
  margin-top: 8px;
  font-size: 13px;
  color: var(--muted);
  text-align: center;
}

.error {
  margin-top: 12px;
  padding: 10px 12px;
  background: #fdecea;
  color: var(--error);
  border-radius: 8px;
  font-size: 14px;
}

.success-state {
  text-align: center;
  padding: 16px 0;
}
.success-state .check {
  width: 64px; height: 64px; margin: 0 auto 16px;
  border-radius: 50%;
  background: var(--green);
  display: flex; align-items: center; justify-content: center;
  color: white; font-size: 36px;
}
.success-state h2 { color: var(--green); margin: 0 0 8px; }
.success-state p { color: var(--muted); margin: 0; }

/* Admin */
.admin-header {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 16px;
}
.admin-header h1 { font-size: 20px; margin: 0; color: var(--green); }
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: end; margin-bottom: 20px;
}
.filter-bar > div { display: flex; flex-direction: column; }
.filter-bar label { font-size: 12px; color: var(--muted); }
.preset-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 16px; }
.preset-row .btn { width: auto; padding: 8px 14px; margin: 0; font-size: 14px; }

.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px; margin-bottom: 20px;
}
.stat-tile {
  background: white; padding: 12px 14px; border-radius: 8px; border: 1px solid #eee;
}
.stat-tile .label { font-size: 12px; color: var(--muted); }
.stat-tile .value { font-size: 22px; font-weight: 700; color: var(--green); margin-top: 4px; }
.stat-tile .per-cat { font-size: 13px; color: var(--text); line-height: 1.6; }

.submission-list { display: flex; flex-direction: column; gap: 10px; }
.submission {
  background: white; padding: 14px; border-radius: 8px; border: 1px solid #eee;
}
.submission-head {
  display: flex; justify-content: space-between; flex-wrap: wrap;
  font-size: 13px; color: var(--muted); margin-bottom: 8px;
}
.submission-ratings { display: flex; gap: 16px; flex-wrap: wrap; margin-bottom: 8px; font-size: 14px; }
.submission-ratings .cat { display: inline-flex; gap: 4px; }
.submission-comment { font-size: 14px; line-height: 1.5; }
.submission-name { color: var(--muted); font-style: italic; }

@media (max-width: 600px) {
  .thank-you { font-size: 56px; }
  .star { width: 40px; height: 40px; }
  .star svg { width: 32px; height: 32px; }
}
