:root {
  --primary-red: #c92734;
  --white: #ffffff;
  --dark-bg: #111111;
  --transition: all 0.3s ease-in-out;
}

/* =========================
   RESET & GLOBAL
   ========================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Montserrat", sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f4f4f4;
  overflow-x: hidden;
}

/* =========================
   NAVBAR (PATOKAN INDEX)
   ========================= */
header {
  position: fixed;
  top: 0;
  width: 100%;
  z-index: 1000;

  padding: 20px 0; /* SAMA INDEX */
  background: transparent;
  transition: background 0.4s ease, box-shadow 0.4s ease;
}

header.scrolled {
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
}

/* WRAPPER */
header .navbar {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;

  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* LOGO */
.logo {
  color: var(--white);
  font-size: 24px;
  font-weight: bold;
  text-decoration: none;
}

.logo span {
  color: var(--primary-red);
}

/* MENU */
.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
}

.nav-links li {
  margin-left: 30px;
}

.nav-links a {
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: var(--transition);
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--primary-red);
}

/* =========================
   BURGER MENU
   ========================= */
.burger {
  display: none;
  cursor: pointer;
}

.burger div {
  width: 25px;
  height: 3px;
  background-color: var(--white);
  margin: 5px;
  transition: all 0.3s ease;
}

/* =========================
   MOBILE NAVBAR
   ========================= */
@media (max-width: 768px) {
  .burger {
    display: block;
    z-index: 1001;
  }

  .nav-links {
    position: fixed;
    right: 0;
    top: 0;
    height: 100vh;
    width: 70%;
    background: rgba(0, 0, 0, 0.97);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transform: translateX(100%);
    transition: transform 0.4s ease;
    z-index: 999;
  }

  .nav-links li {
    margin: 20px 0;
    opacity: 0;
  }

  .nav-active {
    transform: translateX(0%);
  }

  .toggle .line1 {
    transform: rotate(-45deg) translate(-5px, 6px);
  }
  .toggle .line2 {
    opacity: 0;
  }
  .toggle .line3 {
    transform: rotate(45deg) translate(-5px, -6px);
  }
}

/* =========================
   HERO (INDEX)
   ========================= */
.hero {
  height: 100vh;
  min-height: 600px;
  background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
    url("img_home/kastil2.jpg") center/cover no-repeat;
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  color: var(--white);
  padding: 0 20px;
}

.hero-content h1 {
  font-size: clamp(2rem, 8vw, 4rem);
  margin-bottom: 15px;
}

.hero-content p {
  font-size: clamp(1rem, 3vw, 1.2rem);
  max-width: 700px;
  margin: auto;
}

/* =========================
   BUTTON
   ========================= */
.btn-main {
  display: inline-block;
  margin-top: 30px;
  padding: 14px 40px;
  background-color: var(--primary-red);
  color: var(--white);
  text-decoration: none;
  border-radius: 50px;
  font-weight: bold;
  transition: var(--transition);
}

.btn-main:hover {
  background: transparent;
  border: 2px solid var(--primary-red);
  transform: translateY(-3px);
}

/* =========================
   SECTION OFFSET (GLOBAL)
   ========================= */
section {
  scroll-margin-top: 120px;
}

/* =========================
   GALLERY
   ========================= */
.gallery-section {
  padding: 160px 0 80px;
  min-height: 100vh;
  background: linear-gradient(rgba(0, 0, 0, 0.45), rgba(0, 0, 0, 0.45)),
    url("img_galeri/galeri.jpg") center/cover no-repeat;
}

.section-title {
  text-align: center;
  color: #ffcc00;
  font-size: 2.5rem;
  margin-bottom: 50px;
  font-weight: 700;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
}

.gallery-item {
  background: #ffffff;
  padding: 12px;
  border-radius: 15px;
  height: 250px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transition: 0.3s ease;
}

.gallery-item:hover {
  transform: scale(1.05);
}

.gallery-item img,
.gallery-item video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 8px;
}

/* Responsive gallery */
@media (max-width: 1024px) {
  .gallery-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media (max-width: 600px) {
  .gallery-grid {
    grid-template-columns: 1fr;
  }
}

/* =========================
   FOOTER
   ========================= */
.main-footer {
  background: var(--dark-bg);
  color: var(--white);
  padding: 80px 5% 30px;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px;
  max-width: 1200px;
  margin: auto;
  border-bottom: 1px solid #333;
  padding-bottom: 40px;
}

.footer-section h3 {
  color: #f39c12;
  margin-bottom: 20px;
}

.footer-section p {
  color: #aaa;
  font-size: 0.95rem;
}

.footer-bottom {
  text-align: center;
  margin-top: 20px;
  font-size: 0.8rem;
  color: #666;
}

/* =========================
   WHATSAPP FLOAT
   ========================= */
.whatsapp-float {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background-color: #25d366;
  color: white;
  padding: 12px 25px;
  border-radius: 50px;
  font-weight: bold;
  text-decoration: none;
  z-index: 2000;
}
