/* ===== الأنماط الأساسية ===== */
:root {
  --primary-color: #d4af37; /* اللون الذهبي من الشعار */
  --secondary-color: #006400; /* اللون الأخضر الداكن */
  --light-color: #f8f9fa;
  --dark-color: #343a40;
  --gray-color: #6c757d;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Cairo', 'Tajawal', sans-serif;
  line-height: 1.6;
  color: var(--dark-color);
  background-color: var(--light-color);
  direction: rtl;
}

body.en {
  direction: ltr;
  font-family: 'Roboto', 'Open Sans', sans-serif;
}

a {
  text-decoration: none;
  color: var(--primary-color);
}

a:hover {
  color: var(--secondary-color);
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.section {
  padding: 80px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 50px;
  position: relative;
}

.section-title h2 {
  font-size: 2.5rem;
  color: var(--dark-color);
  margin-bottom: 20px;
}

.section-title::after {
  content: '';
  position: absolute;
  width: 80px;
  height: 3px;
  background-color: var(--primary-color);
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
}

.btn {
  display: inline-block;
  padding: 12px 30px;
  border-radius: 5px;
  font-weight: bold;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
  border: 2px solid var(--primary-color);
}

.btn-primary:hover {
  background-color: transparent;
  color: var(--primary-color);
}

.btn-secondary {
  background-color: var(--secondary-color);
  color: white;
  border: 2px solid var(--secondary-color);
}

.btn-secondary:hover {
  background-color: transparent;
  color: var(--secondary-color);
}

/* ===== الهيدر والتنقل ===== */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: white;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  z-index: 1000;
  transition: all 0.3s ease;
}

.header-scrolled {
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 0;
}

.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 60px;
}

.logo h1 {
  font-size: 1.5rem;
  margin-right: 10px;
  color: var(--dark-color);
}

.nav-menu {
  display: flex;
  list-style: none;
}

.nav-item {
  margin-left: 30px;
}

.nav-link {
  font-weight: 600;
  color: var(--dark-color);
  transition: all 0.3s ease;
}

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

.language-switch {
  display: flex;
  align-items: center;
  margin-left: 20px;
}

.language-switch a {
  padding: 5px 10px;
  border-radius: 3px;
  font-weight: 600;
  transition: all 0.3s ease;
}

.language-switch a.active {
  background-color: var(--primary-color);
  color: white;
}

.mobile-nav-toggle {
  display: none;
  font-size: 24px;
  cursor: pointer;
}

/* ===== قسم البداية ===== */
#hero {
  height: 100vh;
  background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('../images/hero-bg.jpg');
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  text-align: center;
  color: white;
}

.hero-content {
  max-width: 800px;
  margin: 0 auto;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 20px;
}

.hero-content p {
  font-size: 1.2rem;
  margin-bottom: 30px;
}

.hero-btns {
  display: flex;
  justify-content: center;
  gap: 20px;
}

/* ===== قسم من نحن ===== */
.about-content {
  display: flex;
  align-items: center;
  gap: 50px;
}

.about-img {
  flex: 1;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.about-img img {
  width: 100%;
  height: auto;
  transition: transform 0.5s ease;
}

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

.about-text {
  flex: 1;
}

.about-text h3 {
  font-size: 1.8rem;
  margin-bottom: 20px;
  color: var(--primary-color);
}

.about-text p {
  margin-bottom: 15px;
}

/* ===== قسم الخدمات ===== */
.services-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.service-box {
  background-color: white;
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
}

.service-box:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.service-icon {
  font-size: 3rem;
  color: var(--primary-color);
  margin-bottom: 20px;
}

.service-title {
  font-size: 1.5rem;
  margin-bottom: 15px;
}

/* ===== قسم المكتبة القانونية ===== */
.legal-library {
  background-color: #f9f9f9;
}

.library-tabs {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 30px;
}

.library-tab {
  padding: 10px 20px;
  margin: 0 5px 10px;
  background-color: white;
  border-radius: 5px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.library-tab.active, .library-tab:hover {
  background-color: var(--primary-color);
  color: white;
}

.library-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.library-item {
  background-color: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.library-item-content {
  padding: 20px;
}

.library-item h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.library-item p {
  margin-bottom: 15px;
  color: var(--gray-color);
}

.library-item a {
  display: inline-block;
  padding: 8px 15px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 5px;
  font-size: 0.9rem;
}

/* ===== قسم إيميلات المحاكم ===== */
.court-emails {
  background-color: white;
}

.search-container {
  max-width: 600px;
  margin: 0 auto 40px;
}

.search-box {
  display: flex;
  border: 2px solid var(--gray-color);
  border-radius: 5px;
  overflow: hidden;
}

.search-box input {
  flex: 1;
  padding: 15px;
  border: none;
  outline: none;
  font-size: 1rem;
}

.search-box button {
  padding: 15px 25px;
  background-color: var(--primary-color);
  color: white;
  border: none;
  cursor: pointer;
  transition: all 0.3s ease;
}

.search-box button:hover {
  background-color: var(--secondary-color);
}

.emails-results {
  max-height: 400px;
  overflow-y: auto;
  background-color: #f9f9f9;
  border-radius: 10px;
  padding: 20px;
}

.email-item {
  background-color: white;
  padding: 15px;
  border-radius: 5px;
  margin-bottom: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.email-item h4 {
  margin-bottom: 5px;
  color: var(--primary-color);
}

.email-item p {
  color: var(--gray-color);
}

/* ===== قسم المدونة ===== */
.blog-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
}

.blog-post {
  background-color: white;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.blog-img {
  height: 200px;
  overflow: hidden;
}

.blog-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-post:hover .blog-img img {
  transform: scale(1.1);
}

.blog-content {
  padding: 20px;
}

.blog-content h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.blog-content p {
  margin-bottom: 15px;
  color: var(--gray-color);
}

.blog-meta {
  display: flex;
  justify-content: space-between;
  color: var(--gray-color);
  font-size: 0.9rem;
  margin-bottom: 10px;
}

/* ===== قسم الاتصال ===== */
.contact {
  background-color: #f9f9f9;
}

.contact-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 50px;
}

.contact-info {
  display: flex;
  flex-direction: column;
}

.contact-item {
  display: flex;
  align-items: flex-start;
  margin-bottom: 30px;
}

.contact-icon {
  font-size: 1.5rem;
  color: var(--primary-color);
  margin-left: 15px;
}

.contact-text h3 {
  font-size: 1.2rem;
  margin-bottom: 5px;
}

.contact-text p {
  color: var(--gray-color);
}

.contact-form {
  background-color: white;
  padding: 30px;
  border-radius: 10px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.form-group {
  margin-bottom: 20px;
}

.form-control {
  width: 100%;
  padding: 12px;
  border: 1px solid #ddd;
  border-radius: 5px;
  font-size: 1rem;
  transition: all 0.3s ease;
}

.form-control:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

textarea.form-control {
  resize: vertical;
  min-height: 120px;
}

/* ===== الفوتر ===== */
footer {
  background-color: var(--dark-color);
  color: white;
  padding: 50px 0 20px;
}

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

.footer-logo img {
  height: 60px;
  margin-bottom: 20px;
}

.footer-about p {
  margin-bottom: 20px;
}

.footer-title {
  font-size: 1.3rem;
  margin-bottom: 20px;
  position: relative;
}

.footer-title::after {
  content: '';
  position: absolute;
  width: 50px;
  height: 2px;
  background-color: var(--primary-color);
  bottom: -10px;
  right: 0;
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 10px;
}

.footer-links a {
  color: #ddd;
  transition: all 0.3s ease;
}

.footer-links a:hover {
  color: var(--primary-color);
  padding-right: 5px;
}

.social-links {
  display: flex;
  gap: 15px;
}

.social-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  color: white;
  transition: all 0.3s ease;
}

.social-links a:hover {
  background-color: var(--primary-color);
  transform: translateY(-5px);
}

.copyright {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== التجاوب مع الشاشات المختلفة ===== */
@media (max-width: 992px) {
  .nav-menu {
    position: fixed;
    top: 80px;
    right: -100%;
    width: 80%;
    height: 100vh;
    background-color: white;
    flex-direction: column;
    padding: 50px 0;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-item {
    margin: 15px 0;
  }

  .mobile-nav-toggle {
    display: block;
  }

  .about-content {
    flex-direction: column;
  }

  .hero-content h1 {
    font-size: 2.5rem;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 60px 0;
  }

  .section-title h2 {
    font-size: 2rem;
  }

  .hero-content h1 {
    font-size: 2rem;
  }

  .hero-btns {
    flex-direction: column;
    gap: 10px;
  }
}

@media (max-width: 576px) {
  .logo h1 {
    display: none;
  }
}

/* ===== دعم اللغة الإنجليزية ===== */
body.en .section-title::after,
body.en .footer-title::after {
  right: auto;
  left: 0;
}

body.en .nav-item {
  margin-left: 0;
  margin-right: 30px;
}

body.en .contact-icon {
  margin-left: 0;
  margin-right: 15px;
}

body.en .footer-links a:hover {
  padding-right: 0;
  padding-left: 5px;
}

/* ===== زر واتساب ===== */
.whatsapp-btn {
  position: fixed;
  bottom: 20px;
  left: 20px;
  width: 60px;
  height: 60px;
  background-color: #25d366;
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  z-index: 999;
  transition: all 0.3s ease;
}

.whatsapp-btn:hover {
  transform: scale(1.1);
  background-color: #128c7e;
}

/* ===== زر العودة للأعلى ===== */
.back-to-top {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 50px;
  height: 50px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.back-to-top.active {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background-color: var(--secondary-color);
}
