/* =====================================================================
   MASYARAKAT.CSS - Komponen halaman masyarakat
   (profil, informasi, layanan, pengaduan, rekomendasi BBM, lacak)
   Navbar, tombol hero, dan footer ada di ../style.css
   ===================================================================== */

body.halaman {
    background: var(--bg);
}

/* ---------- KEPALA HALAMAN ---------- */
.page-header {
    position: relative;
    background:
        linear-gradient(105deg, rgba(10, 38, 25, 0.96) 0%, rgba(15, 51, 35, 0.9) 55%, rgba(22, 101, 52, 0.82) 100%),
        var(--brand-900) url("../images/dinas.jpg") center / cover no-repeat;
    color: #fff;
}

.header-overlay {
    max-width: 1140px;
    margin: 0 auto;
    padding: calc(var(--nav-h) + 44px) 24px 52px;
}

.breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 14px;
    color: rgba(255, 255, 255, 0.65);
    font-size: 13px;
}

.breadcrumb a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
}

.breadcrumb a:hover {
    color: #fff;
}

.breadcrumb .ikon-next {
    opacity: 0.6;
}

.breadcrumb [aria-current] {
    color: var(--brand-400);
    font-weight: 600;
}

.header-overlay h1 {
    margin-bottom: 10px;
    font-size: clamp(26px, 4.2vw, 40px);
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: -0.025em;
    text-wrap: balance;
}

.header-overlay p {
    max-width: 640px;
    color: rgba(255, 255, 255, 0.8);
    font-size: clamp(14.5px, 1.6vw, 16.5px);
    line-height: 1.7;
}

/* ---------- TATA LETAK ---------- */
.container {
    width: 100%;
    max-width: 1140px;
    margin: 0 auto;
    padding: 48px 24px 72px;
}

.container.sempit {
    max-width: 880px;
}

.grid-kartu {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 24px;
}

.kartu {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.kartu.naik {
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.kartu.naik:hover {
    transform: translateY(-5px);
    border-color: #bbf7d0;
    box-shadow: 0 22px 44px -22px rgba(16, 35, 26, 0.35);
}

/* Ubin ikon dipakai di banyak kartu */
.ikon-ubin,
.layanan-card > .ikon,
.layanan-unggulan > .ikon,
.profile-card > .ikon,
.kosong .ikon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    background: var(--brand-100);
    border: 1px solid #bbf7d0;
    color: var(--brand-600);
}

/* ---------- STATUS KOSONG ---------- */
.kosong {
    grid-column: 1 / -1;
    padding: 64px 24px;
    background: var(--surface);
    border: 1px dashed #cfdad3;
    border-radius: var(--radius);
    text-align: center;
}

.kosong .ikon {
    width: 68px;
    height: 68px;
    margin: 0 auto 18px;
    border-radius: 20px;
}

.kosong h3 {
    margin-bottom: 6px;
    font-size: 18px;
    color: var(--text);
}

.kosong p {
    color: var(--text-3);
    font-size: 14.5px;
}

/* ---------- NOTIFIKASI ---------- */
.alert {
    position: relative;
    margin-bottom: 22px;
    padding: 16px 20px 16px 54px;
    border: 1px solid;
    border-radius: 12px;
    font-size: 14.5px;
    line-height: 1.7;
}

.alert::before {
    content: "";
    position: absolute;
    left: 20px;
    top: 17px;
    width: 22px;
    height: 22px;
    background: currentColor;
    -webkit-mask: var(--alert-icon) center / contain no-repeat;
    mask: var(--alert-icon) center / contain no-repeat;
}

.alert.success {
    --alert-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='m9 12 2 2 4-4'/%3E%3C/svg%3E");
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #166534;
}

.alert.error {
    --alert-icon: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v4'/%3E%3Cpath d='M12 16h.01'/%3E%3C/svg%3E");
    background: #fef2f2;
    border-color: #fecaca;
    color: #b91c1c;
}

.form-card + .alert {
    margin-top: 22px;
}

.alert a {
    font-weight: 600;
    text-decoration: underline;
}

.nomor-pengajuan {
    display: inline-block;
    padding: 2px 10px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid currentColor;
    border-radius: 8px;
    font-family: ui-monospace, "SF Mono", Consolas, monospace;
    font-size: 0.95em;
    font-weight: 700;
    letter-spacing: 0.02em;
}

/* ---------- LAYANAN PUBLIK ---------- */
.layanan-unggulan {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-bottom: 28px;
    padding: 28px 32px;
    background: linear-gradient(120deg, var(--brand-900), var(--brand-700));
    border-radius: 20px;
    color: #fff;
    box-shadow: var(--shadow-lg);
}

.layanan-unggulan > .ikon {
    width: 64px;
    height: 64px;
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.22);
    border-radius: 18px;
    color: var(--brand-400);
}

.layanan-unggulan .isi {
    flex: 1;
    min-width: 0;
}

.layanan-unggulan h3 {
    margin-bottom: 6px;
    font-size: 20px;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

.layanan-unggulan p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 14.5px;
    line-height: 1.7;
}

.layanan-unggulan .aksi {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex-shrink: 0;
}

.layanan-unggulan .aksi a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 20px;
    border-radius: 11px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    transition: transform 0.2s ease, background 0.2s ease;
}

.layanan-unggulan .utama {
    background: #fff;
    color: var(--brand-800);
}

.layanan-unggulan .utama:hover {
    background: var(--brand-100);
    transform: translateY(-2px);
}

.layanan-unggulan .kedua {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.28);
    color: #fff;
}

.layanan-unggulan .kedua:hover {
    background: rgba(255, 255, 255, 0.2);
}

.layanan-card {
    display: flex;
    flex-direction: column;
    padding: 26px;
}

.layanan-card > .ikon {
    width: 52px;
    height: 52px;
    margin-bottom: 18px;
    border-radius: 15px;
}

.layanan-card h3 {
    margin-bottom: 10px;
    font-size: 18px;
    line-height: 1.35;
    letter-spacing: -0.01em;
    color: var(--text);
}

.layanan-card .deskripsi {
    margin-bottom: 18px;
    color: var(--text-2);
    font-size: 14.5px;
    line-height: 1.7;
}

/* ---------- INFORMASI ---------- */
.informasi-card {
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.informasi-image,
.informasi-card .tanpa-gambar {
    width: 100%;
    aspect-ratio: 16 / 10;
    object-fit: cover;
    display: block;
}

.informasi-card .tanpa-gambar {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--brand-50), #e1f0e7);
    color: var(--brand-600);
}

.informasi-card .isi {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 20px 22px 22px;
}

.informasi-card .tanggal {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
    color: var(--text-3);
    font-size: 12.5px;
    font-weight: 500;
}

.informasi-card h3 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 10px;
    color: var(--text);
    font-size: 18px;
    line-height: 1.4;
    letter-spacing: -0.01em;
}

.informasi-card .ringkasan {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 18px;
    color: var(--text-2);
    font-size: 14.5px;
    line-height: 1.7;
}

.informasi-card .bawah {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid var(--border);
}

.informasi-card .penulis {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-width: 0;
    overflow: hidden;
    color: var(--text-3);
    font-size: 12.5px;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.btn-baca {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    color: var(--brand-600);
    font-size: 13.5px;
    font-weight: 600;
}

.btn-baca:hover {
    color: var(--brand-800);
}

/* Modal detail informasi */
.modal-informasi {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 10000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: rgba(5, 20, 13, 0.62);
    backdrop-filter: blur(4px);
}

.modal-close {
    position: absolute;
    top: 22px;
    right: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-2);
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.modal-close:hover {
    background: #fee2e2;
    color: #b91c1c;
}

/* ---------- PROFIL DINAS ---------- */
.profile-card {
    display: flex;
    gap: 22px;
    align-items: flex-start;
    margin-bottom: 24px;
    padding: 30px;
}

.profile-card > .ikon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
}

.profile-card .isi {
    flex: 1;
    min-width: 0;
}

.profile-card h2 {
    color: var(--brand-900);
    font-size: 22px;
    line-height: 1.35;
    font-weight: 800;
    letter-spacing: -0.02em;
}

/* ---------- FORMULIR ---------- */
.syarat-box {
    margin-bottom: 24px;
    padding: 24px 28px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: var(--radius);
}

.syarat-box h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: #92400e;
    font-size: 16px;
}

.syarat-box ol {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px 28px;
    margin: 0 0 14px 20px;
    color: #78350f;
    font-size: 14px;
}

.syarat-box li {
    padding-left: 4px;
}

.syarat-box p {
    color: #92400e;
    font-size: 13.5px;
}

.form-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

.form-card > form {
    padding: 30px 32px 32px;
}

.form-header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px 32px;
    background: linear-gradient(180deg, var(--brand-50), var(--surface));
    border-bottom: 1px solid var(--border);
}

.form-header > .ikon-ubin {
    width: 48px;
    height: 48px;
    border-radius: 14px;
}

.form-header h2 {
    color: var(--brand-900);
    font-size: 20px;
    line-height: 1.3;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.form-header p {
    margin-top: 2px;
    color: var(--text-3);
    font-size: 14px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 22px;
}

.form-group {
    margin-bottom: 22px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: var(--text);
    font-size: 14px;
    font-weight: 600;
}

.form-group label span {
    color: #dc2626;
}

.form-group input,
.form-group select,
.form-group textarea {
    display: block;
    width: 100%;
    min-height: 48px;
    padding: 12px 16px;
    background: var(--surface);
    border: 1px solid #cfdad3;
    border-radius: 12px;
    color: var(--text);
    font-family: inherit;
    font-size: 15px;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #a3b1a9;
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover {
    border-color: #a9bcb0;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--brand-500);
    box-shadow: 0 0 0 4px rgba(22, 163, 74, 0.16);
}

.form-group textarea {
    min-height: 130px;
    resize: vertical;
    line-height: 1.7;
}

.form-group input[type="file"] {
    padding: 8px;
    background: var(--surface-2);
    border-style: dashed;
    font-size: 13.5px;
    color: var(--text-2);
    cursor: pointer;
}

.form-group input[type="file"]::file-selector-button {
    margin-right: 14px;
    padding: 9px 16px;
    background: var(--brand-800);
    border: 0;
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.form-group input[type="file"]::file-selector-button:hover {
    background: var(--brand-950);
}

.form-group small {
    display: block;
    margin-top: 7px;
    color: var(--text-3);
    font-size: 12.5px;
    line-height: 1.55;
}

.form-group small.info-berkas:empty {
    display: none;
}

.form-group small.info-berkas.ok {
    color: var(--brand-600);
    font-weight: 600;
}

.form-group small.info-berkas.salah,
.form-group input.salah {
    color: #b91c1c;
}

.form-group input.salah {
    border-color: #f87171;
}

.pernyataan {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 26px;
    padding: 16px 18px;
    background: var(--brand-50);
    border: 1px solid #bbf7d0;
    border-radius: 12px;
    cursor: pointer;
}

.pernyataan input {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--brand-600);
    cursor: pointer;
}

.pernyataan span {
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.6;
}

.judul-berkas {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 8px 0 4px;
    padding-top: 22px;
    border-top: 1px solid var(--border);
    color: var(--brand-900);
    font-size: 17px;
}

.petunjuk-berkas {
    margin-bottom: 20px;
    color: var(--text-3);
    font-size: 13.5px;
}

.grid-berkas {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 22px;
}

.grid-berkas .form-group {
    padding: 16px;
    margin-bottom: 16px;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 14px;
}

.grid-berkas .form-group label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13.5px;
    line-height: 1.4;
}

.form-group label .nomor {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 24px;
    width: 24px;
    height: 24px;
    background: var(--brand-600);
    border-radius: 50%;
    color: #fff;
    font-size: 12px;
    font-weight: 700;
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    padding-top: 6px;
}

.form-actions button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 50px;
    padding: 0 28px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}

.btn-reset {
    background: var(--surface);
    border-color: #cfdad3 !important;
    color: var(--text-2);
}

.btn-reset:hover {
    background: var(--surface-2);
}

.btn-submit {
    background: var(--brand-600);
    color: #fff;
    box-shadow: 0 10px 24px -10px rgba(21, 128, 61, 0.8);
}

.btn-submit:hover {
    background: var(--brand-700);
    transform: translateY(-1px);
}

/* ---------- LACAK STATUS ---------- */
.hasil-lacak {
    margin-top: 22px;
    padding: 26px 28px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-left: 5px solid #f59e0b;
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.hasil-lacak.hasil-diproses {
    border-left-color: #2563eb;
}

.hasil-lacak.hasil-selesai {
    border-left-color: var(--brand-500);
}

.hasil-lacak.hasil-ditolak {
    border-left-color: #dc2626;
}

.hasil-atas {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 14px;
}

.hasil-label {
    display: block;
    margin-bottom: 4px;
    color: var(--text-3);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.hasil-atas .nomor-pengajuan {
    background: var(--surface-2);
    color: var(--text);
    border-color: var(--border);
}

.badge-status {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    flex-shrink: 0;
    padding: 6px 14px;
    border: 1px solid transparent;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
}

.badge-status::before {
    content: "";
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: currentColor;
}

.badge-menunggu {
    background: #fffbeb;
    border-color: #fde68a;
    color: #b45309;
}

.badge-diproses {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #1d4ed8;
}

.badge-selesai {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #15803d;
}

.badge-ditolak {
    background: #fef2f2;
    border-color: #fecaca;
    color: #b91c1c;
}

.hasil-info {
    margin-bottom: 20px;
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.9;
}

.hasil-info strong {
    color: var(--text);
}

.garis-waktu {
    position: relative;
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
    padding: 4px 6px 0;
}

.garis-waktu::before {
    content: "";
    position: absolute;
    top: 21px;
    left: 12%;
    right: 12%;
    height: 3px;
    background: #e3eae5;
    border-radius: 3px;
}

.garis-waktu .tahap {
    position: relative;
    z-index: 1;
    display: flex;
    flex: 1;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: var(--text-3);
    font-size: 13px;
    font-weight: 600;
}

.garis-waktu .tahap span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: var(--surface);
    border: 2px solid #d3ddd7;
    border-radius: 50%;
    color: var(--text-3);
    font-size: 14px;
    font-weight: 700;
}

.garis-waktu .tahap.aktif {
    color: var(--brand-700);
}

.garis-waktu .tahap.aktif span {
    background: var(--brand-600);
    border-color: var(--brand-600);
    color: #fff;
    box-shadow: 0 0 0 5px rgba(22, 163, 74, 0.16);
}

.garis-waktu.ditolak::before {
    display: none;
}

.garis-waktu.ditolak .tahap.aktif {
    color: #b91c1c;
}

.garis-waktu.ditolak .tahap.aktif span {
    background: #dc2626;
    border-color: #dc2626;
    box-shadow: 0 0 0 5px rgba(220, 38, 38, 0.14);
}

.hasil-keterangan {
    padding: 14px 16px;
    background: var(--surface-2);
    border-radius: 12px;
    color: var(--text-2);
    font-size: 14px;
    line-height: 1.7;
}

.hasil-catatan {
    margin-top: 14px;
    padding: 14px 16px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 12px;
    color: #78350f;
    font-size: 14px;
    line-height: 1.7;
}

.hasil-catatan strong {
    color: #92400e;
}

/* ---------- RESPONSIF ---------- */
@media (max-width: 1000px) {
    .grid-kartu {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 800px) {
    .layanan-unggulan {
        flex-direction: column;
        align-items: flex-start;
        padding: 26px 24px;
    }

    .layanan-unggulan .aksi {
        width: 100%;
    }

    .syarat-box ol,
.grid-berkas {
        grid-template-columns: minmax(0, 1fr);
    }
}

@media (max-width: 640px) {
    .header-overlay {
        padding: calc(var(--nav-h) + 30px) 20px 36px;
    }

    .container {
        padding: 32px 16px 56px;
    }

    .grid-kartu {
        grid-template-columns: minmax(0, 1fr);
        gap: 18px;
    }

    .profile-card {
        flex-direction: column;
        gap: 16px;
        padding: 24px 20px;
    }

    

    .form-card > form {
        padding: 22px 20px 24px;
    }

    .form-header {
        padding: 20px;
    }

    .form-row {
        grid-template-columns: minmax(0, 1fr);
    }

    .form-actions {
        flex-direction: column-reverse;
    }

    .form-actions button {
        width: 100%;
    }

    .informasi-card .bawah {
        flex-wrap: wrap;
    }

    .hasil-lacak {
        padding: 22px 18px;
    }

    .hasil-atas {
        flex-direction: column;
    }

    .garis-waktu::before {
        left: 16%;
        right: 16%;
    }

    
}

/* =====================================================================
   PROFIL DINAS - tata letak baru (foto + teks, kepala dinas,
   struktur organisasi, kontak). Kelas diawali "pd-".
   ===================================================================== */
.pd-badge {
    display: inline-block;
    padding: 7px 16px;
    background: linear-gradient(135deg, var(--brand-700), var(--brand-800));
    border-radius: 999px;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1.2;
}

/* ----- Tentang dinas ----- */
.pd-tentang {
    display: grid;
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    gap: 28px;
    align-items: start;
    margin-bottom: 28px;
}

.pd-tentang.tanpa-foto {
    grid-template-columns: minmax(0, 1fr);
}

.pd-foto-dinas {
    display: block;
    width: 100%;
    height: auto;
    max-height: 640px;
    object-fit: contain;
    background: var(--surface-2);
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: var(--shadow);
}

.pd-tentang-teks h2 {
    margin: 12px 0 10px;
    color: var(--brand-900);
    font-size: 26px;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.pd-tentang-teks p {
    color: var(--text-2);
    font-size: 15px;
    line-height: 1.85;
    overflow-wrap: anywhere;
}

/* ----- Visi, misi, tugas dan fungsi ----- */

.pd-bidang,
.pd-kepala,
.pd-kontak {
    background: #eff8f5;
    border: 1px solid #dcebe5;
    border-radius: 16px;
}

/* ----- Kepala dinas ----- */
.pd-kepala {
    display: flex;
    align-items: center;
    gap: 28px;
    margin-bottom: 36px;
    padding: 22px;
}

.pd-foto-kepala {
    width: 175px;
    height: 165px;
    flex-shrink: 0;
    object-fit: cover;
    object-position: top;
    border-radius: 14px;
    box-shadow: 0 0 0 1px var(--border), var(--shadow);
}

.pd-kepala-teks h2 {
    margin: 10px 0 6px;
    color: var(--brand-900);
    font-size: 26px;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.pd-kepala-teks strong {
    display: block;
    color: var(--brand-900);
    font-size: 15px;
    font-weight: 700;
}

/* ----- Struktur organisasi ----- */
.pd-struktur {
    margin-bottom: 36px;
}

.pd-struktur h2 {
    margin: 10px 0 6px;
    color: var(--brand-900);
    font-size: 26px;
    font-weight: 800;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.pd-struktur-ket {
    margin-bottom: 20px;
    color: var(--text-2);
    font-size: 14.5px;
    line-height: 1.7;
}

.pd-bidang-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.pd-bidang {
    padding: 22px 26px 24px;
}

.pd-bidang h3 {
    margin-bottom: 18px;
    padding-bottom: 12px;
    border-bottom: 1px solid #7bbfa5;
    color: var(--brand-800);
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
}

.pd-bidang strong {
    display: block;
    margin-bottom: 4px;
    color: var(--brand-950);
    font-size: 16px;
    font-weight: 700;
}

.pd-bidang span {
    display: block;
    color: var(--text-2);
    font-size: 14px;
}

.pd-bidang p {
    margin-top: 10px;
    color: var(--text-3);
    font-size: 13px;
    line-height: 1.7;
}

/* ----- Kontak ----- */
.pd-kontak {
    display: flex;
    align-items: stretch;
    padding: 22px 8px 22px 24px;
}

.pd-kontak-intro {
    flex: 0 0 26%;
    padding-right: 24px;
}

.pd-kontak-intro h2 {
    margin: 10px 0 8px;
    color: var(--brand-900);
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.pd-kontak-intro p {
    color: var(--text-2);
    font-size: 13.5px;
    line-height: 1.7;
}

.pd-kontak-item {
    display: flex;
    flex: 1 1 0;
    align-items: flex-start;
    gap: 12px;
    min-width: 0;
    padding: 4px 18px;
    border-left: 1px solid #c9ddd5;
}

.pd-kontak-ikon {
    display: flex;
    flex: 0 0 auto;
    padding-top: 2px;
    color: var(--brand-700);
}

.pd-kontak-item strong {
    display: block;
    margin-bottom: 4px;
    color: var(--brand-950);
    font-size: 14px;
    font-weight: 700;
}

.pd-kontak-item p {
    color: var(--text-2);
    font-size: 12.5px;
    line-height: 1.7;
    overflow-wrap: anywhere;
}

@media (max-width: 900px) {
    .pd-tentang {
        grid-template-columns: minmax(0, 1fr);
    }

    .pd-kontak {
        flex-wrap: wrap;
        gap: 18px;
        padding: 22px;
    }

    .pd-kontak-intro {
        flex: 1 1 100%;
        padding-right: 0;
    }

    .pd-kontak-item {
        flex: 1 1 calc(50% - 18px);
        padding: 4px 0 4px 16px;
    }
}

@media (max-width: 640px) {
    .pd-bidang-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .pd-kepala {
        flex-direction: column;
        align-items: flex-start;
        gap: 18px;
    }

    .pd-foto-kepala {
        width: 100%;
        max-width: 220px;
        height: 200px;
    }

    .pd-kontak-item {
        flex-basis: 100%;
    }

    .pd-tentang-teks h2,
    .pd-kepala-teks h2,
    .pd-struktur h2,
    .pd-kontak-intro h2 {
        font-size: 22px;
    }
}

/* ---------- INFORMASI BIDANG (6 bidang) ---------- */

/* Pilihan Informasi Dinas + bidang (halaman satu bidang) */
.pilihan-informasi {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 28px;
}

.pilihan-informasi .pilihan {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 0 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-2);
    font-size: 13.5px;
    font-weight: 600;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.pilihan-informasi .pilihan:hover {
    border-color: #bbf7d0;
    background: var(--brand-50);
    color: var(--brand-700);
}

.pilihan-informasi .pilihan.aktif {
    background: var(--brand-600);
    border-color: var(--brand-600);
    color: #fff;
}

/* ---------- HASIL PEMERIKSAAN BERKAS (halaman Lacak) ---------- */
.hasil-berkas-salah {
    margin-top: 14px;
    padding: 14px 16px;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 12px;
    color: #7f1d1d;
    font-size: 14px;
    line-height: 1.7;
}

.hasil-berkas-salah strong {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #b91c1c;
}

.hasil-berkas-salah ul {
    margin: 8px 0 8px 20px;
    padding: 0;
}

.hasil-berkas-salah li span {
    color: #991b1b;
}

.hasil-berkas-salah p {
    margin: 0;
    font-size: 13.5px;
}

.hasil-berkas-ok {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
    padding: 12px 16px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 12px;
    color: #166534;
    font-size: 14px;
}

/* Label asal informasi (Dinas / Bidang) pada kartu Informasi Dinas */
.informasi-card .tanggal {
    display: flex;
    flex-wrap: wrap;
}

.informasi-card .tanggal .label-sumber {
    margin-left: auto;
    padding: 2px 10px;
    border-radius: 999px;
    font-size: 11.5px;
    font-weight: 700;
    line-height: 1.6;
}

.informasi-card .tanggal .label-sumber.dinas {
    background: #e0f2fe;
    color: #075985;
}

.informasi-card .tanggal .label-sumber.bidang {
    background: var(--brand-100);
    color: var(--brand-700);
}

/* Keterangan jumlah foto / lampiran pada kartu informasi */
.informasi-card .info-tambahan {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 14px;
    margin: 0 0 14px;
    color: var(--brand-700);
    font-size: 12.5px;
    font-weight: 600;
}

.informasi-card .info-tambahan span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

/* ---------- PENCARIAN INFORMASI: TANGGAL / MINGGU / BULAN ---------- */

.btn-reset {
    color: var(--text-2);
    font-size: 13.5px;
    font-weight: 600;
    text-decoration: underline;
}

/* Label bidang penyelenggara pada kartu layanan publik */
.label-bidang-layanan {
    display: inline-block;
    margin: 0 0 10px;
    padding: 3px 10px;
    border-radius: 999px;
    background: #e8f3ec;
    color: #1f6b3a;
    font-size: 12px;
    font-weight: 600;
}

/* Tautan ke halaman Tutorial Penggunaan (di atas formulir) */
.bantuan-tutorial {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding: 14px 18px;
    background: var(--brand-50);
    border: 1px solid #bbf7d0;
    border-radius: 14px;
    color: var(--brand-800);
    font-size: 14.5px;
    line-height: 1.5;
    text-decoration: none;
    transition: background 0.2s, border-color 0.2s;
}

.bantuan-tutorial span {
    flex: 1;
}

.bantuan-tutorial:hover {
    background: var(--brand-100);
    border-color: var(--brand-400);
}

/* =====================================================================
   PENYEMPURNAAN TATA LETAK HALAMAN MASYARAKAT
   ===================================================================== */

/* Modal: tinggi mengikuti layar ponsel yang sebenarnya */

/* Formulir: font 16 px di ponsel agar iPhone tidak memperbesar layar saat mengetik */
@media (max-width: 768px) {
    input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
    select,
    textarea {
        font-size: 16px;
    }
}

/* Perangkat sentuh: kolom isian dan tombol nyaman diketuk */
@media (pointer: coarse) {
    input:not([type="checkbox"]):not([type="radio"]):not([type="file"]),
    select {
        min-height: 48px;
    }

    button,
    .btn-primary,
    .btn-secondary,
    [class*="btn-"] {
        min-height: 44px;
    }
}

/* Tablet (601 - 1024 px): jarak halaman dan kartu lebih proporsional */
@media (min-width: 601px) and (max-width: 1024px) {
    main,
.halaman {
        padding-left: 28px;
        padding-right: 28px;
    }
}

/* Tabel di halaman publik bergulir ke samping, bukan merusak tata letak */
table {
    max-width: 100%;
}

/* Layar pendek (ponsel landscape) */

/* Tablet dan ponsel: pilihan Informasi Dinas / Bidang dipindah ke menu garis tiga (navbar) */
@media (max-width: 1024px) {
    .pilihan-informasi {
        display: none;
    }
}

/* =====================================================================
   BERKAS PERSYARATAN YANG DAPAT DIKELOLA (keterangan dan penanda opsional)
   ===================================================================== */
.syarat-box li .syarat-ket,
.form-group .ket-berkas {
    display: block;
    margin-top: 2px;
    font-size: 13px;
    font-weight: 400;
    line-height: 1.5;
    color: #5b6b62;
}

.tag-opsional {
    display: inline-block;
    margin-left: 4px;
    font-size: 12.5px;
    font-style: normal;
    font-weight: 600;
    color: #6b7280;
}

/* ---------- LACAK: SURAT YANG SUDAH TERBIT (BBM dan NKV) ---------- */
.hasil-surat {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px 18px;
    margin-top: 14px;
    padding: 16px 18px;
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 14px;
}

.hasil-surat-info {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1 1 260px;
}

.hasil-surat-info strong {
    display: block;
    color: #14532d;
    font-size: 15px;
    line-height: 1.4;
}

.hasil-surat-info small {
    display: block;
    margin-top: 2px;
    color: #166534;
    font-size: 13px;
}

.hasil-surat-aksi {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.btn-surat {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid #16a34a;
    border-radius: 10px;
    background: #fff;
    color: #15803d;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    white-space: nowrap;
}

.btn-surat:hover {
    background: #dcfce7;
}

.btn-surat.utama {
    background: #16a34a;
    color: #fff;
}

.btn-surat.utama:hover {
    background: #15803d;
}

@media (max-width: 560px) {
    .hasil-surat-aksi {
        width: 100%;
    }

    .btn-surat {
        flex: 1 1 auto;
    }
}

/* ---------- LACAK: HASIL SELESAI + UCAPAN TERIMA KASIH ---------- */
.lacak-aksi {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px 16px;
    margin-bottom: 18px;
}

.lacak-aksi-teks {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text-2, #475569);
    font-size: 14px;
    word-break: break-all;
}

.lacak-aksi-teks strong {
    color: var(--text, #0f172a);
}

.btn-lacak-lagi {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 44px;
    padding: 0 18px;
    border: 1px solid #16a34a;
    border-radius: 12px;
    background: #fff;
    color: #15803d;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

.btn-lacak-lagi:hover {
    background: #f0fdf4;
    box-shadow: 0 6px 16px -8px rgba(21, 128, 61, 0.5);
}

.selesai-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0 0 22px;
    padding: 34px 24px 30px;
    border-radius: 18px;
    background:
        radial-gradient(circle at 12% 0%, rgba(74, 222, 128, 0.35), transparent 45%),
        radial-gradient(circle at 92% 100%, rgba(34, 197, 94, 0.28), transparent 50%),
        linear-gradient(145deg, #0f3323 0%, #14532d 55%, #166534 100%);
    color: #fff;
    text-align: center;
    box-shadow: 0 18px 40px -22px rgba(15, 51, 35, 0.8);
}

.selesai-ikon {
    position: relative;
    display: grid;
    place-items: center;
    width: 84px;
    height: 84px;
    margin-bottom: 16px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
}

.selesai-ikon::before {
    content: "";
    position: absolute;
    inset: -10px;
    border: 2px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    animation: selesai-denyut 2.4s ease-out infinite;
}

.selesai-ikon span {
    display: grid;
    place-items: center;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #fff;
    color: #16a34a;
    box-shadow: 0 8px 20px -6px rgba(0, 0, 0, 0.35);
    animation: selesai-muncul 0.55s cubic-bezier(0.2, 1.4, 0.4, 1) both;
}

.selesai-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    padding: 5px 14px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #bbf7d0;
    font-size: 12.5px;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.selesai-hero h2 {
    margin: 0 0 12px;
    max-width: 520px;
    color: #fff;
    font-size: clamp(20px, 3.4vw, 27px);
    font-weight: 800;
    line-height: 1.3;
}

.selesai-dinas {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 12px;
    padding: 7px 16px 7px 8px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.12);
    color: #f0fdf4;
    font-size: 14.5px;
    font-weight: 600;
}

.selesai-dinas img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    object-fit: contain;
}

.selesai-pesan {
    margin: 0;
    max-width: 460px;
    color: #bbf7d0;
    font-size: 14px;
    line-height: 1.6;
}

@keyframes selesai-muncul {
    from { transform: scale(0.4); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@keyframes selesai-denyut {
    0% { transform: scale(0.9); opacity: 0.9; }
    100% { transform: scale(1.35); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
    .selesai-ikon::before,
    .selesai-ikon span {
        animation: none;
    }
}

@media (max-width: 560px) {
    .selesai-hero {
        padding: 28px 16px 24px;
    }

    .lacak-aksi {
        flex-direction: column;
        align-items: stretch;
    }
}

/* ---------- KARTU BERHASIL DIKIRIM (BBM, NKV, Pengaduan) ---------- */
.berhasil-kirim {
    overflow: hidden;
    margin: 8px 0 32px;
    background: #fff;
    border: 1px solid #d1fae5;
    border-radius: 22px;
    box-shadow: 0 24px 50px -28px rgba(15, 51, 35, 0.55);
}

.berhasil-atas {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 38px 24px 32px;
    background:
        radial-gradient(circle at 10% 0%, rgba(74, 222, 128, 0.35), transparent 45%),
        radial-gradient(circle at 95% 100%, rgba(34, 197, 94, 0.28), transparent 50%),
        linear-gradient(145deg, #0f3323 0%, #14532d 55%, #166534 100%);
    color: #fff;
    text-align: center;
}

.berhasil-ikon {
    position: relative;
    display: grid;
    place-items: center;
    width: 92px;
    height: 92px;
    margin-bottom: 18px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.14);
}

.berhasil-ikon::before {
    content: "";
    position: absolute;
    inset: -11px;
    border: 2px solid rgba(255, 255, 255, 0.28);
    border-radius: 50%;
    animation: selesai-denyut 2.4s ease-out infinite;
}

.berhasil-ikon span {
    display: grid;
    place-items: center;
    width: 66px;
    height: 66px;
    border-radius: 50%;
    background: #fff;
    color: #16a34a;
    box-shadow: 0 10px 22px -6px rgba(0, 0, 0, 0.35);
    animation: selesai-muncul 0.55s cubic-bezier(0.2, 1.4, 0.4, 1) both;
}

.berhasil-atas h2 {
    margin: 0 0 6px;
    color: #fff;
    font-size: clamp(22px, 3.6vw, 29px);
    font-weight: 800;
    line-height: 1.25;
}

.berhasil-layanan {
    margin: 0 0 10px;
    color: #bbf7d0;
    font-size: 14.5px;
    font-weight: 600;
}

.berhasil-terima {
    margin: 0;
    max-width: 460px;
    color: #dcfce7;
    font-size: 14px;
    line-height: 1.6;
}

.berhasil-isi {
    padding: 28px 28px 26px;
}

/* Nomor pengajuan seperti tiket */
.tiket-nomor {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    margin: -56px 0 26px;
    padding: 20px 18px 16px;
    background: #fff;
    border: 2px dashed #86efac;
    border-radius: 16px;
    box-shadow: 0 14px 30px -20px rgba(21, 128, 61, 0.6);
    text-align: center;
}

.tiket-label {
    color: #64748b;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.tiket-kode {
    color: #14532d;
    font-family: "Consolas", "SFMono-Regular", "Courier New", monospace;
    font-size: clamp(20px, 4.4vw, 28px);
    font-weight: 800;
    letter-spacing: 0.04em;
    word-break: break-all;
}

.btn-salin {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    min-height: 38px;
    padding: 0 16px;
    border: 1px solid #16a34a;
    border-radius: 999px;
    background: #f0fdf4;
    color: #15803d;
    font-size: 13.5px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.btn-salin:hover {
    background: #dcfce7;
}

.btn-salin.tersalin {
    background: #16a34a;
    color: #fff;
}

.tiket-nomor small {
    color: #94a3b8;
    font-size: 12.5px;
}

.berhasil-judul-langkah {
    margin: 0 0 14px;
    color: #0f172a;
    font-size: 16px;
    font-weight: 800;
}

.berhasil-langkah {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0 0 26px;
    padding: 0;
    list-style: none;
}

.berhasil-langkah li {
    display: flex;
    align-items: flex-start;
    gap: 14px;
}

.langkah-no {
    flex: 0 0 auto;
    display: grid;
    place-items: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #dcfce7;
    color: #15803d;
    font-size: 14px;
    font-weight: 800;
}

.berhasil-langkah strong {
    display: block;
    color: #0f172a;
    font-size: 14.5px;
}

.berhasil-langkah p {
    margin: 2px 0 0;
    color: #64748b;
    font-size: 13.5px;
    line-height: 1.6;
}

.berhasil-aksi {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.btn-berhasil {
    flex: 1 1 200px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    min-height: 48px;
    padding: 0 20px;
    border: 1px solid #16a34a;
    border-radius: 12px;
    background: #fff;
    color: #15803d;
    font-size: 14.5px;
    font-weight: 700;
    text-decoration: none;
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

.btn-berhasil:hover {
    background: #f0fdf4;
}

.btn-berhasil.utama {
    background: #16a34a;
    color: #fff;
    box-shadow: 0 10px 22px -12px rgba(21, 128, 61, 0.9);
}

.btn-berhasil.utama:hover {
    background: #15803d;
}

.berhasil-baru {
    margin: 18px 0 0;
    text-align: center;
    font-size: 13.5px;
}

.berhasil-baru a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: #475569;
    text-decoration: none;
    border-bottom: 1px dotted #94a3b8;
}

.berhasil-baru a:hover {
    color: #15803d;
}

@media (prefers-reduced-motion: reduce) {
    .berhasil-ikon::before,
    .berhasil-ikon span {
        animation: none;
    }
}

@media (max-width: 560px) {
    .berhasil-atas {
        padding: 30px 16px 28px;
    }

    .berhasil-isi {
        padding: 22px 16px 22px;
    }
}
