/* =========================================================
   LORONG KATA - CTT PANEL SYSTEM v1.1 (REUSABLE)
   Canonical Minimal Editorial Skin
   Light mode only
   Scope: .lk-ctt-panel-wrap (multiple instances supported)
========================================================= */

/* =========================================================
   01. WRAPPER, TOKENS, AND ISOLATION
========================================================= */
.lk-ctt-panel-wrap {
  --lkctt-surface: rgba(255,255,255,.60);
  --lkctt-surface-2: rgba(255,255,255,.80);
  --lkctt-text: #263244;
  --lkctt-strong: #101827;
  --lkctt-muted: rgba(38,50,68,.72);
  --lkctt-soft: rgba(38,50,68,.52);
  --lkctt-line-soft: rgba(38,50,68,.072);
  --lkctt-line-gold: rgba(154,111,53,.30);
  --lkctt-gold: #9a6f35;
  --lkctt-gold-2: #765322;
  --lkctt-red: #d34242;
  --lkctt-gold-soft: rgba(154,111,53,.10);

  width: 100%;
  max-width: 760px;
  margin: 52px 0 34px;
  color: var(--lkctt-text);
  font-family: "Lato", Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  text-align: left;
}

.lk-ctt-panel-wrap,
.lk-ctt-panel-wrap *,
.lk-ctt-panel-wrap *::before,
.lk-ctt-panel-wrap *::after {
  box-sizing: border-box;
}

.lk-ctt-panel-wrap button {
  font-family: inherit;
  box-shadow: none;
}

.lk-ctt-panel-wrap button:focus-visible,
.lk-ctt-panel-wrap a:focus-visible {
  outline: 2px solid var(--lkctt-gold);
  outline-offset: 3px;
}

/* =========================================================
   02. TOGGLE
========================================================= */
.lk-ctt-toggle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--lkctt-soft);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: .045em;
  cursor: pointer;
  transition: color .2s ease;
}

.lk-ctt-toggle::before {
  content: "";
  width: 20px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--lkctt-gold));
  opacity: .82;
}

.lk-ctt-toggle:hover {
  color: var(--lkctt-gold);
}

/* =========================================================
   03. PANEL
========================================================= */
.lk-ctt-panel {
  position: relative;
  overflow: hidden;
  padding: 22px 24px 18px;
  color: var(--lkctt-text);
  text-align: left;
  transition: opacity .24s ease-out, transform .24s ease-out, padding .24s ease-out;
}

.lk-ctt-panel::before {
  content: "";
  position: absolute;
  left: 0;
  top: 24px;
  bottom: 24px;
  width: 3px;
  border-radius: 999px;
  background: linear-gradient(to bottom, transparent, var(--lkctt-gold), transparent);
  opacity: .54;
  pointer-events: none;
}

.lk-ctt-panel::after {
  content: "";
  position: absolute;
  left: 34px;
  right: 34px;
  top: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--lkctt-gold), transparent);
  opacity: .40;
  pointer-events: none;
}

.lk-ctt-panel.is-ctt-hidden {
  height: 0;
  opacity: 0;
  transform: translateY(-4px);
  pointer-events: none;
  padding-top: 0;
  padding-bottom: 0;
}

/* =========================================================
   04. TAB NAVIGATION
========================================================= */
.lk-ctt-tabs-nav {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 17px;
  padding: 5px;
  border: 1px solid var(--lkctt-line-soft);
  border-radius: 999px;
  background: radial-gradient(circle at 50% 0%, rgba(255,255,255,.07), transparent 64%), var(--lkctt-surface);
  overflow-x: auto;
  overflow-y: hidden;
  white-space: nowrap;
  scrollbar-width: none;
}

.lk-ctt-tabs-nav::-webkit-scrollbar {
  display: none;
}

.lk-ctt-tab-btn {
  position: relative;
  z-index: 2;
  flex: 0 0 auto;
  padding: 7px 14px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--lkctt-muted);
  font-size: 13px;
  font-weight: 760;
  letter-spacing: .025em;
  text-align: center;
  cursor: pointer;
  transition: color .18s ease, background .18s ease, border-color .18s ease;
}

.lk-ctt-tab-btn:hover {
  color: var(--lkctt-strong);
  background: var(--lkctt-gold-soft);
}

.lk-ctt-tab-btn.active {
  color: var(--lkctt-strong);
  background: radial-gradient(circle at 50% 0%, rgba(255,255,255,.14), transparent 62%), var(--lkctt-surface-2);
  border-color: var(--lkctt-line-gold);
}

.lk-ctt-tab-indicator {
  position: absolute;
  bottom: -1px;
  left: 0;
  z-index: 3;
  width: 36px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--lkctt-red), transparent);
  opacity: .95;
  transition: transform .22s ease, width .22s ease;
  pointer-events: none;
}

/* =========================================================
   05. TAB CONTENT
========================================================= */
.lk-ctt-tabs-content {
  margin-top: 0;
}

.lk-ctt-tab-pane,
.lk-ctt-tab-pane[hidden] {
  display: none;
}

.lk-ctt-tab-pane {
  color: var(--lkctt-muted);
  text-align: left;
}

.lk-ctt-tab-pane.active:not([hidden]) {
  display: block;
  animation: lkCttPaneIn .22s ease-out;
}

@keyframes lkCttPaneIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.lk-ctt-tab-pane p {
  margin: 0 0 17px;
  color: var(--lkctt-muted)!important;
  font-size: 14.5px;
  line-height: 1.72;
  letter-spacing: .018em;
  text-align: left;
}

.lk-ctt-tab-pane p:last-child {
  margin-bottom: 0;
}

.lk-ctt-tab-pane a {
  color: var(--lkctt-red);
  text-decoration: none;
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
  transition: color .18s ease, text-decoration-color .18s ease;
}

.lk-ctt-tab-pane a:hover {
  color: var(--lkctt-gold-2);
  text-decoration: underline;
  text-decoration-color: currentColor;
}

/* Universal list styling for content inside CTT tabs */
.lk-ctt-panel-wrap .lk-ctt-tab-pane .lk-ctt-list {
  margin: 2px 0 0;
  padding-left: 21px;
  list-style: disc outside;
}

.lk-ctt-panel-wrap .lk-ctt-tab-pane .lk-ctt-list li {
  margin: 0 0 8px;
  padding: 0;
  color: var(--lkctt-muted);
  font-size: 14.5px;
  line-height: 1.58;
  letter-spacing: .008em;
}

.lk-ctt-panel-wrap .lk-ctt-tab-pane .lk-ctt-list li:last-child {
  margin-bottom: 0;
}

/* =========================================================
   06. ADS FOOTNOTE
========================================================= */
.lk-ctt-ads-wrap {
  margin-top: 24px;
  padding-top: 3px;
  color: rgba(38,50,68,.64) !important;
  text-align: left;
}

.lk-ctt-iklan-footnote {
  margin: 0;
  padding: 9px 0 0;
  border-top: 1px solid rgba(38,50,68,.105) !important;
  color: rgba(38,50,68,.58) !important;
  font-size: 11.5px;
  line-height: 1.55;
  font-style: italic;
  opacity: 1 !important;
}

.lk-ctt-iklan-footnote + .lk-ctt-iklan-footnote {
  margin-top: 5px;
}

.lk-ctt-iklan-footnote a {
  color: var(--lkctt-red) !important;
  text-decoration: none;
  font-weight: 700;
  opacity: 1 !important;
}

.lk-ctt-iklan-footnote a:hover {
  color: var(--lkctt-gold) !important;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* =========================================================
   07. MOBILE
========================================================= */
@media (max-width: 640px) {
  .lk-ctt-panel-wrap {
    max-width: 100%;
    margin-top: 42px;
  }

  .lk-ctt-panel {
    padding: 18px 16px 15px;
  }

  .lk-ctt-panel::after {
    left: 24px;
    right: 24px;
  }

  .lk-ctt-tabs-nav {
    border-radius: 18px;
    gap: 6px;
  }

  .lk-ctt-tab-btn {
    padding: 7px 12px;
    font-size: 12.5px;
  }

  .lk-ctt-tab-pane p {
    font-size: 15.8px;
    line-height: 1.74;
  }

  .lk-ctt-iklan-footnote {
    font-size: 11px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .lk-ctt-panel,
  .lk-ctt-tab-btn,
  .lk-ctt-tab-indicator,
  .lk-ctt-tab-pane.active:not([hidden]) {
    animation: none;
    transition: none;
  }
}



/* =========================================================
   DIALektika SUNYI TOC
   Additional styles only
========================================================= */


/* =========================================================
   01. MAP / TOC CONTAINER
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map {
  margin: 0;
}


/* =========================================================
   02. MAP INTRO
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-intro {
  margin: 0 0 18px;
  color: var(--lkctt-muted);
  font-size: 14.5px;
  line-height: 1.72;
  letter-spacing: .01em;
}


/* =========================================================
   03. MAP LIST
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-list {
  display: grid;
  gap: 2px;
  margin: 0;
  padding: 0;
  list-style: none;
}


/* =========================================================
   04. MAP ITEM
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-item {
  margin: 0;
  padding: 9px 10px 9px 11px;
  border-left: 2px solid transparent;
  border-radius: 7px;
  transition:
    background .18s ease,
    border-color .18s ease;
}

.lk-ctt-panel-wrap .lk-ctt-map-item:hover {
  background: var(--lkctt-gold-soft);
  border-left-color: var(--lkctt-gold);
}


/* =========================================================
   05. MAP TITLE ROW
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-head {
  display: flex;
  align-items: baseline;
  gap: 8px;
}


/* =========================================================
   06. MAIN ARTICLE LINK
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-link {
  min-width: 0;
  flex: 1 1 auto;
  color: var(--lkctt-strong);
  text-decoration: none;
}

.lk-ctt-panel-wrap .lk-ctt-map-link:hover {
  text-decoration: none;
}


/* =========================================================
   07. NUMBER
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-number {
  display: inline-block;
  width: 38px;
  color: var(--lkctt-gold);
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .06em;
}


/* =========================================================
   08. TITLE
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-title {
  font-size: 14.5px;
  font-weight: 760;
  letter-spacing: .01em;
}

.lk-ctt-panel-wrap .lk-ctt-map-link:hover .lk-ctt-map-title {
  color: var(--lkctt-red);
}


/* =========================================================
   09. ENGLISH LINK
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-en {
  flex: 0 0 auto;
  color: var(--lkctt-gold);
  font-size: 9.5px;
  font-weight: 800;
  letter-spacing: .08em;
  text-decoration: none;
  opacity: .78;
  transition:
    color .18s ease,
    opacity .18s ease;
}

.lk-ctt-panel-wrap .lk-ctt-map-en:hover {
  color: var(--lkctt-red);
  opacity: 1;
  text-decoration: underline;
  text-underline-offset: 3px;
}


/* =========================================================
   10. SUBTITLE
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-map-subtitle {
  display: block;
  margin: 3px 0 0 38px;
  color: var(--lkctt-soft);
  font-size: 12.5px;
  line-height: 1.55;
}


/* =========================================================
   11. LORONG KATA / PENULIS
   Existing CTT paragraph styling remains untouched.
   These only provide a safe wrapper for the existing content.
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-editorial-note,
.lk-ctt-panel-wrap .lk-ctt-author-note {
  margin: 0;
}


/* =========================================================
   12. MOBILE
========================================================= */

@media (max-width: 640px) {

  .lk-ctt-panel-wrap .lk-ctt-map-intro {
    font-size: 14px;
  }

  .lk-ctt-panel-wrap .lk-ctt-map-item {
    padding: 8px 8px 8px 9px;
  }

  .lk-ctt-panel-wrap .lk-ctt-map-title {
    font-size: 14px;
  }

  .lk-ctt-panel-wrap .lk-ctt-map-subtitle {
    margin-left: 38px;
    font-size: 12px;
  }

  .lk-ctt-panel-wrap .lk-ctt-map-en {
    font-size: 9px;
  }

}

/* =========================================================
   13. EXTREME DISTORTION CROSS-LAYER NAVIGATION
   Native details/summary; no additional JavaScript required.
========================================================= */

.lk-ctt-panel-wrap .lk-ctt-layer-nav {
  margin: 24px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--lkctt-border, rgba(120, 105, 85, .22));
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav > h4 {
  margin: 0 0 12px;
  font-size: 17px;
  line-height: 1.45;
  font-weight: 500;
  color: var(--lkctt-strong);
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group {
  margin: 0 0 8px;
  border: 1px solid var(--lkctt-border, rgba(120, 105, 85, .22));
  border-radius: 8px;
  background: var(--lkctt-surface, rgba(255,255,255,.60));
  overflow: hidden;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  margin: 0;
  padding: 10px 13px;
  color: var(--lkctt-text);
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  cursor: pointer;
  list-style: none;
  transition: color .18s ease, background-color .18s ease;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary::-webkit-details-marker {
  display: none;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary::before {
  content: "";
  flex: 0 0 7px;
  width: 7px;
  height: 7px;
  margin: 0 2px 0 1px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(-45deg);
  transform-origin: center;
  transition: transform .18s ease;
  opacity: .72;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary:hover {
  color: var(--lkctt-red);
  background: var(--lkctt-gold-soft, rgba(154,111,53,.10));
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary:focus-visible {
  position: relative;
  z-index: 1;
  outline: 2px solid var(--lkctt-gold);
  outline-offset: -3px;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-count {
  margin-left: auto;
  flex: 0 0 auto;
  color: var(--lkctt-soft);
  font-size: 11px;
  font-weight: 400;
  line-height: 1.4;
  white-space: nowrap;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group[open] > summary {
  border-bottom: 1px solid var(--lkctt-border, rgba(120, 105, 85, .22));
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-group[open] > summary::before {
  transform: rotate(45deg);
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-list {
  margin: 0;
  padding: 11px 16px 11px 34px;
  font-size: 13px;
  line-height: 1.55;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-list li {
  margin: 0 0 7px;
  line-height: 1.55;
}

.lk-ctt-panel-wrap .lk-ctt-layer-nav-list li:last-child {
  margin-bottom: 0;
}

@media (max-width: 640px) {
  .lk-ctt-panel-wrap .lk-ctt-layer-nav > h4 {
    font-size: 16px;
  }

  .lk-ctt-panel-wrap .lk-ctt-layer-nav-group > summary {
    min-height: 42px;
    padding: 9px 11px;
    font-size: 14px;
  }

  .lk-ctt-panel-wrap .lk-ctt-layer-nav-count {
    font-size: 10.5px;
  }

  .lk-ctt-panel-wrap .lk-ctt-layer-nav-list {
    padding: 10px 12px 10px 30px;
    font-size: 12.5px;
  }
}
