/* E6000 Custom Styles */

:root {
  --primary-color: #0066cc;
  --primary-dark: #004d99;
  --secondary-color: #6c757d;
  --success-color: #28a745;
  --warning-color: #ffc107;
  --danger-color: #dc3545;
  --light-bg: #f8f9fa;
  --dark-bg: #212529;
}

/* AI Image Placeholder Styles */
ai-img {
  display: block;
  background: linear-gradient(135deg, #e9ecef 0%, #dee2e6 100%);
  position: relative;
  overflow: hidden;
}

ai-img::before {
  content: attr(alt);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: #6c757d;
  font-size: 12px;
  text-align: center;
  padding: 1rem;
  max-width: 80%;
}

ai-img::after {
  content: '';
  position: absolute;
  top: 10px;
  right: 10px;
  width: 24px;
  height: 24px;
  background: rgba(0,0,0,0.1);
  border-radius: 4px;
}

ai-img.rounded-circle {
  border-radius: 50%;
}

ai-img.card-img-top {
  border-radius: 8px 8px 0 0;
}

ai-img.w-100 {
  width: 100%;
}

/* Set dimensions based on size attribute */
ai-img[size="1920x700"] {
  width: 100%;
  height: 700px;
  max-height: 50vh;
}

ai-img[size="800x450"],
ai-img[size="800x400"] {
  width: 100%;
  height: auto;
  aspect-ratio: 16/9;
}

ai-img[size="600x400"] {
  width: 100%;
  height: auto;
  aspect-ratio: 3/2;
}

ai-img[size="400x300"] {
  width: 100%;
  height: auto;
  aspect-ratio: 4/3;
}

ai-img[size="400x250"] {
  width: 100%;
  height: auto;
  aspect-ratio: 8/5;
}

ai-img[size="150x45"] {
  width: 150px;
  height: 45px;
}

ai-img[size="150x150"] {
  width: 150px;
  height: 150px;
}

ai-img[size="120x80"] {
  width: 120px;
  height: 80px;
}

ai-img[size="100x100"] {
  width: 100px;
  height: 100px;
}

ai-img[size="80x80"] {
  width: 80px;
  height: 80px;
}

ai-img[size="80x60"] {
  width: 80px;
  height: 60px;
}

ai-img[size="50x50"] {
  width: 50px;
  height: 50px;
}

ai-img[size="1920x400"] {
  width: 100%;
  height: 400px;
}

/* Promo Bar */
.promo-bar {
  font-size: 0.9rem;
}

/* Top Bar */
.top-bar a {
  text-decoration: none;
}

.top-bar a:hover {
  opacity: 0.8;
}

/* Navigation */
.navbar {
  transition: box-shadow 0.3s ease;
}

.navbar-brand ai-img {
  display: inline-block;
}

.nav-link {
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  transition: color 0.3s ease;
}

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

/* Hero Carousel */
.hero-section .carousel-item {
  position: relative;
}

.hero-section .carousel-item ai-img {
  width: 100%;
  height: 700px;
  object-fit: cover;
}

.hero-section .carousel-caption {
  background: rgba(0, 0, 0, 0.5);
  padding: 2rem;
  border-radius: 8px;
  max-width: 600px;
  left: 50%;
  transform: translateX(-50%);
  bottom: 20%;
}

@media (max-width: 768px) {
  .hero-section .carousel-item ai-img {
    height: 400px;
  }

  .hero-section .carousel-caption {
    padding: 1rem;
  }

  .hero-section .carousel-caption h1 {
    font-size: 1.5rem;
  }
}

/* Cards */
.card {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: none;
  border-radius: 8px;
  overflow: hidden;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.card-img-top {
  transition: transform 0.3s ease;
}

.card:hover .card-img-top {
  transform: scale(1.02);
}

/* Author Card */
.author-card {
  border-left: 4px solid var(--primary-color);
}

.author-card ai-img {
  border: 3px solid var(--primary-color);
}

/* Stats Section */
.stats-section h2 {
  font-weight: 700;
}

/* Buttons */
.btn-primary {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

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

.btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
}

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

/* Floating Buttons */
.floating-buttons {
  z-index: 1000;
}

.floating-buttons .btn {
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.floating-buttons .btn:hover {
  transform: scale(1.1);
}

#backToTop {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

#backToTop.visible {
  opacity: 1;
  visibility: visible;
}

/* Footer */
footer h5 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

footer ul li {
  margin-bottom: 0.5rem;
}

footer a {
  transition: opacity 0.3s ease;
}

footer a:hover {
  opacity: 0.7;
}

/* Page Banner */
.page-banner {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
}

/* Breadcrumb */
.breadcrumb {
  margin-bottom: 0;
  background: transparent;
}

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

.breadcrumb-item a:hover {
  text-decoration: underline;
}

/* Product Grid */
.products-section .card .badge {
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1;
}

.products-section .card {
  position: relative;
}

/* Solutions Section */
.solutions-section .card-title i {
  font-size: 1.2rem;
}

/* Certifications */
.cert-badge {
  opacity: 0.8;
  transition: opacity 0.3s ease;
}

.cert-badge:hover {
  opacity: 1;
}

/* Timeline */
.timeline-container .row {
  position: relative;
}

.timeline-container .row::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 2px;
  background: #dee2e6;
  transform: translateX(-50%);
}

@media (max-width: 768px) {
  .timeline-container .row::before {
    left: 0;
  }
}

/* Article Content */
.article-content h2 {
  margin-top: 2rem;
  margin-bottom: 1rem;
  color: #333;
}

.article-content h3 {
  margin-top: 1.5rem;
  margin-bottom: 0.75rem;
  color: #444;
}

.article-content p {
  line-height: 1.8;
  margin-bottom: 1rem;
}

.article-content ul,
.article-content ol {
  margin-bottom: 1rem;
  padding-left: 1.5rem;
}

.article-content li {
  margin-bottom: 0.5rem;
  line-height: 1.7;
}

.article-content a {
  color: var(--primary-color);
}

.article-content a:hover {
  text-decoration: underline;
}

/* Tables */
.table-responsive {
  border-radius: 8px;
  overflow: hidden;
}

.table thead {
  background-color: var(--primary-color);
  color: white;
}

/* Accordion */
.accordion-button:not(.collapsed) {
  background-color: rgba(0, 102, 204, 0.1);
  color: var(--primary-color);
}

.accordion-button:focus {
  box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
}

/* Modal */
.modal-header.bg-primary {
  border-bottom: none;
}

.modal-content {
  border: none;
  border-radius: 12px;
  overflow: hidden;
}

/* Form Styles */
.form-control:focus,
.form-select:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.25rem rgba(0, 102, 204, 0.25);
}

.form-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
}

/* Error Pages */
.error-section {
  min-height: 60vh;
  display: flex;
  align-items: center;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
  .stats-section .display-4 {
    font-size: 2.5rem;
  }
}

@media (max-width: 576px) {
  .promo-bar {
    font-size: 0.8rem;
  }

  .promo-bar .btn {
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
  }

  .stats-section .display-4 {
    font-size: 2rem;
  }

  .page-banner h1 {
    font-size: 1.75rem;
  }

  .floating-buttons .btn {
    width: 45px;
    height: 45px;
  }
}

/* Print Styles */
@media print {
  .promo-bar,
  .top-bar,
  .navbar,
  .floating-buttons,
  footer,
  .modal {
    display: none !important;
  }

  .page-banner {
    background: #f8f9fa !important;
    color: #333 !important;
    -webkit-print-color-adjust: exact;
  }
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.card {
  animation: fadeIn 0.5s ease-out;
}

/* Smooth Scroll */
html {
  scroll-behavior: smooth;
}

/* Selection Color */
::selection {
  background-color: var(--primary-color);
  color: white;
}

/* Focus Styles for Accessibility */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
  outline: 2px solid var(--primary-color);
  outline-offset: 2px;
}

/* Skip Link for Accessibility */
.skip-link {
  position: absolute;
  top: -40px;
  left: 0;
  background: var(--primary-color);
  color: white;
  padding: 8px;
  z-index: 9999;
}

.skip-link:focus {
  top: 0;
}
