@import url('https://fonts.googleapis.com/css2?family=Lora:wght@500;600;700&family=Inter:wght@400;500;600;700&display=swap');

:root {
  --hijau-tua: #0d4a35;
  --hijau-gelap: #093326;
  --hijau-lebih-gelap: #062119;
  --emas: #c9a227;
  --emas-terang: #e2c15a;
  --krem: #f7f4ec;
  --putih: #ffffff;
  --teks-gelap: #1f2d24;
  --teks-muted: #66766c;
  --garis: #e6e1d2;
  --merah: #b91c1c;
  --sidebar-lebar: 240px;
}

* { box-sizing: border-box; }

body {
  font-family: 'Inter', -apple-system, "Segoe UI", Arial, sans-serif;
  background: var(--krem);
  margin: 0;
  color: var(--teks-gelap);
}

h1, h2, h3, h4 {
  font-family: 'Lora', Georgia, serif;
  color: var(--hijau-tua);
}

a { color: inherit; }

.container {
  max-width: 480px;
  margin: 0 auto;
  padding: 16px;
}

.topbar {
  background: linear-gradient(180deg, var(--hijau-tua), var(--hijau-gelap));
  color: #fff;
  padding: 16px 20px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 10;
  border-bottom: 3px solid var(--emas);
}
.topbar-brand {
  font-family: 'Lora', serif;
  font-weight: 600;
  font-size: 17px;
  letter-spacing: 0.2px;
}
.topbar-brand .sub {
  display: block;
  font-family: 'Inter', sans-serif;
  font-weight: 400;
  font-size: 11px;
  color: var(--emas-terang);
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-top: 1px;
}
.topbar a { color: #fff; text-decoration: none; font-size: 14px; }
.topbar a:hover { color: var(--emas-terang); }

.app-shell { min-height: 100vh; }

.sidebar {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--sidebar-lebar);
  background: linear-gradient(180deg, var(--hijau-tua), var(--hijau-lebih-gelap));
  color: #fff;
  display: flex;
  flex-direction: column;
  z-index: 30;
  transform: translateX(-100%);
  transition: transform 0.2s ease;
}
.sidebar-brand {
  padding: 22px 20px 18px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.sidebar-brand .nama {
  font-family: 'Lora', serif;
  font-weight: 700;
  font-size: 20px;
  color: #fff;
}
.sidebar-brand .sub {
  display: block;
  font-size: 10.5px;
  color: var(--emas-terang);
  letter-spacing: 0.6px;
  text-transform: uppercase;
  margin-top: 3px;
}
.sidebar-nav { flex: 1; padding: 14px 12px; overflow-y: auto; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  border-radius: 8px;
  color: rgba(255,255,255,0.78);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 2px;
  transition: background 0.12s ease, color 0.12s ease;
}
.nav-item svg { width: 18px; height: 18px; flex-shrink: 0; }
.nav-item:hover { background: rgba(255,255,255,0.08); color: #fff; }
.nav-item.aktif {
  background: rgba(201, 162, 39, 0.18);
  color: var(--emas-terang);
  font-weight: 600;
}
.nav-item.aktif svg { color: var(--emas-terang); }
.nav-eyebrow {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: rgba(255,255,255,0.4);
  padding: 14px 12px 6px;
}
.sidebar-footer {
  padding: 14px 20px 18px;
  border-top: 1px solid rgba(255,255,255,0.12);
}
.sidebar-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.avatar-chip {
  width: 34px; height: 34px;
  border-radius: 50%;
  background: var(--emas);
  color: var(--hijau-lebih-gelap);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
  flex-shrink: 0;
}
.sidebar-user .nama { font-size: 13.5px; font-weight: 600; color: #fff; }
.sidebar-user .role { font-size: 11px; color: rgba(255,255,255,0.55); text-transform: capitalize; }
.link-keluar {
  display: flex; align-items: center; gap: 8px;
  font-size: 13px; color: rgba(255,255,255,0.65);
  text-decoration: none;
}
.link-keluar:hover { color: #fff; }
.link-keluar svg { width: 15px; height: 15px; }

.main-area {
  margin-left: 0;
  transition: margin-left 0.2s ease;
}

.main-topbar {
  background: var(--putih);
  border-bottom: 1px solid var(--garis);
  padding: 14px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  position: sticky;
  top: 0;
  z-index: 20;
}
.hamburger {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  cursor: pointer;
  color: var(--hijau-tua);
  flex-shrink: 0;
}
.hamburger:hover { background: var(--krem); }
.hamburger svg { width: 20px; height: 20px; }
.judul-halaman {
  font-family: 'Lora', serif;
  font-weight: 600;
  font-size: 17px;
  color: var(--hijau-tua);
}

.main-content { padding: 22px 20px 48px; }

#navToggle { display: none; }
#navToggle:checked ~ .app-shell-wrap .sidebar { transform: translateX(0); }
#navToggle:checked ~ .app-shell-wrap .overlay-gelap { display: block; }
.overlay-gelap {
  display: none;
  position: fixed; inset: 0;
  background: rgba(6, 33, 25, 0.5);
  z-index: 25;
}

@media (min-width: 960px) {
  .sidebar { transform: translateX(0); }
  .main-area { margin-left: var(--sidebar-lebar); }
  .hamburger { display: none; }
  .overlay-gelap { display: none !important; }
}

.grid-kartu {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 18px;
  align-items: start;
}
.lebar-penuh { grid-column: 1 / -1; }

.card {
  background: var(--putih);
  border-radius: 10px;
  padding: 20px;
  border: 1px solid var(--garis);
  box-shadow: 0 1px 2px rgba(13, 74, 53, 0.04);
}
.card h3, .card h4 { margin-top: 0; }

.eyebrow {
  font-family: 'Inter', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--emas);
  margin: 0 0 6px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
}
.metric-card {
  background: var(--putih);
  border: 1px solid var(--garis);
  border-radius: 10px;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
}
.metric-icon {
  width: 42px; height: 42px;
  border-radius: 9px;
  background: #eaf2ec;
  color: var(--hijau-tua);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.metric-icon svg { width: 22px; height: 22px; }
.metric-icon.emas { background: #fbf3dd; color: #8a6d10; }
.metric-num {
  font-family: 'Lora', serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--hijau-tua);
  line-height: 1.1;
}
.metric-lbl { font-size: 12px; color: var(--teks-muted); margin-top: 1px; }

label { display: block; font-size: 13px; font-weight: 600; margin: 12px 0 5px; color: var(--teks-gelap); }
input, textarea, select {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--garis);
  border-radius: 7px;
  font-size: 15px;
  font-family: inherit;
  background: var(--krem);
  color: var(--teks-gelap);
}
input:focus, textarea:focus, select:focus {
  outline: 2px solid var(--emas);
  outline-offset: 1px;
  background: var(--putih);
}
textarea { min-height: 80px; resize: vertical; }

button, .btn {
  width: 100%;
  background: var(--hijau-tua);
  color: #fff;
  border: none;
  padding: 12px;
  border-radius: 7px;
  font-size: 15px;
  font-weight: 600;
  margin-top: 16px;
  cursor: pointer;
  text-align: center;
  display: inline-block;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  transition: background 0.15s ease;
}
button:hover, .btn:hover { background: var(--hijau-gelap); }

.btn-outline {
  background: var(--putih);
  color: var(--hijau-tua);
  border: 1.5px solid var(--hijau-tua);
}
.btn-outline:hover { background: var(--krem); }

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

@media (min-width: 640px) {
  button, .btn { width: auto; padding: 10px 22px; }
  .btn-block { width: 100%; }
}

.list-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 4px;
  border-bottom: 1px solid var(--garis);
}
.list-row:last-child { border-bottom: none; }
.list-row-nama { font-weight: 600; font-size: 14.5px; }
.list-row-sub { font-size: 12.5px; color: var(--teks-muted); margin-top: 1px; }
.list-row-kanan { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

.log-item {
  border-left: 3px solid var(--hijau-tua);
  padding: 8px 12px;
  margin-bottom: 10px;
  background: var(--krem);
  border-radius: 6px;
}
.log-item .tanggal { font-size: 12px; color: var(--teks-muted); }

.badge {
  display: inline-block;
  background: #eaf2ec;
  color: var(--hijau-tua);
  font-size: 11.5px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 999px;
  white-space: nowrap;
}
.badge-emas { background: #fbf3dd; color: #8a6d10; }

.error { color: var(--merah); font-size: 14px; margin-top: 8px; }
.sukses-teks { color: var(--hijau-tua); font-size: 14px; margin-top: 8px; font-weight: 600; }

.stat-row { display: flex; gap: 10px; }
.stat-box { flex: 1; text-align: center; padding: 10px 6px; border-right: 1px solid var(--garis); }
.stat-box:last-child { border-right: none; }
.stat-box .num { font-family: 'Lora', serif; font-size: 26px; font-weight: 700; color: var(--hijau-tua); line-height: 1.1; }
.stat-box .lbl { font-size: 12px; color: var(--teks-muted); margin-top: 2px; }

.landing-nav {
  background: var(--putih);
  border-bottom: 1px solid var(--garis);
  padding: 14px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 20;
}
.landing-nav-brand {
  font-family: 'Lora', serif;
  font-weight: 700;
  font-size: 19px;
  color: var(--hijau-tua);
}
.landing-nav a.btn-nav {
  background: var(--hijau-tua);
  color: #fff;
  padding: 9px 20px;
  border-radius: 7px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
}

.landing-hero {
  background: linear-gradient(160deg, var(--hijau-tua), var(--hijau-lebih-gelap));
  color: #fff;
  padding: 64px 24px 80px;
  text-align: center;
}
.landing-hero .eyebrow-hero {
  color: var(--emas-terang);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  margin-bottom: 14px;
}
.landing-hero h1 {
  font-family: 'Lora', serif;
  color: #fff;
  font-size: 40px;
  margin: 0 0 14px;
  line-height: 1.15;
}
.landing-hero p {
  font-size: 16px;
  color: rgba(255,255,255,0.82);
  max-width: 560px;
  margin: 0 auto 28px;
  line-height: 1.6;
}
.landing-hero .btn-hero {
  display: inline-block;
  background: var(--emas);
  color: var(--hijau-lebih-gelap);
  padding: 13px 32px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  font-size: 15px;
}
.landing-hero .btn-hero:hover { background: var(--emas-terang); }

.landing-section {
  max-width: 1080px;
  margin: 0 auto;
  padding: 64px 24px;
}
.landing-section-judul {
  text-align: center;
  margin-bottom: 40px;
}
.landing-section-judul .eyebrow {
  justify-content: center;
  display: block;
  text-align: center;
}
.landing-section-judul h2 {
  font-size: 28px;
  margin: 6px 0 10px;
}
.landing-section-judul p {
  color: var(--teks-muted);
  max-width: 520px;
  margin: 0 auto;
  font-size: 15px;
}

.tab-role-row {
  display: flex;
  gap: 8px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 28px;
}
.tab-role-btn {
  background: var(--putih);
  border: 1.5px solid var(--garis);
  color: var(--teks-gelap);
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.tab-role-btn.aktif {
  background: var(--hijau-tua);
  border-color: var(--hijau-tua);
  color: #fff;
}

.langkah-role { display: none; }
.langkah-role.aktif { display: block; }

.langkah-timeline {
  border: 1px solid var(--garis);
  border-radius: 12px;
  background: var(--putih);
  overflow: hidden;
}
.langkah-item {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  padding: 24px 26px;
  border-bottom: 1px solid var(--garis);
}
.langkah-item:last-child { border-bottom: none; }
.langkah-nomor-besar {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--hijau-tua);
  color: #fff;
  font-family: 'Lora', serif;
  font-weight: 700;
  font-size: 17px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.langkah-item h4 {
  font-size: 16px;
  margin: 4px 0 6px;
  color: var(--teks-gelap);
}
.langkah-item p {
  font-size: 14px;
  color: var(--teks-muted);
  margin: 0;
  line-height: 1.55;
}

.langkah-card {
  background: var(--putih);
  border: 1px solid var(--garis);
  border-radius: 10px;
  padding: 20px;
  position: relative;
}
.langkah-nomor {
  width: 30px; height: 30px;
  border-radius: 50%;
  background: #eaf2ec;
  color: var(--hijau-tua);
  font-family: 'Lora', serif;
  font-weight: 700;
  font-size: 14px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 12px;
}
.langkah-card h4 {
  font-size: 15px;
  margin: 0 0 6px;
}
.langkah-card p {
  font-size: 13.5px;
  color: var(--teks-muted);
  margin: 0;
  line-height: 1.5;
}

.landing-section.krem { background: var(--krem); }

.masuk-wrap {
  max-width: 400px;
  margin: 0 auto;
}

.landing-footer {
  background: var(--hijau-lebih-gelap);
  color: rgba(255,255,255,0.65);
  text-align: center;
  padding: 32px 24px;
  font-size: 13px;
}
.landing-footer strong { color: #fff; }

@media (max-width: 600px) {
  .landing-hero h1 { font-size: 30px; }
  .landing-section { padding: 44px 18px; }
}

.stat-strip {
  background: var(--hijau-lebih-gelap);
  padding: 0 24px 40px;
  margin-top: -1px;
}
.stat-strip-inner {
  max-width: 900px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 20px;
  text-align: center;
}
.stat-strip .num {
  font-family: 'Lora', serif;
  font-size: 30px;
  font-weight: 700;
  color: var(--emas-terang);
}
.stat-strip .lbl {
  font-size: 12.5px;
  color: rgba(255,255,255,0.7);
  margin-top: 2px;
}

.grid-fitur {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 18px;
}
.fitur-card {
  background: var(--putih);
  border: 1px solid var(--garis);
  border-radius: 10px;
  padding: 22px 20px;
}
.fitur-card .ikon { font-size: 26px; margin-bottom: 10px; }
.fitur-card h4 { font-size: 15px; margin: 0 0 6px; }
.fitur-card p { font-size: 13px; color: var(--teks-muted); margin: 0; line-height: 1.5; }

.cta-akhir {
  text-align: center;
  padding: 60px 24px;
  background: linear-gradient(160deg, var(--hijau-tua), var(--hijau-lebih-gelap));
  color: #fff;
}
.cta-akhir h2 { color: #fff; font-size: 26px; margin: 0 0 10px; }
.cta-akhir p { color: rgba(255,255,255,0.8); margin: 0 0 24px; }

.landing-nav .nav-links { display: flex; gap: 20px; align-items: center; }
.landing-nav .nav-links a.link-anchor {
  font-size: 14px; color: var(--teks-gelap); text-decoration: none; font-weight: 500;
}
.landing-nav .nav-links a.link-anchor:hover { color: var(--hijau-tua); }
@media (max-width: 680px) {
  .landing-nav .nav-links a.link-anchor { display: none; }
}

/* ===== Branding FAHA (ikon + teks) ===== */
.brand-row {
  display: flex;
  align-items: center;
  gap: 10px;
}
.brand-icon-chip {
  width: 34px; height: 34px;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  padding: 2px;
}
.brand-icon-chip img { width: 100%; height: 100%; object-fit: contain; }
.brand-text-faha {
  font-family: 'Inter', sans-serif;
  line-height: 1.1;
}
.brand-text-faha .nama-besar { font-weight: 800; font-size: 12px; letter-spacing: 0.3px; }
.brand-text-faha .sub-kecil { font-size: 9px; opacity: 0.75; }

.footer-kontak {
  font-size: 12.5px;
  color: rgba(255,255,255,0.55);
  margin-top: 10px;
}
.footer-kontak a { color: rgba(255,255,255,0.75); text-decoration: none; }
.footer-kontak a:hover { color: var(--emas-terang); }

/* ===== Brand chip tunggal ala SIGB (logo lengkap + nama app) ===== */
.brand-icon-chip-full {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.12);
  padding: 6px 10px;
  flex-shrink: 0;
}
.brand-icon-chip-full img {
  height: 44px;
  width: auto;
  display: block;
}

/* ===== Shell mahasiswa: bottom-nav biru-teal (redesain KKN mobile-style) ===== */
:root {
  --biru-tua: #1565c0;
  --biru-terang: #1e88e5;
  --teal: #00acc1;
  --mhs-bg: #f4f7f6;
}

body.mode-mahasiswa { background: var(--mhs-bg); margin:0; }

.mhs-shell {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: #fff;
  display: flex;
  flex-direction: column;
  position: relative;
  padding-bottom: 76px;
  box-shadow: 0 0 30px rgba(0,0,0,0.06);
}

.mhs-topbar {
  background: linear-gradient(135deg, var(--biru-terang), var(--biru-tua));
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 10;
}
.mhs-topbar-brand { display:flex; align-items:center; gap:8px; font-weight:700; font-size:15px; }
.mhs-topbar-brand img { height:26px; width:auto; background:#fff; border-radius:6px; padding:2px; display:block; }
.mhs-judul { font-size:13px; opacity:.9; font-weight:600; }

.mhs-content { flex:1; padding: 16px 16px 20px; }

.mhs-bottomnav {
  position: fixed;
  bottom: 0; left: 50%; transform: translateX(-50%);
  width: 100%; max-width: 480px;
  background: #fff;
  border-top: 1px solid #e5e5e5;
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: 8px 0 max(8px, env(safe-area-inset-bottom));
  z-index: 20;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.05);
}
.mhs-nav-item {
  display: flex; flex-direction: column; align-items:center; gap:2px;
  color: #90a4ae; text-decoration:none; font-size:11px; font-weight:600;
  position: relative; padding: 4px 10px; background:none; border:none; cursor:pointer;
}
.mhs-nav-item svg { width:22px; height:22px; }
.mhs-nav-item.aktif { color: var(--biru-tua); }
.mhs-badge {
  position:absolute; top:-2px; right:2px;
  background:#d32f2f; color:#fff; font-size:9.5px; font-weight:700;
  border-radius:999px; padding:1px 5px; min-width:15px; text-align:center;
}

.mhs-card {
  background:#fff; border:1px solid #e5e5e5; border-radius:14px;
  padding:16px; margin-bottom:14px; box-shadow: 0 2px 8px rgba(0,0,0,0.03);
}
.mhs-welcome {
  background: linear-gradient(135deg, var(--biru-terang), var(--teal));
  color:#fff; border-radius:16px; padding:20px; margin-bottom:16px;
}
.mhs-welcome h2 { margin:0 0 4px; font-size:19px; }
.mhs-welcome p { margin:0; font-size:13px; opacity:.92; }

/* ===== Override tombol untuk mode mahasiswa (biru-teal) ===== */
body.mode-mahasiswa button:not(.mhs-nav-item) {
  background: var(--biru-tua);
}
body.mode-mahasiswa button:not(.mhs-nav-item):hover {
  background: var(--biru-terang);
}
body.mode-mahasiswa .badge {
  background: #e3f2fd;
  color: var(--biru-tua);
}

/* ===== Hamburger dropdown menu mahasiswa ===== */
.mhs-menu-toggle { display:none; }
.mhs-dropdown-menu {
  display:none;
  flex-direction:column;
  background:#0d3d6b;
}
.mhs-dropdown-menu a {
  padding:14px 20px;
  color:#e3f2fd;
  text-decoration:none;
  font-size:14px;
  border-bottom:1px solid rgba(255,255,255,0.08);
}
.mhs-dropdown-menu a:last-child { border-bottom:none; }
.mhs-dropdown-menu a.aktif { color:#ffb300; font-weight:700; }
.mhs-menu-toggle:checked ~ .mhs-dropdown-menu { display:flex; }
.mhs-hamburger-btn { cursor:pointer; color:#fff; display:flex; align-items:center; }
