/* Add here all your CSS customizations */

/* --- Styles extracted from login.php --- */

/* ─── RESET & BASE ─────────────────────────────────────────────── */
body.login-body *, body.login-body *::before, body.login-body *::after { box-sizing: border-box; }

:root {
    --primary:       #1a56db;
    --primary-dark:  #1246bd;
    --primary-light: #3b82f6;
    --accent:        #06b6d4;
    --gold:          #f59e0b;
    --bg-dark:       #0a0f1e;
    --glass-bg:      rgba(255,255,255,0.06);
    --glass-border:  rgba(255,255,255,0.12);
    --text-light:    rgba(255,255,255,0.90);
    --text-muted:    rgba(255,255,255,0.50);
    --input-bg:      rgba(255,255,255,0.08);
    --input-border:  rgba(255,255,255,0.15);
    --input-focus:   rgba(59,130,246,0.50);
    --error-bg:      rgba(239,68,68,0.15);
    --error-border:  rgba(239,68,68,0.40);
    --radius:        14px;
    --radius-sm:     8px;
    --shadow-card:   0 32px 80px rgba(0,0,0,0.60), 0 0 0 1px rgba(255,255,255,0.06);
    --transition:    all 0.25s cubic-bezier(0.4,0,0.2,1);
}

body.login-body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    font-family: 'Inter', 'Plus Jakarta Sans', sans-serif;
    background: var(--bg-dark);
    color: var(--text-light);
    overflow-x: hidden;
}

/* ─── ANIMATED BACKGROUND ──────────────────────────────────────── */
.bg-scene {
    position: fixed; inset: 0; z-index: 0;
    overflow: hidden;
}

.bg-image {
    position: absolute; inset: 0;
    background: url('../img/bg.png') no-repeat center center;
    background-size: cover;
    filter: brightness(0.96);
}

.bg-gradient {
    position: absolute; inset: 0;
    background:
        radial-gradient(ellipse 65% 55% at 5% 90%, rgba(245,120,15,0.32) 0%, transparent 65%),
        radial-gradient(ellipse 60% 60% at 92% 12%, rgba(0,166,244,0.38) 0%, transparent 65%),
        radial-gradient(ellipse 75% 65% at 50% 50%, rgba(10,25,65,0.40) 0%, transparent 75%);
}

/* Floating orbs */
.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(85px);
    opacity: 0.50;
    animation: drift 14s ease-in-out infinite alternate;
}
.orb-1 { width: 520px; height: 520px; top: -80px; right: -60px; left: auto; background: radial-gradient(circle, #00a6f4, transparent 70%); animation-duration: 16s; }
.orb-2 { width: 480px; height: 480px; bottom: -60px; left: -60px; right: auto; background: radial-gradient(circle, #ff8f00, transparent 70%); animation-duration: 12s; animation-delay: -4s; }
.orb-3 { width: 360px; height: 360px; top: 35%; right: 10%; left: auto; background: radial-gradient(circle, #0c64c0, transparent 70%); animation-duration: 18s; animation-delay: -2s; }
.orb-4 { width: 320px; height: 320px; top: 60%; left: 10%; background: radial-gradient(circle, #ff6d00, transparent 70%); animation-duration: 20s; animation-delay: -6s; }

@keyframes drift {
    from { transform: translate(0,0) scale(1); }
    to   { transform: translate(40px, 30px) scale(1.08); }
}

/* Stars */
#stars { position: absolute; inset: 0; }
.star-dot {
    position: absolute;
    width: 2px; height: 2px;
    background: white;
    border-radius: 50%;
    animation: sparkle var(--dur, 3s) ease-in-out infinite;
    animation-delay: var(--delay, 0s);
}
@keyframes sparkle {
    0%, 100% { opacity: 0.1; transform: scale(1); }
    50%       { opacity: 0.9; transform: scale(1.6); }
}

/* Mesh grid lines */
.grid-lines {
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    mask-image: radial-gradient(ellipse 70% 70% at 50% 50%, black 40%, transparent 100%);
}

/* ─── LAYOUT ────────────────────────────────────────────────────── */
.login-page {
    position: relative; z-index: 1;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

/* ─── CARD ──────────────────────────────────────────────────────── */
.login-card {
    width: 100%;
    max-width: 420px;
    min-width: 340px;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
    padding: 40px 32px 40px;
    animation: slideUp 0.5s cubic-bezier(0.16,1,0.3,1) both;
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0,0,0,0.05), transparent);
}

/* Shine sweep on card */
.login-card::after {
    content: '';
    position: absolute;
    top: -50%; left: -60%;
    width: 40%; height: 200%;
    background: linear-gradient(105deg, transparent, rgba(0,0,0,0.01), transparent);
    transform: skewX(-20deg);
    animation: cardShine 8s ease-in-out infinite;
    pointer-events: none;
}
@keyframes cardShine {
    0%, 100% { left: -60%; }
    50%       { left: 120%; }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(32px) scale(0.97); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* ─── LOGO & HEADER ─────────────────────────────────────────────── */
.login-brand {
    text-align: center;
    margin-bottom: 24px;
}

.logo-ring {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 90px; height: 90px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(0,166,244,0.18), rgba(255,140,0,0.14));
    border: 1px solid rgba(0,166,244,0.30);
    box-shadow: 0 0 35px rgba(0,166,244,0.25), 0 0 15px rgba(255,140,0,0.12) inset;
    margin-bottom: 16px;
    position: relative;
}

.logo-ring::before {
    content: '';
    position: absolute; inset: -3px;
    border-radius: 50%;
    border: 1px solid transparent;
    background: linear-gradient(135deg, rgba(0,166,244,0.7), rgba(255,140,0,0.6), transparent) border-box;
    mask: linear-gradient(#fff 0 0) padding-box, linear-gradient(#fff 0 0);
    mask-composite: subtract;
    animation: rotateBorder 6s linear infinite;
}
@keyframes rotateBorder {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

.logo-ring img {
    width: 58px; height: 58px;
    object-fit: contain;
    border-radius: 8px;
    filter: drop-shadow(0 2px 10px rgba(0,166,244,0.4));
}

.login-brand h1 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 4px;
}

.login-brand .subtitle {
    font-size: 0.78rem;
    color: #64748b;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.subtitle-dot {
    width: 4px; height: 4px;
    border-radius: 50%;
    background: var(--accent);
    display: inline-block;
    animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
    0%, 100% { opacity: 0.4; transform: scale(1); }
    50%       { opacity: 1;   transform: scale(1.5); }
}

/* ─── ALERT ERROR ───────────────────────────────────────────────── */
.alert-error {
    background: var(--error-bg);
    border: 1px solid var(--error-border);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    margin-bottom: 20px;
    font-size: 0.82rem;
    color: #fca5a5;
    display: flex;
    align-items: center;
    gap: 8px;
    animation: shakeX 0.4s ease-in-out;
}
@keyframes shakeX {
    0%, 100% { transform: translateX(0); }
    20%, 60%  { transform: translateX(-6px); }
    40%, 80%  { transform: translateX(6px); }
}

/* ─── FORM ELEMENTS ─────────────────────────────────────────────── */
.field-group { margin-bottom: 18px; }

.field-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    margin-bottom: 8px;
}
.field-label i { font-size: 0.85rem; color: #3b82f6; }

.field-input {
    width: 100%;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: var(--radius-sm);
    padding: 12px 16px;
    font-size: 0.9rem;
    font-family: inherit;
    color: #0f172a;
    transition: var(--transition);
    outline: none;
    -webkit-appearance: none;
}
.field-input::placeholder { color: #94a3b8; }
.field-input:focus {
    background: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59,130,246,0.15);
}

/* Password wrapper */
.pw-wrap {
    position: relative;
    display: flex;
    align-items: center;
}
.pw-wrap .field-input { padding-right: 46px; }
.pw-toggle {
    position: absolute; right: 12px;
    background: none; border: none;
    color: #94a3b8;
    cursor: pointer; padding: 4px;
    font-size: 1rem;
    transition: color 0.2s;
}
.pw-toggle:hover { color: #475569; }

/* Captcha field */
.captcha-row {
    display: flex;
    gap: 10px;
    align-items: stretch;
}
.captcha-badge {
    flex-shrink: 0;
    min-width: 120px;
    background: #f1f5f9;
    border: 1px solid #cbd5e1;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 2px;
    color: #0ea5e9;
    font-family: 'Plus Jakarta Sans', monospace;
    user-select: none;
}
.captcha-row .field-input { flex: 1; }

/* Remove number input arrows */
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button { -webkit-appearance: none; }
input[type=number] { -moz-appearance: textfield; }

.field-hint {
    font-size: 0.72rem;
    color: #64748b;
    margin-top: 5px;
    padding-left: 2px;
}

/* ─── SUBMIT BUTTON ─────────────────────────────────────────────── */
.btn-signin {
    width: 100%;
    padding: 13px 24px;
    border: none; border-radius: var(--radius-sm);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.95rem;
    font-weight: 700;
    letter-spacing: 0.3px;
    cursor: pointer;
    position: relative; overflow: hidden;
    background: linear-gradient(135deg, #0099eb 0%, #00b4d8 100%);
    color: white;
    box-shadow: 0 4px 20px rgba(0,153,235,0.42), 0 0 0 1px rgba(255,255,255,0.12) inset;
    transition: var(--transition);
    margin-top: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.btn-signin::before {
    content: '';
    position: absolute; inset: 0;
    background: linear-gradient(135deg, transparent 40%, rgba(255,255,255,0.15));
    opacity: 0; transition: opacity 0.25s;
}
.btn-signin:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(0,153,235,0.58), 0 0 0 1px rgba(255,255,255,0.18) inset;
}
.btn-signin:hover::before { opacity: 1; }
.btn-signin:active:not(:disabled) { transform: translateY(0); }
.btn-signin:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none !important;
}

/* Ripple on button */
.btn-signin .ripple {
    position: absolute;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: scale(0);
    animation: ripple 0.5s linear;
    pointer-events: none;
}
@keyframes ripple {
    to { transform: scale(4); opacity: 0; }
}

/* ─── DIVIDER & FOOTER ──────────────────────────────────────────── */
.card-footer-text {
    text-align: center;
    margin-top: 28px;
    font-size: 0.72rem;
    color: rgba(255,255,255,0.20);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.footer-line {
    flex: 1; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.10), transparent);
}

/* ─── SECURITY BADGE ────────────────────────────────────────────── */
.security-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    margin-top: 14px;
    font-size: 0.7rem;
    color: rgba(255,255,255,0.25);
}
.security-badge i { color: #22c55e; font-size: 0.8rem; }

/* ─── SPINNER ───────────────────────────────────────────────────── */
.spinner {
    width: 16px; height: 16px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ─── LOADING OVERLAY ───────────────────────────────────────────── */
.processing-overlay {
    position: absolute; inset: 0;
    background: rgba(10,15,30,0.85);
    border-radius: 24px;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 12px;
    z-index: 10;
    backdrop-filter: blur(4px);
}
.processing-overlay.show { display: flex; }
.processing-overlay .spinner-lg {
    width: 40px; height: 40px;
    border: 3px solid rgba(59,130,246,0.3);
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}
.processing-text {
    font-size: 0.85rem;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.5px;
}

/* ─── RESPONSIVE ────────────────────────────────────────────────── */
@media (max-width: 480px) {
    .login-card { padding: 32px 24px 28px; }
    .login-brand h1 { font-size: 1.3rem; }
}


@keyframes shakeCard {
    0%, 100% { transform: translateX(0); }
    20%, 60%  { transform: translateX(-8px); }
    40%, 80%  { transform: translateX(8px); }
}


/* --- Styles extracted from login_blocked.php --- */


    body.blocked-body {

      display: flex;

      height: 100vh;

      align-items: center;

      justify-content: center;

      background-color: #f8f9fa;

    }

    body.blocked-body .card {

      max-width: 500px;

      width: 100%;

    }

  

/* --- Styles extracted from template.php --- */


/* Custom dropdown submenu */

.dropdown-submenu {

  position: relative;

}



.dropdown-submenu > .dropdown-menu {

  top: 0;

  left: 100%;

  margin-left: 0;

  margin-right: 0;

}

.dropdown-submenu > a:after {

  content: "▶";

  float: right;

}



/* --- Styles extracted from laporan.php --- */

  .sticky-head { margin-bottom: 0; }
  .sticky-head thead th { vertical-align: middle; background-color: #f8f9fa !important; color: #212529 !important; font-weight: 600 !important; }
  .sticky-head td { vertical-align: top; }
  .sticky-head .num { text-align: center; }
  .sticky-head .num-val { font-weight: 600; font-size: 0.92rem; display: block; }
  .sticky-head .num-sub { font-size: 0.76rem; color: #6c757d; }
  .ket-box { max-height: 100px; overflow: auto; padding-right: 6px; }
  .ket-box ul { margin: 0; padding-left: 18px; }
  .ket-box li { margin-bottom: 4px; font-size: 0.85rem; }
  .sticky-head thead th { position: sticky; top: 0; z-index: 2; }


/* --- Styles extracted from app_admin_atasan.php --- */


    .btn:disabled,

    .btn.disabled {

        opacity: .55;

        cursor: not-allowed;

        pointer-events: none;

    }



/* --- Styles extracted from view.php --- */

  :root{
    --soft-bg: #f8fafc;
    --soft-border: #e9ecef;
    --soft-text: #6c757d;
    --card-radius: 16px;
  }
  .page-header h2{
    font-weight: 700;
    letter-spacing: .2px;
    margin-bottom: 1rem;
  }
  .card-elegant{
    border: 0;
    border-radius: var(--card-radius);
    box-shadow: 0 10px 30px rgba(0,0,0,.06);
    overflow: hidden;
  }
  .card-elegant .card-header{
    background: linear-gradient(135deg, #ffffff, #f8fafc);
    border-bottom: 1px solid var(--soft-border);
    padding: 1rem 1.25rem;
  }
  .card-elegant .card-title{
    margin: 0;
    font-size: 1.1rem;
    font-weight: 700;
    color: #212529;
  }
  .toolbar-actions .btn{
    border-radius: 10px;
    padding: .55rem .9rem;
    font-weight: 600;
  }
  .table-clean{
    margin-bottom: 0;
    vertical-align: middle;
  }
  .table-clean thead th{
    background: #f8fafc;
    border-bottom: 1px solid var(--soft-border);
    color: #495057;
    font-weight: 700;
    text-align: center;
    white-space: nowrap;
  }
  .table-clean tbody td{
    vertical-align: middle;
  }
  .table-clean tbody tr:hover{
    background: #fcfcfd;
  }
  .meta-muted{
    color: var(--soft-text);
    font-size: .875rem;
  }
  .status-stack{
    display: flex;
    flex-direction: column;
    gap: .35rem;
  }
  .badge-soft{
    display: inline-flex;
    align-items: center;
    gap: .35rem;
    padding: .5rem .7rem;
    border-radius: 999px;
    font-weight: 600;
  }
  .modal-content{
    border: 0;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 18px 45px rgba(0,0,0,.12);
  }
  .modal-header-elegant{
    background: linear-gradient(135deg, #0d6efd, #3b82f6);
    color: #fff;
    border-bottom: 0;
    padding: 1rem 1.25rem;
  }
  .modal-header-elegant .modal-title{
    font-weight: 700;
  }
  .nav-tabs .nav-link{
    border: 0;
    border-radius: 10px;
    color: #495057;
    font-weight: 600;
    padding: .7rem 1rem;
  }
  .nav-tabs .nav-link.active{
    background: #eef4ff;
    color: #0d6efd;
  }
  .detail-table th{
    width: 28%;
    background: #f8fafc;
    color: #495057;
    font-weight: 700;
  }
  .detail-table td,
  .detail-table th{
    padding: .85rem 1rem;
    vertical-align: middle;
  }
  .section-subtitle{
    font-size: .95rem;
    font-weight: 700;
    color: #495057;
    margin-bottom: .75rem;
  }
  .file-preview-box{
    padding: .75rem 1rem;
    border: 1px dashed #ced4da;
    border-radius: 12px;
    background: #fafbfc;
  }
  .btn{
    border-radius: 10px;
  }
  .btn-sm{
    border-radius: 8px;
  }
  .modal-footer{
    background: #fcfcfd;
    border-top: 1px solid var(--soft-border);
  }
  .empty-text{
    color: #dc3545;
    font-style: italic;
  }
  .saving-pulse {
    animation: savingPulse 900ms ease-in-out infinite;
  }
  @keyframes savingPulse {
    0%   { transform: scale(1); opacity: 1; }
    50%  { transform: scale(1.01); opacity: .92; }
    100% { transform: scale(1); opacity: 1; }
  }


/* --- Styles extracted from view.php --- */


/* --- Styles extracted from footer.php --- */
.footer {    font-size: 0.85rem;    background: linear-gradient(180deg, #f8f9fa, #ffffff);}.footer .badge {    font-size: 0.7rem;    vertical-align: middle;}.footer .container-fluid {    padding-left: 30px;   /* SAMAKAN dengan konten utama */    padding-right: 24px;}

/* ==========================================================
   RESPONSIVE / MOBILE IMPROVEMENTS — v2.1
   ========================================================== */

/* Tabel responsif: tambah scroll horizontal di mobile */
.table-responsive-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 4px;
}
.table-responsive-wrapper table {
    min-width: 600px;
}

/* Otomatis bungkus tabel dalam card-body agar tidak meluber */
.card-body table.table {
    display: block;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    width: 100%;
}
.card-body table.table thead,
.card-body table.table tbody,
.card-body table.table tfoot {
    display: table;
    width: 100%;
}

/* Header mobile: shrink profil info */
@media (max-width: 768px) {
    .header .userbox .profile-info .name {
        max-width: 100px;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        display: inline-block;
    }
    .header .userbox .profile-info .role {
        display: none;
    }
    /* Kurangi padding header */
    .header .header-right {
        padding-right: 8px;
    }
    /* Content area lebih lebar di mobile */
    .content-body {
        padding: 10px;
    }
    /* Card action buttons di mobile */
    .card-header .card-actions {
        float: none;
        display: flex;
        flex-wrap: wrap;
        gap: 4px;
        margin-bottom: 8px;
    }
    /* Form labels di mobile: lebar penuh */
    .form-group.row > label.col-form-label {
        text-align: left !important;
    }
    /* Modal full-width di mobile */
    .modal-dialog {
        margin: 10px;
    }
    /* Tabel font-size lebih kecil di mobile */
    .table td, .table th {
        font-size: 13px;
        padding: 6px 8px;
    }
    /* Badge wrap di mobile */
    .badge {
        white-space: normal;
        word-break: break-word;
    }
}

@media (max-width: 480px) {
    /* Login card di layar sangat kecil */
    .login-card {
        padding: 24px 16px !important;
        border-radius: 16px !important;
    }
    .login-page {
        padding: 16px !important;
    }
    /* Orb terlalu besar di mobile kecil */
    .orb-1 { width: 200px !important; height: 200px !important; }
    .orb-2 { width: 160px !important; height: 160px !important; }
    .orb-3 { width: 120px !important; height: 120px !important; }
}

/* Input focus: tidak zoom di iOS (font-size minimal 16px) */
input.field-input,
select.form-control,
textarea.form-control,
input.form-control {
    font-size: 16px;
}
/* Kembalikan ukuran asli di desktop */
@media (min-width: 769px) {
    input.field-input,
    select.form-control,
    textarea.form-control,
    input.form-control {
        font-size: 14px;
    }
}

