/* ============================================
   DNAMIS Login Page Styles
   ============================================ */

/* Particles.js Container */
#particles-js {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
}

/* Login Container */
.login-container {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    z-index: 1;
}

.login-box {
    display: flex;
    width: 100%;
    max-width: 1400px;
    min-height: 700px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 24px;
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.37);
    padding: 30px;
    gap: 30px;
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Left Column - Image Section */
.login-image {
    flex: 1;
    position: relative;
    background: rgba(47, 67, 88, 0.4);
    border-radius: 16px;
    padding: 40px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 640px;
    backdrop-filter: blur(10px) saturate(150%);
    -webkit-backdrop-filter: blur(10px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.1);
}

.back-link {
    position: absolute;
    top: 20px;
    left: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
    color: #F7E3A1;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    z-index: 10;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.back-link:hover {
    color: #fff;
    transform: translateX(-5px);
}

.back-link svg {
    width: 16px;
    height: 16px;
}

.image-container {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    margin: 60px 0 40px;
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
}

.slide.active {
    opacity: 1;
}

.slide-svg {
    width: 100%;
    height: 100%;
    max-width: 500px;
    max-height: 400px;
}

/* SVG Animations */
.svg-group {
    animation: fadeIn 0.8s ease-in;
}

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

.person-animation {
    animation: float 3s ease-in-out infinite;
}

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

.card-animation {
    animation: slideIn 0.6s ease-out forwards;
    opacity: 0;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.node-animation {
    animation: scaleIn 0.5s ease-out forwards;
    opacity: 0;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.pulse-animation {
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.7;
        transform: scale(1.1);
    }
}

.line-draw {
    animation: drawLine 1s ease-out forwards;
    opacity: 0;
}

@keyframes drawLine {
    from {
        opacity: 0;
        stroke-dasharray: 1000;
        stroke-dashoffset: 1000;
    }
    to {
        opacity: 1;
        stroke-dashoffset: 0;
    }
}

.progress-animation {
    animation: progressFill 1.5s ease-out forwards;
    opacity: 0;
}

@keyframes progressFill {
    from {
        opacity: 0;
        transform: scaleX(0);
        transform-origin: left;
    }
    to {
        opacity: 1;
        transform: scaleX(1);
    }
}

.image-caption {
    text-align: center;
    color: #F7E3A1;
    margin-bottom: 20px;
}

.image-caption h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    color: #F7E3A1;
}

.image-caption p {
    font-size: 14px;
    opacity: 0.9;
    color: #F7E3A1;
}

.slide-indicators {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(247, 227, 161, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.indicator.active {
    background: #F7E3A1;
    width: 30px;
    border-radius: 5px;
}

/* Right Column - Form Section */
.login-form {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 50px 40px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 16px;
    backdrop-filter: blur(12px) saturate(150%);
    -webkit-backdrop-filter: blur(12px) saturate(150%);
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.05);
    min-height: 640px;
}

.login-form-container {
    width: 100%;
    max-width: 400px;
}

.logo-container {
    text-align: center;
    margin-bottom: 30px;
}

.logo-container img {
    max-width: 100%;
    height: auto;
}

.login-header {
    margin-bottom: 30px;
}

.login-header h1 {
    font-size: 36px;
    font-weight: 800;
    color: #2F4358;
    margin-bottom: 8px;
    letter-spacing: -0.5px;
}

.login-header h5 {
    font-size: 14px;
    color: #666;
    font-weight: 400;
    margin: 0;
}

/* Error Alert */
#errorContainer {
    margin-bottom: 20px;
}

.error-alert {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: #fee;
    border-left: 4px solid #e74c3c;
    border-radius: 6px;
    color: #c0392b;
    font-size: 14px;
    position: relative;
    animation: slideInDown 0.3s ease-out;
}

@keyframes slideInDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.error-alert.animate-slide-in {
    animation: slideInDown 0.3s ease-out;
}

.error-alert.fade-out {
    animation: fadeOut 0.5s ease-out forwards;
}

@keyframes fadeOut {
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

.error-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.error-message {
    flex: 1;
}

.error-close {
    background: none;
    border: none;
    color: #c0392b;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.error-close:hover {
    transform: scale(1.1);
}

/* Form Styles */
.theme-form {
    width: 100%;
}

.form-group {
    margin-bottom: 24px;
}

.input-icon-container {
    position: relative;
}

.input-icon-container input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}

.input-icon-container input:focus {
    outline: none;
    border-color: rgba(47, 67, 88, 0.5);
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 0 0 3px rgba(47, 67, 88, 0.1);
}

.input-icon-container input.is-invalid {
    border-color: #e74c3c;
}

.input-icon-container input.is-invalid:focus {
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.password-field {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #2F4358;
}

.password-toggle i {
    font-size: 18px;
}

.checkbox-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
}

.remember-me-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 26px;
}

.remember-me-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.remember-me-switch .slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 26px;
}

.remember-me-switch .slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.remember-me-switch input:checked + .slider {
    background-color: #2F4358;
}

.remember-me-switch input:checked + .slider:before {
    transform: translateX(24px);
}

.remember-text {
    font-size: 14px;
    color: #666;
    user-select: none;
}

.login-btn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, #2F4358 0%, #1a1a2e 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.login-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(47, 67, 88, 0.3);
}

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

.login-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.btn-text {
    display: inline-block;
}

.btn-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-loader .spinner-border-sm {
    width: 16px;
    height: 16px;
    border-width: 2px;
}

/* Responsive Design */
@media (max-width: 992px) {
    .login-box {
        flex-direction: column;
        max-width: 600px;
        padding: 25px;
        gap: 25px;
        min-height: auto;
    }

    .login-image {
        min-height: 400px;
        padding: 30px 20px;
    }

    .login-form {
        padding: 40px 30px;
        min-height: auto;
    }

    .image-container {
        margin: 40px 0 30px;
    }

    .slide-svg {
        max-width: 400px;
        max-height: 300px;
    }
}

@media (max-width: 768px) {
    .login-container {
        padding: 15px;
    }

    .login-image {
        display: none;
    }

    .login-box {
        max-width: 100%;
        border-radius: 20px;
        padding: 20px;
        min-height: auto;
        background: rgba(255, 255, 255, 0.1);
        backdrop-filter: blur(20px) saturate(180%);
        -webkit-backdrop-filter: blur(20px) saturate(180%);
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    .login-form {
        width: 100%;
        padding: 30px 20px;
        min-height: auto;
        background: rgba(255, 255, 255, 0.7);
        backdrop-filter: blur(12px) saturate(150%);
        -webkit-backdrop-filter: blur(12px) saturate(150%);
        border: 1px solid rgba(255, 255, 255, 0.2);
    }

    .login-header h1 {
        font-size: 28px;
    }
}

@media (max-width: 480px) {
    .login-header h1 {
        font-size: 24px;
    }

    .form-group {
        margin-bottom: 20px;
    }

    .input-icon-container input {
        padding: 12px 14px;
        font-size: 14px;
    }

    .login-btn {
        padding: 12px;
        font-size: 15px;
    }
}

/* Utility Classes */
.d-none {
    display: none !important;
}

.text-center {
    text-align: center;
}

.mb-3 {
    margin-bottom: 1rem;
}

.mb-0 {
    margin-bottom: 0;
}

