/* Global Event Calendar - Custom Styles */

/* ===== CSS Custom Properties ===== */
:root {
  --primary-gold: #D4A44C;
  --primary-gold-light: #E8C882;
  --primary-burgundy: #8B2942;
  --primary-burgundy-dark: #6B1F33;
  --accent-orange: #E67E22;
  --accent-saffron: #F4A534;
  --dark-bg: #1A1A2E;
  --dark-bg-light: #252542;
  --light-bg: #FDF6E3;
  --light-bg-alt: #F5EDD6;
  --text-dark: #2D2D2D;
  --text-light: #F5F5F5;
  --text-muted: #6B7280;
}

/* ===== Base Styles ===== */
html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text-dark);
  overflow-x: hidden;
}

/* ===== Scroll Animations ===== */
.fade-in-section {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

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

/* Staggered animations for children */
.stagger-children > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.stagger-children.visible > *:nth-child(1) { transition-delay: 0.1s; }
.stagger-children.visible > *:nth-child(2) { transition-delay: 0.2s; }
.stagger-children.visible > *:nth-child(3) { transition-delay: 0.3s; }
.stagger-children.visible > *:nth-child(4) { transition-delay: 0.4s; }
.stagger-children.visible > *:nth-child(5) { transition-delay: 0.5s; }
.stagger-children.visible > *:nth-child(6) { transition-delay: 0.6s; }

.stagger-children.visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* ===== Hero Section ===== */
.hero-gradient {
  background: linear-gradient(135deg,
    var(--primary-burgundy) 0%,
    var(--primary-burgundy-dark) 30%,
    #4A1526 60%,
    var(--dark-bg) 100%
  );
  position: relative;
  overflow: hidden;
}

.hero-gradient::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(212, 164, 76, 0.15) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(139, 41, 66, 0.3) 0%, transparent 50%);
  pointer-events: none;
}

/* Decorative pattern overlay */
.hero-pattern {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  opacity: 0.05;
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23D4A44C' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
  pointer-events: none;
}

/* ===== Card Styles ===== */
.feature-card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.feature-icon {
  transition: transform 0.3s ease;
}

.feature-card:hover .feature-icon {
  transform: scale(1.1);
}

/* ===== Button Styles ===== */
.btn-primary {
  background: linear-gradient(135deg, var(--primary-gold) 0%, var(--accent-saffron) 100%);
  color: var(--text-dark);
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(212, 164, 76, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(212, 164, 76, 0.4);
}

.btn-secondary {
  background: transparent;
  border: 2px solid var(--primary-gold);
  color: var(--primary-gold);
  transition: all 0.3s ease;
}

.btn-secondary:hover {
  background: var(--primary-gold);
  color: var(--text-dark);
}

/* ===== Section Styles ===== */
.section-light {
  background-color: var(--light-bg);
}

.section-cream {
  background-color: var(--light-bg-alt);
}

.section-dark {
  background: linear-gradient(180deg, var(--dark-bg) 0%, var(--dark-bg-light) 100%);
  color: var(--text-light);
}

/* ===== Organization Diagram ===== */
.org-diagram {
  position: relative;
}

.org-node {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.org-node:hover {
  transform: scale(1.05);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
}

.org-line {
  stroke: var(--primary-gold);
  stroke-width: 2;
  stroke-dasharray: 5, 5;
  animation: dash 20s linear infinite;
}

@keyframes dash {
  to {
    stroke-dashoffset: -100;
  }
}

/* ===== Image Placeholders ===== */
.img-placeholder {
  background: linear-gradient(135deg, var(--light-bg-alt) 0%, #E8E0D0 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  font-size: 0.875rem;
  border: 2px dashed rgba(107, 114, 128, 0.3);
  border-radius: 0.75rem;
  min-height: 200px;
  transition: all 0.3s ease;
}

.img-placeholder:hover {
  border-color: var(--primary-gold);
  background: linear-gradient(135deg, #F5EDD6 0%, #E8DFC8 100%);
}

/* ===== Coming Soon Badge ===== */
.coming-soon-badge {
  background: linear-gradient(135deg, var(--primary-burgundy) 0%, var(--primary-burgundy-dark) 100%);
  color: var(--text-light);
  font-size: 0.75rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  display: inline-block;
}

/* ===== Footer ===== */
.footer-gradient {
  background: linear-gradient(180deg, var(--dark-bg-light) 0%, var(--dark-bg) 100%);
}

/* ===== Decorative Elements ===== */
.golden-border {
  border-color: var(--primary-gold);
}

.golden-text {
  color: var(--primary-gold);
}

.burgundy-text {
  color: var(--primary-burgundy);
}

/* Subtle glow effect */
.glow-gold {
  box-shadow: 0 0 30px rgba(212, 164, 76, 0.2);
}

/* ===== Responsive Adjustments ===== */
@media (max-width: 640px) {
  .hero-gradient {
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile */
  }

  .fade-in-section {
    transform: translateY(20px);
  }
}

/* ===== Scroll Progress Indicator ===== */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--primary-gold), var(--accent-saffron));
  z-index: 9999;
  transition: width 0.1s ease-out;
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
  width: 10px;
}

::-webkit-scrollbar-track {
  background: var(--dark-bg);
}

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

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

/* ===== Focus States for Accessibility ===== */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--primary-gold);
  outline-offset: 2px;
}

/* ===== Print Styles ===== */
@media print {
  .hero-gradient,
  .section-dark {
    background: white !important;
    color: black !important;
  }

  .fade-in-section {
    opacity: 1 !important;
    transform: none !important;
  }
}
