/* ---------- Global Styles ---------- */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  line-height: 1.6;
  background-color: #fdfdfd;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

header,
footer {
  text-align: center;
  padding: 2rem;
  background-color: #f4f4f4;
}

/* ---------- Main layout ---------- */
main {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding-bottom: 120px; /* space for footer */
  width: 100%;
}

/* ---------- Top Container ---------- */
.top {
  width: 100%;
  max-width: 1100px; /* same as grid+branch together */
  display: flex;
  justify-content: center;
  padding: 0 10px;
}

.top .article img {
  width: 100%;
  height: auto;
  object-fit: contain; /* fully visible */
  border-radius: 6px;
  margin-bottom: 1rem;
}

/* ---------- Grid + Branch Row ---------- */
.grid-branch-container {
  display: flex;
  width: 100%;
  max-width: 1100px; /* same as top */
  gap: 20px;
  align-items: stretch; /* equal height */
}

/* ---------- Grid & Branch Containers ---------- */
.grid,
.branch {
  width: 50%;
  display: flex;
  flex-direction: column;
  justify-content: space-between; /* push headings, images, buttons into aligned positions */
  align-items: stretch;
}

/* ---------- Article inside Grid & Branch ---------- */
.grid .article,
.branch .article {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: stretch;
  height: 100%;
  gap: 10px;
  background: transparent;
  padding: 0;
}

/* ---------- Headings ---------- */
.article > h2 {
  font-size: 1.4rem;
  margin-bottom: 0.5rem;
}

.grid h3,
.branch h3 {
  font-size: 1.1rem;
  margin: 0;
  text-align: left;
}

/* Wrap headings, images, and buttons in a flex column to align tops and bottoms */
.grid .article .content,
.branch .article .content {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}

/* ---------- Image Styling ---------- */
.grid .article img,
.branch .article img {
  width: 100%;
  height: auto;
  object-fit: contain; /* fully visible */
  border-radius: 6px;
  display: block;
}

/* ---------- Buttons Row ---------- */
.buttons-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: 10px;
}

.article a {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: #333;
  color: #fff;
  text-decoration: none;
  border-radius: 4px;
  flex: 1; /* buttons stretch equally */
  text-align: center;
}

.article a:hover {
  background: #555;
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .grid-branch-container {
    flex-direction: column;
    width: 90%;
  }

  .grid,
  .branch {
    width: 100%;
  }

  .grid .article img,
  .branch .article img {
    height: auto;
  }

  .buttons-row {
    flex-direction: column;
  }

  .buttons-row a {
    flex: none;
    width: 100%;
  }
}

@media (max-width: 600px) {
  main { padding: 0.5rem; }
  .article { padding: 0.75rem; }
  .article a { padding: 0.35rem 0.6rem; }
  .top .article img,
  .grid .article img,
  .branch .article img { width: 100%; height: auto; }
}

/* ---------- Global Link Styling ---------- */
a { color: #0066cc; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  text-align: center;
  padding: 1rem 2rem;
  background-color: #f4f4f4;
  border-top: 1px solid #ddd;
  box-shadow: 0 -2px 5px rgba(0, 0, 0, 0.1);
  z-index: 1000;
}





