/* ==========================================================================
   1. Font Imports
   ========================================================================== */
@import url("https://fonts.googleapis.com/css2?family=Montserrat:wght@300;400;500;600;700&display=swap");

/* ==========================================================================
                  2. Reset and Base Variables
                  ========================================================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --primary-red: var(--color-secondary, #dc0a17);
  --secondary-red: #8b0000;
  --dark-blue: var(--color-text-primary, #2c3e50);
  --light-gray: var(--color-ui-hover, #f8f9fa);
  --text-dark: var(--color-text-primary, #1a1a1a);
  --text-body: var(--color-text-secondary, #505050);
}

/* ==========================================================================
                  3. Base HTML & Body Styles
                  ========================================================================== */
html {
  overflow-x: hidden;
  width: 100%;
  position: relative;
}

body {
  font-family: "Montserrat", sans-serif;
  line-height: 1.5;
  background-color: #ffffff;
  color: var(--dark-blue);
  overflow-x: hidden;
  width: 100%;
  position: relative;
}

.container {
  margin: 0 auto;
  /* /padding-top: 86px;/ */
  width: 100%;
  max-width: 100%;
  overflow-x: hidden;
  overflow-y: hidden;
}

/* ==========================================================================
                  4. Carousel Components
                  ========================================================================== */
/* Updated Carousel Styles with SOLIZE Theme */
/* Carousel Title */
.carousel-title {
  text-align: left;
  color: var(--primary-red);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 700;
  margin: 0 0 2rem 2rem; /* Adjusted margin for left alignment */
  text-transform: uppercase;
  padding: 0;
}

/* Carousel Container */
.carousels {
  position: relative;
  /*height: 500px;*/
  width: 100%;
  overflow: hidden;
  margin: 0;
  border-radius: 0;
}

/* Carousel Slide Content */
.carousel-content {
  position: absolute;
  bottom: 17%; /* Positioned above the navigation dots */
  left: 10%;
  right: 40px;
  color: #fff;
  z-index: 5;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.carousel-slide-title {
  font-size: 35px;
  font-weight: 700;
  margin-bottom: 1rem;
  line-height: 1.5;
  width: 30%;

  letter-spacing: -0.2%;
}

.carousel-slide-description {
  font-size: 18px;
  width: 30%;
  line-height: 150% !important;
  font-weight: 500;
  /* /line-height: 100%;/ */
  max-width: 600px;
  letter-spacing: -0.2%;
}

.carousel-button-container {
  margin-top: 1.5rem;
}

.carousel-button {
  display: inline-block;
  padding: 0.8rem 2rem;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  color: #fff;
  border-radius: 4px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.carousel-button:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

@media (max-width: 768px) {
  .carousels-control {
    opacity: 0;
  }
  .carousel-button {
    padding: 0.6rem 1.5rem;
    font-size: 0.9rem;
  }
}

/* Responsive adjustments */
@media (max-width: 768px) {
  /* .container { */
  /*  padding-top: 57px;*/
  /* } */
}
@media (max-width: 768px) {
  .carousel-content {
    left: 20px;
    right: 20px;
    bottom: 60px;
  }

  .carousel-slide-title {
    font-size: 1.5rem;
  }

  .carousel-slide-description {
    font-size: 1rem;
  }
}

.carousels-inner {
  height: 100%;
  width: 100%;
  display: flex;
  transition: transform 0.7s cubic-bezier(0.4, 0, 0.2, 1);
  margin-top: 0;
}

.carousels-item {
  min-width: 100%;
  height: 100%;
  position: relative;
  overflow: hidden;
}

/* ==========================================================================
                  5. Carousel Overlays
                  ========================================================================== */
/* Left diagonal overlay */
.diagonal-overlay-left {
  position: absolute;
  top: 0;
  left: 0;
  width: 55%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-left-rgb, 145, 18, 0),
    var(--carousel-overlay-left-opacity, 0.898)
  );
  clip-path: polygon(0 0, 45% -36%, 76% 100%, 0 100%);
  z-index: 2;
}

/* Right diagonal overlay */
.diagonal-overlay-right-1 {
  position: absolute;
  top: 0;
  right: 0;
  width: 60%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-right-rgb, 145, 18, 0),
    var(--carousel-overlay-right-opacity, 0.598)
  );
  clip-path: polygon(15% 0, 100% 0, 100% 74%, 0 -231%);
}

/* Second right diagonal layer */
.diagonal-overlay-right-2 {
  position: absolute;
  top: 0;
  right: 0;
  width: 55%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-right-rgb, 145, 18, 0),
    var(--carousel-overlay-right-opacity, 0.598)
  );
  clip-path: polygon(20% 0, 100% 0, 101% 105%, 36% -77%);
  z-index: 3;
}

.carousels-item::after {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  /* background: linear-gradient(90deg, rgba(139, 0, 0, 0.7) 0%, rgba(139, 0, 0, 0.4) 50%, rgba(139, 0, 0, 0) 100%); */
}

.carousels-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: all 0.3s ease;
}

/* ==========================================================================
                  6. Carousel Controls
                  ========================================================================== */
/* Carousel Controls with SOLIZE Theme */
.carousels-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: var(--carousel-control-bg, rgba(255, 255, 255, 0.95));
  color: #0d6a40;
  width: 50px;
  height: 50px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  transition: all 0.3s ease;
  z-index: 10;
}

.carousels-prev {
  left: 40px;
}

.carousels-next {
  right: 40px;
}

/* ==========================================================================
                  7. Main Content Styles
                  ========================================================================== */
/* Content Styles with SOLIZE Theme */
.content {
  background: #ffffff;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.5rem 1.5rem;
}

h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  color: var(--primary-red);
  margin-bottom: 1.5rem;
  line-height: 1.2;
  text-transform: uppercase;
}

.content p {
  font-size: clamp(1rem, 2vw, 1.1rem);
  color: var(--text-body);
  margin-bottom: 0.5rem;
  line-height: 1.6;
  font-weight: 400;
}

/* ==========================================================================
                  8. Split Section Components
                  ========================================================================== */
/* Split Section Styles */
/* Base styles for split sections */
.image-row {
  display: flex;
  flex-direction: column;
  gap: 2rem; /* Reduced the gap */
  padding: 2rem 0;
  margin: 0;
}

.split-section {
  display: grid;
  grid-template-columns: 42% 59%; /* Adjusted to bring content and image closer */
  padding: 4rem max(2rem, calc((100% - 1200px) / 2));
  align-items: center; /* Align items vertically */
}

/* Zig-zag pattern: every even section has reversed order */
.split-section:nth-child(even) {
  direction: rtl; /* Reverses the grid items order */
}

/* Ensure content remains left-to-right */
.split-section:nth-child(even) .split-image-container,
.split-section:nth-child(even) .split-content {
  direction: ltr;
}

.split-section:nth-child(even) .split-image-container {
  margin: 0;
}

.split-image-container {
  width: 90%; /* Adjusted width */
  display: flex;
  justify-content: center;
  flex-direction: column;
  gap: 1rem; /* Reduced gap */
  height: 100%;
  margin: 0;
}

.image-main-title {
  color: #333;
  padding: 0.5rem 0;
  margin: 0;
}

.split-image {
  aspect-ratio: 5/4;
  overflow: hidden;
  border-radius: 8px;
  position: relative;
}

.split-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.split-image:hover img {
  transform: scale(1.05);
}

.split-content {
  margin-top: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  height: 100%;
  padding: 2rem 2rem 2rem 0.5rem;
  overflow: hidden;
}

.split-content h2 {
  font-size: var(--split-content-h2-font-size, 28px);
  font-weight: var(--split-content-h2-font-weight, 500);
  margin-bottom: var(--split-content-h2-margin-bottom, 1rem);
  margin-top: var(--split-content-h2-margin-top, 0);
  color: var(--split-content-h2-color, #dc0a17);
  line-height: var(--split-content-h2-line-height, 1.3);
  /*text-transform: uppercase;*/
}

.content-text {
  margin-bottom: 1.5rem; /* Reduced margin */
  flex-grow: 1;
  overflow: hidden;
}

/* Responsive Design: Adjust layout on smaller screens */
@media (max-width: 768px) {
  .split-section,
  .split-section:nth-child(even) {
    grid-template-columns: 1fr;
    direction: ltr;
    gap: 2rem; /* Reduce gap further for mobile */
    padding: 2rem max(1rem, calc((100% - 600px) / 2));
  }

  .split-content {
    padding: 1.5rem 1rem 1.5rem 1rem;
    margin-top: 0;
  }

  .split-image-container,
  .split-section:nth-child(even) .split-image-container {
    width: 100%;
    margin: 0 auto;
  }
}

/* ==========================================================================
                  9. Alert Banner
                  ========================================================================== */
/* Alert Banner with SOLIZE Theme */
.alert-banner {
  width: 100%;
  color: white;
  padding: 25px 0;
  overflow: hidden;
  position: relative;
  margin-top: 2rem;
}

/* ==========================================================================
                  10. Single Content Components
                  ========================================================================== */
/* Single Content Styles */
.single-content {
  margin-top: 2rem;
  /*margin-bottom: 5%;*/
  width: 100%;
}

.single-content h2 {
  text-align: center;
  font-size: 32px;
  font-weight: 500;
  margin-bottom: 1rem;
  color: #dc0a17;
  /*text-transform: uppercase;*/
}

@media (max-width: 992px) {
  .single-content h2 {
    font-size: 24px;
  }
}

@media (max-width: 768px) {
  .single-content h2 {
    font-size: 22px;
    margin-bottom: 0.75rem;
  }
}

@media (max-width: 576px) {
  .single-content h2 {
    font-size: 20px;
    margin-bottom: 0.5rem;
  }
}

/* ==========================================================================
                  11. Button Components
                  ========================================================================== */
/* Button Styles with SOLIZE Theme */
.custom-button {
  display: inline-block;
  padding: 0.8rem 2rem;
  font-size: 1rem;
  font-weight: 500;
  text-decoration: none;
  color: #fff;
  background-color: var(--primary-red);
  border-radius: 4px;
  transition: all 0.3s ease;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.button-container {
  margin-top: auto;
  padding-top: 1.5rem;
  text-align: center;
}

.custom-button:hover {
  transform: translateY(-2px);
  background-color: var(--secondary-red);
}

/* ==========================================================================
                  12. Navigation Dots
                  ========================================================================== */
/* Navigation Dots with SOLIZE Theme */
.carousel-nav {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 10px;
  z-index: 10;
}

.carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background-color: var(--carousel-dot-inactive, rgba(255, 255, 255, 0.5));
  border: 2px solid
    var(--carousel-dot-inactive-border, rgba(255, 255, 255, 0.8));
  cursor: pointer;
  transition: all 0.3s ease;
  padding: 0;
}

.carousel-dot.active {
  background-color: var(--carousel-dot-active, #e51937);
  border-color: var(--carousel-dot-active-border, #ffffff);
  transform: scale(1.3);
}

/* ==========================================================================
                  13. Responsive Design
                  ========================================================================== */
/* Keep existing responsive design with minor adjustments */
@media (max-width: 1024px) {
  .split-section {
    padding: 2rem max(2rem, 5%);
  }

  .carousels {
    height: 70vh;
  }
}

@media (max-width: 768px) {
  .split-section {
    margin-bottom: 10%;
    margin-top: 10%;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    padding: 0.5rem !important;
  }

  .carousels {
    height: 200px;
    width: 100%;
  }
}

@media (max-width: 575px) {
  /* .carousels {
          height: 40vh;
        } */

  .split-image {
    height: min(300px, 40vh);
  }

  .custom-button {
    width: 100%;
  }
}

/* CSS CHANGES - Add to multiEdit.css */

/* ==========================================================================
   Content-Proportional Text Component Styling
   ========================================================================== */

.text-content-dynamic {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
}

.text-content-dynamic .content {
  background: transparent;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 1.5rem;
}

/* Base content spacing - minimal for small content */
.text-content-dynamic.content-minimal {
  padding: 20px 0;
}

/* Medium content gets moderate spacing */
.text-content-dynamic.content-medium {
  padding: 30px 0;
}

/* Large content gets more breathing room */
.text-content-dynamic.content-large {
  padding: 40px 0;
}

/* Add more vertical space when titles are present */
.text-content-dynamic.has-title {
  padding-top: 30px;
}

/* Centering and spacing for single content */
.text-content-dynamic .single-content {
  width: 100%;
  text-align: center;
}

.text-content-dynamic .single-content h2 {
  margin-bottom: 1.5rem;
}

.text-content-dynamic .content-text {
  margin-bottom: 1rem;
}

/* Ensure the last element doesn't have bottom margin */
.text-content-dynamic .content-text > *:last-child {
  margin-bottom: 0;
}

/* Split section styling */
.text-content-dynamic .split-section {
  display: grid;
  grid-template-columns: 42% 59%;
  gap: 2rem;
  align-items: center;
}

/* Responsive adjustments */
@media (max-width: 992px) {
  .text-content-dynamic.content-minimal {
    padding: 15px 0;
  }

  .text-content-dynamic.content-medium {
    padding: 25px 0;
  }

  .text-content-dynamic.content-large {
    padding: 35px 0;
  }
}

@media (max-width: 768px) {
  .text-content-dynamic.content-minimal {
    padding: 12px 0;
  }

  .text-content-dynamic.content-medium {
    padding: 20px 0;
  }

  .text-content-dynamic.content-large {
    padding: 25px 0;
  }

  .text-content-dynamic .content {
    padding: 0 1rem;
  }

  .text-content-dynamic .split-section {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
}

/* ==========================================================================
   Card Gallery with Min-Height and Centered Content
   ========================================================================== */

/* Enhanced Card Gallery with minimum height of 600px */
.card-gallery-enhanced {
  min-height: 600px; /* Set minimum height */
  height: auto; /* Allow expansion based on content */
  display: flex;
  flex-direction: column;
  padding: 30px 0;
  width: 100%;
  justify-content: center; /* Center content vertically */
}

.card-gallery-enhanced .card-gallery {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center; /* Center content vertically */
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

/* Allow gallery container to grow but keep centered */
.card-gallery-enhanced .card-gallery-container {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* 3 columns on desktop */
  gap: 30px;
  margin-bottom: 2rem;
  align-items: center; /* Align items center within the grid */
  width: 100%;
}

/* When content is shorter than min-height (600px) */
.card-gallery-enhanced.short-content {
  justify-content: center;
}

/* When content is taller than min-height (600px) */
.card-gallery-enhanced.tall-content {
  justify-content: flex-start;
  height: auto;
}

/* Card item styling */
.card-gallery-enhanced .card-item {
  height: 100%;
  display: flex;
  margin-bottom: 15px;
}

.card-gallery-enhanced .card-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  width: 100%;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

/* Standardize image height */
.card-gallery-enhanced .card-image {
  height: 220px;
  width: 100%;
}

.card-gallery-enhanced .card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Content area takes remaining space */
.card-gallery-enhanced .card-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 20px;
}

.card-gallery-enhanced .card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 15px;
}

.card-gallery-enhanced .card-description {
  font-size: 1rem;
  color: #505050;
  margin-bottom: 15px;
  line-height: 1.6;
  flex: 1;
}

.card-gallery-enhanced .card-link {
  margin-top: auto;
  align-self: flex-start;
}

/* Adjust gallery title spacing */
.card-gallery-enhanced .card-gallery-title {
  margin-bottom: 30px;
  text-align: center;
}

/* Position pagination at bottom */
.card-gallery-enhanced .card-gallery-pagination {
  margin-top: 20px;
  padding-bottom: 20px;
  display: flex;
  justify-content: center;
}

/* Large desktop screens */
@media (min-width: 1440px) {
  .card-gallery-enhanced .card-gallery-container {
    grid-template-columns: repeat(3, 1fr); /* 4 columns on very large screens */
  }
}

/* Medium desktop and tablet landscape */
@media (max-width: 1200px) and (min-width: 993px) {
  .card-gallery-enhanced .card-gallery-container {
    grid-template-columns: repeat(3, 1fr); /* 3 columns on standard desktop */
  }
}

/* Tablet portrait */
@media (max-width: 992px) {
  .card-gallery-enhanced {
    min-height: 600px; /* Maintain minimum height on tablets */
  }

  .card-gallery-enhanced .card-gallery-container {
    grid-template-columns: repeat(2, 1fr); /* 2 columns on tablet */
  }
}

/* Mobile landscape */
@media (max-width: 768px) {
  .card-gallery-enhanced {
    min-height: 550px;
  }

  .card-gallery-enhanced .card-gallery-title {
    font-size: 1.75rem;
    margin-bottom: 25px;
  }

  .card-gallery-enhanced .card-gallery-container {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }
}

/* Mobile portrait */
@media (max-width: 576px) {
  .card-gallery-enhanced {
    min-height: 500px;
  }

  .card-gallery-enhanced .card-gallery-container {
    grid-template-columns: 1fr; /* 1 column on small mobile */
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
  }

  .card-gallery-enhanced .card-image {
    height: 180px;
  }
}

/* JavaScript to help with content adjustment */
.card-gallery-enhanced .card-gallery-container.flex-centered {
  align-content: center;
  justify-content: center;
}

/* Hide cards for pagination */
.card-item.hidden {
  display: none !important;
}

/* MAIN CARD GALLERY STYLES - FIXED FOR CENTERING */
.card-link-wrapper {
  text-decoration: none;
  color: inherit;
  display: block;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-gallery-component {
  width: 100%;
  padding: 50px 0 70px 0;
  min-height: 600px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.card-gallery-title {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  color: #dc0a17;
  margin-bottom: 2.5rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.card-gallery {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  padding: 1px 1rem;
}

/* FIXED: Better grid layout for centering */
.card-gallery-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 30px;
  margin-bottom: 2rem;
  max-width: 1200px; /* Constrain max width */
  margin-left: auto;
  margin-right: auto;
}

/* Alternative grid approach - use this if you prefer grid */
.card-gallery-container.use-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 356px));
  justify-content: center;
  gap: 30px;
  margin-bottom: 2rem;
}

/* Card specific sizing */
.card-item {
  width: 356px;
  transition: opacity 0.3s ease, transform 0.3s ease;
  flex-shrink: 0; /* Prevent cards from shrinking */
}

.card-inner {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-inner:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.card-image {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card-inner:hover .card-image img {
  transform: scale(1.05);
}

.card-content {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 10px;
}

.card-description {
  font-size: 1rem;
  color: #505050;
  margin-bottom: 15px;
  line-height: 1.6;
  flex: 1;
}

.card-link-text {
  display: inline-block;
  color: #dc0a17;
  text-decoration: none;
  font-weight: 500;
  margin-top: auto;
  position: relative;
  padding-bottom: 2px;
}

.card-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #dc0a17;
  transition: width 0.3s ease;
}

.card-link:hover::after {
  width: 100%;
}

/* Pagination Styles */
.card-gallery-pagination {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.pagination-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
}

.page-indicators {
  display: flex;
  gap: 8px;
}

.prev-page,
.next-page,
.page-indicator {
  padding: 8px 15px;
  border: none;
  background-color: #f0f0f0;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.prev-page,
.next-page {
  background-color: #e0e0e0;
  font-weight: 500;
}

.page-indicator {
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-indicator.active {
  background-color: #dc0a17;
  color: white;
}

.prev-page:hover,
.next-page:hover,
.page-indicator:hover:not(.active) {
  background-color: #d0d0d0;
}

.prev-page:disabled,
.next-page:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Responsive Adjustments */

/* Large screens */
@media (min-width: 1200px) {
  .card-gallery-container {
    max-width: 1200px;
  }

  .card-item {
    width: 356px; /* Original size for large screens */
  }
}

/* Medium-large screens (like 1024px) */
@media (max-width: 1199px) and (min-width: 993px) {
  .card-gallery-container {
    max-width: 950px;
    gap: 20px; /* Reduce gap slightly */
  }

  .card-item {
    width: 300px; /* Reduce card width for better fit */
  }
}

@media (max-width: 992px) {
  .card-gallery-container {
    max-width: 800px; /* Adjust max width for tablets */
    gap: 25px;
  }

  .card-item {
    width: calc(50% - 12.5px); /* Two cards per row */
    min-width: 280px;
    max-width: 350px;
  }
}

@media (max-width: 768px) {
  .card-gallery-title {
    font-size: 1.75rem;
    margin-bottom: 2rem;
  }

  .card-gallery-component {
    min-height: 600px;
    padding: 40px 0 50px 0;
  }

  .card-gallery-container {
    gap: 20px;
  }
}

@media (max-width: 576px) {
  .card-gallery-container {
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
  }

  .card-item {
    width: 100%; /* One card per row on mobile */
  }

  .pagination-nav {
    flex-wrap: wrap;
  }
}

/* ==========================================================================
               14. Rich Text Content Styles
                  ========================================================================== */
.content-text h2 {
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin-bottom: 1.5rem;
  font-weight: 700;
  line-height: 1.3;
}

.content-text p {
  font-size: clamp(1rem, 2vw, 1.1rem);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.content-text a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
  transition: opacity 0.3s ease;
}

.content-text a:hover {
  opacity: 0.8;
}

/* ==========================================================================
                  15. Text Alignment Classes
                  ========================================================================== */
/* Quill Editor Alignment Classes */
.ql-align-center,
.content-text .ql-align-center {
  text-align: center !important;
}

.ql-align-justify,
.content-text .ql-align-justify {
  text-align: justify !important;
}

.ql-align-right,
.content-text .ql-align-right {
  text-align: right !important;
}

/* Color and Font Weight
            
            /* ==========================================================================
               16. Content Typography Styles
               ========================================================================== */
/* Color and Font Weight Preservation */
.content-text strong {
  font-weight: 700;
}

.content-text [style*="color:"] {
  color: var(--custom-color, inherit);
}

/* Spacing for Text Blocks */
.single-content .content-text {
  /* max-width: 800px; */
  margin: 0 auto;
  padding: 0 1rem;
}

.single-content .content-text > *:first-child {
  margin-top: 0;
}

.single-content .content-text > *:last-child {
  margin-bottom: 0;
}

/* Link Styles Within Content */
.content-text a[target="_blank"] {
  padding-right: 1.5em;
  position: relative;
}

.content-text a[target="_blank"]::after {
  content: "↗";
  position: absolute;
  right: 0.3em;
  top: 0;
  font-size: 0.8em;
}

/* ==========================================================================
            17. Image Section Styles
            ========================================================================== */
/* Image Section Base */

/* Simple View Styles */
.image-simple-grid {
  display: grid;
  gap: 2.5rem;
  margin: 0 auto;
  max-width: 1200px;
  width: 100%;
  padding: 1rem 0;
}

.image-simple-grid.single {
  grid-template-columns: minmax(0, 800px);
  justify-content: center;
}

.image-simple-grid.double {
  grid-template-columns: repeat(2, 1fr);
}

.image-simple-grid.triple {
  grid-template-columns: repeat(3, 1fr);
}

.image-simple-grid.quad {
  grid-template-columns: repeat(4, max-content);
  gap: 0.5rem;
  margin: 0 auto;
  justify-content: center;
}
.image-simple-grid.quad .image-simple-media {
  width: 100%;
  height: 280px;
  /* margin-bottom: 0.4rem;  */
}

.image-simple-grid.quad .image-simple-media img {
  width: 100%;
  height: 100%;
  /* object-fit: cover; */
}

.image-simple-grid.quad .image-simple-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  height: auto; /* Changed from 100% */
  position: relative;
}

.image-simple-grid.quad .image-simple-content {
  flex: none; /* Don't expand unnecessarily */
}

.image-simple-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.image-simple-media {
  width: 150px;
  height: 150px;
  margin-bottom: 1.5rem;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.image-simple-media img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.image-simple-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.image-simple-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #dc0a17;
  margin-bottom: 1rem;
  /*text-transform: uppercase;*/
}

.image-simple-description {
  font-size: 1rem;
  line-height: 1.6;
  color: #505050;
  margin-bottom: 4.5rem;
}

.image-simple-button-container {
  margin-top: 1rem;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  .image-simple-grid.quad {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .image-simple-grid.triple {
    grid-template-columns: repeat(2, 1fr);
  }

  .image-simple-media {
    width: 130px;
    height: 130px;
  }
}

@media (max-width: 768px) {
  .image-simple-grid.double,
  .image-simple-grid.triple,
  .image-simple-grid.quad {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
  }

  .image-simple-title {
    font-size: 1.3rem;
  }
}

.image-section {
  width: 100%;
  max-width: 1280px;
  padding: 2rem 2rem;
  margin: 0 auto;
  padding-bottom: 4%;
  padding-top: 4%;
}

.image-section-title {
  margin-top: -66px;
  color: #dc0a17;
  text-align: center;
  font-size: 28px;
  font-weight: 500;
  margin-bottom: 3rem;
  /*text-transform: uppercase;*/
  letter-spacing: 1px;
}

/* Grid Layout System */
.image-grid {
  display: grid;
  gap: 2rem;
  margin: 0 auto;
  max-width: 1200px;
  width: 100%;
  justify-content: center;
}

.image-grid.single {
  grid-template-columns: minmax(0, 800px);
  justify-content: center;
}

.image-grid.double {
  grid-template-columns: repeat(2, 1fr);
}

.image-grid.triple {
  grid-template-columns: repeat(3, 1fr);
}

.image-grid.quad {
  grid-template-columns: repeat(4, 1fr);
}

/* Image Item Styling */
.image-item {
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.image-item-media {
  width: 100%;
  aspect-ratio: 16/10;
  position: relative;
  overflow: hidden;
}

.image-item-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.image-item:hover .image-item-media img {
  transform: scale(1.05);
}

.image-item-media::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #c20716;
  opacity: 0.5;
  z-index: 1;
  transition: opacity 0.3s ease;
}

/* Remove overlay on hover to show actual image */
.image-item-media:hover::before {
  opacity: 0;
}

/* Optional: Add a subtle zoom effect on hover */
.image-item-media:hover img {
  transform: scale(1.05);
}

/* Ensure the overlay is properly positioned */
.image-item-media {
  display: block;
  position: relative;
}

/* Content Styling */
.image-content {
  margin-top: -25px;
  padding: 2rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
  flex: 1;
}

/* Title and description container */
.content-text {
  text-align: justify;
  display: flex;
  flex-direction: column;
  margin-bottom: auto;
}

/* Theme Variations */
.image-item.engineering .image-content {
  background-color: #cc0000;
  color: #ffffff;
}

.image-item.software .image-content,
.image-item.digital .image-content {
  background-color: #f5f5f5;
  color: #1a1a1a;
}

/* Typography */
.image-title {
  margin-top: 0;
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Button wrapper to ensure consistent positioning */
.button-wrapper {
  margin-top: auto;
}

.image-description {
  font-size: 1rem;
  line-height: 1.5;
}

/* Button styling */
.image-button-container {
  margin-top: 1.5rem;
  width: 100%;
}

.custom-button {
  display: inline-block;
  padding: 0.75rem 3.5rem;
  border-radius: 25px;
  color: white;
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s ease;
}

.custom-button:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

/* Color Overlays */
.image-item-media::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.image-item.engineering .image-item-media::after {
  background: linear-gradient(0deg, rgba(0, 0, 139, 0.2), rgba(0, 0, 139, 0.1));
}

.image-item.software .image-item-media::after {
  background: linear-gradient(
    0deg,
    rgba(220, 10, 23, 0.2),
    rgba(220, 10, 23, 0.1)
  );
}

.image-item.digital .image-item-media::after {
  background: linear-gradient(
    0deg,
    rgba(128, 0, 128, 0.2),
    rgba(128, 0, 128, 0.1)
  );
}

/* Error State */
.error-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background-color: #f8f9fa;
  color: #6c757d;
  gap: 0.5rem;
  padding: 1rem;
}

.error-placeholder i {
  font-size: 2rem;
  opacity: 0.5;
}

/* Responsive Adjustments */
@media (max-width: 1200px) {
  .image-grid.quad {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .image-grid.triple {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .image-grid.double,
  .image-grid.triple,
  .image-grid.quad {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
  }

  .image-section {
    padding: 1rem 1rem;
    padding-bottom: 10%;
    padding-top: 10%;
  }

  .image-section-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
  }
}

@media (max-width: 480px) {
  .image-content {
    padding: 1.5rem;
    min-height: 140px;
  }
}
/* Add these styles to your existing CSS file */

/* Position relative for proper overlay positioning */
.image-simple-media {
  width: 250px; /* or another size that fits your design */
  height: 250px; /* or another size that fits your design */
  margin-bottom: 1.5rem;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Add overlay to simple view images */
.image-simple-media::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* This will be overridden by inline styles background-color: #c20716; */
  /* This will be overridden by inline styles opacity: 0.5; */
  z-index: 1;
  transition: opacity 0.3s ease;
}

/* Add hover effect to remove overlay */
.image-simple-media:hover::before {
  opacity: 0;
}

/* Add transition to images for smooth zoom */
.image-simple-media img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  transition: transform 0.3s ease;
}

/* Add zoom effect on hover */
.image-simple-media:hover img {
  transform: scale(1.05);
}

/* Button hover effect for simple view */
.image-simple-button-container .custom-button:hover {
  opacity: 0.9;
  transform: translateY(-2px);
}

/* ==========================================================================
         18. Header Image Component
         ========================================================================== */

.header-image-container {
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  position: relative;
}

.header-image-wrapper {
  position: relative;
  width: 100%;
  height: auto;
}

.header-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  max-height: 400px;
}

.header-text-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.header-text-content {
  padding: 20px;
  max-width: 80%;
}

.header-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
  text-transform: capitalize;
  letter-spacing: 1px;
}

.header-subtitle {
  font-size: 1.2rem;
  margin-bottom: 0;
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .header-image {
    max-height: 350px;
  }
}

@media (max-width: 768px) {
  .header-title {
    font-size: 1.8rem;
  }

  .header-subtitle {
    font-size: 1rem;
  }

  .header-text-content {
    max-width: 95%;
  }

  .header-image {
    max-height: 300px;
  }
}

@media (max-width: 575px) {
  .header-title {
    font-size: 1.4rem;
  }

  .header-subtitle {
    font-size: 0.9rem;
  }

  .header-image {
    max-height: 250px;
  }
}

/* ==========================================================================
          Header Image Component OVERLAY
         ========================================================================== */

/* Left diagonal overlay */
.diagonal-overlay-left-header {
  position: absolute;
  top: 0;
  left: 0;
  width: 55%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-left-rgb, 145, 18, 0),
    var(--carousel-overlay-left-opacity, 0.898)
  );
  clip-path: polygon(0 0, 45% -36%, 76% 100%, 0 100%);
  z-index: 2;
}

/* Right diagonal overlay */
.diagonal-overlay-right-1-header {
  position: absolute;
  top: 0;
  right: 0;
  width: 60%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-right-rgb, 145, 18, 0),
    var(--carousel-overlay-right-opacity, 0.598)
  );
  clip-path: polygon(15% 0, 100% 0, 100% 74%, 0 -231%);
}

/* Second right diagonal layer */
.diagonal-overlay-right-2-header {
  position: absolute;
  top: 0;
  right: 0;
  width: 55%;
  height: 100%;
  background-color: rgba(
    var(--carousel-overlay-right-rgb, 145, 18, 0),
    var(--carousel-overlay-right-opacity, 0.598)
  );
  clip-path: polygon(20% 0, 100% 0, 101% 105%, 36% -77%);
  z-index: 3;
}

/* ===========================================================================
              Card Gallery Component Styles 
========================================================== */
.card-link-wrapper {
  height: 100%;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-gallery-component {
  width: 100%;
  padding: 50px 0 0px 0; /* Increased vertical padding to make the component taller */
  min-height: 600px; /* Set a minimum height for the component */
  display: flex;
  flex-direction: column;
  justify-content: center; /* Vertically center the content */
  align-items: center;
}

.card-gallery-title {
  text-align: center;
  font-size: 32px;
  font-weight: 500;
  color: #dc0a17;
  margin-bottom: 2.5rem;
  text-transform: capitalize;
  letter-spacing: 1px;
}

.card-gallery {
  position: relative;
  max-width: 1280px;
  margin: 0 auto;
  padding: 1px 1rem;
}

.card-gallery-container {
  display: grid;
  grid-template-columns: repeat(auto-fit, 356px);
  gap: 30px;
  margin-bottom: 2rem;
  justify-content: center;
}

.card-item {
  width: 356px;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.card-inner {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  height: 100%;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-inner:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.card-image {
  position: relative;
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.card-inner:hover .card-image img {
  transform: scale(1.05);
}

.card-content {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #2c3e50;
  margin-bottom: 10px;
}

.card-description {
  font-size: 1rem;
  color: #505050;
  margin-bottom: 15px;
  line-height: 1.6;
  flex: 1;
}

.card-link-text {
  display: inline-block;
  color: #dc0a17;
  text-decoration: none;
  font-weight: 500;
  margin-top: auto;
  position: relative;
  padding-bottom: 2px;
}
.card-link::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: #dc0a17;
  transition: width 0.3s ease;
}

.card-link:hover::after {
  width: 100%;
}

/* Pagination Styles */
.card-gallery-pagination {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.pagination-nav {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
}

.page-indicators {
  display: flex;
  gap: 8px;
}

.prev-page,
.next-page,
.page-indicator {
  padding: 8px 15px;
  border: none;
  background-color: #f0f0f0;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.prev-page,
.next-page {
  background-color: #e0e0e0;
  font-weight: 500;
}

.page-indicator {
  min-width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.page-indicator.active {
  background-color: #dc0a17;
  color: white;
}

.prev-page:hover,
.next-page:hover,
.page-indicator:hover:not(.active) {
  background-color: #d0d0d0;
}

.prev-page:disabled,
.next-page:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Responsive Adjustments */
@media (max-width: 992px) {
  .card-gallery-container {
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  }
}

@media (max-width: 768px) {
  .card-gallery-title {
    font-size: 20px;
    margin-bottom: 2rem;
  }

  .card-gallery-component {
    min-height: 600px; /* Smaller minimum height on mobile */
    padding: 40px 0 50px 0;
  }
}

@media (max-width: 576px) {
  .card-gallery-container {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
  }

  .pagination-nav {
    flex-wrap: wrap;
  }
}

/* ==========================================================================
               22. Split Content Additional Styles
               ========================================================================== */

.split-content .button-container {
  margin-top: auto;
  padding-top: 1rem;
  text-align: left;
  flex-shrink: 0;
}

.split-content .custom-button {
  display: inline-block;
  padding: 0.8rem 2rem;
  font-size: 0.95rem;
  font-weight: 600;
  text-decoration: none;
  color: #fff;
  border-radius: 8px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  min-width: 160px;
  white-space: nowrap;
}

.split-content .custom-button:hover {
  transform: translateY(-2px);
  opacity: 0.9;
}

@media (max-width: 768px) {
  .split-content .button-container {
    text-align: center;
  }
}

/* .image-section-title {
           font-size: 2rem;
           margin-bottom: 3rem;
         } */

/* @media (max-width: 480px) {
        .image-content {
          margin-top: -4%;
          padding: 1.5rem;
          min-height: 140px;
        }
      } */

/* Add to multiEdit.css */
/*.split-content .button-container {*/
/*  margin-top: 2rem;*/
/*  padding-top: 0;*/
/*  text-align: left;*/
/*}*/

/*.split-content .custom-button {*/
/*  display: inline-block;*/
/*  padding: 0.8rem 2rem;*/
/*  font-size: 1rem;*/
/*  font-weight: 500;*/
/*  text-decoration: none;*/
/*  color: #fff;*/
/*  border-radius: 4px;*/
/*  transition: all 0.3s ease;*/
/*  text-transform: uppercase;*/
/*  letter-spacing: 0.5px;*/
/*  min-width: 160px;*/
/*}*/

/*.split-content .custom-button:hover {*/
/*  transform: translateY(-2px);*/
/*  opacity: 0.9;*/
/*}*/

/*@media (max-width: 768px) {*/
/*  .split-content .button-container {*/
/*    text-align: center;*/
/*  }*/
/*}*/

/* Video Section Base Styling */
.video-section {
  width: 100%;
  max-width: 1280px;
  margin: 4rem auto;
  padding: 0 2rem;
}

.video-section-title {
  color: #dc0a17;
  text-align: center;
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 4rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Video Grid Layout */
.video-grid {
  display: grid;
  gap: 2rem;
  width: 100%;
}

.video-grid.single {
  grid-template-columns: minmax(0, 800px);
  justify-content: center;
}

.video-grid.double {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.video-grid.triple {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.video-grid.quad {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

/* Video Item Styling */
.video-item {
  background: #ffffff;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  transition: transform 0.3s ease;
}

.video-item:hover {
  transform: translateY(-5px);
}

.video-content {
  display: flex;
  flex-direction: column;
}

/* Video Frame Container */
.video-frame {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 Aspect Ratio */
  background: #000;
}

.video-frame iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Video Text Content */
.video-title {
  font-size: 1.25rem;
  font-weight: 600;
  color: #2c3e50;
  margin: 1.5rem 1.5rem 1rem;
  line-height: 1.4;
}

.video-description {
  font-size: 1rem;
  color: #505050;
  margin: 0 1.5rem 1.5rem;
  line-height: 1.6;
}

/* Responsive Design */
@media (max-width: 1200px) {
  .video-grid.quad {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 992px) {
  .video-grid.triple,
  .video-grid.quad {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .video-section {
    margin: 3rem auto;
    padding: 0 1rem;
  }

  .video-section-title {
    font-size: 2rem;
    margin-bottom: 2rem;
  }

  .video-grid.double,
  .video-grid.triple,
  .video-grid.quad {
    grid-template-columns: 1fr;
    max-width: 600px;
    margin: 0 auto;
  }

  .video-title {
    font-size: 1.1rem;
    margin: 1.25rem 1.25rem 0.75rem;
  }

  .video-description {
    font-size: 0.95rem;
    margin: 0 1.25rem 1.25rem;
  }
}

/* =========================================================
                                Image slider css
  ============================================================== */

.slider-title {
  text-align: center;
  margin-bottom: 2rem;
  font-weight: 500;
  font-size: 2em;
  color: var(--primary-text-color, #ca0713);
}

.image-slider-section {
  width: 100%;
  padding: 55px 0;
  background: #fff;
}

.slider-container {
  position: relative;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 0 60px;
}

.slider-track {
  display: flex;
  gap: 20px;
  overflow: hidden;
  width: 100%;
  transition: transform 0.3s cubic-bezier(0.2, 0, 0.2, 1); /* Use optimized easing function */
  will-change: transform; /* Hint to browser for optimization */
}

.slide-thumbnail {
  height: 140px;
  border-radius: 8px;
  overflow: hidden;
  transition: all 0.3s ease;
  flex: 0 0 calc(25% - 15px);
}

/* Default for 4 or more slides */
/* .slide-thumbnail {
 flex: 0 0 calc(25% - 15px);
} */

/* Adjustments based on number of slides */
.slider-count-3 .slide-thumbnail {
  flex: 0 0 calc(33.33% - 15px);
}

.slider-count-2 .slide-thumbnail {
  flex: 0 0 calc(45% - 15px);
}

.slider-count-1 .slide-thumbnail {
  flex: 0 0 calc(70% - 15px);
}

.slide-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slide-thumbnail:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Navigation buttons */
.slider-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background: #dc0a17;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  transition: all 0.3s ease;
  z-index: 2;
}

.slider-nav:hover {
  background: #b00813;
}

.prev-btn {
  left: 0;
}

.next-btn {
  right: 0;
}

/* Responsive adjustments */
@media (max-width: 1200px) {
  .slide-thumbnail {
    height: 180px;
  }
}

@media (max-width: 992px) {
  .slide-thumbnail {
    height: 150px;
  }
}

@media (max-width: 768px) {
  .slider-track {
    display: flex;
    overflow: hidden;
    gap: 20px;
    transition: transform 0.4s ease-in-out; /* Smooth animation */
  }

  .slider-container {
    padding: 0 50px;
    gap: 15px;
  }

  .slide-thumbnail {
    height: 120px;
  }

  .slide-thumbnail img {
    height: 102%;
  }

  /* Responsive adjustments for different counts */
  .slider-count-3 .slide-thumbnail {
    flex: 0 0 calc(33.33% - 10px);
  }

  .slider-count-2 .slide-thumbnail {
    flex: 0 0 calc(45% - 10px);
  }

  .slider-count-1 .slide-thumbnail {
    flex: 0 0 calc(70% - 10px);
  }
}

@media (max-width: 576px) {
  /* .slider-container {
          padding: 0 40px;
          gap: 10px;
        }
      
        .slide-thumbnail {
          height: 100px;
        } */

  /* Responsive adjustments for different counts */
  .slider-count-3 .slide-thumbnail {
    flex: 0 0 calc(33.33% - 7px);
  }

  .slider-count-2 .slide-thumbnail {
    flex: 0 0 calc(45% - 7px);
  }

  .slider-count-1 .slide-thumbnail {
    flex: 0 0 calc(80% - 7px);
  }
}
@media (max-width: 576px) {
  .slider-container {
    padding: 0 20px;
    gap: 5px;
  }

  .slide-thumbnail {
    height: 193px;
    flex: 0 0 100%; /* Ensure only one slide is visible */
  }

  .slider-track {
    justify-content: flex-start; /* Ensure slides align properly */
  }
}

/* Simple View Styles */
.image-simple-grid {
  display: grid;
  gap: 2.5rem;
  margin: 0 auto;
  max-width: 1200px;
  width: 100%;
  padding: 1rem 0;
}

.image-simple-grid.single {
  grid-template-columns: minmax(0, 800px);
  justify-content: center;
}

.image-simple-grid.double {
  grid-template-columns: repeat(2, 1fr);
}

.image-simple-grid.triple {
  grid-template-columns: repeat(3, 1fr);
}

.image-simple-grid.quad {
  margin-bottom: -7%;
  grid-template-columns: repeat(4, 1fr);
}

.image-simple-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  height: 100%;
  position: relative;
  /* adding-bottom: 70px; */
}

.image-simple-media {
  width: 160px;
  height: 160px;
  margin-bottom: 1.5rem;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.image-simple-media img {
  max-width: 100%;
  max-height: 92% !important;
  object-fit: contain;
  margin-bottom: 3.5rem !important;
}

.image-simple-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex: 1;
  width: 100%;
}

.image-simple-title {
  font-size: 20px;
  font-weight: 600;
  color: #dc0a17;
  margin-bottom: 1rem;
  /*text-transform: uppercase;*/
}

.image-simple-description {
  font-size: 1rem;
  line-height: 1.6;
  color: #505050;
  /* margin-bottom: 1.5rem; */
}

.image-simple-button-container {
  position: absolute;
  bottom: 0;
  width: 100%;
  margin-top: 1.5rem;
  text-align: center;
}

/* Custom button styles */
.custom-button {
  display: inline-block;
  padding: 0.75rem 2rem;
  background-color: #dc0a17;
  color: white;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 600;
  transition: transform 0.3s ease;
  text-transform: uppercase;
}

.custom-button:hover {
  background-color: #b30813;
}

/* recent change for single image */
.image-simple-grid.single {
  grid-template-columns: 1fr;
  max-width: 1100px;
  margin: 0 auto;
}

.image-simple-grid.single .image-simple-media {
  width: 100%;
  height: auto;
  max-height: 630px;
  margin-bottom: 2rem;
  aspect-ratio: 1.75 / 1; /* 1100:630 aspect ratio */
}

.image-simple-grid.single .image-simple-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  max-width: 100%;
}

.image-simple-grid.single .image-simple-title {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 1.5rem;
}

.image-simple-grid.single .image-simple-description {
  font-size: clamp(1rem, 1.2vw, 1.2rem);
  max-width: 800px;
  margin: 0 auto 1.5rem auto;
  line-height: 1.6;
}
.image-simple-grid.double {
  display: grid;
  grid-template-columns: repeat(2, 500px);
  justify-content: center;
  gap: 5.5rem;
  max-width: 1100px;
  margin: 0 auto;
}

.image-simple-grid.double .image-simple-media {
  width: 100%;
  height: 300px;
  margin-bottom: 1.5rem;
}

/* Triple image layout - three 300x200 images */
.image-simple-grid.triple {
  margin-bottom: -9% !important;

  display: grid;
  grid-template-columns: repeat(3, 400px);
  gap: 1.5rem;
  max-width: 1100px;
  margin: 0 auto;
  justify-content: center;
}

.image-simple-grid.triple .image-simple-media {
  width: 100%;
  height: 200px;
  margin-bottom: 1.5rem;
}
/*  */

/* Responsive adjustments */
@media (max-width: 1200px) {
  .image-simple-grid.single .image-simple-media {
    height: auto;
    aspect-ratio: 1.75/1; /* Maintains 1100:630 ratio */
  }

  .image-simple-grid.double {
    grid-template-columns: repeat(2, minmax(300px, 500px));
    width: 90%;
  }

  .image-simple-grid.double .image-simple-media {
    height: auto;
    aspect-ratio: 5/3; /* Maintains 500:300 ratio */
  }

  .image-simple-grid.triple {
    grid-template-columns: repeat(3, minmax(250px, 300px));
    gap: 2rem;
    width: 90%;
  }

  .image-simple-grid.triple .image-simple-media {
    height: auto;
    aspect-ratio: 3/2; /* Maintains 300:200 ratio */
  }

  .image-simple-grid.quad {
    margin-bottom: -10%;
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 992px) {
  .image-simple-grid.triple {
    grid-template-columns: repeat(2, 300px);
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .image-simple-grid.double {
    grid-template-columns: 1fr;
    max-width: 500px;
  }

  .image-simple-grid.triple,
  .image-simple-grid.quad {
    grid-template-columns: 1fr;
    max-width: 500px;
  }

  .image-simple-title {
    font-size: 1.3rem;
  }
}

@media (max-width: 576px) {
  .image-simple-grid.single .image-simple-media {
    height: auto;
  }

  .image-simple-grid.single,
  .image-simple-grid.double,
  .image-simple-grid.triple,
  .image-simple-grid.quad {
    width: 95%;
    margin-bottom: -32%;
  }
}
/* ==========================================================================
   Clickable Image Slider Styles
   ========================================================================== */

/* Clickable slide link wrapper */
.slide-link {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
  text-decoration: none;
  transition: all 0.3s ease;
  border-radius: 8px;
  overflow: hidden;
}

.slide-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(220, 10, 23, 0.3);
}

/* Clickable image styling */
.slide-link img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: all 0.3s ease;
}

.slide-link:hover img {
  filter: brightness(1.1);
  transform: scale(1.02);
}

/* External link overlay icon */
.slide-overlay {
  position: absolute;
  top: 12px;
  right: 12px;
  background: rgba(220, 10, 23, 0.9);
  color: white;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: all 0.3s ease;
  pointer-events: none;
  font-size: 12px;
}

.slide-link:hover .slide-overlay {
  opacity: 1;
  transform: scale(1.1);
}

/* Ensure clickable images have proper cursor */
.slide-link {
  cursor: pointer;
}

/* Add subtle pulse animation to indicate interactivity */
@keyframes subtle-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(220, 10, 23, 0.4);
  }
  70% {
    box-shadow: 0 0 0 6px rgba(220, 10, 23, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(220, 10, 23, 0);
  }
}

.slide-link:focus {
  animation: subtle-pulse 1.5s infinite;
  outline: none;
}

/* Ensure non-clickable images maintain their existing hover effects */
.slide-thumbnail:not(:has(.slide-link)):hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Mobile responsive styles */
@media (max-width: 768px) {
  .slide-overlay {
    width: 28px;
    height: 28px;
    top: 8px;
    right: 8px;
    font-size: 10px;
  }

  .slide-link:hover {
    transform: translateY(-2px);
  }
}

@media (max-width: 576px) {
  .slide-overlay {
    width: 24px;
    height: 24px;
    top: 6px;
    right: 6px;
    font-size: 9px;
  }

  /* On mobile, show overlay slightly more prominently */
  .slide-overlay {
    opacity: 0.7;
  }

  .slide-link:hover .slide-overlay,
  .slide-link:active .slide-overlay {
    opacity: 1;
  }
}

/* Accessibility improvements */
.slide-link:focus-visible {
  outline: 2px solid #dc0a17;
  outline-offset: 2px;
}

/* Ensure overlay doesn't interfere with navigation on touch devices */
@media (hover: none) and (pointer: coarse) {
  .slide-overlay {
    opacity: 0.8;
  }
}

/* ==========================================================================
               23. User Reviews Component
               ========================================================================== */
.reviews-section {
  position: relative;
  width: 100%;
  max-width: 1280px;
  margin: 4rem auto;
  padding: 0 3.5rem; /* Increased padding to accommodate navigation buttons */
  overflow: hidden; /* Prevent cards from overflowing */
  padding-top: 2%;
  padding-bottom: 2%;
}

.reviews-section-title {
  text-align: center;
  font-size: 28px;
  font-weight: 500;
  color: #dc0a17;
  margin: 2rem;
  margin-bottom: 1rem;
  /*text-transform: uppercase;*/
  letter-spacing: 1px;
}

.reviews-slider {
  position: relative;
  width: 100%;
  padding: 1rem 0 3rem;
  overflow: visible; /* Allow nav buttons to be visible outside the container */
}

.reviews-container {
  display: flex;
  flex-wrap: nowrap;
  gap: 30px;
  transition: transform 0.5s ease;
  width: 100%;
  overflow: visible; /* Needed for proper navigation positioning */
}

.review-card {
  flex: 0 0 calc((100% - 60px) / 3); /* Default for 3 per view */
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 25px;
  transition: all 0.3s ease;
  height: 270px; /* Fixed height */
  display: flex;
  flex-direction: column;
}

.reviews-slider[data-slides-per-view="1"] .review-card {
  flex: 0 0 100%;
}

.reviews-slider[data-slides-per-view="2"] .review-card {
  flex: 0 0 calc((100% - 30px) / 2);
}

.review-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.review-content {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.reviewer-name {
  font-size: 1.25rem;
  font-weight: 600;
  color: #dc0a17;
  margin-bottom: 5px;
}

.review-title {
  font-size: 1rem;
  font-weight: 500;
  color: #2c3e50;
  margin-bottom: 10px;
}

.review-text-truncated {
  font-size: 0.95rem;
  color: #505050;
  line-height: 1.6;
  flex-grow: 1;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 5;
  -webkit-box-orient: vertical;
  position: relative;
}

.read-more-btn {
  align-self: flex-end;
  background: none;
  border: none;
  color: #dc0a17;
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
  padding: 5px 0;
  margin-top: 10px;
  transition: color 0.3s ease;
}

.read-more-btn:hover {
  color: #8b0000;
  text-decoration: underline;
}

.reviews-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  background: #fff;
  color: #dc0a17;
  border: none;
  border-radius: 50%;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 10; /* Ensure buttons are above cards */
  transition: all 0.3s ease;
}

.reviews-nav:hover {
  background: #dc0a17;
  color: #fff;
}

.reviews-nav.prev-review {
  left: -20px;
}

.reviews-nav.next-review {
  right: -20px;
}

/* Pause animation when modal is open */
body.modal-open .reviews-container {
  animation-play-state: paused !important;
}

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {
  .reviews-container {
    transition: none !important;
  }
}

/* Review Modal */
.review-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  overflow: auto;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.review-modal.show {
  opacity: 1;
}

.review-modal-content {
  background-color: #fff;
  margin: 10% auto;
  padding: 30px;
  border-radius: 8px;
  max-width: 600px;
  width: 90%;
  position: relative;
  transform: translateY(-20px);
  transition: transform 0.3s ease;
}

.review-modal.show .review-modal-content {
  transform: translateY(0);
}

.review-modal-close {
  position: absolute;
  top: 15px;
  right: 15px;
  color: #aaa;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}

.review-modal-close:hover {
  color: #dc0a17;
}

#modalReviewerName {
  color: #0d6a40;
  margin-bottom: 10px;
  font-size: 1.5rem;
}

#modalReviewTitle {
  color: #2c3e50;
  margin-bottom: 20px;
  font-size: 1.2rem;
  font-weight: 500;
}

#modalReviewText {
  color: #505050;
  line-height: 1.6;
  font-size: 1rem;
}

/* Responsive Styles */
@media (max-width: 992px) {
  .reviews-section {
    padding: 0 3rem;
  }

  .review-card {
    height: 280px;
  }

  /* Adjust for tablet view */
  .reviews-slider[data-slides-per-view="3"] .review-card {
    flex: 0 0 calc((100% - 30px) / 2);
  }
}

@media (max-width: 768px) {
  .reviews-section {
    padding: 0 2.5rem;
  }
  .reviews-section-title {
    font-size: 1.75rem;
    margin-bottom: 1rem;
  }

  .review-card {
    flex: 0 0 100% !important; /* Override all previous settings */
    height: 250px;
  }

  .reviews-nav {
    width: 35px;
    height: 35px;
  }

  .reviews-nav.prev-review {
    left: -15px;
  }

  .reviews-nav.next-review {
    right: -15px;
  }
}

@media (max-width: 576px) {
  .review-card {
    padding: 20px;
    height: 230px;
  }

  .reviewer-name {
    font-size: 1.1rem;
  }

  .review-title {
    font-size: 0.95rem;
  }

  .review-text-truncated {
    font-size: 0.9rem;
    -webkit-line-clamp: 4;
  }

  .review-modal-content {
    margin: 20% auto;
    padding: 20px;
  }

  #modalReviewerName {
    font-size: 1.3rem;
  }

  #modalReviewTitle {
    font-size: 1.1rem;
  }
}

/* ============================================
   TESTIMONIAL - DESIGNATION STYLING (Text Mode)
   ============================================ */
.reviewer-designation-text {
  font-size: 0.85rem;
  color: #666;
  margin-top: 5px;
  line-height: 1.4;
  font-style: italic;
}

/* Modal designation styling */
.modal-designation {
  font-size: 0.95rem;
  color: #666;
  margin-bottom: 15px;
  font-style: italic;
  line-height: 1.5;
}

/* ============================================
   TESTIMONIAL - IMAGE MODE (Flip Cards)
   ============================================ */
.reviews-image-mode .reviews-container {
  display: flex;
  flex-wrap: nowrap;
  gap: 30px;
}

/* Flip Card Container */
.review-flip-card {
  flex: 0 0 calc((100% - 60px) / 3);
  height: 380px;
  perspective: 1000px;
  cursor: pointer;
}

.reviews-image-mode[data-slides-per-view="1"] .review-flip-card {
  flex: 0 0 100%;
}

.reviews-image-mode[data-slides-per-view="2"] .review-flip-card {
  flex: 0 0 calc((100% - 30px) / 2);
}

/* Inner card that flips */
.flip-card-inner {
  position: relative;
  width: 100%;
  height: 100%;
  text-align: center;
  transition: transform 0.6s ease;
  transform-style: preserve-3d;
}

.review-flip-card:hover .flip-card-inner {
  transform: rotateY(180deg);
}

/* Front and Back faces */
.flip-card-front,
.flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 25px;
}

/* Front Face - Image + Name + Designation */
.flip-card-front {
  background: #fff;
  border: 1px solid #e8e8e8;
}

.reviewer-image-wrapper {
  width: 150px;
  height: 150px;
  border-radius: 8px;
  overflow: hidden;
  margin-bottom: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.reviewer-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.reviewer-image-placeholder {
  background: linear-gradient(135deg, #f5f5f5 0%, #e8e8e8 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.reviewer-image-placeholder i {
  font-size: 60px;
  color: #ccc;
}

.reviewer-name-image {
  font-size: 1.2rem;
  font-weight: 600;
  color: #1a7f64;
  margin: 0 0 8px 0;
  text-align: center;
}

.reviewer-designation {
  font-size: 0.9rem;
  color: #555;
  line-height: 1.5;
  text-align: center;
  margin: 0;
}

/* Back Face - Review Text */
.flip-card-back {
  background: linear-gradient(135deg, #f8faf9 0%, #e8f5f0 100%);
  transform: rotateY(180deg);
  padding: 30px 25px;
  justify-content: space-between;
}

.quote-icon {
  font-size: 3rem;
  color: #1a7f64;
  font-family: Georgia, serif;
  line-height: 1;
  opacity: 0.6;
}

.quote-open {
  align-self: flex-start;
}

.quote-close {
  align-self: flex-end;
}

.review-text-flip {
  font-size: 0.95rem;
  color: #333;
  line-height: 1.7;
  text-align: center;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 6;
  -webkit-box-orient: vertical;
  flex-grow: 1;
  display: flex;
  align-items: center;
}

.reviewer-name-back {
  font-size: 1rem;
  font-weight: 600;
  color: #1a7f64;
  margin: 10px 0 0 0;
}

/* ============================================
   IMAGE MODE - Responsive Styles
   ============================================ */
@media (max-width: 992px) {
  .review-flip-card {
    height: 350px;
  }

  .reviews-image-mode[data-slides-per-view="3"] .review-flip-card {
    flex: 0 0 calc((100% - 30px) / 2);
  }

  .reviewer-image-wrapper {
    width: 120px;
    height: 120px;
  }
}

@media (max-width: 768px) {
  .review-flip-card {
    flex: 0 0 100% !important;
    height: 320px;
  }

  .reviewer-image-wrapper {
    width: 100px;
    height: 100px;
  }

  .reviewer-name-image {
    font-size: 1.1rem;
  }

  .reviewer-designation {
    font-size: 0.85rem;
  }

  .quote-icon {
    font-size: 2.5rem;
  }

  .review-text-flip {
    font-size: 0.9rem;
    -webkit-line-clamp: 5;
  }
}

@media (max-width: 576px) {
  .review-flip-card {
    height: 300px;
  }

  .reviewer-image-wrapper {
    width: 80px;
    height: 80px;
    margin-bottom: 15px;
  }

  .reviewer-image-placeholder i {
    font-size: 40px;
  }

  .flip-card-front,
  .flip-card-back {
    padding: 20px;
  }

  .quote-icon {
    font-size: 2rem;
  }

  .review-text-flip {
    -webkit-line-clamp: 4;
  }
}

/* Custom CSS to hide the theme's hamburger menu */
/* Add this to your multiEdit.css or create a separate CSS file */

/* Hide theme's hamburger icon */
.navbar-toggler,
button[aria-label="Toggle navigation"],
[class*="hamburger-icon"],
[class*="menu-toggle"]:not(.mobile-menu-toggle),
[class*="navbar-toggle"]:not(.mobile-menu-toggle) {
  display: none !important;
}

/* These selectors target common hamburger menu implementations */
header > button,
.header button[type="button"],
.site-header button[aria-expanded],
.header-container button.toggle,
.header-right .menu-button {
  display: none !important;
}

/* Ensure our menu is positioned correctly */
#mainNav {
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  z-index: 1000 !important;
}

/* Fix for SOLIZE theme - based on your screenshot */
.container {
  /* Match your current spacing padding-top: 45px !important; */
}

/* Override any conflicting styles from vendor libraries */
.navbar .dropdown-menu.show {
  display: block !important;
}

/* 
============================================================
             CHnages with the text block to match with the admin side looks
============================================================ */

/* Quill content styling */
.content-text {
  /* Base styling */
  line-height: 1.5;
}

/* Text sizes from Quill */
.ql-size-small {
  font-size: 0.75em;
}

.ql-size-large {
  font-size: 1.5em;
}

.ql-size-huge {
  font-size: 2em;
}

/* Custom color support */
.ql-color-ca0713 {
  color: #ca0713;
}

/* Indentation for lists and paragraphs */
.ql-indent-1 {
  padding-left: 3em !important;
}
.ql-indent-2 {
  padding-left: 6em !important;
}
.ql-indent-3 {
  padding-left: 9em !important;
}
.ql-indent-4 {
  padding-left: 12em !important;
}
.ql-indent-5 {
  padding-left: 15em !important;
}

/* List item spacing */
.content-text ul,
.content-text ol {
  padding-left: 1.5em;
  margin-top: 0.5em;
  margin-bottom: 0.5em;
}

.content-text li {
  margin-bottom: 0.25em;
}

/* Nested list spacing */
.content-text li > ul,
.content-text li > ol {
  margin-top: 0.25em;
}

/* Paragraph spacing */
.content-text p {
  margin-top: 0.75em;
  margin-bottom: 0.75em;
}

/* ==========================================================================
                  Region Selector Styles 
========================================================================== */

/* Region Selector Styles */
#essential-navbar .region-selector {
  position: relative;
  margin-right: 20px;
}

#essential-navbar .region-toggle {
  display: flex;
  align-items: center;
  padding: 5px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  cursor: pointer;
  background-color: #fff;
}

#essential-navbar .region-toggle .fa-globe {
  margin-right: 6px;
  color: #e51937;
  font-size: 16px;
}

#essential-navbar .region-toggle span {
  margin: 0 5px;
  font-weight: 500;
}

#essential-navbar .region-dropdown {
  position: absolute;
  top: 100%;
  right: 0;
  background-color: #fff;
  border-radius: 4px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  min-width: 200px;
  z-index: 1002;
  padding: 10px 0;
  list-style: none;
  margin: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all 0.3s ease;
  display: none;
}

#essential-navbar .region-dropdown.active {
  opacity: 1;
  display: block;
  width: 72px;
  padding: 6px 1px;
  background-color: #bbbbbb;
  visibility: visible;
  transform: translateY(5px);
}

#essential-navbar .region-dropdown li {
  padding: 0;
}

#essential-navbar .region-dropdown a {
  display: block;
  padding: 3px 6px;
  color: #dc0a17;
  background-color: white;
  text-decoration: none;
  transition: background-color -0.8s;
  font-size: 14px;
  border-radius: 35px;
  box-shadow: 0 0 10px gray;
}

#essential-navbar .region-dropdown a:hover {
  background-color: #f5f5f5;
  color: #e51937;
}

/* Mobile region selector */
#essential-navbar .mobile-region-selector {
  border-top: 1px solid #eee;
  margin-top: 10px;
  padding-top: 15px;
}

#essential-navbar .mobile-region-selector > div {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

#essential-navbar .mobile-region-selector span {
  font-weight: 500;
}

@media (max-width: 992px) {
  #essential-navbar .region-selector {
    display: none;
  }
}

/* ==========================================================================
   Text Input Component Styles
   ========================================================================== */

.text-input-container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1rem;
}

/* ==========================================================================
   Single Text Block Styles
   ========================================================================== */

.single-text-block {
  margin: 2rem 0;
  text-align: center;
}

.single-block-title {
  font-size: 2rem;
  font-weight: 500;
  color: #dc0a17;
  margin-bottom: 1.5rem;
  text-align: center;
}

.single-block-content {
  font-size: 1.1rem;
  line-height: 1.6;
  color: #505050;
  margin-bottom: 1.5rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* ==========================================================================
   Text with Navbar Layout Styles
   ========================================================================== */

.text-with-navbar-block {
  margin: 3rem 0;
  background: #f8f9fa;
  border-radius: 8px;
  overflow: hidden;
}

.navbar-section-title {
  font-size: 1.8rem;
  font-weight: 500;
  color: #dc0a17;
  text-align: center;
  margin: 0;
  padding: 2rem 1rem 0;
}

.navbar-container {
  display: grid;
  grid-template-columns: 280px 1fr;
  min-height: 400px;
}

/* Left Navigation Styles */
.navbar-navigation {
  background: #ffffff;
  padding: 0;
  border-right: 1px solid #e0e0e0;
  display: flex;
  flex-direction: column;
}

.nav-tab {
  padding: 1rem 1.5rem;
  border: none;
  background: transparent;
  text-align: left;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 500;
  color: #505050;
  border-bottom: 1px solid #f0f0f0;
  transition: all 0.3s ease;
  position: relative;
}

.nav-tab:hover {
  background: #f8f9fa;
  color: #333;
}

.nav-tab.active {
  background: #dc0a17;
  color: white;
  font-weight: 600;
}

.nav-tab.active::after {
  content: "";
  position: absolute;
  right: -1px;
  top: 0;
  height: 100%;
  width: 3px;
  background: #dc0a17;
}

/* Right Content Area Styles */
.navbar-content-area {
  padding: 2rem;
  position: relative;
  background: white;
}

.navbar-content {
  display: none;
  animation: fadeIn 0.3s ease-in-out;
}

.navbar-content.active {
  display: block;
}

.navbar-content .content-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 0.5rem;
  position: relative;
}

.navbar-content .content-title::after {
  content: "";
  position: absolute;
  bottom: -5px;
  left: 0;
  width: 50px;
  height: 3px;
  background: #dc0a17;
}

.navbar-content .content-description {
  font-size: 1rem;
  line-height: 1.6;
  color: #505050;
  margin-top: 1.5rem;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ==========================================================================
   Grid Display Layout Styles
   ========================================================================== */

.grid-display-block {
  margin: 3rem 0;
}

.grid-section-title {
  font-size: 1.8rem;
  font-weight: 500;
  color: #dc0a17;
  text-align: center;
  margin-bottom: 2rem;
  text-transform: initial;
  letter-spacing: 0.5px;
}

.grid-columns-container {
  display: grid;
  gap: 0; /* No gap - columns touch each other */
  grid-template-columns: repeat(3, 1fr); /* Default 3 columns */
}

/* Column count variations */
.grid-columns-container[data-columns="2"] {
  grid-template-columns: repeat(2, 1fr);
}

.grid-columns-container[data-columns="3"] {
  grid-template-columns: repeat(3, 1fr);
}

.grid-columns-container[data-columns="4"] {
  grid-template-columns: repeat(4, 1fr);
}

.grid-column {
  background: white;
  padding: 1.5rem;
  border-right: 4px solid #dc0a17; /* Vertical red line */
  transition: transform 0.3s ease;
}

.grid-column:hover {
  transform: translateY(-2px);
}

.column-title {
  font-size: 1.2rem;
  font-weight: 600;
  color: #333;
  margin-bottom: 1rem;
  border-bottom: 2px solid #f0f0f0;
  padding-bottom: 0.5rem;
}

.column-content {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #505050;
  flex-grow: 1; /* Allow content to grow and fill available space */
}

.column-content ul {
  padding-left: 1.2rem;
  margin: 0.5rem 0;
}

.column-content li {
  margin-bottom: 0.5rem;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

/* Large Desktop */
@media (max-width: 1200px) {
  .grid-columns-container[data-columns="4"] {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Tablet */
@media (max-width: 992px) {
  .text-input-container {
    padding: 1.5rem 1rem;
  }

  .navbar-container {
    grid-template-columns: 250px 1fr;
  }

  .navbar-content-area {
    padding: 1.5rem;
  }

  .grid-columns-container[data-columns="3"],
  .grid-columns-container[data-columns="4"] {
    grid-template-columns: repeat(2, 1fr);
  }

  .nav-tab {
    padding: 0.8rem 1.2rem;
    font-size: 0.95rem;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .text-input-container {
    padding: 1rem 0.5rem;
  }

  /* Stack navbar layout vertically on mobile */
  .navbar-container {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .navbar-navigation {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
    border-right: none;
    border-bottom: 1px solid #e0e0e0;
    padding: 0.5rem 0;
    /* Hide scrollbar but keep functionality */
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .navbar-navigation::-webkit-scrollbar {
    display: none;
  }

  .nav-tab {
    flex: 0 0 auto;
    white-space: nowrap;
    padding: 0.8rem 1rem;
    margin: 0 0.25rem;
    border-radius: 20px;
    border-bottom: none;
    /* Limit to show approximately 1.3 tabs */
    max-width: calc(65vw - 20px);
    min-width: 100px;
    font-size: 0.85rem;
    overflow: hidden;
    text-overflow: ellipsis;
    position: relative;
  }

  /* Add swipe indicator to each tab */
  .nav-tab::after {
    content: "→";
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    color: rgba(220, 10, 23, 0.6);
    font-size: 12px;
    font-weight: bold;
  }

  /* Change arrow color to white on active tab */
  .nav-tab.active::after {
    display: block;
    color: white;
  }

  .navbar-content-area {
    padding: 1.5rem 1rem;
  }

  .navbar-content .content-title {
    font-size: 1.3rem;
  }

  /* Fix responsive content in tabs */
  .navbar-content .content-description {
    font-size: 0.95rem;
    line-height: 1.5;
  }

  .navbar-content .content-description p {
    margin-bottom: 1rem;
  }

  .navbar-content .content-description img {
    max-width: 100% !important;
    height: auto !important;
    margin: 1rem 0;
  }

  .navbar-content .content-description ul,
  .navbar-content .content-description ol {
    padding-left: 1.2rem;
    margin: 1rem 0;
  }

  .navbar-content .content-description li {
    margin-bottom: 0.5rem;
    line-height: 1.4;
  }

  /* Grid becomes single column on mobile */
  .grid-columns-container,
  .grid-columns-container[data-columns="2"],
  .grid-columns-container[data-columns="3"],
  .grid-columns-container[data-columns="4"] {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .grid-section-title {
    font-size: 1.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
  }

  .single-block-title {
    font-size: 1.6rem;
  }

  .navbar-section-title {
    font-size: 1.5rem;
    padding: 1.5rem 1rem 0;
  }
}

/* Additional mobile responsiveness for very small screens */
@media (max-width: 480px) {
  .nav-tab {
    max-width: calc(60vw - 15px);
    min-width: 80px;
    padding: 0.7rem 0.8rem;
    font-size: 0.8rem;
  }

  .nav-tab::after {
    right: 6px;
    font-size: 10px;
  }

  .navbar-content-area {
    padding: 1rem;
  }

  .navbar-content .content-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
  }

  .navbar-content .content-description {
    font-size: 0.9rem;
  }
}

/* Small Mobile */
@media (max-width: 576px) {
  .text-input-container {
    padding: 0.5rem;
  }

  .navbar-content-area {
    padding: 1rem;
  }

  .grid-column {
    padding: 1rem;
  }

  .column-title {
    font-size: 1.1rem;
  }

  .column-content {
    font-size: 0.9rem;
  }

  .nav-tab {
    padding: 0.6rem 0.8rem;
    font-size: 0.9rem;
  }
}

/* Prefix-Link Text Block Styles - FULL WIDTH VERSION */
.prefix-link-display-block {
  width: 100vw; /* Full viewport width */
  margin-left: calc(50% - 50vw); /* Break out of container */
  margin-right: calc(50% - 50vw); /* Break out of container */
  padding: 3rem 0; /* Vertical padding only */
  background: #f8f9fa; /* Optional background */
}

.prefix-link-section-title {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  color: #dc0a17;
  margin: 0 0 1rem 0;
  padding: 0 2rem;
}

.prefix-link-columns-container {
  display: grid;
  gap: 2rem; /* Reduced gap for better space utilization */
  align-items: start;
  width: 100%; /* Full width */
  padding: 0 2rem; /* Edge padding */
  box-sizing: border-box;
}

.prefix-link-columns-container[data-columns="1"] {
  grid-template-columns: 1fr;
  max-width: 1200px;
  margin: 0 auto;
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  padding: 2rem;
  border: 1px solid #e0e0e0;
}

.prefix-link-columns-container[data-columns="2"] {
  grid-template-columns: 1fr 2px 1fr; /* Adjusted ratio for better balance */
  /* Remove max-width and margin for full-width layout */
  background: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  border: 1px solid #e0e0e0;
  max-width: 1400px;
  margin: 0 auto;
  padding: 2rem;
}

.prefix-link-column {
  display: flex;
  flex-direction: column;
}

/* Make News section (first column) utilize more space */
.prefix-link-column:first-child {
  padding-right: 1rem;
}

/* Make Events section (second column) utilize right half properly */
.prefix-link-column:last-child {
  padding-left: 1rem;
}

.prefix-link-column-title {
  font-size: 22px;
  font-weight: 700;
  color: #333;
  margin: 0 0 2rem 0;
  border-bottom: 2px solid #dc0a17;
  padding-bottom: 0.5rem;
}

.prefix-link-items {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  flex: 1; /* Take remaining space */
}

.prefix-link-item {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.5rem; /* Slightly reduced gap */
  align-items: start;
  padding: 0.75rem 0;
  border-bottom: 1px solid #f0f0f0;
}

.prefix-link-item:last-child {
  border-bottom: none;
}

.prefix-text {
  font-size: 14px;
  font-weight: 600;
  color: #666;
  white-space: nowrap;
  flex-shrink: 0;
  min-width: 100px; /* Slightly reduced for better space usage */
}

.prefix-description {
  flex: 1;
}

.prefix-description a {
  color: #333;
  text-decoration: none;
  line-height: 1.4;
  display: block;
  transition: color 0.3s ease;
}

.prefix-description a:hover {
  color: #dc0a17;
}

.prefix-description a:focus {
  outline: 2px solid #dc0a17;
  outline-offset: 2px;
}

/* Enhanced vertical divider */
.prefix-link-divider {
  width: 2px;
  background: linear-gradient(to bottom, #dc0a17, #ff4757);
  border-radius: 1px;
  min-height: 300px;
  justify-self: center;
  align-self: stretch; /* Stretch to full height */
}

/* Adjust the display block padding for both 1-column and 2-column to give more space around the box */
.prefix-link-display-block:has(
    .prefix-link-columns-container[data-columns="1"]
  ),
.prefix-link-display-block:has(
    .prefix-link-columns-container[data-columns="2"]
  ) {
  padding: 3rem 2rem;
}

/* Responsive Design */
@media (max-width: 1400px) {
  .prefix-link-columns-container {
    padding: 0 1.5rem;
  }

  .prefix-link-columns-container[data-columns="2"] {
    max-width: 1200px;
    padding: 2rem 1.5rem;
  }
}

@media (max-width: 1200px) {
  .prefix-link-columns-container[data-columns="2"] {
    grid-template-columns: 1.5fr 2px 1.5fr; /* Adjust ratio for smaller screens */
    max-width: 1000px;
    padding: 2rem 1rem;
  }

  .prefix-link-columns-container {
    padding: 0 1rem;
  }
}

@media (max-width: 768px) {
  .prefix-link-display-block {
    padding: 2rem 0;
  }

  .prefix-link-columns-container[data-columns="2"] {
    grid-template-columns: 1fr;
    gap: 2rem;
    margin: 0 1rem;
    max-width: calc(100% - 2rem);
    padding: 1.5rem;
  }

  .prefix-link-divider {
    display: none;
  }

  .prefix-link-section-title {
    font-size: 24px;
    margin-bottom: 2rem;
    padding: 0 1rem;
  }

  .prefix-link-columns-container {
    padding: 0 1rem;
  }

  .prefix-link-column {
    min-height: auto;
    padding: 0 !important;
  }

  .prefix-link-column-title {
    font-size: 20px;
  }

  .prefix-link-item {
    grid-template-columns: 1fr;
    gap: 0.5rem;
  }

  .prefix-text {
    min-width: auto;
    font-size: 13px;
    color: #dc0a17;
  }

  /* Mobile responsive for 1-column box */
  .prefix-link-columns-container[data-columns="1"] {
    padding: 1.5rem;
    margin: 0 1rem;
    max-width: calc(100% - 2rem);
  }

  .prefix-link-display-block:has(
      .prefix-link-columns-container[data-columns="1"]
    ),
  .prefix-link-display-block:has(
      .prefix-link-columns-container[data-columns="2"]
    ) {
    padding: 2rem 0;
  }
}

@media (max-width: 480px) {
  .prefix-link-display-block {
    padding: 1rem 0;
  }

  .prefix-link-items {
    gap: 1rem;
  }

  .prefix-link-item {
    padding: 0.5rem 0;
  }

  .prefix-link-section-title,
  .prefix-link-columns-container {
    padding: 0 0.5rem;
  }

  .prefix-link-columns-container[data-columns="1"] {
    padding: 1rem;
    margin: 0 0.5rem;
    max-width: calc(100% - 1rem);
  }

  .prefix-link-columns-container[data-columns="2"] {
    padding: 1rem;
    margin: 0 0.5rem;
    max-width: calc(100% - 1rem);
  }
}
