:root {
    --navy: #0b2545;
    --navy-dark: #071a33;
    --gold: #c8a24a;
    --gold-dark: #a9843a;
    --bg: #f4f6f9;
    --card-bg: #ffffff;
    --text: #1c2733;
    --muted: #6b7688;
    --border: #e2e6ec;
    --success: #1e7e45;
    --danger: #c0392b;
    --radius: 12px;
    --shadow: 0 4px 18px rgba(11, 37, 69, 0.08);
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    min-height: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: var(--bg);
    color: var(--text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    line-height: 1.5;
}

a { color: inherit; text-decoration: none; }

/* ===== Top bar ===== */
.topbar {
    background: linear-gradient(135deg, var(--navy) 0%, var(--navy-dark) 100%);
    color: #fff;
    padding: 28px 20px 90px;
    text-align: center;
}

.topbar .site-logo {
    display: block;
    width: 84px;
    height: 84px;
    margin: 0 auto 14px;
    object-fit: contain;
}

@media (max-width: 560px) {
    .topbar .site-logo {
        width: 60px;
        height: 60px;
        margin-bottom: 10px;
    }
}

.topbar .eyebrow {
    letter-spacing: 3px;
    font-size: 12px;
    text-transform: uppercase;
    color: var(--gold);
    font-weight: 600;
    margin-bottom: 10px;
}

.topbar h1 {
    margin: 0;
    font-size: clamp(24px, 5vw, 40px);
    font-weight: 800;
    letter-spacing: 1px;
}

.topbar p.subtitle {
    margin: 10px 0 0;
    color: #cdd7e6;
    font-size: 15px;
}

/* ===== Main container ===== */
.wrapper {
    flex: 1;
    width: 100%;
    max-width: 880px;
    margin: -60px auto 40px;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

.card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 28px;
    margin-bottom: 24px;
}

/* ===== Menu buttons (landing page) ===== */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

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

.menu-btn {
    display: flex;
    align-items: center;
    gap: 14px;
    background: #fff;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 22px 20px;
    box-shadow: var(--shadow);
    font-weight: 700;
    font-size: 16px;
    color: var(--navy);
    transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}

.menu-btn:hover, .menu-btn:focus-visible {
    transform: translateY(-3px);
    border-color: var(--gold);
    box-shadow: 0 10px 24px rgba(11,37,69,0.14);
}

.menu-btn .icon {
    width: 44px;
    height: 44px;
    flex: none;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--navy), var(--navy-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gold);
    font-size: 20px;
}

.menu-btn span.label small {
    display: block;
    font-weight: 400;
    color: var(--muted);
    font-size: 12px;
    margin-top: 2px;
}

/* ===== Buttons (generic) ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: none;
    border-radius: 8px;
    padding: 13px 24px;
    font-size: 15px;
    font-weight: 700;
    cursor: pointer;
    transition: background .15s ease, opacity .15s ease;
    text-align: center;
}

.btn-primary {
    background: var(--navy);
    color: #fff;
}
.btn-primary:hover { background: var(--navy-dark); }

.btn-gold {
    background: var(--gold);
    color: var(--navy-dark);
}
.btn-gold:hover { background: var(--gold-dark); }

.btn-outline {
    background: transparent;
    color: var(--navy);
    border: 1.5px solid var(--navy);
}
.btn-outline:hover { background: var(--navy); color: #fff; }

.btn-block { width: 100%; }
.btn:disabled { opacity: .6; cursor: not-allowed; }

.btn-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 18px;
}

/* ===== Forms ===== */
.form-group { margin-bottom: 18px; }

.form-group label {
    display: block;
    font-weight: 700;
    font-size: 14px;
    margin-bottom: 6px;
    color: var(--navy);
}

.form-control {
    width: 100%;
    padding: 12px 14px;
    border: 1.5px solid var(--border);
    border-radius: 8px;
    font-size: 15px;
    background: #fff;
    color: var(--text);
}

.form-control:focus {
    outline: none;
    border-color: var(--navy);
}

.check-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 4px 0 18px;
}

.check-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    accent-color: var(--navy);
}

.check-row label {
    font-weight: 600;
    font-size: 14px;
}

#wakilBox { display: none; margin-top: -6px; }

/* ===== Autocomplete suggest box ===== */
.suggest-box {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    z-index: 20;
    background: #fff;
    border: 1.5px solid var(--border);
    border-radius: 8px;
    margin-top: 4px;
    max-height: 260px;
    overflow-y: auto;
    box-shadow: var(--shadow);
    display: none;
}

.suggest-item {
    padding: 10px 14px;
    cursor: pointer;
    border-bottom: 1px solid var(--border);
}
.suggest-item:last-child { border-bottom: none; }
.suggest-item:hover, .suggest-item.active { background: #eef2f7; }

.suggest-item .s-nama { font-weight: 700; color: var(--navy); font-size: 14px; }
.suggest-item .s-meta { font-size: 12px; color: var(--muted); margin-top: 2px; }
.suggest-item .s-daftar { font-size: 11px; color: var(--danger); font-weight: 700; margin-top: 2px; }

.suggest-empty { padding: 12px 14px; color: var(--muted); font-size: 13px; }

.alert {
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 14px;
    margin-bottom: 16px;
}
.alert-success { background: #e5f5ea; color: var(--success); border: 1px solid #bfe6cc; }
.alert-danger { background: #fbeae7; color: var(--danger); border: 1px solid #f2c7bf; }

/* ===== Table ===== */
.table-wrap {
    overflow-x: auto;
    border: 1px solid var(--border);
    border-radius: 10px;
}

table.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    min-width: 480px;
}

table.data-table th, table.data-table td {
    padding: 12px 14px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

table.data-table th {
    background: var(--navy);
    color: #fff;
    font-weight: 700;
    position: sticky;
    top: 0;
}

table.data-table tbody tr:nth-child(even) { background: #f8f9fb; }
table.data-table tbody tr:hover { background: #eef2f7; }

.badge-wakil {
    display: inline-block;
    background: #fff4e0;
    color: #8a5a00;
    border: 1px solid #f0d9a6;
    border-radius: 6px;
    padding: 2px 8px;
    font-size: 12px;
    font-weight: 700;
}

.badge-walkin {
    display: inline-block;
    background: #e6f0ff;
    color: #1a4d99;
    border: 1px solid #b8d4f5;
    border-radius: 6px;
    padding: 2px 8px;
    font-size: 12px;
    font-weight: 700;
}

.muted { color: var(--muted); font-size: 13px; }
.text-center { text-align: center; }

h2.section-title {
    margin: 0 0 4px;
    font-size: 20px;
    color: var(--navy);
}

h2.section-title + p.muted { margin-top: 0; margin-bottom: 20px; }

.search-box { margin-bottom: 16px; }

/* ===== Login ===== */
.login-wrapper {
    max-width: 400px;
    margin: 80px auto;
    padding: 0 20px;
}

.login-logo {
    text-align: center;
    margin-bottom: 20px;
}

.login-logo .badge {
    display: inline-block;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--navy), var(--navy-dark));
    color: var(--gold);
    font-weight: 800;
    font-size: 22px;
    line-height: 56px;
}

/* ===== Admin topbar (simpler) ===== */
.admin-bar {
    background: var(--navy);
    color: #fff;
    padding: 16px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}
.admin-bar strong { color: var(--gold); }

/* ===== Footer ===== */
.site-footer {
    text-align: center;
    padding: 20px;
    color: var(--muted);
    font-size: 13px;
}

/* ===== Utility ===== */
.flex-between {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 18px;
}