:root {
  --neon-pink: #ff00c8;
  --neon-purple: #7a00ff;
  --light-text: #ffffff;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Orbitron', sans-serif;
  background: radial-gradient(circle at center, #2a004d, #0a001a 80%);
  color: white;
  overflow-x: hidden;
}

/* Apply Arabic font when in RTL mode */
[dir="rtl"] * {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
}

/* Special handling for specific elements in RTL mode */
[dir="rtl"] h1 {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif !important;
  font-weight: bold;
}

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  position: relative;
  padding: 4rem 2rem;
}

.abstract-shape,
.sphere {
  position: absolute;
  z-index: 0;
}

.abstract-shape {
  width: 300px;
  height: 400px;
  background: rgba(255, 0, 200, 0.05);
  border: 2px solid var(--neon-pink);
  clip-path: polygon(30% 0%, 70% 10%, 100% 50%, 80% 100%, 20% 100%, 0% 50%);
  box-shadow: 0 0 20px var(--neon-pink), 0 0 40px var(--neon-purple);
  animation: pulse 4s infinite ease-in-out;
}

.sphere {
  border-radius: 50%;
  filter: blur(2px);
  opacity: 0.6;
  animation: float 6s ease-in-out infinite alternate;
  background: radial-gradient(circle, var(--neon-pink), var(--neon-purple));
}

.sphere.one { width: 80px; height: 80px; top: 10%; left: 20%; }
.sphere.two { width: 60px; height: 60px; top: 40%; right: 15%; animation-delay: 1s; }
.sphere.three { width: 40px; height: 40px; bottom: 15%; left: 25%; animation-delay: 2s; }

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  animation: fadeInUp 2s ease forwards;
  opacity: 0;
}

h2 {
  font-size: 1.6em;
  color: #fce4ff;
  margin-bottom: 0.4em;
  animation: neonGlow 4s infinite ease-in-out;
}

.tuniar-logo {
  display: inline-block;
  margin-left: 5px;
  height: 20px;
  vertical-align: middle;
}

h1 {
  font-size: 3em;
  background: linear-gradient(to right, var(--neon-pink), var(--neon-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  margin: 0.2em 0;
}

/* Special handling for h1 in RTL mode */
[dir="rtl"] h1 {
  background: linear-gradient(to right, var(--neon-pink), var(--neon-purple));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.location {
  font-size: 1em;
  color: #ccc;
  margin-top: 0.3em;
}
.logo-top-center {
  display: block;
  margin: 0 auto 20px auto;
  max-width: 400px;
  height: auto;
}

.logo-center {
  margin: 2rem auto 1rem;
  width: 80px;
}

.button, .btn {
  margin-top: 1rem;
  padding: 12px 30px;
  background: var(--neon-pink);
  color: white;
  border: none;
  border-radius: 30px;
  font-size: 1em;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 0 10px var(--neon-pink), 0 0 30px var(--neon-purple);
  transition: transform 0.3s, background 0.3s;
  display: inline-block;
}

.button:hover, .btn:hover {
  background: #e600ac;
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(157, 78, 221, 0.5);
}

/* Language switcher styles */
.language-switcher {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 10;
  display: flex;
  gap: 10px;
}

.lang-btn {
  padding: 8px 15px;
  background: rgba(0, 0, 0, 0.3);
  color: white;
  border: 1px solid var(--neon-pink);
  border-radius: 20px;
  font-size: 0.9em;
  cursor: pointer;
  transition: all 0.3s ease;
}

.lang-btn:hover, .lang-btn.active {
  background: var(--neon-pink);
  box-shadow: 0 0 10px var(--neon-pink);
}

section {
  padding: 5rem 10%;
}

section.about, .footer {
  background-color: rgba(0, 0, 0, 0.3);
}

h2 {
  font-size: 2.5rem;
  margin-bottom: 2rem;
  position: relative;
  display: inline-block;
}

h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -10px;
  width: 100%;
  height: 3px;
  background: linear-gradient(90deg, var(--neon-pink), transparent);
}

.about p {
  font-size: 1.2rem;
  line-height: 1.6;
  margin-bottom: 1.5rem;
  max-width: 800px;
}

.program-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 3rem;
}

.program-item {
  background-color: rgba(0, 0, 0, 0.3);
  border-radius: 10px;
  padding: 2rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  position: relative;
}

.program-item::before {
  content: '';
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, var(--neon-pink), var(--neon-purple));
}

.program-item:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 30px rgba(157, 78, 221, 0.3);
}

.program-item h3 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

.program-item .time {
  font-size: 1.2rem;
  color: var(--neon-pink);
  margin-bottom: 0.5rem;
}

.footer {
  text-align: center;
  padding: 3rem 10%;
}

.footer-text {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
}

@keyframes fadeInUp {
  0% { transform: translateY(40px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}

@keyframes neonGlow {
  0%, 100% {
    text-shadow: 0 0 5px var(--neon-pink), 0 0 10px var(--neon-pink), 0 0 20px var(--neon-purple);
  }
  50% {
    text-shadow: 0 0 15px #ff66e7, 0 0 30px #a74aff;
  }
}

@keyframes pulse {
  0%, 100% { box-shadow: 0 0 10px var(--neon-pink), 0 0 30px var(--neon-purple); }
  50% { box-shadow: 0 0 20px #ff66e7, 0 0 50px #a74aff; }
}

@keyframes float {
  from { transform: translateY(0px); }
  to { transform: translateY(-20px); }
}

@media (max-width: 768px) {
  h1 { font-size: 2.2em; }
  .hero { padding: 3rem 1.5rem; }
  .logo-center { width: 120px; }
  .language-switcher {
    top: 10px;
    right: 10px;
  }
  .lang-btn {
    padding: 5px 10px;
    font-size: 0.8em;
  }
}
