/**
 * Inner Page & Sidebar Component Styling - IIFCL Theme
 * Implements modern CSS Grid 2-Column Responsive Layouts
 */

/* ==========================================================================
   1. Two-Column Layout Grid (Desktop & Responsive)
   ========================================================================== */
.page-layout-grid {
  width: 100%;
  margin: 0 auto;
}

/* Desktop 2-Column Layout (>= 992px) */
@media (min-width: 992px) {
  .page-layout--with-left-sidebar {
    display: grid !important;
    grid-template-columns: 320px minmax(0, 1fr) !important;
    column-gap: 2.5rem !important;
    align-items: start !important;
  }

  .page-layout--with-right-sidebar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) 320px !important;
    column-gap: 2.5rem !important;
    align-items: start !important;
  }

  .page-layout--with-left-sidebar .sidebar-left-column {
    grid-column: 1 !important;
  }

  .page-layout--with-left-sidebar .main-content-column {
    grid-column: 2 !important;
  }

  .page-layout--with-right-sidebar .main-content-column {
    grid-column: 1 !important;
  }

  .page-layout--with-right-sidebar .sidebar-right-column {
    grid-column: 2 !important;
  }
}

/* Tablet and Mobile Stacking (< 992px) */
@media (max-width: 991.98px) {
  .page-layout--with-left-sidebar,
  .page-layout--with-right-sidebar {
    display: flex !important;
    flex-direction: column !important;
    gap: 2rem !important;
  }

  /* Main content always appears first on small screens */
  .main-content-column {
    order: 1 !important;
    width: 100% !important;
  }

  /* Sidebar always stacks underneath on small screens */
  .sidebar-column {
    order: 2 !important;
    width: 100% !important;
  }
}

/* Full Width Layout */
.page-layout--full-width {
  width: 100%;
}

.page-layout--full-width .main-content-column {
  width: 100%;
}

/* ==========================================================================
   2. General-Purpose Sidebar & Content Column Styles
   ========================================================================== */
.sidebar-column {
  margin-bottom: 2rem;
}

.sidebar-inner-content {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.main-inner-content {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

/* ==========================================================================
   3. Heading Component Styles
   ========================================================================== */
.component-heading {
  margin-top: 1rem;
  margin-bottom: 0.75rem;
}

.component-heading .section-component-heading {
  color: #0f172a;
  font-weight: 700;
  margin: 0;
  line-height: 1.3;
}

.heading-style--underlined .section-component-heading {
  position: relative;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid #e2e8f0;
}

.heading-style--underlined .section-component-heading::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 45px;
  height: 2px;
  background-color: #0d6efd;
}

.heading-style--badge .section-component-heading {
  display: inline-block;
  background-color: #eff6ff;
  color: #1d4ed8;
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  font-size: 0.95rem;
  font-weight: 600;
  border-left: 3px solid #0d6efd;
}

.heading-style--highlight .section-component-heading {
  background: linear-gradient(120deg, #dbeafe 0%, #eff6ff 100%);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border-left: 4px solid #0d6efd;
}

/* ==========================================================================
   4. Component Blocks (Links, Contacts, Documents, Menus, Media)
   ========================================================================== */
.sidebar-widget-block {
  margin-bottom: 1.25rem;
}

.sidebar-nav-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.sidebar-nav-list li {
  padding: 0.5rem 0;
}

.border-bottom-dashed {
  border-bottom: 1px dashed #e2e8f0;
}

.sidebar-nav-list li:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.sidebar-nav-list li a {
  color: #334155;
  font-size: 0.95rem;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: all 0.2s ease;
}

.sidebar-nav-list li a:hover {
  color: #0d6efd;
  transform: translateX(4px);
}

.sidebar-nav-list li a i {
  color: #0d6efd;
  font-size: 0.85rem;
}

/* Contact Info Component */
.component-contact-info .contact-entry {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.4rem 0;
}

.component-contact-info .contact-entry i {
  color: #0d6efd;
  font-size: 1rem;
  margin-top: 0.2rem;
  width: 18px;
  text-align: center;
}

/* Document Download Component */
.component-document {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 1.25rem;
}

.component-document .document-icon i {
  color: #dc3545;
  font-size: 2rem;
}

.component-document .document-title {
  color: #0f172a;
  font-size: 1rem;
  font-weight: 600;
}

/* Reusable Button Component */
.component-button .btn {
  font-weight: 600;
  padding: 0.5rem 1.25rem;
  transition: all 0.3s ease;
}

.component-button .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(13, 110, 253, 0.2);
}

/* Image Component */
.component-image .image-wrapper img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  display: block;
}

/* Media Component */
.component-media .ratio {
  border-radius: 8px;
}

/* ==========================================================================
   Homepage Reference Design Custom Enhancements
   ========================================================================== */
@media only screen and (min-width: 1200px) and (max-width: 1399px) {
  .mainmenu ul {
    gap: 0 15px;
  }
}

.footer-main-area {
  position: relative;
  padding: 80px 0 40px 0;
}

.visitors-counter {
  background-color: #023e82;
  width: fit-content;
  padding: 8px 16px;
  color: #fff;
  margin-top: 16px;
}

#myVideo {
  width: 100%;
  height: 700px;
  object-fit: unset;
  display: block;
}

.countup-item .inline-content {
  display: inline-flex !important;
  align-items: baseline !important;
  justify-content: center !important;
  white-space: nowrap !important;
}

.countup-item .odometer {
  display: inline-block !important;
  white-space: nowrap !important;
}
