/* --------------- Header Social Icons ----------------- */
.social-icons {
  display: flex;
  justify-content: center;
  gap: 1rem;
}

.social-icons a {
  font-size: 1.5rem;
  color: white;
  transition: transform 0.2s ease;
}

.social-icons a:hover {
  transform: scale(1.2);
  color: #009688;
}

.social-icons .custom-icon {
  width: 1.5rem;
  height: 1.5rem;
  filter: invert(100%);
  transition: transform 0.2s ease;
}

.social-icons .custom-icon:hover {
  transform: scale(1.2);
  filter: invert(80%);
}

/* --------------- Certifications Page ----------------- */
details {
  margin-bottom: 1em;
}

summary {
  cursor: pointer;
  font-weight: bold;
  font-size: 1.1em;
}

.image-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-start;
}

.image-grid img {
  flex: 1 1 calc(33.333% - 10px);
  max-width: calc(33.333% - 10px);
  height: auto;
  border-radius: 6px;
  object-fit: cover;
  cursor: zoom-in;
  transition: transform 0.2s;
}

.image-grid img:hover {
  transform: scale(1.03);
}

@media (max-width: 768px) {
  .image-grid img {
    flex: 1 1 calc(50% - 10px);
    max-width: calc(50% - 10px);
  }
}

@media (max-width: 480px) {
  .image-grid img {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

/* ---------------- Modal Styles ---------------- */
#imgModal {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: rgba(0, 0, 0, 0.85);
  padding-top: 60px;
  overflow: hidden;
  text-align: center;
}

#imgModal .carousel {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

#imgModal img {
  max-width: 90%;
  max-height: 66vh;
  border-radius: 8px;
  transition: opacity 0.3s ease-in-out;
}

#imgModal .closeBtn {
  position: absolute;
  top: 20px;
  right: 35px;
  color: white;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  z-index: 2;
}

/* Navigation arrows */
#prevBtn, #nextBtn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: rgba(0, 0, 0, 0.5);
  color: white;
  border: none;
  padding: 12px 16px;
  cursor: pointer;
  font-size: 2rem;
  z-index: 2;
  border-radius: 50%;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

#prevBtn:hover, #nextBtn:hover {
  /* background-color: rgba(255, 255, 255, 0.2); */
  transform: translateY(-50%) scale(1.1);
}

#prevBtn {
  left: 20px;
}

#nextBtn {
  right: 20px;
}

/* Modal text and links */
#modalText {
  color: white;
  max-width: 90%;
  margin: 1.5em auto 1em;
  text-align: center;
}

#modalTitle h2 {
  margin-bottom: 0px;
  font-size: 1.5rem;
}

#modalText p {
  margin-bottom: 1px;
}

#modalLinks a {
  color: #00aaff;
  margin: 0 10px;
  text-decoration: underline;
  font-weight: 500;
}

#modalTags {
  color: #aaa;
  font-size: 0.95em;
}

/* ---------------- Responsive Adjustments ---------------- */
@media (max-width: 768px) {
  #imgModal img {
    max-width: 95%;
    max-height: 60vh;
  }

  #prevBtn, #nextBtn {
    padding: 10px 14px;
    font-size: 1.8rem;
  }

  #modalText h2 {
    font-size: 1.3rem;
  }
}

@media (max-width: 480px) {
  #modalText p {
    font-size: 0.95rem;
  }

  #prevBtn, #nextBtn {
    font-size: 1.5rem;
    padding: 8px 12px;
  }
}

/* --------------- Articles Page ----------------- */
.article-content {
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 15px;
}

.article-content img {
  width: 120px;
  height: 80px;
  border-radius: 6px;
  object-fit: cover;
  cursor: pointer;
  transition: transform 0.2s;
}

.article-content img:hover {
  transform: scale(1.05);
}

.article-content a {
  text-decoration: none;
  font-weight: 500;
}

.article-content p {
  margin: 0;
  font-size: 1.1em;
}

/* --------------- Projects & Contributions Page ----------------- */
/* Note: Modal and image-grid styles are already included above */

/* ------------------- Accordion/Admonition ----------------- */
.md-typeset .admonition,
.md-typeset details {
  border-width: 0;
  border-left-width: 4px;
  border-color: #009688;
}

.md-typeset .admonition-title:before, 
.md-typeset summary:before {
    background: var(--md-primary-fg-color);
}

.md-banner {
    background-color: var(--md-footer-bg-color);
    /* background-color: var(--md-primary-fg-color); */
    color: var(--md-footer-fg-color);
    overflow: auto;
}

.md-typeset h1 {
    color: var(--md-primary-fg-color);
}

.md-typeset .admonition, .md-typeset details {
    border-color: var(--md-primary-fg-color);
}