/* ============================================================
   COMPONENTS — tombol, badge, chip, kartu, form, tab, alert
   ============================================================ */

/* ── Tombol ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 48px; padding: 12px 22px;
  border-radius: 10px; border: 1px solid transparent;
  font-family: var(--font-body); font-weight: 600; font-size: 15px; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  transition: filter .2s ease, background-color .2s ease, transform .15s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-sm { min-height: 44px; padding: 10px 18px; font-size: 14px; border-radius: 8px; }
.btn-lg { min-height: 54px; padding: 15px 26px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-accent { background: var(--accent); color: var(--on-accent); }
.btn-accent:hover { color: var(--on-accent); filter: brightness(1.07); }
.btn-dark { background: var(--brand-deep); color: #FFFFFF; }
.btn-dark:hover { color: #FFFFFF; background: var(--brand); }
:root[data-theme="dark"] .section-alt .btn-dark { background: var(--accent); color: var(--on-accent); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line-strong); }
.btn-ghost:hover { color: var(--ink); background: rgba(127, 140, 155, .12); }
.btn-row { display: flex; flex-wrap: wrap; gap: 14px; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px;
  font-weight: 600; color: var(--link); text-decoration: none;
}
.link-arrow:hover { gap: 12px; }

/* ── Badge, chip, pill ── */
.badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--font-body); font-size: 12px; font-weight: 600; line-height: 1;
  padding: 6px 10px; border-radius: 999px; white-space: nowrap;
}
.badge-soft { background: var(--surface); color: var(--muted); border: 1px solid var(--line); }
.badge-live { background: var(--live-bg); color: var(--live-ink); }

.chip {
  display: inline-flex; align-items: center; gap: 10px; align-self: flex-start;
  border: 1px solid var(--line-strong); border-radius: 999px; padding: 8px 14px;
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted);
}
.chip-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); flex: none; }

.pill-list { display: flex; flex-wrap: wrap; gap: 12px; }
.pill {
  border: 1px solid var(--ink); border-radius: 999px; padding: 10px 16px;
  font-family: var(--font-mono); font-size: 13px;
}

/* ── Kartu ── */
.card-hover { transition: transform .25s ease, box-shadow .25s ease; }
.card-hover:hover { transform: translateY(-4px); box-shadow: var(--shadow); }

.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 20px; }
.pcard {
  display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-lg);
  color: var(--ink); text-decoration: none;
}
.pcard:hover { color: var(--ink); }
.pcard-img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.pcard-body { padding: 20px; display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.pcard-title { font-family: var(--font-display); font-weight: 700; font-size: 20px; line-height: 1.25; }

.check-list { display: flex; flex-direction: column; gap: 12px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; font-size: 16px; }
.check-list svg { flex: none; margin-top: 2px; color: var(--link); }

/* ── Tab ── */
.tabs { display: flex; flex-wrap: wrap; gap: 8px; }
.tab {
  min-height: 44px; padding: 10px 16px; border-radius: 999px; cursor: pointer;
  font-size: 14px; font-weight: 500;
  background: var(--surface); color: var(--muted); border: 1px solid var(--line-strong);
  transition: background-color .2s ease, color .2s ease;
}
:root[data-theme="dark"] .tab { background: transparent; }
.tab[aria-selected="true"],
:root[data-theme="dark"] .tab[aria-selected="true"] { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }

/* ── Form ── */
.form-card {
  background: #FFFFFF; color: #13202B; border-radius: 18px; padding: clamp(22px, 3vw, 32px);
  display: flex; flex-direction: column; gap: 18px;
}
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: #3E4C59; }
.field-full { grid-column: 1 / -1; }
.field input, .field select, .field textarea {
  width: 100%; padding: 13px 14px; font-size: 15px; font-weight: 400;
  border: 1px solid #C9D3DC; border-radius: 10px; background: #FFFFFF; color: #13202B;
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.req { color: #B42318; }
.field-label { display: block; }
.form-note { font-size: 13px; color: #5F6B78; text-align: center; }
.form-card .btn-dark { background: #0B1C2C; color: #FFFFFF; }
.hp-field { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

@media (max-width: 560px) {
  .form-grid { grid-template-columns: 1fr; }
}

/* ── Alert ── */
.alert { padding: 14px 16px; border-radius: 10px; font-size: 15px; line-height: 1.5; }
.alert-success { background: #E6F4EC; color: #14532D; border: 1px solid #B7E1C7; }
.alert-error { background: #FDECEC; color: #8A1C1C; border: 1px solid #F5C2C2; }

.notice {
  margin-top: 8px; padding: 14px 16px; border-radius: 10px;
  background: var(--surface); border: 1px dashed var(--line-strong); color: var(--muted); max-width: 640px;
}
