/*
Theme Name: BantuBelajar
Theme URI: https://example.com/bantubelajar
Author: Kelompok 1 PAPB
Description: Proposal BantuBelajar dalam bentuk website. Beranda dengan hero, deskripsi umum, dan 10 halaman bab sesuai poin di proposal.
Version: 5.0.1
Requires at least: 6.0
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bantubelajar
*/

/* ---------- Token (warna dan font dari versi sebelumnya) ---------- */
:root {
	--ink: #202E46;
	--ink-2: #5B6478;
	--ink-3: #8A93A6;
	--bg: #FBFAF7;
	--sheet: #FFFFFF;
	--line: #ECE8E4;
	--accent: #E34142;
	--accent-2: #F26B6B;
	--accent-soft: #FDECEA;
	--accent-tint: #FEF6F5;
	--r-lg: 24px;
	--r-md: 16px;
	--r-sm: 10px;
	--shadow-sm: 0 1px 2px rgba(32, 46, 70, .05), 0 6px 18px -10px rgba(32, 46, 70, .14);
	--wrap: 1200px;
	--gut: clamp(18px, 4vw, 40px);
	--f: "Plus Jakarta Sans", "Segoe UI", system-ui, -apple-system, sans-serif;
}

/* ---------- Dasar ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 96px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 16px/1.72 var(--f); -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img, svg { max-width: 100%; height: auto; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--ink); color: #fff; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.wrap { width: min(100% - 2 * var(--gut), var(--wrap)); margin-inline: auto; position: relative; }

h1, h2, h3, h4 { font-family: var(--f); color: var(--ink); margin: 0; letter-spacing: -.025em; line-height: 1.2; }
h1 { font-size: 40px; font-weight: 800; }
h2 { font-size: 30px; font-weight: 800; }
h3 { font-size: 20px; font-weight: 700; margin: 36px 0 12px; }
h4 { font-size: 17px; font-weight: 700; }
p { margin: 0 0 16px; }
ul, ol { margin: 0 0 18px; padding-left: 22px; }
li { margin-bottom: 6px; }
strong { font-weight: 700; }
.small { font-size: 14px; line-height: 1.6; color: var(--ink-2); }

.btn { display: inline-flex; align-items: center; justify-content: center; font: 700 15px/1.2 var(--f); padding: 14px 26px; border-radius: 999px; border: 2px solid transparent; text-decoration: none; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s, transform .2s; }
.btn:hover { transform: translateY(-1px); }
.btn--solid { background: var(--accent); color: #fff; box-shadow: 0 10px 22px -10px rgba(227, 65, 66, .6); }
.btn--solid:hover { background: #C93536; color: #fff; }
.btn--line { background: #fff; color: var(--ink); border-color: var(--line); }
.btn--line:hover { border-color: var(--ink); color: var(--ink); }
.btn--sm { padding: 11px 22px; font-size: 14px; }
.eyebrow { font: 700 13px/1 var(--f); letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }

/* ---------- Header (menu di tengah, seperti screenshot) ---------- */
.top { position: sticky; top: 0; z-index: 60; background: rgba(255, 255, 255, .94); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.top__in { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 16px; height: 76px; padding: 0 var(--gut); max-width: 1320px; margin: 0 auto; }
.brand img { display: block; height: 44px; width: auto; }
.top__nav { display: flex; align-items: center; justify-content: center; gap: 30px; }
.top__nav a { font: 600 15px/1 var(--f); color: var(--ink); text-decoration: none; padding: 10px 0; position: relative; white-space: nowrap; }
.top__nav a:hover { color: var(--accent); }
.top__nav a.is-active { color: var(--accent); }
.top__nav a.is-active::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 3px; border-radius: 3px; background: var(--accent); }
.top__right { display: flex; justify-content: flex-end; align-items: center; gap: 12px; }
.menu-toggle { display: none; font: 700 14px/1 var(--f); color: var(--ink); background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: 10px 16px; cursor: pointer; }

/* ---------- Beranda ---------- */
.hero { position: relative; overflow: hidden; padding: 84px 0 96px; background: radial-gradient(900px 500px at 92% 0%, #FDE3E0 0%, transparent 60%), radial-gradient(700px 400px at 0% 100%, #EEF1F7 0%, transparent 65%), var(--bg); }
.hero__blob { position: absolute; right: -10%; top: 8%; width: 56%; aspect-ratio: 1; border-radius: 46% 54% 42% 58% / 52% 40% 60% 48%; background: linear-gradient(150deg, var(--accent-2), var(--accent)); opacity: .12; pointer-events: none; }
.hero__grid { position: relative; z-index: 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 72px; align-items: center; }
.hero h1 { font-size: 60px; line-height: 1.05; letter-spacing: -.035em; margin-bottom: 24px; }
.hero h1 .hl { color: var(--accent); }
.lede { font-size: 18px; color: var(--ink-2); max-width: 34em; }
.actions { display: flex; flex-wrap: wrap; gap: 14px; margin: 30px 0 20px; }
.hero__visual { position: relative; padding: 16px 0 0 40px; }
.hero__photo { position: relative; border-radius: 220px 220px 36px 36px; overflow: hidden; aspect-ratio: 4 / 4.4; box-shadow: 0 40px 70px -34px rgba(32, 46, 70, .45); background: #F3EFEA; }
.hero__photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 30%; }
.phone--glass { position: absolute; left: -10px; bottom: -8px; width: min(88%, 330px); background: rgba(255, 255, 255, .62); backdrop-filter: blur(18px) saturate(140%); -webkit-backdrop-filter: blur(18px) saturate(140%); border: 1px solid rgba(255, 255, 255, .75); border-radius: 28px; padding: 18px 16px; box-shadow: 0 30px 60px -24px rgba(32, 46, 70, .35), inset 0 1px 0 rgba(255, 255, 255, .7); font-family: var(--f); }
.phone__bar { display: flex; justify-content: space-between; font: 700 11.5px/1 var(--f); color: var(--ink-2); padding: 2px 8px 12px; }
.phone__title { font: 800 21px/1.2 var(--f); letter-spacing: -.02em; padding: 0 8px; margin: 0; }
.phone__sub { font: 500 13px/1.4 var(--f); color: var(--ink-2); padding: 4px 8px 12px; margin: 0; }
.opp { display: grid; grid-template-columns: 1fr auto; gap: 2px 12px; align-items: center; padding: 12px 10px; margin: 0 0 8px; border-radius: var(--r-sm); background: rgba(255, 255, 255, .6); }
.opp__name { font: 700 14px/1.3 var(--f); margin: 0; }
.opp__meta { font: 500 12px/1.4 var(--f); color: var(--ink-2); margin: 0; grid-column: 1; }
.opp__btn { grid-column: 2; grid-row: 1 / span 2; font: 700 13px/1 var(--f); padding: 10px 14px; border: 0; border-radius: 999px; background: var(--accent); color: #fff; cursor: pointer; min-width: 88px; }
.opp__btn[aria-pressed="true"] { background: #17955F; }
.phone__nav { display: flex; justify-content: space-around; margin-top: 12px; padding: 12px 6px 0; border-top: 1px solid rgba(32, 46, 70, .08); font: 600 12px/1 var(--f); color: var(--ink-2); }
.phone__nav b { color: var(--accent); }
.hero__cap { margin: 14px 0 0; text-align: right; font-size: 12.5px; }

.home-desc { padding: 96px 0 64px; background: var(--sheet); border-top: 1px solid var(--line); scroll-margin-top: 80px; }
.home-desc__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr); gap: 64px; align-items: start; }
.home-desc__head h2 { font-size: 36px; line-height: 1.15; }
.home-desc .prose { max-width: 720px; }

.chapters { padding: 80px 0 104px; }
.chapters h2 { font-size: 36px; margin-bottom: 36px; }
.chapter-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.chapter-card { display: flex; flex-direction: column; gap: 8px; padding: 26px 26px 24px; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-md); text-decoration: none; color: var(--ink); box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s, border-color .2s; min-height: 170px; }
.chapter-card:hover { transform: translateY(-3px); border-color: #F5C4C2; color: var(--ink); }
.chapter-card__num { font: 800 13px/1 var(--f); color: var(--accent); letter-spacing: .08em; }
.chapter-card__title { font: 700 17px/1.35 var(--f); letter-spacing: -.01em; }
.chapter-card__count { font: 500 13px/1.4 var(--f); color: var(--ink-3); margin-top: auto; padding-top: 10px; }

/* ---------- Halaman bab ---------- */
.docs { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 48px; width: min(100% - 2 * var(--gut), var(--wrap)); margin: 0 auto; padding: 44px 0 88px; align-items: start; }
.docs__side { position: sticky; top: 100px; max-height: calc(100vh - 124px); overflow-y: auto; overscroll-behavior: contain; padding-right: 6px; scrollbar-width: thin; }
.side__label { font: 800 12px/1 var(--f); letter-spacing: .12em; text-transform: uppercase; color: var(--ink-3); margin: 0 0 14px; }
.side__list { list-style: none; padding: 0; margin: 0; }
.side__item { margin: 0 0 4px; }
.side__item > a { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--r-sm); text-decoration: none; color: var(--ink-2); font: 500 14px/1.45 var(--f); }
.side__item > a:hover { background: #fff; color: var(--ink); }
.side__num { font: 800 12px/1.6 var(--f); color: var(--ink-3); flex: none; }
.side__item.is-current > a { background: var(--sheet); color: var(--accent); font-weight: 700; box-shadow: var(--shadow-sm); }
.side__item.is-current .side__num { color: var(--accent); }
.side__sub { list-style: none; padding: 4px 0 10px 40px; margin: 0; border-left: 2px solid var(--accent-soft); margin-left: 22px; }
.side__sub li { margin: 0; }
.side__sub a { display: block; padding: 6px 10px; font: 500 13px/1.45 var(--f); color: var(--ink-2); text-decoration: none; border-radius: 8px; }
.side__sub a:hover { color: var(--accent); background: var(--accent-tint); }

.docs__main { min-width: 0; }
.docs__head { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); padding: 44px 52px 36px; margin-bottom: 20px; }
.crumb { font: 700 12px/1 var(--f); letter-spacing: .1em; text-transform: uppercase; color: var(--accent); margin-bottom: 14px; }
.docs__title { font-size: 38px; line-height: 1.15; }
.sec-block, .prose--intro { background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-sm); padding: 40px 52px 36px; margin-bottom: 20px; scroll-margin-top: 100px; }
.sec-block__title { font-size: 26px; line-height: 1.25; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.prose { max-width: 740px; font-size: 16px; }
.prose > *:first-child { margin-top: 0; }
.prose p { color: #2E3A52; }
.prose h2 { font-size: 22px; margin: 0 0 14px; }
.prose h3 { font-size: 19px; color: var(--ink); padding-left: 14px; border-left: 3px solid var(--accent); margin-top: 34px; }
.prose h4 { font-size: 16px; margin: 24px 0 8px; }
.prose ul li::marker { color: var(--accent); }
.prose blockquote { margin: 0 0 18px; padding: 16px 20px; background: var(--accent-tint); border-radius: var(--r-sm); border-left: 3px solid var(--accent-2); color: #2E3A52; }
.prose blockquote p { margin: 0 0 10px; }
.prose blockquote p:last-child { margin: 0; }
.prose figure, .figure { margin: 28px 0; background: var(--bg); border: 1px solid var(--line); border-radius: var(--r-md); padding: 24px; }
.prose figure svg, .figure svg { display: block; width: 100%; height: auto; }
.figure figcaption { font-size: 14px; color: var(--ink-2); text-align: center; padding-top: 12px; }
.tbl { overflow-x: auto; margin: 24px 0 28px; border: 1px solid var(--line); border-radius: var(--r-md); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.6; min-width: 480px; }
.prose th { background: var(--accent-soft); color: var(--ink); text-align: left; font: 700 13.5px/1.3 var(--f); padding: 13px 16px; }
.prose td { padding: 13px 16px; border-top: 1px solid var(--line); vertical-align: top; color: #2E3A52; }
.prose tbody tr:first-child td { border-top: 0; }
.prose td:first-child { font-weight: 600; color: var(--ink); }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 8px; }
.pager__card { display: flex; flex-direction: column; gap: 6px; padding: 20px 24px; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-md); text-decoration: none; color: var(--ink); box-shadow: var(--shadow-sm); transition: border-color .2s; }
.pager__card:hover { border-color: #F5C4C2; color: var(--ink); }
.pager__card--next { text-align: right; align-items: flex-end; grid-column: 2; }
.pager__label { font: 700 12px/1 var(--f); letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.pager__title { font: 700 15px/1.4 var(--f); }

.page-plain { padding: 72px 0; }
.page-plain h1 { margin-bottom: 20px; }

/* ---------- Footer ---------- */
.foot { background: var(--ink); color: #B8C2D3; padding: 64px 0 0; margin-top: 40px; border-radius: 36px 36px 0 0; font-size: 15px; }
.foot__in { display: grid; grid-template-columns: 1fr 1.6fr; gap: 48px; }
.foot__logo { display: block; width: 170px; height: auto; background: #fff; border-radius: 16px; padding: 10px 14px; margin-bottom: 18px; }
.foot__txt { margin: 0 0 14px; max-width: 42ch; }
.foot__head { font: 700 15px/1.4 var(--f); color: #fff; margin: 0 0 12px; }
.foot__list { list-style: none; padding: 0; margin: 0; columns: 2; column-gap: 28px; }
.foot__list li { margin-bottom: 8px; break-inside: avoid; }
.foot a { color: #B8C2D3; text-decoration: none; font-size: 14px; }
.foot a:hover { color: #FFE08A; }
.foot__bar { border-top: 1px solid #34455F; margin-top: 44px; padding: 22px 0 28px; font-size: 13.5px; }
.foot__bar p { margin: 0; }

/* ---------- Diagram arsitektur ---------- */
.d-layer { stroke-width: 1.5; }
.d-layer--users { fill: #F3F4F7; stroke: #9AA3B5; }
.d-layer--app { fill: var(--accent-soft); stroke: var(--accent); }
.d-layer--cloud { fill: #FFF4D6; stroke: #B98700; }
.d-layer--ext { fill: #E3F6EE; stroke: #17955F; }
.d-box { fill: #fff; stroke: #D5DBE5; stroke-width: 1.5; }
.d-title { font: 700 12px var(--f); fill: var(--ink-2); letter-spacing: .04em; }
.d-txt { font: 700 12.5px var(--f); fill: var(--ink); }
.d-sub { font: 500 11px var(--f); fill: var(--ink-2); }
.d-line { stroke: var(--ink-2); stroke-width: 1.6; fill: none; }
.d-cap { font: 500 10.5px var(--f); fill: var(--ink-2); font-style: italic; }

/* ---------- Responsif ---------- */
@media (max-width: 1140px) {
	.top__in { grid-template-columns: auto 1fr; }
	.top__nav { gap: 20px; }
	.top__nav a { font-size: 14px; }
}
@media (max-width: 1040px) {
	.docs { grid-template-columns: 250px minmax(0, 1fr); gap: 28px; }
	.hero__grid { grid-template-columns: minmax(0, 1fr); gap: 56px; }
	.hero__visual { max-width: 520px; width: 100%; margin: 0 auto; }
	.hero h1 { font-size: 50px; }
	.home-desc__grid { grid-template-columns: minmax(0, 1fr); gap: 24px; }
	.chapter-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
	.top__in { grid-template-columns: 1fr auto; height: 66px; }
	.top__nav { display: none; position: absolute; top: 66px; left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0; background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow-sm); padding: 8px var(--gut) 14px; }
	.top__nav.is-open { display: flex; }
	.top__nav a { padding: 14px 0; border-bottom: 1px solid var(--line); }
	.top__nav a.is-active::after { display: none; }
	.top__right .btn { display: none; }
	.menu-toggle { display: inline-block; }
	.brand img { height: 38px; }
	.docs { grid-template-columns: minmax(0, 1fr); }
	.docs__side { position: static; max-height: none; overflow: visible; background: var(--sheet); border: 1px solid var(--line); border-radius: var(--r-lg); padding: 18px; box-shadow: var(--shadow-sm); }
	.docs__head, .sec-block, .prose--intro { padding: 28px 24px; }
	.docs__title { font-size: 30px; }
	.sec-block__title { font-size: 22px; }
}
@media (max-width: 760px) {
	.hero { padding: 48px 0 64px; }
	.hero h1 { font-size: 38px; }
	.hero__photo { border-radius: 140px 140px 28px 28px; aspect-ratio: 1 / 1.05; }
	.phone--glass { position: relative; left: auto; bottom: auto; margin: -56px 0 0 auto; width: 92%; }
	.hero__cap { text-align: left; }
	.home-desc__head h2, .chapters h2 { font-size: 28px; }
	.chapter-grid { grid-template-columns: minmax(0, 1fr); }
	.pager { grid-template-columns: minmax(0, 1fr); }
	.pager__card--next { grid-column: 1; text-align: left; align-items: flex-start; }
	.foot__in { grid-template-columns: minmax(0, 1fr); }
	.foot__list { columns: 1; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
