:root {
  --ink: #102033;
  --ink-2: #1b3148;
  --paper: #e7edf2;
  --card: #fffcf8;
  --line: #d5deE6;
  --text: #1c2c3b;
  --muted: #5d7286;
  --blue: #2f6fed;
  --blue-2: #1d4e89;
  --amber: #e2a123;
  --teal: #0f8f7a;
  --pos: #1f9d62;
  --neg: #d64545;
  --neu: #8b9aab;
  --shadow: 0 10px 30px rgba(16, 32, 51, 0.06);
  --serif: "Newsreader", Georgia, serif;
  --sans: "Outfit", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--sans);
  color: var(--text);
  background:
    radial-gradient(1200px 400px at 100% -10%, rgba(226, 161, 35, 0.16), transparent 50%),
    var(--paper);
  min-height: 100vh;
}
a { color: var(--blue-2); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }

.shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 268px;
  background: var(--ink);
  color: #efe8db;
  display: flex;
  flex-direction: column;
  padding: 22px 16px 18px;
  z-index: 5;
  overflow: auto;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  color: inherit;
  text-decoration: none;
  margin-bottom: 26px;
}
.brand:hover { text-decoration: none; }
.brand-text { min-width: 0; }
.brand strong {
  display: block;
  font-family: var(--serif);
  font-size: 22px;
  line-height: 1;
  letter-spacing: -0.03em;
}
.brand em {
  display: block;
  margin-top: 4px;
  font-style: normal;
  color: #d5deE6;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0;
  line-height: 1.25;
}
.mark {
  width: 46px;
  height: 46px;
  background: transparent;
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}
.mark img {
  width: 46px;
  height: 46px;
  object-fit: contain;
  display: block;
}
.pitch-logo {
  width: 92px;
  height: 92px;
  object-fit: contain;
  display: block;
  margin-bottom: 18px;
  background: transparent;
}
.sidebar nav { display: flex; flex-direction: column; gap: 4px; }
.sidebar nav a {
  color: #d5deE6;
  text-decoration: none;
  padding: 10px 12px;
  border-radius: 10px;
  font-weight: 500;
  border-left: 3px solid transparent;
}
.sidebar nav a:hover { background: rgba(255, 255, 255, 0.05); text-decoration: none; }
.sidebar nav a.active {
  background: rgba(226, 161, 35, 0.12);
  color: #fff;
  border-left-color: var(--amber);
}
.side-foot {
  margin-top: auto;
  color: #9aabbd;
  font-size: 12px;
  line-height: 1.45;
  padding: 12px;
}

.main { margin-left: 268px; padding: 22px 28px 48px; }
.topbar {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-end;
  margin-bottom: 18px;
}
.eyebrow {
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 4px;
}
.topbar h1 {
  font-family: var(--serif);
  font-size: 36px;
  font-weight: 650;
  letter-spacing: -0.03em;
  line-height: 1;
}
.who { display: flex; align-items: center; gap: 10px; color: var(--muted); }
.who span { color: var(--text); font-weight: 600; }
.who small { text-transform: uppercase; letter-spacing: 0.08em; font-size: 11px; }

.flash {
  background: #e7f6ef;
  color: #0e6a42;
  border: 1px solid #b7e4cd;
  padding: 12px 14px;
  border-radius: 12px;
  margin-bottom: 16px;
}
.flash.err { background: #fdecec; color: #9d2b2b; border-color: #f3c4c4; }

.toolbar {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: end;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: end; }
label { display: grid; gap: 6px; font-size: 12px; color: var(--muted); font-weight: 600; }
input, select, textarea {
  background: white;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 10px 12px;
  min-height: 42px;
}
textarea { min-height: 80px; width: 100%; }
input[type="checkbox"] { min-height: 0; width: 16px; height: 16px; padding: 0; accent-color: var(--blue-2); }
input:focus, select:focus, textarea:focus {
  outline: 3px solid rgba(47, 111, 237, 0.18);
  border-color: var(--blue);
}

.btn {
  border: 0;
  background: var(--ink);
  color: white;
  border-radius: 10px;
  min-height: 42px;
  padding: 0 14px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.btn:hover { text-decoration: none; filter: brightness(1.08); }
.btn.teal { background: var(--teal); }
.btn.amber { background: #9a6b10; }
.btn.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}
.btn.danger { background: #8d2f2f; }
.btn.small { min-height: 34px; padding: 0 10px; font-size: 13px; }
.btn:disabled { opacity: 0.7; cursor: wait; }

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-bottom: 12px;
}
.stat, .card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.stat { padding: 16px 16px 14px; position: relative; overflow: hidden; }
.stat::before {
  content: "";
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--blue-2);
}
.stat.pos::before { background: var(--pos); }
.stat.neg::before { background: var(--neg); }
.stat.amber::before { background: var(--amber); }
.stat span { display: block; color: var(--muted); font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 600; }
.stat strong {
  display: block;
  margin-top: 8px;
  font-family: var(--serif);
  font-size: 34px;
  letter-spacing: -0.03em;
  font-weight: 650;
}
.stat em { font-style: normal; color: var(--muted); font-size: 13px; }

.grid-2, .grid-3, .grid-main { display: grid; gap: 12px; margin-bottom: 12px; }
.grid-2 { grid-template-columns: 1.4fr 0.8fr; }
.grid-3 { grid-template-columns: 1.1fr 0.8fr 0.9fr; }
.grid-main { grid-template-columns: 1.15fr 0.85fr; }
.card { padding: 16px 16px 14px; }
.card h2 {
  font-size: 15px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 12px;
}
.card .sub { color: var(--muted); font-size: 13px; margin-top: -8px; margin-bottom: 12px; }
.chart-box { position: relative; height: 260px; }
.chart-box.short { height: 220px; }
.chart-box.tall { height: 300px; }
.chart-box.spokebox { height: 340px; }
input.rate { width: 130px; }
input.factor { width: 72px; }

.news-list { display: flex; flex-direction: column; }
.news-row {
  display: grid;
  grid-template-columns: 92px 1fr auto;
  gap: 10px;
  align-items: start;
  padding: 10px 0;
  border-top: 1px solid #e6edf3;
}
.news-row:first-child { border-top: 0; padding-top: 0; }
.news-row time, .meta { color: var(--muted); font-size: 12px; }
.news-row a { color: var(--text); font-weight: 600; }
.news-row .src { color: var(--muted); font-size: 12px; margin-top: 3px; }

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 3px 8px;
  font-size: 12px;
  font-weight: 600;
  background: #eef2f6;
  color: #516579;
}
.badge.positif { background: #e5f6ee; color: #127a49; }
.badge.negatif { background: #fdecec; color: #b43232; }
.badge.netral { background: #eef2f6; color: #5c6e80; }
.badge.scope { background: #f8f1e2; color: #8a6414; }

.cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  align-items: center;
  justify-content: center;
  min-height: 180px;
  padding: 8px;
  line-height: 1.15;
}
.cloud span { color: var(--blue-2); font-weight: 650; letter-spacing: -0.02em; }
.cloud span:nth-child(3n) { color: #0f6f62; }
.cloud span:nth-child(4n) { color: #9a6b10; }
.cloud span:nth-child(5n) { color: #5d4d93; }

.person { padding: 9px 0; border-top: 1px solid #e6edf3; }
.person:first-child { border-top: 0; }
.person b { display: block; }
.person span { color: var(--muted); font-size: 13px; }

.pair-list { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.pair-list span {
  background: #f4f7fb;
  border-radius: 999px;
  padding: 4px 8px;
  font-size: 12px;
  color: var(--muted);
}
#ontologi, #jaringan { height: 320px; background: #f7fafc; border-radius: 12px; }
#peta, #peta-sosial { height: 420px; border-radius: 12px; }
.loc-list { margin: 8px 0 0; padding: 0; list-style: none; }
.loc-list li { display: flex; justify-content: space-between; gap: 8px; padding: 6px 0; border-top: 1px solid #e6edf3; font-size: 14px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
th, td { padding: 10px 8px; border-bottom: 1px solid #e6edf3; vertical-align: top; }
tr:hover td { background: rgba(47, 111, 237, 0.03); }

.muted { color: var(--muted); }
.stack { display: grid; gap: 12px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form-grid .wide { grid-column: 1 / -1; }
.split { display: grid; grid-template-columns: 280px 1fr; gap: 12px; align-items: start; }
.note {
  background: #f8f1e2;
  border: 1px solid #ead7ae;
  color: #6d5316;
  border-radius: 12px;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.5;
}
code, .code {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  background: #102033;
  color: #f4efe4;
  padding: 10px 12px;
  border-radius: 10px;
  display: block;
  overflow-x: auto;
}
.empty {
  padding: 28px 8px;
  text-align: center;
  color: var(--muted);
}
.empty strong { display: block; color: var(--text); font-size: 18px; margin-bottom: 6px; }

.stream { display: flex; flex-direction: column; gap: 10px; }
.stream article {
  border: 1px solid #e6edf3;
  border-radius: 12px;
  padding: 12px;
  background: #fff;
}
.stream header { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 6px; }
.stream p { line-height: 1.45; }

.sheet { max-width: 900px; }
.bars { display: grid; gap: 8px; }
.bar-row { display: grid; grid-template-columns: 140px 1fr 48px; gap: 8px; align-items: center; font-size: 14px; }
.bar { height: 10px; background: #e6edf3; border-radius: 99px; overflow: hidden; }
.bar i { display: block; height: 100%; background: var(--blue-2); border-radius: 99px; }
.bar.pos i { background: var(--pos); }
.bar.neg i { background: var(--neg); }
.bar.neu i { background: var(--neu); }

.login-wrap, .install-wrap {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
}
.pitch {
  background:
    radial-gradient(500px 240px at 20% 20%, rgba(226, 161, 35, 0.25), transparent 60%),
    var(--ink);
  color: #f6f1e7;
  padding: 56px 52px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.pitch h1 {
  font-family: var(--serif);
  font-weight: 650;
  font-size: 64px;
  letter-spacing: -0.04em;
  line-height: 0.92;
  margin: 18px 0;
}
.pitch p { max-width: 460px; color: #d9cbb6; line-height: 1.55; font-size: 18px; }
.pitch ul { margin: 28px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.pitch li { color: #f6f1e7; }
.pitch li span { color: var(--amber); margin-right: 8px; }
.panel { display: grid; place-items: center; padding: 32px 20px; }
.panel form, .panel .box {
  width: min(420px, 100%);
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 26px;
  box-shadow: var(--shadow);
  display: grid;
  gap: 12px;
}
.panel h2 { font-family: var(--serif); font-size: 32px; font-weight: 650; }
.err-text { color: var(--neg); font-size: 14px; }

.login-wrap .pitch {
  position: relative;
  overflow: hidden;
  padding: 36px 44px 32px;
  background: #102033;
  justify-content: flex-end;
  gap: 22px;
}
.pitch-photo {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
}
.pitch-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(16, 32, 51, 0.12) 0%, rgba(16, 32, 51, 0.05) 24%, rgba(16, 32, 51, 0.78) 52%, rgba(16, 32, 51, 0.96) 100%);
}
.pitch-copy,
.pitch-foot { position: relative; z-index: 1; }
.login-wrap .pitch-logo {
  width: 58px;
  height: 58px;
  margin-bottom: 16px;
  filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.45));
}
.login-wrap .eyebrow {
  color: #f0e2c4;
  letter-spacing: 0.14em;
}
.login-wrap .pitch h1 {
  font-size: 52px;
  line-height: 0.98;
  margin: 10px 0 12px;
  max-width: 440px;
  color: #f7f3ea;
  text-shadow: 0 10px 28px rgba(0, 0, 0, 0.35);
}
.login-wrap .lede {
  max-width: 380px;
  margin: 0;
  color: #eadfce;
  font-size: 16px;
  line-height: 1.5;
}
.login-wrap .pitch ul {
  margin: 18px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.login-wrap .pitch li {
  color: #f6f1e7;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 13px;
  line-height: 1.3;
}
.pitch-foot {
  margin: 0;
  color: #d9cfc0;
  font-size: 13px;
  letter-spacing: 0.02em;
}
.login-wrap .panel form {
  padding: 32px 28px 28px;
  gap: 14px;
  border-radius: 22px;
}
.login-wrap .panel h2 { letter-spacing: -0.03em; }
.login-wrap .panel .btn { width: 100%; min-height: 46px; margin-top: 4px; }

.actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.pager { display: flex; gap: 8px; margin-top: 14px; }

@media print {
  .sidebar, .topbar, .toolbar, .no-print, .btn { display: none !important; }
  .main { margin: 0; padding: 0; }
  body { background: white; }
  .card, .stat { box-shadow: none; }
}

@media (max-width: 1100px) {
  .stats, .grid-3, .grid-2, .grid-main, .split, .form-grid { grid-template-columns: 1fr; }
}
@media (max-width: 860px) {
  .sidebar { position: sticky; top: 0; width: auto; flex-direction: row; align-items: center; gap: 12px; padding: 10px; }
  .sidebar nav { flex-direction: row; overflow: auto; }
  .side-foot, .brand em { display: none; }
  .brand { margin: 0; }
  .main { margin: 0; padding: 16px; }
  .login-wrap, .install-wrap { grid-template-columns: 1fr; }
  .pitch { padding: 28px 20px; }
  .pitch h1 { font-size: 46px; }
  .login-wrap .pitch { min-height: 560px; padding: 28px 22px 22px; }
  .login-wrap .pitch h1 { font-size: 40px; }
  .news-row { grid-template-columns: 1fr; }
}
