/* 979JILI CASINO PHILIPPINES - COMPLETE FIXED STYLESHEET */
/* Works for Homepage and All Support Pages */
/* Optimized for Performance, Mobile-First, SEO-Friendly */

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  --primary: #E31E24;
  --primary-dark: #B71C1C;
  --gold: #FFD700;
  --gold-dark: #B8860B;
  --white: #FFFFFF;
  --off-white: #FAFAFA;
  --light-gray: #F5F5F5;
  --gray: #E0E0E0;
  --text: #1A1A1A;
  --text-gray: #666666;
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 32px rgba(0,0,0,0.12);
  --shadow-red: 0 8px 24px rgba(227,30,36,0.2);
  --shadow-gold: 0 8px 24px rgba(255,215,0,0.3);
  --font-primary: 'Outfit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

/* ============================================
   LAYOUT CONTAINERS - CRITICAL FOR SUPPORT PAGES
   ============================================ */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.card {
  background: #fff;
  padding: 2.5rem;
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--gray);
  margin-bottom: 2rem;
}

.section-alt {
  background: var(--off-white);
  padding: 3rem 1.5rem;
}

/* ============================================
   SECTION HEADERS - FOR SUPPORT PAGES
   ============================================ */
.section-header {
  text-align: center;
  margin-bottom: 3rem;
}

.section-tag {
  display: inline-block;
  background: rgba(227,30,36,0.1);
  color: var(--primary);
  padding: 0.5rem 1.25rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.875rem;
  margin-bottom: 1rem;
  text-transform: uppercase;
}

.section-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin-bottom: 1rem;
  color: var(--text);
}

.section-subtitle {
  font-size: 1.15rem;
  color: var(--text-gray);
  max-width: 700px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ============================================
   TRUST SECTION - FOR SUPPORT PAGES
   ============================================ */
.trust-section {
  padding: 3rem 1.5rem;
  background: var(--off-white);
}

.trust-container {
  max-width: 1200px;
  margin: 0 auto;
}

.trust-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.trust-badge {
  text-align: center;
  padding: 2rem;
  background: white;
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.trust-badge:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.trust-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  display: block;
}

.trust-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.trust-desc {
  color: var(--text-gray);
  line-height: 1.6;
  font-size: 0.95rem;
}

/* ============================================
   INFO/WARNING BOXES - FOR SUPPORT PAGES
   ============================================ */
.info-box {
  background: #EFF6FF;
  padding: 1.5rem;
  border-radius: 12px;
  border-left: 4px solid #3B82F6;
  margin: 1.5rem 0;
}

.warning-box {
  background: #FFF5F5;
  padding: 1.5rem;
  border-radius: 12px;
  border-left: 4px solid var(--primary);
  margin: 1.5rem 0;
}

.author-box {
  background: linear-gradient(135deg, #FFF9E6, #FFF4CC);
  padding: 1.5rem;
  border-radius: 12px;
  border-left: 4px solid var(--gold);
  margin: 1.5rem 0;
}

/* ============================================
   HERO ENHANCEMENTS
   ============================================ */
.hero::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -20%;
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(255,215,0,0.1) 0%, transparent 70%);
  border-radius: 50%;
  animation: pulse 8s ease-in-out infinite;
  will-change: transform;
}

.hero-container {
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.hero-content h1 {
  animation: fadeInUp 0.8s ease;
  position: relative;
}

.hero-content h1 .highlight {
  position: relative;
  color: var(--primary);
}

.hero-content h1 .highlight::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 12px;
  background: rgba(227,30,36,0.15);
  z-index: -1;
}

.hero-subtitle {
  animation: fadeInUp 0.8s ease 0.2s backwards;
  font-size: 1.25rem;
  color: var(--text-gray);
  margin-bottom: 2rem;
  line-height: 1.6;
}

.hero-cta {
  animation: fadeInUp 0.8s ease 0.4s backwards;
  display: flex;
  gap: 1rem;
  justify-content: flex-start;
  flex-wrap: wrap;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white;
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: var(--shadow-red);
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  display: inline-block;
  text-decoration: none;
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 40px rgba(227,30,36,0.35);
}

.btn-secondary {
  background: white;
  color: var(--primary);
  padding: 1rem 2.5rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1.1rem;
  border: 2px solid var(--primary);
  transition: all 0.3s ease;
  cursor: pointer;
  display: inline-block;
  text-decoration: none;
}

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

.btn-white {
  background: white;
  color: var(--primary);
  padding: 1.25rem 3rem;
  border-radius: 50px;
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  display: inline-block;
  text-decoration: none;
}

.btn-white:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,0.25);
}

/* ============================================
   HEADER ENHANCEMENTS
   ============================================ */
.header.scrolled {
  box-shadow: var(--shadow-md);
}

.logo img {
  transition: transform 0.3s ease;
}

.logo:hover img {
  transform: scale(1.05);
}

.nav-link {
  position: relative;
  transition: color 0.3s ease;
}

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

.nav-link:hover {
  color: var(--primary);
}

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

/* ============================================
   UTILITY CLASSES
   ============================================ */
.center-image {
  text-align: center;
  margin: 2rem 0;
}

.center-image img {
  max-width: 100%;
  display: block;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow: var(--shadow-md);
  transition: transform 0.3s ease;
}

.center-image img:hover {
  transform: scale(1.02);
}

/* ============================================
   GAME CARDS
   ============================================ */
.games-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.game-card {
  background: white;
  border-radius: 20px;
  padding: 2rem;
  border: 2px solid var(--gray);
  transition: all 0.4s ease;
  position: relative;
  overflow: hidden;
}

.game-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 0;
}

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

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

.game-card > * {
  position: relative;
  z-index: 1;
}

.game-card:hover h3,
.game-card:hover p {
  color: white;
}

.game-card:hover a {
  color: var(--gold);
}

/* ============================================
   FAQ SECTION - CRITICAL FIX FOR SUPPORT PAGES
   ============================================ */
.faq-container {
  max-width: 900px;
  margin: 0 auto;
}

.faq-item {
  background: white;
  border-radius: 16px;
  margin-bottom: 1rem;
  border: 1px solid var(--gray);
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-item:hover {
  box-shadow: var(--shadow-md);
}

.faq-question {
  padding: 1.5rem 2rem;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text);
  transition: all 0.3s ease;
  user-select: none;
}

.faq-question:hover {
  color: var(--primary);
  background: rgba(227,30,36,0.02);
}

.faq-icon {
  font-size: 1.5rem;
  color: var(--primary);
  transition: transform 0.3s ease;
  flex-shrink: 0;
  margin-left: 1rem;
}

.faq-item.active .faq-icon {
  transform: rotate(180deg);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.4s ease, padding 0.4s ease;
  padding: 0 2rem;
  color: var(--text-gray);
  line-height: 1.8;
}

.faq-item.active .faq-answer {
  max-height: 600px;
  padding: 0 2rem 1.5rem;
}

/* ============================================
   FOOTER - FOR SUPPORT PAGES
   ============================================ */
.footer {
  background: #1A1A1A;
  color: rgba(255,255,255,0.8);
  padding: 3rem 1.5rem 1.5rem;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
}

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

.footer-brand h3 {
  color: white;
  font-size: 1.25rem;
  margin-bottom: 1rem;
}

.footer-brand p {
  line-height: 1.7;
  font-size: 0.95rem;
}

.footer-column h4 {
  color: white;
  margin-bottom: 1rem;
  font-size: 1.1rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.footer-links a {
  color: rgba(255,255,255,0.7);
  transition: color 0.3s ease;
  text-decoration: none;
}

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

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 2rem;
  text-align: center;
  font-size: 0.9rem;
}

.footer-bottom p {
  margin: 0.5rem 0;
}

/* ============================================
   LINKS
   ============================================ */
.blue-link {
  color: #007BFF;
  font-weight: 600;
  transition: color 0.3s ease;
  text-decoration: underline;
}

.blue-link:hover {
  color: var(--primary);
}

/* ============================================
   TABLES
   ============================================ */
table {
  border-collapse: collapse;
  width: 100%;
  margin: 1.5rem 0;
}

th, td {
  padding: 12px;
  border: 1px solid var(--gray);
  text-align: left;
}

th {
  background: var(--light-gray);
  font-weight: 600;
  color: var(--text);
}

tr:hover {
  background: var(--off-white);
}

/* ============================================
   IMAGES
   ============================================ */
img {
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Tablet (1024px and below) */
@media (max-width: 1024px) {
  .hero-content h1 {
    font-size: 2.25rem !important;
  }
  
  h2, .section-title {
    font-size: 1.75rem !important;
  }
  
  .games-grid, .trust-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

/* Mobile (768px and below) */
@media (max-width: 768px) {
  .nav-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 70px;
    right: 20px;
    background: white;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    z-index: 1000;
  }
  
  .nav-menu.active {
    display: flex;
  }
  
  .hero {
    padding: 3rem 1rem;
  }
  
  .hero-content h1 {
    font-size: 2rem !important;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
  
  .hero-cta {
    flex-direction: column;
    width: 100%;
  }
  
  .btn-primary,
  .btn-secondary,
  .btn-white {
    width: 100%;
    text-align: center;
  }
  
  h2, .section-title {
    font-size: 1.5rem !important;
  }
  
  h3 {
    font-size: 1.25rem !important;
  }
  
  .games-grid, .trust-grid, .footer-grid {
    grid-template-columns: 1fr;
  }
  
  .card {
    padding: 1.5rem;
  }
  
  .faq-question {
    font-size: 1rem;
    padding: 1.25rem 1.5rem;
  }
  
  .faq-answer {
    padding: 0 1.5rem;
  }
  
  .faq-item.active .faq-answer {
    padding: 0 1.5rem 1.25rem;
  }
  
  .trust-badge {
    padding: 1.5rem;
  }
  
  .section-alt {
    padding: 2rem 1rem;
  }
  
  table {
    font-size: 0.9rem;
  }
  
  th, td {
    padding: 8px;
  }
}

/* Small Mobile (480px and below) */
@media (max-width: 480px) {
  .hero-content h1 {
    font-size: 1.75rem !important;
  }
  
  h2, .section-title {
    font-size: 1.35rem !important;
  }
  
  h3 {
    font-size: 1.15rem !important;
  }
  
  table {
    font-size: 0.85rem;
  }
  
  th, td {
    padding: 6px;
  }
  
  .game-card, .trust-badge {
    padding: 1.5rem;
  }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .header,
  .mobile-toggle,
  .nav-menu,
  .hero-cta,
  footer,
  .footer,
  .btn-primary,
  .btn-secondary,
  .btn-white {
    display: none;
  }
  
  body {
    font-size: 12pt;
    line-height: 1.5;
    color: #000;
  }
  
  h1, h2, h3 {
    page-break-after: avoid;
  }
  
  table, img, .card {
    page-break-inside: avoid;
  }
  
  a {
    color: #000;
    text-decoration: underline;
  }
}

/* ============================================
   ACCESSIBILITY
   ============================================ */

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Focus states for keyboard navigation */
a:focus,
button:focus,
.nav-link:focus,
.cta-button:focus,
.faq-question:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

/* Selection styling */
::selection {
  background: var(--primary);
  color: white;
}

::-moz-selection {
  background: var(--primary);
  color: white;
}

/* ============================================
   PERFORMANCE OPTIMIZATIONS
   ============================================ */

/* GPU acceleration for animations */
.game-card,
.trust-badge,
.btn-primary,
.btn-secondary,
.btn-white,
.logo img {
  will-change: transform;
}

/* Optimize font rendering */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* ============================================
   CUSTOM SCROLLBAR (Webkit browsers)
   ============================================ */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--light-gray);
}

::-webkit-scrollbar-thumb {
  background: var(--primary);
  border-radius: 5px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--primary-dark);
}

/* ============================================
   ADDITIONAL UTILITY CLASSES
   ============================================ */
.text-center {
  text-align: center;
}

.text-left {
  text-align: left;
}

.text-right {
  text-align: right;
}

.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }
.mt-4 { margin-top: 2rem; }

.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }

.p-1 { padding: 0.5rem; }
.p-2 { padding: 1rem; }
.p-3 { padding: 1.5rem; }
.p-4 { padding: 2rem; }

/* ============================================
   END OF STYLESHEET
   ============================================ */