/* MICS - Mullingar Islamic Cultural Society Styles */

html {
  overflow-x: hidden;
  max-width: 100%;
}

body {
  font: 400 15px 'Inter', sans-serif;
  line-height: 1.8;
  color: #818181;
  overflow-x: hidden;
  max-width: 100%;
}

h2 {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  text-transform: uppercase;
  color: #303030;
  font-weight: 600;
  margin-bottom: 30px;
  position: relative;
  letter-spacing: 1px;
}

h2::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: linear-gradient(90deg, #0d7849 0%, #ff7900 100%);
  border-radius: 2px;
}

h4 {
  font-family: 'Inter', sans-serif;
  font-size: 19px;
  line-height: 1.375em;
  color: #303030;
  font-weight: 500;
  margin-bottom: 30px;
}

.jumbotron {
  background-color: #1abc9c;
  color: #fff;
  padding: 100px 25px;
  font-family: 'Inter', sans-serif;
}

.container-fluid {
  padding: 60px 50px;
}

.bg-grey {
  background-color: #f6f6f6;
}

.logo-small {
  color: #ff7900;
  font-size: 50px;
}

.logo {
  color: #ff7900;
  font-size: 200px;
}

.thumbnail {
  padding: 0 0 15px 0;
  border: none;
  border-radius: 0;
}

.thumbnail img {
  width: 100%;
  height: 100%;
  margin-bottom: 10px;
}

.carousel-control.right, .carousel-control.left {
  background-image: none;
  color: #1abc9c;
}

.carousel-indicators li {
  border-color: #1abc9c;
}

.carousel-indicators li.active {
  background-color: #1abc9c;
}

.item h4 {
  font-size: 19px;
  line-height: 1.375em;
  font-weight: 400;
  font-style: italic;
  margin: 70px 0;
}

.item span {
  font-style: normal;
}

.panel {
  border: 1px solid #1abc9c; 
  border-radius:0 !important;
  transition: box-shadow 0.5s;
}

.panel:hover {
  box-shadow: 5px 0px 40px rgba(0,0,0, .2);
}

.panel-footer .btn:hover {
  border: 1px solid #1abc9c;
  background-color: #fff !important;
  color: #1abc9c;
}

.panel-heading {
  color: #fff !important;
  background-color: #1abc9c !important;
  padding: 25px;
  border-bottom: 1px solid transparent;
  border-top-left-radius: 0px;
  border-top-right-radius: 0px;
  border-bottom-left-radius: 0px;
  border-bottom-right-radius: 0px;
}

.panel-footer {
  background-color: white !important;
}

.panel-footer h3 {
  font-size: 32px;
}

.panel-footer h4 {
  color: #aaa;
  font-size: 14px;
}

.panel-footer .btn {
  margin: 15px 0;
  background-color: #1abc9c;
  color: #fff;
}

/* Navbar Styles */
.navbar {
  margin-bottom: 0;
  background-color: #0d7849;
  background: linear-gradient(135deg, #0d7849 0%, #0a5d38 100%);
  box-shadow: 0 4px 20px rgba(0,0,0,0.15);
  backdrop-filter: blur(10px);
  z-index: 9999;
  border: 0;
  font-size: 14px !important;
  line-height: 1.6 !important;
  letter-spacing: 0.5px;
  border-radius: 0;
  font-family: 'Inter', sans-serif;
  min-height: 75px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-scrolled {
  min-height: 65px;
  box-shadow: 0 2px 30px rgba(0,0,0,0.25);
  background: linear-gradient(135deg, rgba(13, 120, 73, 0.95) 0%, rgba(10, 93, 56, 0.95) 100%);
}

.navbar-brand {
  padding: 10px 20px !important;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.brand-container {
  display: flex;
  align-items: center;
  gap: 15px;
  transition: all 0.3s ease;
}

.brand-logo {
  height: 50px;
  width: auto;
  filter: brightness(1.1) drop-shadow(0 2px 4px rgba(0,0,0,0.1));
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-brand:hover .brand-logo {
  transform: scale(1.05) rotate(2deg);
  filter: brightness(1.2) drop-shadow(0 4px 8px rgba(0,0,0,0.2));
}

.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.brand-name {
  font-family: 'Playfair Display', serif;
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  letter-spacing: 1px;
  line-height: 1;
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
  background: linear-gradient(135deg, #fff 0%, #f0f9f5 100%);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-subtitle {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.85);
  letter-spacing: 0.8px;
  text-transform: uppercase;
  line-height: 1;
}

.navbar li a, .navbar .navbar-brand {
  color: #fff !important;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-nav {
  margin-top: 5px;
}

.navbar-nav > li > a {
  padding: 20px 18px !important;
  font-family: 'Inter', sans-serif;
  font-weight: 600 !important;
  font-size: 13px !important;
  text-transform: uppercase;
  letter-spacing: 1px;
  position: relative;
  border-radius: 0;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  color: rgba(255, 255, 255, 0.9) !important;
}

.navbar-nav > li > a:before {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 0;
  height: 3px;
  background: linear-gradient(90deg, #fff 0%, #ff7900 100%);
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  transform: translateX(-50%);
  border-radius: 2px 2px 0 0;
}

.navbar-nav li a:hover, .navbar-nav li.active a {
  color: #fff !important;
  background-color: rgba(255,255,255,0.12) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  backdrop-filter: blur(5px);
}

.navbar-nav li a:hover:before, .navbar-nav li.active a:before {
  width: 85%;
}

.navbar-default .navbar-toggle {
  border: 2px solid rgba(255,255,255,0.4);
  background-color: rgba(255,255,255,0.1);
  border-radius: 8px;
  padding: 10px 12px;
  margin-top: 20px;
  margin-right: 20px;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(5px);
}

.navbar-default .navbar-toggle:hover, .navbar-default .navbar-toggle:focus {
  background-color: rgba(255,255,255,0.25);
  border-color: rgba(255,255,255,0.7);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.navbar-default .navbar-toggle .icon-bar {
  background-color: #fff;
  height: 3px;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.navbar-default .navbar-toggle:hover .icon-bar {
  background-color: #fff;
  box-shadow: 0 0 5px rgba(255,255,255,0.5);
}

/* Responsive Brand Styles */
@media (max-width: 767px) {
  .navbar {
    min-height: 65px;
  }
  
  .navbar-brand {
    padding: 8px 15px !important;
  }
  
  .brand-container {
    gap: 10px;
  }
  
  .brand-logo {
    height: 40px;
  }
  
  .brand-name {
    font-size: 22px;
  }
  
  .brand-subtitle {
    font-size: 9px;
    letter-spacing: 0.5px;
  }
  
  .navbar-nav > li > a {
    padding: 15px 20px !important;
    font-size: 14px !important;
    letter-spacing: 0.8px;
  }
}

@media (max-width: 480px) {
  .brand-subtitle {
    display: none;
  }
  
  .brand-name {
    font-size: 20px;
  }
  
  .brand-logo {
    height: 35px;
  }
}

.navbar-collapse {
  border-top: none !important;
  box-shadow: none !important;
}

/* Mobile navbar improvements */
@media (max-width: 767px) {
  .navbar-nav {
    margin-top: 0;
    background-color: rgba(13, 120, 73, 0.98);
    border-radius: 0 0 8px 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  }
  .navbar-nav > li > a {
    padding: 15px 25px !important;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    font-size: 14px !important;
  }
  .navbar-nav > li:last-child > a {
    border-bottom: none;
  }
  .navbar-nav > li > a:before {
    display: none;
  }
  .navbar-brand {
    font-size: 20px !important;
    padding: 12px 15px !important;
  }
  .navbar-brand img {
    height: 35px;
    margin-right: 8px;
  }
}

footer .glyphicon {
  font-size: 20px;
  margin-bottom: 20px;
  color: #ff7900;
}

/* Animations */
.slideanim {
  opacity:0;
}

.slideInDown {
  animation-name: slideInDown; 
  animation-duration: 1s; 
  opacity: 1;
}

@keyframes slideInDown {
  0% {
    opacity: 0;
    transform: translateY(-100%);
  } 
  100% {
    opacity: 1;
    transform: translateY(0%);
  }
}

@media screen and (max-width: 768px) {
  /* Mobile-first responsive fixes */
  .container-fluid {
    padding: 40px 15px;
  }
  
  .col-sm-4 {
    text-align: center;
    margin: 25px 0;
  }
  
  .btn-lg {
    width: 100%;
    margin-bottom: 35px;
  }
  
  .hero-section {
    padding: 80px 15px;
    min-height: 60vh;
    background: linear-gradient(135deg, #0d7849 0%, #0a5d38 50%, #1e7e5a 100%);
    width: 100vw;
    max-width: 100%;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    box-sizing: border-box;
  }
  
  .hero-section h1 {
    font-size: 4em;
    letter-spacing: 2px;
  }
  
  .hero-section h2 {
    font-size: 1.6em;
  }
  
  .hero-section p {
    font-size: 1.2em;
    padding: 0 20px;
  }
  
  .hero-section .btn {
    display: block;
    width: 85%;
    margin: 15px auto;
    padding: 15px 25px;
    font-size: 14px;
  }
  
  .hero-floating-crescent {
    font-size: 100px;
    /* Additional mobile fixes for Unicode rendering */
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.15);
    font-variant-emoji: text;
  }
  
  .hero-floating-star {
    font-size: 30px;
  }
  
  /* Ensure all sections use full width on mobile */
  .row {
    margin-left: 0;
    margin-right: 0;
  }
  
  .col-sm-4, .col-sm-6, .col-sm-8, .col-md-4, .col-md-6, .col-md-8 {
    padding-left: 15px;
    padding-right: 15px;
  }
}

@media screen and (max-width: 480px) {
  .logo {
    font-size: 150px;
  }
  
  /* Enhanced mobile responsiveness */
  .container-fluid {
    padding: 30px 10px;
  }
  
  .hero-section {
    padding: 60px 10px;
    min-height: 50vh;
    background: linear-gradient(135deg, #0d7849 0%, #0a5d38 100%);
    width: 100vw;
    max-width: 100%;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    box-sizing: border-box;
  }
  
  .hero-section h1 {
    font-size: 3.2em;
    letter-spacing: 1px;
  }
  
  .hero-section h2 {
    font-size: 1.3em;
  }
  
  .hero-section p {
    font-size: 1.1em;
    padding: 0 10px;
  }
  
  .hero-section .btn {
    width: 90%;
    margin: 12px auto;
    padding: 12px 20px;
    font-size: 13px;
  }
  
  .hero-floating-crescent {
    font-size: 80px;
    /* Enhanced mobile Unicode support */
    -webkit-text-stroke: 1px rgba(255, 255, 255, 0.2);
    font-variant-emoji: text;
    /* Prevent emoji fallback on very small screens */
    -webkit-font-feature-settings: "liga" off, "clig" off, "kern" off;
    font-feature-settings: "liga" off, "clig" off, "kern" off;
  }
  
  .hero-floating-star {
    font-size: 25px;
  }
  
  /* Ensure full width on very small screens */
  .col-sm-4, .col-sm-6, .col-sm-8, .col-md-4, .col-md-6, .col-md-8 {
    padding-left: 10px;
    padding-right: 10px;
  }
  
  /* Very small screen timetable adjustments */
  .timetable-container {
    padding: 15px 5px;
    margin: 0 2px;
  }
  
  .prayer-times-table {
    font-size: 10px;
  }
  
  .prayer-times-table th,
  .prayer-times-table td {
    padding: 4px 2px;
  }
  
  .prayer-name {
    font-size: 10px;
  }
  
  .prayer-time, .iqama-time {
    font-size: 10px;
  }
  
  .status-badge {
    padding: 1px 3px;
    font-size: 8px;
  }
  
  .next-prayer-container {
    margin: 0 2px;
    padding: 15px 10px;
  }
  
  .time-value {
    font-size: 16px;
  }
  
  .time-separator {
    font-size: 14px;
    margin: 0 3px;
  }
}

/* MICS Custom Styles */
.navbar-scrolled {
  background: linear-gradient(135deg, rgba(13, 120, 73, 0.95) 0%, rgba(10, 93, 56, 0.95) 100%) !important;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.hero-section {
  background: linear-gradient(135deg, #0d7849 0%, #0a5d38 30%, #1e7e5a 60%, #ff7900 100%);
  color: #fff;
  padding: 120px 0;
  text-align: center;
  min-height: 80vh;
  width: 100%;
  max-width: 100%;
  display: flex;
  align-items: center;
  position: relative;
  overflow: hidden;
  box-sizing: border-box;
}

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

.hero-section::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 40%;
  height: 40%;
  background: radial-gradient(ellipse at bottom right, rgba(255, 121, 0, 0.15) 0%, rgba(255, 121, 0, 0.08) 40%, transparent 70%);
  pointer-events: none;
  z-index: 1;
}

.hero-section .container {
  position: relative;
  z-index: 2;
}

.hero-floating-elements {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 1;
}

.hero-floating-crescent {
  position: absolute;
  color: rgba(255, 255, 255, 0.15);
  font-size: 150px;
  animation: heroFloat 12s ease-in-out infinite;
  text-shadow: 0 0 30px rgba(255, 255, 255, 0.3);
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
  transition: all 0.3s ease;
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
  /* Add padding for better hit area */
  padding: 20px;
  margin: -20px;
  z-index: 10;
  
  /* Comprehensive font stack for Unicode symbol support */
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Arial Unicode MS', 'Symbola', 'DejaVu Sans', 'Noto Emoji', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', 'Liberation Sans', FreeSans, sans-serif;
  
  /* Prevent emoji rendering on mobile devices */
  font-variant-emoji: text;
  -webkit-text-stroke: 1px rgba(255, 255, 255, 0.1);
  font-feature-settings: "liga" 0, "clig" 0, "calt" 0;
  text-rendering: optimizeSpeed;
  
  /* CSS-based crescent fallback for mobile devices */
  position: relative;
}

.hero-floating-crescent::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 120px;
  height: 120px;
  border: 8px solid currentColor;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.hero-floating-crescent::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 55%;
  width: 100px;
  height: 100px;
  background: var(--hero-bg-color, #1a2332);
  border-radius: 50%;
  transform: translate(-50%, -50%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* Fallback for when Unicode fails on mobile */
@supports not (font-variant-emoji: text) {
  .hero-floating-crescent {
    font-size: 0;
  }
  
  .hero-floating-crescent::before,
  .hero-floating-crescent::after {
    opacity: 1;
  }
}

.hero-floating-crescent:hover {
  animation-play-state: paused;
  transform: scale(1.2) rotate(360deg) !important;
  color: rgba(255, 255, 255, 0.4) !important;
  text-shadow: 0 0 50px rgba(255, 255, 255, 0.8) !important;
  filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.6)) hue-rotate(45deg) !important;
}

.hero-floating-star {
  position: absolute;
  color: rgba(255, 255, 255, 0.25);
  font-size: 45px;
  animation: heroTwinkle 8s ease-in-out infinite;
  text-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3));
  transition: all 0.3s ease;
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
  /* Add padding for better hit area */
  padding: 15px;
  margin: -15px;
  z-index: 10;
}

.hero-floating-star:hover {
  animation-play-state: paused;
  transform: scale(1.5) rotate(720deg) !important;
  color: rgba(255, 255, 255, 0.6) !important;
  text-shadow: 0 0 40px rgba(255, 255, 255, 1) !important;
  filter: drop-shadow(0 0 25px rgba(255, 255, 255, 0.8)) hue-rotate(90deg) brightness(1.5) !important;
}

/* Exciting Animation Variants */
.hero-floating-crescent.spiral {
  animation: heroSpiral 15s ease-in-out infinite;
}

.hero-floating-star.pulse {
  animation: heroPulse 10s ease-in-out infinite;
}

.hero-floating-star.orbit {
  animation: heroOrbit 18s linear infinite;
}

/* Interactive Animation States */
.hero-floating-crescent:active {
  animation: heroPulse 2s ease-in-out;
  transform: scale(2) rotate(1080deg) !important;
  color: rgba(255, 121, 0, 0.8) !important;
  text-shadow: 0 0 60px rgba(255, 121, 0, 1) !important;
  filter: drop-shadow(0 0 30px rgba(255, 121, 0, 1)) brightness(2) !important;
}

.hero-floating-star:active {
  animation: heroSpiral 3s ease-in-out;
  transform: scale(2.5) rotate(1440deg) !important;
  color: rgba(13, 120, 73, 0.9) !important;
  text-shadow: 0 0 70px rgba(13, 120, 73, 1) !important;
  filter: drop-shadow(0 0 35px rgba(13, 120, 73, 1)) brightness(2.5) saturate(3) !important;
}

/* Focus States for Accessibility */
.hero-floating-crescent:focus,
.hero-floating-star:focus {
  outline: 3px solid rgba(255, 121, 0, 0.7);
  outline-offset: 5px;
  animation-play-state: paused;
  transform: scale(1.3) !important;
  color: rgba(255, 121, 0, 0.6) !important;
  text-shadow: 0 0 50px rgba(255, 121, 0, 0.9) !important;
  border-radius: 50%;
}

/* Enhanced visibility for focused elements */
.hero-floating-crescent:focus-visible,
.hero-floating-star:focus-visible {
  outline: 4px solid rgba(255, 121, 0, 0.9);
  outline-offset: 8px;
  background: rgba(255, 121, 0, 0.1);
  border-radius: 50%;
}

/* Advanced Interactive Effects */
.hover-effect {
  animation-play-state: paused !important;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.clicked {
  animation: explosiveClick 2s ease-out !important;
}

@keyframes explosiveClick {
  0% {
    transform: scale(1) rotate(0deg);
  }
  10% {
    transform: scale(3) rotate(180deg);
    opacity: 1;
    filter: hue-rotate(0deg) brightness(3) saturate(3);
  }
  30% {
    transform: scale(2.5) rotate(360deg);
    opacity: 0.8;
    filter: hue-rotate(120deg) brightness(2.5) saturate(2.5);
  }
  50% {
    transform: scale(2) rotate(540deg);
    opacity: 0.6;
    filter: hue-rotate(240deg) brightness(2) saturate(2);
  }
  70% {
    transform: scale(1.5) rotate(720deg);
    opacity: 0.4;
    filter: hue-rotate(300deg) brightness(1.5) saturate(1.5);
  }
  100% {
    transform: scale(1) rotate(1080deg);
    opacity: 0.2;
    filter: hue-rotate(360deg) brightness(1) saturate(1);
  }
}

.click-ripple {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 121, 0, 0.8) 0%, rgba(255, 255, 255, 0.4) 50%, transparent 100%);
  transform: translate(-50%, -50%) scale(0);
  animation: rippleEffect 1s ease-out;
  pointer-events: none;
}

@keyframes rippleEffect {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(10);
    opacity: 0;
  }
}

.multi-click-effect {
  animation: celebrationBurst 3s ease-in-out !important;
}

@keyframes celebrationBurst {
  0%, 100% {
    transform: scale(1) rotate(0deg);
    filter: hue-rotate(0deg) brightness(1) saturate(1);
  }
  10% {
    transform: scale(4) rotate(360deg);
    filter: hue-rotate(60deg) brightness(4) saturate(4);
  }
  20% {
    transform: scale(3.5) rotate(720deg);
    filter: hue-rotate(120deg) brightness(3.5) saturate(3.5);
  }
  30% {
    transform: scale(3) rotate(1080deg);
    filter: hue-rotate(180deg) brightness(3) saturate(3);
  }
  40% {
    transform: scale(2.5) rotate(1440deg);
    filter: hue-rotate(240deg) brightness(2.5) saturate(2.5);
  }
  50% {
    transform: scale(2) rotate(1800deg);
    filter: hue-rotate(300deg) brightness(2) saturate(2);
  }
  60% {
    transform: scale(3) rotate(2160deg);
    filter: hue-rotate(360deg) brightness(3) saturate(3);
  }
  70% {
    transform: scale(2.5) rotate(2520deg);
    filter: hue-rotate(420deg) brightness(2.5) saturate(2.5);
  }
  80% {
    transform: scale(2) rotate(2880deg);
    filter: hue-rotate(480deg) brightness(2) saturate(2);
  }
  90% {
    transform: scale(1.5) rotate(3240deg);
    filter: hue-rotate(540deg) brightness(1.5) saturate(1.5);
  }
}

.celebration-mode {
  background: radial-gradient(circle at center, rgba(255, 121, 0, 0.1) 0%, rgba(13, 120, 73, 0.1) 50%, rgba(255, 255, 255, 0.05) 100%) !important;
  animation: celebrationBackground 3s ease-in-out;
}

@keyframes celebrationBackground {
  0%, 100% {
    filter: hue-rotate(0deg) brightness(1);
  }
  25% {
    filter: hue-rotate(90deg) brightness(1.2);
  }
  50% {
    filter: hue-rotate(180deg) brightness(1.4);
  }
  75% {
    filter: hue-rotate(270deg) brightness(1.2);
  }
}

.natural-movement {
  animation-delay: var(--random-delay, 0s);
  animation-duration: calc(var(--base-duration, 10s) + var(--random-offset, 0s));
}

.hero-floating-crescent:nth-child(1) {
  top: 15%;
  left: 8%;
  animation-delay: 0s;
}

.hero-floating-crescent:nth-child(2) {
  top: 25%;
  right: 12%;
  animation-delay: 3s;
}

.hero-floating-crescent:nth-child(3) {
  bottom: 20%;
  left: 15%;
  animation-delay: 6s;
}

.hero-floating-star:nth-child(4) {
  top: 20%;
  left: 75%;
  animation-delay: 1s;
}

.hero-floating-star:nth-child(5) {
  top: 65%;
  left: 3%;
  animation-delay: 4s;
}

.hero-floating-star:nth-child(6) {
  top: 85%;
  right: 20%;
  animation-delay: 7s;
}

.hero-floating-star:nth-child(7) {
  top: 40%;
  right: 3%;
  animation-delay: 2.5s;
}

.hero-floating-star:nth-child(8) {
  bottom: 35%;
  left: 85%;
  animation-delay: 5.5s;
}

.hero-floating-star:nth-child(9) {
  top: 8%;
  left: 45%;
  animation-delay: 1.8s;
}

/* Additional elements positioning */
.hero-floating-star:nth-child(10) {
  top: 25%;
  left: 75%;
  animation-delay: 3.2s;
}

.hero-floating-crescent:nth-child(11) {
  top: 60%;
  right: 40%;
  animation-delay: 6s;
}

.hero-floating-star:nth-child(12) {
  bottom: 20%;
  left: 30%;
  animation-delay: 4.5s;
}

@keyframes heroFloat {
  0%, 100% { 
    transform: translateY(0px) rotate(0deg) scale(1);
    opacity: 0.15;
  }
  25% { 
    transform: translateY(-30px) rotate(90deg) scale(1.1);
    opacity: 0.25;
  }
  50% { 
    transform: translateY(-15px) rotate(180deg) scale(0.9);
    opacity: 0.2;
  }
  75% { 
    transform: translateY(-25px) rotate(270deg) scale(1.05);
    opacity: 0.3;
  }
}

@keyframes heroTwinkle {
  0%, 100% { 
    transform: scale(1) rotate(0deg);
    opacity: 0.25;
    filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.3)) hue-rotate(0deg);
  }
  20% { 
    transform: scale(1.3) rotate(72deg);
    opacity: 0.6;
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.6)) hue-rotate(60deg);
  }
  40% { 
    transform: scale(0.8) rotate(144deg);
    opacity: 0.4;
    filter: drop-shadow(0 0 20px rgba(255, 255, 255, 0.4)) hue-rotate(120deg);
  }
  60% { 
    transform: scale(1.2) rotate(216deg);
    opacity: 0.7;
    filter: drop-shadow(0 0 25px rgba(255, 255, 255, 0.7)) hue-rotate(180deg);
  }
  80% { 
    transform: scale(0.9) rotate(288deg);
    opacity: 0.35;
    filter: drop-shadow(0 0 12px rgba(255, 255, 255, 0.5)) hue-rotate(240deg);
  }
}

/* Additional Advanced Floating Element Animations */
@keyframes heroSpiral {
  0% {
    transform: translateX(0) translateY(0) rotate(0deg) scale(1);
    opacity: 0.2;
    filter: hue-rotate(0deg) drop-shadow(0 0 8px rgba(255, 255, 255, 0.2));
  }
  25% {
    transform: translateX(50px) translateY(-30px) rotate(90deg) scale(1.2);
    opacity: 0.4;
    filter: hue-rotate(60deg) drop-shadow(0 0 15px rgba(255, 121, 0, 0.3));
  }
  50% {
    transform: translateX(30px) translateY(-60px) rotate(180deg) scale(0.9);
    opacity: 0.6;
    filter: hue-rotate(120deg) drop-shadow(0 0 20px rgba(13, 120, 73, 0.4));
  }
  75% {
    transform: translateX(-20px) translateY(-40px) rotate(270deg) scale(1.3);
    opacity: 0.3;
    filter: hue-rotate(180deg) drop-shadow(0 0 25px rgba(255, 121, 0, 0.5));
  }
  100% {
    transform: translateX(0) translateY(0) rotate(360deg) scale(1);
    opacity: 0.2;
    filter: hue-rotate(240deg) drop-shadow(0 0 12px rgba(255, 255, 255, 0.3));
  }
}

@keyframes heroPulse {
  0% {
    transform: scale(1) rotate(0deg);
    opacity: 0.1;
    text-shadow: 0 0 15px rgba(255, 255, 255, 0.2);
    filter: hue-rotate(0deg) brightness(1) saturate(1);
  }
  20% {
    transform: scale(1.4) rotate(45deg);
    opacity: 0.5;
    text-shadow: 0 0 30px rgba(255, 121, 0, 0.6);
    filter: hue-rotate(72deg) brightness(1.3) saturate(1.5);
  }
  40% {
    transform: scale(0.8) rotate(90deg);
    opacity: 0.3;
    text-shadow: 0 0 25px rgba(13, 120, 73, 0.5);
    filter: hue-rotate(144deg) brightness(1.1) saturate(1.2);
  }
  60% {
    transform: scale(1.2) rotate(180deg);
    opacity: 0.7;
    text-shadow: 0 0 40px rgba(255, 121, 0, 0.8);
    filter: hue-rotate(216deg) brightness(1.5) saturate(2);
  }
  80% {
    transform: scale(0.9) rotate(270deg);
    opacity: 0.4;
    text-shadow: 0 0 35px rgba(13, 120, 73, 0.7);
    filter: hue-rotate(288deg) brightness(1.2) saturate(1.3);
  }
  100% {
    transform: scale(1) rotate(360deg);
    opacity: 0.1;
    text-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    filter: hue-rotate(360deg) brightness(1) saturate(1);
  }
}

@keyframes heroOrbit {
  0% {
    transform: translateX(-50px) translateY(50px) rotate(0deg) scale(0.8);
    opacity: 0.2;
    filter: hue-rotate(0deg) drop-shadow(0 0 10px rgba(255, 255, 255, 0.2));
  }
  33% {
    transform: translateX(50px) translateY(-25px) rotate(120deg) scale(1.1);
    opacity: 0.6;
    filter: hue-rotate(120deg) drop-shadow(0 0 20px rgba(255, 121, 0, 0.4));
  }
  66% {
    transform: translateX(-25px) translateY(-50px) rotate(240deg) scale(1.3);
    opacity: 0.4;
    filter: hue-rotate(240deg) drop-shadow(0 0 25px rgba(13, 120, 73, 0.5));
  }
  100% {
    transform: translateX(-50px) translateY(50px) rotate(360deg) scale(0.8);
    opacity: 0.2;
    filter: hue-rotate(360deg) drop-shadow(0 0 15px rgba(255, 255, 255, 0.3));
  }
}

.hero-section h1 {
  font-family: 'Playfair Display', serif;
  font-size: 6em;
  margin-bottom: 20px;
  text-shadow: 0 4px 20px rgba(0,0,0,0.3), 0 0 40px rgba(255,255,255,0.1);
  font-weight: 700;
  letter-spacing: 4px;
  background: linear-gradient(45deg, #fff, #e8f5e8, #fff);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: shimmer 3s ease-in-out infinite;
}

.hero-section h2 {
  font-family: 'Inter', sans-serif;
  font-size: 2.2em;
  font-weight: 400;
  margin-bottom: 30px;
  text-shadow: 0 2px 10px rgba(0,0,0,0.3);
  color: rgba(255, 255, 255, 0.95);
  text-transform: none;
  letter-spacing: 1px;
}

.hero-section p {
  font-family: 'Inter', sans-serif;
  font-size: 1.4em;
  font-weight: 300;
  margin-bottom: 50px;
  text-shadow: 0 1px 5px rgba(0,0,0,0.3);
  max-width: 700px;
  margin-left: auto;
  margin-right: auto;
  color: rgba(255, 255, 255, 0.9);
  line-height: 1.6;
}

@keyframes shimmer {
  0%, 100% { 
    background-position: -200% center; 
  }
  50% { 
    background-position: 200% center; 
  }
}

.hero-section .btn {
  margin: 15px;
  padding: 18px 40px;
  font-size: 16px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  border-radius: 50px;
  transition: all 0.4s ease;
  box-shadow: 0 6px 20px rgba(0,0,0,0.2);
  border: 2px solid transparent;
}

.hero-section .btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 35px rgba(0,0,0,0.3);
}

.hero-section .btn-outline-light {
  border: 2px solid rgba(255,255,255,0.8);
  color: #fff;
  background: rgba(255,255,255,0.1);
  backdrop-filter: blur(10px);
}

.hero-section .btn-outline-light:hover {
  background: #ff7900;
  color: #fff;
  border-color: #ff7900;
  box-shadow: 0 12px 35px rgba(255, 121, 0, 0.4);
}

.islamic-green {
  background-color: #0d7849 !important;
  color: #fff !important;
}

.islamic-green-btn {
  background-color: #0d7849;
  border-color: #0d7849;
  color: #fff;
}

.islamic-green-btn:hover {
  background-color: #0a5d38;
  border-color: #0a5d38;
}

/* Irish Orange Theme Colors */
.irish-orange {
  background-color: #ff7900 !important;
  color: #fff !important;
}

.irish-orange-btn {
  background-color: #ff7900;
  border-color: #ff7900;
  color: #fff;
  transition: all 0.3s ease;
}

.irish-orange-btn:hover {
  background-color: #e86a00;
  border-color: #e86a00;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 121, 0, 0.4);
}

.irish-accent {
  color: #ff7900 !important;
}

/* Timetable Styles */
.timetable-container {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  padding: 30px;
  margin-bottom: 20px;
  overflow-x: auto;
}

.prayer-times-header h3 {
  color: #0d7849;
  font-weight: 600;
  margin-bottom: 25px;
  text-transform: none;
}

.prayer-times-table {
  margin-bottom: 0;
  font-size: 14px;
  min-width: 100%;
  white-space: nowrap;
}

.prayer-times-table th {
  background-color: #0d7849;
  color: #fff;
  border: none;
  font-weight: 600;
  text-align: center;
  padding: 15px 10px;
}

.prayer-times-table td {
  padding: 12px 10px;
  text-align: center;
  vertical-align: middle;
  border-color: #eee;
}

.prayer-name {
  font-weight: 600;
  color: #333;
}

.prayer-name .glyphicon {
  margin-right: 8px;
  color: #0d7849;
}

.prayer-time, .iqama-time {
  font-family: 'Courier New', monospace;
  font-weight: bold;
  font-size: 16px;
}

.prayer-passed {
  background-color: rgba(108, 117, 125, 0.1);
  color: #6c757d;
}

.prayer-soon {
  background-color: rgba(255, 193, 7, 0.1);
  color: #856404;
}

.prayer-upcoming {
  background-color: rgba(40, 167, 69, 0.1);
  color: #155724;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.status-passed {
  background-color: #6c757d;
  color: #fff;
}

.status-soon {
  background-color: #ffc107;
  color: #212529;
}

.status-upcoming {
  background-color: #28a745;
  color: #fff;
}

.next-prayer-container {
  background: linear-gradient(135deg, #0d7849 0%, #0a5d38 100%);
  color: #fff;
  border-radius: 12px;
  padding: 25px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(13, 120, 73, 0.3);
}

.next-prayer-info h4 {
  margin-bottom: 20px;
  font-size: 18px;
  font-weight: 600;
  color: #fff;
}

.countdown-timer {
  display: flex;
  justify-content: center;
  align-items: center;
  margin-bottom: 15px;
  font-family: 'Courier New', monospace;
}

.time-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin: 0 5px;
}

.time-value {
  font-size: 24px;
  font-weight: bold;
  line-height: 1;
}

.time-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-top: 2px;
  opacity: 0.8;
}

.time-separator {
  font-size: 20px;
  font-weight: bold;
  margin: 0 8px;
}

.target-time {
  font-size: 14px;
  margin: 0;
  opacity: 0.9;
}

@media (max-width: 768px) {
  .timetable-container {
    padding: 20px 10px;
    margin: 0 5px;
  }
  
  .prayer-times-table {
    font-size: 11px;
    width: 100%;
    table-layout: fixed;
  }
  
  .prayer-times-table th,
  .prayer-times-table td {
    padding: 6px 3px;
    word-wrap: break-word;
  }
  
  .prayer-times-table th {
    font-size: 10px;
  }
  
  .prayer-name {
    font-size: 11px;
  }
  
  .prayer-name .glyphicon {
    margin-right: 3px;
    font-size: 10px;
  }
  
  .prayer-time, .iqama-time {
    font-size: 12px;
  }
  
  .status-badge {
    padding: 2px 4px;
    font-size: 9px;
  }
  
  .next-prayer-container {
    margin: 0 5px;
    padding: 20px 15px;
  }
  
  .time-value {
    font-size: 18px;
  }
  
  .time-separator {
    font-size: 16px;
    margin: 0 5px;
  }
  
  .time-label {
    font-size: 9px;
  }
  
  .target-time {
    font-size: 12px;
  }
}

/* Donation Section Styles */
.main-donation-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.1);
  padding: 40px;
  margin-bottom: 30px;
  border: 2px solid #0d7849;
}

.donation-btn {
  font-size: 18px;
  padding: 15px 30px;
  border-radius: 8px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 600;
}

.donation-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(13, 120, 73, 0.4);
}

.barcode-container {
  text-align: center;
  padding: 20px;
  background: #f8f9fa;
  border-radius: 8px;
  border: 1px solid #dee2e6;
}

.donation-barcode {
  max-width: 150px;
  height: auto;
  border: 2px solid #0d7849;
  border-radius: 8px;
  padding: 10px;
  background: #fff;
}

.donation-features p {
  text-align: left;
  margin-bottom: 8px;
  font-size: 14px;
}

.donation-category-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  padding: 30px 25px;
  margin-bottom: 30px;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border-top: 4px solid #0d7849;
}

.donation-category-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.category-icon {
  margin-bottom: 20px;
}

.category-icon span {
  font-size: 48px;
  color: #0d7849;
  display: inline-block;
  padding: 20px;
  background: rgba(13, 120, 73, 0.1);
  border-radius: 50%;
  width: 90px;
  height: 90px;
  line-height: 50px;
}

.donation-category-card h4 {
  color: #0d7849;
  font-weight: 600;
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.donation-category-card p {
  color: #666;
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.category-list {
  list-style: none;
  padding: 0;
  margin-bottom: 25px;
  text-align: left;
}

.category-list li {
  padding: 5px 0;
  color: #555;
  font-size: 13px;
  position: relative;
  padding-left: 20px;
}

.category-list li:before {
  content: "✓";
  color: #0d7849;
  font-weight: bold;
  position: absolute;
  left: 0;
  top: 5px;
}

.donation-info-banner {
  background: linear-gradient(135deg, rgba(13, 120, 73, 0.1) 0%, rgba(10, 93, 56, 0.1) 100%);
  border: 1px solid rgba(13, 120, 73, 0.2);
  border-radius: 8px;
  padding: 25px;
  text-align: left;
}

.donation-info-banner h4 {
  color: #0d7849;
  margin-bottom: 15px;
  text-transform: none;
}

.donation-info-banner p {
  color: #555;
  margin-bottom: 10px;
  line-height: 1.6;
}

@media (max-width: 768px) {
  .main-donation-card {
    padding: 25px 15px;
    margin: 0 5px 30px 5px;
  }
  
  .donation-btn {
    width: 100%;
    margin-top: 20px;
    font-size: 16px;
    padding: 12px 20px;
  }
  
  .barcode-container {
    margin-top: 30px;
    padding: 15px;
  }
  
  .donation-barcode {
    max-width: 120px;
  }
  
  .donation-category-card {
    margin-bottom: 20px;
    margin-left: 5px;
    margin-right: 5px;
    padding: 25px 15px;
  }
  
  .category-icon span {
    font-size: 36px;
    width: 70px;
    height: 70px;
    line-height: 30px;
    padding: 15px;
  }
  
  .donation-info-banner {
    margin: 0 5px;
    padding: 20px 15px;
  }
}

/* Error Page Styles */
.error-page {
  min-height: 100vh;
  background: linear-gradient(135deg, #0d7849 0%, #0a5d38 50%, #ff7900 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px 0;
  position: relative;
  overflow: hidden;
}

.error-page::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center, rgba(255, 121, 0, 0.1) 0%, transparent 70%);
  pointer-events: none;
  z-index: 1;
}

.error-container {
  background: rgba(255, 255, 255, 0.95);
  border-radius: 20px;
  padding: 60px 40px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  max-width: 600px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
  border: 3px solid rgba(255, 121, 0, 0.3);
}

.error-logo {
  margin-bottom: 30px;
}

.error-logo img {
  height: 80px;
  filter: brightness(1);
}

.error-code {
  font-size: 120px;
  font-weight: 700;
  background: linear-gradient(45deg, #0d7849, #ff7900);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 20px 0;
  line-height: 1;
  text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
  font-family: 'Playfair Display', serif;
}

.error-title {
  font-family: 'Inter', sans-serif;
  font-size: 32px;
  color: #0d7849;
  margin-bottom: 20px;
  font-weight: 600;
}

.error-message {
  font-size: 18px;
  color: #666;
  margin-bottom: 30px;
  line-height: 1.6;
}

.islamic-quote {
  background: linear-gradient(135deg, rgba(13, 120, 73, 0.1) 0%, rgba(255, 121, 0, 0.1) 100%);
  border: 1px solid rgba(255, 121, 0, 0.3);
  border-radius: 10px;
  padding: 20px;
  margin: 30px 0;
  font-style: italic;
  color: #0d7849;
  font-size: 16px;
}

.islamic-quote .arabic {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 10px;
  direction: rtl;
  text-align: center;
  color: #ff7900;
}

.islamic-quote .translation {
  font-size: 14px;
  color: #666;
  margin-top: 10px;
}

.error-actions {
  margin-top: 40px;
}

.error-btn {
  background: linear-gradient(135deg, #0d7849 0%, #0a5d38 100%);
  border: none;
  color: #fff;
  padding: 15px 30px;
  font-size: 16px;
  font-weight: 600;
  border-radius: 50px;
  margin: 10px;
  text-decoration: none;
  display: inline-block;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
  box-shadow: 0 4px 15px rgba(13, 120, 73, 0.3);
}

.error-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(13, 120, 73, 0.4);
  color: #fff;
  text-decoration: none;
}

.error-btn.btn-outline {
  background: linear-gradient(135deg, #ff7900 0%, #e86a00 100%);
  border: 2px solid #ff7900;
  color: #fff;
  box-shadow: 0 4px 15px rgba(255, 121, 0, 0.3);
}

.error-btn.btn-outline:hover {
  background: linear-gradient(135deg, #e86a00 0%, #d45e00 100%);
  border-color: #e86a00;
  color: #fff;
  box-shadow: 0 8px 25px rgba(255, 121, 0, 0.4);
}

.helpful-links {
  margin-top: 40px;
  padding-top: 30px;
  border-top: 1px solid #eee;
}

.helpful-links h4 {
  color: #0d7849;
  margin-bottom: 20px;
  font-weight: 600;
}

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

.helpful-links li {
  margin: 8px 0;
}

.helpful-links a {
  color: #666;
  text-decoration: none;
  transition: color 0.3s ease;
  font-size: 14px;
}

.helpful-links a:hover {
  color: #ff7900;
  text-decoration: none;
}

.floating-elements {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  pointer-events: none;
  z-index: 1;
}

.floating-crescent {
  position: absolute;
  color: rgba(255, 255, 255, 0.12);
  font-size: 150px;
  animation: float 6s ease-in-out infinite;
  text-shadow: 0 0 20px rgba(255, 121, 0, 0.2);
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
  transition: all 0.3s ease;
  /* Add padding for better hit area */
  padding: 20px;
  margin: -20px;
  z-index: 10;
}

.floating-star {
  position: absolute;
  color: rgba(255, 255, 255, 0.18);
  font-size: 40px;
  animation: twinkle 4s ease-in-out infinite;
  text-shadow: 0 0 15px rgba(255, 121, 0, 0.3);
  pointer-events: auto;
  cursor: pointer;
  user-select: none;
  transition: all 0.3s ease;
  /* Add padding for better hit area */
  padding: 15px;
  margin: -15px;
  z-index: 10;
}

.floating-crescent:nth-child(1) {
  top: 10%;
  left: 10%;
  animation-delay: 0s;
}

.floating-crescent:nth-child(2) {
  top: 20%;
  right: 15%;
  animation-delay: 2s;
}

.floating-crescent:nth-child(3) {
  bottom: 15%;
  left: 20%;
  animation-delay: 4s;
}

.floating-star:nth-child(4) {
  top: 15%;
  left: 70%;
  animation-delay: 1s;
}

.floating-star:nth-child(5) {
  top: 60%;
  left: 5%;
  animation-delay: 3s;
}

.floating-star:nth-child(6) {
  top: 80%;
  right: 25%;
  animation-delay: 5s;
}

.floating-star:nth-child(7) {
  top: 35%;
  right: 5%;
  animation-delay: 2.5s;
}

.floating-star:nth-child(8) {
  bottom: 30%;
  left: 80%;
  animation-delay: 4.5s;
}

.floating-star:nth-child(9) {
  top: 5%;
  left: 40%;
  animation-delay: 1.5s;
}

/* Error Page Interactive Effects */
.floating-crescent:hover {
  animation-play-state: paused;
  transform: scale(1.3) rotate(360deg) !important;
  color: rgba(255, 121, 0, 0.4) !important;
  text-shadow: 0 0 50px rgba(255, 121, 0, 0.8) !important;
  filter: drop-shadow(0 0 20px rgba(255, 121, 0, 0.6)) hue-rotate(45deg) !important;
}

.floating-star:hover {
  animation-play-state: paused;
  transform: scale(1.5) rotate(720deg) !important;
  color: rgba(255, 121, 0, 0.6) !important;
  text-shadow: 0 0 40px rgba(255, 121, 0, 1) !important;
  filter: drop-shadow(0 0 25px rgba(255, 121, 0, 0.8)) hue-rotate(90deg) brightness(1.5) !important;
}

.floating-crescent:active {
  animation: errorPulse 2s ease-in-out;
  transform: scale(2.5) rotate(1080deg) !important;
  color: rgba(255, 121, 0, 0.9) !important;
  text-shadow: 0 0 70px rgba(255, 121, 0, 1) !important;
  filter: drop-shadow(0 0 35px rgba(255, 121, 0, 1)) brightness(2.5) !important;
}

.floating-star:active {
  animation: errorSpiral 3s ease-in-out;
  transform: scale(3) rotate(1440deg) !important;
  color: rgba(13, 120, 73, 0.9) !important;
  text-shadow: 0 0 80px rgba(13, 120, 73, 1) !important;
  filter: drop-shadow(0 0 40px rgba(13, 120, 73, 1)) brightness(3) saturate(3) !important;
}

.floating-crescent:focus,
.floating-star:focus {
  outline: 3px solid rgba(255, 121, 0, 0.7);
  outline-offset: 5px;
  animation-play-state: paused;
  transform: scale(1.4) !important;
  color: rgba(255, 121, 0, 0.7) !important;
  text-shadow: 0 0 60px rgba(255, 121, 0, 0.9) !important;
  border-radius: 50%;
}

/* Error Page Animation Variants */
.floating-crescent.spiral-variant {
  animation: errorSpiralFloat 8s ease-in-out infinite;
}

.floating-star.pulse-variant {
  animation: errorPulseFloat 7s ease-in-out infinite;
}

.floating-star.orbit-variant {
  animation: errorOrbitFloat 10s linear infinite;
}

@keyframes errorSpiralFloat {
  0% {
    transform: translateX(0) translateY(0) rotate(0deg) scale(1);
    opacity: 0.12;
    filter: hue-rotate(0deg);
  }
  25% {
    transform: translateX(40px) translateY(-25px) rotate(90deg) scale(1.2);
    opacity: 0.3;
    filter: hue-rotate(90deg);
  }
  50% {
    transform: translateX(25px) translateY(-50px) rotate(180deg) scale(0.9);
    opacity: 0.4;
    filter: hue-rotate(180deg);
  }
  75% {
    transform: translateX(-15px) translateY(-30px) rotate(270deg) scale(1.1);
    opacity: 0.2;
    filter: hue-rotate(270deg);
  }
  100% {
    transform: translateX(0) translateY(0) rotate(360deg) scale(1);
    opacity: 0.12;
    filter: hue-rotate(360deg);
  }
}

@keyframes errorPulseFloat {
  0% {
    transform: scale(1) rotate(0deg);
    opacity: 0.18;
    filter: brightness(1) saturate(1);
  }
  20% {
    transform: scale(1.3) rotate(72deg);
    opacity: 0.5;
    filter: brightness(1.3) saturate(1.5);
  }
  40% {
    transform: scale(0.8) rotate(144deg);
    opacity: 0.3;
    filter: brightness(1.1) saturate(1.2);
  }
  60% {
    transform: scale(1.1) rotate(216deg);
    opacity: 0.6;
    filter: brightness(1.4) saturate(1.8);
  }
  80% {
    transform: scale(0.9) rotate(288deg);
    opacity: 0.4;
    filter: brightness(1.2) saturate(1.3);
  }
  100% {
    transform: scale(1) rotate(360deg);
    opacity: 0.18;
    filter: brightness(1) saturate(1);
  }
}

@keyframes errorOrbitFloat {
  0% {
    transform: translateX(-35px) translateY(35px) rotate(0deg) scale(0.9);
    opacity: 0.18;
    filter: hue-rotate(0deg);
  }
  33% {
    transform: translateX(35px) translateY(-20px) rotate(120deg) scale(1.1);
    opacity: 0.5;
    filter: hue-rotate(120deg);
  }
  66% {
    transform: translateX(-20px) translateY(-35px) rotate(240deg) scale(1.2);
    opacity: 0.3;
    filter: hue-rotate(240deg);
  }
  100% {
    transform: translateX(-35px) translateY(35px) rotate(360deg) scale(0.9);
    opacity: 0.18;
    filter: hue-rotate(360deg);
  }
}

@keyframes errorPulse {
  0% {
    transform: scale(1) rotate(0deg);
    opacity: 0.12;
  }
  25% {
    transform: scale(2.5) rotate(270deg);
    opacity: 0.8;
    filter: hue-rotate(90deg) brightness(2.5) saturate(2.5);
  }
  50% {
    transform: scale(2) rotate(540deg);
    opacity: 0.6;
    filter: hue-rotate(180deg) brightness(2) saturate(2);
  }
  75% {
    transform: scale(1.5) rotate(810deg);
    opacity: 0.4;
    filter: hue-rotate(270deg) brightness(1.5) saturate(1.5);
  }
  100% {
    transform: scale(1) rotate(1080deg);
    opacity: 0.12;
    filter: hue-rotate(360deg) brightness(1) saturate(1);
  }
}

@keyframes errorSpiral {
  0% {
    transform: translateX(0) translateY(0) rotate(0deg) scale(1);
    opacity: 0.18;
  }
  25% {
    transform: translateX(60px) translateY(-40px) rotate(360deg) scale(2.5);
    opacity: 0.7;
    filter: hue-rotate(120deg) brightness(2.5) saturate(2.5);
  }
  50% {
    transform: translateX(40px) translateY(-80px) rotate(720deg) scale(2);
    opacity: 0.5;
    filter: hue-rotate(240deg) brightness(2) saturate(2);
  }
  75% {
    transform: translateX(-30px) translateY(-50px) rotate(1080deg) scale(1.5);
    opacity: 0.3;
    filter: hue-rotate(300deg) brightness(1.5) saturate(1.5);
  }
  100% {
    transform: translateX(0) translateY(0) rotate(1440deg) scale(1);
    opacity: 0.18;
    filter: hue-rotate(360deg) brightness(1) saturate(1);
  }
}

/* Error Page JavaScript Interaction Classes */
.error-clicked {
  animation: errorExplosiveClick 2.5s ease-out !important;
}

@keyframes errorExplosiveClick {
  0% {
    transform: scale(1) rotate(0deg);
  }
  15% {
    transform: scale(3.5) rotate(270deg);
    opacity: 1;
    filter: hue-rotate(0deg) brightness(3.5) saturate(3.5);
  }
  35% {
    transform: scale(3) rotate(540deg);
    opacity: 0.9;
    filter: hue-rotate(150deg) brightness(3) saturate(3);
  }
  55% {
    transform: scale(2.5) rotate(810deg);
    opacity: 0.7;
    filter: hue-rotate(300deg) brightness(2.5) saturate(2.5);
  }
  75% {
    transform: scale(2) rotate(1080deg);
    opacity: 0.5;
    filter: hue-rotate(450deg) brightness(2) saturate(2);
  }
  100% {
    transform: scale(1) rotate(1350deg);
    opacity: 0.12;
    filter: hue-rotate(540deg) brightness(1) saturate(1);
  }
}

.error-ripple {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 25px;
  height: 25px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 121, 0, 0.9) 0%, rgba(13, 120, 73, 0.5) 50%, transparent 100%);
  transform: translate(-50%, -50%) scale(0);
  animation: errorRippleEffect 1.2s ease-out;
  pointer-events: none;
}

@keyframes errorRippleEffect {
  0% {
    transform: translate(-50%, -50%) scale(0);
    opacity: 1;
  }
  100% {
    transform: translate(-50%, -50%) scale(12);
    opacity: 0;
  }
}

.error-celebration {
  animation: errorCelebrationBurst 3.5s ease-in-out !important;
}

@keyframes errorCelebrationBurst {
  0%, 100% {
    transform: scale(1) rotate(0deg);
    filter: hue-rotate(0deg) brightness(1) saturate(1);
  }
  12% {
    transform: scale(4.5) rotate(450deg);
    filter: hue-rotate(90deg) brightness(4.5) saturate(4.5);
  }
  25% {
    transform: scale(4) rotate(900deg);
    filter: hue-rotate(180deg) brightness(4) saturate(4);
  }
  37% {
    transform: scale(3.5) rotate(1350deg);
    filter: hue-rotate(270deg) brightness(3.5) saturate(3.5);
  }
  50% {
    transform: scale(3) rotate(1800deg);
    filter: hue-rotate(360deg) brightness(3) saturate(3);
  }
  62% {
    transform: scale(3.5) rotate(2250deg);
    filter: hue-rotate(450deg) brightness(3.5) saturate(3.5);
  }
  75% {
    transform: scale(3) rotate(2700deg);
    filter: hue-rotate(540deg) brightness(3) saturate(3);
  }
  87% {
    transform: scale(2) rotate(3150deg);
    filter: hue-rotate(630deg) brightness(2) saturate(2);
  }
}

.error-party-mode {
  background: radial-gradient(circle at center, rgba(255, 121, 0, 0.15) 0%, rgba(13, 120, 73, 0.15) 50%, rgba(255, 255, 255, 0.08) 100%) !important;
  animation: errorPartyBackground 3.5s ease-in-out;
}

@keyframes errorPartyBackground {
  0%, 100% {
    filter: hue-rotate(0deg) brightness(1);
  }
  20% {
    filter: hue-rotate(120deg) brightness(1.3);
  }
  40% {
    filter: hue-rotate(240deg) brightness(1.6);
  }
  60% {
    filter: hue-rotate(360deg) brightness(1.4);
  }
  80% {
    filter: hue-rotate(480deg) brightness(1.2);
  }
}

.enhanced-movement {
  animation-duration: calc(var(--base-duration, 6s) + var(--random-offset, 2s));
}

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

@keyframes twinkle {
  0%, 100% { 
    opacity: 0.18;
    transform: scale(1) rotate(0deg);
    filter: drop-shadow(0 0 15px rgba(255, 121, 0, 0.3));
  }
  25% { 
    opacity: 0.4;
    transform: scale(1.2) rotate(90deg);
    filter: drop-shadow(0 0 25px rgba(255, 121, 0, 0.5));
  }
  50% { 
    opacity: 0.8;
    transform: scale(1) rotate(180deg);
    filter: drop-shadow(0 0 30px rgba(255, 121, 0, 0.6));
  }
  75% { 
    opacity: 0.3;
    transform: scale(0.8) rotate(270deg);
    filter: drop-shadow(0 0 20px rgba(255, 121, 0, 0.4));
  }
}

/* Error Page Mobile Styles */
@media (max-width: 768px) {
  .error-container {
    padding: 40px 20px;
    margin: 20px;
  }
  
  .error-code {
    font-size: 80px;
  }
  
  .error-title {
    font-size: 24px;
  }
  
  .error-message {
    font-size: 16px;
  }
  
  .error-btn {
    padding: 12px 25px;
    font-size: 14px;
    margin: 8px;
    display: block;
    width: 80%;
    margin-left: auto;
    margin-right: auto;
  }
  
  .floating-crescent {
    font-size: 100px;
  }
  
  .floating-star {
    font-size: 30px;
  }
}

@media (max-width: 480px) {
  .error-container {
    padding: 30px 15px;
  }
  
  .error-code {
    font-size: 60px;
  }
  
  .error-title {
    font-size: 20px;
  }
  
  .islamic-quote .arabic {
    font-size: 16px;
  }
  
  .floating-crescent {
    font-size: 80px;
  }
  
  .floating-star {
    font-size: 25px;
  }
}

/* Mobile-specific hero crescent styles for better Unicode rendering */
@media (max-width: 768px) {
  .hero-floating-crescent {
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', 'Segoe UI', 'Arial Unicode MS', 'Symbola', 'DejaVu Sans', sans-serif;
    font-variant-emoji: text !important;
    -webkit-font-feature-settings: "liga" 0, "clig" 0, "calt" 0, "kern" 1;
    font-feature-settings: "liga" 0, "clig" 0, "calt" 0, "kern" 1;
    -webkit-text-stroke: 2px rgba(255, 255, 255, 0.2);
    text-rendering: geometricPrecision;
    font-size: 120px;
  }
  
  .hero-floating-crescent::before {
    width: 96px;
    height: 96px;
    border-width: 6px;
  }
  
  .hero-floating-crescent::after {
    width: 80px;
    height: 80px;
  }
}

@media (max-width: 480px) {
  .hero-floating-crescent {
    font-size: 80px;
    font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Helvetica Neue', Arial, sans-serif;
    font-variant-emoji: text !important;
    -webkit-font-feature-settings: "liga" off, "clig" off, "calt" off;
    font-feature-settings: "liga" off, "clig" off, "calt" off;
    -webkit-text-stroke: 1.5px rgba(255, 255, 255, 0.3);
  }
  
  .hero-floating-crescent::before {
    width: 64px;
    height: 64px;
    border-width: 4px;
  }
  
  .hero-floating-crescent::after {
    width: 54px;
    height: 54px;
  }
}

/* Force Unicode text rendering on mobile webkit browsers */
@media (max-width: 768px) and (-webkit-min-device-pixel-ratio: 1) {
  .hero-floating-crescent {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-variant: normal;
    font-variant-emoji: text !important;
    -webkit-text-stroke: 2px rgba(255, 255, 255, 0.15);
  }
}