/* Fleet Page Styles */
:root {
  --primary-color: #e74c3c;
  --secondary-color: #2c3e50;
  --text-color: #333;
  --light-gray: #f8f9fa;
  --border-color: #e9ecef;
  --white: #ffffff;
  --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  --border-radius: 50px;
}

/* Hero Section */
.fleet-hero-section {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  padding: 80px 0;
  color: white;
  text-align: center;
}

.fleet-hero-content h1 {
  font-size: 3rem;
  margin-bottom: 40px;
  font-weight: 700;
}

.fleet-search-form {
  max-width: 800px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.1);
  padding: 30px;
  border-radius: var(--border-radius);
  backdrop-filter: blur(10px);
}

.search-row {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 20px;
  align-items: end;
}

.search-field {
  display: flex;
  flex-direction: column;
}

.search-field label {
  font-size: 14px;
  margin-bottom: 8px;
  font-weight: 500;
}

.input-wrap {
  position: relative;
}

.fleet-search-input {
  width: 100%;
  padding: 12px 40px 12px 15px;
  border: none;
  border-radius: 50px;
  background: white;
  font-size: 14px;
  color: var(--text-color);
}

.input-wrap i {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: #666;
}

.fleet-search-btn {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 30px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
}

.fleet-search-btn:hover {
  background: #c0392b;
  transform: translateY(-2px);
}

/* Filter Section */
.fleet-filter-section {
  background: var(--white);
  padding: 30px 0;
  border-bottom: 1px solid var(--border-color);
}

.filter-row {
  display: grid;
  grid-template-columns: 1fr 1fr 2fr auto;
  gap: 30px;
  align-items: center;
}

.filter-label {
  font-weight: 600;
  margin-bottom: 10px;
  display: block;
  color: var(--text-color);
}

.price-slider-container {
  position: relative;
}

.price-slider {
  width: 100%;
  height: 6px;
  border-radius: 50px;
  background: #ddd;
  outline: none;
  -webkit-appearance: none;
}

.price-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--primary-color);
  cursor: pointer;
}

.price-display {
  margin-top: 10px;
  font-weight: 600;
  color: var(--primary-color);
}

.sort-select {
  width: 100%;
  padding: 10px;
  border: 1px solid var(--border-color);
  border-radius: 50px;
  background: white;
}

.category-buttons {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.category-btn {
  padding: 8px 16px;
  border: 1px solid var(--border-color);
  background: white;
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
  font-size: 14px;
}

.category-btn.active,
.category-btn:hover {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.view-toggle {
  display: flex;
  gap: 10px;
}

.view-icon {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-color);
  border-radius: 50px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.view-icon.active,
.view-icon:hover {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

/* Cars Section */
.cars-section {
  padding: 60px 0;
  background: var(--light-gray);
}

.cars-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-bottom: 40px;
}

/* Car Card Design - Matching the Image */
.car-card {
  background: var(--white);
  border-radius: var(--border-radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
}

.car-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Car Header with Title and Model */
.car-header {
  background: var(--white);
  padding: 15px 15px 10px 15px;
  border-bottom: 1px solid var(--border-color);
}

.car-title-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 8px;
}

.car-title-info {
  flex: 1;
}

.car-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--secondary-color);
  margin: 0;
  line-height: 1.2;
  text-align: right;
  max-width: 200px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
}

.car-model {
  font-size: 12px;
  color: #666;
  font-weight: 500;
  text-align: left;
  min-width: 60px;
}

.no-model {
  color: #e74c3c;
  font-weight: 600;
}

.car-type-row {
  display: flex;
  justify-content: flex-end;
}

.car-type {
  font-size: 12px;
  color: #666;
  font-weight: 500;
  text-align: right;
}

/* RTL Support for Arabic */
[dir="rtl"] .car-title,
[dir="rtl"] .car-model {
  text-align: left;
}

[dir="rtl"] .car-model {
  text-align: right;
}

[dir="rtl"] .car-type {
  text-align: left;
}

/* Arabic Language Support */
[lang="ar"] .car-title {
  text-align: right;
  direction: rtl;
}

[lang="ar"] .car-model {
  text-align: left;
  direction: ltr;
}

[lang="ar"] .car-type {
  text-align: right;
  direction: rtl;
}

/* English Language Support */
[lang="en"] .car-title {
  text-align: left;
  direction: ltr;
}

[lang="en"] .car-model {
  text-align: right;
  direction: ltr;
}

[lang="en"] .car-type {
  text-align: left;
  direction: ltr;
}

[dir="rtl"] .price-label,
[dir="rtl"] .price-amount {
  text-align: left;
}

[dir="rtl"] .spec-item {
  flex-direction: row-reverse;
}

[dir="rtl"] .car-title-row {
  flex-direction: row-reverse;
}

/* Car Image Section */
.car-image-section {
  padding: 0 15px;
  margin-bottom: 15px;
}

.car-image-container {
  position: relative;
  width: 100%;
  height: 140px;
  overflow: hidden;
  border-radius: 50px;
  background: #f8f9fa;
}

.car-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.car-card:hover .car-image {
  transform: scale(1.05);
}

/* Car Specifications Section */
.car-specs-section {
  padding: 0 15px;
  margin-bottom: 15px;
}

.car-specs-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.spec-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 0;
}

.spec-icon {
  width: 28px;
  height: 28px;
  border: 2px solid var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-color);
  font-size: 12px;
  flex-shrink: 0;
}

.spec-text {
  font-size: 11px;
  color: var(--text-color);
  font-weight: 500;
  line-height: 1.3;
}

/* Car Footer with Price and Booking */
.car-footer {
  margin-top: auto;
  padding: 15px;
  background: #f8f9fa;
  border-top: 1px solid var(--border-color);
}

.car-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
}

.price-section {
  flex: 1;
}

.price-label {
  font-size: 10px;
  color: #666;
  margin-bottom: 3px;
  text-align: right;
}

.price-amount {
  font-size: 1rem;
  font-weight: 700;
  color: var(--secondary-color);
  line-height: 1.2;
  text-align: right;
}

.booking-section {
  flex-shrink: 0;
}

.book-now-btn {
  background: var(--primary-color);
  color: white;
  text-align: center;
  padding: 8px 15px;
  border-radius: 50px;
  text-decoration: none;
  font-weight: 600;
  font-size: 12px;
  transition: all 0.3s ease;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  display: inline-block;
}

.book-now-btn:hover {
  background: #c0392b;
  transform: translateY(-2px);
  color: white;
  text-decoration: none;
}

/* Show More Section */
.show-more-section {
  text-align: center;
  margin: 40px 0;
}

.show-more-btn {
  background: var(--secondary-color);
  color: white;
  border: none;
  padding: 15px 40px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.show-more-btn:hover {
  background: #34495e;
  transform: translateY(-2px);
}

/* Newsletter Section */
.newsletter-section {
  background: var(--secondary-color);
  color: white;
  padding: 60px 0;
}

.newsletter-content {
  display: grid;
  grid-template-columns: 1fr 2fr;
  gap: 50px;
  align-items: start;
}

.newsletter-left h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}

.newsletter-form {
  display: flex;
  gap: 10px;
}

.newsletter-input {
  flex: 1;
  padding: 12px;
  border: none;
  border-radius: 50px;
  font-size: 14px;
}

.newsletter-btn {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 25px;
  border-radius: 50px;
  font-weight: 600;
  cursor: pointer;
}

.newsletter-right {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}

.company-info h3,
.contact-info h4,
.important-links h4 {
  margin-bottom: 15px;
  font-size: 1.2rem;
}

.contact-info p {
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.social-links {
  display: flex;
  gap: 15px;
  margin-top: 15px;
}

.social-links a {
  color: white;
  font-size: 20px;
  transition: color 0.3s ease;
}

.social-links a:hover {
  color: var(--primary-color);
}

.important-links ul {
  list-style: none;
  padding: 0;
}

.important-links li {
  margin-bottom: 8px;
}

.important-links a {
  color: white;
  text-decoration: none;
  transition: color 0.3s ease;
}

.important-links a:hover {
  color: var(--primary-color);
}

/* Pagination */
.pagination-wrapper {
  display: flex;
  justify-content: center;
  margin-top: 40px;
}

.pagination-wrapper .pagination {
  display: flex;
  gap: 10px;
}

.pagination-wrapper .page-link {
  padding: 10px 15px;
  border: 1px solid var(--border-color);
  border-radius: 50px;
  color: var(--text-color);
  text-decoration: none;
  transition: all 0.3s ease;
}

.pagination-wrapper .page-link:hover,
.pagination-wrapper .page-item.active .page-link {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 1200px) {
  .cars-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 768px) {
  .fleet-hero-content h1 {
    font-size: 2rem;
  }
  
  .search-row {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  
  .filter-row {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  
  .cars-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .car-title {
    max-width: 150px;
    font-size: 1rem;
  }
  
  .car-footer {
    flex-direction: column;
    gap: 15px;
    text-align: center;
  }
  
  .price-label,
  .price-amount {
    text-align: center;
  }
  
  .newsletter-content {
    grid-template-columns: 1fr;
    gap: 30px;
  }
  
  .newsletter-right {
    grid-template-columns: 1fr;
    gap: 20px;
  }
}

@media (max-width: 480px) {
  .fleet-hero-section {
    padding: 40px 0;
  }
  
  .fleet-search-form {
    padding: 20px;
  }
  
  .cars-grid {
    grid-template-columns: 1fr;
  }
  
  .car-content {
    padding: 15px;
  }
  
  .car-title {
    font-size: 1.1rem;
    max-width: 180px;
  }
  
  .price-amount {
    font-size: 1.5rem;
  }
}

/* Loading States */
.loading {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid #f3f3f3;
  border-top: 2px solid var(--primary-color);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Accessibility */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Focus States */
.fleet-search-input:focus,
.sort-select:focus,
.newsletter-input:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

.book-now-btn:focus,
.fleet-search-btn:focus,
.show-more-btn:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}