/*
 * Blocks Drop Shadow Element Styles
 * File: /elements/css/blocks-drop-shadow.css
 */

/* Main Element Wrapper */
.bds-wrapper {
  width: 100%;
  margin-bottom: 100px;
}

/* Main Heading (e.g., "OUR VALUES") */
.bds-main-heading {
  font-family: 'Figtree', sans-serif;
  font-weight: 500;
  font-size: 36px;
  line-height: 150%;
  letter-spacing: 0.5em; 
  color: #36194C;
  text-transform: uppercase;
  max-width: 1440px;
  width: calc(100% - 40px);
  margin: 0px auto;
  margin-bottom: 40px;
}

/* --- Grid Wrapper --- */
/* Switched to GRID with grid-auto-rows: 1fr for global equal height */
.bds-grid-wrapper {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: 1fr; 
  gap: 40px;
  max-width: 1440px;
  width: calc(100% - 40px);
  margin: 0px auto;
}

/* --- Repeater Item --- */
.bds-grid-item {
  display: flex;
  flex-direction: column;
  /* Visual Styles */
  box-shadow: 0px 10px 25px 0px #0000004D;
  backdrop-filter: blur(15px);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 30px;
}

/* --- 3-COLUMN LAYOUT (from toggle) --- */

.bds-grid-wrapper.three-columns {
  grid-template-columns: repeat(3, 1fr);
}

/* Special Case: 4 items (3 + 1) */
.bds-grid-wrapper.layout-3-1 .bds-grid-item:last-child {
  grid-column: 1 / -1;
}

/* Special Case: 5 items (3 + 2) */
.bds-grid-wrapper.layout-3-2 {
  /* Use 6 columns to allow 1/3 (span 2) and 1/2 (span 3) sizing */
  grid-template-columns: repeat(6, 1fr);
}

.bds-grid-wrapper.layout-3-2 .bds-grid-item {
  grid-column: span 2;
}

.bds-grid-wrapper.layout-3-2 .bds-grid-item:nth-last-child(-n+2) {
  grid-column: span 3;
}

/* --- Item Content --- */

.bds-item-title {
  font-family: 'Figtree', sans-serif;
  font-weight: 500;
  font-size: 24px;
  line-height: 150%;
  letter-spacing: 0%;
  color: #36194C !important;
  margin-top: 0;
  margin-bottom: 15px;
}

.bds-item-content {
  font-family: 'Figtree', sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 150%;
  letter-spacing: 0;
  color: #36194C;
  margin-top: 0;
}

.bds-item-content p:last-child {
  margin-bottom: 0;
}

.bds-main-heading.text-center {
  text-align: center;
}

/* Sub Heading Styles */
.bds-sub-heading {
  font-family: 'Figtree', sans-serif;
  font-weight: 400;
  font-size: 1.4em;
  line-height: 150%;
  letter-spacing: 0;
  color: #36194C;
  max-width: 1440px;
  width: calc(100% - 40px);
  margin: -25px auto 60px auto;
  padding: 0;
}

.bds-sub-heading.text-center {
  text-align: center;
}

/* --- Responsive Styling --- */

@media (max-width: 991px) {
  .bds-grid-wrapper {
    grid-template-columns: 1fr;
    grid-auto-rows: auto; /* Reset to natural height when stacked on mobile */
    gap: 30px;
    width: calc(100% - 0px);
  }

  .bds-grid-wrapper.three-columns,
  .bds-grid-wrapper.layout-3-2 {
    grid-template-columns: 1fr;
  }

  .bds-grid-wrapper .bds-grid-item,
  .bds-grid-wrapper.layout-3-1 .bds-grid-item:last-child,
  .bds-grid-wrapper.layout-3-2 .bds-grid-item:nth-last-child(-n+2) {
    grid-column: auto;
  }
}

@media (max-width: 767px) {
  .bds-main-heading {
    font-size: 32px;
    margin-bottom: 30px;
  }

  .bds-item-title {
    font-size: 22px;
  }

  .bds-item-content p {
    font-size: 16px;
  }
  
  .bds-grid-item {
    padding: 24px;
  }

  .bds-wrapper {
    margin-left: 20px;
    margin-right: 20px;
    width: auto;
    margin-bottom: 20px !important;
  }
}