/* CardZone - Ultimate Card Game Hub Stylesheet */

/* ===== CSS RESET & BASE ===== */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: #0F0A1E;
  color: #E2E8F0;
  line-height: 1.6;
  min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Playfair Display', Georgia, serif;
  font-weight: 700;
  line-height: 1.2;
}

a {
  color: #F59E0B;
  text-decoration: none;
  transition: color 0.3s ease;
}

a:hover {
  color: #FBBF24;
}

img {
  max-width: 100%;
  height: auto;
}

/* ===== CSS VARIABLES ===== */
:root {
  --primary: #4C1D95;
  --secondary: #6D28D9;
  --accent: #F59E0B;
  --accent-hover: #FBBF24;
  --bg-dark: #0F0A1E;
  --bg-card: #1E1530;
  --bg-card-hover: #2a1f42;
  --text: #E2E8F0;
  --text-muted: #A0AEC0;
  --light: #F5F3FF;
  --border: rgba(107, 41, 217, 0.3);
  --gradient: linear-gradient(135deg, var(--primary), var(--secondary));
  --shadow: 0 4px 20px rgba(76, 29, 149, 0.3);
  --shadow-lg: 0 10px 40px rgba(76, 29, 149, 0.4);
  --radius: 12px;
  --radius-sm: 8px;
  --radius-lg: 16px;
}

/* ===== LAYOUT ===== */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-wrapper {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.main-content {
  flex: 1;
  padding: 40px 0;
}

section {
  margin-bottom: 60px;
}

/* ===== NAVIGATION ===== */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(15, 10, 30, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  padding: 15px 0;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Playfair Display', serif;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--light);
}

.logo-icon {
  font-size: 1.8rem;
}

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

.nav-links {
  display: flex;
  gap: 30px;
  list-style: none;
}

.nav-links a {
  color: var(--text);
  font-weight: 500;
  padding: 8px 0;
  position: relative;
}

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: width 0.3s ease;
}

.nav-links a:hover::after,
.nav-links a.active::after {
  width: 100%;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--light);
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 5px;
}

.menu-toggle span {
  width: 25px;
  height: 3px;
  background: var(--light);
  border-radius: 2px;
  transition: all 0.3s ease;
}

/* ===== HERO SECTION ===== */
.hero {
  position: relative;
  padding: 80px 0;
  text-align: center;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center, rgba(107, 41, 217, 0.2) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 3.5rem;
  color: var(--light);
  margin-bottom: 20px;
}

.hero h1 span {
  color: var(--accent);
}

.hero .tagline {
  font-size: 1.3rem;
  color: var(--text-muted);
  margin-bottom: 30px;
}

/* Animated Card Suits */
.card-suits {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  overflow: hidden;
}

.suit {
  position: absolute;
  font-size: 3rem;
  opacity: 0.15;
  animation: float 6s ease-in-out infinite;
}

.suit-1 { top: 20%; left: 10%; animation-delay: 0s; }
.suit-2 { top: 60%; left: 5%; animation-delay: 1s; }
.suit-3 { top: 30%; right: 10%; animation-delay: 2s; }
.suit-4 { top: 70%; right: 8%; animation-delay: 0.5s; }
.suit-5 { top: 10%; right: 25%; animation-delay: 1.5s; }
.suit-6 { bottom: 20%; left: 20%; animation-delay: 2.5s; }

@keyframes float {
  0%, 100% { transform: translateY(0) rotate(0deg); }
  50% { transform: translateY(-20px) rotate(10deg); }
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 12px 30px;
  border-radius: var(--radius);
  font-weight: 600;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
  border: none;
  font-size: 1rem;
}

.btn-primary {
  background: var(--accent);
  color: var(--bg-dark);
}

.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--bg-dark);
  transform: translateY(-2px);
  box-shadow: 0 5px 20px rgba(245, 158, 11, 0.4);
}

.btn-secondary {
  background: transparent;
  color: var(--light);
  border: 2px solid var(--secondary);
}

.btn-secondary:hover {
  background: var(--secondary);
  border-color: var(--secondary);
}

.btn-sm {
  padding: 8px 20px;
  font-size: 0.9rem;
}

/* ===== SECTION HEADERS ===== */
.section-header {
  text-align: center;
  margin-bottom: 40px;
}

.section-header h2 {
  font-size: 2.5rem;
  color: var(--light);
  margin-bottom: 10px;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* ===== GAME CARDS ===== */
.game-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 25px;
}

.game-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.game-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--gradient);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.game-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--secondary);
}

.game-card:hover::before {
  opacity: 1;
}

.game-card-icon {
  font-size: 2.5rem;
  margin-bottom: 15px;
}

.game-card h3 {
  color: var(--light);
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.game-card p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 15px;
}

.category-badge {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(107, 41, 217, 0.3);
  color: var(--accent);
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 500;
  margin-bottom: 12px;
}

/* ===== ARTICLE CARDS ===== */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 30px;
}

.article-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.article-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: var(--secondary);
}

.article-card-image {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.article-card-content {
  padding: 20px;
}

.article-card h3 {
  color: var(--light);
  font-size: 1.2rem;
  margin-bottom: 10px;
  line-height: 1.4;
}

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

/* ===== FILTER TABS ===== */
.filter-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  margin-bottom: 30px;
}

.filter-tab {
  padding: 10px 24px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 30px;
  color: var(--text);
  cursor: pointer;
  transition: all 0.3s ease;
  font-weight: 500;
}

.filter-tab:hover,
.filter-tab.active {
  background: var(--secondary);
  border-color: var(--secondary);
  color: var(--light);
}

/* ===== WHY CHOOSE US ===== */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.feature-card {
  text-align: center;
  padding: 30px;
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.feature-card:hover {
  border-color: var(--secondary);
  transform: translateY(-3px);
}

.feature-icon {
  font-size: 3rem;
  margin-bottom: 20px;
}

.feature-card h3 {
  color: var(--light);
  margin-bottom: 10px;
}

.feature-card p {
  color: var(--text-muted);
}

/* ===== STATS ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
  margin: 40px 0;
}

.stat-card {
  text-align: center;
  padding: 30px;
  background: var(--gradient);
  border-radius: var(--radius-lg);
}

.stat-number {
  font-size: 3rem;
  font-weight: 700;
  color: var(--accent);
  font-family: 'Playfair Display', serif;
}

.stat-label {
  color: var(--light);
  font-size: 1.1rem;
}

/* ===== TEAM SECTION ===== */
.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
}

.team-card {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 30px;
  text-align: center;
  border: 1px solid var(--border);
  transition: all 0.3s ease;
}

.team-card:hover {
  border-color: var(--secondary);
}

.team-avatar {
  font-size: 4rem;
  margin-bottom: 15px;
}

.team-card h3 {
  color: var(--light);
  margin-bottom: 5px;
}

.team-role {
  color: var(--accent);
  font-weight: 500;
  margin-bottom: 10px;
}

.team-bio {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* ===== CONTACT FORM ===== */
.contact-form {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 1px solid var(--border);
  max-width: 600px;
  margin: 0 auto;
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--light);
  font-weight: 500;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-dark);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--secondary);
}

.form-group textarea {
  min-height: 120px;
  resize: vertical;
}

.contact-form .btn {
  width: 100%;
}

/* ===== FAQ ===== */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 15px;
  border: 1px solid var(--border);
}

.faq-item h3 {
  color: var(--light);
  font-size: 1.1rem;
  margin-bottom: 10px;
}

.faq-item p {
  color: var(--text-muted);
}

/* ===== FOOTER ===== */
.footer {
  background: var(--bg-card);
  border-top: 1px solid var(--border);
  padding: 50px 0 20px;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-section h4 {
  color: var(--light);
  font-size: 1.2rem;
  margin-bottom: 20px;
}

.footer-section ul {
  list-style: none;
}

.footer-section ul li {
  margin-bottom: 10px;
}

.footer-section ul a {
  color: var(--text-muted);
}

.footer-section ul a:hover {
  color: var(--accent);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid var(--border);
  color: var(--text-muted);
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 15px;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--bg-dark);
  border-radius: 50%;
  color: var(--text);
  transition: all 0.3s ease;
}

.social-links a:hover {
  background: var(--secondary);
  color: var(--light);
}

/* ===== 404 PAGE ===== */
.error-page {
  text-align: center;
  padding: 100px 20px;
}

.error-404 {
  font-size: 8rem;
  font-weight: 700;
  color: var(--primary);
  font-family: 'Playfair Display', serif;
  position: relative;
  display: inline-block;
}

.error-404::before,
.error-404::after {
  content: '♠';
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 4rem;
  color: var(--accent);
  opacity: 0.5;
}

.error-404::before { left: -80px; }
.error-404::after { right: -80px; }

.error-page h1 {
  font-size: 2rem;
  color: var(--light);
  margin: 20px 0;
}

.error-page p {
  color: var(--text-muted);
  margin-bottom: 30px;
}

/* ===== CONTENT PAGES (About, Privacy, Terms) ===== */
.content-page {
  max-width: 800px;
  margin: 0 auto;
  padding: 40px 20px;
}

.content-page h1 {
  font-size: 2.5rem;
  color: var(--light);
  margin-bottom: 30px;
  text-align: center;
}

.content-page h2 {
  font-size: 1.8rem;
  color: var(--light);
  margin: 30px 0 15px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.content-page h2:first-of-type {
  margin-top: 0;
  border-top: none;
  padding-top: 0;
}

.content-page p {
  color: var(--text);
  margin-bottom: 15px;
  line-height: 1.8;
}

.content-page ul {
  margin: 15px 0 20px 30px;
  color: var(--text);
}

.content-page li {
  margin-bottom: 8px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .menu-toggle {
    display: flex;
  }

  .nav-links {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg-dark);
    border-bottom: 1px solid var(--border);
    padding: 20px;
    gap: 15px;
    display: none;
  }

  .nav-links.active {
    display: flex;
  }

  .hero h1 {
    font-size: 2.5rem;
  }

  .hero .tagline {
    font-size: 1.1rem;
  }

  .section-header h2 {
    font-size: 2rem;
  }

  .game-grid,
  .article-grid {
    grid-template-columns: 1fr;
  }

  .contact-form {
    padding: 25px;
  }

  .error-404 {
    font-size: 5rem;
  }

  .error-404::before,
  .error-404::after {
    font-size: 2.5rem;
  }

  .error-404::before { left: -50px; }
  .error-404::after { right: -50px; }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 2rem;
  }

  .btn {
    padding: 10px 20px;
  }

  .filter-tabs {
    gap: 8px;
  }

  .filter-tab {
    padding: 8px 16px;
    font-size: 0.9rem;
  }
}

/* ===== UTILITIES ===== */
.text-center { text-align: center; }
.text-accent { color: var(--accent); }
.mb-0 { margin-bottom: 0; }
.mb-20 { margin-bottom: 20px; }
.mt-40 { margin-top: 40px; }

/* Loading Animation */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.fade-in {
  animation: fadeIn 0.6s ease forwards;
}

/* Playable game badge */
.playable-badge {
  position: absolute;
  top: 10px;
  right: 10px;
  background: #10B981;
  color: white;
  font-size: 0.7rem;
  padding: 2px 8px;
  border-radius: 20px;
  font-weight: bold;
  z-index: 10;
}
.game-card { position: relative; }
