/* =================================
  Kegiatan Disjas
  ================================= */
.disjas {
  max-width: 1200px;
  margin: 0 auto;
  padding: 50px 8% 20px 8%;
}

/* Responsive disjas untuk layar besar */
@media (min-width: 1400px) {
  .disjas {
    max-width: 1400px;
  }
}

@media (min-width: 1600px) {
  .disjas {
    max-width: 1600px;
  }
}

@media (min-width: 1920px) {
  .disjas {
    max-width: 1800px;
  }
}

.activity-container {
  margin-bottom: 10px;
}

.row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  background-color: #fff;
  border-radius: 20px;
  padding: 20px 20px 0 20px;
}

.col {
  flex: 1;
  min-width: 300px;
}

.image-col {
  display: flex;
  justify-content: center;
  align-items: center;
}

.image-col img {
  width: 70%;
  max-width: 500px;
  height: auto;
  border-radius: 15px;
}

.content-col {
  display: flex;
  justify-content: center;
  align-items: center;
}

.activity-container h2 {
  font-size: clamp(1.3rem, 1.7vw, 1.9rem);
  color: #003366;
  font-weight: 700;
  text-align: left;
  margin-bottom: 15px;
}

.activity-container p {
  font-size: clamp(0.8rem, 1.1vw, 1.1rem);
  color: #555;
  line-height: 1.7;
  text-align: justify;
  margin: 10px 0;
}

/* Responsive Kegiatan */
@media (max-width: 992px) {
  .row {
    flex-direction: column;
    text-align: center;
  }

  .activity-container h2 {
    text-align: center;
  }

  .image-col img {
    max-width: 90%;
  }
}

@media (max-width: 576px) {
  .activity-container h2 {
    font-size: 1.4rem;
  }

  .activity-container p {
    font-size: 0.9rem;
  }

  .row {
    padding: 20px;
  }
}

/* =================================
  Pilar
================================= */
.card-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px 8%;
  text-align: center;
}

.section-title {
  font-size: 1.8rem;
  color: #003366;
  font-weight: 700;
  position: relative;
  display: inline-block;
  margin-bottom: 10px;
}

.section-subtitle {
  color: #666;
  font-size: 1rem;
  margin-bottom: 10px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 20px;
}

.card-item {
  background: white;
  padding: 20px;
  border-radius: 15px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  max-width: 260px;
  margin: 0 auto;
}

.card-item:hover {
  transform: translateY(-8px);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.15);
}

.card-item img {
  width: 150px;
  height: 150px;
  object-fit: contain;
  transition: filter 0.3s ease;
}

.card-item:hover img {
  filter: brightness(80%);
}

.card-item p {
  color: #666;
  font-size: 0.9rem;
  margin: 10px 0 15px 0;
}

.card-btn {
  background: linear-gradient(90deg, #0056b3, #0073e6);
  color: #fff;
  border: none;
  border-radius: 25px;
  padding: 8px 20px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
}
.card-btn:hover {
  background: linear-gradient(90deg, #0073e6, #00aaff);
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 115, 230, 0.3);
}

/* =================================
      Pilar section (CSS utama)
    ================================== */
:root {
  --orange: #f78b1f;
  --darkorange: #e27610;
  --white: #fff;
  --thumb: #eee;
}

/* wrapper scroll horizontal */
.cards-scroll {
  display: flex;
  gap: 16px; /* gunakan gap yang konsisten */
  overflow-x: auto;
  padding: 14px 0;
  scroll-behavior: smooth;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  align-items: flex-start; /* agar isi rata atas */
}

.cards-scroll::-webkit-scrollbar {
  height: 10px;
}
.cards-scroll::-webkit-scrollbar-thumb {
  background: var(--darkorange);
  border-radius: 999px;
}
.cards-scroll::-webkit-scrollbar-track {
  background: var(--thumb);
  border-radius: 999px;
}

/* Card dasar (desktop) */
.card {
  flex: 0 0 320px; /* fallback desktop */
  background: var(--white);
  border-radius: 16px;
  box-shadow: 0 6px 20px rgba(4, 20, 30, 0.08);
  padding: 20px;
  scroll-snap-align: start;
  text-align: center;
  min-height: 240px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: transform 0.3s ease, background 0.3s ease;
}

.card:hover {
  transform: translateY(-5px);
  background: linear-gradient(135deg, #ff7a00, #ffb347);
  transition: all 0.3s ease;
}

.card:hover h2 {
  color: #fff;
}

/* Konten kartu */
.card-content {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card-title {
  font-size: 0.9rem;
  margin-bottom: 12px;
  font-weight: 600;
  color: #073049;
}

.card img {
  width: 88px;
  height: auto;
  margin: 6px auto 14px;
  display: block;
}

.card:hover img {
  transform: scale(1.05);
}

.card .card-link {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 12px;
  background: var(--orange);
  color: white;
  text-decoration: none;
  font-weight: 600;
  margin-top: 8px;
}

.card:hover .card-link {
  background: var(--darkorange);
}

.scroll-btn {
  background: linear-gradient(90deg, #ff7a00, #ffae42);
  color: #fff;
  border: none;
  border-radius: 25px;
  padding: 8px 20px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px;
}

.scroll-btn:hover {
  background: linear-gradient(90deg, #ffae42, #ffd580);
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(255, 165, 0, 0.3);
}

/* =============================
  RESPONSIVE: pastikan 2 card pas
============================= */

/* Untuk tablet / mobile besar: paksa 2 kartu penuh */
@media (max-width: 768px) {
  .cards-scroll {
    gap: 14px;
    padding: 12px 0;
  }
  .card {
    flex: 0 0 calc((100% - 14px) / 2);
    min-height: 220px;
    padding: 18px;
  }
  .card img {
    width: 84px;
  }
  .card-title {
    font-size: 1rem;
  }
}

/* Untuk layar sangat kecil: tetap 2 kartu utuh, kecilkan gap & padding container */
@media (max-width: 420px) {
  .cards-container {
    padding: 20px 8%;
  } /* kurangi padding luar agar ruang lebih lebar */
  .cards-scroll {
    gap: 10px;
    padding: 10px 0;
  }
  .card {
    flex: 0 0 calc((100% - 10px) / 2);
    min-height: 200px;
    padding: 14px;
    border-radius: 14px;
  }
  .card img {
    width: 72px;
  }
  .card-title {
    font-size: 0.98rem;
  }
}
/* =================================
  Laporan
================================= */
.laporan {
  padding-bottom: 40px;
}

/* =================================
  Arsip Section
================================= */
.arsip-section {
  max-width: 1230px;
  margin: 0 auto;
  padding: 30px 8%;
}

.arsip-section h1 {
  font-size: 1.8rem;
  color: #003366;
  font-weight: 700;
  margin-bottom: 20px;
  text-align: center;
}

.arsip-header {
  text-align: center;
  margin-bottom: 40px;
}
.arsip-title {
  font-size: 2rem;
  color: #003366;
  margin-bottom: 10px;
}
.arsip-subtitle {
  color: #555;
  font-size: 1rem;
} /* ============================== KARTU KHUSUS ============================== */
.arsip-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 30px;
  position: relative;
  z-index: 1;
}
.arsip-card {
  background: white;
  border-radius: 20px;
  padding: 25px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-left-color 0.3s ease, z-index 0s;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-left: 5px solid #003366;
  position: relative;
  overflow: visible;
  will-change: transform;
  z-index: 1;
}
.arsip-card:has(.dropdown-content.show) {
  z-index: 999 !important; /* Card dengan dropdown aktif di atas semua */
}
.arsip-card:hover {
  box-shadow: 0 20px 45px rgba(0, 0, 0, 0.15);
  border-left-color: #ff6600;
}

.arsip-card img {
  width: 100px;
  height: 100px;
  border-radius: 15px;
  padding: 12px;
  flex-shrink: 0;
}
.arsip-card-info {
  flex: 1;
}
.arsip-card-info a {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  color: #003366;
  text-decoration: none;
  margin-bottom: 6px;
  transition: color 0.3s ease;
  pointer-events: none; /* agar link tidak bisa diklik */
}

.arsip-desc {
  font-size: 0.6rem;
  color: #555;
  margin: 0;
  padding-right: 50px;
} /* ============================== DROPDOWN ============================== */

.arsip-card .dropdown {
  position: absolute;
  top: 60px;
  right: 10px;
  z-index: 10;
}

.arsip-card .dropdown-toggle {
  background: rgba(0, 102, 255, 0.1);
  border: 2px solid rgba(0, 102, 255, 0.2);
  border-radius: 50%;
  width: 45px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  margin-left: 10px;
}

.arsip-card .dropdown-toggle:hover {
  background: rgba(255, 102, 0, 0.1);
  border: 2px solid rgba(255, 102, 0, 0.2);
}

.arsip-card .dropdown-toggle i {
  transition: transform 0.3s ease;
}

.arsip-card .dropdown-toggle.active i {
  transform: rotate(180deg);
}

/* menu tersembunyi default */
.arsip-card .dropdown-content {
  position: absolute;
  top: 50px;
  right: 0;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  border: 1px solid rgba(0, 0, 0, 0.05);
  min-width: 220px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: opacity 0.3s ease, transform 0.3s ease, visibility 0.3s ease;
  z-index: 1000;
}

.arsip-card .dropdown-content.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.arsip-card .dropdown-content a {
  display: block;
  padding: 10px 15px;
  text-align: left;
  color: #333;
  text-decoration: none;
  font-size: 0.9rem;
  transition: background 0.2s ease;
}

.arsip-card .dropdown-content a:first-child {
  border-radius: 10px 10px 0 0;
}

.arsip-card .dropdown-content a:last-child {
  border-radius: 0 0 10px 10px;
}

.arsip-card .dropdown-content a:hover {
  background: #f0f0f0;
}

/* Hilangkan elemen ::after dari dropdown-toggle */
.dropdown-toggle::after {
  content: none !important;
  border: none !important;
}

/* ------------------------------------------- */
/* MEDIA QUERY untuk Responsif (Layar Kecil/Mobile) */
/* ------------------------------------------- */

@media (max-width: 650px) {
  .arsip-section {
    padding: 20px 5%; /* Padding yang lebih kecil untuk layar sempit */
  }

  .arsip-grid {
    /* Perubahan Kunci: Di layar < 650px, setiap kartu mengambil lebar penuh. */
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .arsip-card {
    /* Memastikan arsip-card mengambil lebar penuh dari grid 1fr */
    width: 100%;
    padding: 20px; /* Padding sedikit lebih kecil */
  }

  .arsip-card img {
    width: 80px;
    height: 80px;
  }

  .arsip-card-info a,
  .arsip-desc {
    padding-right: 40px; /* Jaga jarak dengan tombol dropdown */
  }

  .arsip-card .dropdown {
    /* Posisi dropdown bisa disesuaikan lagi untuk layar kecil */
    top: 50px;
    right: 5px;
  }

  .arsip-card .dropdown-toggle {
    width: 38px;
    height: 38px;
  }
}

/* =================================
  RESPONSIVE DESIGN UNTUK LAYAR BESAR
================================= */

/* Layar Desktop Besar (1400px - 1599px) */
@media (min-width: 1400px) {
  .disjas {
    max-width: 1400px;
  }

  .activity-container h2 {
    font-size: clamp(1.5rem, 1.9vw, 1.9rem);
  }

  .activity-container p {
    font-size: clamp(0.8rem, 1.1vw, 1.1rem);
  }

  .image-col img {
    max-width: clamp(500px, 35vw, 600px);
  }

  .card-section {
    max-width: 1400px;
  }

  .section-title {
    font-size: clamp(1.8rem, 2.2vw, 2.2rem);
  }

  .card-item {
    max-width: clamp(260px, 18vw, 300px);
  }

  .card-item img {
    width: clamp(150px, 11vw, 180px);
    height: clamp(150px, 11vw, 180px);
  }
}

/* Layar Desktop Sangat Besar (1600px - 1919px) */
@media (min-width: 1600px) {
  .disjas {
    max-width: 1600px;
  }

  .activity-container h2 {
    font-size: clamp(1.9rem, 2.2vw, 2.2rem);
  }

  .image-col img {
    max-width: clamp(600px, 40vw, 700px);
  }

  .card-section {
    max-width: 1600px;
  }

  .card-item {
    max-width: clamp(300px, 20vw, 350px);
  }
}

/* Layar Ultra Wide (1920px+) */
@media (min-width: 1920px) {
  .disjas {
    max-width: 1800px;
  }

  .activity-container h2 {
    font-size: clamp(2.2rem, 2.5vw, 2.5rem);
  }

  .image-col img {
    max-width: clamp(700px, 45vw, 800px);
  }

  .card-section {
    max-width: 1800px;
  }

  .card-item {
    max-width: clamp(350px, 22vw, 400px);
  }
}