:root {
  --page-bg: #eef1f9;
  --gap: 26px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family:"Inter", sans-serif;
  background: var(--page-bg);
}

.esg-grid {
  max-width: 1400px;
  margin: 0 auto;
  padding: 40px 24px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: repeat(6, minmax(70px, 1fr));
  gap: var(--gap);
  height: 900px;
}

.esg-card {
  position: relative;
  border-radius: 6px;
  overflow: hidden;
  background-size: cover;
  background-position: center;
  color: #fff;
}

.esg-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.35) 30%, transparent 60%);
}

.esg-card.big { grid-column: 1; }
.esg-card.small { grid-column: 2; }

.esg-card:nth-child(1) { grid-row: 1 / span 3; }
.esg-card:nth-child(2) { grid-row: 4 / span 3; }
.esg-card:nth-child(3) { grid-column: 2; grid-row: 1 / span 2; }
.esg-card:nth-child(4) { grid-column: 2; grid-row: 3 / span 2; }
.esg-card:nth-child(5) { grid-column: 2; grid-row: 5 / span 2; }

.esg-caption {
  position: absolute;
  left: 26px;
  right: 26px;
  bottom: 22px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.esg-caption h3 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 500;
}

.esg-know-more {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #fff;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.3s ease;
}

/* Underline that swipes in on hover — mirrors .bc .bc-more::after */

.esg-know-more::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -5px;
  width: 100%;
  height: 1px;
  background: currentColor;
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1);
}

/* CSS chevron arrow — mirrors .bc .bc-arrow-icon */

.esg-arrow-icon {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-right: 1.5px solid currentColor;
  border-top: 1.5px solid currentColor;
  transform: rotate(45deg);
  transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1);
}

/* Animation on hover — mirrors .bc .bc-more interactions */

.esg-card:hover .esg-know-more,
.esg-know-more:hover {
  color: #7fd4ee;
}

.esg-card:hover .esg-know-more::after {
  transform: scaleX(1);
  transform-origin: left;
}

.esg-card:hover .esg-arrow-icon {
  transform: translate(4px, -4px) rotate(45deg);
}

@media (prefers-reduced-motion: reduce) {
  .esg-know-more::after,
  .esg-arrow-icon {
    transition: none;
  }
}

@media (max-width: 800px) {
  .esg-grid {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    height: auto;
  }
  .esg-card, .esg-card:nth-child(1), .esg-card:nth-child(2),
  .esg-card:nth-child(3), .esg-card:nth-child(4), .esg-card:nth-child(5) {
    grid-column: 1;
    grid-row: auto;
    height: 300px;
  }
}
