:root {
  --primary: #0077b6;
  --primary-dark: #023e8a;
  --bg: #f6f9fc;
  --white: #fff;
  --danger: #d90429;
  --gray: #6c757d;
  --success: #10b981;
  --info: #4361ee;
  --shadow: 0 2px 16px rgba(0,0,0,0.09);
}

body {
  background: var(--bg);
  font-family: 'Segoe UI', Arial, sans-serif;
  margin: 0;
  padding: 0;
  color: #222;
}
.container {
  max-width: 1000px;
  margin: 32px auto;
  background: var(--white);
  border-radius: 11px;
  box-shadow: var(--shadow);
  padding: 32px 18px;
}

.text-center {
  text-align: center;
}
h1, h2, h3 {
  color: var(--primary-dark);
  margin-top: 0;
}
a {
  color: var(--primary);
  text-decoration: none;
  transition: 0.2s;
  font-weight: 500;
}
a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}
button, input[type="submit"] {
  background: var(--primary);
  color: var(--white);
  border: none;
  padding: 9px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 1em;
  margin: 2px 0;
  transition: background 0.2s;
}
button:hover, input[type="submit"]:hover {
  background: var(--primary-dark);
}
input[type="text"],
input[type="password"],
input[type="number"],
input[type="date"],
textarea,
select {
  width: 97%;
  padding: 9px;
  margin: 5px 0 15px 0;
  border: 1px solid #bbb;
  border-radius: 6px;
  box-sizing: border-box;
  font-size: 1em;
  background: #f8fafc;
}
textarea { min-height: 70px; resize: vertical; }
label { font-weight: 500; color: #222; }
table {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0;
  background: var(--white);
  border-radius: 6px;
  overflow: hidden;
}
th, td {
  border: 1px solid #e3eaf0;
  padding: 10px 9px;
  text-align: left;
  font-size: 0.99em;
}
th {
  background: var(--primary);
  color: var(--white);
  font-weight: 600;
}
tr:nth-child(even) td {
  background: #f5f9fc;
}
form {
  margin: 0 0 18px 0;
}
.error {
  background: #ffd6d6;
  color: #b00020;
  border-left: 5px solid var(--danger);
  padding: 10px 15px;
  margin: 18px 0;
  border-radius: 4px;
}
.success {
  background: #d1fae5;
  color: #065f46;
  border-left: 5px solid #10b981;
  padding: 10px 15px;
  margin: 18px 0;
  border-radius: 4px;
}
.topnav {
  background: var(--primary-dark);
  padding: 10px 12px;
  border-radius: 8px 8px 0 0;
  margin-bottom: 18px;
}
.topnav a {
  color: #fff;
  margin-right: 18px;
  font-weight: 500;
  font-size: 1em;
  text-decoration: none;
}
.topnav a.active, .topnav a:hover {
  color: #ffc300;
}

/* --- Dashboard Table & Filter Fixes --- */
.dashboard-filter-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  background: none;
  margin-bottom: 10px;
  justify-content: center; /* Tambahan agar filter center */
}
.dashboard-filter-row input[type="text"],
.dashboard-filter-row input[type="date"],
.dashboard-filter-row select {
  width: auto;
  min-width: 120px;
  max-width: 200px;
  margin: 0;
  padding: 8px 10px;
  border-radius: 7px;
  background: #f6faff;
  font-size: 1em;
}
.dashboard-filter-row button {
  padding: 10px 20px;
  border-radius: 7px;
  font-size: 1em;
  font-weight: 500;
  margin: 0;
}
.dashboard-date-range {
  margin-bottom: 10px;
  color: var(--primary-dark);
  font-weight: 500;
}

/* Tabel dashboard khusus aksi */
.table-dashboard th, .table-dashboard td {
  padding: 12px 8px;
  text-align: left;
  vertical-align: middle;
}
.table-dashboard th {
  background: var(--primary);
  color: #fff;
  font-weight: 600;
  border-bottom: 2px solid #e6e6e6;
}
.table-dashboard tr:nth-child(even) {
  background: #f7fafc;
}
.table-dashboard tr {
  border-bottom: 1.5px solid #e8eef4;
}
.table-dashboard td.aksi {
  min-width: 120px;
  max-width: 155px;
  display: flex;
  flex-direction: column;
  gap: 3px;
  align-items: flex-start;
}
.btn-hapus {
  background: var(--danger);
  color: #fff;
  border: none;
  border-radius: 7px;
  padding: 7px 20px;
  font-size: 1em;
  cursor: pointer;
  margin-top: 4px;
  margin-bottom: 2px;
  width: 100%;
  max-width: 120px;
  transition: background 0.2s;
}
.btn-hapus:hover {
  background: #b00020;
}
.aksi-link {
  color: var(--primary-dark);
  text-decoration: none;
  margin-right: 8px;
  display: inline-block;
  font-size: 1em;
}
.aksi-link:last-child {
  margin-right: 0;
}

/* --- CSS BARU TAMBAHAN --- */

/* Info box for latest revision or announcements */
.info-box {
  background: #f1f6fa;
  border-left: 5px solid var(--info);
  padding: 12px 18px;
  margin: 16px 0 22px 0;
  border-radius: 7px;
  color: #24326a;
  font-size: 1.04em;
}

.badge {
  display: inline-block;
  padding: 2px 10px;
  font-size: 0.92em;
  border-radius: 14px;
  color: #fff;
  background: var(--primary-dark);
  margin-right: 6px;
  font-weight: 500;
  letter-spacing: .5px;
  vertical-align: middle;
}
.badge-success { background: var(--success);}
.badge-danger { background: var(--danger);}
.badge-info   { background: var(--info);}
.badge-gray   { background: var(--gray);}

.card {
  background: #f8fbff;
  border-radius: 12px;
  box-shadow: 0 1.5px 10px #0002;
  padding: 22px 24px;
  margin: 18px 0;
  border: 1.5px solid #e3eaf0;
}
.card-title {
  font-size: 1.20em;
  color: var(--primary-dark);
  margin-bottom: 8px;
  font-weight: 600;
}
.card-content {
  color: #444;
  font-size: 1.04em;
}
.card-actions {
  margin-top: 14px;
}

/* Custom alert/info/success for inline messages */
.alert {
  padding: 12px 18px;
  border-radius: 6px;
  margin: 18px 0;
  font-size: 1em;
}
.alert-info {
  background: #e3eaff;
  color: #23318d;
  border-left: 4px solid var(--info);
}
.alert-success {
  background: #dcfce7;
  color: #065f46;
  border-left: 4px solid var(--success);
}
.alert-danger {
  background: #ffe6e6;
  color: #a4001d;
  border-left: 4px solid var(--danger);
}

/* Responsive improvements - new */
@media (max-width: 700px) {
  .container {
    max-width: 99vw;
    padding: 7vw 2vw;
  }
  th, td {
    padding: 6px 2px;
    font-size: 0.96em;
  }
  h1, h2 {
    font-size: 1.23em;
  }
  .topnav a { font-size: 0.95em; }
  .dashboard-filter-row input,
  .dashboard-filter-row select,
  .dashboard-filter-row button {
    font-size: 0.93em;
    min-width: 80px;
    max-width: 150px;
    padding: 7px 7px;
  }
  .card {
    padding: 7vw 2vw;
  }
}

/* Print-friendly table (optional) */
@media print {
  .container, .card { box-shadow: none !important; border: none !important; }
  body { background: #fff !important; }
  .topnav, .dashboard-filter-row, .btn-hapus, .aksi-link, .alert, .info-box { display: none !important; }
}

.logo-container {
    text-align: center;
    margin-bottom: 5px;
}
.logo {
    max-width: 130px;
    height: auto;
}
.user-role-badge {
            display:inline-block;
            background:#eee;
            border-radius:4px;
            color:#444;
            font-size:13px;
            padding:4px 10px;
            margin-right:12px;
            vertical-align:middle;
        }
        @media (max-width: 600px) {
            .user-role-badge {
                display:block;
                margin-bottom:8px;
            }
            .topnav {
                display: flex;
                flex-direction: column;
                gap: 6px;
            }
          }