@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  /* HSL Color System */
  --slate-900: #0f172a; /* Deep Slate (Navy/Black) */
  --slate-800: #1e293b;
  --slate-700: #334155;
  --slate-600: #475569;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  
  --gold-500: #d97706; /* Warm Gold (Accent) */
  --gold-600: #b45309;
  --gold-100: #fef3c7;
  
  --primary: var(--slate-900);
  --secondary: var(--slate-800);
  --accent: var(--gold-500);
  --accent-hover: var(--gold-600);
  --background: var(--slate-50);
  --surface: #ffffff;
  --text-main: var(--slate-800);
  --text-muted: var(--slate-600);
  --text-light: var(--slate-100);
  
  /* Layout & Cards */
  --font-en: 'Inter', system-ui, -apple-system, sans-serif;
  --font-ar: 'Cairo', system-ui, -apple-system, sans-serif;
  --spacing-sm: 12px;
  --spacing-md: 24px;
  --spacing-lg: 48px;
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 24px;
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 10px 30px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 40px rgba(15, 23, 42, 0.12);
  --transition-smooth: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-fast: all 0.2s ease;
}

/* RTL Override */
[dir="rtl"] {
  --font-en: 'Cairo', system-ui, -apple-system, sans-serif;
}

/* Reset & Global */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-en);
  background-color: var(--background);
  color: var(--text-main);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body[dir="rtl"] {
  font-family: var(--font-ar);
}

a {
  color: inherit;
  text-decoration: none;
}

/* Glassmorphism Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(241, 245, 249, 0.5);
  transition: var(--transition-fast);
}

header.scrolled {
  background: rgba(255, 255, 255, 0.95);
  box-shadow: var(--shadow-sm);
}

.nav-container {
  max-width: 1300px;
  margin: 0 auto;
  padding: var(--spacing-sm) var(--spacing-md);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Dynamic Brand Logo Alignment */
.logo-container {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-img {
  height: 58px;
  width: auto;
  object-fit: contain;
}

.logo-text {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--primary);
  letter-spacing: -0.5px;
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links {
  display: flex;
  gap: 24px;
  list-style: none;
}

.nav-links a {
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text-muted);
  position: relative;
  padding: 6px 0;
  transition: var(--transition-fast);
}

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

.nav-links a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--accent);
  transition: var(--transition-fast);
}

.nav-links a:hover::after {
  width: 100%;
}

.lang-switch {
  background: var(--primary);
  color: white !important;
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  transition: var(--transition-fast);
  border: 1px solid transparent;
}

.lang-switch:hover {
  background: transparent;
  color: var(--primary) !important;
  border-color: var(--primary);
}

/* Mobile Toggle */
.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
}

.mobile-menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--primary);
  margin: 5px 0;
  transition: var(--transition-fast);
  border-radius: 2px;
}

/* ----------------------------------------------------
 * HERO SLIDER
 * ---------------------------------------------------- */
.hero-slider {
  position: relative;
  height: 85vh;
  min-height: 600px;
  overflow: hidden;
  background-color: var(--primary);
  margin-top: 68px; /* Avoid header overlapping */
}

.slide {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  opacity: 0;
  z-index: 1;
  transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  align-items: center;
}

.slide.active {
  opacity: 1;
  z-index: 2;
}

.slide-image-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}

.slide-image-wrapper::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(15, 23, 42, 0.5) 0%, rgba(15, 23, 42, 0.85) 100%);
}

.slide-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.08);
  transition: transform 6s ease-out;
}

.slide.active .slide-image {
  transform: scale(1);
}

.slide-content-container {
  max-width: 1300px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
  position: relative;
  z-index: 3;
  width: 100%;
  color: white;
}

.slide-content {
  max-width: 700px;
  text-align: start;
}

.slide-content h4 {
  color: var(--accent);
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: var(--spacing-sm);
  letter-spacing: 1.5px;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease 0.3s;
}

.slide-content h1 {
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: var(--spacing-sm);
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease 0.5s;
}

.slide-content p {
  font-size: clamp(1rem, 2vw, 1.25rem);
  opacity: 0;
  margin-bottom: var(--spacing-md);
  color: rgba(241, 245, 249, 0.8);
  transform: translateY(20px);
  transition: all 0.8s ease 0.7s;
}

.slide-content .btn {
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease 0.9s;
}

.slide.active .slide-content h4,
.slide.active .slide-content h1,
.slide.active .slide-content p,
.slide.active .slide-content .btn {
  opacity: 1;
  transform: translateY(0);
}

/* Slider Controls */
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  width: 54px;
  height: 54px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  transition: var(--transition-fast);
}

.slider-arrow:hover {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 15px rgba(217, 119, 6, 0.4);
}

/* Mirror Arrows for LTR/RTL */
.slider-prev {
  left: 32px;
}
.slider-next {
  right: 32px;
}

[dir="rtl"] .slider-prev {
  left: auto;
  right: 32px;
  transform: translateY(-50%) scaleX(-1);
}
[dir="rtl"] .slider-next {
  right: auto;
  left: 32px;
  transform: translateY(-50%) scaleX(-1);
}

.slider-dots {
  position: absolute;
  bottom: 32px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  gap: 12px;
}

.slider-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  cursor: pointer;
  transition: var(--transition-fast);
}

.slider-dot.active {
  background: var(--accent);
  transform: scale(1.2);
  box-shadow: 0 0 10px rgba(217, 119, 6, 0.4);
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 12px 28px;
  background: var(--accent);
  color: white;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: var(--transition-fast);
  text-align: center;
  border: none;
  cursor: pointer;
}

.btn:hover {
  background: var(--accent-hover);
  box-shadow: 0 8px 20px rgba(217, 119, 6, 0.3);
  transform: translateY(-2px);
}

/* ----------------------------------------------------
 * SECTIONS & LAYOUTS
 * ---------------------------------------------------- */
section {
  padding: 90px 24px;
}

.section-container {
  max-width: 1300px;
  margin: 0 auto;
}

.section-title {
  text-align: center;
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: var(--spacing-lg);
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 4px;
  background: var(--accent);
  margin: 12px auto 0;
  border-radius: 2px;
}

/* Grid Framework */
.grid {
  display: grid;
  gap: var(--spacing-md);
  grid-template-columns: 1fr;
}

@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
}

/* About Us Section */
#about {
  background: white;
}

.about-wrapper {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
  align-items: center;
}

@media (min-width: 992px) {
  .about-wrapper {
    flex-direction: row;
    gap: var(--spacing-lg);
  }
}

.about-content {
  flex: 1.2;
}

.about-content h3 {
  font-size: 1.8rem;
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
  color: var(--secondary);
}

.about-content p {
  font-size: 1.1rem;
  color: var(--text-muted);
  text-align: justify;
}

.about-visual {
  flex: 0.8;
  width: 100%;
  position: relative;
}

.about-image {
  width: 100%;
  height: 380px;
  border-radius: var(--radius-md);
  object-fit: cover;
  box-shadow: var(--shadow-md);
}

.about-badge {
  position: absolute;
  bottom: -20px;
  right: -20px;
  background: var(--primary);
  color: white;
  padding: 24px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  text-align: center;
  border-bottom: 4px solid var(--accent);
}

[dir="rtl"] .about-badge {
  right: auto;
  left: -20px;
}

.about-badge span {
  display: block;
  font-size: 2.2rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
}

/* Expertise / Divisions Cards */
#expertise {
  background: var(--slate-100);
}

.division-card {
  background: white;
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  box-shadow: var(--shadow-sm);
  border-top: 4px solid var(--primary);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.division-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-top-color: var(--accent);
}

.div-icon-wrapper {
  background: var(--gold-100);
  color: var(--accent);
  width: 56px;
  height: 56px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
}

.division-card h3 {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--primary);
}

.division-card p {
  color: var(--text-muted);
  font-size: 0.98rem;
  line-height: 1.6;
}

/* Brands & Partners Section */
#products {
  background: white;
}

.brand-card {
  background: var(--slate-50);
  border: 1px solid rgba(241, 245, 249, 0.8);
  border-radius: var(--radius-md);
  padding: var(--spacing-md);
  transition: var(--transition-smooth);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.brand-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-4px);
  background: white;
}

.brand-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.brand-logo-container {
  height: 50px;
  width: 150px;
  background: white;
  border-radius: var(--radius-sm);
  padding: 0;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.brand-logo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.brand-division-tag {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: white;
  background: var(--slate-700);
  padding: 4px 10px;
  border-radius: 20px;
}

.brand-division-tag.security { background-color: #1e3a8a; }
.brand-division-tag.packaging { background-color: #0d9488; }
.brand-division-tag.adhesives { background-color: #b45309; }

.brand-card h4 {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--primary);
}

.brand-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ----------------------------------------------------
 * CONTACT & MAP SECTION
 * ---------------------------------------------------- */
#contact {
  background: var(--slate-100);
}

.contact-layout {
  display: flex;
  flex-direction: column;
  gap: var(--spacing-md);
}

@media (min-width: 992px) {
  .contact-layout {
    flex-direction: row;
    align-items: stretch;
    gap: var(--spacing-lg);
  }
}

.contact-info-panel {
  flex: 0.9;
  background: white;
  border-radius: var(--radius-md);
  padding: 40px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 32px;
}

.contact-info-list {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.contact-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.contact-icon {
  background: var(--gold-100);
  color: var(--accent);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 1.2rem;
}

.contact-details h5 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--secondary);
  margin-bottom: 4px;
}

.contact-details p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Leaflet Map integration */
.map-panel {
  width: 100%;
  height: 260px;
  background: white;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(241, 245, 249, 0.8);
}

#map {
  width: 100%;
  height: 100%;
  z-index: 5;
}

/* Customizing Leaflet styles */
.leaflet-popup-content-wrapper {
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(241, 245, 249, 0.5);
}

/* ----------------------------------------------------
 * FOOTER
 * ---------------------------------------------------- */
footer {
  background: var(--primary);
  color: white;
  padding: 60px 24px 30px;
  border-top: 4px solid var(--accent);
}

.footer-grid {
  max-width: 1300px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 40px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 992px) {
  .footer-grid {
    grid-template-columns: 1fr 1.2fr 1fr;
  }
}

.footer-col h4 {
  color: white;
  font-size: 1.15rem;
  font-weight: 700;
  margin-top: 0;
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 8px;
}

.footer-col h4::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 35px;
  height: 2px;
  background: var(--accent);
}

body[dir="rtl"] .footer-col h4::after {
  left: auto;
  right: 0;
}

.footer-logo-img {
  height: 65px;
  margin-bottom: 16px;
  object-fit: contain;
}

.footer-tagline {
  font-size: 0.95rem;
  color: rgba(241, 245, 249, 0.7);
  line-height: 1.6;
  margin: 0;
}

.footer-contact-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-contact-list li {
  font-size: 0.95rem;
  color: rgba(241, 245, 249, 0.7);
  line-height: 1.6;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.footer-contact-list li i {
  color: var(--accent);
  margin-top: 4px;
  font-size: 1.05rem;
}

.footer-contact-list li a {
  color: rgba(241, 245, 249, 0.7);
  text-decoration: none;
  transition: color 0.2s;
}

.footer-contact-list li a:hover {
  color: var(--accent);
}

.footer-map-container {
  height: 200px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom {
  max-width: 1300px;
  margin: 24px auto 0;
  text-align: center;
  font-size: 0.85rem;
  color: rgba(241, 245, 249, 0.5);
}

/* ----------------------------------------------------
 * SCROLL ANIMATION & TRANSITIONS
 * ---------------------------------------------------- */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.animate-on-scroll.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Delay modifiers */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.2s; }
.delay-3 { transition-delay: 0.3s; }
.delay-4 { transition-delay: 0.4s; }

/* Responsive styles */
@media (max-width: 992px) {
  .mobile-menu-toggle {
    display: block;
  }
  .nav-menu {
    display: none;
    flex-direction: column;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #0f172a;
    padding: 24px;
    border-bottom: 2px solid var(--accent);
    box-shadow: var(--shadow-md);
    z-index: 999;
  }
  .nav-menu.active {
    display: flex;
  }
  .nav-links {
    flex-direction: column;
    align-items: center;
    gap: 16px;
    margin-bottom: 16px;
    padding: 0;
  }
  .nav-links li a {
    color: white;
  }
}

/* Floating WhatsApp Widget */
.whatsapp-float {
  position: fixed;
  bottom: 30px;
  inset-inline-end: 30px;
  background: #25d366;
  color: white;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.15);
  transition: transform 0.2s, background 0.2s;
  z-index: 999;
  text-decoration: none;
}
.whatsapp-float:hover {
  transform: scale(1.1);
  background: #128c7e;
  color: white;
}

/* FAQ Accordion Section */
.faq-section {
  padding: var(--spacing-lg) 24px;
  background: var(--slate-50);
}
.faq-list {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.faq-item {
  background: white;
  border: 1px solid rgba(226, 232, 240, 0.8);
  border-radius: var(--radius-sm);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.2s;
}
.faq-item.active {
  border-color: var(--accent);
}
.faq-item-header {
  padding: 20px 24px;
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--primary);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  transition: background 0.2s;
}
.faq-item-header:hover {
  background: var(--slate-50);
}
.faq-item-header i {
  transition: transform 0.3s ease;
  color: var(--accent);
}
.faq-item.active .faq-item-header i {
  transform: rotate(180deg);
}
.faq-item-content {
  max-height: 0;
  padding: 0 24px;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0.16, 1, 0.3, 1), padding 0.3s ease;
  background: white;
  border-top: 1px solid transparent;
}
.faq-item.active .faq-item-content {
  max-height: 500px;
  padding: 20px 24px;
  border-top: 1px solid rgba(226, 232, 240, 0.5);
}
.faq-item-content p {
  margin: 0;
  line-height: 1.7;
  color: var(--text-muted);
  font-size: 0.98rem;
}

/* Contact Form styles */
.contact-form-map-column {
  display: flex;
  flex-direction: column;
  gap: 30px;
  width: 100%;
}
.contact-form {
  background: white;
  padding: 30px;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid rgba(226, 232, 240, 0.8);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
@media (min-width: 576px) {
  .form-grid {
    grid-template-columns: 1fr 1fr;
  }
}
.contact-form input, .contact-form textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--text-main);
  background: var(--slate-50);
  transition: border-color 0.2s, background 0.2s;
}
.contact-form input:focus, .contact-form textarea:focus {
  border-color: var(--accent);
  background: white;
  outline: none;
}
.contact-form textarea {
  min-height: 120px;
  resize: vertical;
}
.contact-success-alert {
  background: #dcfce7;
  border: 1px solid #bbf7d0;
  color: #166534;
  padding: 16px 24px;
  border-radius: var(--radius-sm);
  margin-bottom: 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 600;
  width: 100%;
  box-sizing: border-box;
}
.contact-success-alert i {
  font-size: 1.3rem;
}

