html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #2a5298;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
  font-family: 'Poppins', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  line-height: 1.7;
  color: #333;
}

/* Arabic Text Support */
[dir="rtl"] {
  font-family: 'Noto Kufi Arabic', 'Segoe UI', 'Tahoma', 'Arial', sans-serif;
  text-align: right;
}

/* Brand Text Styling */
.brand-text {
  line-height: 1.2;
}

.brand-text span {
  display: block;
}

@media (max-width: 768px) {
  .brand-text span {
    font-size: 0.9rem !important;
  }
  .brand-text .text-primary {
    font-size: 0.8rem !important;
  }
}

/* SDCC Custom Styles */
.hero-section {
  background: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
  background-attachment: fixed;
  min-height: 70vh;
  display: flex;
  align-items: center;
}

.text-primary {
  color: #2a5298 !important;
}

.btn-primary {
  background-color: #2a5298;
  border-color: #2a5298;
}

.btn-primary:hover {
  background-color: #1e3c72;
  border-color: #1e3c72;
}

.card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.15) !important;
}

.navbar-brand {
  font-size: 1.5rem;
}

.navbar-brand small {
  font-size: 0.7rem;
  display: block;
  line-height: 1;
}

.footer {
  margin-top: auto;
}

/* Smooth scrolling */
html {
  scroll-behavior: smooth;
}

/* Section spacing */
section {
  scroll-margin-top: 80px;
}

/* Professional color scheme - Accessibility Enhanced */
:root {
  --sdcc-primary: #2a5298;
  --sdcc-secondary: #1e3c72;
  --sdcc-accent: #f8f9fa;
  --sdcc-dark: #212529;
  --sdcc-primary-dark: #1e3c72; /* For better contrast */
  --sdcc-text-on-primary: #ffffff; /* Ensures 4.5:1 contrast */
  --sdcc-text-muted: #6c757d; /* Better than default gray */
  
  /* Construction Industry Colors */
  --sdcc-accent-orange: #ff6b35; /* Construction industry accent */
  --sdcc-accent-yellow: #ffa726; /* Safety/warning colors */
  --sdcc-construction-blue: #0066cc;
  --sdcc-steel-gray: #495057;
  --sdcc-light-gray: #f8f9fa;
  --sdcc-medium-gray: #6c757d;
  
  /* Professional shadows */
  --shadow-light: 0 2px 4px rgba(0,0,0,0.08);
  --shadow-medium: 0 4px 12px rgba(0,0,0,0.15);
  --shadow-heavy: 0 8px 24px rgba(0,0,0,0.25);
}

/* Typography improvements */
h1, h2, h3, h4, h5, h6 {
  font-weight: 600;
}

.display-3 {
  font-weight: 700;
}

/* Enhanced button styles */
.btn-lg {
  padding: 12px 30px;
  font-size: 1.1rem;
}

/* Professional spacing */
.py-5 {
  padding-top: 4rem !important;
  padding-bottom: 4rem !important;
}

/* Logo Styles */
.logo-container {
  position: relative;
  display: inline-block;
  width: 80px;
  height: 45px;
}

.logo-img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.logo-text {
  display: flex;
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #2a5298 0%, #1e3c72 100%);
  border-radius: 8px;
  padding: 8px 12px;
  box-shadow: 0 2px 8px rgba(42, 82, 152, 0.3);
}

.logo-main {
  color: white;
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: 1px;
}

.logo-icon {
  color: #00ff88;
  margin-left: 4px;
  font-size: 0.9rem;
}

/* Responsive logo */
@media (max-width: 768px) {
  .brand-text small {
    display: none;
  }

  .logo-container {
    width: 60px;
    height: 40px;
  }

  .logo-text {
    padding: 4px 8px;
  }

  .logo-main {
    font-size: 0.9rem;
  }
}

/* Professional Enhancements */
.hero-section {
  position: relative;
  overflow: hidden;
}

.hero-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(30, 60, 114, 0.1);
  backdrop-filter: blur(0.5px);
}

.hero-section .container {
  position: relative;
  z-index: 2;
}

/* Enhanced Navigation */
.navbar {
  backdrop-filter: blur(10px);
  background-color: rgba(255, 255, 255, 0.95) !important;
  transition: all 0.3s ease;
}

.navbar-nav .nav-link {
  position: relative;
  transition: color 0.3s ease;
}

.navbar-nav .nav-link:hover {
  color: var(--sdcc-primary) !important;
}

.navbar-nav .nav-link::after {
  content: '';
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--sdcc-primary);
  transition: width 0.3s ease;
}

.navbar-nav .nav-link:hover::after {
  width: 100%;
}

/* Enhanced Cards */
.card {
  border: none !important;
  border-radius: 15px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
}

.card-body {
  padding: 2rem;
}

/* Professional Sections */
.section-divider {
  height: 2px;
  background: linear-gradient(90deg, transparent, var(--sdcc-primary), transparent);
  margin: 3rem auto;
  width: 100px;
}

/* Enhanced Typography */
.display-4 {
  font-weight: 700;
  letter-spacing: -0.02em;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}

.lead {
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1.6;
}

/* Professional Contact Section */
.contact-card {
  background: linear-gradient(135deg, rgba(42, 82, 152, 0.05), rgba(30, 60, 114, 0.05));
  border-radius: 20px;
  padding: 2rem;
  transition: all 0.3s ease;
}

.contact-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 15px 35px rgba(42, 82, 152, 0.1);
}

.contact-icon {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, var(--sdcc-primary), var(--sdcc-secondary));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  color: white;
  font-size: 1.5rem;
}

/* Enhanced Footer */
.footer {
  background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%) !important;
  border-top: 3px solid var(--sdcc-primary);
}

/* Professional Animations */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.fade-in-up {
  animation: fadeInUp 0.8s ease-out forwards;
}

/* Enhanced Buttons */
.btn {
  border-radius: 50px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.btn-primary {
  background: linear-gradient(135deg, var(--sdcc-primary) 0%, var(--sdcc-secondary) 100%);
  border: none;
  box-shadow: 0 4px 15px rgba(42, 82, 152, 0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px rgba(42, 82, 152, 0.4);
}

.btn-outline-light {
  border: 2px solid rgba(255, 255, 255, 0.8);
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
}

.btn-outline-light:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: white;
  transform: translateY(-2px);
}

/* Professional spacing and layout */
.section-title {
  position: relative;
  margin-bottom: 3rem;
}

.section-title::after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 3px;
  background: var(--sdcc-primary);
}

/* Enhanced Industries Section */
.industries-list {
  columns: 2;
  column-gap: 2rem;
}

.industries-list li {
  break-inside: avoid;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* Accessibility - Skip Navigation Link */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.sr-only-focusable:focus {
  position: static !important;
  width: auto !important;
  height: auto !important;
  padding: 0.5rem 1rem !important;
  margin: 0 !important;
  overflow: visible !important;
  clip: auto !important;
  white-space: normal !important;
  background: var(--sdcc-primary) !important;
  color: white !important;
  text-decoration: none !important;
  z-index: 100000 !important;
  border-radius: 0.375rem !important;
  font-weight: 600 !important;
  box-shadow: 0 4px 15px rgba(42, 82, 152, 0.5) !important;
}

/* Accessibility Enhancements - High Contrast Focus States */
.btn:focus-visible,
.form-control:focus-visible,
.form-select:focus-visible,
.form-check-input:focus-visible,
a:focus-visible {
  outline: 3px solid var(--sdcc-primary);
  outline-offset: 2px;
  box-shadow: 0 0 0 2px white, 0 0 0 4px var(--sdcc-primary);
}

/* Enhanced text contrast */
.text-muted {
  color: var(--sdcc-text-muted) !important;
}

/* Better contrast for hero section text */
.hero-section .display-4,
.hero-section .lead,
.hero-section .h5 {
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7);
  color: var(--sdcc-text-on-primary) !important;
}

/* Ensure proper contrast for card text */
.card .text-muted {
  color: #495057 !important; /* Better contrast on white backgrounds */
}

/* Construction Industry Color Classes */
.text-construction-orange { 
  color: var(--sdcc-accent-orange) !important; 
}

.text-construction-yellow { 
  color: var(--sdcc-accent-yellow) !important; 
}

.text-steel-gray { 
  color: var(--sdcc-steel-gray) !important; 
}

.bg-construction-gradient {
  background: linear-gradient(135deg, 
    var(--sdcc-primary) 0%, 
    var(--sdcc-construction-blue) 50%, 
    var(--sdcc-secondary) 100%);
}

/* Enhanced Button Styles */
.btn-construction {
  background: linear-gradient(135deg, 
    var(--sdcc-accent-orange) 0%, 
    #e55b2b 100%);
  border: none;
  color: white;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 12px 28px;
  border-radius: 6px;
  box-shadow: var(--shadow-medium);
  transition: all 0.3s ease;
}

.btn-construction:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-heavy);
  background: linear-gradient(135deg, 
    #e55b2b 0%, 
    var(--sdcc-accent-orange) 100%);
  color: white;
}

/* Construction pattern overlay */
.construction-pattern-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    repeating-linear-gradient(
      45deg,
      transparent,
      transparent 2px,
      rgba(255, 255, 255, 0.03) 2px,
      rgba(255, 255, 255, 0.03) 4px
    );
  pointer-events: none;
}

.text-shadow-strong {
  text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.8);
}

/* Hero Animations */
.hero-badge {
  animation: fadeInDown 1s ease-out 0.5s both;
}

.hero-actions {
  animation: fadeInUp 1s ease-out 1s both;
}

@keyframes fadeInDown {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Professional Construction Cards */
.card-construction {
  border: none;
  border-radius: 12px;
  overflow: hidden;
  background: white;
  box-shadow: var(--shadow-light);
  transition: all 0.4s ease;
  position: relative;
}

.card-construction::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    var(--sdcc-primary), 
    var(--sdcc-accent-orange));
  transition: all 0.4s ease;
}

.card-construction:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: var(--shadow-heavy);
}

.card-construction:hover::before {
  height: 6px;
}

.card-icon-construction {
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, var(--sdcc-primary), var(--sdcc-secondary));
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: white;
  font-size: 2rem;
  box-shadow: var(--shadow-medium);
}

/* Service Features */
.service-features {
  border-top: 1px solid rgba(42, 82, 152, 0.1);
  padding-top: 1rem;
}

.service-feature {
  display: flex;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(42, 82, 152, 0.05);
}

.service-feature:last-child {
  border-bottom: none;
}

.service-feature-icon {
  width: 20px;
  height: 20px;
  background: var(--sdcc-accent-orange);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 0.75rem;
  color: white;
  font-size: 0.75rem;
  flex-shrink: 0;
}

/* Construction Branding Elements */
.construction-accent-bar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    var(--sdcc-primary) 0%, 
    var(--sdcc-accent-orange) 50%, 
    var(--sdcc-primary) 100%);
}

.construction-badge {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--sdcc-primary), var(--sdcc-secondary));
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 1.2rem;
}

.construction-nav-link {
  position: relative;
  border-radius: 6px;
  transition: all 0.3s ease;
}

.construction-nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-1px);
}

/* Enhanced Section Dividers */
.section-divider {
  height: 4px;
  background: linear-gradient(90deg, 
    var(--sdcc-primary) 0%, 
    var(--sdcc-accent-orange) 50%, 
    var(--sdcc-primary) 100%);
  margin: 3rem auto;
  width: 120px;
  border-radius: 2px;
}

/* Section with Construction Accent */
.section-construction-accent {
  background: linear-gradient(135deg, 
    rgba(42, 82, 152, 0.05) 0%, 
    rgba(255, 107, 53, 0.03) 100%);
  position: relative;
}

.section-construction-accent::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, 
    var(--sdcc-primary), 
    var(--sdcc-accent-orange));
}

/* Footer Enhancements */
.construction-accent-line {
  height: 3px;
  background: linear-gradient(90deg, 
    var(--sdcc-primary) 0%, 
    var(--sdcc-accent-orange) 50%, 
    var(--sdcc-primary) 100%);
  border-radius: 2px;
}

.footer-services li {
  padding: 0.25rem 0;
  color: #adb5bd;
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--sdcc-primary);
  color: white;
  border-radius: 8px;
  text-decoration: none;
  transition: all 0.3s ease;
}

.social-link:hover {
  background: var(--sdcc-accent-orange);
  transform: translateY(-2px);
  color: white;
}

/* Professional responsive design */
@media (max-width: 768px) {
  .hero-section {
    min-height: 60vh;
    text-align: center;
    padding: 3rem 0;
  }

  .display-4 {
    font-size: 2rem;
  }
  
  .display-3 {
    font-size: 2.5rem;
  }
  
  .hero-actions {
    flex-direction: column;
    gap: 1rem;
  }
  
  .hero-actions .btn {
    width: 100%;
    max-width: 280px;
  }
  
  .card-construction {
    margin-bottom: 2rem;
  }
  
  /* Mobile navigation improvements */
  .navbar-collapse {
    background: rgba(255, 255, 255, 0.98);
    border-radius: 8px;
    margin-top: 1rem;
    padding: 1rem;
    box-shadow: var(--shadow-medium);
  }
  
  .navbar-nav .nav-link {
    color: var(--sdcc-dark) !important;
    font-weight: 600;
    padding: 0.75rem 0;
    border-bottom: 1px solid rgba(42, 82, 152, 0.1);
  }
  
  .navbar-nav .nav-link:hover {
    color: var(--sdcc-primary) !important;
    background: rgba(42, 82, 152, 0.05);
    border-radius: 4px;
  }

  .section-title::after {
    left: 0;
    transform: none;
  }

  .industries-list {
    columns: 1;
  }
}
