/* ======================================================= */
/* Variabel Tema (Light & Dark Mode) */
/* ======================================================= */
:root {
  --sidebar-width: 260px;
  --bg-color: #f4f7f6;
  --text-color: #333;
  --text-color-light: #555;
  --header-color: #1a1a1a;
  --container-bg: #ffffff;
  --sidebar-bg: #f9f9f9;
  --border-color: #e0e0e0;
  --shadow-color: rgba(0, 0, 0, 0.05);
  --link-hover-bg: #e6f7f5;
  --link-hover-text: #007a66;
  --link-active-bg: #00a98f;
  --link-active-text: #ffffff;
  --note-bg: #e6f7f5;
  --note-border: #00a98f;
  --note-alt-bg: #fffaf0;
  --note-alt-border: #ff9900;
  --blockquote-bg: #f9f9f9;
  --blockquote-border: #ccc;
  --image-border: #e0e0e0;
  --image-caption-text: #777;
  --link-color: #007a66;
  --link-hover-color: #00a98f;
}

body.dark-mode {
  --bg-color: #1a1a1a;
  --text-color: #e0e0e0;
  --text-color-light: #aaa;
  --header-color: #ffffff;
  --container-bg: #2c2c2c;
  --sidebar-bg: #252525;
  --border-color: #444;
  --shadow-color: rgba(0, 0, 0, 0.2);
  --link-hover-bg: #30403e;
  --link-hover-text: #00a98f;
  --link-active-bg: #00a98f;
  --link-active-text: #ffffff;
  --note-bg: #30403e;
  --note-border: #00a98f;
  --note-alt-bg: #4d3a1a;
  --note-alt-border: #ff9900;
  --blockquote-bg: #333;
  --blockquote-border: #555;
  --image-border: #555;
  --image-caption-text: #999;
  --link-color: #00c7a5;
  --link-hover-color: #33e0c7;
}

/* ======================================================= */
/* Pengaturan Dasar */
/* ======================================================= */
* {
  box-sizing: border-box;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;
  line-height: 1.6;
  background-color: var(--bg-color);
  color: var(--text-color);
  margin: 0;
  padding: 0;
  transition: background-color 0.3s ease, color 0.3s ease;
  overflow-x: hidden;
}

/* ======================================================= */
/* EFEK INTERAKTIF (Smooth Scroll, Selection) */
/* ======================================================= */
html {
  scroll-behavior: smooth;
}
::selection {
  background-color: var(--link-hover-bg);
  color: var(--link-hover-text);
}
/* Firefox */
::-moz-selection {
  background-color: var(--link-hover-bg);
  color: var(--link-hover-text);
}
/* Focus styles for accessibility */
*:focus-visible {
  outline: 2px solid var(--link-color);
  outline-offset: 2px;
  border-radius: 5px;
}

/* ======================================================= */
/* [BAGIAN 1] STYLE HALAMAN MATERI (SIDEBAR, CONTENT, DLL.) */
/* ======================================================= */
.container {
  display: flex;
  width: 100%;
  height: 100vh;
  position: relative;
  background: var(--container-bg);
}
.sidebar {
  width: var(--sidebar-width);
  min-width: var(--sidebar-width);
  background: var(--sidebar-bg);
  border-right: 1px solid var(--border-color);
  transition: all 0.3s ease;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
}
.sidebar-content {
  padding: 20px;
}
.sidebar h3 {
  font-size: 1.2em;
  color: var(--header-color);
  border-bottom: 2px solid var(--note-border);
  padding-bottom: 10px;
}
.sidebar ul {
  list-style: none;
  padding: 0;
  margin: 0;
}
.sidebar ul li a {
  display: block;
  padding: 10px 15px;
  text-decoration: none;
  color: var(--text-color-light);
  border-radius: 5px;
  margin-bottom: 5px;
  font-weight: 500;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.sidebar ul li a:hover {
  background-color: var(--link-hover-bg);
  color: var(--link-hover-text);
}
.sidebar ul li a.active {
  background-color: var(--link-active-bg);
  color: var(--link-active-text);
  font-weight: 700;
}
.content {
  flex: 1;
  height: 100vh;
  overflow-y: auto;
  padding: 30px 40px;
}
#sidebar-toggle {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  left: calc(var(--sidebar-width) - 15px);
  z-index: 10;
  width: 30px;
  height: 40px;
  background: var(--container-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  cursor: pointer;
  font-size: 1.2em;
  color: var(--text-color);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  box-shadow: 0 1px 4px var(--shadow-color);
  transition: all 0.3s ease;
}
#sidebar-toggle:hover {
  background: var(--link-hover-bg);
}
.container.sidebar-collapsed .sidebar {
  width: 0;
  min-width: 0;
  border: none;
}
.container.sidebar-collapsed #sidebar-toggle {
  left: -15px;
  transform: translateY(-50%) scaleX(-1);
  border-radius: 0 8px 8px 0;
}
article h1 {
  font-size: 2.5em;
  color: var(--header-color);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 15px;
  margin-top: 0;
}
article h2 {
  font-size: 1.8em;
  color: var(--header-color);
  margin-top: 40px;
  margin-bottom: 15px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 10px;
}
article h3 {
  font-size: 1.4em;
  color: var(--header-color);
  margin-top: 30px;
}
article p,
article ul,
article ol {
  font-size: 1.05em;
  margin-bottom: 20px;
  color: var(--text-color-light);
}
article p {
  color: var(--text-color);
}
article p.intro {
  font-size: 1.2em;
  color: var(--text-color-light);
  font-style: italic;
}
article ul,
article ol {
  padding-left: 30px;
}
article ul.sub-list {
  margin-top: 10px;
  font-size: 0.95em;
}
article li {
  margin-bottom: 10px;
}
article strong {
  color: var(--header-color);
  font-weight: 600;
}
article a {
  color: var(--link-color);
  font-weight: 600;
  text-decoration: underline;
  transition: color 0.2s ease;
}
article a:hover {
  color: var(--link-hover-color);
  text-decoration: none;
}
.note {
  background-color: var(--note-bg);
  border-left: 5px solid var(--note-border);
  padding: 15px 20px;
  margin: 20px 0;
  border-radius: 5px;
  transition: background-color 0.3s ease;
}
.note.alt {
  background-color: var(--note-alt-bg);
  border-left-color: var(--note-alt-border);
}
.note strong {
  color: var(--header-color);
}
blockquote {
  font-size: 1.1em;
  font-style: italic;
  border-left: 5px solid var(--blockquote-border);
  padding: 10px 20px;
  margin: 20px 0;
  background: var(--blockquote-bg);
  transition: background-color 0.3s ease;
}
.image-wrapper {
  text-align: center;
  margin: 25px 0;
}
.image-wrapper img {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--image-border);
  border-radius: 5px;
  box-shadow: 0 2px 5px var(--shadow-color);
  transition: border-color 0.3s ease;
}
.image-caption {
  font-size: 0.9em;
  color: var(--image-caption-text);
  margin-top: 10px;
  font-style: italic;
}
.page-navigation {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
}
.page-navigation a {
  display: inline-block;
  padding: 12px 20px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  color: var(--text-color-light);
  transition: all 0.2s ease;
  max-width: 48%;
}
.page-navigation a:hover {
  background-color: var(--link-hover-bg);
  color: var(--link-hover-text);
  border-color: var(--note-border);
  transform: translateY(-2px);
}
.page-navigation .prev-page {
  text-align: left;
}
.page-navigation .next-page {
  text-align: right;
  margin-left: auto;
}
.support-block {
  margin-top: 50px;
  padding-top: 30px;
  border-top: 2px solid var(--border-color);
  text-align: center;
}
.support-block h3 {
  font-size: 1.6em;
  font-weight: 600;
  color: var(--header-color);
  margin-top: 0;
  margin-bottom: 15px;
}
.support-block p {
  font-size: 1.1em;
  color: var(--text-color-light);
  max-width: 600px;
  margin: 0 auto 25px auto;
}
.support-block .support-button {
  display: inline-block;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--link-active-text);
  background-color: var(--note-border);
  padding: 12px 30px;
  border-radius: 8px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 10px -1px rgba(0, 169, 143, 0.2);
}
.support-block .support-button:hover {
  transform: translateY(-2px);
  background-color: #00c7a5;
  box-shadow: 0 6px 15px -1px rgba(0, 169, 143, 0.3);
}

/* ======================================================= */
/* [BAGIAN 2] STYLE HOMEPAGE (ANIMASI DARI CLAUDE) */
/* ======================================================= */
/* ANIMASI KEYFRAMES */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes slideInFromTop {
  from {
    opacity: 0;
    transform: translateY(-50px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes slideInFromLeft {
  from {
    opacity: 0;
    transform: translateX(-50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
@keyframes slideInFromRight {
  from {
    opacity: 0;
    transform: translateX(50px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}
@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.9);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
}
@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}
@keyframes shimmer {
  0% {
    background-position: -1000px 0;
  }
  100% {
    background-position: 1000px 0;
  }
}
@keyframes glowPulse {
  0%,
  100% {
    box-shadow: 0 0 20px rgba(0, 169, 143, 0.3);
  }
  50% {
    box-shadow: 0 0 40px rgba(0, 169, 143, 0.5);
  }
}
@keyframes rotateIn {
  from {
    opacity: 0;
    transform: rotate(-90deg) scale(0);
  }
  to {
    opacity: 1;
    transform: rotate(0) scale(1);
  }
}
@keyframes backgroundMove {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}
@keyframes loadingBar {
  from {
    width: 0;
  }
  to {
    width: 100%;
  }
}

/* Loading Bar */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--link-color),
    var(--link-hover-color)
  );
  animation: loadingBar 1s ease-out;
  z-index: 9999;
  pointer-events: none;
}

/* Background Homepage */
.homepage-body {
  background: linear-gradient(
    -45deg,
    var(--link-hover-bg),
    var(--bg-color),
    var(--note-bg),
    var(--bg-color)
  );
  background-size: 400% 400%;
  animation: backgroundMove 15s ease infinite;
  min-height: 100vh;
}
body.dark-mode.homepage-body {
  background: linear-gradient(
    -45deg,
    #1a1a1a,
    #2c2c2c,
    #30403e,
    #1a1a1a
  );
  background-size: 400% 400%;
  animation: backgroundMove 15s ease infinite;
}

/* Kontainer Homepage */
.homepage-container {
  max-width: 960px;
  margin: 0 auto;
  padding: 40px 20px;
  animation: fadeInUp 0.8s ease-out;
}
.homepage-container header {
  text-align: center;
  border-bottom: none;
  padding-bottom: 20px;
  margin-bottom: 50px;
  position: relative;
}
.homepage-container h1 {
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--header-color);
  margin-bottom: 15px;
  letter-spacing: -1.5px;
  animation: slideInFromTop 0.8s ease-out;
  position: relative;
  display: inline-block;
}
.homepage-container h1::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  width: 0;
  height: 3px;
  background: linear-gradient(
    90deg,
    var(--link-color),
    var(--link-hover-color)
  );
  transition: width 0.5s ease, left 0.5s ease;
}
.homepage-container h1:hover::after {
  width: 100%;
  left: 0;
}
.homepage-container header p {
  font-size: 1.25rem;
  color: var(--text-color-light);
  line-height: 1.7;
  max-width: 700px;
  margin: 0 auto;
  animation: fadeInUp 1s ease-out 0.2s both;
}

/* Tombol Tema (Floating) */
#theme-toggle-floating {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 999;
  background: var(--container-bg);
  border: 2px solid var(--border-color);
  border-radius: 50%;
  padding: 0;
  cursor: pointer;
  width: 44px;
  height: 44px;
  color: var(--text-color);
  overflow: hidden;
  animation: rotateIn 0.6s ease-out, float 3s ease-in-out infinite;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}
#theme-toggle-floating:hover {
  transform: scale(1.1) rotate(180deg);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
  animation-play-state: paused;
}
#theme-toggle-floating:active {
  transform: scale(0.95);
}
/* Icon animations */
#theme-toggle-floating svg {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease-out, opacity 0.2s ease-out;
}
.moon-icon {
  transform: translateY(0);
  opacity: 1;
}
.sun-icon {
  transform: translateY(-100%);
  opacity: 0;
  position: absolute;
  left: 50%;
  top: 50%;
  margin-left: -10px;
  margin-top: -10px;
}
body.dark-mode .moon-icon {
  transform: translateY(100%) rotate(360deg);
  opacity: 0;
}
body.dark-mode .sun-icon {
  transform: translateY(0) rotate(360deg);
  opacity: 1;
}

/* Tombol Tema (Sidebar) */
.theme-switcher {
  padding: 0;
  margin: 15px 0;
  text-align: left;
}
#theme-toggle-sidebar {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  width: 100%;
  height: 36px;
  color: var(--text-color);
  overflow: hidden;
  border-radius: 5px;
  background-color: var(--container-bg);
  border: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  position: relative; /* Untuk ikon */
}
#theme-toggle-sidebar:hover {
  background-color: var(--link-hover-bg);
  color: var(--link-hover-text);
  transform: scale(1.05);
}
#theme-toggle-sidebar svg {
  width: 20px;
  height: 20px;
  transition: transform 0.3s ease-out, opacity 0.2s ease-out;
}

/* Tombol Dukungan */
.support-button {
  display: inline-block;
  text-decoration: none;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--link-active-text);
  background: linear-gradient(135deg, var(--note-alt-border), #ffaa33);
  padding: 12px 24px;
  border-radius: 8px;
  transition: all 0.3s ease;
  margin-top: 10px;
  box-shadow: 0 4px 10px -1px rgba(255, 153, 0, 0.2);
  animation: fadeInUp 1.2s ease-out 0.4s both, pulse 2s ease-in-out infinite;
  position: relative;
  overflow: hidden;
}
.support-button::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s ease;
}
.support-button:hover::before {
  left: 100%;
}
.support-button:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 20px -1px rgba(255, 153, 0, 0.4);
  animation-play-state: paused;
}

/* Card Styles */
.card-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 30px;
}
.level-chooser {
  grid-template-columns: 1fr 1fr;
  gap: 30px;
}
.card {
  display: block;
  text-decoration: none;
  background: var(--container-bg);
  border: none;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02), 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  position: relative;
}
.card:nth-child(1) {
  animation: slideInFromLeft 0.8s ease-out 0.6s both;
}
.card:nth-child(2) {
  animation: slideInFromRight 0.8s ease-out 0.8s both;
}
.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    transparent,
    var(--link-hover-bg),
    transparent
  );
  transform: translateX(-100%);
  transition: transform 0.6s ease;
  opacity: 0.5;
}
.card:hover::before {
  transform: translateX(100%);
}
.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 12px;
  padding: 2px;
  background: linear-gradient(135deg, var(--link-color), var(--link-hover-color));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  opacity: 0;
  transition: opacity 0.3s ease;
}
.card:hover::after {
  opacity: 1;
}
.card:hover {
  transform: translateY(-10px) scale(1.02);
  box-shadow: 0 20px 40px -10px rgba(0, 169, 143, 0.3),
    0 10px 20px rgba(0, 0, 0, 0.1);
}
.card-content {
  padding: 24px 28px;
  position: relative;
  z-index: 1;
}
.card-number {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--link-hover-text);
  background: linear-gradient(135deg, var(--link-hover-bg), var(--note-bg));
  padding: 4px 10px;
  border-radius: 20px;
  margin-bottom: 16px;
  transition: all 0.3s ease;
  position: relative;
}
.card:hover .card-number {
  transform: scale(1.1);
  box-shadow: 0 2px 8px rgba(0, 169, 143, 0.3);
}
@keyframes sparkle {
  0%,
  100% {
    opacity: 0;
    transform: scale(0);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}
.card:hover .card-number::before {
  content: "✨";
  position: absolute;
  top: -10px;
  right: -10px;
  animation: sparkle 0.6s ease;
}
.card-title {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--header-color);
  margin-top: 0;
  margin-bottom: 12px;
  transition: color 0.3s ease;
}
.card:hover .card-title {
  color: var(--note-border);
  transform: translateX(5px);
  transition: all 0.3s ease;
}
.card-description {
  font-size: 1rem;
  color: var(--text-color-light);
  line-height: 1.6;
  transition: color 0.3s ease;
}
.card:hover .card-description {
  color: var(--text-color);
}
.level-card {
  border-width: 2px;
  position: relative;
  background: linear-gradient(135deg, var(--container-bg), var(--sidebar-bg));
}
.level-card .card-title {
  font-size: 1.8rem;
}

/* Halaman Level 1 & 2 */
.back-to-home {
  display: inline-block;
  margin-bottom: 20px;
  font-size: 1rem;
  font-weight: 600;
  color: var(--link-color);
  text-decoration: none;
  padding: 8px 12px;
  border: 1px solid transparent;
  border-radius: 8px;
  transition: all 0.2s ease;
}
.back-to-home:hover {
  background-color: var(--link-hover-bg);
  border-color: var(--border-color);
}
.level-section {
  /* Beri jarak antar bagian Level 1 dan Level 2 */
  margin-bottom: 60px;
}
.level-title {
  font-size: 2.2rem;
  font-weight: 700;
  color: var(--header-color);
  letter-spacing: -1px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border-color);
}
.level-description {
  font-size: 1.1rem;
  color: var(--text-color-light);
  margin-top: 0;
  margin-bottom: 30px;
}

/* Responsive */
@media (max-width: 768px) {
  /* Halaman Materi */
  .container {
    flex-direction: column;
    height: auto;
  }
  .sidebar {
    width: 100%;
    min-width: 100%;
    height: auto;
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    overflow-y: hidden;
  }
  .content {
    height: auto;
    overflow-y: hidden;
    padding: 20px;
  }
  #sidebar-toggle {
    display: none;
  }
  article h1 {
    font-size: 2em;
  }
  article h2 {
    font-size: 1.5em;
  }

  /* Halaman Homepage & Level */
  .homepage-container {
    padding: 20px;
  }
  .homepage-container h1 {
    font-size: 2.5rem;
    letter-spacing: -1px;
  }
  .homepage-container header p {
    font-size: 1.1rem;
  }
  .level-chooser {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .card:nth-child(1),
  .card:nth-child(2) {
    animation: fadeInUp 0.8s ease-out both;
  }
  .card:nth-child(2) {
    animation-delay: 0.2s;
  }
  #theme-toggle-floating {
    top: 15px;
    right: 15px;
    width: 40px;
    height: 40px;
  }
}

/* ======================================================= */
/* FITUR IMAGE ZOOM (LIGHTBOX) */
/* ======================================================= */

/* 1. Ubah kursor gambar di artikel agar terlihat bisa diklik */
.image-wrapper img {
  cursor: zoom-in;
  transition: transform 0.2s ease, border-color 0.3s ease;
}

.image-wrapper img:hover {
  transform: scale(1.02);
  border-color: var(--link-active-bg);
}

/* 2. Container Modal (Latar Belakang Gelap) */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.85); /* Gelap transparan */
  backdrop-filter: blur(5px); /* Efek blur modern */
  z-index: 10000; /* Pastikan di atas segalanya */
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none; /* Agar bisa diklik tembus saat sembunyi */
  transition: opacity 0.3s ease;
}

/* Class aktif untuk memunculkan modal */
.lightbox-modal.active {
  opacity: 1;
  pointer-events: all;
}

/* 3. Gambar di dalam Modal */
.lightbox-content {
  max-width: 90%;
  max-height: 90%;
  box-shadow: 0 5px 30px rgba(0, 0, 0, 0.5);
  border-radius: 4px;
  
  /* Transisi default untuk efek pop-up */
  transform: scale(0.9);
  opacity: 0;
  transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease;
  
  /* Cursor default saat belum di-zoom */
  cursor: zoom-in; 
}

/* Saat modal aktif, gambar muncul normal */
.lightbox-modal.active .lightbox-content {
  transform: scale(1);
  opacity: 1;
}

/* STATE BARU: Saat gambar di-zoom */
.lightbox-content.is-zoomed {
  /* Perbesar gambar 2.5 kali lipat */
  transform: scale(2.5); 
  cursor: zoom-out; /* Ubah kursor jadi minus */
  
  /* PENTING: Hapus transisi transform-origin agar gerakan mouse responsif/instan */
  /* Kita tetap biarkan transisi transform agar zoom-in/out halus */
  transition: transform 0.3s ease; 
}

/* 4. Tombol Tutup (X) */
.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 40px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.2s ease, transform 0.2s ease;
  z-index: 10001;
  line-height: 1;
}

.lightbox-close:hover {
  color: var(--note-alt-border); /* Warna oranye saat hover */
  transform: scale(1.1);
}

/* 5. Caption di dalam Modal */
.lightbox-caption {
  position: absolute;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  color: #fff;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 0.9rem;
  text-align: center;
  max-width: 80%;
}

/* ======================================================= */
/* STYLE UNTUK KUNCI JAWABAN (DETAILS/SUMMARY) */
/* ======================================================= */
details.solution-box {
  background-color: var(--container-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  margin: 20px 0;
  overflow: hidden;
  transition: all 0.3s ease;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

details.solution-box summary {
  padding: 15px 20px;
  cursor: pointer;
  font-weight: 600;
  color: var(--link-color);
  background-color: var(--note-bg);
  list-style: none; /* Hilangkan panah default browser */
  user-select: none;
  transition: background-color 0.2s ease;
}

details.solution-box summary:hover {
  background-color: var(--link-hover-bg);
}

/* Hilangkan panah default di Webkit */
details.solution-box summary::-webkit-details-marker {
  display: none;
}

details.solution-box[open] summary {
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 0;
}

.solution-content {
  padding: 20px;
  background-color: var(--container-bg);
  animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ======================================================= */
/* FITUR COPY CODE BUTTON */
/* ======================================================= */

/* Wrapper agar tombol bisa diposisikan absolute relatif terhadap ini */
.code-wrapper {
  position: relative;
  margin-bottom: 1.5rem;
}

.code-wrapper pre {
  margin-bottom: 0; /* Margin dipindah ke wrapper */
  padding-top: 40px; /* Beri ruang di atas untuk tombol */
}

/* Tombol Copy */
.copy-btn {
  position: absolute;
  top: 5px;
  right: 5px;
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #ddd;
  padding: 5px 10px;
  font-size: 0.8rem;
  border-radius: 4px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: 'Inter', sans-serif;
  display: flex;
  align-items: center;
  gap: 5px;
  z-index: 10;
}

.copy-btn:hover {
  background-color: rgba(255, 255, 255, 0.2);
  color: #fff;
}

/* State saat berhasil dicopy */
.copy-btn.copied {
  background-color: var(--note-border); /* Warna Hijau n8n */
  color: white;
  border-color: var(--note-border);
}