:root {
  --primary: #0db9d7;
  --bg: #1e1e2c;
  --text: #ededed;
  --hover: #ffd700;
  --hamburger-size: 2.5rem; /* Ukuran ikon hamburger */
  --icon-size: 1.8rem; /* Ukuran ikon Instagram dan TikTok */
  --line-height: 2.5rem; /* Line height sesuai dengan ukuran ikon terbesar */
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  outline: none;
  border: none;
  text-decoration: none;
}

body {
  font-family: "Poppins", sans-serif;
  background: var(--bg);
  color: var(--text);
  /* min-height:800px; */
}

/* navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.4rem 7%;
  background: rgba(58, 63, 92, 0.2); /* More transparency */
  backdrop-filter: blur(10px); /* Apply blur for glassmorphism effect */
  -webkit-backdrop-filter: blur(10px); /* Support for Safari */
  border-bottom-left-radius: 0.5rem;
  border-bottom-right-radius: 0.5rem;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  border-bottom: 2px solid var(--primary); /* Optional: Add a border with a more visible primary color */
}

.navbar .navbar-logo {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text);
  font-style: italic;
}

.navbar .navbar-logo span {
  color: var(--primary);
}

.navbar .navbar-nav a {
  color: var(--text);
  display: inline-block;
  font-size: 1.3rem;
  margin: 0 1rem;
  line-height: var(--line-height); /* Sesuaikan dengan line-height terbesar */
  vertical-align: middle; /* Pastikan semua ikon sejajar vertikal */
  transition: transform 0.3s ease
}

.navbar .navbar-nav a:hover {
  transform: scale(1.02);
  color: var(--hover);
}

.navbar .navbar-nav a::after {
  content: "";
  display: block;
  padding-bottom: 0.5rem;
  border-bottom: 0.1rem solid var(--hover);
  transform: scaleX(0);
  transition: transform 0.3s ease, color 0.3s ease; /* Tambahkan transisi untuk semua ikon */
}

.navbar .navbar-nav a:hover::after {
  transform: scaleX(0.6);
  transition: transform 0.3s ease, color 0.3s ease; /* Tambahkan transisi untuk semua ikon */
}

#instagram-icon:hover {
  transform: scale(1.02);
  color: var(--hover);
}

#tiktok-icon:hover {
  transform: scale(1.02);
  color: var(--hover);
}

.navbar .navbar-extra a {
  color: var(--text);
  margin: 0 0.5rem;
  font-size: var(--icon-size); /* Ukuran default ikon Instagram dan TikTok */
  line-height: var(--line-height); /* Sesuaikan dengan line-height terbesar */
  vertical-align: middle; /* Pastikan semua ikon sejajar vertikal */
}

#hamburger-menu {
  display: none;
  font-size: var(--hamburger-size); /* Ukuran ikon hamburger */
  line-height: var(--line-height); /* Sesuaikan dengan line-height terbesar */
  vertical-align: middle; /* Pastikan semua ikon sejajar vertikal */
}

.navbar .navbar-extra a:hover {
  color: var(--hover);
  transform: scale(1.025);
  transition: transform 0.3s ease, color 0.3s ease; /* Tambahkan transisi untuk semua ikon */
}

.navbar .navbar-nav a.active {
  color: var(--hover); /* Warna ketika page aktif */
}

.navbar .navbar-nav a.active::after {
  transform: scaleX(1);
  transition: transform 0.3s ease;
}

/* General Chat Icon Styles */
#chat-icon {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 60px;
  height: 60px;
  cursor: pointer;
  background-color: rgba(58, 63, 92, 0.8);
  backdrop-filter: blur(10px);
  border-radius: 50%;
  padding: 15px;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

/* animasi */
#chat-icon {
  -webkit-animation: bounce-in-top 1.1s both;
  animation: bounce-in-top 1.1s both;
}

@-webkit-keyframes bounce-in-top {
  0% {
    -webkit-transform: translateY(-500px);
    transform: translateY(-500px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
    opacity: 0;
  }
  38% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
    opacity: 1;
  }
  55% {
    -webkit-transform: translateY(-65px);
    transform: translateY(-65px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  72% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
  81% {
    -webkit-transform: translateY(-28px);
    transform: translateY(-28px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  90% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
  95% {
    -webkit-transform: translateY(-8px);
    transform: translateY(-8px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  100% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
}
@keyframes bounce-in-top {
  0% {
    -webkit-transform: translateY(-500px);
    transform: translateY(-500px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
    opacity: 0;
  }
  38% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
    opacity: 1;
  }
  55% {
    -webkit-transform: translateY(-65px);
    transform: translateY(-65px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  72% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
  81% {
    -webkit-transform: translateY(-28px);
    transform: translateY(-28px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  90% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
  95% {
    -webkit-transform: translateY(-8px);
    transform: translateY(-8px);
    -webkit-animation-timing-function: ease-in;
    animation-timing-function: ease-in;
  }
  100% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    -webkit-animation-timing-function: ease-out;
    animation-timing-function: ease-out;
  }
}

#chat-icon:hover {
  transform: scale(1.04);
}

#chat-icon ion-icon {
  font-size: 30px;
  color: #fff;
}

#chat-icon ion-icon:hover {
  color: var(--hover);
}

.hidden {
  display: none;
}

/* General Chat Popup Styles */
#chat-popup {
  position: fixed;
  bottom: 20px;
  right: 20px;
  width: 36rem;
  max-width: 91%;
  min-width: 40%;
  height: min-content;
  background: rgba(58, 63, 92, 0.4);
  backdrop-filter: blur(10px);
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  border-bottom-left-radius: 20px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
  padding: 20px;
  border: 2px solid rgba(13, 185, 215, 1);
  z-index: 1000;
}

.chat-container {
  display: flex;
  flex-direction: column;
  align-items: stretch;
}

.chat-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

.chat-header h2 {
  font-size: 1.8rem;
  margin: 0;
  padding: 0;
  color: var(--primary);
  text-shadow: 2px 2px 2px rgba(0, 0, 0, 0.1);
}

.chat-output {
  height: 20vw;
  max-height: 18rem;
  min-height: 12rem;
  overflow-y: auto;
  margin: 0;
  padding-top: 8px;
  padding-bottom: 8px;
  border-radius: 10px;
  color: #fff;
}

.chat-input-container {
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

input[type="text"], textarea {
  width: 100%;
  padding: 10px;
  border-radius: 10px;
  border: none;
  font-size: 14px;
  backdrop-filter: blur(20px);
  background: rgba(30, 30, 44, 0.6);
  color: #fff;
}

textarea {
  resize: none;
}

button#send-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
}

button#send-btn ion-icon {
  margin-top: 10px;
  font-size: 26px;
  color: #fff;
  transition: transform 0.3s ease;
}

button#send-btn ion-icon:hover {
  transform: scale(1.08);
  color: var(--hover);
}

/* Chat Icon Behavior */
#chat-popup.active + #chat-icon {
  display: none;
}

ul {
  list-style-type: none;
  padding: 0;
}

li {
  background: rgba(30, 30, 44, 0.6);
  margin-bottom: 5px;
  padding: 10px;
  border-radius: 5px;
  text-align: left;
}

.name {
  font-size: 120%;
  font-weight: bold;
  color: var(--primary);
}

.timestamp {
  font-size: 80%;
  float: right;
}

/* Responsive Design */
@media (max-width: 768px) {
  #chat-popup {
    width: 90%;
    bottom: 10px;
    right: 10px;
  }

  #chat-icon {
    width: 50px;
    height: 50px;
    padding: 10px;
  }

  #chat-icon ion-icon {
    font-size: 25px;
  }

  input[type="text"], textarea {
    font-size: 12px;
  }

  .chat-header h2 {
    font-size: 1.6rem;
  }

  button#send-btn ion-icon {
    font-size: 22px;
  }

  .chat-output {
    max-height: 50rem;
    height: 30vw;
  }
}

@media (max-width: 480px) {
  #chat-popup {
    width: 90%;
    justify-content: center;
    max-width: none;
    padding: 15px;
  }

  #chat-icon {
    width: 45px;
    height: 45px;
    padding: 8px;
  }

  #chat-icon ion-icon {
    font-size: 22px;
  }

  input[type="text"], textarea {
    font-size: 11px;
  }

  .chat-header h2 {
    font-size: 1.4rem;
  }

  button#send-btn ion-icon {
    font-size: 20px;
  }

  .chat-output {
    height: 60vw;
  }
}

/* hero section */
.hero {
  min-width: 100%;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  align-content: center;
  padding: 0 5%;
  margin-top: 6rem;
  gap: 5%;
}

.hero .content {
  max-width: 46rem;
  padding: 1.8rem;
  padding-top: 4rem;
}

.homeimg img {
  width: 36vw;
  max-width: 48rem;
  min-width: 460px;
  padding: 1.2rem;
  padding-top: 2.4rem;
  -webkit-animation: shake-vertical 15s linear infinite both;
  animation: shake-vertical 15s linear infinite both;
}

@-webkit-keyframes shake-vertical {
  0%,
  100% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
  }
  10%,
  30%,
  50%,
  70% {
    -webkit-transform: translateY(-8px);
    transform: translateY(-8px);
  }
  20%,
  40%,
  60% {
    -webkit-transform: translateY(8px);
    transform: translateY(8px);
  }
  80% {
    -webkit-transform: translateY(6.4px);
    transform: translateY(6.4px);
  }
  90% {
    -webkit-transform: translateY(-6.4px);
    transform: translateY(-6.4px);
  }
}
@keyframes shake-vertical {
  0%,
  100% {
    -webkit-transform: translateY(0);
    transform: translateY(0);
  }
  10%,
  30%,
  50%,
  70% {
    -webkit-transform: translateY(-8px);
    transform: translateY(-8px);
  }
  20%,
  40%,
  60% {
    -webkit-transform: translateY(8px);
    transform: translateY(8px);
  }
  80% {
    -webkit-transform: translateY(6.4px);
    transform: translateY(6.4px);
  }
  90% {
    -webkit-transform: translateY(-6.4px);
    transform: translateY(-6.4px);
  }
}

.hero .content h1 {
  font-size: clamp(4rem, 8vw, 5rem);
  color: var(--text);
  text-shadow: 1px 1px 3px rgba(1, 1, 3, 0.5);
  line-height: 1.1;
  pointer-events: none;
}

.hero .content h1 {
  -webkit-animation: slide-in-blurred-tl 0.6s cubic-bezier(0.23, 1, 0.32, 1)
    both;
  animation: slide-in-blurred-tl 0.6s cubic-bezier(0.23, 1, 0.32, 1) both;
}

@-webkit-keyframes slide-in-blurred-tl {
  0% {
    -webkit-transform: translate(-1000px, -1000px) skew(80deg, 10deg);
    transform: translate(-1000px, -1000px) skew(80deg, 10deg);
    -webkit-transform-origin: 100% 0%;
    transform-origin: 100% 0%;
    -webkit-filter: blur(40px);
    filter: blur(40px);
    opacity: 0;
  }
  100% {
    -webkit-transform: translate(0, 0) skew(0deg, 0deg);
    transform: translate(0, 0) skew(0deg, 0deg);
    -webkit-transform-origin: 50% 50%;
    transform-origin: 50% 50%;
    -webkit-filter: blur(0);
    filter: blur(0);
    opacity: 1;
  }
}
@keyframes slide-in-blurred-tl {
  0% {
    -webkit-transform: translate(-1000px, -1000px) skew(80deg, 10deg);
    transform: translate(-1000px, -1000px) skew(80deg, 10deg);
    -webkit-transform-origin: 100% 0%;
    transform-origin: 100% 0%;
    -webkit-filter: blur(40px);
    filter: blur(40px);
    opacity: 0;
  }
  100% {
    -webkit-transform: translate(0, 0) skew(0deg, 0deg);
    transform: translate(0, 0) skew(0deg, 0deg);
    -webkit-transform-origin: 50% 50%;
    transform-origin: 50% 50%;
    -webkit-filter: blur(0);
    filter: blur(0);
    opacity: 1;
  }
}

.hero .content .button {
  -webkit-animation: slide-in-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94)
    both;
  animation: slide-in-left 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94) both;
}

@-webkit-keyframes slide-in-left {
  0% {
    -webkit-transform: translateX(-1000px);
    transform: translateX(-1000px);
    opacity: 0;
  }
  100% {
    -webkit-transform: translateX(0);
    transform: translateX(0);
    opacity: 1;
  }
}
@keyframes slide-in-left {
  0% {
    -webkit-transform: translateX(-1000px);
    transform: translateX(-1000px);
    opacity: 0;
  }
  100% {
    -webkit-transform: translateX(0);
    transform: translateX(0);
    opacity: 1;
  }
}

.hero .content .button {
  margin-top: 1rem;
  display: inline-block;
  padding: 1rem 3rem;
  font-size: 1.4rem;
  color: var(--text);
  font-weight: 700;
  background: var(--bg);
  background: rgba(58, 63, 92, 0.2); /* Semi-transparent primary color */
  border-radius: 0.5rem;
  backdrop-filter: blur(4px); /* Apply blur to background */
  -webkit-backdrop-filter: blur(10px); /* Support for Safari */
  transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth transition */
  border: 2px solid var(--primary) /* Optional: Add a border with a more visible primary color */
}

.hero .content .button:hover {
  transform: scale(1.02);
  background: rgba(13, 185, 215, 0.2);
  box-shadow: 0 4px 15px rgba(13, 185, 215, 0.5),
  0 0 10px rgba(13, 185, 215, 0.6); /* Glow yang halus */
}

/* Style untuk pop-up */
.popup {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  background: rgba(0, 0, 0, 0.5);
  visibility: hidden;
  opacity: 0;
  transition: visibility 0s, opacity 0.5s ease;
}

.popup-content {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  padding: 20px;
  border-radius: 10px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  text-align: center;
  width: 80%;
  max-width: 400px;
  color: var(--text);
  font-family: "Poppins", sans-serif;
}

.close-btn {
  background-color: var(--primary);
  border: none;
  color: var(--text);
  padding: 10px 20px;
  margin-top: 20px;
  border-radius: 10px;
  cursor: pointer;
  font-size: 16px;
}

.close-btn:hover {
  background-color: #ff6f61;
}

.popup.show {
  visibility: visible;
  opacity: 1;
}

/* Scrollbar kapsul dengan border-radius 50% dan tanpa segitiga di pojok */
::-webkit-scrollbar {
  width: 12px; /* Lebar scrollbar */
  height: 12px; /* Tinggi scrollbar */
  scroll-snap-type: proximity;
}

::-webkit-scrollbar-track {
  background-color: transparent; /* Latar belakang track scrollbar transparan */
}

::-webkit-scrollbar-thumb {
  background-color: rgba(
    255,
    255,
    255,
    0.2
  ); /* Warna scrollbar semi-transparan */
  border-radius: 50%; /* Border-radius 50% untuk bentuk bulat */
  border: 3px solid transparent; /* Membuat jarak agar tampak seperti kapsul */
  background-clip: padding-box; /* Menghindari warna scrollbar mengisi seluruh area */
}

::-webkit-scrollbar-thumb:hover {
  background-color: rgba(255, 255, 255, 0.8); /* Warna scrollbar saat dihover */
}

/* Menghilangkan segitiga di pojok scrollbar */
::-webkit-scrollbar-corner {
  background-color: transparent; /* Membuat sudut scrollbar transparan */
}

/* Untuk Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

*::-webkit-scrollbar-track-piece {
  background-color: transparent;
}

/* Memastikan scrollbar berbentuk bulat */
*::-webkit-scrollbar-thumb {
  border-radius: 50%; /* Membuat bentuk bulat pada scrollbar thumb */
}

/* aboute section */
.aboute {
  margin-top: 2rem;
  padding: 2rem 7% 1.4rem;
}

.aboute .row .aboute-img img {
  width: 100%;
  margin-bottom: 1rem;
  border-radius: 10px;
}

.aboute .row .content {
  flex: 1 1 35rem;
  padding: 0 1rem;
}

.aboute .row .content h3 {
  font-size: 1.8rem;
  color: var(--text);
  margin-bottom: 1rem;
}

.aboute .row .content p {
  margin-bottom: 0.8rem;
  font-size: 1.3rem;
  color: var(--text);
  font-weight: 300;
  line-height: 1.6;
}

.titlemaps {
  padding: 0 calc(7% + 1rem);
  margin-bottom: 0;
  margin-top: 1rem;
}

.titlemaps h3 {
  font-size: 1.8rem;
  color: var(--text);
}

.maps {
  display: flex;
  position: relative;
  justify-content: center;
  margin-bottom: 2rem;
  padding: 2rem 7% 1.4rem;
  width: 100%;
  height: 46rem;
}

.maps iframe {
  width: 100%;
  height: 100%;
  border-radius: 10px;
}

/* walisiswa Section */
#profile-section.profile-background {
  min-height: 100vh;
  width: 100%;
  /*   background-image: url('https://lh3.googleusercontent.com/pw/AP1GczMPmfj8iRcZg76hsUdtvEHQhUdnVqka3IvaFaLodH9TT_IxCOACCVM4pju-mc6pB8E7uPI6ZawfA-wX0Z8LC7jkZPNDVnazg50CkJbZupO2HbA0l5-npvMlDeFUhrQwOTvyaVw-a3r8ulZpswqkOkNc=w1623-h913-s-no-gm?authuser=0'); */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed; /* Background tetap saat scroll */
  padding: 4rem 2rem; /* Konsisten padding di seluruh section */
}

/* Heading style */
h2 {
  text-align: center;
  margin-bottom: 40px;
  padding-top: 5rem;
  font-size: 2.6rem; /* Konsistensi ukuran heading */
  color: var(--text);
  margin-left: auto;
  margin-right: auto; /* Tengah */
  max-width: 800px; /* Batasi lebar teks heading */
}

h2 {
  -webkit-animation: tracking-in-expand 0.7s cubic-bezier(0.215, 0.610, 0.355, 1.000) both;
	        animation: tracking-in-expand 0.7s cubic-bezier(0.215, 0.610, 0.355, 1.000) both;
}

@-webkit-keyframes tracking-in-expand {
  0% {
    letter-spacing: -0.5em;
    opacity: 0;
  }
  40% {
    opacity: 0.6;
  }
  100% {
    opacity: 1;
  }
}
@keyframes tracking-in-expand {
  0% {
    letter-spacing: -0.5em;
    opacity: 0;
  }
  40% {
    opacity: 0.6;
  }
  100% {
    opacity: 1;
  }
}

h2 span {
  color: var(--primary); /* Warna utama untuk highlight */
}

/* Card styles */
.card {
  background: rgba(58, 63, 92, 0.2); /* More transparency */
  backdrop-filter: blur(10px);
  border-radius: 15px;
  overflow: hidden;
  text-align: center;
  padding: 30px 20px; /* Konsisten padding dalam card */
  margin: 20px; /* Konsisten jarak antar card */
  cursor: pointer;
  transition: transform 0.3s ease, box-shadow 0.3s ease; /* Smooth transition */
  position: relative;
  border: 2px solid var(--primary); /* Optional: Add a border with a more visible primary color */
}

.card:hover {
  box-shadow: 0 4px 15px rgba(13, 185, 215, 0.5),
    0 0 10px rgba(13, 185, 215, 0.6); /* Glow yang halus */
}

.profile-pic {
  width: 8rem;
  height: 8rem;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 15px;
}

.teacher-card {
  max-width: 300px;
  margin: 0 auto 40px auto; /* Tengah dan jarak bawah */
}

/* Modal background */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7); /* Background semi-transparan */
  display: flex;
  justify-content: center;
  align-items: center; /* Memastikan modal selalu di tengah secara vertikal dan horizontal */
}

/* Modal content styled like a card */
.modal-content.card-style {
  background: rgba(255, 255, 255, 0.2);
  backdrop-filter: blur(10px);
  border-radius: 15px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  padding: 30px;
  width: 90%; /* Mengurangi lebar modal pada perangkat kecil */
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  display: flex; /* Flexbox untuk tata letak gambar dan teks */
  align-items: center;
  margin-top: auto; /* Auto margin untuk memusatkan secara vertikal */
  margin-bottom: auto;
}

/* Profile picture inside modal */
.modal-content .profile-pic {
  width: 6rem;
  height: 6rem;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 20px; /* Jarak antara foto dan detail */
}

/* Details inside modal */
#modal-details {
  flex-grow: 1;
  text-align: left; /* Detail teks rata kiri */
}

#modal-details p {
  margin: 5px 0;
  color: white;
}

#modal-details h3 {
  color: var(--primary);
  margin-bottom: 10px;
}

/* Menyesuaikan modal pada perangkat mobile */
@media only screen and (max-width: 600px) {
  .modal-content.card-style {
    flex-direction: column; /* Gambar dan detail vertikal pada perangkat kecil */
    align-items: flex-start; /* Rata kiri untuk elemen */
    padding: 20px;
  }

  .modal-content .profile-pic {
    margin-bottom: 20px; /* Beri jarak bawah pada gambar di perangkat kecil */
    margin-right: 0;
  }

  #modal-details {
    text-align: left; /* Pastikan teks rata kiri pada mobile */
  }
}


/* Responsive grid layout */
.student-cards {
  display: grid;
  grid-template-columns: repeat(1, 1fr);
  gap: 20px; /* Konsisten jarak antar elemen grid */
  margin-left: 4rem; /* Konsisten padding kiri */
  margin-right: 4rem; /* Konsisten padding kanan */
}

@media (min-width: 768px) {
  .student-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 1024px) {
  .student-cards {
    grid-template-columns: repeat(4, 1fr);
    margin-left: 6rem; /* Konsisten margin pada resolusi besar */
    margin-right: 6rem; /* Konsisten margin pada resolusi besar */
  }
}

/* Card text styles */
.card h3 {
  margin: 10px 0;
  font-size: 1.2em;
  color: var(--text); /* Konsistensi warna teks */
}

.card p {
  margin: 5px 0;
  font-size: 0.9em;
  color: var(--text); /* Konsistensi warna teks sekunder */
}

/* Detail section */
.details {
  margin-top: 10px;
  display: none;
  text-align: left;
}

.details p {
  margin: 5px 0;
}

.details a {
  margin-right: 5px;
  color: var(--primary); /* Konsistensi warna link */
  text-decoration: none;
}

.details a:hover {
  text-decoration: underline;
}

/* Icon styles */
.ion-icon {
  font-size: var(--icon-size); /* Konsistensi ukuran ikon */
  color: var(--text); /* Konsistensi warna ikon */
}

/* Responsive adjustments for mobile */
@media (max-width: 768px) {
  html {
    font-size: 62.5%;
  }

  .student-cards {
    margin-left: 2rem;
    margin-right: 2rem;
  }
}

@media (max-width: 450px) {
  html {
    font-size: 55%;
    padding: 0 1rem; /* Konsistensi margin pada perangkat kecil */
  }
}

/* Galeri Awal */
.gallery-title {
  margin-top: 4rem;
}

.month-title {
  font-weight: 500;
  font-size: 2rem;
  margin: 20px;
}

.month-title:hover {
  cursor: default;
  color: var(--hover);
}

.gallery {
  display: flex;
  overflow-x: auto; /* Scroll secara horizontal */
  gap: 20px; /* Jarak default antar gambar */
  padding: 10px;
}

.gallery-row {
  position: relative;
  margin: 32px;
}

.gallery-item {
  position: relative;
  width: 18rem; /* Ukuran default lebar gambar */
  height: 18rem; /* Ukuran default tinggi gambar */
  flex-shrink: 0; /* Agar item tidak mengecil saat di-hover */
  transition: transform 0.3s ease;
}

.gallery-item:hover {
  z-index: 10;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* Menjaga rasio 1:1 sebelum hover */
  border-radius: 10px;
  transition: transform 0.3s ease-in-out, width 0.3s ease-in-out,
    height 0.3s ease-in-out;
}

.gallery-item img:hover {
  transform: scale(1.06); /* Sedikit memperbesar gambar */
  box-shadow: 0 0 0.8rem 0 rgba(13, 185, 215, 0.2);
}

/* Style untuk modal */
.modal {
  display: none; /* Modal disembunyikan secara default */
  position: fixed;
  z-index: 10;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  padding-top: 100px;
  overflow: auto;
  background-color: rgba(27, 28, 30, 0.8); /* Background semi-transparan */
}

/* Gambar modal */
.modal-content {
  margin: auto;
  display: block;
  max-width: 90%;
  max-height: 90%;
  border-radius: 10px;
}

/* Style untuk tombol close */
.close {
  position: absolute;
  top: 78px;
  right: 24px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
}

.close:hover {
  color: var(--hover);
}

/* Caption untuk gambar */
#caption {
  margin: 15px auto;
  text-align: center;
  color: #ccc;
  font-size: 18px;
}

/* Style untuk tombol "Sebelumnya" dan "Selanjutnya" */
.prev,
.next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  padding: 16px;
  margin-top: -22px;
  color: white;
  font-weight: bold;
  font-size: 20px;
  transition: 0.6s ease;
  border-radius: 0 3px 3px 0;
  user-select: none;
}

.next {
  right: 0;
  border-radius: 3px 0 0 3px;
}

.prev {
  left: 0;
  border-radius: 3px 0 0 3px;
}

.prev:hover,
.next:hover {
  color: var(--hover);
}
/* Galeri Akhir */

/* media queries */

/* laptop */
@media (max-width: 1366px) {
  html {
    font-size: 75%;
  }
  .homeimg img {
    min-width: 460px;
  }
}

/* tablet */
@media (max-width: 768px) {
  html {
    font-size: 62.5%;
  }

  .hero .content {
    text-align: center;
  }

  .hero {
    display: flex;
    flex-direction: column; /* Elemen disusun vertikal */
    justify-content: center; /* Pusatkan elemen secara vertikal */
    align-items: center; /* Pusatkan elemen secara horizontal */
    height: 100vh; /* Tinggi penuh layar */
  }

  .homeimg img {
    min-width: 420px;
  }

  #hamburger-menu {
    display: inline-block;
  }

  .navbar .navbar-nav {
    position: absolute;
    top: 100%;
    right: -100%;
    background: rgba(58, 63, 92, 0.8);
    border: 2px solid rgba(255, 255, 255, 0.18);
    backdrop-filter: blur(1000px); /* Apply blur for glassmorphism effect */
    -webkit-backdrop-filter: blur(10px); /* Support for Safari */
    width: 28rem;
    height: 100vh;
    transition: right 0.3s;
    z-index: 1000;
  }

  .navbar .navbar-nav.active {
    right: 0;
  }

  .navbar .navbar-nav a {
    color: var(--text);
    display: flexbox;
    margin: 1rem;
    padding: 0.6rem;
    font-size: 2rem;
  }

  .navbar .navbar-nav a::after {
    transform-origin: 0 0;
  }

  .navbar .navbar-nav a:hover::after {
    transform: scaleX(1);
  }
}

/* mobile */
@media (max-width: 450px) {
  html {
    font-size: 55%;
  }
  .homeimg img {
    min-width: 300px;
  }
}