/* ============================================================
   SOT Motion — gaya: gelap, ungu SOT + aksen kuning
   ============================================================ */
:root {
  --bg:        #0a0a12;
  --bg-2:      #101020;
  --surface:   #15152a;
  --surface-2: #1c1c38;
  --line:      #2a2a4a;
  --text:      #eceaf5;
  --muted:     #9a97b8;
  --brand:     #8B4FA8;
  --brand-2:   #B06FD0;
  --accent:    #FED524;
  --radius:    14px;
  --serif:     'Instrument Serif', Georgia, serif;
  --sans:      'Geist', -apple-system, 'Segoe UI', system-ui, sans-serif;
  --mono:      'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrap { width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 20px; }

.serif { font-family: var(--serif); font-style: italic; font-weight: 400; }

.shine {
  background: linear-gradient(100deg, var(--accent) 0%, #fff6c9 42%, var(--accent) 100%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ---------- header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 40;
  background: rgba(10,10,18,.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  height: 62px;
}
.brand {
  display: flex; align-items: center; gap: 10px;
  font-size: 16.5px; font-weight: 600; letter-spacing: -.2px;
  color: var(--text); text-decoration: none;
}
.brand-mark {
  display: grid; place-items: center;
  width: 32px; height: 32px; border-radius: 9px;
  background: linear-gradient(140deg, var(--brand), var(--brand-2));
  color: #fff; font-size: 11.5px; font-weight: 800; letter-spacing: .5px;
}
.lang-btn {
  padding: 7px 15px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--text); font-family: var(--mono); font-size: 12px;
  font-weight: 600; cursor: pointer; transition: all .15s;
}
.lang-btn:hover { border-color: var(--accent); color: var(--accent); }

/* ---------- stage + orbs ---------- */
.stage { position: relative; flex: 1 1 auto; padding-bottom: 60px; }
.backdrop { position: absolute; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .30; }
.orb.a { width: 420px; height: 420px; background: #7A3D96; top: -140px; left: -110px; }
.orb.b { width: 380px; height: 380px; background: #FED524; opacity: .10; top: 60px; right: -130px; }
.orb.c { width: 340px; height: 340px; background: #5B2A86; bottom: -120px; left: 34%; }

.view { position: relative; z-index: 1; }

/* ---------- intro ---------- */
.intro { padding: 54px 0 30px; max-width: 660px; }
.intro h1 {
  font-size: clamp(30px, 5.4vw, 48px);
  font-weight: 600; line-height: 1.14; letter-spacing: -1.4px;
}
.intro p { margin-top: 14px; color: var(--muted); font-size: 16px; }

/* ---------- toolbar ---------- */
.toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 16px; }
.search {
  display: flex; align-items: center; gap: 9px;
  flex: 1 1 250px; max-width: 340px;
  padding: 10px 14px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: 999px; transition: border-color .15s;
}
.search:focus-within { border-color: var(--brand-2); }
.search svg { width: 17px; height: 17px; color: var(--muted); flex: 0 0 auto; }
.search input {
  flex: 1; border: 0; background: transparent; outline: none;
  color: var(--text); font-family: inherit; font-size: 14px;
}
.search input::placeholder { color: var(--muted); }

.filters { display: flex; flex-wrap: wrap; gap: 7px; }
.filter {
  padding: 7px 13px; border-radius: 999px;
  border: 1px solid var(--line); background: transparent;
  color: var(--muted); font-family: inherit; font-size: 12.5px;
  cursor: pointer; transition: all .15s;
}
.filter:hover { color: var(--text); border-color: var(--brand-2); }
.filter.is-on {
  background: var(--accent); border-color: var(--accent); color: #1a1400; font-weight: 600;
}

.count { color: var(--muted); font-size: 13px; margin-bottom: 18px; font-family: var(--mono); }

/* ---------- grid ---------- */
.grid {
  display: grid; gap: 14px;
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
}
.empty { grid-column: 1 / -1; color: var(--muted); padding: 44px 0; text-align: center; }

.card {
  position: relative;
  padding: 20px 19px 17px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); cursor: pointer;
  transition: transform .16s, border-color .16s, background .16s;
  animation: rise .40s both;
  display: flex; flex-direction: column;
}
@keyframes rise { from { opacity: 0; transform: translateY(10px) } to { opacity: 1; transform: none } }
.card:hover, .card:focus-visible {
  transform: translateY(-3px);
  border-color: var(--brand-2);
  background: var(--surface-2);
  outline: none;
}
.card-top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 11px;
}
.lib {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .4px;
  padding: 3px 9px; border-radius: 999px;
  background: rgba(139,79,168,.22); color: var(--brand-2);
  border: 1px solid rgba(176,111,208,.28);
}
.arrow { color: var(--muted); font-size: 15px; transition: transform .16s, color .16s; }
.card:hover .arrow { transform: translateX(3px); color: var(--accent); }

.card h3 { font-size: 16.5px; font-weight: 600; letter-spacing: -.3px; margin-bottom: 7px; }
.card p { color: var(--muted); font-size: 13.5px; line-height: 1.55; flex: 1 1 auto; }
.card-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 13px; }
.card-tags span {
  font-size: 11px; padding: 2.5px 8px; border-radius: 999px;
  background: rgba(255,255,255,.05); color: var(--muted);
}

/* ---------- detail ---------- */
.detail-bar {
  position: sticky; top: 62px; z-index: 30;
  background: rgba(10,10,18,.90); backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line); padding: 11px 0;
}
.back {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px 7px 10px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--text); font-family: inherit; font-size: 13.5px;
  cursor: pointer; transition: all .15s;
}
.back:hover { border-color: var(--accent); color: var(--accent); }
.back svg { width: 16px; height: 16px; }

.detail-body { padding-top: 30px; max-width: 820px; }
.detail-head h2 {
  font-size: clamp(24px, 4vw, 34px); font-weight: 600;
  letter-spacing: -1px; line-height: 1.2;
}
.detail-head h2:focus { outline: none; }
.detail-head p { margin-top: 11px; color: var(--muted); font-size: 15.5px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; }
.chip {
  font-size: 11.5px; padding: 3px 10px; border-radius: 999px;
  background: rgba(139,79,168,.20); color: var(--brand-2);
  border: 1px solid rgba(176,111,208,.26);
}

/* tetapan */
.settings {
  margin: 28px 0 24px; padding: 20px;
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius);
}
.settings-title {
  font-size: 12px; font-weight: 600; letter-spacing: 1.1px;
  text-transform: uppercase; color: var(--muted); margin-bottom: 15px;
}
.setting { margin-bottom: 15px; }
.setting:last-child { margin-bottom: 0; }
.setting-row { display: flex; flex-wrap: wrap; gap: 20px; }
.setting-row .setting { flex: 1 1 200px; }
.setting-label {
  display: block; font-size: 12.5px; color: var(--muted);
  margin-bottom: 8px; font-family: var(--mono);
}
.segmented { display: flex; flex-wrap: wrap; gap: 6px; }
.seg {
  padding: 7px 14px; border-radius: 9px;
  border: 1px solid var(--line); background: transparent;
  color: var(--muted); font-family: var(--mono); font-size: 12.5px;
  cursor: pointer; transition: all .14s;
}
.seg:hover { color: var(--text); border-color: var(--brand-2); }
.seg.is-on {
  background: var(--accent); border-color: var(--accent);
  color: #1a1400; font-weight: 600;
}

/* prompt box */
.prompt-box {
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
}
.prompt-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 16px; border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.02);
}
.prompt-title {
  font-size: 12px; font-weight: 600; letter-spacing: 1px;
  text-transform: uppercase; color: var(--muted);
}
.copy-button {
  display: inline-flex; align-items: center; gap: 7px;
  padding: 7px 14px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface);
  color: var(--text); font-family: inherit; font-size: 13px;
  cursor: pointer; transition: all .15s;
}
.copy-button:hover { border-color: var(--accent); color: var(--accent); }
.copy-button.done { background: #1a3d24; border-color: #2e7d4a; color: #7ee2a8; }
.copy-button svg { width: 15px; height: 15px; }
.icon-done { display: none; }
.copy-button.done .icon-copy { display: none; }
.copy-button.done .icon-done { display: block; }

.prompt-text {
  padding: 18px 16px; margin: 0;
  font-family: var(--mono); font-size: 12.5px; line-height: 1.7;
  color: #cfcbe6; white-space: pre-wrap; word-break: break-word;
  max-height: 460px; overflow-y: auto;
}
.prompt-text:focus { outline: 1px solid var(--brand-2); outline-offset: -1px; }

.paste-tip { margin-top: 14px; color: var(--muted); font-size: 13px; }

/* ---------- footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 22px 0; margin-top: auto;
  position: relative; z-index: 1;
}
.site-footer .wrap {
  display: flex; flex-wrap: wrap; gap: 12px;
  align-items: center; justify-content: space-between;
  color: var(--muted); font-size: 13px;
}
.author { display: flex; align-items: baseline; gap: 7px; }
.author small { font-size: 11.5px; opacity: .75; }
.count-total { font-family: var(--mono); font-size: 12px; }

/* ---------- mobile ---------- */
@media (max-width: 640px) {
  .intro { padding: 34px 0 22px; }
  .intro h1 { letter-spacing: -1px; }
  .grid { grid-template-columns: 1fr; gap: 11px; }
  .detail-bar { top: 62px; }
  .detail-body { padding-top: 22px; }
  .settings { padding: 16px; }
  .prompt-text { font-size: 12px; max-height: 380px; }
  .search { max-width: 100%; }
}

/* ---------- scrollbar ---------- */
::-webkit-scrollbar { width: 9px; height: 9px; }
::-webkit-scrollbar-track { background: var(--bg-2); }
::-webkit-scrollbar-thumb { background: var(--line); border-radius: 5px; }
::-webkit-scrollbar-thumb:hover { background: var(--brand); }
