/* =========================================================
   SIDARSA — CEK DPT (Desa Sarwodadi)
   Tema global: Dominasi Biru Telur Asin | Mobile first
   File: assets/css/cek-dpt.css
   ========================================================= */

:root {
    --dpt-orange: #0d9488;
    --dpt-orange-dark: #0f766e;
    --dpt-orange-soft: #f0fdfd;
    --dpt-green: #0284c7;
    --dpt-green-dark: #0369a1;
    --dpt-green-soft: #e0f2fe;
    --dpt-ink: #0f172a;
    --dpt-muted: #64748b;
    --dpt-border: #ccfbf1;
    --dpt-surface: #ffffff;
    --dpt-page: #f4fbfb;
    --dpt-shadow: 0 12px 34px rgba(13, 148, 136, .08);
}

.dpt-page {
    flex: 1 0 auto;
    width: 100%;
    padding: 24px 0 48px;
    color: var(--dpt-ink);
    background:
        radial-gradient(circle at 10% 3%, rgba(13, 148, 136, .07), transparent 25rem),
        radial-gradient(circle at 95% 30%, rgba(2, 132, 199, .07), transparent 24rem),
        var(--dpt-page);
}
.dpt-page-container { width: 100%; }
.dpt-wrapper {
    position: relative;
    width: 100%;
    max-width: 590px;
    margin: 14px auto 24px;
    padding: 0 10px;
}
.dpt-card {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    padding: 34px 34px 28px;
    background: rgba(255,255,255,.96);
    border: 1px solid rgba(255,255,255,.9);
    border-radius: 26px;
    box-shadow: var(--dpt-shadow);
}
.dpt-card-decoration {
    position: absolute;
    z-index: -1;
    top: -115px;
    right: -90px;
    width: 260px;
    height: 210px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(13, 148, 136, .22), rgba(56, 189, 248, .18));
    pointer-events: none;
}
.dpt-brand-mark {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 76px;
    height: 76px;
    margin: 0 auto 10px;
    border-radius: 23px;
    background: linear-gradient(145deg, #f0fdfd, #e0f2fe);
    border: 1px solid #ccfbf1;
    box-shadow: inset 0 1px 0 #fff;
}
.dpt-logo { display: block; width: 58px; height: 58px; object-fit: contain; }
.dpt-branding { text-align: center; margin-bottom: 25px; }
.dpt-brand-title {
    margin: 0;
    color: var(--dpt-ink);
    font-size: 1.85rem;
    font-weight: 900;
    line-height: 1.1;
    letter-spacing: -.7px;
}
.brand-orange { color: var(--dpt-orange); }
.brand-green { color: var(--dpt-green); }
.dpt-brand-sub {
    margin: 7px 0 0;
    color: var(--dpt-muted);
    font-size: .84rem;
    font-weight: 550;
    line-height: 1.5;
}
.dpt-intro {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 25px;
    padding: 15px;
    text-align: left;
    border: 1px solid #99f6e4;
    border-radius: 16px;
    background: linear-gradient(110deg, #f0fdfd, #e0f2fe);
}
.dpt-intro-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 43px;
    width: 43px;
    height: 43px;
    color: var(--dpt-orange);
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 3px 10px rgba(13, 148, 136, .08);
    font-size: 1.15rem;
}
.dpt-intro h2 {
    margin: 0 0 3px;
    color: var(--dpt-green-dark);
    font-size: .98rem;
    font-weight: 850;
    line-height: 1.3;
}
.dpt-intro p {
    margin: 0;
    color: #475569;
    font-size: .77rem;
    line-height: 1.45;
}
.dpt-form-group { margin: 0 0 18px; text-align: left; }
.dpt-label {
    display: block;
    margin: 0 0 8px;
    color: #334155;
    font-size: .83rem;
    font-weight: 800;
}
.input-icon-wrapper { position: relative; width: 100%; }
.input-icon {
    position: absolute;
    top: 50%;
    left: 15px;
    z-index: 1;
    transform: translateY(-50%);
    color: #94a3b8;
    font-size: 1rem;
    pointer-events: none;
}
.dpt-input {
    display: block;
    width: 100%;
    height: 52px;
    box-sizing: border-box;
    padding: 12px 14px 12px 44px;
    color: var(--dpt-ink);
    background: #f0fdfd;
    border: 1px solid #99f6e4;
    border-radius: 13px;
    outline: none;
    font-size: .92rem;
    font-weight: 650;
    letter-spacing: .3px;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.dpt-input::placeholder { color: #94a3b8; font-weight: 450; letter-spacing: 0; }
.dpt-input:hover { border-color: #5eead4; }
.dpt-input:focus {
    background: #fff;
    border-color: var(--dpt-orange);
    box-shadow: 0 0 0 4px rgba(13, 148, 136, .15);
}
.dpt-input:invalid:not(:placeholder-shown) { border-color: #fca5a5; }
.dpt-input-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-top: 7px;
    color: #64748b;
    font-size: .7rem;
}
#nikCounter { color: var(--dpt-orange); font-weight: 800; font-variant-numeric: tabular-nums; }
.turnstile-box {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 70px;
    margin: 18px 0 20px;
    overflow: hidden;
}
.dpt-btn-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    width: 100%;
    min-height: 51px;
    padding: 13px 18px;
    color: #fff !important;
    text-align: center;
    text-decoration: none !important;
    background: linear-gradient(100deg, var(--dpt-orange), #06b6d4 52%, var(--dpt-green));
    border: 0;
    border-radius: 13px;
    box-shadow: 0 7px 16px rgba(13, 148, 136, .2);
    font-size: .94rem;
    font-weight: 850;
    letter-spacing: .1px;
    cursor: pointer;
    transition: transform .2s ease, box-shadow .2s ease, filter .2s ease;
}
.dpt-btn-submit:hover {
    color: #fff !important;
    filter: saturate(1.08);
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(13, 148, 136, .25);
}
.dpt-btn-submit:active { transform: translateY(0); }
.dpt-btn-submit:disabled { opacity: .68; cursor: wait; transform: none; box-shadow: none; }
.dpt-btn-submit.is-loading i { animation: dpt-spin 1s linear infinite; }
.dpt-privacy-note {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    gap: 6px;
    margin: 15px 0 0;
    color: #64748b;
    font-size: .69rem;
    line-height: 1.45;
}
.dpt-privacy-note i { margin-top: 2px; color: var(--dpt-orange); }

.dpt-help-card {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-top: 14px;
    padding: 17px 18px;
    background: #fff;
    border: 1px solid var(--dpt-border);
    border-radius: 17px;
    box-shadow: 0 5px 16px rgba(13, 148, 136, .04);
}
.dpt-help-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 35px;
    width: 35px;
    height: 35px;
    color: var(--dpt-orange);
    background: var(--dpt-orange-soft);
    border-radius: 11px;
    font-size: 1rem;
}
.dpt-help-card h2 { margin: 0 0 4px; color: var(--dpt-ink); font-size: .85rem; font-weight: 850; }
.dpt-help-card p { margin: 0; color: var(--dpt-muted); font-size: .76rem; line-height: 1.55; }

/* Modal hasil */
.dpt-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 10050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 18px;
    overflow-y: auto;
    background: rgba(15, 23, 42, .55);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}
.dpt-modal-box {
    position: relative;
    width: 100%;
    max-width: 490px;
    max-height: min(90vh, 850px);
    overflow-y: auto;
    box-sizing: border-box;
    padding: 30px 26px 24px;
    color: var(--dpt-ink);
    text-align: center;
    background: #fff;
    border: 1px solid rgba(255,255,255,.8);
    border-radius: 24px;
    box-shadow: 0 24px 70px rgba(0,0,0,.22);
    animation: dpt-modal-in .22s ease-out;
}
.dpt-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: #64748b;
    background: #f1f5f9;
    border: 0;
    border-radius: 50%;
    font-size: 1rem;
    cursor: pointer;
}
.dpt-modal-close:hover { color: var(--dpt-orange); background: var(--dpt-orange-soft); }
.status-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    margin: 0 auto 15px;
    border-radius: 20px;
    font-size: 1.65rem;
}
.icon-success { color: var(--dpt-orange); background: var(--dpt-orange-soft); }
.icon-danger { color: #e11d48; background: #fff1f2; }
.dpt-modal-title { margin: 0 0 6px; color: var(--dpt-ink); font-size: 1.15rem; font-weight: 900; line-height: 1.3; }
.dpt-modal-description { margin: 0 0 17px; color: var(--dpt-muted); font-size: .82rem; line-height: 1.55; overflow-wrap: anywhere; }
.dpt-check-time { margin: -7px 0 15px; color: #94a3b8; font-size: .7rem; }
.pemilih-info-card {
    display: flex;
    align-items: flex-start;
    gap: 13px;
    margin: 17px 0;
    padding: 15px;
    text-align: left;
    background: #f0fdfd;
    border: 1px solid #ccfbf1;
    border-radius: 16px;
}
.avatar-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 46px;
    width: 46px;
    height: 46px;
    color: var(--dpt-orange);
    background: linear-gradient(145deg, #f0fdfd, #e0f2fe);
    border-radius: 14px;
    font-size: 1.2rem;
}
.pemilih-info-content { min-width: 0; flex: 1; }
.pemilih-name { margin: 0 0 8px; color: var(--dpt-ink); font-size: .94rem; font-weight: 900; line-height: 1.35; overflow-wrap: anywhere; }
.table-info { width: 100%; border-collapse: collapse; font-size: .75rem; table-layout: fixed; }
.table-info td { padding: 4px 0; vertical-align: top; overflow-wrap: anywhere; }
.table-info .lbl { width: 90px; color: #64748b; }
.table-info .sep { width: 12px; color: #94a3b8; }
.table-info .val { color: #1e293b; font-weight: 700; }
.table-info .val-highlight { color: var(--dpt-orange); }
.table-info .val-muted { color: #64748b; font-size: .68rem; font-weight: 550; }
.alert-custom {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 15px 0;
    padding: 11px 13px;
    border-radius: 12px;
    font-size: .78rem;
    line-height: 1.45;
}
.alert-success-custom { color: #0f766e; background: #f0fdfd; border: 1px solid #99f6e4; }
.alert-danger-custom { color: #be123c; background: #fff1f2; border: 1px solid #fecdd3; }
.btn-close-custom {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 45px;
    padding: 11px 15px;
    color: #475569;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    font-size: .86rem;
    font-weight: 800;
    cursor: pointer;
    transition: background .2s ease, color .2s ease;
}
.btn-close-custom:hover { color: var(--dpt-green-dark); background: #e0f2fe; }
.dpt-report-button { margin-top: 15px; }
.dpt-secondary-action { margin-top: 9px; }
body.dpt-modal-open { overflow: hidden; }

@keyframes dpt-spin { to { transform: rotate(360deg); } }
@keyframes dpt-modal-in {
    from { opacity: 0; transform: translateY(8px) scale(.985); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

/* Tablet */
@media (max-width: 768px) {
    .dpt-page { padding: 15px 0 28px; }
    .dpt-wrapper { max-width: 540px; margin: 5px auto 18px; padding: 0 4px; }
    .dpt-card { padding: 27px 25px 23px; border-radius: 22px; }
    .dpt-help-card { padding: 14px; }
}

/* Mobile */
@media (max-width: 480px) {
    .dpt-page { padding: 10px 0 22px; }
    .dpt-page-container { padding-left: 12px !important; padding-right: 12px !important; }
    .dpt-wrapper { margin: 4px auto 14px; padding: 0; }
    .dpt-card { padding: 23px 18px 20px; border-radius: 20px; }
    .dpt-brand-mark { width: 64px; height: 64px; border-radius: 19px; margin-bottom: 9px; }
    .dpt-logo { width: 49px; height: 49px; }
    .dpt-brand-title { font-size: 1.65rem; }
    .dpt-brand-sub { font-size: .75rem; margin-top: 5px; }
    .dpt-branding { margin-bottom: 20px; }
    .dpt-intro { gap: 10px; padding: 12px; margin-bottom: 21px; border-radius: 14px; }
    .dpt-intro-icon { flex-basis: 38px; width: 38px; height: 38px; font-size: 1rem; border-radius: 12px; }
    .dpt-intro h2 { font-size: .88rem; }
    .dpt-intro p { font-size: .71rem; }
    .dpt-label { font-size: .78rem; }
    .dpt-input { height: 49px; font-size: .86rem; }
    .turnstile-box { margin: 14px 0 17px; }
    .dpt-btn-submit { min-height: 48px; font-size: .87rem; }
    .dpt-help-card { gap: 10px; border-radius: 15px; }
    .dpt-help-card h2 { font-size: .81rem; }
    .dpt-help-card p { font-size: .71rem; }
    .dpt-modal-overlay { padding: 12px; }
    .dpt-modal-box { padding: 28px 17px 18px; border-radius: 20px; }
    .dpt-modal-title { font-size: 1.03rem; }
    .pemilih-info-card { gap: 10px; padding: 11px; }
    .avatar-placeholder { flex-basis: 38px; width: 38px; height: 38px; border-radius: 12px; font-size: 1rem; }
    .table-info { font-size: .69rem; }
    .table-info .lbl { width: 78px; }
    .table-info .sep { width: 10px; }
}
@media (max-width: 350px) {
    .dpt-card { padding: 20px 13px 18px; }
    .dpt-intro { align-items: flex-start; }
    .dpt-intro-icon { flex-basis: 33px; width: 33px; height: 33px; }
    .dpt-input-meta { font-size: .64rem; }
    .table-info { font-size: .65rem; }
    .table-info .lbl { width: 68px; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        scroll-behavior: auto !important;
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}