:root {
  --teal: #0f9d8a;
  --bg: #f3f4f6;
  --ink: #233b39;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, "Noto Sans TC", sans-serif;
  line-height: 1.65;
}
main {
  max-width: 1280px;
  margin: auto;
  padding: 24px;
}
header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 24px;
}
h1 {
  font-size: 25px;
  margin: 0;
}
h2 {
  font-size: 21px;
  margin: 0 0 16px;
}
h3 {
  font-size: 16px;
}
small,
.muted {
  color: #607572;
}
button,
.pill {
  border: 0;
  border-radius: 999px;
  padding: 10px 18px;
  background: var(--teal);
  color: white;
  cursor: pointer;
  font: inherit;
  transition: transform 0.25s cubic-bezier(0.34, 1.56, 0.64, 1);
}
button:hover {
  transform: translateY(-2px);
}
button.secondary {
  background: #e5f4f1;
  color: #176d61;
}
button:disabled {
  opacity: 0.45;
  cursor: default;
}
input,
textarea,
select {
  width: 100%;
  padding: 10px;
  border: 1px solid #dce5e3;
  border-radius: 12px;
  font: inherit;
  color: inherit;
  background: white;
}
textarea {
  min-height: 90px;
}
label {
  display: block;
  margin-bottom: 12px;
}
input[type="checkbox"],
input[type="radio"] {
  width: auto;
  margin-right: 8px;
}
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}
.card {
  background: white;
  border-radius: 26px;
  padding: 24px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  min-width: 0;
}
.wide {
  grid-column: 1/-1;
}
.row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}
.row > label {
  flex: 1;
  min-width: 120px;
}
.notice {
  background: #e9f6f3;
  padding: 14px;
  border-radius: 16px;
}
.badge {
  background: #f2c14e;
  padding: 4px 12px;
  border-radius: 999px;
  color: #443a20;
}
.table-wrap {
  overflow: auto;
}
table {
  border-collapse: collapse;
  width: 100%;
  font-size: 14px;
}
th,
td {
  text-align: left;
  padding: 9px;
  border-bottom: 1px solid #e9eeed;
  vertical-align: top;
}
td input {
  min-width: 110px;
}
td textarea {
  min-width: 170px;
  min-height: 60px;
}
a {
  color: #087e70;
  overflow-wrap: anywhere;
}
pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 13px;
}
#toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #233b39;
  color: white;
  padding: 12px 22px;
  border-radius: 20px;
  max-width: 90vw;
  z-index: 9;
}
#login {
  max-width: 440px;
  margin: 10vh auto;
}
.hidden {
  display: none !important;
}
.event {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 15px 0;
}
.winner {
  font-size: 24px;
  padding: 16px;
  background: #f0faf7;
  border-radius: 18px;
  margin: 10px 0;
}
.reveal {
  animation: reveal 0.7s cubic-bezier(0.34, 1.56, 0.64, 1);
}
@keyframes reveal {
  from {
    opacity: 0;
    transform: translateY(25px) scale(0.9);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
@media (max-width: 700px) {
  main {
    padding: 14px;
  }
  .grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
  .card {
    padding: 18px;
  }
  header {
    align-items: flex-start;
  }
  h1 {
    font-size: 20px;
  }
  .wide {
    grid-column: auto;
  }
  .row > label {
    min-width: 100%;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}

.google-login { display: inline-block; padding: 18px 28px; background: #234a38; color: white; border-radius: 8px; font-size: 1.2rem; text-decoration: none; }
