@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-weight: 700 900;
  font-display: swap;
  src: url('../font/montserrat-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Montserrat';
  font-style: normal;
  font-weight: 700 900;
  font-display: swap;
  src: url('../font/montserrat-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../font/open-sans-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Open Sans';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../font/open-sans-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html, body {
    scrollbar-gutter: stable;
}

body {
    font-family: 'Open Sans', sans-serif;
    background: radial-gradient(circle at center, #1a3822 0%, #0d1a11 100%);
    color: #e0e0e0; min-height: 100vh; overflow-x: hidden;
}

::-webkit-scrollbar { height: 6px; width: 6px; }
::-webkit-scrollbar-track { background: #0d1a11; }
::-webkit-scrollbar-thumb { background: #1a7a27; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #4CAF50; }

nav { 
    display: flex; 
    justify-content: flex-start;
    align-items: center; 
    padding: 15px 50px;
    background: rgba(10, 20, 13, 0.7);
    backdrop-filter: blur(15px); 
    -webkit-backdrop-filter: blur(15px);
    position: sticky;
    top: 0; 
    z-index: 1000;
    border-bottom: 1px solid rgba(76, 175, 80, 0.15);
}

.nav-logo { 
    font-family: 'Montserrat', sans-serif; font-size: 1.4rem; font-weight: 900; 
    color: white; text-decoration: none; display: flex; align-items: center; gap: 10px; 
}
.nav-logo img { width: 35px; }

.nav-links { 
    display: flex; gap: 35px; align-items: center; 
    margin-left: auto;
    margin-right: 30px;
}

.nav-item {
    position: relative;
    color: #d1d1d1; text-decoration: none; font-weight: 600; font-size: 0.9rem;
    padding-bottom: 5px; cursor: pointer; transition: color 0.3s;
}
.nav-item:hover, .nav-item.active { color: #4CAF50; }

.nav-item::after {
    content: ''; position: absolute; width: 0; height: 2px;
    bottom: 0; left: 50%; background-color: #4CAF50;
    transition: all 0.3s ease-in-out;
    transform: translateX(-50%);
}
.nav-item:hover::after, .nav-item.active::after { width: 100%; }

.dropdown { 
    position: relative; display: inline-block; 
    padding-bottom: 15px; margin-bottom: -15px; 
}
.dropbtn { display: flex; align-items: center; gap: 5px; }

.dropdown-content {
    display: none; position: absolute; top: 100%; left: -10px;
    background-color: rgba(13, 26, 17, 0.95); min-width: 170px;
    box-shadow: 0px 8px 25px rgba(0,0,0,0.7); z-index: 100;
    border-radius: 8px; border: 1px solid rgba(76, 175, 80, 0.3);
    overflow: hidden; margin-top: 0px; 
    animation: fadeInDown 0.3s ease forwards;
}

.dropdown-content a {
    color: #bbb; padding: 12px 20px; text-decoration: none; display: block; font-size: 0.85rem;
    border-bottom: 1px solid rgba(76, 175, 80, 0.1); transition: all 0.3s;
}
.dropdown-content a:last-child { border-bottom: none; }
.dropdown-content a:hover { 
    background-color: rgba(76, 175, 80, 0.15); 
    color: #4CAF50; 
    padding-left: 25px;
}

.dropdown:hover .dropdown-content { display: block; }

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

.btn-discord { 
    background-color: transparent; 
    color: #4CAF50; 
    padding: 8px 18px; 
    border-radius: 20px;
    text-decoration: none; 
    font-weight: 600; 
    font-size: 0.8rem;
    transition: all 0.3s; 
    border: 1px solid #4CAF50; 
    display: flex; align-items: center; gap: 8px;
}
.btn-discord:hover { 
    background-color: #4CAF50; 
    color: white; 
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.4); 
    transform: translateY(-2px);
}

.btn-primary { background-color: #1a7a27; color: white; padding: 10px 20px; border-radius: 8px; text-decoration: none; font-weight: bold; transition: 0.3s; border: 1px solid #28a745; }
.btn-primary:hover { background-color: #28a745; box-shadow: 0 0 15px rgba(40, 167, 69, 0.5); }

.fade-in-up { animation: fadeInUp 1s ease-out forwards; opacity: 0; }
@keyframes fadeInUp { 0% { opacity: 0; transform: translateY(30px); } 100% { opacity: 1; transform: translateY(0); } }

.hero-container {
    display: flex; justify-content: space-between; align-items: center;
    max-width: 1200px; margin: 80px auto; padding: 0 50px;
}
.hero-text { flex: 1; max-width: 600px; }
.hero-text h1 { font-family: 'Montserrat', sans-serif; font-size: 4rem; line-height: 1.1; margin-bottom: 20px; color: white; text-shadow: 2px 2px 4px rgba(0,0,0,0.5); }
.hero-text h1 span { color: transparent; -webkit-text-stroke: 2px #4CAF50; }
.hero-text p { font-size: 1.1rem; margin-bottom: 30px; color: #bbb; line-height: 1.8; }
.hero-buttons { display: flex; gap: 15px; }
.hero-image { flex: 1; display: flex; justify-content: flex-end; }
.hero-image img { max-width: 100%; width: 450px; filter: drop-shadow(0 0 20px rgba(76, 175, 80, 0.3)); }

.org-chart-wrapper {
    width: 100%;
    overflow-x: auto;
    padding: 20px 0;
}

.org-chart-canvas {
    min-width: 1400px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 auto;
}

.tree-container { display: flex; justify-content: center; width: 100%; }
/* Irama jarak bagan: SATU angka, 14px, untuk tiap celah yang bisa ditunjuk —
   kartu ke kartu, kartu ke garis, garis ke kartu. Celah mendatar antar `li`
   = padding kiri+kanan `li` (7+7); celah tegak antar tingkat = padding atas
   `ul` + padding atas `li` (14+14), dan garisnya jatuh di tengahnya karena
   `drawWires` selalu memakai titik tengah celah. Dulu campurannya 20/40/35
   karena `:only-child` mematikan padding `li` di sebagian tingkat saja dan
   dua `ul` di HTML membawa padding sendiri (0 dan 15) — sekarang tidak ada
   lagi pengecualian, jadi jaraknya sama di mana pun. */
.tree ul { padding-top: 14px; position: relative; display: flex; justify-content: center; transition: all 0.5s; width: 100%; }
.tree li { text-align: center; list-style-type: none; position: relative; padding: 14px 7px 0 7px; transition: all 0.5s; }
.tree li::before, .tree li::after { content: ''; position: absolute; top: 0; right: 50%; border-top: 2px solid #4CAF50; width: 50%; height: 14px; }
.tree li::after { right: auto; left: 50%; border-left: 2px solid #4CAF50; }
.tree li:only-child::after, .tree li:only-child::before { display: none; }
.tree li:first-child::before, .tree li:last-child::after { border: 0 none; }
.tree li:last-child::before { border-right: 2px solid #4CAF50; border-radius: 0 5px 0 0; }
.tree li:first-child::after { border-radius: 5px 0 0 0; }
.tree ul ul::before { content: ''; position: absolute; top: 0; left: 50%; border-left: 2px solid #4CAF50; width: 0; height: 14px; }

.group-node { display: flex; justify-content: center; flex-wrap: wrap; gap: 14px; position: relative; z-index: 2; }
.tree li a, .group-node a, .grid-box a {
    border: 2px solid #555; padding: 8px 4px; text-decoration: none; color: #e0e0e0;
    display: inline-flex; flex-direction: column; align-items: center; justify-content: center;
    border-radius: 8px; background: #112215;
    transition: all 0.3s; width: 140px; box-shadow: 0 4px 6px rgba(0,0,0,0.3); text-align: center; position: relative; z-index: 2;
}
.tree li a:hover, .group-node a:hover, .grid-box a:hover { 
    background: #1a4a27; border-color: #4CAF50; 
    transform: scale(1.1);
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.6); z-index: 10; 
}
.tree li a img, .group-node a img, .grid-box a img { width: 40px; height: 40px; object-fit: cover; border-radius: 50%; margin-bottom: 5px; border: 2px solid #4CAF50; }
.tree li a strong, .group-node a strong, .grid-box a strong { display: block; color: #4CAF50; margin-bottom: 3px; font-size: 0.75rem; text-transform: uppercase; }
.tree li a span, .group-node a span, .grid-box a span { font-size: 0.7rem; color: #bbb; display: block; }

/* Tinggi kartu diseragamkan; lebarnya sengaja dibiarkan mengikuti panjang nama
   (`min-width`, bukan `width`). Tinggi minimumnya harus memuat nama dua baris —
   kartu KOOR tersempit (105px) membungkus "WILLY ANDRIANO OMERO" jadi 129px,
   dan sebelum ini kartu berisi satu baris berhenti di 105px. */
.tree li a, .group-node a { min-height: 132px; }

.koor-node a { min-width: 75px; padding: 6px 2px; }
.koor-node a img { width: 30px; height: 30px; }
.koor-node a strong { font-size: 0.65rem; }

.massive-section { display: flex; flex-direction: column; align-items: center; position: relative; width: 100%; margin-top: -10px;}

/* Keduanya tinggal penyusun jarak; garisnya digambar `.magic-line`.
   Jangan dihapus dari HTML: indeks anaknya dipakai sebagai kunci model portal.
   Tinggi `--tall` dipilih supaya celah "blok → judul seksi" sama dengan blok
   grid lain: di sana celahnya = margin bawah grid (20) + spacer (30) + margin
   atas judul (10) = 60. Di sini `.magic-wrapper` membawa `margin-bottom: -20px`,
   jadi spacer-nya harus 70 supaya sisanya juga 60 — dulu 40, jadi celahnya
   cuma 30 dan judul "Dokter Spesialis" terlihat lebih rapat dari yang lain. */
.center-line { width: 2px; height: 30px; background-color: transparent; margin: 0 auto; z-index: 0; }
.center-line--tall { height: 70px; }

/* Tulang belakang bagan: SATU garis yang tumbuh sendiri setinggi isi bagiannya,
   jadi ia ikut berapa pun jumlah orangnya tanpa diukur tangan. Tingginya
   diukur terhadap `.massive-section`, bukan `.magic-wrapper`: karena itu
   pembungkusnya dibuat `static` (lihat `.magic-wrapper` di bawah) supaya ia
   bukan containing block, dan `top: 0; bottom: 0` di sini berarti tepi atas
   sampai tepi bawah bagian — menutup celah margin antar blok sekaligus. */
.magic-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background-color: #4CAF50;
    transform: translateX(-50%);
    z-index: 0;
}

/* `position: static` disengaja: kalau ia `relative`, ia jadi containing block
   bagi `.magic-line` dan garisnya cuma setinggi cabang, lalu terputus di blok
   berikutnya. */
.magic-wrapper { position: static; width: 100%; display: flex; justify-content: center; margin-bottom: -20px; }
.half-width { flex: 1; width: 50%; }

.magic-branch.left-side { padding-right: 60px !important; }
.magic-branch.right-side { padding-left: 60px !important; }

/* Siku cabang turun di TENGAH ISI, bukan di tengah kotak `li`. Padding 60px
   yang hanya di satu sisi menggeser isi sejauh setengah selisihnya, sedangkan
   persentase pseudo-element mutlak diukur terhadap padding box `li`:
   padding mendatar `.tree li` + (lebar li - padding mendatar - 60px) / 2
   = 7 + (lebar - 67) / 2, jadi isinya di `50% - 26.5px`. Angka 26.5 ini ikut
   padding `li` yang di atas; kalau padding itu diubah, ubah ini juga.
   Mendatarnya direntang `left/right: 0` supaya tetap menyentuh tulang belakang
   di tengah `massive-section`; lebarnya ikut lebar `li`, jadi berapa pun
   anggotanya tetap pas tanpa diukur tangan. */
.magic-branch.left-side::after { left: calc(50% - 26.5px); right: 0; width: auto; }
.magic-branch.right-side::before { right: calc(50% - 26.5px); left: 0; width: auto; }

/* Lapisan garis bagan — lihat `drawWires` di portal.js. `viewBox` SVG-nya
   sebesar kanvas dalam satuan tata letak, jadi gambarnya ikut terskala `zoom`
   persis seperti garis CSS lain. */
.org-chart-canvas { position: relative; }
.org-wires {
    position: absolute; left: 0; top: 0; width: 100%; height: 100%;
    overflow: visible; pointer-events: none; z-index: 0;
}

/* Garis bawaan mati begitu lapisan di atas terpasang — dua set garis sekaligus
   berarti garis dobel. Tanpa JavaScript kelas `wired` tidak pernah dipasang,
   jadi garis bawaannya tetap tampil apa adanya. */
.org-chart-canvas.wired .tree li::before,
.org-chart-canvas.wired .tree li::after,
.org-chart-canvas.wired .tree ul ul::before,
.org-chart-canvas.wired .magic-branch.left-side::after,
.org-chart-canvas.wired .magic-branch.right-side::before,
.org-chart-canvas.wired .igo-wrapper::before,
.org-chart-canvas.wired .igo-wrapper::after { display: none; }

.section-title {
    background: #0d1a11; border: 2px solid #4CAF50; color: #4CAF50;
    padding: 5px 20px; border-radius: 20px; font-weight: bold; font-size: 0.8rem;
    margin: 10px 0; position: relative; z-index: 2; text-transform: uppercase; letter-spacing: 1px;
}

.split-layout {
    display: flex;
    gap: 30px;
    justify-content: center;
    flex-wrap: wrap;
    width: 100%;
    margin-bottom: 20px;
}

/* Grid terakhir tidak menyisakan margin bawah, supaya tulang belakang
   berhenti tepat di tepi bawahnya, bukan 20px di bawahnya. */
.split-layout:last-child { margin-bottom: 0; }

.split-group { 
    display: flex; 
    flex-wrap: wrap; 
    justify-content: center; 
    gap: 14px;
    max-width: 602px;
}

.grid-box a {
    width: 140px;
    min-height: 132px;
    padding: 10px 5px;
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border: 2px solid #555;
    border-radius: 8px;
    background: #112215;
    text-decoration: none;
    transition: all 0.3s;
}

.grid-box a:hover { 
    background: #1a4a27; border-color: #4CAF50; 
    transform: scale(1.1); box-shadow: 0 0 15px rgba(76, 175, 80, 0.6); z-index: 10; 
}

.grid-box a img { 
    width: 45px; 
    height: 45px; 
    object-fit: cover; 
    border-radius: 50%; 
    margin-bottom: 8px; 
    border: 2px solid #4CAF50; 
}

.grid-box a strong { 
    font-size: 0.65rem; 
    text-align: center; 
    margin-bottom: 4px; 
    line-height: 1.2; 
    color: #4CAF50;
}

.grid-box a span { 
    font-size: 0.7rem; 
    color: #bbb;
    text-align: center; 
    word-wrap: break-word;
    width: 100%;
    line-height: 1.3;
}

.modal-content { background: #112215; border: 2px solid #4CAF50; border-radius: 15px; padding: 30px; width: 90%; max-width: 400px; text-align: center; position: relative; box-shadow: 0 0 30px rgba(76, 175, 80, 0.4); animation: scaleUp 0.3s ease-out; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes scaleUp { from { transform: scale(0.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.close-btn { position: absolute; top: 10px; right: 15px; color: #bbb; font-size: 1.5rem; cursor: pointer; transition: 0.3s; font-weight: bold; }
.close-btn:hover { color: #4CAF50; }
.modal-content img { width: 120px; height: 120px; border-radius: 50%; border: 3px solid #4CAF50; object-fit: cover; margin-bottom: 15px; }
.modal-content h3 { color: white; margin-bottom: 5px; font-family: 'Montserrat', sans-serif; }

.rules-container {
    max-width: 750px; 
    margin: 50px auto;
    padding: 0 20px;
    padding-bottom: 80px;
}

.page-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 2.2rem;
    color: white;
    text-align: center;
    margin-bottom: 10px;
    text-transform: uppercase;
    text-shadow: 0 0 15px rgba(76, 175, 80, 0.4);
}

.page-subtitle {
    text-align: center;
    color: #bbb;
    margin-bottom: 40px;
    font-size: 0.95rem;
}

.rule-card {
    background: rgba(17, 34, 21, 0.85);
    border-left: 3px solid #4CAF50;
    border-radius: 8px;
    padding: 20px 25px;
    margin-bottom: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
}

.rule-card:hover {
    transform: translateX(5px);
    box-shadow: 0 8px 25px rgba(76, 175, 80, 0.2);
    border-color: #28a745;
}

.rule-card h2 {
    color: #4CAF50;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.15rem;
    margin-bottom: 0; 
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
}

.rule-card h2::after {
    content: '▼';
    font-size: 0.8rem;
    transition: transform 0.3s ease;
    color: #4CAF50;
}

.rule-card.active h2 {
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(76, 175, 80, 0.2);
}

.rule-card.active h2::after {
    transform: rotate(180deg);
}

.rule-card ul, 
.rule-card .main-list, 
.rule-card .sub-list {
    list-style: none !important;
    padding-left: 0;
    margin: 0;
    display: none;
}

.rule-card.active ul, 
.rule-card.active .main-list {
    display: block;
    padding-top: 15px;
    animation: fadeIn 0.4s ease;
}

.rule-card ul li {
    position: relative;
    padding-left: 25px;
    margin-bottom: 12px;
    color: #d1d1d1;
    line-height: 1.5;
    font-size: 0.95rem;
}

.rule-card ul li::before {
    content: '➔';
    position: absolute;
    left: 0;
    top: 1px;
    color: #1a7a27;
    font-size: 0.85rem;
}

.rule-card .sub-list {
    display: block;
    margin-top: 10px;
    margin-left: 20px;
}

.rule-card .sub-list li::before {
    content: '○';
    color: #4CAF50;
}

.rules-footer-note {
    max-width: 500px;
    margin: 40px auto;
    padding: 15px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px dashed #4CAF50;
    border-radius: 10px;
    text-align: center;
}

.rules-footer-note p {
    color: #ffcc00;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.buku-saku-container {
    max-width: 900px;
    margin: 50px auto;
    padding: 0 20px;
    padding-bottom: 80px;
}

.tabs-header {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.tab-btn {
    background: rgba(17, 34, 21, 0.8);
    border: 2px solid #1a7a27;
    color: #ccc;
    padding: 12px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Montserrat', sans-serif;
    font-weight: bold;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    background: #1a7a27;
    color: white;
}

.tab-btn.active {
    background: #4CAF50;
    color: white;
    border-color: #4CAF50;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.5);
}

.tab-content {
    display: none;
    background: rgba(17, 34, 21, 0.85);
    border-left: 4px solid #4CAF50;
    border-radius: 8px;
    padding: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
    animation: fadeIn 0.4s ease;
    backdrop-filter: blur(5px);
}

.tab-content.active {
    display: block;
}

.tab-content h3 {
    color: #4CAF50;
    font-family: 'Montserrat', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 20px;
    border-bottom: 1px solid rgba(76, 175, 80, 0.3);
    padding-bottom: 10px;
}

.med-table-container {
    overflow-x: auto;
    margin-top: 20px;
}

.med-table {
    width: 100%;
    border-collapse: collapse;
    color: #e0e0e0;
    font-size: 0.9rem;
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.med-table th {
    background: #1a7a27;
    color: white;
    padding: 12px;
    text-align: left;
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 1px solid #28a745;
}

.med-table td {
    padding: 12px;
    border: 1px solid rgba(76, 175, 80, 0.2);
    background: rgba(0, 0, 0, 0.2);
}

.med-table tr:nth-child(even) td {
    background: rgba(17, 34, 21, 0.4);
}

.med-table tr:hover td {
    background: rgba(76, 175, 80, 0.1);
    color: #4CAF50;
    transition: 0.2s;
}

.floating-img {
    animation: float 4s ease-in-out infinite;
}
@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-20px); filter: drop-shadow(0 0 30px rgba(76, 175, 80, 0.6)); }
    100% { transform: translateY(0px); }
}

.glow-text {
    color: transparent;
    -webkit-text-stroke: 2px #4CAF50;
    animation: pulseGlow 2s infinite alternate;
}
@keyframes pulseGlow {
    from { text-shadow: 0 0 10px rgba(76, 175, 80, 0.5), 0 0 20px rgba(76, 175, 80, 0.3); }
    to { text-shadow: 0 0 20px rgba(76, 175, 80, 0.8), 0 0 30px rgba(76, 175, 80, 0.6), 0 0 40px rgba(76, 175, 80, 0.4); }
}

.fade-in-up.delay-1 { animation-delay: 0.2s; }
.fade-in-up.delay-2 { animation-delay: 0.4s; }
.fade-in-up.delay-3 { animation-delay: 0.6s; }

.hero-container {
    position: relative;
    z-index: 10;
}

/* `padding-top` di sini ikut irama 14px bagan (lihat `.tree ul`/`.tree li`).
   Sampingnya tetap 80px: itu pelebar cabang khas halaman EMT, bukan jarak. */
.cabang-lebar { padding: 14px 80px 0 80px !important; }
.igo-li::before, .igo-li::after { border-left: none !important; border-right: none !important; }
.igo-wrapper { position: relative; transform: translateX(110px); z-index: 3; }
.igo-wrapper > a::before { display: none !important; }
.igo-wrapper::before { content: ''; position: absolute; top: -14px; left: -110px; width: calc(110px + 50%); height: 2px; background: #4CAF50; z-index: 1; }
.igo-wrapper::after { content: ''; position: absolute; top: -14px; left: 50%; width: 2px; height: 14px; background: #4CAF50; transform: translateX(-50%); z-index: 1; }

.modal { 
    display: none; 
    position: fixed; 
    z-index: 9999; 
    left: 0; 
    top: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(6px);
    justify-content: center; 
    align-items: center; 
}

.modal-content { 
    background: linear-gradient(145deg, rgba(16, 30, 20, 0.95), rgba(10, 20, 13, 0.95)); 
    padding: 40px 30px 35px 30px; 
    border-radius: 16px; 
    border: 1px solid rgba(76, 175, 80, 0.3);
    text-align: center; 
    position: relative; 
    width: 340px;
    max-width: 85%; 
    box-shadow: 0 20px 40px rgba(0,0,0,0.8), 0 0 20px rgba(76, 175, 80, 0.15);
    animation: modalFadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalFadeIn { 
    from { transform: translateY(20px) scale(0.95); opacity: 0; } 
    to { transform: translateY(0) scale(1); opacity: 1; } 
}

.close-btn { 
    color: rgba(255, 255, 255, 0.4); 
    position: absolute; 
    top: 12px; 
    right: 18px; 
    font-size: 28px; 
    font-weight: normal; 
    cursor: pointer; 
    transition: all 0.3s ease; 
    line-height: 1;
}

.close-btn:hover, .close-btn:focus { 
    color: #ff4c4c; 
    transform: scale(1.1);
}

#modalImg { 
    width: 130px; 
    height: 130px; 
    border-radius: 50%; 
    object-fit: cover; 
    border: 3px solid #4CAF50; 
    margin-bottom: 18px; 
    box-shadow: 0 0 20px rgba(76, 175, 80, 0.3);
    background: #111;
}

#modalRole { 
    color: #4CAF50; 
    margin: 0 0 8px 0; 
    font-size: 0.9rem; 
    letter-spacing: 2px; 
    text-transform: uppercase; 
    font-weight: 600;
}

#modalName { 
    color: #ffffff; 
    margin: 0; 
    font-size: 1.4rem; 
    font-weight: 700;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}
.portal-body {
  display: flex; flex-direction: column; min-height: 100vh;
}

.ic { vertical-align: -0.125em; flex-shrink: 0; }

.btn-editor {
    background-color: #4CAF50;
    color: #ffffff;
    padding: 8px 18px;
    border-radius: 20px;
    text-decoration: none;
    font-weight: 600;
    margin-left: 10px;
    transition: all 0.3s ease;
}
.btn-editor:hover {
    background-color: #45a049;
    box-shadow: 0 0 15px rgba(76, 175, 80, 0.4);
    transform: translateY(-2px);
}

body.pe-side-open { display: flex; flex-wrap: wrap; align-items: flex-start; flex-direction: row; }
body.pe-side-open nav { flex: 0 0 100%; order: -2; }

.pe-content { flex: 1; min-width: 0; }

@media (max-width: 900px) {
    body.pe-side-open { display: block; }
}

body.pe-embed .pe-content { flex-basis: 100%; }

.pe-editing [data-portal-block],
.pe-editing [data-portal-item] {
    outline: 1px dashed rgba(76, 175, 80, 0.55);
    outline-offset: 2px; border-radius: 4px;
}
.pe-editing [data-portal-item] { position: relative; }
.pe-editing [data-portal-block]:focus,
.pe-editing [data-portal-item]:focus {
    outline: 2px solid #4CAF50; background: rgba(76, 175, 80, 0.1);
}
.pe-flash { animation: pe-flash 1.2s ease; }
@keyframes pe-flash {
    0%, 100% { box-shadow: 0 0 0 0 rgba(76, 175, 80, 0); }
    35% { box-shadow: 0 0 0 6px rgba(76, 175, 80, 0.55); }
}

.org-chart-canvas { width: 1400px; min-width: 100%; }

.org-chart-wrapper { overflow-x: auto; }

.pe-editing .pe-photo { cursor: pointer; outline: 2px dashed rgba(76, 175, 80, 0.85); }
.pe-editing .pe-item-btn {
    width: 20px; height: 20px; line-height: 19px;
    text-align: center; border-radius: 50%; font-size: 13px; font-weight: 700;
    cursor: pointer; z-index: 10; user-select: none;
}

.pe-editing .pe-item-tools {
    position: absolute; bottom: 4px; left: 50%; transform: translateX(-50%);
    display: flex; gap: 4px; z-index: 10;
}
.pe-editing .pe-add { background: #4CAF50; color: #06100a; }
.pe-editing .pe-del { background: #c62828; color: #ffffff; }

@media (max-width: 900px) {
    nav {
        flex-wrap: wrap;
        padding: 12px 16px;
        gap: 8px 12px;
    }
    .nav-logo { font-size: 1rem; }
    .nav-links {
        order: 3;
        flex-basis: 100%;
        margin: 0;
        gap: 4px 18px;
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .nav-item {
        display: inline-flex;
        align-items: center;
        min-height: 44px;
        font-size: 0.85rem;
    }
    .btn-discord,
    .btn-editor,
    .btn-primary {
        min-height: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        padding: 8px 14px;
    }

    .dropdown {
        padding-bottom: 0;
        margin-bottom: 0;
    }
    .dropdown-content {
        position: static;
        left: auto;
        min-width: 0;
        margin-top: 4px;
        animation: none;
        box-shadow: none;
    }
    .dropdown:focus-within .dropdown-content { display: block; }
    .dropdown-content a { padding: 12px 14px; }

    .hero-container {
        flex-direction: column;
        text-align: center;
        gap: 28px;
        margin: 48px auto;
        padding: 0 20px;
    }
    .hero-text,
    .hero-image { min-width: 0; max-width: 100%; }

    .hero-text h1 { font-size: clamp(2rem, 9vw, 3rem); }
    .hero-text p { font-size: 1rem; line-height: 1.7; }
    .hero-image { justify-content: center; }
    .hero-image img { width: 100%; max-width: 320px; }
    .hero-buttons { justify-content: center; flex-wrap: wrap; }

    .page-title {
        font-size: clamp(1.4rem, 6.5vw, 2.2rem);

        overflow-wrap: anywhere;
    }

    .rules-container { margin: 32px auto; padding: 0 14px; padding-bottom: 56px; }
    .rule-card { padding: 16px 18px; }

    .rule-card ul li { padding-left: 18px; }
    .rule-card .sub-list { margin-left: 10px; }
    .rule-card h2 { font-size: 1.05rem; min-height: 44px; display: flex; align-items: center; }

    .tab-content { padding: 18px; }
    .tab-btn { padding: 10px 16px; min-height: 44px; }
    .med-table th,
    .med-table td { padding: 8px; }
    .med-table { font-size: 0.82rem; }

    img { max-width: 100%; }
}

body .coming-soon-title {
    font-size: clamp(1.8rem, 9vw, 4rem);
    letter-spacing: clamp(2px, 1.1vw, 8px);
    max-width: 100%;
}

@media (max-width: 520px) {
    .rules-container { margin: 24px auto; padding: 0 12px; padding-bottom: 40px; }
    .rule-card { padding: 14px 14px; }
    .tab-content { padding: 14px; }
    .med-table th,
    .med-table td { padding: 6px; }
    .hero-container { margin: 32px auto; padding: 0 14px; gap: 20px; }
    .hero-text h1 { font-size: clamp(1.7rem, 10vw, 2.4rem); }
    .hero-image img { max-width: 240px; }

    body .coming-soon-sub { font-size: 1rem; letter-spacing: 1px; }
    body .coming-soon-container { padding: 0 16px; }

    body .modal-content { min-width: 0; padding: 24px 18px; }
}
