:root {
  --bg: #f6f2ea;
  --ink: #1d1a2e;
  --muted: #5d5873;
  --violet: #3b3a8f;
  --violet-deep: #2a2870;
  --red: #e2231a;
  --card: #ffffff;
  --line: #e4ddd0;
  --radius: 18px;
  --shadow: 0 2px 0 var(--ink);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.6 "Inter", system-ui, sans-serif;
}
h1, h2, h3 { font-family: "Bricolage Grotesque", system-ui, sans-serif; line-height: 1.15; margin: 0 0 .5em; }
a { color: var(--violet); }
img { max-width: 100%; display: block; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }

/* Header */
.site-header { background: var(--violet-deep); color: #fff; position: sticky; top: 0; z-index: 50; }
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.logo { color: #fff; text-decoration: none; font: 800 1.35rem "Bricolage Grotesque", sans-serif; display: flex; align-items: center; gap: 10px; }
.logo-mark { background: var(--red); width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center; font-size: 1.1rem; transform: rotate(-6deg); }

/* Hero */
.hero { background: radial-gradient(120% 90% at 80% 10%, #5b59c9 0%, var(--violet) 45%, var(--violet-deep) 100%); color: #fff; padding: 72px 0 84px; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; color: #ffd7d4; font-weight: 600; margin: 0 0 12px; }
.hero h1 { font-size: clamp(2.4rem, 6vw, 4.4rem); font-weight: 800; }
.hero h1 span { color: #fff; background: var(--red); padding: 0 .2em; box-decoration-break: clone; -webkit-box-decoration-break: clone; }
.hero .lead { max-width: 560px; color: #e6e4ff; font-size: 1.1rem; }

/* Buttons */
.btn {
  display: inline-block; background: var(--red); color: #fff; border: 2px solid var(--ink);
  padding: 12px 22px; border-radius: 999px; font-weight: 700; text-decoration: none;
  cursor: pointer; font-size: 1rem; box-shadow: 0 4px 0 var(--ink); transition: transform .1s, box-shadow .1s;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 5px 0 var(--ink); }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }
.btn-block { width: 100%; margin-top: 18px; }
.btn-ghost { background: #fff; color: var(--ink); }

/* Sections & cards */
.section { padding: 48px 0 8px; }
.section h2 { font-size: 1.9rem; }
.section-sub { color: var(--muted); margin-top: -6px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 18px; margin-top: 20px; }
.card {
  background: var(--card); border: 2px solid var(--ink); border-radius: var(--radius);
  padding: 20px; text-decoration: none; color: var(--ink); display: flex; flex-direction: column;
  box-shadow: 0 5px 0 var(--ink); transition: transform .12s, box-shadow .12s;
}
.card:hover { transform: translateY(-3px) rotate(-.4deg); box-shadow: 0 8px 0 var(--ink); }
.card-icon { font-size: 2rem; width: 56px; height: 56px; display: grid; place-items: center; background: #ece9ff; border-radius: 14px; margin-bottom: 12px; }
.card h3 { font-size: 1.2rem; margin-bottom: 6px; }
.card p { color: var(--muted); margin: 0 0 14px; font-size: .95rem; flex: 1; }
.card-go { color: var(--red); font-weight: 700; font-size: .9rem; }

.steps { padding-left: 1.2em; }
.steps li { margin-bottom: 8px; }
.note { color: var(--muted); font-size: .92rem; background: #fff; border: 1px dashed var(--line); padding: 12px 14px; border-radius: 12px; }

/* Tool page */
.tool-page { padding: 32px 16px 24px; }
.back { text-decoration: none; font-weight: 600; font-size: .95rem; }
.tool-page h1 { font-size: clamp(1.9rem, 4.5vw, 2.8rem); margin-top: 14px; display: flex; align-items: center; gap: 12px; }
.title-icon { font-size: .9em; }
.tool-page .lead { color: var(--muted); max-width: 640px; }
.tool-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 22px; margin-top: 24px; align-items: start; }
.panel { background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); padding: 22px; box-shadow: 0 5px 0 var(--ink); }

.tabs { display: flex; background: #efeae0; border-radius: 999px; padding: 4px; margin-bottom: 16px; }
.tab { flex: 1; border: 0; background: transparent; padding: 10px; border-radius: 999px; font-weight: 600; cursor: pointer; color: var(--muted); font-size: .95rem; }
.tab.active { background: var(--violet); color: #fff; }

.drop {
  position: relative; display: grid; place-items: center; min-height: 240px; border: 2px dashed #b9b3d8;
  border-radius: 14px; background: #faf8ff; cursor: pointer; overflow: hidden; text-align: center; padding: 16px;
}
.drop.dragover { border-color: var(--violet); background: #eeebff; }
.drop input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.drop img { max-height: 320px; border-radius: 10px; }
.drop-text small { color: var(--muted); }
.check { display: flex; gap: 10px; align-items: flex-start; margin-top: 14px; font-size: .92rem; color: var(--muted); }
.check input { margin-top: 4px; accent-color: var(--violet); }
.label { font-weight: 600; display: block; margin-bottom: 8px; }
textarea { width: 100%; border: 2px solid var(--line); border-radius: 12px; padding: 12px; font: inherit; resize: vertical; }
textarea:focus { outline: none; border-color: var(--violet); }
.hint { color: var(--muted); }
.quota { text-align: center; color: var(--muted); font-size: .9rem; margin: 12px 0 0; }
.error { background: #ffeceb; color: #a3150f; border: 1px solid #f6b9b5; padding: 10px 12px; border-radius: 10px; margin: 12px 0 0; font-size: .93rem; }
.hp { position: absolute; left: -9999px; }

.result { min-height: 380px; display: grid; place-items: center; text-align: center; background: repeating-linear-gradient(45deg, #fff, #fff 12px, #fbf9f4 12px, #fbf9f4 24px); }
.result-icon { font-size: 3rem; opacity: .6; }
.result-empty p { color: var(--muted); }
.result figure { margin: 0; width: 100%; }
.result figure img { border-radius: 12px; margin: 0 auto; border: 2px solid var(--ink); }
.result figcaption { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }
.loading small { color: var(--muted); }
.spinner { width: 54px; height: 54px; border: 6px solid #e4e1fb; border-top-color: var(--red); border-radius: 50%; margin: 0 auto 14px; animation: spin 1s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

.tips { padding-left: 1.2em; color: var(--muted); }
.ad { margin: 28px 0; min-height: 90px; }
.prose { max-width: 760px; }
.prose h2 { font-size: 1.3rem; margin-top: 1.6em; }


@media (max-width: 820px) {
  .tool-layout { grid-template-columns: 1fr; }
  .hero { padding: 48px 0 56px; }
}

/* Artikel */
.page-title { font-size: clamp(2rem, 5vw, 2.8rem); }
.article-card h3 { font-size: 1.1rem; }
.pager { display: flex; gap: 8px; margin-top: 28px; flex-wrap: wrap; }
.pager a { border: 2px solid var(--ink); border-radius: 10px; padding: 6px 13px; text-decoration: none; color: var(--ink); font-weight: 700; background: #fff; }
.pager a.current { background: var(--violet); color: #fff; }
.article { max-width: 780px; padding-top: 32px; }
.article-head { margin: 18px 0 26px; }
.article-icon { font-size: 2.4rem; display: inline-grid; place-items: center; width: 72px; height: 72px; background: #ece9ff; border: 2px solid var(--ink); border-radius: 18px; margin-bottom: 14px; }
.article-head h1 { font-size: clamp(1.9rem, 4.5vw, 2.7rem); }
.meta { color: var(--muted); font-size: .92rem; margin: 0; }
.article-body { font-size: 1.07rem; }
.article-body h2 { font-size: 1.45rem; margin-top: 1.7em; }
.article-body li { margin-bottom: 6px; }
.article-body table { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: .95rem; display: block; overflow-x: auto; }
.article-body th, .article-body td { border: 1px solid var(--line); padding: 9px 11px; text-align: left; }
.article-body th { background: #ece9ff; }
.cta { margin: 36px 0 8px; text-align: center; background: #ece9ff; }
.cta h2 { margin-top: 0; }


/* ===== Navigasi ===== */
.skip { position: absolute; left: -999px; top: 8px; background: #fff; color: var(--ink); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav > a, .dd-btn {
  color: #d9d7ff; text-decoration: none; font: 600 .95rem "Inter", sans-serif; padding: 8px 12px;
  border-radius: 10px; background: none; border: 0; cursor: pointer; display: flex; align-items: center; gap: 6px;
}
.site-nav > a:hover, .dd-btn:hover, .site-nav > a.active, .dd-btn.active { color: #fff; background: rgba(255,255,255,.1); }
.caret { display: inline-block; font-size: .7rem; transition: transform .15s; }
.dd { position: relative; }
.dd.open .caret { transform: rotate(180deg); }
.dd-menu {
  display: none; position: absolute; top: calc(100% + 8px); left: 0; min-width: 260px; background: #fff;
  border: 2px solid var(--ink); border-radius: 14px; box-shadow: 0 6px 0 var(--ink); padding: 8px; z-index: 60;
}
.dd.open .dd-menu { display: block; }
.dd-menu a { display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 9px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .93rem; }
.dd-menu a:hover { background: #ece9ff; }
.dd-menu a span { width: 26px; text-align: center; }
.menu-toggle { display: none; background: none; border: 2px solid rgba(255,255,255,.35); border-radius: 10px; width: 44px; height: 40px; cursor: pointer; padding: 0; flex-direction: column; justify-content: center; align-items: center; gap: 5px; }
.menu-toggle span { display: block; width: 20px; height: 2px; background: #fff; border-radius: 2px; transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 900px) {
  .menu-toggle { display: flex; }
  .site-nav {
    display: none; position: absolute; top: 64px; left: 0; right: 0; background: var(--violet-deep);
    flex-direction: column; align-items: stretch; padding: 8px 16px 18px; gap: 2px;
    max-height: calc(100vh - 64px); overflow-y: auto; border-top: 1px solid rgba(255,255,255,.12);
  }
  .site-nav.open { display: flex; }
  .site-nav > a, .dd-btn { width: 100%; justify-content: space-between; padding: 12px; font-size: 1rem; }
  .dd-menu { position: static; box-shadow: none; border: 0; background: rgba(255,255,255,.06); margin: 2px 0 6px; min-width: 0; }
  .dd-menu a { color: #e6e4ff; }
  .dd-menu a:hover { background: rgba(255,255,255,.1); }
  body.nav-open { overflow: hidden; }
}

/* Breadcrumb */
.crumbs ol { list-style: none; padding: 0; margin: 0 0 6px; display: flex; flex-wrap: wrap; gap: 4px; font-size: .9rem; color: var(--muted); }
.crumbs li:not(:last-child)::after { content: "›"; margin-left: 6px; color: #a9a4c0; }
.crumbs a { text-decoration: none; font-weight: 600; }
.crumbs a:hover { text-decoration: underline; }
.crumbs span { overflow: hidden; text-overflow: ellipsis; }

/* Chip tool lainnya */
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { display: inline-flex; align-items: center; gap: 8px; background: #fff; border: 2px solid var(--ink); border-radius: 999px; padding: 8px 14px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .92rem; }
.chip:hover { background: #ece9ff; }

/* Footer */
.site-footer { margin-top: 64px; background: var(--ink); color: #b8b4d0; font-size: .92rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 28px; padding-top: 44px; padding-bottom: 28px; }
.footer-grid h3 { color: #fff; font-size: 1rem; margin-bottom: 12px; }
.footer-grid a:not(.logo) { display: block; color: #cfcbe6; text-decoration: none; padding: 4px 0; }
.footer-grid a:not(.logo):hover { color: #fff; text-decoration: underline; }
.footer-brand p { margin-top: 12px; max-width: 280px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 18px; padding-bottom: 22px; }
.footer-bottom p { margin: 0; }
@media (max-width: 820px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }

/* Tentang & Kontak */
.lead-dark { font-size: 1.15rem; color: var(--ink); }
.contact-layout { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 22px; margin-top: 20px; align-items: start; }
.contact-form .label { margin-top: 14px; }
.contact-form .label:first-of-type { margin-top: 0; }
.input { width: 100%; border: 2px solid var(--line); border-radius: 12px; padding: 11px 12px; font: inherit; background: #fff; }
.input:focus { outline: none; border-color: var(--violet); }
.contact-info .panel h2 { font-size: 1.2rem; margin-top: 0; }
.contact-info p { color: var(--muted); font-size: .95rem; }
.success { background: #e6f6eb; color: #14612f; border: 1px solid #b6e3c4; padding: 10px 12px; border-radius: 10px; margin: 0 0 12px; }
.contact-form .error { margin: 0 0 10px; }
@media (max-width: 820px) { .contact-layout { grid-template-columns: 1fr; } }
