/* ==========================================================================
   WIZARD ONLINE / VATICINIO - MODERN DARK FANTASY DESIGN SYSTEM
   ========================================================================== */

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

:root {
  --bg-dark: #090b14;
  --bg-card: rgba(18, 24, 43, 0.75);
  --bg-card-hover: rgba(28, 36, 64, 0.85);
  --bg-glass: rgba(15, 21, 37, 0.6);
  --border-color: rgba(255, 255, 255, 0.1);
  --border-glow: rgba(139, 92, 246, 0.4);

  --primary: #8b5cf6;
  --primary-hover: #7c3aed;
  --primary-glow: rgba(139, 92, 246, 0.35);
  --accent-cyan: #06b6d4;
  --accent-gold: #f59e0b;
  --accent-rose: #f43f5e;
  --accent-emerald: #10b981;

  --text-main: #f3f4f6;
  --text-muted: #9ca3af;
  --text-dim: #6b7280;

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 24px;
  --radius-full: 9999px;

  --shadow-main: 0 10px 30px -10px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 25px rgba(139, 92, 246, 0.25);
  
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Global Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-family: 'Inter', sans-serif;
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

h1, h2, h3, h4, .font-heading {
  font-family: 'Outfit', sans-serif;
  letter-spacing: -0.02em;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

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

/* Container */
.container {
  width: 100%;
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Header & Navigation */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
  padding: 1rem 0;
}

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

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: 'Outfit', sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  color: #fff;
}

.logo-icon {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--primary), var(--accent-cyan));
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 12px var(--primary-glow);
  font-size: 1.2rem;
}

.logo-badge {
  font-size: 0.75rem;
  background: rgba(255, 255, 255, 0.1);
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  color: var(--accent-cyan);
  font-weight: 600;
  border: 1px solid rgba(6, 182, 212, 0.3);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
}

.nav-link:hover, .nav-link.active {
  color: #fff;
  text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius-md);
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.btn-primary {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 4px 20px var(--primary-glow), inset 0 1px 0 rgba(255,255,255,0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 30px rgba(139, 92, 246, 0.5), inset 0 1px 0 rgba(255,255,255,0.5);
}

.btn-secondary {
  background: var(--bg-card);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--primary);
  transform: translateY(-2px);
}

.btn-lg {
  padding: 1rem 2.2rem;
  font-size: 1.05rem;
  border-radius: var(--radius-lg);
}

/* Hero Section */
.hero {
  position: relative;
  padding: 9rem 0 5rem;
  min-height: 85vh;
  display: flex;
  align-items: center;
  background: radial-gradient(circle at 50% 20%, rgba(139, 92, 246, 0.15), transparent 60%);
  overflow: hidden;
}

.hero-bg-wrapper {
  position: absolute;
  top: 0;
  right: -10%;
  width: 60%;
  height: 100%;
  opacity: 0.4;
  mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
  -webkit-mask-image: radial-gradient(circle at center, black 30%, transparent 80%);
  z-index: -1;
  pointer-events: none;
}

.hero-bg-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 3rem;
  align-items: center;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1rem;
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.3);
  border-radius: var(--radius-full);
  font-size: 0.85rem;
  color: #c4b5fd;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.hero-title {
  font-size: clamp(2.5rem, 5vw, 4.2rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 1.2rem;
  background: linear-gradient(135deg, #ffffff 30%, #a78bfa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  font-size: 1.15rem;
  color: var(--text-muted);
  margin-bottom: 2.2rem;
  max-width: 580px;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  align-items: center;
  flex-wrap: wrap;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}

.hero-card-stack {
  position: relative;
  width: 280px;
  height: 390px;
}

.stacked-card {
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: var(--radius-md);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.6);
  border: 2px solid var(--border-color);
  transition: var(--transition);
}

.stacked-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: calc(var(--radius-md) - 2px);
}

.stacked-card.card-1 {
  transform: rotate(-12deg) translateY(10px);
  z-index: 1;
}

.stacked-card.card-2 {
  transform: rotate(8deg) translateX(20px);
  z-index: 2;
}

.stacked-card.card-3 {
  transform: rotate(-2deg) translateY(-10px);
  z-index: 3;
  box-shadow: var(--shadow-glow), 0 20px 40px rgba(0, 0, 0, 0.8);
}

.hero-visual:hover .stacked-card.card-1 {
  transform: rotate(-20deg) translateX(-40px);
}
.hero-visual:hover .stacked-card.card-2 {
  transform: rotate(18deg) translateX(50px);
}
.hero-visual:hover .stacked-card.card-3 {
  transform: scale(1.05);
}

/* Legal Notice Banner */
.disclaimer-banner {
  background: rgba(245, 158, 11, 0.1);
  border-top: 1px solid rgba(245, 158, 11, 0.3);
  border-bottom: 1px solid rgba(245, 158, 11, 0.3);
  padding: 1rem 0;
  font-size: 0.85rem;
  color: #fcd34d;
  text-align: center;
}

.disclaimer-banner strong {
  color: #fff;
}

/* Sections */
.section {
  padding: 5rem 0;
  position: relative;
}

.section-header {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 4rem;
}

.section-title {
  font-size: 2.4rem;
  font-weight: 800;
  margin-bottom: 0.8rem;
  color: #fff;
}

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

/* Features Grid */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 2rem;
  backdrop-filter: blur(12px);
  transition: var(--transition);
}

.feature-card:hover {
  transform: translateY(-6px);
  border-color: var(--border-glow);
  box-shadow: var(--shadow-glow);
  background: var(--bg-card-hover);
}

.feature-icon {
  width: 54px;
  height: 54px;
  border-radius: var(--radius-md);
  background: rgba(139, 92, 246, 0.15);
  border: 1px solid rgba(139, 92, 246, 0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  color: var(--primary);
  margin-bottom: 1.4rem;
}

.feature-title {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  color: #fff;
}

.feature-text {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Rules Showcase Tabs */
.rules-section {
  background: linear-gradient(180deg, var(--bg-dark), #0f1424, var(--bg-dark));
}

.rules-tabs {
  display: flex;
  justify-content: center;
  gap: 1rem;
  margin-bottom: 3rem;
  flex-wrap: wrap;
}

.tab-btn {
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius-full);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  transition: var(--transition);
}

.tab-btn:hover, .tab-btn.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  box-shadow: 0 4px 15px var(--primary-glow);
}

.tab-content {
  display: none;
  animation: fadeIn 0.4s ease;
}

.tab-content.active {
  display: block;
}

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

.rule-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.8rem;
}

.rule-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: var(--transition);
}

.rule-card:hover {
  border-color: var(--border-glow);
  transform: translateY(-4px);
}

.rule-card-img {
  height: 240px;
  overflow: hidden;
  background: #000;
}

.rule-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.rule-card:hover .rule-card-img img {
  transform: scale(1.08);
}

.rule-card-body {
  padding: 1.5rem;
  flex: 1;
}

.rule-card-tag {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-cyan);
  margin-bottom: 0.4rem;
}

.rule-card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.6rem;
}

.rule-card-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* AI Assets Notice Badge */
.ai-notice-box {
  margin-top: 3rem;
  background: rgba(6, 182, 212, 0.08);
  border: 1px solid rgba(6, 182, 212, 0.25);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.ai-notice-icon {
  font-size: 2.5rem;
  color: var(--accent-cyan);
}

.ai-notice-text h4 {
  font-size: 1.2rem;
  color: #fff;
  margin-bottom: 0.3rem;
}

.ai-notice-text p {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Legal Document Page Styling */
.legal-page {
  padding: 8rem 0 5rem;
}

.legal-box {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 3rem;
  box-shadow: var(--shadow-main);
}

.legal-box h1 {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
  color: #fff;
}

.legal-box h2 {
  font-size: 1.5rem;
  margin: 2rem 0 1rem;
  color: var(--accent-cyan);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.4rem;
}

.legal-box h3 {
  font-size: 1.2rem;
  margin: 1.5rem 0 0.6rem;
  color: #fff;
}

.legal-box p, .legal-box ul {
  color: var(--text-muted);
  margin-bottom: 1rem;
  font-size: 0.98rem;
}

.legal-box ul {
  padding-left: 1.5rem;
}

.legal-box li {
  margin-bottom: 0.4rem;
}

.legal-alert {
  background: rgba(244, 63, 94, 0.1);
  border-left: 4px solid var(--accent-rose);
  padding: 1.2rem;
  border-radius: var(--radius-sm);
  margin: 1.5rem 0;
  color: #fecdd3;
}

/* Footer */
.footer {
  background: #05070d;
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 2rem;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr repeat(2, 1fr);
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-brand p {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 0.8rem;
  max-width: 380px;
}

.footer-col h4 {
  font-size: 1.05rem;
  color: #fff;
  margin-bottom: 1.2rem;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.footer-links a {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: center;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-dim);
}

.legal-disclaimer-text {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border-color);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  max-width: 900px;
  line-height: 1.5;
  color: var(--text-muted);
}

/* Mobile Toggle */
.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: #fff;
  font-size: 1.8rem;
  cursor: pointer;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .hero-cta {
    justify-content: center;
  }
  .hero-bg-wrapper {
    width: 100%;
    right: 0;
  }
  .hero-visual {
    margin-top: 2rem;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .mobile-menu-btn {
    display: block;
  }
  .nav-links {
    position: fixed;
    top: 70px;
    left: 0;
    width: 100%;
    background: var(--bg-dark);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    display: none;
  }
  .nav-links.open {
    display: flex;
  }
}
