body {
  margin: 0;
  font-family: Arial, sans-serif;
  background: #f7f7f7;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

h3 {
  margin: 20px 0;
  text-align: center;
  font-weight: normal;
}

.page-container {
  flex: 1;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* Map container with fixed aspect ratio math */
.map-container {
  width: min(90vw, 90vh * 9372 / 9959);
  height: calc(min(90vw, 90vh * 9372 / 9959) * 9959 / 9372); /* derive height */
  border: 1px solid #555;
  margin: 10px auto 50px auto;
  position: relative;
}

#map {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
}

/* Default cursor for map: grab/move */
#map,
#map * {
  cursor: move !important;
}

/* But when hovering zoom controls: default arrow */
#map .leaflet-control-zoom,
#map .leaflet-control-zoom *,
#map .leaflet-control-container,
#map .leaflet-control-container * {
  cursor: default !important;
}

/* === Shapes and Captions (below map) === */
.shape {
  background: #ddd; /* fallback if no image */
  margin: 10px auto;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Rectangle (153:50 ratio) */
.rectangle {
  width: 60vw;
  max-width: 800px;
  aspect-ratio: 153 / 50;
  border-radius: 20px;
}

/* Bigger 2 Circles */
.circle {
  width: 400px;
  aspect-ratio: 1 / 1;
  border-radius: 50%;
}

/* Smaller circles row */
.small-circle {
  width: 200px;
  height: 200px;       /* ensure perfect circle */
  border-radius: 50%;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.circles-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px;
  margin-bottom: -20px;
}

/* Rectangles row */
.rectangles-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px;
  margin-bottom: 40px;
}

/* Rectangle (20:7 ratio) (Hyderabad) */
.rect-20-7 {
  height: 200px;
  aspect-ratio: 20 / 7;
  border-radius: 15px;
  overflow: hidden;
  margin-left: 100px;
}

/* Rectangle (7:2 ratio) (Bengaluru) ( */
.rect-7-2 {
  height: 200px;
  aspect-ratio: 7 / 2;
  border-radius: 15px;
  overflow: hidden;
  margin-left: -400px;
}

/* Shape + Caption container */
.shape-with-caption {
  display: flex;
  flex-direction: column;
  align-items: center;
  max-width: 220px;
  text-align: center;
}

.shape-with-caption .caption {
  margin-top: 10px;
  font-size: 0.9rem;
  line-height: 1.3;
}

.shape-with-caption .caption-blr {
  margin-top: 10px;
  font-size: 0.9rem;
  line-height: 1.3;
  transform: translateX(-200px);
  margin-bottom: 20px;
}

.shape-with-caption .caption-hyd {
  margin-top: 10px;
  font-size: 0.9rem;
  line-height: 1.3;
  transform: translateX(300px);
  margin-bottom: 20px;
}

/* Images inside shapes */
.shape img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 1px solid grey;
  border-radius: inherit; /* rectangle stays rounded, circle stays round */
}

/* Circles row with big spacing */
.shapes-row {
  display: flex;
  justify-content: center;
  gap: 50px;
  flex-wrap: wrap;
}

.caption {
  margin: 20px 0 50px 0;
  font-size: 1rem;
  text-align: left;
}

/* === Squares Row === */
.squares-row {
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: flex-start;
  gap: 50px;
  margin-top: -40px;
  flex-wrap: nowrap; /* prevent stacking */
}

.big-square {
  width: 500px;
  height: 500px;
  border-radius: 15px;
  border: 1px solid #888;
  overflow: hidden;
  background: #fff;
}

.shape-with-caption-square {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 500px;
}

.shape-with-caption-square img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.shape-with-caption-square .caption {
  margin-top: 12px;
  font-size: 1rem;
  line-height: 1.5;
  color: #333;
}

/* Map Breakdown Title */
p.map-breakdown {
  font-weight: normal;
  font-size: 24px;
  margin: 0 0 20px 0;
  text-align: center;
}

/* === Mobile Responsive Overrides === */
@media (max-width: 768px) {
  /* Map shrinks to screen */
  .map-container {
    width: 95vw;
    height: auto;
    aspect-ratio: 9372 / 9959;
  }

  /* Circles shrink */
  .circle {
    width: 70vw;
    max-width: 250px;
    height: auto;
  }

  .small-circle {
    width: 40vw;
    max-width: 150px;
    height: auto;
  }

  /* Rectangles stack smaller with proportional left shift */
  .rect-20-7,
  .rect-7-2 {
    width: 70vw;          /* smaller than 85vw */
    height: auto;
    margin: 10px auto;
    transform: translateX(-8vw); /* smaller shift to balance */
  }

  /* Captions aligned with rectangles */
  .shape-with-caption .caption-blr,
  .shape-with-caption .caption-hyd {
    transform: translateX(-8vw);
    margin: 10px 0;
    text-align: center;
  }

  /* Squares shrink and stack */
  .squares-row {
    flex-wrap: wrap;
    gap: 20px;
  }

  .big-square {
    width: 90vw;
    height: auto;
    aspect-ratio: 1 / 1;
  }

  /* Text size smaller */
  h3 {
    font-size: 1.2rem;
    padding: 0 10px;
  }

  .caption {
    font-size: 0.85rem;
    text-align: center;
  }
}
