/*
 * Funorama - Social Gaming Platform
 * Mobile-first responsive design
 */

/* ============================================
   CSS VARIABLES
   ============================================ */

:root {
  /* Colors - Light Theme */
  --background: #fafbff;
  --foreground: #0f172a;
  --card: #ffffff;
  --card-foreground: #0f172a;
  --popover: #ffffff;
  --popover-foreground: #0f172a;
  --primary: #8b5cf6;
  --primary-foreground: #ffffff;
  --secondary: #f1f5f9;
  --secondary-foreground: #1e293b;
  --muted: #f1f5f9;
  --muted-foreground: #64748b;
  --accent: #06b6d4;
  --accent-foreground: #0f172a;
  --destructive: #ef4444;
  --destructive-foreground: #ffffff;
  --border: #e2e8f0;
  --input: #f8fafc;
  --ring: #8b5cf6;

  /* Typography */
  --font-heading: "Poppins", sans-serif;
  --font-body: "Inter", sans-serif;

  /* Spacing */
  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 1.5rem;
  --space-lg: 2rem;
  --space-xl: 3rem;
  --space-2xl: 4rem;
  --space-3xl: 6rem;

  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --radius-full: 9999px;

  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
  --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);

  /* Transitions */
  --transition-fast: 150ms ease-in-out;
  --transition-base: 250ms ease-in-out;
  --transition-slow: 350ms ease-in-out;

  /* Container */
  --container-max: 1280px;
  --container-padding: var(--space-md);
}

[data-theme="dark"] {
  --background: #0f172a;
  --foreground: #f8fafc;
  --card: #1e293b;
  --card-foreground: #f8fafc;
  --popover: #1e293b;
  --popover-foreground: #f8fafc;
  --primary: #8b5cf6;
  --primary-foreground: #ffffff;
  --secondary: #334155;
  --secondary-foreground: #e2e8f0;
  --muted: #334155;
  --muted-foreground: #94a3b8;
  --accent: #0891b2;
  --accent-foreground: #f8fafc;
  --destructive: #ef4444;
  --destructive-foreground: #ffffff;
  --border: #334155;
  --input: #1e293b;
  --ring: #8b5cf6;
}

/* ============================================
   OVERFLOW PREVENTION
   ============================================ */

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

html {
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden;
  min-width: 320px;
}

img,
video,
iframe,
embed,
object,
svg {
  max-width: 100%;
  height: auto;
}

[class*="grid"] > *,
[class*="flex"] > * {
  min-width: 0;
}

pre,
code,
.code-block {
  max-width: 100%;
  overflow-x: auto;
}

p,
li,
td,
th {
  overflow-wrap: break-word;
}

input,
textarea,
select,
button {
  max-width: 100%;
}

/* ============================================
   BASE STYLES
   ============================================ */

body {
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--foreground);
  background-color: var(--background);
  transition: background-color var(--transition-base),
    color var(--transition-base);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--space-sm);
  color: var(--foreground);
}

h1 {
  font-size: 2.5rem;
  font-weight: 800;
}

h2 {
  font-size: 2rem;
  font-weight: 700;
}

h3 {
  font-size: 1.5rem;
  font-weight: 600;
}

h4 {
  font-size: 1.25rem;
  font-weight: 600;
}

p {
  margin-bottom: var(--space-sm);
}

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

a:hover {
  color: var(--accent);
}

ul {
  list-style: none;
}

/* ============================================
   CONTAINER & LAYOUT
   ============================================ */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-padding);
}

section {
  padding: var(--space-2xl) 0;
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-md);
  border: 2px solid transparent;
  cursor: pointer;
  transition: all var(--transition-base);
  text-decoration: none;
  min-height: 44px;
  white-space: nowrap;
}

.btn-primary {
  background-color: var(--primary);
  color: var(--primary-foreground);
  border-color: var(--primary);
}

.btn-primary:hover {
  background-color: var(--accent);
  border-color: var(--accent);
  color: var(--accent-foreground);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background-color: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

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

.btn-large {
  padding: 1rem 2rem;
  font-size: 1.125rem;
}

.btn-full {
  width: 100%;
}

.btn-play {
  background-color: rgba(139, 92, 246, 0.95);
  color: white;
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  backdrop-filter: blur(10px);
}

.btn-play:hover {
  background-color: var(--accent);
  transform: scale(1.05);
}

/* ============================================
   HEADER
   ============================================ */

header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(250, 251, 255, 0.8);
  backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
  transition: all var(--transition-base);
}

[data-theme="dark"] header {
  background-color: rgba(15, 23, 42, 0.8);
}

header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--space-sm) 0;
  gap: var(--space-md);
  min-width: 0;
}

.logo-link {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  text-decoration: none;
  flex-shrink: 0;
}

.logo {
  width: 48px;
  height: 48px;
  object-fit: contain;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--foreground);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.age-badge {
  position: absolute;
  top: var(--space-xs);
  right: var(--space-sm);
  background-color: var(--primary);
  color: white;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
}

.nav-desktop {
  display: none;
}

.nav-desktop ul {
  display: flex;
  gap: var(--space-lg);
}

.nav-desktop a {
  color: var(--foreground);
  font-weight: 500;
  padding: 0.5rem 0;
  position: relative;
}

.nav-desktop a::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  transition: width var(--transition-base);
}

.nav-desktop a:hover::after {
  width: 100%;
}

.header-actions {
  display: none;
  align-items: center;
  gap: var(--space-sm);
}

.theme-toggle {
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: var(--radius-md);
  color: var(--foreground);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.theme-toggle:hover {
  background-color: var(--secondary);
}

.theme-toggle .moon-icon {
  display: none;
}

[data-theme="dark"] .theme-toggle .sun-icon {
  display: none;
}

[data-theme="dark"] .theme-toggle .moon-icon {
  display: block;
}

.mobile-menu-toggle {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  z-index: 1001;
  flex-shrink: 0;
}

.mobile-menu-toggle span {
  width: 24px;
  height: 3px;
  background-color: var(--foreground);
  border-radius: var(--radius-full);
  transition: all var(--transition-base);
}

.mobile-menu-toggle[aria-expanded="true"] span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-toggle[aria-expanded="true"] span:nth-child(3) {
  transform: rotate(-45deg) translate(7px, -6px);
}

.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background-color: var(--background);
  padding: 5rem var(--space-lg) var(--space-lg);
  transform: translateX(-100%);
  transition: transform var(--transition-base);
  overflow-y: auto;
  z-index: 999;
}

.mobile-menu.active {
  transform: translateX(0);
}

.mobile-menu ul {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
}

.mobile-menu a {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--foreground);
  padding: var(--space-sm) 0;
}

.mobile-menu-actions {
  display: flex;
  flex-direction: column;
  gap: var(--space-sm);
  margin-top: var(--space-xl);
}

/* ============================================
   POPUPS
   ============================================ */

.popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  padding: var(--space-md);
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition-base);
}

.popup-overlay.active {
  opacity: 1;
  visibility: visible;
}

.popup-content {
  background-color: var(--card);
  border-radius: var(--radius-xl);
  padding: var(--space-xl);
  max-width: 500px;
  width: 100%;
  text-align: center;
  box-shadow: var(--shadow-xl);
  transform: scale(0.9);
  transition: transform var(--transition-base);
}

.popup-overlay.active .popup-content {
  transform: scale(1);
}

.popup-icon {
  margin-bottom: var(--space-md);
}

.popup-content h2,
.popup-content h3 {
  color: var(--foreground);
  margin-bottom: var(--space-sm);
}

.popup-content p {
  color: var(--muted-foreground);
  margin-bottom: var(--space-lg);
}

.popup-actions {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
  justify-content: center;
}

.cookie-popup .popup-content {
  max-width: 400px;
  padding: var(--space-lg);
}

.cookie-popup h3 {
  font-size: 1.25rem;
}

.cookie-popup p {
  font-size: 0.875rem;
}

/* ============================================
   HERO SECTION
   ============================================ */

.hero {
  position: relative;
  padding: var(--space-3xl) 0;
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.1),
    rgba(6, 182, 212, 0.1)
  );
  overflow: hidden;
}

.particles-bg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0.3;
  background-image: radial-gradient(
      circle at 20% 30%,
      var(--primary) 0%,
      transparent 50%
    ),
    radial-gradient(circle at 80% 70%, var(--accent) 0%, transparent 50%);
  animation: float 20s ease-in-out infinite;
}

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

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

.hero h1 {
  font-size: 2.5rem;
  margin-bottom: var(--space-md);
  background: linear-gradient(135deg, var(--primary), var(--accent));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  max-width: 700px;
  margin: 0 auto var(--space-xl);
}

.hero-benefits {
  display: grid;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.benefit-item {
  text-align: center;
}

.benefit-icon {
  margin-bottom: var(--space-sm);
  display: flex;
  justify-content: center;
}

.benefit-item h3 {
  font-size: 1.25rem;
  margin-bottom: var(--space-xs);
}

.benefit-item p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
}

.hero-cta {
  display: flex;
  gap: var(--space-md);
  justify-content: center;
  flex-wrap: wrap;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}

.pulse-animation {
  animation: pulse 2s ease-in-out infinite;
}

/* ============================================
   GAMES SECTION
   ============================================ */

.games-section {
  background-color: var(--background);
}

.section-header {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.section-subtitle {
  color: var(--muted-foreground);
  max-width: 600px;
  margin: 0 auto;
}

.game-filters {
  display: flex;
  gap: var(--space-sm);
  justify-content: center;
  margin-bottom: var(--space-xl);
  flex-wrap: wrap;
}

.filter-btn {
  background-color: var(--secondary);
  color: var(--secondary-foreground);
  border: 2px solid transparent;
  padding: 0.5rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-base);
}

.filter-btn:hover,
.filter-btn.active {
  background-color: var(--primary);
  color: var(--primary-foreground);
}

.games-grid {
  display: grid;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.game-card {
  background-color: var(--card);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
  min-width: 0;
}

.game-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-xl);
}

.game-thumbnail {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 2;
}

.game-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.game-card:hover .game-thumbnail img {
  transform: scale(1.1);
}

.game-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity var(--transition-base);
}

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

.game-info {
  padding: var(--space-md);
}

.game-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.game-badge.relaxing {
  background-color: rgba(139, 92, 246, 0.1);
  color: var(--primary);
}

.game-badge.dynamic {
  background-color: rgba(6, 182, 212, 0.1);
  color: var(--accent);
}

.game-badge.themed {
  background-color: rgba(239, 68, 68, 0.1);
  color: var(--destructive);
}

.game-info h3 {
  font-size: 1.25rem;
  margin-bottom: var(--space-xs);
}

.game-info p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin-bottom: 0;
}

.games-disclaimer {
  text-align: center;
  color: var(--muted-foreground);
  font-size: 0.875rem;
  font-style: italic;
}

/* ============================================
   COMMUNITY SECTION
   ============================================ */

.community-section {
  background: linear-gradient(to bottom, var(--background), var(--secondary));
}

.community-grid {
  display: grid;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.community-feature {
  background-color: var(--card);
  padding: var(--space-lg);
  border-radius: var(--radius-lg);
  text-align: center;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

.community-feature:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}

.feature-icon {
  margin-bottom: var(--space-md);
  display: flex;
  justify-content: center;
}

.community-feature h3 {
  font-size: 1.25rem;
  margin-bottom: var(--space-sm);
}

.community-feature p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
}

.community-testimonial {
  background-color: var(--card);
  padding: var(--space-xl);
  border-radius: var(--radius-lg);
  text-align: center;
  margin-bottom: var(--space-xl);
  box-shadow: var(--shadow-md);
}

.testimonial-avatar {
  width: 80px;
  height: 80px;
  border-radius: var(--radius-full);
  margin: 0 auto var(--space-md);
  object-fit: cover;
}

.community-testimonial blockquote {
  border: none;
}

.community-testimonial p {
  font-size: 1.125rem;
  font-style: italic;
  color: var(--foreground);
  margin-bottom: var(--space-md);
}

.community-testimonial cite {
  color: var(--muted-foreground);
  font-style: normal;
  font-size: 0.875rem;
}

.community-cta {
  text-align: center;
}

.social-share {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  margin-top: var(--space-md);
  flex-wrap: wrap;
}

.social-share span {
  font-weight: 600;
  color: var(--muted-foreground);
}

.social-btn {
  background-color: var(--secondary);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--foreground);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.social-btn:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
  transform: scale(1.1);
}

/* ============================================
   ACCESS SECTION
   ============================================ */

.access-section {
  background-color: var(--background);
}

.access-content {
  display: grid;
  gap: var(--space-xl);
  align-items: center;
}

.access-visual img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
}

.section-intro {
  font-size: 1.125rem;
  color: var(--muted-foreground);
  margin-bottom: var(--space-lg);
}

.access-features {
  display: grid;
  gap: var(--space-lg);
  margin-bottom: var(--space-xl);
}

.access-feature-item {
  display: flex;
  gap: var(--space-md);
  align-items: flex-start;
}

.feature-icon-small {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  background-color: var(--secondary);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-text h3 {
  font-size: 1.125rem;
  margin-bottom: var(--space-xs);
}

.feature-text p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin-bottom: 0;
}

.access-cta {
  display: flex;
  gap: var(--space-md);
  flex-wrap: wrap;
}

/* ============================================
   FINAL SECTION
   ============================================ */

.final-section {
  background: linear-gradient(
    135deg,
    rgba(139, 92, 246, 0.05),
    rgba(6, 182, 212, 0.05)
  );
}

.final-intro {
  text-align: center;
  margin-bottom: var(--space-xl);
}

.lead {
  font-size: 1.25rem;
  color: var(--muted-foreground);
  max-width: 700px;
  margin: 0 auto;
}

.content-columns {
  display: grid;
  gap: var(--space-xl);
}

.seo-content {
  min-width: 0;
}

.seo-content h2 {
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
}

.seo-content h3 {
  margin-top: var(--space-lg);
  margin-bottom: var(--space-sm);
}

.seo-content p {
  margin-bottom: var(--space-md);
  line-height: 1.7;
}

.cta-text {
  font-weight: 600;
  color: var(--primary);
  font-size: 1.125rem;
  text-align: center;
  margin-top: var(--space-lg);
}

/* Contact Form */
.contact-sidebar {
  min-width: 0;
}

.contact-form-wrapper {
  background-color: var(--card);
  padding: var(--space-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  margin-bottom: var(--space-lg);
}

.contact-form-wrapper h3 {
  margin-bottom: var(--space-xs);
}

.contact-form-wrapper > p {
  color: var(--muted-foreground);
  margin-bottom: var(--space-lg);
}

.contact-form {
  display: grid;
  gap: var(--space-md);
}

.form-group {
  display: grid;
  gap: var(--space-xs);
}

.form-group label {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--foreground);
}

.form-group input,
.form-group textarea {
  padding: 0.75rem;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  background-color: var(--input);
  color: var(--foreground);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: all var(--transition-fast);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.form-success {
  display: none;
  align-items: center;
  gap: var(--space-sm);
  padding: var(--space-md);
  background-color: rgba(6, 182, 212, 0.1);
  color: var(--accent);
  border-radius: var(--radius-md);
  margin-top: var(--space-md);
}

.form-success.active {
  display: flex;
}

/* FAQ */
.faq-section {
  background-color: var(--card);
  padding: var(--space-lg);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.faq-section h3 {
  margin-bottom: var(--space-md);
}

.faq-accordion {
  display: grid;
  gap: var(--space-sm);
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.faq-question {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md);
  background-color: transparent;
  border: none;
  text-align: left;
  font-weight: 600;
  color: var(--foreground);
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

.faq-question:hover {
  background-color: var(--secondary);
}

.faq-question svg {
  flex-shrink: 0;
  transition: transform var(--transition-base);
}

.faq-question[aria-expanded="true"] svg {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base);
}

.faq-question[aria-expanded="true"] + .faq-answer {
  max-height: 500px;
}

.faq-answer p {
  padding: 0 var(--space-md) var(--space-md);
  color: var(--muted-foreground);
  margin-bottom: 0;
}

/* ============================================
   FOOTER
   ============================================ */

footer {
  background-color: var(--card);
  border-top: 1px solid var(--border);
  padding: var(--space-2xl) 0 var(--space-md);
}

.footer-content {
  display: grid;
  gap: var(--space-xl);
  margin-bottom: var(--space-xl);
}

.footer-brand {
  min-width: 0;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: var(--space-xs);
  margin-bottom: var(--space-md);
}

.footer-tagline {
  color: var(--muted-foreground);
  margin-bottom: var(--space-md);
}

.social-links {
  display: flex;
  gap: var(--space-sm);
  flex-wrap: wrap;
}

.social-link {
  width: 44px;
  height: 44px;
  background-color: var(--secondary);
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--foreground);
  transition: all var(--transition-fast);
}

.social-link:hover {
  background-color: var(--primary);
  color: var(--primary-foreground);
  transform: scale(1.1);
}

.footer-column h4 {
  font-size: 1.125rem;
  margin-bottom: var(--space-md);
}

.footer-links {
  display: grid;
  gap: var(--space-xs);
}

.footer-links a {
  color: var(--muted-foreground);
  transition: color var(--transition-fast);
}

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

.footer-newsletter-text {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin-bottom: var(--space-md);
}

.newsletter-form {
  display: flex;
  gap: var(--space-xs);
}

.newsletter-form input {
  flex: 1;
  padding: 0.625rem;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  background-color: var(--input);
  color: var(--foreground);
  font-size: 0.875rem;
  min-width: 0;
}

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

.newsletter-form .btn {
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  flex-shrink: 0;
}

.footer-disclaimer {
  text-align: center;
  padding: var(--space-lg) 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--space-lg);
}

.disclaimer-text {
  color: var(--foreground);
  font-weight: 700;
  margin-bottom: var(--space-xs);
}

.disclaimer-subtext {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin-bottom: 0;
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-md);
}

.footer-bottom p {
  color: var(--muted-foreground);
  font-size: 0.875rem;
  margin-bottom: 0;
}

.back-to-top {
  background-color: var(--primary);
  color: var(--primary-foreground);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
}

.back-to-top:hover {
  background-color: var(--accent);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

/* ============================================
   RESPONSIVE - TABLET
   ============================================ */

@media (min-width: 768px) {
  :root {
    --container-padding: var(--space-xl);
  }

  h1 {
    font-size: 3.5rem;
  }

  h2 {
    font-size: 2.5rem;
  }

  .nav-desktop {
    display: block;
  }

  .header-actions {
    display: flex;
  }

  .mobile-menu-toggle {
    display: none;
  }

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

  .hero-benefits {
    grid-template-columns: repeat(3, 1fr);
  }

  .games-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .community-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .access-content {
    grid-template-columns: 1fr 1fr;
  }

  .content-columns {
    grid-template-columns: 2fr 1fr;
  }

  .footer-content {
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
  }
}

/* ============================================
   RESPONSIVE - DESKTOP
   ============================================ */

@media (min-width: 1024px) {
  h1 {
    font-size: 4rem;
  }

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

  .games-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .community-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ============================================
   ANIMATIONS
   ============================================ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

/* ДОДАЙ у style.css (мінімально, щоб модалка працювала красиво) */
.game-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  justify-content: center;
  align-items: center;
  z-index: 1001;
  padding: 16px;
}

.game-modal.is-open {
  display: flex;
}

.game-modal__window {
  background: #fff;
  width: 90%;
  max-width: 900px;
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.game-modal__bar {
  padding: 15px;
  font-size: 1.2em;
  font-weight: 700;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #222;
  color: #fff;
}

.game-modal__close {
  cursor: pointer;
  font-size: 1.1em;
  line-height: 1;
  border: 0;
  background: transparent;
  color: #fff;
}

#gameIframe {
  width: 100%;
  height: 500px;
  border: none;
  display: block;
}
