/* =====================================================
   SIMTARU Kota Jambi - Shared Styles
   ===================================================== */

/* ----- CSS Variables ----- */
:root {
  --primary: #0056b3;
  --accent: #ffd700;
  --bg: #f4f6f9;
  --card: #fff;
  --text: #222;
  --text-muted: #666;
  --shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
  --radius: 12px;
  --transition: all 0.3s ease;
}

/* ----- Base Styles ----- */
html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: 'Inter', 'Segoe UI', system-ui, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}

/* ----- Dark Mode ----- */
body.dark {
  --bg: #0f1724;
  --card: #0b1220;
  --text: #e6eef8;
  --text-muted: #94a3b8;
}

body.dark .site-nav {
  background: rgba(2, 6, 23, 0.92);
}

/* ----- Navbar ----- */
.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1100;
  background: rgba(0, 86, 179, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 0.6rem 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.site-nav .brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: #fff;
  font-weight: 700;
  text-decoration: none;
}

.site-nav .brand img {
  border-radius: 8px;
  object-fit: cover;
}

.site-nav .navlinks {
  margin-left: auto;
  display: flex;
  gap: 1.5rem;
  align-items: center;
}

.site-nav .navlinks a {
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  padding: 0.4rem 0.8rem;
  border-radius: 6px;
  transition: var(--transition);
}

.site-nav .navlinks a:hover {
  background: rgba(255, 255, 255, 0.15);
}

.hamburger {
  display: none;
  background: transparent;
  border: none;
  font-size: 1.8rem;
  color: #fff;
  cursor: pointer;
  padding: 0.25rem;
}

.theme-toggle {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #fff;
  padding: 0.4rem 0.8rem;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 500;
  transition: var(--transition);
}

.theme-toggle:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.4);
}

/* ----- Hero Slider ----- */
.hero-slider {
  height: 100vh;
  position: relative;
  overflow: hidden;
  margin: 0;
  transition: all 1s ease;
}

.hero-slider.scrolled {
  transform: translateY(-10%);
  opacity: 0.3;
  filter: blur(4px);
}

.swiper,
.swiper-wrapper,
.swiper-slide {
  height: 100%;
  width: 100%;
}

.swiper-slide {
  display: flex;
  align-items: center;
  justify-content: center;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.35), rgba(0, 0, 0, 0.6));
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  color: #fff;
  text-align: center;
  padding: 2rem;
  max-width: 1000px;
  margin: auto;
  opacity: 0;
  transform: translateY(40px);
  transition: all 1s ease;
}

.swiper-slide-active .hero-content {
  opacity: 1;
  transform: translateY(0);
}

.hero-content h1 {
  font-size: 2.8rem;
  margin-bottom: 0.75rem;
  text-shadow: 1px 2px 8px rgba(0, 0, 0, 0.5);
  font-weight: 800;
}

.hero-content p {
  font-size: 1.15rem;
  margin-bottom: 1.5rem;
  opacity: 0.95;
}

/* ----- Hero for Unduh Page ----- */
.hero {
  min-height: 56vh;
  background-size: cover;
  background-position: center;
  position: relative;
  color: #fff;
}

.hero .hero-content {
  opacity: 1;
  transform: none;
  padding: 3rem;
}

/* ----- Scroll Indicator ----- */
.scroll-down {
  position: absolute;
  bottom: 30px;
  left: 50%;
  transform: translateX(-50%);
  cursor: pointer;
  z-index: 10;
}

.scroll-down span {
  display: block;
  width: 28px;
  height: 48px;
  border: 2px solid rgba(255, 255, 255, 0.8);
  border-radius: 50px;
  position: relative;
  box-shadow: 0 0 15px rgba(255, 255, 255, 0.3);
}

.scroll-down span::after {
  content: '';
  position: absolute;
  top: 8px;
  left: 50%;
  width: 6px;
  height: 6px;
  background: #fff;
  border-radius: 50%;
  transform: translateX(-50%);
  animation: scrollAnim 1.6s infinite;
}

@keyframes scrollAnim {
  0% { opacity: 0; transform: translate(-50%, 0); }
  50% { opacity: 1; transform: translate(-50%, 12px); }
  100% { opacity: 0; transform: translate(-50%, 24px); }
}

/* ----- Main Container ----- */
.main-wrap {
  max-width: 1200px;
  margin: 2.5rem auto;
  padding: 1rem;
}

/* ----- Card Sections ----- */
.card-section {
  background: var(--card);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow);
  transition: var(--transition);
}

.card-section:hover {
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}

.fullwidth-section {
  width: 100%;
  max-width: none;
  border-radius: 0;
  margin-left: 0;
  margin-right: 0;
}

.section-title {
  color: var(--primary);
  margin-bottom: 0.75rem;
  font-weight: 700;
  font-size: 1.5rem;
}

/* ----- Map Container ----- */
.map-container {
  height: 480px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

/* ----- Reveal Animation ----- */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.7s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
  opacity: 1;
  transform: translateY(0);
}

.reveal img {
  transition: transform 0.5s ease;
}

.reveal.active img {
  transform: scale(1.02);
}

/* ----- FAB Group ----- */
.fab-group {
  position: fixed;
  right: 20px;
  bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  z-index: 1200;
}

.fab {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--primary);
  color: #fff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  border: none;
  font-size: 1.4rem;
  transition: var(--transition);
  text-decoration: none;
}

.fab:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
}

/* ----- Back to Top Button ----- */
.back-to-top {
  position: fixed;
  bottom: 90px;
  right: 20px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 1100;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

/* ----- PDF Frame ----- */
.pdf-frame {
  width: 100%;
  height: 70vh;
  border: 1px solid #ddd;
  border-radius: 8px;
}

/* ----- Footer ----- */
.site-footer {
  background: linear-gradient(135deg, var(--primary), #003d82);
  color: #fff;
  padding: 3rem 1rem 1.5rem;
  margin-top: 3rem;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
}

.footer-section h4 {
  font-size: 1.1rem;
  margin-bottom: 1rem;
  font-weight: 700;
}

.footer-section p,
.footer-section a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 0.95rem;
  line-height: 1.8;
}

.footer-section a {
  text-decoration: none;
  display: block;
  transition: var(--transition);
}

.footer-section a:hover {
  color: var(--accent);
  padding-left: 5px;
}

.footer-social {
  display: flex;
  gap: 1rem;
  margin-top: 0.5rem;
}

.footer-social a {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.footer-social a:hover {
  background: var(--accent);
  color: var(--primary);
  padding-left: 0;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin-top: 2rem;
  padding-top: 1.5rem;
  text-align: center;
  color: rgba(255, 255, 255, 0.7);
  font-size: 0.9rem;
}

/* ----- Loading Skeleton ----- */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s infinite;
  border-radius: 4px;
}

body.dark .skeleton {
  background: linear-gradient(90deg, #1e293b 25%, #334155 50%, #1e293b 75%);
  background-size: 200% 100%;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ----- Responsive ----- */
@media (max-width: 768px) {
  .hamburger {
    display: block;
    margin-left: auto;
  }

  .site-nav .navlinks {
    display: none;
    position: absolute;
    top: 60px;
    right: 1rem;
    background: rgba(0, 86, 179, 0.98);
    flex-direction: column;
    gap: 0.5rem;
    padding: 1rem;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  }

  .site-nav .navlinks.show {
    display: flex;
  }

  .theme-toggle {
    order: 1;
  }

  .hero-content h1 {
    font-size: 1.8rem;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .map-container {
    height: 320px;
  }

  .pdf-frame {
    height: 50vh;
  }

  .footer-content {
    text-align: center;
  }

  .footer-social {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .site-nav .brand span {
    font-size: 0.85rem;
  }

  .hero-content h1 {
    font-size: 1.5rem;
  }

  .card-section {
    padding: 1rem;
  }
}
