.chart-area {
    position: relative;
    min-height: 275px;
}

.chart-area canvas {
    position: relative;
    z-index: 1;
    display: block;
}

/* Tombol 'Kembali' di tengah donut */
.chart-back-btn {
    font-size: .8rem;
    padding: .2rem .5rem;
    position: absolute;
    left: 50%;
    top: calc(50% + 8px);
    transform: translate(-50%, -50%);
    z-index: 3;
    box-shadow: 0 2px 8px rgba(0, 0, 0, .2);
    opacity: .95;
    display: none;
}

.chart-back-btn.is-visible {
    display: inline-block;
}

#mapTungro {
    height: 420px;
    border-radius: .5rem;
}

#wrapper #content-wrapper {
    background-color: #ffffff;
}

.global-filter .form-select {
    min-width: 140px;
}

.title-header {
    color: #000000;
}

.card-header-text {
    color: #ffffff;
}

.card {
    --bs-card-cap-bg: #6CD756;
}

:root {
    --bs-primary: #4AB83F;
    --bs-primary-rgb: 74, 184, 63;

    --bs-success: #6CD756;
    --bs-success-rgb: 108, 215, 86;

    --bs-danger: #FE6555;
    --bs-danger-rgb: 254, 101, 85;

    --bs-warning: #FCDA00;
    --bs-warning-rgb: 252, 218, 0;
}

.legend {
    background: #fff;
    padding: .5rem .75rem;
    line-height: 1.1;
    border-radius: .5rem;
    box-shadow: 0 1px 6px rgba(0, 0, 0, .1);
}

.legend i {
    width: 16px;
    height: 10px;
    float: left;
    margin-right: .5rem;
    opacity: 0.8;
}

.gauge-wrap {
    position: relative;
    height: 75px;
    display: flex;
    flex-direction: row;
}

.gauge-inner {
    max-width: 300px;
}

#gauge,
#apiGauge {
    display: block;
}

.gauge-label {
    position: absolute;
    left: 50%;
    top: 60%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 2;
}

.gauge-title {
    position: absolute;
    top: 10%;
    left: 50%;
    text-align: center;
    transform: translate(-50%, -50%);
    font-size: 1.05rem;
    font-weight: bold;
    margin-bottom: .15rem;
}

.gauge-percent {
    font-weight: 700;
    font-size: 1.95rem;
    line-height: 1;
}

.welcome-chat {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    margin: 8px 0 14px 0;
}

.welcome-avatar {
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 34px;
    flex: 0 0 56px;
    overflow: hidden;
}

.welcome-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.welcome-bubble {
    background: #ffffff;
    color: #666;
    border: 1px solid #eef2ee;
    padding: 14px 16px;
    border-radius: 16px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, .06);
    font-size: 1.05rem;
    line-height: 1.35;
}

.info-modal .welcome-cursor {
    display: inline-block;
    width: 2px;
    height: 1.05em;
    margin-left: 2px;
    background: #888;
    animation: blink 1s steps(2, start) infinite;
    vertical-align: -2px;
}

@keyframes blink {
    50% {
        background: transparent;
    }
}

.pie-level-badge {
    position: absolute;
    top: -10%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    background: #ffffff;
    padding: 4px 10px;
    border-radius: 999px;
    font-size: 1.05rem;
    font-weight: bold;
    color: #555;
    pointer-events: none;
    /* supaya tidak menghalangi klik chart */
}

/* [BARU] CSS untuk Login & Register Modal */
.auth-modal .modal-content {
    border: none;
    border-radius: 10px;
    padding: 1rem;
}

.auth-modal .modal-header {
    border-bottom: none;
}

.auth-modal .modal-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: #333;
}

.auth-modal .btn-close {
    position: absolute;
    right: 30px;
    top: 30px;
    z-index: 10;
}

.auth-modal .form-group {
    position: relative;
    margin-bottom: 1.2rem;
}

.auth-modal .form-label {
    font-weight: 600;
    color: #555;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
}

.auth-modal .form-control {
    border-radius: 8px;
    border: 1px solid #ddd;
    padding: 0.5rem 0.7rem;
    height: auto;
}

.auth-modal .form-control:focus {
    box-shadow: 0 0 0 2px var(--bs-primary-rgb, 0, 123, 255);
    border-color: var(--bs-primary, --bs-success);
}


.auth-modal .form-control-icon-right {
    position: absolute;
    right: 1rem;
    top: 70%;
    transform: translateY(-50%);
    color: #aaa;
    cursor: pointer;
}

.auth-modal .form-control-with-icon-left {
    padding-left: 3rem;
}

.auth-modal .btn-login {
    background-color: var(--bs-success);
    /* Biru dari gambar */
    border: none;
    border-radius: 8px;
    padding: 0.85rem;
    font-weight: 600;
    font-size: 1.1rem;
    width: 100%;
}

.auth-modal .forgot-password {
    text-align: right;
    margin-top: -1rem;
    margin-bottom: 1.5rem;
}

.auth-modal .forgot-password a {
    font-size: 0.9rem;
    color: var(--bs-primary);
    text-decoration: none;
}

.auth-modal .signup-link {
    text-align: center;
    margin-top: 2rem;
    color: #aaa;
}

.auth-modal .signup-link a {
    font-weight: 600;
    color: var(--bs-success);
    text-decoration: none;
}

/* [BARU] CSS untuk Modal Kurasi */
#curationModal .table-responsive {
    max-height: 400px;
    /* Batasi tinggi tabel */
}

#curationModal .table th,
#curationModal .table td {
    vertical-align: middle;
    font-size: 0.9rem;
}

#curationModal .form-check-input {
    width: 1.2em;
    height: 1.2em;
}
