@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

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

:root {
  --blue: #2563eb;
  --blue-light: #3b82f6;
  --blue-dark: #1e3a8a;
  --blue-grad: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
  --green: #059669;
  --green-light: #10b981;
  --red: #dc2626;
  --gold: #f59e0b;
  --gold-grad: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  --gray: #64748b;
  --gray-light: #f1f5f9;
  --gray-bg: #f8fafc;
  --border: #e2e8f0;
  --text: #0f172a;
  --text-muted: #64748b;
  --radius: 16px;
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.04);
  --shadow: 0 10px 25px rgba(15, 23, 42, 0.05);
  --shadow-lg: 0 20px 40px rgba(15, 23, 42, 0.08);
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: var(--gray-bg);
  line-height: 1.6;
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--blue); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--blue-dark); text-decoration: none; }

/* Layout */
.container { max-width: 1000px; margin: 0 auto; padding: 0 20px; }

/* Header */
header {
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text);
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.main-nav { display: flex; gap: 8px; margin: 0 auto; flex-wrap: wrap; justify-content: center; }
.nav-link { font-size: 14px; font-weight: 700; color: var(--text-muted); padding: 8px 16px; border-radius: 20px; transition: all 0.2s; }
.nav-link.active { background: var(--blue-light); color: #fff; }
.nav-link:hover:not(.active) { background: var(--gray-light); color: var(--text); }
.site-name {
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--blue-dark);
  letter-spacing: -0.02em;
  white-space: nowrap;
}
.lang-switcher { display: flex; gap: 8px; }
.lang-select {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  background-color: #fff;
  cursor: pointer;
  appearance: none;
  background-image: url('data:image/svg+xml;utf8,<svg fill="none" stroke="%2364748b" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>');
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
  padding-right: 36px;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}
.lang-select:hover {
  border-color: var(--blue-light);
}
.lang-select:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Hero */
.hero {
  background: var(--blue-grad);
  color: #fff;
  padding: 70px 0 60px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: url('data:image/svg+xml;utf8,<svg width="100" height="100" viewBox="0 0 100 100" xmlns="http://www.w3.org/2000/svg"><circle cx="50" cy="50" r="40" fill="rgba(255,255,255,0.03)"/></svg>') 0 0/50px 50px;
  pointer-events: none;
}
.hero h1 { 
  font-size: clamp(2rem, 5vw, 3.5rem); 
  font-weight: 800; 
  margin-bottom: 16px; 
  letter-spacing: -0.03em;
  line-height: 1.1;
  position: relative;
  z-index: 1;
}
.hero p { 
  font-size: 1.15rem; 
  opacity: 0.9; 
  max-width: 650px; 
  margin: 0 auto; 
  font-weight: 400;
  position: relative;
  z-index: 1;
}

/* Ad placeholders */
.ad-slot {
  text-align: center;
  background: rgba(241, 245, 249, 0.5);
  border: 1px dashed var(--border);
  border-radius: 12px;
  margin: 20px 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 12px;
}
#ad-top { min-height: 90px; }
#ad-bottom { min-height: 250px; }

/* Form */
.form-section { padding: 40px 0 24px; margin-top: -40px; position: relative; z-index: 10; }
.form-card {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: var(--radius);
  padding: 0;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}
.mode-switcher {
  display: flex;
  background: var(--gray-bg);
  border-bottom: 1px solid var(--border);
}
.mode-btn {
  flex: 1;
  padding: 16px;
  background: none;
  border: none;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: all 0.2s;
  position: relative;
}
.mode-btn:hover { color: var(--blue); background: rgba(37, 99, 235, 0.05); }
.mode-btn.active { color: var(--blue-dark); background: #fff; }
.mode-btn.active::after {
  content: ''; position: absolute; bottom: -1px; left: 0; right: 0;
  height: 3px; background: var(--blue);
}
.mode-panel { padding: 32px; display: none; }
.mode-panel.active { display: block; animation: slideDown 0.3s ease-out; }

/* Simple Mode Quiz */
.quiz-options {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 16px;
  margin-top: 12px;
}
.quiz-card {
  border: 2px solid var(--border);
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: #fff;
}
.quiz-card:hover { border-color: var(--blue-light); transform: translateY(-2px); }
.quiz-card.active {
  border-color: var(--blue);
  background: rgba(37, 99, 235, 0.05);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}
.quiz-icon { font-size: 32px; margin-bottom: 8px; }
.quiz-text { font-weight: 600; font-size: 14px; color: var(--text); }
.mt-4 { margin-top: 24px; }
.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 20px;
  margin-bottom: 24px;
}
.form-group { display: flex; flex-direction: column; gap: 8px; }
.form-group label { 
  font-size: 12px; 
  font-weight: 700; 
  color: var(--text-muted); 
  text-transform: uppercase; 
  letter-spacing: 0.05em; 
}
.form-group input, .form-group select {
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-size: 15px;
  font-weight: 500;
  font-family: inherit;
  background: var(--gray-bg);
  color: var(--text);
  transition: all 0.2s ease;
  appearance: none;
}
.form-group select {
  background-image: url('data:image/svg+xml;utf8,<svg fill="none" stroke="%2364748b" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M19 9l-7 7-7-7"></path></svg>');
  background-repeat: no-repeat;
  background-position: right 12px center;
  background-size: 16px;
  padding-right: 40px;
}
.form-group input:focus, .form-group select:focus {
  outline: none;
  border-color: var(--blue-light);
  background: #fff;
  box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}
.compare-btn {
  width: 100%;
  padding: 16px;
  background: var(--blue-grad);
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 1.1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  letter-spacing: 0.02em;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}
.compare-btn:hover { 
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
}
.compare-btn:active { transform: translateY(0); }

/* Results */
#results { padding: 8px 0 40px; opacity: 0; transition: opacity 0.5s ease; }
#results.visible { opacity: 1; }
.results-table { display: flex; flex-direction: column; gap: 20px; }

/* Province Card */
.province-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}
.province-card:hover { 
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg); 
  border-color: rgba(59, 130, 246, 0.3);
}
.province-card.top-pick { 
  border: 2px solid var(--gold); 
}

.badge-recommended {
  background: var(--gold-grad);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 6px 16px;
  text-align: center;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.card-header {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 24px;
  cursor: pointer;
  background: #fff;
  flex-wrap: wrap;
  transition: background 0.2s;
}
.card-header:hover { background: #fdfdfe; }

.card-name {
  min-width: 180px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.province-flag { 
  font-size: 2rem; 
  background: var(--gray-light);
  width: 50px; height: 50px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px;
}
.card-name > div {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.province-name { font-weight: 800; font-size: 1.15rem; color: var(--text); letter-spacing: -0.01em; }
.province-capital { font-size: 13px; color: var(--text-muted); font-weight: 500; }

.card-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 16px 28px;
  flex: 1;
}
.stat { display: flex; flex-direction: column; gap: 4px; min-width: 90px; }
.stat-label { font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; letter-spacing: 0.05em; }
.stat-value { font-size: 1.1rem; font-weight: 800; letter-spacing: -0.01em; }
.stat-value.tax { font-size: 0.9rem; font-weight: 600; }
.surplus-positive { color: var(--green); }
.surplus-negative { color: var(--red); }

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
.badge-french { background: #fee2e2; color: var(--red); }
.badge-no-french { background: #d1fae5; color: var(--green); }

.expand-icon { 
  margin-left: auto; 
  color: var(--blue); 
  background: var(--gray-light);
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease; 
  font-size: 12px; 
}
.province-card.open .expand-icon { 
  transform: rotate(180deg); 
  background: var(--blue-light);
  color: #fff;
}

/* Detail panel */
.card-detail {
  display: none;
  padding: 32px;
  background: var(--gray-bg);
  border-top: 1px solid var(--border);
}
.province-card.open .card-detail { 
  display: block; 
  animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.detail-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
}
@media (max-width: 768px) { .detail-grid { grid-template-columns: 1fr; gap: 24px; } }

.detail-section h4 {
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--blue-dark);
  margin-bottom: 16px;
  margin-top: 24px;
}
.detail-section h4:first-child { margin-top: 0; }

/* Cost bars */
.cost-bars { display: flex; flex-direction: column; gap: 12px; }
.bar-row { display: flex; align-items: center; gap: 12px; }
.bar-label { font-size: 13px; font-weight: 600; min-width: 90px; color: var(--text); }
.bar-track { flex: 1; background: var(--border); border-radius: 6px; height: 12px; overflow: hidden; }
.bar-fill { height: 100%; border-radius: 6px; transition: width 1s cubic-bezier(0.4, 0, 0.2, 1); }
.bar-value { font-size: 13px; font-weight: 700; min-width: 60px; text-align: right; }

/* Stars */
.stars { font-size: 1.4rem; color: var(--gold); letter-spacing: 4px; margin-bottom: 16px; }

/* Programs */
.programs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.program-tag {
  background: #dbeafe;
  color: var(--blue-dark);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.province-notes { 
  font-size: 14px; 
  color: var(--text-muted); 
  line-height: 1.7; 
  background: #fff;
  padding: 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
}

/* SEO content */
.seo-section { padding: 60px 0; border-top: 1px solid var(--border); }
.seo-section h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 16px; color: var(--text); letter-spacing: -0.01em; }
.seo-section p { color: var(--text-muted); font-size: 15px; line-height: 1.8; }

/* Sort pills */
.sort-pills {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
  background: #fff;
  padding: 12px 20px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
}
.sort-label { font-size: 13px; color: var(--text-muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.sort-pill {
  background: var(--gray-bg);
  border: 1px solid transparent;
  color: var(--text-muted);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}
.sort-pill:hover { background: #e2e8f0; color: var(--text); }
.sort-pill.active { background: var(--blue-grad); color: #fff; box-shadow: 0 4px 10px rgba(37, 99, 235, 0.2); }

/* Best-for tags */
.best-for-tags { font-size: 1rem; margin-left: 6px; }

/* Affordability ratio */
.stat-sub { font-size: 11px; margin-top: 4px; font-weight: 600; padding: 2px 6px; border-radius: 4px; display: inline-block; }
.afford-low { background: #d1fae5; color: var(--green); }
.afford-mid { background: #fef3c7; color: var(--gold); }
.afford-high { background: #fee2e2; color: var(--red); }

/* Suburb rent note */
.suburb-note { font-size: 13px; color: var(--text-muted); margin-top: 16px; font-weight: 500; }

/* FAQ */
.faq-section { padding: 60px 0 24px; border-top: 1px solid var(--border); }
.faq-section h2 { font-size: 1.5rem; font-weight: 800; margin-bottom: 24px; color: var(--text); letter-spacing: -0.01em; }
.faq-item { 
  border: 1px solid var(--border); 
  border-radius: 12px; 
  margin-bottom: 12px; 
  overflow: hidden; 
  background: #fff;
  box-shadow: var(--shadow-sm);
}
.faq-q {
  padding: 18px 20px;
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background 0.2s;
}
.faq-q:hover { background: var(--gray-bg); color: var(--blue); }
.faq-icon { 
  color: var(--blue); 
  font-size: 12px; 
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1); 
  flex-shrink: 0; 
  background: #eff6ff;
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
}
.faq-item.open .faq-icon { transform: rotate(180deg); background: var(--blue); color: #fff; }
.faq-a { 
  display: none; 
  padding: 0 20px 20px; 
  font-size: 15px; 
  color: var(--text-muted); 
  line-height: 1.7; 
}
.faq-item.open .faq-a { display: block; animation: slideDown 0.3s ease-out; }

/* Disclaimer */
.disclaimer {
  background: #fffbeb;
  border-left: 4px solid var(--gold);
  padding: 16px 20px;
  border-radius: 0 12px 12px 0;
  font-size: 14px;
  font-weight: 500;
  color: #92400e;
  margin: 32px 0;
  box-shadow: var(--shadow-sm);
}

/* Footer */
footer {
  background: var(--text);
  color: rgba(255, 255, 255, 0.7);
  padding: 50px 0 30px;
  font-size: 14px;
}
.footer-inner {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
}
.footer-col h4 {
  color: #fff;
  margin-bottom: 16px;
  font-size: 1.1rem;
  font-weight: 700;
}
.footer-col ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.footer-col ul li {
  margin-bottom: 10px;
}
.footer-col ul a {
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: color 0.2s ease;
}
.footer-col ul a:hover {
  color: #fff;
}
.footer-bottom {
  text-align: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.1);
  opacity: 0.6;
  font-size: 12px;
}
@media (max-width: 768px) {
  .footer-inner {
    grid-template-columns: 1fr;
    gap: 30px;
  }
}
.footer-langs { display: flex; gap: 16px; margin-bottom: 16px; flex-wrap: wrap; }
.footer-langs a { font-weight: 600; padding: 4px 12px; border-radius: 20px; background: rgba(255,255,255,0.1); color: #fff; text-decoration: none; }
.footer-langs a:hover { background: rgba(255,255,255,0.2); color: var(--blue-light); }

/* Feedback button */
.feedback-btn {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: var(--blue-grad);
  color: #fff;
  border: none;
  border-radius: 30px;
  padding: 14px 24px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 25px rgba(37,99,235,0.3);
  z-index: 200;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.feedback-btn:hover { transform: translateY(-3px); box-shadow: 0 14px 30px rgba(37,99,235,0.4); }

/* Mobile */
@media (max-width: 600px) {
  .hero { padding: 50px 0 40px; }
  .card-header { padding: 20px; flex-direction: column; align-items: flex-start; gap: 16px; }
  .card-name { width: 100%; display: flex; align-items: center; }
  .expand-icon { position: absolute; right: 20px; top: 28px; }
  .card-stats { gap: 12px; width: 100%; justify-content: space-between; }
  .stat { min-width: 45%; }
  .form-grid { grid-template-columns: 1fr; gap: 16px; }
  .form-card { padding: 20px; }
  .feedback-btn { bottom: 20px; right: 20px; padding: 12px 20px; }
}

/* Print */
@media print {
  header, .form-section, .feedback-btn, .ad-slot, footer, .sort-pills { display: none; }
  #results { opacity: 1; }
  .card-detail { display: block !important; }
  body { background: #fff; }
  .province-card { box-shadow: none; border-color: #ccc; break-inside: avoid; }
}

/* Modal */
.modal-overlay {
  position: fixed; top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none;
  transition: opacity 0.3s ease;
  padding: 20px;
}
.modal-overlay.active { opacity: 1; pointer-events: auto; }
.modal-content {
  background: #fff;
  width: 100%; max-width: 800px; max-height: 90vh;
  border-radius: 20px;
  overflow-y: auto;
  position: relative;
  transform: translateY(20px);
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
}
.modal-overlay.active .modal-content { transform: translateY(0); }
.modal-close {
  position: absolute; top: 16px; right: 16px;
  width: 36px; height: 36px;
  border-radius: 50%; border: none;
  background: rgba(0,0,0,0.5); color: #fff;
  font-size: 24px; line-height: 1;
  cursor: pointer; z-index: 10;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s;
}
.modal-close:hover { background: rgba(0,0,0,0.8); }

/* Modal Inner Styling */
.modal-hero {
  height: 250px; background-size: cover; background-position: center;
  position: relative;
}
.modal-hero::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 50%;
  background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
}
.modal-hero h2 {
  position: absolute; bottom: 20px; left: 32px;
  color: #fff; font-size: 2.5rem; z-index: 2; margin: 0;
  font-weight: 800; letter-spacing: -0.02em;
}
.modal-grid { padding: 32px; display: grid; gap: 24px; }
.modal-stats {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 16px; background: var(--gray-bg); padding: 20px; border-radius: 16px;
  border: 1px solid var(--border);
}
.modal-stat { display: flex; flex-direction: column; gap: 4px; }
.modal-stat-val { font-size: 1.1rem; font-weight: 800; color: var(--blue-dark); }
.modal-stat-lbl { font-size: 11px; font-weight: 700; color: var(--text-muted); text-transform: uppercase; }

.modal-section h3 {
  font-size: 1.1rem; font-weight: 800; color: var(--text); margin-bottom: 12px;
  display: flex; align-items: center; gap: 8px;
}
.modal-section p { color: var(--text-muted); font-size: 15px; line-height: 1.6; }
.modal-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.modal-tag { background: #eff6ff; color: var(--blue-dark); padding: 6px 12px; border-radius: 20px; font-size: 13px; font-weight: 600; }

.explore-btn {
  background: transparent; border: 1px solid var(--blue); color: var(--blue);
  padding: 8px 16px; border-radius: 20px; font-size: 13px; font-weight: 700;
  cursor: pointer; transition: all 0.2s; margin-top: 16px;
}
.explore-btn:hover { background: var(--blue); color: #fff; }

@media (max-width: 600px) {
  .modal-hero { height: 180px; }
  .modal-hero h2 { font-size: 2rem; left: 20px; }
  .modal-grid { padding: 20px; }
}

/* Spirit Animal Section */
.spirit-animal-section {
  margin: 40px 0;
  padding: 0;
}
.spirit-card {
  background: linear-gradient(135deg, #ffedd5 0%, #fef08a 100%);
  border-radius: 24px;
  padding: 40px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  border: 2px dashed #f59e0b;
  position: relative;
  overflow: hidden;
}
.spirit-card::before {
  content: '🍁';
  position: absolute;
  font-size: 100px;
  opacity: 0.1;
  top: -20px;
  right: -20px;
  transform: rotate(15deg);
}
.spirit-card h2 {
  font-size: 2rem;
  color: #92400e;
  font-weight: 800;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}
.spirit-card p {
  color: #b45309;
  font-size: 1.1rem;
  margin-bottom: 30px;
  font-weight: 500;
}
.spirit-options {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}
.spirit-btn {
  background: #fff;
  border: 2px solid #fcd34d;
  padding: 12px 24px;
  border-radius: 30px;
  font-size: 15px;
  font-weight: 700;
  color: #92400e;
  cursor: pointer;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 6px rgba(251, 191, 36, 0.2);
}
.spirit-btn:hover {
  transform: translateY(-3px) scale(1.05);
  background: #fef3c7;
  border-color: #f59e0b;
  box-shadow: 0 8px 15px rgba(245, 158, 11, 0.3);
}
.spirit-btn.active {
  background: #f59e0b;
  color: #fff;
  border-color: #d97706;
  box-shadow: 0 4px 10px rgba(217, 119, 6, 0.4);
}
.spirit-result {
  margin-top: 30px;
  padding-top: 30px;
  border-top: 2px dashed rgba(245, 158, 11, 0.3);
  display: none;
  animation: slideDown 0.4s ease-out;
}
.spirit-result.active {
  display: block;
}
@keyframes bounce {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-10px) rotate(-5deg); }
  50% { transform: translateY(-15px) rotate(0deg); }
  75% { transform: translateY(-10px) rotate(5deg); }
}

.spirit-emoji {
  font-size: 5rem;
  margin-bottom: 15px;
  display: inline-block;
  animation: bounce 2.5s ease-in-out infinite;
  text-shadow: 0 10px 15px rgba(245, 158, 11, 0.4);
}

.spirit-name {
  font-size: 1.5rem;
  font-weight: 800;
  color: #92400e;
  margin-bottom: 10px;
}
.spirit-desc {
  font-size: 1.1rem;
  color: #b45309;
  max-width: 600px;
  margin: 0 auto 20px;
}
.spirit-prov {
  display: inline-block;
  background: #92400e;
  color: #fff;
  padding: 8px 20px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 14px;
}

.data-freshness-badge {
  font-size: 12px; color: var(--text-muted); text-align: right;
  margin-bottom: 12px; padding: 6px 12px; background: var(--gray-bg);
  border-radius: 6px; border: 1px solid var(--border);
}
