/* 
 * PMO ENNOVA THEME - Silver Dark Theme
 * Author: PMO System
 * Version: 1.0
 */

/* ===== ROOT VARIABLES ===== */
:root {
    /* Silver Dark Theme Colors */
    --primary-silver: #7d8b9a;
    --dark-silver: #5a6572;
    --light-silver: #a8b5c2;
    --bg-silver: #f8f9fa;
    --card-silver: #ffffff;
    --text-dark: #2c3e50;
    --text-muted: #6c757d;
    --border-color: #e0e0e0;
    --shadow-color: rgba(90, 101, 114, 0.1);
    
    /* Accent Colors */
    --accent-blue: #3498db;
    --accent-green: #2ecc71;
    --accent-red: #e74c3c;
    --accent-yellow: #f39c12;
    --accent-purple: #9b59b6;
}

/* ===== DISABLE ZOOM ===== */
html {
    touch-action: manipulation;
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
}

body {
    zoom: 1;
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
    max-zoom: 1;
    min-zoom: 1;
    user-zoom: fixed;
}

/* ===== NAVBAR STYLING ===== */
.navbar-ennova {
    background: linear-gradient(135deg, var(--dark-silver) 0%, #4a5568 100%) !important;
    border-bottom: 3px solid var(--light-silver) !important;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    padding: 0.5rem 0;
}

.navbar-brand {
    display: flex !important;
    align-items: center !important;
    padding: 0.5rem 0 !important;
}

.navbar-logo {
    height: 40px;
    width: auto;
    margin-right: 12px;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

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

.brand-text {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 1.4rem;
    font-weight: 600;
    color: white !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    letter-spacing: 0.5px;
}

.brand-subtext {
    font-size: 0.85rem;
    opacity: 0.9;
    font-weight: 300;
}

/* ===== CARD STYLING ===== */
.card {
    border: none !important;
    border-radius: 12px !important;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    box-shadow: 0 4px 6px var(--shadow-color);
    background-color: var(--card-silver);
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 15px var(--shadow-color);
}

.card-header {
    background: linear-gradient(to right, var(--primary-silver), var(--dark-silver)) !important;
    color: white !important;
    font-weight: 600;
    border-bottom: none !important;
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
}

.card-body {
    padding: 1.5rem;
}

/* ===== BUTTON STYLING ===== */
.btn {
    border-radius: 8px !important;
    font-weight: 500;
    transition: all 0.3s ease;
    border: none;
    padding: 0.5rem 1.5rem;
}

.btn-primary {
    background: linear-gradient(to right, var(--dark-silver), #6c757d) !important;
    border: none !important;
    box-shadow: 0 3px 5px rgba(90, 101, 114, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(to right, #6c757d, var(--dark-silver)) !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 8px rgba(90, 101, 114, 0.4);
}

.btn-outline-primary {
    border: 2px solid var(--dark-silver) !important;
    color: var(--dark-silver) !important;
    background: transparent !important;
}

.btn-outline-primary:hover {
    background: var(--dark-silver) !important;
    color: white !important;
    border-color: var(--dark-silver) !important;
}

/* ===== BADGE STYLING ===== */
.badge {
    border-radius: 20px;
    padding: 0.4em 0.9em;
    font-weight: 500;
}

.badge.bg-primary {
    background: linear-gradient(to right, var(--primary-silver), var(--accent-blue)) !important;
}

/* ===== LIST GROUP STYLING ===== */
.list-group-item {
    border-left: none;
    border-right: none;
    border-color: var(--border-color);
    padding: 1rem 1.25rem;
    transition: all 0.2s ease;
}

.list-group-item:first-child {
    border-top: none;
}

.list-group-item:last-child {
    border-bottom: none;
}

.list-group-item:hover {
    background-color: rgba(122, 139, 154, 0.08);
    border-left: 4px solid var(--primary-silver);
    padding-left: 1.5rem;
}

/* ===== TYPOGRAPHY ===== */
body {
    background-color: var(--bg-silver);
    color: var(--text-dark);
    font-family: 'Segoe UI', 'Roboto', sans-serif;
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
    color: var(--dark-silver);
    font-weight: 600;
}

.text-muted {
    color: var(--text-muted) !important;
}

.display-6 {
    color: var(--dark-silver);
    font-weight: 700;
}

/* ===== STATS CARDS SPECIAL ===== */
.card .display-6 {
    font-size: 2.5rem;
    background: linear-gradient(to right, var(--dark-silver), var(--primary-silver));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ===== RESPONSIVE ADJUSTMENTS ===== */
@media (max-width: 768px) {
    .navbar-brand {
        padding-left: 15px !important;
    }
    
    .navbar-logo {
        height: 35px;
    }
    
    .brand-text {
        font-size: 1.2rem;
    }
    
    .card {
        margin-bottom: 1rem;
    }
    
    .display-6 {
        font-size: 2rem;
    }
    
    /* Prevent zoom on mobile */
    input, select, textarea {
        font-size: 16px !important;
    }
}

@media (max-width: 576px) {
    .navbar-logo {
        height: 30px;
    }
    
    .brand-text {
        font-size: 1rem;
    }
    
    .card-header {
        padding: 0.75rem 1rem;
        font-size: 1rem;
    }
}

/* ===== UTILITY CLASSES ===== */
.rounded-ennova {
    border-radius: 12px;
}

.shadow-ennova {
    box-shadow: 0 4px 15px var(--shadow-color);
}

.border-ennova {
    border: 1px solid var(--border-color);
}

/* ===== FOOTER STYLING ===== */
.footer-ennova {
    background-color: var(--dark-silver);
    color: white;
    padding: 1.5rem 0;
    margin-top: 2rem;
    border-top: 3px solid var(--light-silver);
}

/* ===== SCROLLBAR STYLING ===== */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-silver);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-silver);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--dark-silver);
}

/* ===== FORM ELEMENTS ===== */
.form-control, .form-select {
    border-radius: 8px;
    border: 1px solid var(--border-color);
    padding: 0.6rem 1rem;
    transition: all 0.3s ease;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary-silver);
    box-shadow: 0 0 0 0.25rem rgba(122, 139, 154, 0.25);
}

/* ===== TABLE STYLING ===== */
.table {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: rgba(122, 139, 154, 0.05);
    --bs-table-hover-bg: rgba(122, 139, 154, 0.1);
}

.table thead th {
    background-color: var(--dark-silver);
    color: white;
    border: none;
    font-weight: 600;
    padding: 1rem;
}

.table tbody td {
    padding: 1rem;
    border-color: var(--border-color);
}

/* ===== ANIMATIONS ===== */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

/* Background styling */
        .login-page {
            background: linear-gradient(135deg, rgba(90, 101, 114, 0.9) 0%, rgba(44, 62, 80, 0.9) 100%),
                        url('https://pmo.ennova.com.my/img/login-bg.jpg') center/cover no-repeat fixed;
            min-height: 100vh;
            position: relative;
        }

        /* Fallback background jika gambar tak load */
        .login-page::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            right: 0;
            bottom: 0;
            background: 
                radial-gradient(circle at 20% 80%, rgba(122, 139, 154, 0.3) 0%, transparent 50%),
                radial-gradient(circle at 80% 20%, rgba(52, 152, 219, 0.3) 0%, transparent 50%),
                linear-gradient(45deg, #2c3e50 0%, #34495e 100%);
            z-index: -1;
        }

        /* Logo styling */
        .login-logo {
            text-align: center;
            margin-bottom: 2rem;
        }

        .login-logo img {
            height: 80px;
            width: auto;
            margin-bottom: 1rem;
            filter: brightness(0) invert(1);
            transition: transform 0.3s ease;
        }

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

        .login-logo h1 {
            color: white;
            font-size: 2.2rem;
            font-weight: 700;
            margin-bottom: 0.5rem;
            text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
            letter-spacing: 1px;
        }

        .login-logo p {
            color: rgba(255, 255, 255, 0.8);
            font-size: 1rem;
            font-weight: 300;
            letter-spacing: 0.5px;
        }

        /* Login card styling */
        .login-card {
            background: rgba(255, 255, 255, 0.95);
            backdrop-filter: blur(10px);
            border-radius: 20px;
            padding: 2.5rem;
            box-shadow: 
                0 15px 35px rgba(0, 0, 0, 0.2),
                0 5px 15px rgba(0, 0, 0, 0.1),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
            border: 1px solid rgba(255, 255, 255, 0.2);
            transform: translateY(0);
            transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
        }

        .login-card:hover {
            transform: translateY(-5px);
            box-shadow: 
                0 20px 40px rgba(0, 0, 0, 0.25),
                0 10px 20px rgba(0, 0, 0, 0.15),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
        }

        /* Form styling */
        .form-label {
            color: #2c3e50;
            font-weight: 600;
            margin-bottom: 0.5rem;
            font-size: 0.95rem;
        }

        .form-control-lg {
            padding: 0.85rem 1.25rem;
            border-radius: 12px;
            border: 2px solid #e0e0e0;
            background: rgba(255, 255, 255, 0.9);
            transition: all 0.3s ease;
            font-size: 1rem;
        }

        .form-control-lg:focus {
            border-color: #5a6572;
            box-shadow: 0 0 0 0.25rem rgba(90, 101, 114, 0.25);
            background: white;
        }

        /* Button styling */
        .btn-login {
            background: linear-gradient(135deg, #5a6572 0%, #2c3e50 100%);
            border: none;
            color: white;
            padding: 1rem 2rem;
            font-size: 1.1rem;
            font-weight: 600;
            border-radius: 12px;
            transition: all 0.3s ease;
            letter-spacing: 0.5px;
            text-transform: uppercase;
        }

        .btn-login:hover {
            background: linear-gradient(135deg, #4a5568 0%, #1a2530 100%);
            transform: translateY(-2px);
            box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
        }

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

        /* Language switcher */
        .lang-switcher {
            position: absolute;
            top: 20px;
            right: 20px;
            z-index: 1000;
        }

        .lang-btn {
            background: rgba(255, 255, 255, 0.15);
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 255, 255, 0.2);
            color: white;
            border-radius: 20px;
            padding: 0.5rem 1rem;
            transition: all 0.3s ease;
        }

        .lang-btn:hover {
            background: rgba(255, 255, 255, 0.25);
            transform: translateY(-2px);
        }

        /* Error alert */
        .alert-danger {
            background: rgba(231, 76, 60, 0.9);
            backdrop-filter: blur(10px);
            color: white;
            border: none;
            border-radius: 12px;
            padding: 1rem 1.5rem;
            margin-bottom: 1.5rem;
            box-shadow: 0 5px 15px rgba(231, 76, 60, 0.2);
        }

        /* Footer */
        .login-footer {
            color: rgba(255, 255, 255, 0.7);
            font-size: 0.9rem;
            margin-top: 2rem;
            text-align: center;
        }

        .login-footer a {
            color: rgba(255, 255, 255, 0.9);
            text-decoration: none;
            transition: color 0.3s ease;
        }

        .login-footer a:hover {
            color: white;
            text-decoration: underline;
        }

        /* Responsive adjustments */
        @media (max-width: 768px) {
            .login-page {
                padding: 20px;
            }
            
            .login-card {
                padding: 2rem;
            }
            
            .login-logo img {
                height: 60px;
            }
            
            .login-logo h1 {
                font-size: 1.8rem;
            }
            
            .lang-switcher {
                top: 10px;
                right: 10px;
            }
        }

        @media (max-width: 576px) {
            .login-card {
                padding: 1.5rem;
            }
            
            .login-logo h1 {
                font-size: 1.5rem;
            }
            
            .btn-login {
                padding: 0.85rem 1.5rem;
                font-size: 1rem;
            }
        }

        /* Animation for form */
        @keyframes fadeInUp {
            from {
                opacity: 0;
                transform: translateY(30px);
            }
            to {
                opacity: 1;
                transform: translateY(0);
            }
        }

        .login-card {
            animation: fadeInUp 0.6s ease-out;
        }

        /* Input icons */
        .input-group-icon {
            position: relative;
        }

        .input-group-icon i {
            position: absolute;
            left: 1rem;
            top: 50%;
            transform: translateY(-50%);
            color: #7d8b9a;
            z-index: 10;
        }

        .input-group-icon input {
            padding-left: 3rem;
        }