/* Pustaka Dokumen Publik – WebGIS Mahalona Raya
   Scope: .pd-*; tidak mengubah navbar atau halaman publik lain. */

.pd-page {
    background: #f6f8f6;
    color: #172d24;
    min-height: 70vh;
    padding: 28px 20px 72px;
    font-family: 'Plus Jakarta Sans', system-ui, sans-serif;
}

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

.pd-container {
    width: min(1120px, 100%);
    margin-inline: auto;
}

.pd-breadcrumb {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
    color: #748379;
    font-size: 12px;
    margin-bottom: 28px;
}

.pd-breadcrumb a {
    color: #36664d;
    text-decoration: none;
}

.pd-breadcrumb a:hover {
    text-decoration: underline;
}

.pd-breadcrumb span[aria-current] {
    color: #395346;
    font-weight: 650;
}

.pd-page-head {
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(230px, .85fr);
    gap: 40px;
    align-items: end;
    margin-bottom: 27px;
}

.pd-overline {
    margin: 0 0 10px;
    text-transform: uppercase;
    letter-spacing: .13em;
    color: #29714a;
    font-weight: 800;
    font-size: 10px;
}

.pd-page-head h1 {
    font-size: clamp(28px, 3.5vw, 42px);
    line-height: 1.18;
    letter-spacing: -.04em;
    margin: 0 0 14px;
    color: #102c20;
    font-weight: 800;
}

.pd-lead {
    font-size: 14px;
    line-height: 1.75;
    color: #607268;
    max-width: 640px;
    margin: 0;
}

.pd-page-head-note {
    display: flex;
    gap: 12px;
    padding: 15px 16px;
    align-items: start;
    background: #ebf2ed;
    border: 1px solid #d8e5dc;
    border-radius: 10px;
}

.pd-note-icon {
    display: grid;
    place-items: center;
    width: 35px;
    height: 35px;
    flex: none;
    color: #205b3c;
}

.pd-note-icon svg {
    width: 24px;
    height: 24px;
}

.pd-page-head-note strong,
.pd-page-head-note span:not(.pd-note-icon) {
    display: block;
}

.pd-page-head-note strong {
    font-size: 12px;
    color: #214730;
    margin-bottom: 5px;
}

.pd-page-head-note div span {
    font-size: 11px;
    line-height: 1.6;
    color: #607568;
}

.pd-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 25px;
}

.pd-stat {
    padding: 16px 19px;
    background: white;
    border: 1px solid #e0e8e1;
    border-radius: 10px;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.pd-stat span {
    font-size: 11px;
    color: #637469;
    font-weight: 600;
}

.pd-stat strong {
    font-size: 24px;
    color: #163d2a;
    line-height: 1.3;
    font-weight: 800;
    font-variant-numeric: tabular-nums;
}

.pd-library {
    background: #fff;
    border: 1px solid #dfe7e1;
    border-radius: 12px;
    overflow: hidden;
}

.pd-library-head {
    padding: 23px 24px 18px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
}

.pd-library-head h2 {
    margin: 0 0 5px;
    color: #19382a;
    font-size: 19px;
    font-weight: 800;
    letter-spacing: -.02em;
}

.pd-library-head p {
    margin: 0;
    color: #708078;
    font-size: 12px;
    line-height: 1.65;
}

.pd-result-count {
    color: #3e644e;
    background: #edf5ef;
    border-radius: 7px;
    padding: 7px 10px;
    white-space: nowrap;
    font-size: 11px;
    font-weight: 700;
}

.pd-filter {
    background: #fafcfb;
    border-block: 1px solid #e8eee9;
    padding: 16px 24px;
    display: grid;
    grid-template-columns: minmax(220px, 1fr) minmax(130px, 180px) 112px auto auto;
    align-items: end;
    gap: 10px;
}

.pd-label {
    display: block;
    margin: 0 0 6px;
    font-size: 10px;
    color: #536a5a;
    font-weight: 700;
}

.pd-field {
    display: flex;
    align-items: center;
    position: relative;
}

.pd-field svg {
    width: 17px;
    height: 17px;
    position: absolute;
    left: 12px;
    pointer-events: none;
    color: #6a8272;
}

.pd-search,
.pd-select {
    min-width: 0;
}

.pd-field input,
.pd-select select {
    width: 100%;
    height: 42px;
    border: 1px solid #d7e1d8;
    border-radius: 8px;
    background: #fff;
    color: #23372b;
    font: inherit;
    font-size: 12px;
    outline: none;
}

.pd-field input {
    padding: 0 12px 0 39px;
}

.pd-select select {
    padding: 0 11px;
    cursor: pointer;
}

.pd-field input:focus,
.pd-select select:focus {
    border-color: #39865a;
    box-shadow: 0 0 0 3px rgba(39, 111, 68, .1);
}

.pd-submit,
.pd-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-decoration: none;
    font: inherit;
    font-size: 12px;
    font-weight: 750;
    border-radius: 8px;
    cursor: pointer;
    min-height: 42px;
    padding: 10px 15px;
    text-align: center;
}

.pd-submit,
.pd-btn-primary {
    color: #fff!important;
    background: #115638;
    border: 1px solid #115638;
}

.pd-submit:hover,
.pd-btn-primary:hover {
    background: #0a412a;
    border-color: #0a412a;
}

.pd-clear {
    color: #267047;
    font-size: 11px;
    font-weight: 700;
    text-decoration: none;
    padding: 12px 3px;
    white-space: nowrap;
}

.pd-clear:hover {
    text-decoration: underline;
}

.pd-documents {
    padding: 0 24px;
}

.pd-document {
    display: grid;
    grid-template-columns: 66px minmax(0, 1fr) 112px;
    gap: 18px;
    padding: 23px 0;
    border-bottom: 1px solid #e8ede8;
}

.pd-document:last-child {
    border-bottom: 0;
}

.pd-file-illustration {
    width: 64px;
    height: 74px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    flex: none;
    border: 1px solid #d8e6dc;
    border-radius: 9px;
    background: #f0f6f1;
    color: #236345;
}

.pd-file-illustration svg {
    width: 25px;
    height: 25px;
}

.pd-file-illustration span {
    font-size: 10px;
    font-weight: 800;
    letter-spacing: .03em;
    overflow-wrap: anywhere;
    padding: 0 4px;
    text-align: center;
}

.pd-document-body {
    min-width: 0;
}

.pd-document-flags {
    display: flex;
    gap: 7px;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 8px;
}

.pd-category,
.pd-featured {
    display: inline-block;
    padding: 4px 7px;
    border-radius: 5px;
    background: #eef4ef;
    color: #286143;
    font-size: 10px;
    font-weight: 750;
}

.pd-featured {
    background: #fbf4e7;
    color: #8b6122;
}

.pd-document h3 {
    font-size: 15px;
    color: #19392a;
    font-weight: 800;
    line-height: 1.5;
    margin: 0 0 8px;
    overflow-wrap: anywhere;
}

.pd-document-desc {
    color: #65766d;
    font-size: 11.5px;
    line-height: 1.65;
    margin: 0 0 10px;
}

.pd-meta {
    display: flex;
    flex-wrap: wrap;
    column-gap: 16px;
    row-gap: 7px;
    padding: 0;
    margin: 0;
}

.pd-meta div {
    display: flex;
    align-items: baseline;
    gap: 5px;
    min-width: 0;
}

.pd-meta dt,
.pd-meta dd {
    font-size: 10.5px;
    margin: 0;
    line-height: 1.5;
}

.pd-meta dt {
    color: #829188;
}

.pd-meta dd {
    color: #3f5848;
    font-weight: 650;
    overflow-wrap: anywhere;
}

.pd-source {
    margin: 9px 0 0;
    color: #89968c;
    font-size: 10px;
    overflow-wrap: anywhere;
}

.pd-document-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    align-self: center;
    gap: 8px;
}

.pd-btn {
    min-height: 37px;
    padding: 9px 10px;
    font-size: 11px;
}

.pd-btn svg {
    width: 16px;
    height: 16px;
    flex: none;
}

.pd-btn-outline {
    border: 1px solid #ccdbd0;
    color: #24583a!important;
    background: #fff;
}

.pd-btn-outline:hover {
    background: #f2f7f3;
}

.pd-unavailable {
    font-size: 10px;
    color: #8b6554;
    line-height: 1.6;
    background: #fff6ee;
    padding: 10px;
    border-radius: 7px;
    text-align: center;
}

.pd-empty {
    display: flex;
    align-items: center;
    flex-direction: column;
    text-align: center;
    padding: 55px 16px;
}

.pd-empty svg {
    width: 42px;
    height: 42px;
    color: #7e9e86;
    margin-bottom: 12px;
}

.pd-empty h3 {
    margin: 0 0 8px;
    font-size: 17px;
    color: #314b3a;
}

.pd-empty p {
    margin: 0 0 18px;
    color: #687b6f;
    font-size: 12px;
    line-height: 1.7;
    max-width: 390px;
}

.pd-pagination {
    border-top: 1px solid #e7eee8;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 15px 24px;
    color: #64756a;
    font-size: 11px;
}

.pd-pagination div {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pd-pagination a {
    color: #24583d;
    border: 1px solid #d1e1d6;
    border-radius: 7px;
    text-decoration: none;
    padding: 9px 12px;
    font-weight: 700;
}

.pd-pagination a:hover {
    background: #f1f7f2;
}

.pd-disclaimer {
    color: #809087;
    font-size: 10.5px;
    line-height: 1.7;
    padding: 16px 0 0;
    margin: 0;
}

.pd-page a:focus-visible,
.pd-page button:focus-visible {
    outline: 3px solid #6bb48b;
    outline-offset: 2px;
}

@media(max-width:1080px) {
    .pd-filter {
        grid-template-columns: minmax(220px, 1fr) minmax(140px, .5fr) 120px auto;
    }
    .pd-clear {
        grid-column: 1/-1;
        justify-self: end;
        padding: 0;
    }
}

@media(max-width:800px) {
    .pd-page-head {
        grid-template-columns: 1fr;
        gap: 18px;
    }
    .pd-page-head-note {
        width: min(470px, 100%);
    }
    .pd-filter {
        grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    }
    .pd-search {
        grid-column: 1/-1;
    }
    .pd-submit {
        min-width: 130px;
    }
    .pd-clear {
        grid-column: auto;
        justify-self: start;
        align-self: center;
    }
}

@media(max-width:580px) {
    .pd-page {
        padding: 20px 14px 50px;
    }
    .pd-breadcrumb {
        margin-bottom: 23px;
    }
    .pd-page-head {
        gap: 16px;
        margin-bottom: 19px;
    }
    .pd-page-head h1 {
        font-size: 30px;
    }
    .pd-lead {
        font-size: 12.5px;
    }
    .pd-stats {
        gap: 7px;
        margin-bottom: 16px;
    }
    .pd-stat {
        padding: 13px 11px;
    }
    .pd-stat span {
        font-size: 10px;
        line-height: 1.4;
    }
    .pd-stat strong {
        font-size: 19px;
    }
    .pd-library-head {
        padding: 19px 15px 15px;
        align-items: start;
        flex-direction: column;
        gap: 10px;
    }
    .pd-library-head h2 {
        font-size: 18px;
    }
    .pd-filter {
        padding: 14px 15px;
        gap: 10px;
    }
    .pd-documents {
        padding: 0 15px;
    }
    .pd-document {
        grid-template-columns: 53px minmax(0, 1fr);
        gap: 11px;
        padding: 18px 0;
    }
    .pd-file-illustration {
        width: 50px;
        height: 60px;
    }
    .pd-file-illustration svg {
        width: 20px;
        height: 20px;
    }
    .pd-file-illustration span {
        font-size: 9px;
    }
    .pd-document h3 {
        font-size: 13.5px;
    }
    .pd-document-actions {
        grid-column: 2;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: start;
    }
    .pd-document-actions .pd-btn {
        flex: 0 1 auto;
        min-width: 96px;
    }
    .pd-meta {
        gap: 5px 12px;
    }
    .pd-pagination {
        padding: 14px 15px;
    }
}

@media(max-width:350px) {
    .pd-page {
        padding-inline: 10px;
    }
    .pd-page-head-note {
        padding: 12px;
    }
    .pd-stats {
        gap: 5px;
    }
    .pd-stat {
        padding: 12px 8px;
    }
    .pd-filter {
        grid-template-columns: 1fr;
    }
    .pd-search {
        grid-column: auto;
    }
    .pd-clear {
        grid-column: auto;
    }
    .pd-document-actions .pd-btn {
        min-width: 90px;
    }
}

@media(prefers-reduced-motion:reduce) {
    .pd-page *,
    .pd-page *::before,
    .pd-page *::after {
        scroll-behavior: auto!important;
        transition: none!important;
    }
}