:root {
  --primary: #047857; /* Emerald green */
  --primary-hover: #065f46;
  --primary-light: #ecfdf5;
  --accent: #f59e0b; /* Aussie Gold */
  --accent-light: #fef3c7;
  --dark: #0f172a; /* Slate 900 */
  --text-main: #1e293b;
  --text-muted: #64748b;
  --bg-main: #f8fafc;
  --card-bg: #ffffff;
  --border: #e2e8f0;
  --radius-lg: 16px;
  --radius-md: 10px;
  --radius-sm: 6px;
  --shadow-sm: 0 1px 3px rgba(0,0,0,0.08);
  --shadow-md: 0 4px 14px rgba(0,0,0,0.06);
  --shadow-hover: 0 12px 28px rgba(0,0,0,0.12);
  --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

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

body {
  font-family: var(--font-family);
  background-color: var(--bg-main);
  color: var(--text-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

/* Header & Navigation */
header.navbar {
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 0;
  z-index: 100;
  border-bottom: 1px solid var(--border);
}

.nav-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--dark);
}

.logo .flag-icon {
  font-size: 1.6rem;
}

.logo span.highlight {
  color: var(--primary);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-md);
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.btn-primary {
  background-color: var(--primary);
  color: #ffffff;
}

.btn-primary:hover {
  background-color: var(--primary-hover);
  transform: translateY(-1px);
}

.btn-outline {
  border-color: var(--border);
  color: var(--text-main);
  background: white;
}

.btn-outline:hover {
  background: #f1f5f9;
}

.btn-gold {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: white;
}

/* Hero Section */
.hero {
  background: linear-gradient(135deg, #064e3b 0%, #065f46 50%, #047857 100%);
  color: white;
  padding: 56px 20px 48px;
  text-align: center;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  padding: 6px 14px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: 2.5rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  line-height: 1.2;
}

.hero p {
  font-size: 1.15rem;
  color: #d1fae5;
  margin-bottom: 30px;
}

/* Stats Ribbon */
.stats-ribbon {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-top: 24px;
  flex-wrap: wrap;
}

.stat-box {
  background: rgba(255, 255, 255, 0.1);
  padding: 12px 24px;
  border-radius: var(--radius-md);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.stat-number {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fef08a; /* Soft gold */
}

.stat-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #e2e8f0;
}

/* Main Container */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 32px 20px;
}

/* Filter and Search Bar */
.filter-section {
  background: white;
  padding: 20px;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border);
  margin-bottom: 28px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.search-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.search-input-wrap {
  position: relative;
  flex: 2;
  min-width: 260px;
}

.search-input-wrap input {
  width: 100%;
  padding: 12px 14px 12px 40px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
}

.search-input-wrap input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(4, 120, 87, 0.12);
}

.search-icon {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

.select-wrap {
  flex: 1;
  min-width: 160px;
}

.select-wrap select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  font-size: 0.95rem;
  background-color: white;
  outline: none;
  cursor: pointer;
}

.category-chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  scrollbar-width: none;
}

.category-chips::-webkit-scrollbar {
  display: none;
}

.chip {
  padding: 7px 14px;
  border-radius: 9999px;
  font-size: 0.85rem;
  font-weight: 600;
  border: 1px solid var(--border);
  background: #f8fafc;
  color: var(--text-main);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s;
}

.chip:hover {
  background: #f1f5f9;
}

.chip.active {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
}

/* Competitions Grid */
.competitions-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.competitions-count {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 500;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(330px, 1fr));
  gap: 24px;
}

/* Competition Card */
.comp-card {
  background: var(--card-bg);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.comp-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
}

.card-image-wrap {
  height: 180px;
  position: relative;
  overflow: hidden;
  background: #e2e8f0;
}

.card-image-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.comp-card:hover .card-image-wrap img {
  transform: scale(1.04);
}

.card-top-badges {
  position: absolute;
  top: 10px;
  left: 10px;
  right: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
}

.badge {
  padding: 4px 10px;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.badge-category {
  background: rgba(15, 23, 42, 0.85);
  color: white;
  backdrop-filter: blur(4px);
}

.badge-timer {
  background: #ef4444; /* red for urgency */
  color: white;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  box-shadow: 0 2px 6px rgba(239, 68, 68, 0.4);
}

.badge-timer.safe {
  background: #047857; /* green */
}

.badge-timer.warning {
  background: #d97706; /* amber */
}

.fav-btn {
  position: absolute;
  bottom: 10px;
  right: 10px;
  background: rgba(255, 255, 255, 0.9);
  border: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.15);
  transition: transform 0.15s;
}

.fav-btn:hover {
  transform: scale(1.1);
}

.fav-btn.active {
  color: #ef4444;
}

.card-body {
  padding: 18px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.card-organizer {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.85rem;
  color: var(--text-muted);
  font-weight: 600;
  margin-bottom: 6px;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 8px;
  line-height: 1.35;
}

.card-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-prize-box {
  background: var(--primary-light);
  border: 1px dashed #6ee7b7;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.prize-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--primary-hover);
  font-weight: 700;
}

.prize-value {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--primary-hover);
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 18px;
}

.pill {
  font-size: 0.75rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 4px;
  background: #f1f5f9;
  color: var(--text-muted);
}

.pill.pill-region {
  background: #e0f2fe;
  color: #0369a1;
}

.card-footer {
  margin-top: auto;
  display: flex;
  gap: 8px;
}

.btn-enter {
  flex: 2;
  background: var(--primary);
  color: white;
}

.btn-enter:hover {
  background: var(--primary-hover);
}

.btn-details {
  flex: 1;
  background: white;
  border: 1px solid var(--border);
  color: var(--text-main);
}

/* Modal Popup */
.modal-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-overlay.active {
  display: flex;
}

.modal-content {
  background: white;
  border-radius: var(--radius-lg);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-hover);
  position: relative;
  padding: 24px;
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Newsletter Section */
.newsletter-section {
  background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: 40px 24px;
  margin-top: 48px;
  text-align: center;
}

.newsletter-section h2 {
  font-size: 1.8rem;
  margin-bottom: 10px;
}

.newsletter-section p {
  color: #94a3b8;
  max-width: 500px;
  margin: 0 auto 24px;
}

.newsletter-form {
  display: flex;
  max-width: 480px;
  margin: 0 auto;
  gap: 8px;
  flex-wrap: wrap;
}

.newsletter-form input {
  flex: 1;
  min-width: 240px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  border: 1px solid #334155;
  background: #1e293b;
  color: white;
  font-size: 0.95rem;
}

.newsletter-form input:focus {
  outline: none;
  border-color: var(--primary);
}

/* Footer */
footer {
  border-top: 1px solid var(--border);
  background: white;
  margin-top: 60px;
  padding: 40px 20px;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
  text-align: center;
}

.legal-box {
  background: #f8fafc;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  color: #64748b;
  border: 1px solid var(--border);
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 1.85rem;
  }
  .hero p {
    font-size: 1rem;
  }
  .grid {
    grid-template-columns: 1fr;
  }
  .stats-ribbon {
    gap: 12px;
  }
  .stat-box {
    padding: 8px 16px;
  }
  .search-row {
    flex-direction: column;
  }
}

/* --- CompetitionsGuide-Style Enhancements --- */

/* Winners Ticker Bar */
.winners-ticker-wrap {
  background: #1e293b;
  color: #f8fafc;
  padding: 10px 20px;
  border-bottom: 1px solid #334155;
  font-size: 0.85rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  overflow: hidden;
}

.winners-ticker-badge {
  background: #f59e0b;
  color: #0f172a;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.winners-ticker-content {
  display: flex;
  gap: 24px;
  white-space: nowrap;
  animation: ticker-slide 25s linear infinite;
}

.ticker-item {
  color: #cbd5e1;
}

.ticker-item strong {
  color: #fef08a;
}

@keyframes ticker-slide {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* Recommended Section */
.featured-section {
  margin-bottom: 36px;
}

.section-title-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--dark);
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-sub {
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* Special Badge Types */
.badge-recommended {
  background: linear-gradient(135deg, #f59e0b 0%, #b45309 100%);
  color: white;
  box-shadow: 0 2px 8px rgba(245, 158, 11, 0.4);
}

.badge-skill {
  background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
  color: white;
}

.badge-daily {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: white;
}

/* Recommended Card Highlight */
.comp-card.recommended-card {
  border: 2px solid #fbbf24;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.12);
}

.comp-card.recommended-card:hover {
  box-shadow: 0 12px 30px rgba(245, 158, 11, 0.22);
}

.recommended-ribbon {
  background: #fef3c7;
  color: #92400e;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 12px;
  border-bottom: 1px solid #fde68a;
  display: flex;
  align-items: center;
  gap: 6px;
}

.skill-question-box {
  background: #f5f3ff;
  border: 1px dashed #c4b5fd;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 12px;
  font-size: 0.85rem;
  color: #4c1d95;
}

.skill-question-box strong {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: #6d28d9;
  margin-bottom: 2px;
}

/* Guide Modal / Pro Tips */
.guide-step {
  background: #f8fafc;
  border-left: 4px solid var(--primary);
  padding: 14px 16px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin-bottom: 14px;
}

.guide-step h4 {
  color: var(--dark);
  font-size: 1rem;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.guide-step p {
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.5;
}

/* --- VIP Membership & Paywall Styling --- */

/* VIP Pill in Navbar */
.vip-pill-btn {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
  color: #ffffff !important;
  border: none;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(245, 158, 11, 0.35);
}

.vip-pill-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.45);
}

.vip-active-badge {
  background: #047857;
  color: white;
  border-radius: 9999px;
  font-size: 0.7rem;
  padding: 2px 6px;
  font-weight: 800;
}

/* VIP Pricing Modal */
.vip-modal-header {
  text-align: center;
  margin-bottom: 24px;
}

.vip-crown-icon {
  font-size: 2.8rem;
  margin-bottom: 8px;
  display: inline-block;
  animation: bounce-subtle 2s infinite ease-in-out;
}

@keyframes bounce-subtle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.vip-plans-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.vip-plan-card {
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px 16px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s ease;
  position: relative;
  background: white;
}

.vip-plan-card:hover {
  border-color: #f59e0b;
  transform: translateY(-2px);
}

.vip-plan-card.selected {
  border-color: #d97706;
  background: #fefce8;
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.2);
}

.vip-plan-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: #f59e0b;
  color: #0f172a;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  padding: 2px 10px;
  border-radius: 9999px;
  letter-spacing: 0.05em;
  white-space: nowrap;
}

.vip-plan-name {
  font-size: 1.1rem;
  font-weight: 800;
  color: var(--dark);
  margin-bottom: 6px;
}

.vip-plan-price {
  font-size: 1.8rem;
  font-weight: 900;
  color: #0f172a;
  margin-bottom: 4px;
}

.vip-plan-price small {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-muted);
}

.vip-plan-billing {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.vip-perks-list {
  background: #f8fafc;
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 20px;
  border: 1px solid var(--border);
}

.vip-perks-list ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.vip-perks-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: var(--text-main);
}

.vip-perks-list li svg {
  color: #047857;
  flex-shrink: 0;
}

/* Daily Entry Tracker Widget */
.tracker-banner {
  background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
  color: white;
  border-radius: var(--radius-lg);
  padding: 18px 24px;
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.tracker-stat {
  display: flex;
  align-items: center;
  gap: 12px;
}

.tracker-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  font-weight: 800;
}

.daily-entry-btn {
  background: #ffffff;
  color: #0369a1;
  font-weight: 700;
  border: 1px solid #bae6fd;
}

.daily-entry-btn.completed {
  background: #ecfdf5;
  color: #047857;
  border-color: #a7f3d0;
}

/* Locked VIP Blur Feature */
.vip-locked-box {
  background: #fefce8;
  border: 1px dashed #fde047;
  border-radius: var(--radius-sm);
  padding: 8px 12px;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
}

.vip-unlock-link {
  color: #b45309;
  font-weight: 700;
  text-decoration: underline;
  cursor: pointer;
}
