/* 
=======================================
  Main Stylesheet for Al-Dowyshan Company
  Author: Claude
  Support: LTR and RTL
=======================================
*/

@import url("variables.css");

/* Variables */
:root {
  --primary-color: #00579d;
  --secondary-color: #003b6f;
  --accent-color: #56ccf2;
  --text-color: #333;
  --light-color: #f9f9f9;
  --light-blue: #e6f7ff;
  --dark-color: #1b1b1b;
  --border-color: #e0e0e0;
  --white: #ffffff;
  --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  --transition: all 0.3s ease;
}

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

body {
  font-family: "Cairo", sans-serif;
  color: var(--text-color);
  line-height: var(--line-height-normal, 1.8);
  overflow-x: hidden;
  background-color: var(--white);
  font-size: var(--base-font-size, 32px);
}

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

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

ul {
  list-style: none;
}

img {
  max-width: 100%;
  height: auto;
}

.dropdown-toggle::after {
  content: "";
  display: none;
}

.section-padding {
  padding: var(--spacing-2xl, 100px) 0;
}

.section-header {
  margin-bottom: var(--spacing-lg, 60px);
}

.section-title {
  color: var(--primary-color);
  font-size: var(--font-size-4xl, 64px);
  font-weight: 700;
  position: relative;
  display: inline-block;
  margin-bottom: var(--spacing-sm, 20px);
  padding-bottom: var(--spacing-xs, 10px);
}

.section-title:after {
  content: "";
  position: absolute;
  width: 100px;
  height: var(--border-width-lg, 4px);
  background: #3e3e3e;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
}

.btn {
  font-weight: 600;
  padding: var(--spacing-sm, 20px) var(--spacing-md, 40px);
  border-radius: var(--border-radius-lg, 40px);
  transition: var(--transition);
  border: none;
  cursor: pointer;
  text-align: center;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  font-size: var(--base-font-size, 32px);
}

.main-btn {
  background-color: var(--primary-color);
  color: var(--white);
  box-shadow: var(--box-shadow);
}

.main-btn:hover {
  background-color: var(--secondary-color);
  color: var(--white);
  transform: translateY(-3px);
}

/* Animation */
.animate-element {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-element.show {
  opacity: 1;
  transform: translateY(0);
}

/* Header - UNCHANGED AS REQUESTED */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 999;
  padding: 15px 0;
  background-color: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: var(--transition);
}

.header.scrolled {
  padding: 10px 0;
}

.logo img {
  max-height: 60px;
  transition: var(--transition);
}

.header.scrolled .logo img {
  max-height: 50px;
}

.main-nav {
  display: flex;
  justify-content: center;
}

.nav-list {
  display: flex;
  align-items: center;
  margin: 0;
  padding: 0;
}

.nav-item {
  position: relative;
  margin: 0 10px;
}

.nav-link {
  display: block;
  padding: 8px 15px;
  color: var(--text-color);
  font-weight: 600;
  font-size: 16px;
  transition: var(--transition);
}

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

.dropdown-toggle {
  position: relative;
  padding-right: 22px;
}

.dropdown-toggle i {
  font-size: 12px;
  position: absolute;
  right: 5px;
  top: 50%;
  transform: translateY(-50%);
  transition: var(--transition);
}

.dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  min-width: 220px;
  background-color: var(--white);
  box-shadow: var(--box-shadow);
  border-radius: 5px;
  padding: 10px 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: var(--transition);
  z-index: 99;
  display: block !important;
  /* Ensure menu is always present in DOM */
}

.dropdown-item {
  display: block;
  padding: 8px 20px;
  color: var(--text-color);
  font-size: 14px;
  transition: var(--transition);
}

.dropdown-item:hover {
  background-color: rgba(0, 87, 157, 0.1);
  color: var(--primary-color);
}

/* Important: Make dropdown work on hover */
.nav-item:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav-item:hover .dropdown-toggle i {
  transform: translateY(-50%) rotate(180deg);
}

.language-switcher {
  display: flex;
  align-items: center;
}

.lang-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  color: var(--primary-color);
  font-weight: 600;
  font-size: 14px;
  border: 1px solid var(--primary-color);
  padding: 5px 10px;
  border-radius: 20px;
  transition: var(--transition);
}

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

.mobile-toggle {
  width: 30px;
  height: 22px;
  position: relative;
  cursor: pointer;
  display: none;
  margin-right: 10px;
}

.mobile-toggle span {
  display: block;
  position: absolute;
  height: 3px;
  width: 100%;
  background: var(--primary-color);
  border-radius: 3px;
  left: 0;
  transform: rotate(0deg);
  transition: 0.25s ease-in-out;
}

.mobile-toggle span:nth-child(1) {
  top: 0px;
}

.mobile-toggle span:nth-child(2) {
  top: 9px;
}

.mobile-toggle span:nth-child(3) {
  top: 18px;
}

.mobile-toggle.active span:nth-child(1) {
  top: 9px;
  transform: rotate(135deg);
}

.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
  left: -60px;
}

.mobile-toggle.active span:nth-child(3) {
  top: 9px;
  transform: rotate(-135deg);
}

.mobile-menu {
  position: fixed;
  top: 90px;
  right: -100%;
  width: 280px;
  height: calc(100vh - 90px);
  background-color: var(--white);
  box-shadow: -5px 0 15px rgba(0, 0, 0, 0.1);
  padding: 20px;
  overflow-y: auto;
  transition: var(--transition);
  z-index: 998;
}

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

.mobile-nav li {
  margin-bottom: 10px;
}

.mobile-nav a {
  display: block;
  padding: 10px 0;
  color: var(--text-color);
  font-size: 16px;
  font-weight: 600;
  transition: var(--transition);
}

.mobile-nav a:hover {
  color: var(--primary-color);
}

.mobile-nav .has-submenu > a {
  position: relative;
}

.mobile-nav .has-submenu > a i {
  position: absolute;
  left: 0;
  font-size: 12px;
  transition: var(--transition);
}

.mobile-nav .has-submenu.active > a i {
  transform: rotate(180deg);
}

.mobile-nav .submenu {
  padding-right: 15px;
  display: none;
  margin-top: 5px;
}

.mobile-nav .submenu a {
  font-size: 14px;
  padding: 8px 0;
  color: #555;
}

/* Hero Section */
.hero-section {
  background: url("../assets/images/hero-background.png") no-repeat center
    center;
  background-size: cover;
  /* padding: calc(var(--spacing-2xl, 100px) + var(--spacing-lg, 60px)) 0 var(--spacing-xl, 80px); */
  position: relative;
  overflow: hidden;
  min-height: 800px;
  display: flex;
  align-items: center;
}

/* .hero-section:before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0.8) 50%, rgba(255, 255, 255, 0.4) 100%);
  z-index: 0;
} */

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-title {
  color: var(--primary-color);
  font-size: var(--font-size-5xl, 96px);
  font-weight: 800;
  margin-bottom: var(--spacing-sm, 20px);
  animation: fadeInUp 1s ease;
}

.hero-subtitle {
  font-size: var(--font-size-2xl, 48px);
  color: var(--text-color);
  margin-bottom: var(--spacing-lg, 60px);
  animation: fadeInUp 1s ease 0.3s both;
}

.hero-buildings {
  position: relative;
  /* height: 800px; */
  z-index: 1;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(var(--spacing-lg, 60px));
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.news-card {
  background-color: var(--white);
  border-radius: var(--border-radius-md, 20px);
  padding: var(--spacing-sm, 20px);
  text-align: center;
  box-shadow: var(--box-shadow);
  transition: var(--transition);
  margin-bottom: var(--spacing-lg, 60px);
  position: relative;
  z-index: 1;
}

.news-card:hover {
  transform: translateY(-20px);
}

.news-image {
  height: 300px;
}

.news-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.news-title {
  color: var(--primary-color);
  font-size: var(--font-size-sm, 40px);
  font-weight: 700;
  margin-top: var(--spacing-sm, 10px);
  margin-bottom: var(--spacing-sm, 40px);
}

.news-description {
  font-size: var(--font-size-xs, 28px);
  color: var(--grey-text, #555);
  margin-bottom: var(--spacing-md, 40px);
  line-height: var(--line-height-tight, 1.5);
}

.news-btn {
  display: inline-block;
  padding: var(--spacing-xs, 10px) var(--spacing-md, 40px);
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: var(--spacing-md, 40px);
  font-size: var(--font-size-sm, 28px);
  font-weight: 600;
  transition: var(--transition);
}

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

/* Services Section */
.services-section {
  background-color: var(--light-color);
}

.service-card {
  background-color: var(--white);
  border-radius: var(--border-radius-md, 20px);
  padding: var(--spacing-lg, 60px);
  text-align: center;
  box-shadow: var(--box-shadow);
  height: 100%;
  transition: var(--transition);
  margin-bottom: var(--spacing-lg, 60px);
  position: relative;
  z-index: 1;
}

.service-card:hover {
  transform: translateY(-20px);
}

.service-card:before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 0;
  background-color: rgba(0, 87, 157, 0.05);
  border-radius: var(--border-radius-md, 20px);
  transition: var(--transition);
  z-index: -1;
}

.service-card:hover:before {
  height: 100%;
}

.service-icon {
  margin-bottom: var(--spacing-md, 40px);
}

.service-icon img {
  height: 120px;
  width: auto;
}

.service-title {
  color: var(--primary-color);
  font-size: var(--font-size-xl, 40px);
  font-weight: 700;
  margin-bottom: var(--spacing-sm, 20px);
}

.service-description {
  font-size: var(--font-size-sm, 28px);
  color: var(--grey-text, #555);
  margin-bottom: var(--spacing-md, 40px);
  line-height: var(--line-height-tight, 1.5);
}

.service-btn {
  display: inline-block;
  padding: var(--spacing-xs, 10px) var(--spacing-md, 40px);
  background-color: var(--primary-color);
  color: var(--white);
  border-radius: var(--spacing-md, 40px);
  font-size: var(--font-size-sm, 28px);
  font-weight: 600;
  transition: var(--transition);
}

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

/* About Section */
.about-section {
  background-color: var(--white);
}

.about-content {
  margin-bottom: var(--spacing-lg, 60px);
}

.about-text {
  color: var(--grey-text, #555);
  font-size: var(--base-font-size, 32px);
  margin-bottom: var(--spacing-md, 40px);
  text-align: justify;
}

.features-numbers {
  margin-top: var(--spacing-2xl, 100px);
}

.feature-number-item {
  text-align: center;
  margin-bottom: var(--spacing-lg, 60px);
}

.number-icon {
  width: var(--icon-size-xl, 120px);
  height: var(--icon-size-xl, 120px);
  margin: 0 auto var(--spacing-sm, 20px);
  background-color: var(--primary-color);
  border-radius: var(--border-radius-full, 50%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: var(--font-size-2xl, 48px);
  font-weight: 700;
  position: relative;
}

.number-icon:after {
  content: "";
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  border: var(--border-width-lg, 4px) solid var(--primary-color);
  border-radius: var(--border-radius-full, 50%);
  opacity: 0.3;
}

.feature-text {
  font-size: var(--font-size-sm, 28px);
  color: var(--text-color);
  font-weight: 600;
}

/* How We Work Section */
/* .how-work-section {
  background-color: var(--light-blue);
} */

.step-item {
  text-align: center;
  margin-bottom: var(--spacing-lg, 60px);
  position: relative;
}

.step-diamond {
  width: 100px;
  height: 100px;
  background-color: var(--white);
  margin: 0 auto var(--spacing-md, 40px);
  transform: rotate(45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  border: var(--border-width-lg, 4px) solid var(--primary-color);
  position: relative;
}

.step-number {
  transform: rotate(-45deg);
  color: var(--primary-color);
  font-size: var(--font-size-3xl, 56px);
  font-weight: 700;
}

.step-title {
  color: var(--primary-color);
  font-size: var(--font-size-lg, 36px);
  font-weight: 700;
  margin-bottom: var(--spacing-sm, 20px);
}

.step-description {
  font-size: var(--font-size-sm, 28px);
  color: var(--grey-text, #555);
}

.step-item:not(:last-child):after {
  content: "";
  position: absolute;
  top: 70px;
  left: 50%;
  width: 100%;
  height: var(--border-width-lg, 4px);
  background-color: var(--primary-color);
  opacity: 0.3;
  z-index: -1;
}

/* Location Section */
.location-section {
  padding-bottom: var(--spacing-2xl, 100px);
}

.location-text {
  margin-right: var(--spacing-sm, 20px);
}

.map-container {
  border-radius: var(--border-radius-md, 20px);
  overflow: hidden;
  box-shadow: var(--box-shadow);
  margin-bottom: var(--spacing-lg, 60px);
}

.map-btn {
  background-color: var(--primary-color);
  color: var(--white);
  padding: var(--spacing-sm, 20px) var(--spacing-md, 40px);
  border-radius: var(--spacing-lg, 60px);
  font-weight: 600;
  transition: var(--transition);
  font-size: var(--base-font-size, 32px);
}

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

/* Footer */
.footer-section {
  background-color: var(--light-color);
  padding: var(--spacing-xl, 80px) 0 var(--spacing-md, 40px);
  position: relative;
}

.footer-column {
  margin-bottom: var(--spacing-lg, 60px);
}

.footer-logo {
  max-width: 240px;
  margin-bottom: var(--spacing-sm, 20px);
}

.footer-slogan {
  font-size: var(--font-size-xs, 24px);
  color: var(--grey-text, #555);
  margin-bottom: var(--spacing-md, 40px);
}

.footer-title {
  color: var(--primary-color);
  font-size: var(--font-size-lg, 36px);
  font-weight: 700;
  margin-bottom: var(--spacing-md, 40px);
  position: relative;
  display: inline-block;
  padding-bottom: var(--spacing-sm, 20px);
}

.footer-title:after {
  content: "";
  position: absolute;
  width: 80px;
  height: var(--border-width-lg, 4px);
  background: var(--accent-color);
  bottom: 0;
  right: 0;
}

.footer-links {
  margin: 0;
  padding: 0;
}

.footer-links li {
  margin-bottom: var(--spacing-sm, 20px);
}

.footer-links a {
  color: var(--grey-text, #555);
  font-size: var(--font-size-sm, 28px);
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: var(--spacing-xs, 10px);
}

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

.footer-links a i {
  color: var(--primary-color);
  font-size: var(--icon-size-md, 32px);
}

.bcaitech-section {
  text-align: center;
  margin: var(--spacing-lg, 60px) 0;
  padding-top: var(--spacing-md, 40px);
  border-top: var(--border-width-md, 2px) solid var(--border-color);
}

.bcaitech-link {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.bcaitech-logo {
  height: 60px;
}

.bcaitech-text {
  font-size: var(--font-size-xs, 24px);
  color: var(--grey-text, #555);
}

.footer-bottom {
  text-align: center;
  padding-top: var(--spacing-md, 40px);
  border-top: var(--border-width-md, 2px) solid var(--border-color);
}

.footer-bottom p {
  font-size: var(--font-size-sm, 28px);
  color: var(--grey-text, #555);
}

/* WhatsApp BOx */
.whatsapp-chat-box {
  position: fixed;
  bottom: 100px;
  left: var(--spacing-lg, 40px);
  z-index: 999;
  width: 300px;
  background-color: white;
  border-radius: 15px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  transform: scale(0);
  transform-origin: bottom left;
  transition: transform 0.3s ease;
  opacity: 0;
  visibility: hidden;
}

.whatsapp-chat-box.active {
  transform: scale(1);
  opacity: 1;
  visibility: visible;
}

.whatsapp-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background-color: white;
  color: var(--primary-color);
  padding: 15px;
}

.whatsapp-chat-header-details {
  display: flex;
  align-items: center;
}

.whatsapp-chat-logo {
  display: flex;
  align-items: center;
  font-weight: bold;
  font-size: 16px;
}

.whatsapp-chat-logo img {
  width: 30px;
  height: 30px;
  margin-left: 10px;
  border-radius: 50%;
}

.whatsapp-close-btn {
  border: none;
  background: none;
  color: var(--primary-color);
  font-size: 20px;
  cursor: pointer;
}

.whatsapp-chat-body {
  padding: 15px;
  background-color: #f0f8ff;
}

.whatsapp-chat-message {
  background-color: white;
  padding: 10px 15px;
  border-radius: 10px;
  border-top-right-radius: 0;
  margin-bottom: 10px;
  position: relative;
}

.whatsapp-chat-message::before {
  content: "";
  position: absolute;
  top: 0;
  right: -10px;
  width: 0;
  height: 0;
  border-left: 10px solid white;
  border-top: 10px solid transparent;
}

.whatsapp-chat-message p {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

.whatsapp-chat-footer {
  padding: 15px 0px;
  text-align: center;
}

.whatsapp-chat-btn {
  width: 100%;
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 3px 18px;
  border-radius: 5px;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.3s ease;
  font-size: 18px;
  text-decoration: underline;
}

.whatsapp-chat-btn:hover {
  background-color: var(--secondary-color);
  color: white;
}

.whatsapp-toggle-btn {
  position: fixed;
  bottom: var(--spacing-md, 40px);
  left: var(--spacing-md, 40px);
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 998;
  background-color: var(--primary-color);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  overflow: hidden;
  padding: 10px;
}

.whatsapp-toggle-btn:hover {
  transform: scale(1.1);
}

.whatsapp-toggle-btn img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Error field styling */
.field-error {
  border-color: #dc3545 !important;
  background-color: #fff5f5 !important;
}

.error-message {
  color: #dc3545;
  font-size: 0.875em;
  margin-top: 0.25rem;
  display: block;
}

/* Modal error list styling */
.error-list {
  padding-left: 20px;
  margin: 15px 0;
  list-style-type: disc;
}

.error-list li {
  color: #dc3545;
  margin-bottom: 5px;
}

/* Notification modal styling */
.success-notification {
  border-left: 5px solid #28a745;
}

.error-notification {
  border-left: 5px solid #dc3545;
}

.warning-notification {
  border-left: 5px solid #ffc107;
}

.info-notification {
  border-left: 5px solid #17a2b8;
}
