* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: "Noto Sans TC", "Microsoft JhengHei", sans-serif;
  background: #f3fbf6;
  color: #073f2d;
  line-height: 1.7;
}

/* Header */

.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  padding: 16px 7%;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 0 6px 24px rgba(0, 80, 50, 0.08);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  width: 48px;
  height: 48px;
  border-radius: 16px;
  background: linear-gradient(135deg, #00a86b, #78d98b);
  display: grid;
  place-items: center;
  font-size: 1.5rem;
}

.logo h1 {
  font-size: 1.1rem;
  color: #064b35;
  line-height: 1.2;
}

.logo p {
  font-size: 0.8rem;
  color: #6a8178;
}

nav {
  display: flex;
  gap: 20px;
}

nav a {
  color: #355f53;
  text-decoration: none;
  font-weight: 800;
}

/* Hero */

.hero {
  padding: 90px 7% 60px;
  background:
    linear-gradient(115deg, rgba(246,255,249,.96), rgba(225,247,238,.76)),
    radial-gradient(circle at 85% 15%, rgba(0,168,107,.18), transparent 30%);
}

.hero-content {
  max-width: 920px;
}

.badge {
  display: inline-block;
  color: #00a86b;
  font-weight: 900;
  letter-spacing: 1px;
  margin-bottom: 16px;
}

.hero h2 {
  font-size: clamp(2.3rem, 5vw, 4rem);
  color: #053b2a;
  line-height: 1.15;
  margin-bottom: 18px;
}

.hero p {
  max-width: 880px;
  font-size: 1.15rem;
  color: #49695f;
}

/* Layout */

.container {
  padding: 56px 7%;
}

.card {
  background: rgba(255, 255, 255, 0.94);
  border: 1px solid rgba(0, 120, 80, 0.12);
  border-radius: 28px;
  padding: 30px;
  box-shadow: 0 12px 32px rgba(0, 80, 50, 0.08);
}

.card h3 {
  color: #064b35;
  margin-bottom: 18px;
  font-size: 1.35rem;
}

.card p {
  margin-bottom: 12px;
  color: #49695f;
}

.card ul {
  padding-left: 22px;
  color: #49695f;
}

/* Form */

label {
  display: block;
  font-weight: 900;
  color: #064b35;
  margin: 14px 0 6px;
}

input,
select {
  width: 100%;
  padding: 15px 18px;
  border: 1px solid rgba(0, 120, 80, 0.2);
  border-radius: 16px;
  font-size: 1rem;
  background: #fff;
  color: #073f2d;
}

input:focus,
select:focus {
  outline: none;
  border-color: #00a86b;
  box-shadow: 0 0 0 4px rgba(0, 168, 107, 0.12);
}

button {
  margin-top: 22px;
  border: none;
  border-radius: 16px;
  padding: 14px 22px;
  font-weight: 900;
  cursor: pointer;
  background: linear-gradient(135deg, #007e55, #00b878);
  color: white;
  font-size: 1rem;
}

button:hover {
  opacity: 0.92;
}

/* Results */

.result-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

#weatherRisk,
#climateAlert {
  color: #355f53;
}

/* Risk badges */

.risk-list {
  display: grid;
  gap: 12px;
  margin-top: 12px;
}

.risk-item {
  padding: 14px 16px;
  border-radius: 16px;
  background: #f3fbf6;
  border: 1px solid rgba(0, 120, 80, 0.12);
}

.risk-item strong {
  color: #064b35;
}

.risk-low {
  color: #057a4f;
  font-weight: 900;
}

.risk-mid {
  color: #b45309;
  font-weight: 900;
}

.risk-high {
  color: #b91c1c;
  font-weight: 900;
}

/* Link buttons */

.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.link-btn {
  display: inline-block;
  padding: 12px 18px;
  border-radius: 14px;
  background: #0ea66c;
  color: #fff;
  text-decoration: none;
  font-weight: 900;
}

.link-btn:hover {
  opacity: 0.9;
}

/* Alert box */

.alert-box {
  background: #fff7ed;
  border: 1px solid rgba(249, 115, 22, 0.28);
  border-radius: 18px;
  padding: 18px;
}

.alert-box h4 {
  color: #9a3412;
  margin-bottom: 10px;
}

.typhoon-link {
  background: #f97316;
}

/* Footer */

footer {
  text-align: center;
  padding: 32px 7%;
  background: #053b2a;
  color: white;
}

/* Mobile */

@media (max-width: 900px) {
  .header {
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
  }

  nav {
    flex-wrap: wrap;
  }

  .result-grid {
    grid-template-columns: 1fr;
  }

  .container {
    padding: 42px 6%;
  }

  .card {
    padding: 24px;
  }
}

/* 農民決策模擬專用 */

.btn-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.secondary-btn {
  background: #eef3ef;
  color: #064b35;
  border: 1px solid rgba(0,120,80,.16);
}

.status-text {
  margin-bottom: 18px;
  color: #064b35;
  font-weight: 900;
}

.decision-card {
  min-height: 220px;
}

.highlight-card {
  background: linear-gradient(135deg, #f0fff7, #ffffff);
  border: 2px solid rgba(0,168,107,.22);
}

.decision-score {
  display: inline-block;
  margin-top: 10px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #e7f8ef;
  color: #057a4f;
  font-weight: 900;
}

.warning-text {
  color: #b45309;
  font-weight: 900;
}

.danger-text {
  color: #b91c1c;
  font-weight: 900;
}

.success-text {
  color: #057a4f;
  font-weight: 900;
}

@media (max-width: 900px) {
  .btn-row {
    flex-direction: column;
  }

  .btn-row button {
    width: 100%;
  }
}

.hidden {
  display: none;
}

.challenge-box {
  margin-top: 28px;
  padding: 22px;
  border-radius: 22px;
  background: #f0fff7;
  border: 1px solid rgba(0,168,107,.22);
}

.choice-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 16px;
}

.choice-btn {
  background: #e7f8ef;
  color: #064b35;
}

.choice-btn.active {
  background: linear-gradient(135deg, #007e55, #00b878);
  color: white;
}

.challenge-result {
  margin-top: 18px;
  font-weight: 900;
  color: #064b35;
}

@media (max-width: 900px) {
  .choice-grid {
    grid-template-columns: 1fr;
  }
}

.guide-toggle summary {
  cursor: pointer;
  font-size: 1.25rem;
  font-weight: 900;
  color: #064b35;
}

.guide-toggle summary::marker {
  color: #00a86b;
}

.guide-toggle[open] summary {
  margin-bottom: 18px;
}

.event-cards{
  margin-top:16px;
  display:grid;
  gap:10px;
}

.event-card{
  padding:12px 16px;
  border-radius:14px;
  font-weight:800;
}

.climate{
  background:#fff3cd;
}

.market{
  background:#d1ecf1;
}

.cost{
  background:#ffe5d0;
}

.farm{
  background:#e7f8ef;
}

.certificate {
  border: 4px double #00a86b;
  border-radius: 24px;
  padding: 28px;
  text-align: center;
  background: linear-gradient(135deg, #ffffff, #f0fff7);
}

.certificate-org {
  font-weight: 900;
  color: #057a4f;
  letter-spacing: 2px;
  margin-bottom: 12px;
}

.certificate h2 {
  color: #064b35;
  margin-bottom: 18px;
}

.certificate h3 {
  color: #007e55;
  margin: 14px 0;
}

.certificate-score {
  margin: 20px auto;
  padding: 18px;
  border-radius: 18px;
  background: #e7f8ef;
  max-width: 520px;
  text-align: left;
}

.certificate-date {
  margin-top: 18px;
  font-weight: 900;
}

.share-row {
  margin-top: 20px;
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

.share-row button {
  padding: 10px 18px;
  border-radius: 999px;
  border: none;
  background: #00a86b;
  color: white;
  font-weight: 800;
  cursor: pointer;
}