/* ==========================================================================
   PPID Universitas Nusantara Mandiri — stylesheet
   Mobile-first, tanpa dependency eksternal.
   ========================================================================== */

:root {
  --biru: #0b3a6e;
  --biru-terang: #15508f;
  --biru-gelap: #072a52;
  --emas: #c9a227;
  --emas-terang: #e0bd45;
  --teks: #1c2530;
  --teks-lembut: #4a5768;
  --abu: #f4f6f9;
  --abu-garis: #dde3ea;
  --putih: #ffffff;
  --sukses: #1c7a4a;
  --radius: 10px;
  --shadow: 0 2px 10px rgba(11, 58, 110, 0.08);
  --shadow-besar: 0 8px 28px rgba(11, 58, 110, 0.14);
  --lebar: 1120px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  color: var(--teks);
  background: var(--putih);
}

img,
svg {
  max-width: 100%;
  height: auto;
}

a {
  color: var(--biru-terang);
}

a:hover {
  color: var(--biru);
}

h1,
h2,
h3,
h4 {
  line-height: 1.25;
  color: var(--biru);
  margin: 0 0 0.5em;
}

h1 {
  font-size: 1.75rem;
}

h2 {
  font-size: 1.4rem;
}

h3 {
  font-size: 1.1rem;
}

p {
  margin: 0 0 1rem;
}

:focus-visible {
  outline: 3px solid var(--emas);
  outline-offset: 2px;
}

.container {
  width: 100%;
  max-width: var(--lebar);
  margin: 0 auto;
  padding: 0 1rem;
}

/* Skip link ---------------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--emas);
  color: var(--biru-gelap);
  padding: 0.6rem 1rem;
  font-weight: 700;
  z-index: 999;
  border-radius: 0 0 var(--radius) 0;
}

.skip-link:focus {
  left: 0;
}

/* Header ------------------------------------------------------------------- */
.site-header {
  background: var(--biru);
  color: var(--putih);
  border-bottom: 4px solid var(--emas);
}

.site-header a {
  color: var(--putih);
  text-decoration: none;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 1rem;
  max-width: var(--lebar);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  text-decoration: none;
}

.brand-mark {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-text strong {
  font-size: 1rem;
  letter-spacing: 0.2px;
}

.brand-text span {
  font-size: 0.75rem;
  color: var(--emas-terang);
  letter-spacing: 0.6px;
  text-transform: uppercase;
}

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 10px;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 8px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--putih);
  border-radius: 2px;
}

.nav-toggle[aria-expanded="true"] {
  background: rgba(255, 255, 255, 0.12);
}

.site-nav {
  width: 100%;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: none;
  flex-direction: column;
  gap: 0.15rem;
  padding-bottom: 0.75rem;
}

.nav-list.is-open {
  display: flex;
}

.nav-list a {
  display: block;
  padding: 0.6rem 0.75rem;
  border-radius: 6px;
  font-size: 0.95rem;
  border-left: 3px solid transparent;
}

.nav-list a:hover {
  background: rgba(255, 255, 255, 0.1);
}

.nav-list a[aria-current="page"] {
  background: rgba(255, 255, 255, 0.14);
  border-left-color: var(--emas);
  font-weight: 600;
}

@media (min-width: 860px) {
  .header-inner {
    flex-wrap: wrap;
    padding-bottom: 0;
  }

  .nav-toggle {
    display: none;
  }

  .site-nav {
    width: auto;
  }

  .nav-list {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    padding-bottom: 0;
    gap: 0.15rem;
  }

  .nav-list a {
    border-left: none;
    border-bottom: 3px solid transparent;
    border-radius: 6px 6px 0 0;
    padding: 0.7rem 0.85rem;
  }

  .nav-list a[aria-current="page"] {
    border-left: none;
    border-bottom-color: var(--emas);
    background: rgba(255, 255, 255, 0.12);
  }
}

/* Hero --------------------------------------------------------------------- */
.hero {
  background: linear-gradient(150deg, var(--biru) 0%, var(--biru-terang) 100%);
  color: var(--putih);
  padding: 2.5rem 0 3rem;
}

.hero h1 {
  color: var(--putih);
  font-size: 1.7rem;
  margin-bottom: 0.6rem;
}

.hero p {
  color: #dfe8f3;
  max-width: 62ch;
}

.hero-eyebrow {
  display: inline-block;
  font-size: 0.75rem;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--emas-terang);
  border: 1px solid rgba(201, 162, 39, 0.55);
  border-radius: 999px;
  padding: 0.2rem 0.7rem;
  margin-bottom: 1rem;
}

.hero-search {
  margin-top: 1.5rem;
  background: var(--putih);
  border-radius: var(--radius);
  padding: 0.75rem;
  box-shadow: var(--shadow-besar);
}

.hero-search form {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.hero-search input {
  width: 100%;
  padding: 0.8rem 0.9rem;
  border: 1px solid var(--abu-garis);
  border-radius: 8px;
  font-size: 1rem;
  color: var(--teks);
}

@media (min-width: 640px) {
  .hero h1 {
    font-size: 2.15rem;
  }

  .hero-search form {
    flex-direction: row;
  }

  .hero-search input {
    flex: 1;
  }
}

/* Tombol ------------------------------------------------------------------- */
.btn {
  display: inline-block;
  padding: 0.7rem 1.15rem;
  border-radius: 8px;
  border: 2px solid transparent;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.btn-primer {
  background: var(--biru);
  color: var(--putih);
}

.btn-primer:hover {
  background: var(--biru-gelap);
  color: var(--putih);
}

.btn-emas {
  background: var(--emas);
  color: var(--biru-gelap);
}

.btn-emas:hover {
  background: var(--emas-terang);
  color: var(--biru-gelap);
}

.btn-garis {
  background: transparent;
  border-color: var(--biru);
  color: var(--biru);
}

.btn-garis:hover {
  background: var(--biru);
  color: var(--putih);
}

.btn-kecil {
  padding: 0.35rem 0.75rem;
  font-size: 0.82rem;
}

.btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

/* Section ------------------------------------------------------------------ */
.section {
  padding: 2.25rem 0;
}

.section-abu {
  background: var(--abu);
}

.section-head {
  margin-bottom: 1.5rem;
}

.section-head p {
  color: var(--teks-lembut);
  margin: 0;
  max-width: 68ch;
}

.section-head h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  background: var(--emas);
  margin-top: 0.5rem;
  border-radius: 2px;
}

/* Grid & kartu ------------------------------------------------------------- */
.grid {
  display: grid;
  gap: 1rem;
}

.grid-2 {
  grid-template-columns: 1fr;
}

.grid-3 {
  grid-template-columns: 1fr;
}

.grid-4 {
  grid-template-columns: 1fr;
}

@media (min-width: 640px) {
  .grid-2,
  .grid-3,
  .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (min-width: 900px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }

  .grid-4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

.card {
  background: var(--putih);
  border: 1px solid var(--abu-garis);
  border-radius: var(--radius);
  padding: 1.15rem;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.card h3 {
  margin-bottom: 0.35rem;
}

.card p {
  color: var(--teks-lembut);
  font-size: 0.94rem;
  margin-bottom: 1rem;
}

.card .btn {
  margin-top: auto;
  align-self: flex-start;
}

.card-icon {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  background: rgba(11, 58, 110, 0.08);
  color: var(--biru);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

/* Statistik ---------------------------------------------------------------- */
.stat-strip {
  background: var(--biru-gelap);
  color: var(--putih);
  padding: 2rem 0;
}

.stat-strip h2 {
  color: var(--putih);
}

.stat-item {
  text-align: center;
  padding: 0.75rem 0.5rem;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.06);
}

.stat-value {
  display: block;
  font-size: 1.8rem;
  font-weight: 700;
  color: var(--emas-terang);
  line-height: 1.1;
}

.stat-label {
  font-size: 0.85rem;
  color: #cfdcec;
}

/* Berita ------------------------------------------------------------------- */
.news-item {
  border-left: 3px solid var(--emas);
  padding-left: 1rem;
}

.news-date {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  color: var(--teks-lembut);
}

/* Tabel -------------------------------------------------------------------- */
.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--abu-garis);
  border-radius: var(--radius);
  background: var(--putih);
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 560px;
}

caption {
  text-align: left;
  padding: 0.85rem 1rem;
  font-weight: 600;
  color: var(--biru);
  background: var(--abu);
  border-bottom: 1px solid var(--abu-garis);
}

th,
td {
  text-align: left;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--abu-garis);
  font-size: 0.93rem;
  vertical-align: top;
}

th {
  background: var(--abu);
  color: var(--biru);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

tbody tr:last-child td {
  border-bottom: none;
}

tbody tr:hover {
  background: #fafbfd;
}

/* Tab ---------------------------------------------------------------------- */
.tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  border-bottom: 2px solid var(--abu-garis);
  margin-bottom: 1.25rem;
}

.tab {
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  padding: 0.7rem 0.9rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--teks-lembut);
  cursor: pointer;
  margin-bottom: -2px;
}

.tab[aria-selected="true"] {
  color: var(--biru);
  border-bottom-color: var(--emas);
}

.tab-panel[hidden] {
  display: none;
}

/* Filter ------------------------------------------------------------------- */
.filter-bar {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding: 1rem;
  background: var(--abu);
  border-radius: var(--radius);
  border: 1px solid var(--abu-garis);
}

@media (min-width: 720px) {
  .filter-bar {
    flex-direction: row;
    align-items: flex-end;
  }

  .filter-bar .field {
    flex: 1;
  }

  .filter-bar .field-tahun {
    flex: 0 0 180px;
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.field label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--biru);
}

input,
select,
textarea {
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--teks);
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--abu-garis);
  border-radius: 8px;
  background: var(--putih);
  width: 100%;
}

textarea {
  min-height: 110px;
  resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--biru-terang);
  outline: 2px solid rgba(21, 80, 143, 0.25);
  outline-offset: 0;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 720px) {
  .form-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .span-2 {
    grid-column: 1 / -1;
  }
}

fieldset {
  border: 1px solid var(--abu-garis);
  border-radius: var(--radius);
  padding: 1rem;
  margin: 0 0 1.25rem;
}

legend {
  font-weight: 700;
  color: var(--biru);
  padding: 0 0.4rem;
}

.hint {
  font-size: 0.82rem;
  color: var(--teks-lembut);
}

/* Langkah ------------------------------------------------------------------ */
.steps {
  list-style: none;
  counter-reset: langkah;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.9rem;
}

.steps li {
  counter-increment: langkah;
  position: relative;
  padding-left: 3rem;
}

.steps li::before {
  content: counter(langkah);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.1rem;
  height: 2.1rem;
  border-radius: 50%;
  background: var(--biru);
  color: var(--putih);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
}

.steps strong {
  display: block;
  color: var(--biru);
}

.steps p {
  margin: 0.15rem 0 0;
  color: var(--teks-lembut);
  font-size: 0.93rem;
}

/* Alert -------------------------------------------------------------------- */
.alert {
  border-radius: var(--radius);
  padding: 1rem 1.15rem;
  border-left: 4px solid var(--biru);
  background: #eef4fb;
  margin-bottom: 1.25rem;
}

.alert h3 {
  margin-top: 0;
}

.alert-sukses {
  border-left-color: var(--sukses);
  background: #eaf7f0;
}

.alert-emas {
  border-left-color: var(--emas);
  background: #fdf6e3;
}

.reg-number {
  display: inline-block;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: var(--biru-gelap);
  background: var(--putih);
  border: 2px dashed var(--emas);
  border-radius: 8px;
  padding: 0.4rem 0.9rem;
  margin: 0.35rem 0 0.75rem;
}

[hidden] {
  display: none !important;
}

/* Timeline ----------------------------------------------------------------- */
.timeline {
  list-style: none;
  margin: 0;
  padding: 0 0 0 1.6rem;
  border-left: 2px solid var(--abu-garis);
}

.timeline li {
  position: relative;
  padding: 0 0 1.4rem 0.4rem;
}

.timeline li:last-child {
  padding-bottom: 0;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -2.05rem;
  top: 0.4rem;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--abu-garis);
  border: 3px solid var(--putih);
  box-shadow: 0 0 0 2px var(--abu-garis);
}

.timeline li.selesai::before {
  background: var(--sukses);
  box-shadow: 0 0 0 2px var(--sukses);
}

.timeline li.aktif::before {
  background: var(--emas);
  box-shadow: 0 0 0 2px var(--emas);
}

.timeline .waktu {
  font-size: 0.8rem;
  color: var(--teks-lembut);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.timeline .judul {
  font-weight: 700;
  color: var(--biru);
}

.timeline .ket {
  margin: 0.15rem 0 0;
  font-size: 0.93rem;
  color: var(--teks-lembut);
}

/* Prose -------------------------------------------------------------------- */
.prose ul,
.prose ol {
  padding-left: 1.25rem;
}

.prose li {
  margin-bottom: 0.4rem;
}

.info-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.info-list li {
  padding: 0.6rem 0;
  border-bottom: 1px solid var(--abu-garis);
}

.info-list li:last-child {
  border-bottom: none;
}

.info-list strong {
  display: block;
  color: var(--biru);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.4px;
}

/* Footer ------------------------------------------------------------------- */
.site-footer {
  background: var(--biru-gelap);
  color: #cfdcec;
  padding: 2.25rem 0 1.25rem;
  margin-top: 2rem;
  font-size: 0.92rem;
}

.site-footer h3 {
  color: var(--putih);
  font-size: 1rem;
}

.site-footer a {
  color: #cfdcec;
  text-decoration: none;
}

.site-footer a:hover {
  color: var(--emas-terang);
  text-decoration: underline;
}

.footer-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-list li {
  margin-bottom: 0.35rem;
}

.footer-bottom {
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  font-size: 0.84rem;
  color: #9fb3ca;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

@media (min-width: 720px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
  }
}

/* Utilitas ----------------------------------------------------------------- */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.text-center {
  text-align: center;
}

.mt-1 {
  margin-top: 0.5rem;
}

.mt-2 {
  margin-top: 1rem;
}

.mt-3 {
  margin-top: 1.5rem;
}

.mb-0 {
  margin-bottom: 0;
}

.empty-state {
  padding: 1.25rem;
  text-align: center;
  color: var(--teks-lembut);
  font-style: italic;
}

@media print {
  .site-header,
  .site-footer,
  .hero-search,
  .filter-bar {
    display: none;
  }
}

/* Cegah track grid melebar oleh tabel lebar (scroll horizontal mobile) */
.grid > * { min-width: 0; }
