/* Custom Login Styles - DelmanSuper Brand Colors */
:root {
    --delman-blue: #2563eb;
    --delman-blue-light: #3b82f6;
    --delman-blue-dark: #1d4ed8;
    --delman-orange: #f97316;
    --delman-orange-light: #fb923c;
    --delman-orange-dark: #ea580c;
    --delman-purple: #8b5cf6;
    --delman-purple-light: #a78bfa;
    --delman-purple-dark: #7c3aed;
    --delman-gray: #6b7280;
    --delman-gray-light: #9ca3af;
    --delman-gray-dark: #374151;
}

/* Background dengan gradient yang sesuai brand */
body {
    background: linear-gradient(135deg, 
        rgba(37, 99, 235, 0.1) 0%, 
        rgba(139, 92, 246, 0.1) 25%, 
        rgba(249, 115, 22, 0.1) 50%, 
        rgba(37, 99, 235, 0.1) 75%, 
        rgba(139, 92, 246, 0.1) 100%);
    min-height: 100vh;
    position: relative;
}

/* Background pattern dengan elemen geometris */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(circle at 20% 80%, rgba(37, 99, 235, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(249, 115, 22, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(139, 92, 246, 0.1) 0%, transparent 50%);
    pointer-events: none;
}

/* Container utama */
.authentication-wrapper {
    position: relative;
    z-index: 1;
}

/* Card login dengan styling yang lebih menarik */
.card {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 
        0 20px 25px -5px rgba(0, 0, 0, 0.1),
        0 10px 10px -5px rgba(0, 0, 0, 0.04),
        0 0 0 1px rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    overflow: hidden;
}

/* Header card dengan gradient */
.card-body {
    padding: 2.5rem;
    position: relative;
}

.card-body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, 
        var(--delman-blue) 0%, 
        var(--delman-purple) 50%, 
        var(--delman-orange) 100%);
}

/* Logo styling */
.card-img {
    max-width: 200px;
    height: auto;
    margin: 0 auto 1.5rem;
    display: block;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

/* Title styling */
h4 {
    color: var(--delman-gray-dark);
    font-weight: 700;
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
}

/* HR styling */
hr {
    border: none;
    height: 2px;
    background: linear-gradient(90deg, 
        var(--delman-blue) 0%, 
        var(--delman-purple) 50%, 
        var(--delman-orange) 100%);
    margin: 1.5rem 0;
    border-radius: 1px;
}

/* Form input styling */
.form-control {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 0.875rem 1rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
}

.form-control:focus {
    border-color: var(--delman-blue);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
    background: rgba(255, 255, 255, 1);
}

.form-control::placeholder {
    color: var(--delman-gray);
    font-weight: 400;
}

/* Input dengan icon */
.form-control-lg {
    padding: 1rem 1.25rem;
    font-size: 1.1rem;
}

/* Remember me styling */
.form-check-input {
    width: 1.25rem;
    height: 1.25rem;
    border-radius: 6px;
    border: 2px solid #d1d5db;
    transition: all 0.3s ease;
}

.form-check-input:checked {
    background-color: var(--delman-blue);
    border-color: var(--delman-blue);
}

.form-check-input:focus {
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-check-label {
    color: var(--delman-gray-dark);
    font-weight: 500;
    margin-left: 0.5rem;
}

/* Button styling */
.btn-primary {
    background: linear-gradient(135deg, 
        var(--delman-blue) 0%, 
        var(--delman-blue-light) 100%);
    border: none;
    border-radius: 12px;
    padding: 1rem 2rem;
    font-weight: 600;
    font-size: 1.1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, 
        var(--delman-blue-dark) 0%, 
        var(--delman-blue) 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(37, 99, 235, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
}

/* Error styling */
.invalid-feedback {
    color: #dc2626;
    font-weight: 500;
    margin-top: 0.5rem;
}

.form-control.is-invalid {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.1);
}

/* Responsive design */
@media (max-width: 768px) {
    .card-body {
        padding: 2rem 1.5rem;
    }
    
    .card-img {
        max-width: 150px;
        height: auto;
    }
    
    h4 {
        font-size: 1.25rem;
    }
    
    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }
    
    .form-control-lg {
        padding: 0.875rem 1rem;
        font-size: 1rem;
    }
}

@media (max-width: 576px) {
    .authentication-wrapper {
        padding: 1rem;
    }
    
    .card-body {
        padding: 1.5rem 1rem;
    }
    
    .card-img {
        max-width: 120px;
        height: auto;
    }
    
    h4 {
        font-size: 1.1rem;
    }
    
    .btn-lg {
        padding: 0.75rem 1.25rem;
        font-size: 0.95rem;
    }
    
    .form-control-lg {
        padding: 0.75rem 0.875rem;
        font-size: 0.95rem;
    }
    
    .input-group-text {
        padding: 0.75rem 0.875rem;
        font-size: 0.9rem;
    }
    
    #togglePassword {
        padding: 0.75rem 0.875rem;
        min-width: 45px;
    }
    
    #togglePassword i {
        font-size: 1rem;
    }
    
    .form-label {
        font-size: 0.85rem;
    }
}

@media (max-width: 480px) {
    .card-body {
        padding: 1.25rem 0.75rem;
    }
    
    .card-img {
        max-width: 100px;
        height: auto;
    }
    
    h4 {
        font-size: 1rem;
    }
    
    .btn-lg {
        padding: 0.625rem 1rem;
        font-size: 0.9rem;
    }
    
    .form-control-lg {
        padding: 0.625rem 0.75rem;
        font-size: 0.9rem;
    }
    
    .input-group-text {
        padding: 0.625rem 0.75rem;
        font-size: 0.85rem;
    }
    
    #togglePassword {
        padding: 0.625rem 0.75rem;
        min-width: 40px;
    }
    
    #togglePassword i {
        font-size: 0.9rem;
    }
    
    .form-label {
        font-size: 0.8rem;
    }
    
    small {
        font-size: 0.75rem;
    }
}

/* Landscape orientation untuk mobile */
@media (max-height: 600px) and (orientation: landscape) {
    .authentication-wrapper {
        padding: 0.5rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .card-img {
        max-width: 80px;
        height: auto;
        margin-bottom: 0.5rem;
    }
    
    h4 {
        font-size: 1rem;
        margin-bottom: 0.25rem;
    }
    
    .mb-4 {
        margin-bottom: 1rem !important;
    }
    
    .mt-4 {
        margin-top: 1rem !important;
    }
}

/* Animasi loading untuk button */
.btn-primary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Hover effects untuk card */
.card:hover {
    transform: translateY(-5px);
    box-shadow: 
        0 25px 50px -12px rgba(0, 0, 0, 0.15),
        0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Focus states untuk accessibility */
.form-control:focus,
.btn-primary:focus,
.form-check-input:focus {
    outline: none;
}

/* Input group styling */
.input-group-text {
    background: linear-gradient(135deg, var(--delman-blue) 0%, var(--delman-blue-light) 100%);
    border: 2px solid var(--delman-blue);
    color: white !important;
    font-weight: 600;
    border-radius: 12px 0 0 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 50px;
}

.input-group-text i {
    color: white !important;
    font-size: 1.1rem;
    display: block !important;
}

.input-group .form-control {
    border-radius: 0;
    border-left: none;
    border-right: none;
}

.input-group .form-control:first-child {
    border-radius: 12px 0 0 12px;
}

.input-group .form-control:last-child {
    border-radius: 0 12px 12px 0;
}

.input-group .form-control:focus {
    border-left: none;
    border-right: none;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

/* Password toggle button styling */
#togglePassword {
    background: linear-gradient(135deg, var(--delman-orange) 0%, var(--delman-orange-light) 100%);
    border: 2px solid var(--delman-orange);
    color: white;
    border-radius: 0 12px 12px 0;
    padding: 0.875rem 1rem;
    transition: all 0.3s ease;
    min-width: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

#togglePassword:hover {
    background: linear-gradient(135deg, var(--delman-orange-dark) 0%, var(--delman-orange) 100%);
    border-color: var(--delman-orange-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(249, 115, 22, 0.3);
}

#togglePassword:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(249, 115, 22, 0.2);
}

#togglePassword i {
    color: white !important;
    font-size: 1.1rem;
    display: block !important;
}

#togglePassword:focus {
    outline: 2px solid var(--delman-orange);
    outline-offset: 2px;
}

/* Form label styling */
.form-label {
    color: var(--delman-gray-dark);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

/* Text muted styling */
.text-muted {
    color: var(--delman-gray) !important;
}

/* Border top styling */
.border-top {
    border-color: rgba(37, 99, 235, 0.1) !important;
}

/* Icon styling dalam button */
.btn i {
    font-size: 1rem;
}

/* Small text styling */
small {
    font-size: 0.8rem;
    font-weight: 500;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

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

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

/* Loading animation untuk button */
@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.7);
    }
    70% {
        box-shadow: 0 0 0 10px rgba(37, 99, 235, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 99, 235, 0);
    }
}

.btn-primary:focus {
    animation: pulse 2s infinite;
}

/* Enhanced card hover effect */
.card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 
        0 32px 64px -12px rgba(0, 0, 0, 0.25),
        0 0 0 1px rgba(255, 255, 255, 0.1);
}

/* Form validation styling */
.was-validated .form-control:valid {
    border-color: #10b981;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 8 8'%3e%3cpath fill='%2310b981' d='m2.3 6.73.94-.94 1.88 1.88 3.77-3.77.94.94L4.12 9.55z'/%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right calc(0.375em + 0.1875rem) center;
    background-size: calc(0.75em + 0.375rem) calc(0.75em + 0.375rem);
}

/* Enhanced focus states */
.form-control:focus,
.btn:focus,
.form-check-input:focus {
    outline: 2px solid var(--delman-blue);
    outline-offset: 2px;
}

/* Icon visibility fixes */
.ti {
    font-family: 'tabler-icons' !important;
    font-style: normal !important;
    font-weight: normal !important;
    font-variant: normal !important;
    text-transform: none !important;
    line-height: 1 !important;
    -webkit-font-smoothing: antialiased !important;
    -moz-osx-font-smoothing: grayscale !important;
}

/* Ensure all icons are visible */
.input-group-text i,
#togglePassword i,
.btn i {
    display: inline-block !important;
    vertical-align: middle !important;
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .card,
    .btn,
    .form-control {
        transition: none;
    }
    
    .btn-primary:focus {
        animation: none;
    }
}
