:root {
  --primary-dark: #0F6B3A;
  --primary-light: #28A745;
  --white: #FFFFFF;
  --gold: #FFD700;
  --text-dark: #102018;
  --bg-light: #f3f9f5;
  --glass-bg: rgba(255, 255, 255, 0.2);
  --glass-border: rgba(255, 255, 255, 0.45);
  --shadow-soft: 0 10px 30px rgba(15, 107, 58, 0.18);
  --shadow-hover: 0 16px 35px rgba(15, 107, 58, 0.28);
  --transition: all 0.35s ease;
}

/* Dark mode variables */
body.dark-mode {
  --text-dark: #e8f5ed;
  --bg-light: #0b1e14;
  --glass-bg: rgba(15, 107, 58, 0.28);
  --glass-border: rgba(112, 214, 151, 0.38);
  --shadow-soft: 0 12px 32px rgba(0, 0, 0, 0.35);
  --shadow-hover: 0 18px 40px rgba(0, 0, 0, 0.45);
}

/* Global reset */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Poppins', sans-serif;
  background: linear-gradient(165deg, #f2fff6, var(--bg-light));
  color: var(--text-dark);
  line-height: 1.65;
  overflow-x: hidden;
}

body.menu-open,
body.modal-open {
  overflow: hidden;
  touch-action: none;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  width: min(1150px, 92%);
  margin: 0 auto;
}

.section {
  padding: 6rem 0;
}

.section.reveal {
  content-visibility: visible;
}

.section-alt {
  background: linear-gradient(145deg, rgba(15, 107, 58, 0.06), rgba(40, 167, 69, 0.08));
}

/* Loading screen */
#loading-screen {
  position: fixed;
  inset: 0;
  background: linear-gradient(135deg, var(--primary-dark), var(--primary-light));
  display: grid;
  place-items: center;
  z-index: 2000;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

#loading-screen.hide {
  opacity: 0;
  visibility: hidden;
}

.loader-content {
  text-align: center;
  color: var(--white);
}

.spinner {
  width: 62px;
  height: 62px;
  margin: 0 auto 1rem;
  border: 5px solid rgba(255, 255, 255, 0.3);
  border-top: 5px solid var(--gold);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Header & navbar */
.header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(12px);
  background: rgba(15, 107, 58, 0.12);
  border-bottom: 1px solid rgba(255, 255, 255, 0.35);
  transition: var(--transition);
}

.header.scrolled {
  background: rgba(15, 107, 58, 0.9);
  box-shadow: var(--shadow-soft);
}

.navbar {
  min-height: 78px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  color: var(--white);
}

.logo-img {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: contain;
  flex-shrink: 0;
  box-shadow: var(--shadow-soft);
  background: #fff;
}

.logo-text h1 {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.2;
}

.logo-text p {
  font-size: 0.72rem;
  opacity: 0.9;
}

.nav-menu {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 1.2rem;
}

.nav-menu a {
  color: var(--white);
  font-size: 0.92rem;
  font-weight: 500;
  position: relative;
}

.nav-menu a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -4px;
  width: 0;
  height: 2px;
  background: var(--gold);
  transition: var(--transition);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
  width: 100%;
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
  color: var(--white);
  cursor: pointer;
  transition: var(--transition);
}

.icon-btn:hover {
  transform: translateY(-2px);
  background: var(--gold);
  color: var(--primary-dark);
}

.hamburger {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  cursor: pointer;
  padding: 8px;
}

.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  margin: 5px 0;
  background: var(--white);
  transition: 0.3s;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
  opacity: 0;
}

.hamburger.active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Hero section */
.hero {
  position: relative;
  min-height: 90vh;
  display: flex;
  align-items: center;
  background: url('img/IMG_20260511_132322.jpg') center/cover no-repeat;
  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(120deg, rgba(15, 107, 58, 0.85), rgba(40, 167, 69, 0.45));
}

.hero-content {
  position: relative;
  z-index: 1;
  color: var(--white);
  animation: fadeInHero 1.2s ease;
}

@keyframes fadeInHero {
  from {
    opacity: 0;
    transform: translateY(22px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.hero-tag {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 20px;
  font-size: 0.8rem;
  margin-bottom: 1rem;
  background: rgba(255, 255, 255, 0.12);
}

.hero h2 {
  font-size: clamp(1.6rem, 3.6vw, 3rem);
  max-width: 800px;
  line-height: 1.3;
}

.hero h2 span {
  color: var(--gold);
}

.typing-wrap {
  margin-top: 1rem;
  font-size: 1.05rem;
  min-height: 32px;
}

.typing-label {
  font-weight: 600;
  color: #fff6b2;
}

#typingText {
  font-weight: 500;
  border-right: 2px solid var(--gold);
  padding-right: 4px;
  margin-left: 6px;
}

.hero-subtitle {
  margin: 1rem 0 1.8rem;
  max-width: 650px;
  font-size: 1.04rem;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Shared cards and buttons */
.glass-card {
  background: var(--glass-bg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--glass-border);
  border-radius: 16px;
  box-shadow: var(--shadow-soft);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .glass-card {
    background: rgba(255, 255, 255, 0.92);
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: none;
  cursor: pointer;
  transition: var(--transition);
  font-weight: 600;
  border-radius: 12px;
  padding: 0.72rem 1.3rem;
}

.btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
}

.btn-primary {
  background: linear-gradient(135deg, var(--gold), #ffea7f);
  color: #2b2b2b;
}

.btn-outline {
  border: 1px solid rgba(255, 255, 255, 0.65);
  color: var(--white);
  background: rgba(255, 255, 255, 0.1);
}

.btn-small {
  padding: 0.55rem 1rem;
  font-size: 0.84rem;
  margin-top: 0.6rem;
  background: var(--primary-dark);
  color: var(--white);
}

.btn-small:hover {
  background: var(--primary-light);
}

.section-title {
  text-align: center;
  margin-bottom: 2.4rem;
}

.section-title h3 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--primary-dark);
}

.section-title p {
  margin-top: 0.4rem;
  color: #2f3e35;
}

body.dark-mode .section-title h3,
body.dark-mode .section-title p {
  color: #ddf6e6;
}

/* Profile section */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.profile-card {
  padding: 1.3rem;
  transition: var(--transition);
}

.profile-card i {
  font-size: 1.6rem;
  color: var(--primary-dark);
  margin-bottom: 0.6rem;
}

.profile-card h4 {
  margin-bottom: 0.45rem;
}

.profile-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

/* Management cards */
.management-structure {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.management-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.1rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid rgba(15, 107, 58, 0.15);
}

body.dark-mode .management-group-header {
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.management-group-header h4 {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.1rem;
  color: var(--primary-dark);
}

body.dark-mode .management-group-header h4 {
  color: #ddf6e6;
}

.management-group-header h4 i {
  font-size: 0.95rem;
  color: var(--primary-light);
}

.management-count {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary-dark);
  background: rgba(15, 107, 58, 0.1);
  border-radius: 999px;
  padding: 0.3rem 0.75rem;
  white-space: nowrap;
}

body.dark-mode .management-count {
  color: #c5e8d3;
  background: rgba(255, 255, 255, 0.08);
}

.management-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}

.management-grid--inti {
  grid-template-columns: repeat(4, minmax(200px, 1fr));
  max-width: 100%;
  margin: 0 auto;
}

.management-grid--leadership {
  display: grid;
  grid-template-columns: repeat(2, minmax(260px, 320px));
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 0.5rem;
  padding-bottom: 2rem;
  border-bottom: 2px solid rgba(15, 107, 58, 0.15);
}

body.dark-mode .management-grid--leadership {
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.member-card--ketua,
.member-card--wakil {
  border-color: rgba(255, 215, 0, 0.55);
  background: linear-gradient(180deg, rgba(255, 215, 0, 0.1), var(--white) 45%);
  box-shadow: 0 14px 36px rgba(15, 107, 58, 0.2);
}

body.dark-mode .member-card--ketua,
body.dark-mode .member-card--wakil {
  background: linear-gradient(180deg, rgba(255, 215, 0, 0.12), #123624 45%);
  border-color: rgba(255, 215, 0, 0.4);
}

.member-card--ketua .member-card-photo,
.member-card--wakil .member-card-photo {
  height: 280px;
}

.member-card--ketua .member-info h4,
.member-card--wakil .member-info h4 {
  font-size: 1.08rem;
}

.member-card--ketua .member-info h5,
.member-card--wakil .member-info h5 {
  font-size: 0.95rem;
  font-weight: 700;
}

.member-card--inti {
  border-color: rgba(255, 215, 0, 0.45);
  background: linear-gradient(180deg, rgba(255, 215, 0, 0.06), var(--white) 40%);
}

.member-card {
  background: var(--white);
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(15, 107, 58, 0.2);
  box-shadow: var(--shadow-soft);
  transition: var(--transition);
}

body.dark-mode .member-card {
  background: #123624;
}

body.dark-mode .member-card--inti {
  background: linear-gradient(180deg, rgba(255, 215, 0, 0.08), #123624 40%);
  border-color: rgba(255, 215, 0, 0.35);
}

.member-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.45s ease;
}

.member-card-photo {
  width: 100%;
  height: 240px;
  overflow: hidden;
  background: linear-gradient(145deg, rgba(15, 107, 58, 0.12), rgba(40, 167, 69, 0.08));
}

.member-info {
  padding: 1rem;
}

.member-info h5 {
  color: var(--primary-light);
  margin-bottom: 0.4rem;
}

.member-card:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: var(--shadow-hover);
  border-color: var(--gold);
}

.member-card:hover img {
  transform: scale(1.08);
}

/* Program section */
.program-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 1rem;
}

.program-card {
  padding: 1.2rem;
  transition: var(--transition);
}

.program-card i {
  font-size: 1.5rem;
  color: var(--primary-dark);
  margin-bottom: 0.75rem;
}

.program-card:hover {
  transform: translateY(-8px);
}

/* Gallery grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.25rem;
}

.gallery-card {
  position: relative;
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  background: var(--white);
  box-shadow: var(--shadow-soft);
  cursor: pointer;
  transition: var(--transition);
  border: 1px solid rgba(15, 107, 58, 0.1);
}

body.dark-mode .gallery-card {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.gallery-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-hover);
}

.gallery-card-image {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: rgba(15, 107, 58, 0.08);
}

.gallery-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.gallery-card:hover .gallery-card-image img {
  transform: scale(1.06);
}

.gallery-card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(15, 107, 58, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.35rem;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-card:hover .gallery-card-overlay {
  opacity: 1;
}

.gallery-card-caption {
  padding: 0.8rem 0.95rem;
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-dark);
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.gallery-card-badge {
  position: absolute;
  top: 0.7rem;
  left: 0.7rem;
  background: linear-gradient(140deg, var(--primary-dark), var(--primary-light));
  color: var(--white);
  font-size: 0.72rem;
  font-weight: 600;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  z-index: 1;
  max-width: calc(100% - 1.4rem);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.gallery-item-hidden {
  display: none;
}

.gallery-toolbar {
  margin-bottom: 1.75rem;
}

.gallery-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
  padding: 0.9rem 1rem;
  background: var(--white);
  border-radius: 14px;
  border: 1px solid rgba(15, 107, 58, 0.12);
  box-shadow: var(--shadow-soft);
}

body.dark-mode .gallery-filter {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(255, 255, 255, 0.1);
}

.gallery-filter-btn {
  border: 1px solid rgba(18, 94, 58, 0.18);
  background: transparent;
  color: var(--primary-dark);
  border-radius: 999px;
  padding: 0.42rem 1rem;
  font-size: 0.82rem;
  font-weight: 500;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.gallery-filter-btn:hover,
.gallery-filter-btn.active {
  background: linear-gradient(140deg, var(--primary-dark), var(--primary-light));
  color: var(--white);
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(15, 107, 58, 0.25);
}

body.dark-mode .gallery-filter-btn {
  color: #ddf6e6;
  border-color: rgba(255, 255, 255, 0.15);
}

.program-detail-layout {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.program-gallery {
  padding: 1.75rem;
}

.program-gallery-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.35rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(15, 107, 58, 0.12);
}

body.dark-mode .program-gallery-header {
  border-bottom-color: rgba(255, 255, 255, 0.1);
}

.program-gallery .section-title {
  margin-bottom: 0;
  text-align: left;
}

.program-gallery .section-title h3 {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  font-size: 1.25rem;
  color: var(--primary-dark);
}

.program-gallery .section-title h3 i {
  font-size: 1rem;
  opacity: 0.85;
}

.program-gallery .section-title p {
  margin-top: 0.35rem;
  font-size: 0.92rem;
}

body.dark-mode .program-gallery .section-title h3 {
  color: #ddf6e6;
}

.gallery-count {
  flex-shrink: 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary-dark);
  background: rgba(15, 107, 58, 0.1);
  border-radius: 999px;
  padding: 0.35rem 0.8rem;
}

body.dark-mode .gallery-count {
  color: #c5e8d3;
  background: rgba(255, 255, 255, 0.08);
}

/* Gallery modal */
.gallery-modal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1500;
}

.gallery-modal.show {
  display: flex;
  animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.gallery-modal img {
  width: min(90%, 900px);
  max-height: 82vh;
  object-fit: contain;
  border-radius: 12px;
}

.modal-close,
.modal-nav {
  position: absolute;
  border: none;
  color: var(--white);
  background: rgba(255, 255, 255, 0.2);
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.25rem;
}

.modal-close { top: 24px; right: 30px; }
.modal-nav.prev { left: 24px; }
.modal-nav.next { right: 24px; }

/* News section */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
}

.news-card {
  background: var(--white);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(15, 107, 58, 0.2);
  transition: var(--transition);
}

body.dark-mode .news-card {
  background: #123624;
}

.news-card img {
  height: 200px;
  width: 100%;
  object-fit: cover;
}

.news-body {
  padding: 1rem;
}

.news-body h4 {
  font-size: 1rem;
  margin-bottom: 0.55rem;
}

.news-meta {
  margin-top: 0.9rem;
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  align-items: center;
  flex-wrap: wrap;
  font-size: 0.85rem;
}

.news-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-hover);
}

/* Achievement carousel */
.achievement-carousel {
  position: relative;
  overflow: hidden;
  max-width: 900px;
  margin: 0 auto;
  min-height: 220px;
}

.achievement-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transform: translateX(20px);
  background: linear-gradient(140deg, var(--primary-dark), var(--primary-light));
  color: var(--white);
  border-radius: 16px;
  box-shadow: var(--shadow-soft);
  padding: 2rem;
  display: grid;
  place-content: center;
  text-align: center;
  transition: all 0.55s ease;
}

.achievement-slide i {
  font-size: 2rem;
  color: var(--gold);
  margin-bottom: 0.7rem;
}

.achievement-slide.active {
  opacity: 1;
  transform: translateX(0);
  position: relative;
}

/* Stats section */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
}

.stat-card {
  padding: 1.2rem;
  text-align: center;
  transition: var(--transition);
}

.stat-card i {
  font-size: 1.7rem;
  color: var(--primary-dark);
}

.stat-card h4 {
  font-size: 2rem;
  margin: 0.45rem 0;
}

.stat-card:hover {
  transform: translateY(-6px);
}

/* Contact section */
.contact-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.contact-info,
.contact-form {
  padding: 1.4rem;
}

.contact-info p {
  margin-bottom: 0.6rem;
}

.contact-info i {
  color: var(--primary-dark);
  margin-right: 6px;
}

.map-wrap {
  margin-top: 1rem;
  border-radius: 12px;
  overflow: hidden;
}

.map-wrap iframe {
  width: 100%;
  min-height: 280px;
  border: 0;
}

.input-group {
  margin-bottom: 0.9rem;
}

.input-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.input-group input,
.input-group textarea {
  width: 100%;
  border: 1px solid rgba(15, 107, 58, 0.35);
  padding: 0.75rem;
  border-radius: 10px;
  font: inherit;
  background: rgba(255, 255, 255, 0.9);
}

body.dark-mode .input-group input,
body.dark-mode .input-group textarea {
  background: rgba(255, 255, 255, 0.12);
  color: var(--text-dark);
}

.input-group small {
  color: #df2020;
  display: block;
  min-height: 18px;
}

#formStatus {
  margin-top: 0.7rem;
  font-weight: 500;
}

/* Footer */
.footer {
  background: #093a22;
  color: var(--white);
  padding: 3rem 0 1rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.footer-brand .logo-img {
  margin-bottom: 0.6rem;
}

.footer-links ul {
  list-style: none;
}

.footer-links li {
  margin: 0.35rem 0;
}

.footer-links a:hover {
  color: var(--gold);
}

.social-icons {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.7rem;
}

.social-icons a {
  width: 38px;
  height: 38px;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 50%;
  display: grid;
  place-items: center;
  transition: var(--transition);
}

.social-icons a:hover {
  background: var(--gold);
  color: #1e1e1e;
  transform: translateY(-2px);
}

.copyright {
  margin-top: 1.8rem;
  text-align: center;
  font-size: 0.9rem;
  opacity: 0.9;
}

/* Back to top */
#backToTop {
  position: fixed;
  right: 20px;
  bottom: 24px;
  width: 46px;
  height: 46px;
  border: none;
  border-radius: 50%;
  background: linear-gradient(145deg, var(--primary-dark), var(--primary-light));
  color: var(--white);
  cursor: pointer;
  display: grid;
  place-items: center;
  box-shadow: var(--shadow-soft);
  opacity: 0;
  pointer-events: none;
  transition: var(--transition);
  z-index: 1200;
}

#backToTop.show {
  opacity: 1;
  pointer-events: auto;
}

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.visible,
#kepengurusan.reveal {
  opacity: 1;
  transform: translateY(0);
}

/* Detail page */
.detail-card {
  overflow: hidden;
  display: grid;
  grid-template-columns: 1.1fr 1.4fr;
}

.detail-cover-wrap img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

.detail-content {
  padding: 1.5rem;
}

.detail-badge {
  display: inline-block;
  margin-bottom: 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--white);
  background: linear-gradient(140deg, var(--primary-dark), var(--primary-light));
  border-radius: 999px;
  padding: 0.28rem 0.8rem;
}

.detail-content h2 {
  color: var(--primary-dark);
  margin-bottom: 0.35rem;
}

body.dark-mode .detail-content h2 {
  color: #ddf6e6;
}

.detail-date {
  font-size: 0.9rem;
  color: #3a5447;
  margin-bottom: 0.8rem;
}

body.dark-mode .detail-date {
  color: #c5e8d3;
}

.detail-content h3 {
  margin-top: 1rem;
  margin-bottom: 0.35rem;
}

.detail-content ul {
  margin-left: 1rem;
}

.detail-content li {
  margin-bottom: 0.35rem;
}

.detail-actions {
  margin-top: 1.2rem;
}

/* Responsive styles */
@media (max-width: 1024px) {
  .profile-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  }
}

@media (max-width: 860px) {
  .hamburger {
    display: block;
  }
  .nav-menu {
    position: absolute;
    top: 78px;
    left: 0;
    right: 0;
    flex-direction: column;
    padding: 1rem;
    gap: 0.95rem;
    background: rgba(12, 87, 47, 0.96);
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
  }
  .nav-menu.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }
  .contact-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .section {
    padding: 5rem 0;
  }
  .hero {
    min-height: 82vh;
  }
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
  }
  .program-gallery {
    padding: 1.25rem;
  }
  .program-gallery-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .management-group-header {
    flex-direction: column;
    align-items: flex-start;
  }
  .management-grid--leadership {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin-left: auto;
    margin-right: auto;
  }
  .management-grid--inti {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 1rem;
    padding-bottom: 0.5rem;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
  }
  .management-grid--inti .member-card {
    flex: 0 0 220px;
  }
  .achievement-slide {
    padding: 1.4rem;
  }
}

@media (max-width: 560px) {
  .logo-text p {
    display: none;
  }
  .profile-grid {
    grid-template-columns: 1fr;
  }
  .gallery-grid {
    grid-template-columns: 1fr;
  }
  .gallery-filter {
    flex-wrap: nowrap;
    overflow-x: auto;
    justify-content: flex-start;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .gallery-filter::-webkit-scrollbar {
    display: none;
  }
  .hero-buttons {
    flex-direction: column;
    align-items: flex-start;
  }
  .news-grid {
    grid-template-columns: 1fr;
  }
  .detail-card {
    grid-template-columns: 1fr;
  }
  .detail-cover-wrap img {
    min-height: 240px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
