@keyframes gradientAnimation {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

body {
  font-family: "Noto Sans Arabic", sans-serif;
  font-optical-sizing: auto;
  font-weight: 400;
  font-style: normal;
  background: #1a1a1d;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    linear-gradient(135deg, 
      rgba(25, 25, 30, 0.95) 0%,
      rgba(30, 35, 40, 0.95) 100%
    );
  z-index: -2;
}

body::after {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    repeating-linear-gradient(45deg,
      rgba(255, 255, 255, 0.01) 0px,
      rgba(255, 255, 255, 0.01) 1px,
      transparent 1px,
      transparent 20px
    );
  z-index: -1;
  pointer-events: none;
}
  
  .ease-up-down {  
      animation: ease-up-down 2s infinite;  
      transform: translateY(0);  
  }  
    
  @keyframes ease-up-down {  
      0%, 100% {  
        transform: translateY(0);  
      }  
      50% {  
        transform: translateY(-10px);  
      }  
  }
  
  @media (min-width: 768px) { /* Medium devices (tablets, 768px and up) */
    .card-img {
      min-height: 17rem;
    }
  }
  
  @media (min-width: 992px) { /* Large devices (desktops, 992px and up) */
    .card-img {
      min-height: 17rem;
    }
  }
  
  @media (min-width: 1200px) { /* Extra large devices (large desktops, 1200px and up) */
    .card-img {
      min-height: 17rem;
    }
  }
  
  .img-admin {  
    transition: transform 0.2s ease;  
  }  
  
  .img-admin:hover {  
    transform: scale(1.3);  
  }  
  
  .card{
      border: 0.13em;
      border-style:dashed;
      border-color: #ffffff;
      transition: transform 0.4s !important;
  }
  
  .card:hover {  
      border-style:solid;
      transform: scale(1.05) !important;
  }
  
  .footer-link{
      text-decoration:none;
      color: #ffffff;
  }
  
  
  .ribbon {
    position: absolute;
    right: -5px; top: -5px;
    z-index: 1;
    overflow: hidden;
    width: 75px; height: 75px;
    text-align: right;
  }
  .ribbon span {
    font-size: 10px;
    font-weight: bold;
    color: #FFF;
    text-transform: uppercase;
    text-align: center;
    line-height: 20px;
    transform: rotate(45deg);
    -webkit-transform: rotate(45deg);
    width: 100px;
    display: block;
    background: #79A70A;
    background: linear-gradient(#B6BAC9 0%, #808080 100%);
    box-shadow: 0 3px 10px -5px rgba(0, 0, 0, 1);
    position: absolute;
    top: 19px; right: -21px;
  }
  .ribbon span::before {
    content: "";
    position: absolute; left: 0px; top: 100%;
    z-index: -1;
    border-left: 3px solid #808080;
    border-right: 3px solid transparent;
    border-bottom: 3px solid transparent;
    border-top: 3px solid #808080;
  }
  .ribbon span::after {
    content: "";
    position: absolute; right: 0px; top: 100%;
    z-index: -1;
    border-left: 3px solid transparent;
    border-right: 3px solid #808080;
    border-bottom: 3px solid transparent;
    border-top: 3px solid #808080;
  }
  
  .link-header{
    transition: background-color 0.5s ease;
    color: var(--bs-body-color);
    border-radius: 2em;
    padding: 0.3em;
  }
  
  .link-header:hover {
    background-color: var(--bs-gray-500);
    color: var(--bs-body-bg);
    border-radius: 2em;
    padding: 0.3em;
  }

  .swiper {
    padding-bottom: 2rem;
    padding-top: 0.5rem;
  }
  
  .swiper-pagination-bullet {
    background: #007aff;
    opacity: 0.5;
  }
  
  .swiper-pagination-bullet-active {
    opacity: 1;
  }
  .swiper-button-next{
    background-color: grey;
    color: white;
    padding-top: 3rem;
    padding-bottom: 3rem;
    padding-left: 1rem;
    padding-right: 1rem;
    border-radius: 5px;
    opacity: 0.6;
  }
  .swiper-button-prev{
    background-color: grey;
    color: white;
    padding-top: 3rem;
    padding-bottom: 3rem;
    padding-left: 1rem;
    padding-right: 1rem;
    border-radius: 5px;
    opacity: 0.5;
  }

  /* Theme Toggle Button */
.theme-toggle-btn {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: var(--bs-primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
  transition: all 0.3s ease;
  z-index: 1000;
}

.theme-toggle-btn:hover {
  transform: scale(1.1);
}

.theme-toggle-btn i {
  font-size: 1.5rem;
}

/* Theme Specific Styles */
[data-bs-theme="light"] {
  --bg-gradient-start: rgba(255, 255, 255, 0.95);
  --bg-gradient-end: rgba(240, 240, 245, 0.95);
  --grid-color: rgba(0, 0, 0, 0.05);
}

[data-bs-theme="dark"] {
  --bg-gradient-start: rgba(25, 25, 30, 0.95);
  --bg-gradient-end: rgba(30, 35, 40, 0.95);
  --grid-color: rgba(255, 255, 255, 0.01);
}

body::before {
  background: linear-gradient(135deg, 
      var(--bg-gradient-start) 0%,
      var(--bg-gradient-end) 100%
  );
}

body::after {
  background: repeating-linear-gradient(45deg,
      var(--grid-color) 0px,
      var(--grid-color) 1px,
      transparent 1px,
      transparent 20px
  );
}

[data-bs-theme="light"] body {
  background: #f8f9fa;
}

[data-bs-theme="light"] .card {
  border-color: var(--bs-gray-400);
}

[data-bs-theme="light"] .footer-link {
  color: var(--bs-dark);
}

/* Light theme specific styles */
[data-bs-theme="light"] {
  --bs-body-color: #212529;
  --bs-body-bg: #ffffff;
  --bs-navbar-color: #212529;
}

[data-bs-theme="light"] body {
  background: #f8f9fa;
  color: var(--bs-body-color);
}

[data-bs-theme="light"] .card {
  border-color: var(--bs-gray-300);
  background-color: var(--bs-body-bg);
}

[data-bs-theme="light"] .footer-link {
  color: var(--bs-body-color);
}

[data-bs-theme="light"] .navbar {
  background-color: var(--bs-body-bg) !important;
}

[data-bs-theme="light"] .nav-link {
  color: var(--bs-body-color);
}

[data-bs-theme="light"] .text-light {
  color: var(--bs-body-color) !important;
}

/* Newsletter and footer background fixes for light mode */
[data-bs-theme="light"] .bg-dark {
  background-color: var(--bs-gray-100) !important;
}

[data-bs-theme="light"] .bg-dark h3,
[data-bs-theme="light"] .bg-dark p,
[data-bs-theme="light"] .bg-dark .text-light {
  color: var(--bs-body-color) !important;
}

[data-bs-theme="light"] .text-primary {
  color: var(--bs-primary) !important;
}

/* Dark theme specific styles */
[data-bs-theme="dark"] {
  --bs-body-color: #f8f9fa;
  --bs-body-bg: #212529;
}

[data-bs-theme="dark"] .card {
  background-color: var(--bs-dark);
}

[data-bs-theme="dark"] .footer-link {
  color: var(--bs-body-color);
}

[data-bs-theme="dark"] .text-light {
  color: var(--bs-body-color) !important;
}

/* Common styles for both themes */
.card {
  transition: all 0.3s ease;
}

.navbar {
  transition: background-color 0.3s ease;
}

/* Swiper button colors */
.swiper-button-next,
.swiper-button-prev {
  background-color: var(--bs-primary);
  color: var(--bs-body-bg);
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
  opacity: 1;
}

/* Theme toggle button improvements */
.theme-toggle-btn {
  background: var(--bs-primary);
  color: var(--bs-body-bg);
  opacity: 0.9;
}

.theme-toggle-btn:hover {
  opacity: 1;
}