@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700;800;900&family=Plus+Jakarta+Sans:ital,wght@0,300..800;1,300..800&display=swap');

:root {
    --filkom-primary: #0f2b5c;
    --filkom-primary-dark: #0a1c3d;
    --filkom-secondary: #1e5bb8;
    --filkom-accent: #2563eb;
    --filkom-accent-light: #e0f2fe;
    --filkom-accent-cyan: #06b6d4;
    --filkom-bg: #f8fafc;
    --filkom-card-bg: #ffffff;
    --filkom-text-main: #1e293b;
    --filkom-text-muted: #64748b;
    --filkom-border: #e2e8f0;
    --sidebar-width: 270px;
    --sidebar-collapsed-width: 80px;
    --topbar-height: 70px;
}

body {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background-color: var(--filkom-bg);
    color: var(--filkom-text-main);
    overflow-x: clip;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Custom Scrollbars */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}
::-webkit-scrollbar-track {
    background: #f1f5f9;
}
::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Mobile Sidebar Backdrop */
.sidebar-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(10, 28, 61, 0.65);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    z-index: 1025;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.sidebar-backdrop.show {
    opacity: 1;
    visibility: visible;
}

/* Sidebar Styling */
#sidebar-wrapper {
    width: var(--sidebar-width);
    min-height: 100vh;
    background: linear-gradient(180deg, #0f2b5c 0%, #0c234a 100%);
    color: #f8fafc;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 1030;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

#sidebar-wrapper.collapsed {
    transform: translateX(-100%) !important;
    box-shadow: none !important;
    pointer-events: none;
}

#sidebar-wrapper .sidebar-brand {
    height: var(--topbar-height);
    display: flex;
    align-items: center;
    padding: 0 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
}

#sidebar-wrapper .sidebar-nav {
    padding: 1rem 0.75rem;
    overflow-y: auto;
    flex-grow: 1;
    -webkit-overflow-scrolling: touch;
}

.nav-section-title {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.45);
    padding: 0.75rem 0.85rem 0.35rem;
}

.sidebar-nav-link {
    display: flex;
    align-items: center;
    padding: 0.7rem 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    border-radius: 0.5rem;
    font-weight: 500;
    font-size: 0.88rem;
    margin-bottom: 0.25rem;
    transition: all 0.2s ease;
    min-height: 42px;
}

.sidebar-nav-link i {
    font-size: 1.15rem;
    width: 1.75rem;
    margin-right: 0.5rem;
    display: inline-flex;
    justify-content: center;
    color: rgba(255, 255, 255, 0.7);
    transition: color 0.2s ease;
}

.sidebar-nav-link:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.1);
}

.sidebar-nav-link:hover i {
    color: #38bdf8;
}

.sidebar-nav-link.active {
    color: #ffffff;
    background: linear-gradient(90deg, #1e5bb8 0%, #2563eb 100%);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    font-weight: 600;
}

.sidebar-nav-link.active i {
    color: #ffffff;
}

/* Page Content Wrapper */
#content-wrapper {
    margin-left: var(--sidebar-width);
    transition: margin-left 0.3s cubic-bezier(0.16, 1, 0.3, 1), width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    width: calc(100% - var(--sidebar-width));
}

#content-wrapper.expanded {
    margin-left: 0 !important;
    width: 100% !important;
}

/* Top Navbar */
.top-navbar {
    height: var(--topbar-height);
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border-bottom: 1px solid var(--filkom-border);
    padding: 0 1.5rem;
    position: sticky !important;
    top: 0 !important;
    z-index: 1020 !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.03);
    transition: box-shadow 0.25s ease, background-color 0.25s ease;
}

.top-navbar.is-scrolled {
    background: rgba(255, 255, 255, 0.98) !important;
    box-shadow: 0 4px 20px rgba(15, 23, 42, 0.08) !important;
}

/* Cards & Elevated Containers */
.card {
    border-radius: 0.875rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-custom {
    border: 1px solid var(--filkom-border);
    border-radius: 0.875rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
    background: #ffffff;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card-custom:hover {
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
}

.filter-card {
    border: 1px solid var(--filkom-border);
    border-radius: 0.75rem;
    background: #ffffff;
}

.filter-card .form-label,
form[method="GET" i] .form-label,
form[method="get" i] .form-label {
    font-size: 0.78rem;
    font-weight: 600;
    color: #64748b;
    margin-bottom: 0.25rem;
}

.filter-card .form-control,
.filter-card .form-select,
form[method="GET" i] .form-control,
form[method="GET" i] .form-select,
form[method="get" i] .form-control,
form[method="get" i] .form-select {
    font-size: 0.82rem;
}

.stat-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.35rem;
    flex-shrink: 0;
}

.bg-soft-primary {
    background-color: #e8f0fe;
    color: #1e5bb8;
}

.bg-soft-success {
    background-color: #dcfce7;
    color: #15803d;
}

.bg-soft-warning {
    background-color: #fef3c7;
    color: #b45309;
}

.bg-soft-info {
    background-color: #e0f2fe;
    color: #0369a1;
}

.bg-soft-danger {
    background-color: #fee2e2;
    color: #b91c1c;
}

.bg-soft-purple {
    background-color: #f3e8ff;
    color: #7e22ce;
}

.text-purple {
    color: #7e22ce !important;
}

.bg-purple-subtle {
    background-color: #f3e8ff !important;
    color: #7e22ce !important;
    border: 1px solid #e9d5ff !important;
}

.bg-primary-subtle {
    background-color: #e0f2fe !important;
    color: #0284c7 !important;
}

.bg-warning-subtle {
    background-color: #fef3c7 !important;
    color: #b45309 !important;
}

.bg-success-subtle {
    background-color: #dcfce7 !important;
    color: #15803d !important;
}

.bg-danger-subtle {
    background-color: #fee2e2 !important;
    color: #b91c1c !important;
}

.bg-info-subtle {
    background-color: #e0f2fe !important;
    color: #0369a1 !important;
}

/* Stepper Component */
.stepper-container {
    display: flex;
    justify-content: space-between;
    position: relative;
    margin: 1.5rem 0;
}

.stepper-container::before {
    content: '';
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    height: 3px;
    background-color: #e2e8f0;
    z-index: 1;
}

.stepper-item {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    flex: 1;
    padding: 0 0.25rem;
}

.stepper-circle {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: #ffffff;
    border: 3px solid #cbd5e1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #64748b;
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
    font-size: 0.85rem;
}

.stepper-item.completed .stepper-circle {
    background-color: #10b981;
    border-color: #10b981;
    color: #ffffff;
}

.stepper-item.active .stepper-circle {
    background-color: #1e5bb8;
    border-color: #1e5bb8;
    color: #ffffff;
    box-shadow: 0 0 0 4px rgba(30, 91, 184, 0.2);
}

.stepper-title {
    font-size: 0.78rem;
    font-weight: 600;
    color: #64748b;
}

.stepper-item.active .stepper-title,
.stepper-item.completed .stepper-title {
    color: #0f2b5c;
    font-weight: 700;
}

/* =======================================================
   LOGIN PAGE - MODERN ANIMATED UI & APPLE GLASSMORPHISM
   ======================================================= */
.login-bg {
    font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, sans-serif !important;
    min-height: 100vh;
    min-height: 100dvh;
    background: radial-gradient(circle at 50% 0%, #0c2554 0%, #07152b 55%, #030a14 100%);
    position: relative;
    overflow-x: hidden;
    overflow-y: auto;
    padding: max(1rem, env(safe-area-inset-top)) 0.75rem max(1rem, env(safe-area-inset-bottom)) 0.75rem;
    letter-spacing: -0.01em;
}

.login-hero-title {
    font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif !important;
    font-weight: 800 !important;
    letter-spacing: -0.035em !important;
    line-height: 1.15 !important;
}

.login-mobile-title {
    font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif !important;
    font-weight: 800 !important;
    font-size: 1.45rem !important;
    line-height: 1.2 !important;
    letter-spacing: -0.03em !important;
}

.login-title-gradient {
    background: linear-gradient(135deg, #38bdf8 0%, #60a5fa 55%, #93c5fd 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
    display: inline-block;
    filter: drop-shadow(0 2px 10px rgba(56, 189, 248, 0.3));
}

.login-univ-name {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
    color: rgba(255, 255, 255, 0.75) !important;
    letter-spacing: 0.015em !important;
}

.login-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.login-card-wrapper {
    max-width: 440px;
}

/* Cyber Grid Background Overlay */
.cyber-grid {
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(rgba(56, 189, 248, 0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(56, 189, 248, 0.04) 1px, transparent 1px);
    background-size: 50px 50px;
    mask-image: radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 80%);
    -webkit-mask-image: radial-gradient(ellipse at 50% 50%, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0) 80%);
    pointer-events: none;
    z-index: 0;
}


/* Fluid Animated Gradient Aurora Orbs */
.orb-wrapper {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.aurora-orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.55;
    will-change: transform, opacity;
}

.orb-primary {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(30, 91, 184, 0.6) 0%, rgba(14, 165, 233, 0.35) 60%, transparent 80%);
    top: -150px;
    right: -100px;
    animation: floatOrb1 20s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
}

.orb-secondary {
    width: 550px;
    height: 550px;
    background: radial-gradient(circle, rgba(15, 43, 92, 0.7) 0%, rgba(37, 99, 235, 0.4) 60%, transparent 80%);
    bottom: -150px;
    left: -120px;
    animation: floatOrb2 25s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
}

.orb-accent {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(197, 155, 39, 0.22) 0%, rgba(245, 158, 11, 0.12) 50%, transparent 80%);
    top: 40%;
    left: 20%;
    animation: floatOrb3 18s ease-in-out infinite alternate;
}

.orb-cyan {
    width: 450px;
    height: 450px;
    background: radial-gradient(circle, rgba(56, 189, 248, 0.35) 0%, rgba(3, 105, 161, 0.2) 60%, transparent 80%);
    bottom: 10%;
    right: 15%;
    animation: floatOrb4 22s cubic-bezier(0.4, 0, 0.2, 1) infinite alternate;
}

@keyframes floatOrb1 {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(-80px, 100px) scale(1.15) rotate(90deg); }
    100% { transform: translate(-140px, 40px) scale(0.95) rotate(180deg); }
}

@keyframes floatOrb2 {
    0% { transform: translate(0, 0) scale(1) rotate(0deg); }
    50% { transform: translate(100px, -90px) scale(1.12) rotate(-60deg); }
    100% { transform: translate(160px, -40px) scale(0.9) rotate(-120deg); }
}

@keyframes floatOrb3 {
    0% { transform: translate(0, 0) scale(0.95); opacity: 0.3; }
    50% { transform: translate(-60px, 80px) scale(1.2); opacity: 0.6; }
    100% { transform: translate(40px, -50px) scale(1.05); opacity: 0.4; }
}

@keyframes floatOrb4 {
    0% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(-90px, -70px) scale(1.2); }
    100% { transform: translate(60px, -110px) scale(0.9); }
}

/* Apple Liquid / Frosted Glass Login Card */
.login-card {
    background: rgba(255, 255, 255, 0.68) !important;
    backdrop-filter: blur(28px) saturate(210%) !important;
    -webkit-backdrop-filter: blur(28px) saturate(210%) !important;
    border: 1px solid rgba(255, 255, 255, 0.65) !important;
    border-radius: 1.75rem !important;
    box-shadow: 
        0 30px 60px -12px rgba(0, 8, 28, 0.45),
        0 12px 28px -6px rgba(0, 8, 28, 0.25),
        inset 0 1.5px 1.5px 0 rgba(255, 255, 255, 0.95),
        inset 0 -1px 1px 0 rgba(255, 255, 255, 0.25) !important;
    position: relative;
    z-index: 10;
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.login-card:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 36px 70px -12px rgba(0, 8, 28, 0.55),
        0 16px 32px -6px rgba(0, 8, 28, 0.3),
        inset 0 1.5px 1.5px 0 rgba(255, 255, 255, 1),
        inset 0 -1px 1px 0 rgba(255, 255, 255, 0.35) !important;
}

/* 3D Student Mascot Avatar (Transparent Cutout) */
.login-mascot-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 0 10px;
}

.login-mascot-img {
    height: 124px;
    width: auto;
    object-fit: contain;
    background: transparent !important;
    filter: drop-shadow(0 10px 20px rgba(7, 21, 43, 0.35));
    transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), filter 0.35s ease;
    will-change: transform;
}

.login-mascot-wrapper:hover .login-mascot-img {
    transform: translateY(-4px) scale(1.04);
    filter: drop-shadow(0 14px 26px rgba(30, 91, 184, 0.45));
}

.mascot-shield-badge {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 26px;
    height: 32px;
    object-fit: contain;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.35));
    transition: transform 0.3s ease;
}

.login-mascot-wrapper:hover .mascot-shield-badge {
    transform: rotate(6deg) scale(1.1);
}

/* Transparent Logo Branding (No White Box / Background) */
.login-logo-box {
    width: auto;
    height: auto;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
    padding: 0 !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.login-brand-logo {
    width: 60px;
    height: 72px;
    object-fit: contain;
    background: transparent !important;
    filter: drop-shadow(0 4px 10px rgba(15, 43, 92, 0.25));
    transition: transform 0.3s ease;
}

.login-brand-logo:hover {
    transform: scale(1.05);
}

/* Floating Badges & Cards on the Left Panel */
.floating-brand-badge {
    animation: floatBadge 4s ease-in-out infinite;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}

@keyframes floatBadge {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

.feature-glass-box {
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.16) !important;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border-radius: 0.875rem;
    transition: all 0.3s ease;
}

.feature-glass-box:hover {
    background: rgba(255, 255, 255, 0.13) !important;
    border-color: rgba(56, 189, 248, 0.5) !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(15, 43, 92, 0.35);
}

/* Translucent Frosted Form Controls (Apple-style) */
.login-input-group {
    border-radius: 0.85rem;
    transition: box-shadow 0.25s ease;
}

.login-input-group .input-group-text {
    background: rgba(255, 255, 255, 0.5) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.75) !important;
    border-right: none !important;
    color: #475569 !important;
    border-top-left-radius: 0.85rem !important;
    border-bottom-left-radius: 0.85rem !important;
    padding-left: 1rem;
    padding-right: 0.75rem;
    transition: all 0.25s ease;
}

.login-input-group .form-control {
    background: rgba(255, 255, 255, 0.5) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.75) !important;
    color: #0f172a !important;
    font-weight: 500;
    font-size: 16px; /* Essential for mobile iOS Safari to prevent auto-zooming */
    min-height: 44px;
    transition: all 0.25s ease;
}

.login-input-group .form-control::placeholder {
    color: #94a3b8;
    font-weight: 400;
    font-size: 0.88rem;
}

.login-input-group .btn-password-toggle {
    background: rgba(255, 255, 255, 0.5) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(255, 255, 255, 0.75) !important;
    border-left: none !important;
    color: #64748b !important;
    border-top-right-radius: 0.85rem !important;
    border-bottom-right-radius: 0.85rem !important;
    transition: all 0.25s ease;
}

/* Glowing Apple Accent Focus State */
.login-input-group:focus-within {
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.35), 0 4px 15px rgba(30, 91, 184, 0.15) !important;
}

.login-input-group:focus-within .input-group-text,
.login-input-group:focus-within .form-control,
.login-input-group:focus-within .btn-password-toggle {
    background: rgba(255, 255, 255, 0.9) !important;
    border-color: #38bdf8 !important;
}

.login-input-group:focus-within .input-group-text {
    color: #1e5bb8 !important;
}

/* Submit Button with Smooth Gradient & Specular Sweep */
.btn-login-submit {
    background: linear-gradient(135deg, #1e5bb8 0%, #0f2b5c 100%) !important;
    border: 1px solid rgba(255, 255, 255, 0.3) !important;
    border-radius: 0.85rem !important;
    font-weight: 600;
    letter-spacing: 0.3px;
    color: #ffffff !important;
    position: relative;
    overflow: hidden;
    min-height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 
        0 8px 20px -4px rgba(30, 91, 184, 0.45),
        inset 0 1px 0 rgba(255, 255, 255, 0.35) !important;
}

.btn-login-submit::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -70%;
    width: 45%;
    height: 200%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
    transform: rotate(25deg);
    transition: left 0.75s ease;
}

.btn-login-submit:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 12px 28px -4px rgba(30, 91, 184, 0.55),
        inset 0 1px 0 rgba(255, 255, 255, 0.45) !important;
    color: #ffffff !important;
}

.btn-login-submit:hover::after {
    left: 130%;
}

.btn-login-submit:active {
    transform: translateY(0);
    box-shadow: 0 4px 12px rgba(30, 91, 184, 0.3) !important;
}

/* Apple Frosted Glass Quick Shortcut Buttons */
.btn-glass-shortcut {
    background: rgba(255, 255, 255, 0.5) !important;
    backdrop-filter: blur(10px) !important;
    -webkit-backdrop-filter: blur(10px) !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
    color: #0f2b5c !important;
    font-weight: 600;
    border-radius: 0.75rem !important;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.btn-glass-shortcut:hover {
    background: rgba(255, 255, 255, 0.85) !important;
    color: #1e5bb8 !important;
    border-color: rgba(56, 189, 248, 0.6) !important;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(30, 91, 184, 0.15) !important;
}

.btn-glass-shortcut:active {
    transform: translateY(0);
}

/* Enhanced Table Touch-Scrolling */
.table-responsive {
    -webkit-overflow-scrolling: touch;
    border-radius: 0.75rem;
}

.table-responsive::-webkit-scrollbar {
    height: 5px;
}
.table-responsive::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

/* Mobile-Friendly Form Controls */
.form-control, .form-select {
    border-color: #cbd5e1;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    padding: 0.55rem 0.75rem;
    transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
}

.form-control:focus, .form-select:focus {
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.btn {
    border-radius: 0.5rem;
    font-weight: 500;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-primary {
    background: linear-gradient(135deg, #0f2b5c 0%, #1e5bb8 100%);
    border-color: #0f2b5c;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #0a1c3d 0%, #174894 100%);
    border-color: #0a1c3d;
}

/* =======================================================
   RESPONSIVE BREAKPOINTS (Mobile & Tablet Optimization)
   ======================================================= */

/* Tablet & Mobile Screens (< 992px) */
@media (max-width: 991.98px) {
    #sidebar-wrapper {
        width: min(290px, 85vw);
        transform: translateX(-100%);
        box-shadow: 8px 0 30px rgba(0, 0, 0, 0.3);
    }

    #sidebar-wrapper.show {
        transform: translateX(0);
    }

    #content-wrapper {
        margin-left: 0 !important;
        width: 100% !important;
        max-width: 100vw;
    }

    .top-navbar {
        padding: 0 1rem;
    }
}

/* Small Devices / Phones (< 768px) */
@media (max-width: 767.98px) {
    html, body {
        font-size: 0.85rem;
        overflow-x: clip !important;
        max-width: 100vw;
    }

    #content-wrapper {
        overflow-x: clip !important;
        max-width: 100vw !important;
    }

    main {
        padding: 0.75rem 0.5rem !important;
    }

    .card {
        border-radius: 0.75rem;
    }

    .card-body {
        padding: 0.85rem !important;
    }

    .card-custom {
        padding: 0.85rem !important;
    }

    /* Headings scaling on mobile */
    h3, .h3 { font-size: 1.25rem !important; }
    h4, .h4 { font-size: 1.15rem !important; }
    h5, .h5 { font-size: 1.02rem !important; }
    h6, .h6 { font-size: 0.92rem !important; }
    .display-3 { font-size: 2rem !important; }
    .display-4 { font-size: 1.6rem !important; }

    /* Top navbar mobile height & spacing */
    .top-navbar {
        height: 60px;
        padding: 0 0.75rem !important;
        position: sticky !important;
        top: 0 !important;
        z-index: 1020 !important;
    }

    /* Card padding compression on Mobile (Overrides Bootstrap utility .p-4) */
    .card.p-4,
    .card-custom.p-4,
    div.p-4.card,
    div.p-4.card-custom {
        padding: 0.85rem !important;
    }

    .card.mb-4,
    .card-custom.mb-4 {
        margin-bottom: 0.85rem !important;
    }

    /* Filter Card Container */
    .filter-card,
    .filter-box,
    .card.filter-card,
    .card.card-custom.filter-card {
        padding: 0.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    /* Precision Filter Controls Compact Font & Sizing on Mobile */
    .filter-card .form-control,
    .filter-card .form-select,
    .filter-card input,
    .filter-card select,
    form[method="GET" i] .form-control,
    form[method="GET" i] .form-select,
    form[method="GET" i] input,
    form[method="GET" i] select,
    form[method="get" i] .form-control,
    form[method="get" i] .form-select,
    form[method="get" i] input,
    form[method="get" i] select,
    .form-control-sm,
    .form-select-sm,
    .input-group-sm > .form-control,
    .input-group-sm > .form-select,
    .input-group-sm > input,
    .input-group-sm > select {
        font-size: 0.74rem !important;
        padding: 0.25rem 0.45rem !important;
        min-height: 28px !important;
        height: 28px !important;
        line-height: 1.2 !important;
        border-radius: 0.375rem !important;
    }

    .filter-card select option,
    form[method="GET" i] select option,
    form[method="get" i] select option,
    .form-select-sm option {
        font-size: 0.74rem !important;
    }

    .filter-card input::placeholder,
    form[method="GET" i] input::placeholder,
    form[method="get" i] input::placeholder,
    .form-control-sm::placeholder,
    .input-group-sm input::placeholder {
        font-size: 0.72rem !important;
        color: #94a3b8 !important;
    }

    /* Filter Form Labels */
    .filter-card .form-label,
    .filter-card label,
    form[method="GET" i] label,
    form[method="get" i] label,
    .form-label,
    label.form-label,
    label.small {
        font-size: 0.68rem !important;
        margin-bottom: 0.12rem !important;
        font-weight: 600 !important;
        color: #64748b !important;
        text-transform: none;
    }

    /* Filter Bar Action Buttons (Filter & Reset) */
    .filter-card .btn,
    .filter-card .btn-sm,
    form[method="GET" i] .btn,
    form[method="GET" i] .btn-sm,
    form[method="get" i] .btn,
    form[method="get" i] .btn-sm,
    .input-group-sm > .btn {
        font-size: 0.72rem !important;
        padding: 0.22rem 0.5rem !important;
        min-height: 28px !important;
        height: 28px !important;
        line-height: 1.2 !important;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        border-radius: 0.375rem !important;
    }

    /* Back Buttons ("Kembali ke Halaman Sebelumnya / Kembali") */
    .btn-back,
    a.btn-back,
    button.btn-back,
    a.btn:has(.fa-arrow-left),
    button:has(.fa-arrow-left),
    a.btn:has(.fa-chevron-left),
    .btn-outline-secondary:has(.fa-arrow-left),
    a.btn-outline-secondary:has(.fa-arrow-left) {
        font-size: 0.7rem !important;
        padding: 0.2rem 0.55rem !important;
        border-radius: 50rem !important;
        min-height: 26px !important;
        height: 26px !important;
        line-height: 1.2 !important;
        display: inline-flex !important;
        align-items: center !important;
        gap: 0.25rem !important;
        font-weight: 500 !important;
    }

    .btn-back i,
    a.btn-back i,
    button.btn-back i,
    a.btn:has(.fa-arrow-left) i,
    button:has(.fa-arrow-left) i {
        font-size: 0.66rem !important;
    }

    /* General Form Controls on Mobile */
    .form-control:not(.form-control-sm):not(form[method="GET"] .form-control),
    .form-select:not(.form-select-sm):not(form[method="GET"] .form-select) {
        font-size: 0.85rem;
        padding: 0.4rem 0.6rem;
    }

    /* General Small Buttons on Mobile */
    .btn:not(.btn-lg) {
        font-size: 0.78rem;
        padding: 0.3rem 0.6rem;
    }

    .btn-sm {
        font-size: 0.74rem !important;
        padding: 0.24rem 0.52rem !important;
    }

    /* Buttons stack nicely on mobile */
    .mobile-stack-buttons {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        width: 100%;
    }

    .mobile-stack-buttons .btn {
        width: 100%;
    }

    /* Precision Table Styling for Mobile */
    .table-responsive {
        width: 100% !important;
        max-width: 100%;
        overflow-x: auto !important;
        -webkit-overflow-scrolling: touch;
        border: 1px solid var(--filkom-border);
        border-radius: 0.65rem;
        margin-bottom: 0.25rem;
    }

    .table {
        margin-bottom: 0;
        font-size: 0.8rem;
    }

    .table td, .table th {
        padding: 0.5rem 0.45rem !important;
        font-size: 0.78rem;
        vertical-align: middle;
        white-space: nowrap;
    }

    /* Allow main title/name content to wrap naturally */
    .table td > div.fw-semibold,
    .table td > div.fw-bold,
    .table td strong {
        white-space: normal;
        word-break: break-word;
        line-height: 1.25;
    }

    /* Compact Buttons inside Tables */
    .table .btn, .table .btn-sm {
        padding: 0.22rem 0.45rem !important;
        font-size: 0.72rem !important;
        line-height: 1.2;
    }

    .table .btn-group {
        display: inline-flex;
        flex-wrap: nowrap;
    }

    /* Compact Badges */
    .badge {
        font-size: 0.65rem;
        font-weight: 600;
        padding: 0.22rem 0.42rem;
    }

    /* Stat Box Cards on Mobile */
    .stat-icon-box {
        width: 40px;
        height: 40px;
        font-size: 1.15rem;
    }

    /* Modal padding on mobile */
    .modal-dialog {
        margin: 0.5rem;
        max-width: calc(100% - 1rem);
    }

    .modal-content {
        border-radius: 0.875rem;
    }

    .modal-body {
        padding: 1rem !important;
    }
}

/* Extra Small Phones (< 576px) */
@media (max-width: 575.98px) {
    .table td, .table th {
        padding: 0.42rem 0.35rem !important;
        font-size: 0.75rem;
    }

    .table td.text-end {
        padding-right: 0.35rem !important;
    }

    .stepper-container {
        margin: 0.5rem 0;
    }

    .stepper-container::before {
        top: 15px;
    }

    .stepper-circle {
        width: 28px;
        height: 28px;
        font-size: 0.7rem;
        border-width: 2px;
    }

    .stepper-title {
        font-size: 0.62rem;
        line-height: 1.1;
    }

    /* Unified Mobile Metric Strip (1 Baris Kesamping di Mode Mobile) */
    .mobile-metric-card {
        background: #ffffff;
        border: 1px solid #e2e8f0;
        border-radius: 0.875rem !important;
        box-shadow: 0 2px 8px -2px rgba(15, 23, 42, 0.05) !important;
        padding: 0.5rem 0.2rem !important;
        margin-bottom: 0.85rem !important;
    }

    .mobile-metric-scroll {
        display: flex;
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        margin: 0;
        padding: 0;
    }

    .mobile-metric-scroll::-webkit-scrollbar {
        display: none;
    }

    .mobile-metric-col {
        position: relative;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 0.25rem 0.15rem !important;
        min-width: 0;
    }

    .mobile-metric-scroll .mobile-metric-col {
        flex: 0 0 25%;
        min-width: 78px;
    }

    .mobile-metric-col:not(:last-child)::after,
    .mobile-metric-divider {
        content: "";
        position: absolute;
        right: 0;
        top: 15%;
        bottom: 15%;
        width: 1px;
        background: #e2e8f0;
    }

    .mobile-metric-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        text-align: center;
        width: 100%;
        padding: 0 0.1rem;
    }

    .mobile-metric-value {
        font-family: 'Outfit', 'Plus Jakarta Sans', sans-serif;
        font-size: 1.25rem;
        font-weight: 800;
        line-height: 1.1;
        letter-spacing: -0.02em;
        margin-bottom: 2px;
    }

    .mobile-metric-label {
        font-size: 0.62rem;
        font-weight: 700;
        text-transform: uppercase;
        color: #64748b;
        letter-spacing: 0.3px;
        line-height: 1.15;
        margin-bottom: 3px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 95%;
    }

    .mobile-metric-badge {
        font-size: 0.56rem;
        font-weight: 600;
        padding: 1px 5px;
        border-radius: 9999px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        white-space: nowrap;
        line-height: 1.2;
        max-width: 92%;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    /* Compact Stat Cards (1 Baris Kesamping di Mode Mobile) */
    .stat-compact-card {
        padding: 0.5rem 0.35rem !important;
        border-radius: 0.75rem !important;
    }

    .stat-compact-title {
        font-size: 0.62rem !important;
        line-height: 1.15;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .stat-compact-num {
        font-size: 1.15rem !important;
        line-height: 1;
    }

    .stat-micro-icon {
        width: 22px !important;
        height: 22px !important;
        min-width: 22px !important;
        font-size: 0.65rem !important;
        border-radius: 6px !important;
    }

    .login-bg {
        padding: 1.25rem 0.85rem !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
    }

    .login-container {
        padding-left: 0.25rem !important;
        padding-right: 0.25rem !important;
    }

    .login-card-wrapper {
        max-width: 100% !important;
        width: 100% !important;
        padding: 0 !important;
        margin: 0 auto !important;
    }

    .login-card {
        padding: 1.75rem 1.35rem !important;
        border-radius: 1.5rem !important;
        box-shadow: 
            0 20px 45px -10px rgba(0, 8, 28, 0.5),
            inset 0 1.5px 1.5px 0 rgba(255, 255, 255, 0.95),
            inset 0 -1px 1px 0 rgba(255, 255, 255, 0.25) !important;
    }

    .login-mascot-img {
        height: 105px !important;
    }

    .mascot-shield-badge {
        width: 22px !important;
        height: 27px !important;
        bottom: 0px !important;
        right: 0px !important;
    }

    .login-logo-box {
        width: auto !important;
        height: auto !important;
        padding: 0 !important;
        border: none !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    .login-brand-logo {
        width: 52px !important;
        height: 64px !important;
        margin-bottom: 0.25rem !important;
    }

    .login-card-title {
        font-size: 1.2rem !important;
    }

    .login-card-subtitle {
        font-size: 0.82rem !important;
    }

    .login-input-group .form-control {
        font-size: 16px !important; /* Prevents auto-zoom on iOS */
        min-height: 42px;
    }

    .login-input-group .input-group-text,
    .login-input-group .btn-password-toggle {
        min-height: 42px;
    }

    .btn-login-submit {
        min-height: 44px !important;
        font-size: 0.92rem !important;
    }

    .btn-glass-shortcut {
        font-size: 0.72rem !important;
        padding: 0.5rem 0.25rem !important;
    }

    /* Filter Form buttons full width on small screens */
    form.row.g-2 > div[class*="col-"] > button[type="submit"],
    form.row.g-3 > div[class*="col-"] > button[type="submit"] {
        font-size: 0.72rem !important;
    }
}

/* ==========================================================================
   PREMIUM SWEETALERT2 POPUPS & TOAST NOTIFICATIONS (APPLE / LINEAR STYLE)
   ========================================================================== */

/* Toast Container Positioning */
.swal2-container.swal2-top,
.swal2-container.swal2-top-end {
    padding: 1rem !important;
    z-index: 99999 !important;
}

/* Toast Card Base */
.swal2-toast.filkom-swal-toast {
    background: rgba(255, 255, 255, 0.94) !important;
    backdrop-filter: blur(16px) saturate(190%) !important;
    -webkit-backdrop-filter: blur(16px) saturate(190%) !important;
    border: 1px solid rgba(255, 255, 255, 0.85) !important;
    border-radius: 1rem !important;
    box-shadow: 
        0 20px 40px -12px rgba(15, 23, 42, 0.16),
        0 4px 14px -2px rgba(15, 23, 42, 0.08),
        inset 0 1px 1px 0 rgba(255, 255, 255, 0.95) !important;
    padding: 0.85rem 1.15rem !important;
    min-width: 300px !important;
    max-width: 440px !important;
    align-items: center !important;
    overflow: hidden !important;
    position: relative !important;
    cursor: pointer !important;
    user-select: none !important;
    transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.2s ease !important;
}

.swal2-toast.filkom-swal-toast:hover {
    transform: translateY(-2px) scale(1.01) !important;
    box-shadow: 
        0 24px 45px -10px rgba(15, 23, 42, 0.2),
        0 8px 18px -4px rgba(15, 23, 42, 0.1) !important;
}

/* Accent Glow and Left Indicator Border by Icon Type */
.swal2-toast.filkom-swal-toast.swal2-icon-success {
    border-left: 4.5px solid #10b981 !important;
}
.swal2-toast.filkom-swal-toast.swal2-icon-success .filkom-toast-progress {
    background: linear-gradient(90deg, #10b981 0%, #34d399 100%) !important;
}

.swal2-toast.filkom-swal-toast.swal2-icon-error {
    border-left: 4.5px solid #f43f5e !important;
}
.swal2-toast.filkom-swal-toast.swal2-icon-error .filkom-toast-progress {
    background: linear-gradient(90deg, #ef4444 0%, #f43f5e 100%) !important;
}

.swal2-toast.filkom-swal-toast.swal2-icon-warning {
    border-left: 4.5px solid #f59e0b !important;
}
.swal2-toast.filkom-swal-toast.swal2-icon-warning .filkom-toast-progress {
    background: linear-gradient(90deg, #d97706 0%, #fbbf24 100%) !important;
}

.swal2-toast.filkom-swal-toast.swal2-icon-info {
    border-left: 4.5px solid #0ea5e9 !important;
}
.swal2-toast.filkom-swal-toast.swal2-icon-info .filkom-toast-progress {
    background: linear-gradient(90deg, #0284c7 0%, #38bdf8 100%) !important;
}

/* Toast Title & Content */
.filkom-toast-title {
    font-family: 'Outfit', sans-serif !important;
    font-size: 0.94rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    letter-spacing: -0.01em !important;
    margin: 0 !important;
    padding: 0 !important;
}

.filkom-toast-content {
    font-family: 'Plus Jakarta Sans', sans-serif !important;
    font-size: 0.8rem !important;
    font-weight: 500 !important;
    color: #475569 !important;
    line-height: 1.4 !important;
    margin: 0.2rem 0 0 0 !important;
    padding: 0 !important;
}

/* Sleek Icon Scaling in Toast */
.swal2-toast.filkom-swal-toast .swal2-icon {
    width: 28px !important;
    height: 28px !important;
    min-width: 28px !important;
    margin: 0 0.85rem 0 0 !important;
    border-width: 2.5px !important;
}

.swal2-toast.filkom-swal-toast .swal2-icon.swal2-success [class^='swal2-success-line'] {
    height: 3px !important;
}

/* Modern Micro Progress Bar */
.filkom-toast-progress {
    height: 3px !important;
    opacity: 0.85 !important;
}

/* Fluid Snappy Animations for Toast */
@keyframes filkomToastSlideDown {
    0% {
        opacity: 0;
        transform: translate3d(0, -32px, 0) scale(0.92);
        filter: blur(4px);
    }
    60% {
        transform: translate3d(0, 4px, 0) scale(1.02);
    }
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
        filter: blur(0);
    }
}

@keyframes filkomToastSlideUp {
    0% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
    100% {
        opacity: 0;
        transform: translate3d(16px, -20px, 0) scale(0.9);
        filter: blur(4px);
    }
}

.filkom-toast-in {
    animation: filkomToastSlideDown 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

.filkom-toast-out {
    animation: filkomToastSlideUp 0.22s cubic-bezier(0.4, 0, 1, 1) forwards !important;
}

/* Full Modal Popups (Swal.fire Dialog) */
.swal2-popup.filkom-swal-modal {
    background: rgba(255, 255, 255, 0.96) !important;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border: 1px solid rgba(255, 255, 255, 0.8) !important;
    border-radius: 1.5rem !important;
    box-shadow: 
        0 30px 60px -15px rgba(15, 23, 42, 0.25),
        0 12px 28px -6px rgba(15, 23, 42, 0.12) !important;
    padding: 2rem 1.5rem !important;
    font-family: 'Plus Jakarta Sans', sans-serif !important;
}

.swal2-popup.filkom-swal-modal .swal2-title {
    font-family: 'Outfit', sans-serif !important;
    font-weight: 700 !important;
    font-size: 1.35rem !important;
    color: #0f172a !important;
}

.swal2-popup.filkom-swal-modal .swal2-html-container {
    color: #475569 !important;
    font-size: 0.92rem !important;
    line-height: 1.5 !important;
}

.swal2-popup.filkom-swal-modal .swal2-confirm {
    background: linear-gradient(135deg, #1e5bb8 0%, #0f2b5c 100%) !important;
    border-radius: 9999px !important;
    padding: 0.65rem 1.75rem !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
    box-shadow: 0 4px 14px rgba(30, 91, 184, 0.35) !important;
}

.swal2-popup.filkom-swal-modal .swal2-cancel {
    background: #f1f5f9 !important;
    color: #475569 !important;
    border-radius: 9999px !important;
    padding: 0.65rem 1.5rem !important;
    font-weight: 600 !important;
    font-size: 0.9rem !important;
}

@keyframes filkomModalIn {
    0% {
        opacity: 0;
        transform: scale(0.88);
    }
    60% {
        transform: scale(1.02);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.filkom-modal-in {
    animation: filkomModalIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards !important;
}

/* Mobile Adjustments for Toasts */
@media (max-width: 767.98px) {
    .swal2-container.swal2-top,
    .swal2-container.swal2-top-end {
        padding: 0.75rem !important;
    }

    .swal2-toast.filkom-swal-toast {
        min-width: 0 !important;
        width: 100% !important;
        max-width: 94vw !important;
        margin: 0 auto !important;
        padding: 0.75rem 1rem !important;
    }

    .filkom-toast-title {
        font-size: 0.88rem !important;
    }

    .filkom-toast-content {
        font-size: 0.76rem !important;
    }
}
