
:root {
    --ms-primary: #0072C6;
    --ms-primary-dark: #005a9e;
    --ms-sky: #0ea5e9;
    --ms-sky-dark: #0284c7;
    --ms-sky-light: #e0f2fe;
    --ms-sky-50: #f0f9ff;
    --ms-cyan: #06b6d4;
    --ms-gray-50: #fafafa;
    --ms-gray-100: #f5f5f5;
    --ms-gray-200: #e8e8e8;
    --ms-gray-400: #a0a0a0;
    --ms-gray-500: #6e6e6e;
    --ms-gray-700: #3b3b3b;
    --ms-gray-900: #1a1a1a;
}

/* Login page only (login.css is loaded solely on this page):
   make the content area fill the exact space between header and footer
   so the footer stays visible and no page scroll appears when it fits. */
main.main-content {
    display: flex;
    flex-direction: column;
}

main.main-content > .container-fluid {
    display: flex;
    flex-direction: column;
    flex: 1 0 auto;
    min-height: 0;
}

.design-a {
    flex: 1 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(180deg, #e0f4ff 0%, #bae6fd 30%, #7dd3fc 60%, #38bdf8 85%, #0ea5e9 100%);
    padding: 32px 24px;
    position: relative;
    overflow: hidden;
}

.da-wave {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 200px;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1440 200'%3E%3Cpath fill='%23ffffff' fill-opacity='0.4' d='M0,80L48,85C96,90,192,100,288,95C384,90,480,70,576,75C672,80,768,110,864,115C960,120,1056,100,1152,90C1248,80,1344,80,1392,80L1440,80L1440,200L0,200Z'/%3E%3C/svg%3E") no-repeat bottom;
    background-size: cover;
}

.da-cloud {
    position: absolute;
    left: 0;
    will-change: transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    animation: cloudDrift linear infinite;
    opacity: 0;
}

.da-cloud-1 { top: 12%; animation-duration: 50s; animation-delay: 0s; }
.da-cloud-2 { top: 28%; animation-duration: 65s; animation-delay: 4s; }
.da-cloud-3 { top: 6%; animation-duration: 55s; animation-delay: 9s; }

@keyframes cloudDrift {
    0% { transform: translate3d(-320px, 0, 0); opacity: 0; }
    3% { opacity: 1; }
    92% { opacity: 1; }
    100% { transform: translate3d(calc(100vw + 120px), 0, 0); opacity: 0; }
}

.da-card {
    position: relative;
    z-index: 2;
    max-width: 1000px;
    width: 100%;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255,255,255,0.9);
    border-radius: 28px;
    padding: 0;
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: stretch;
    box-shadow: 0 24px 80px rgba(0,100,180,0.12), 0 4px 16px rgba(0,0,0,0.04);
    overflow: hidden;
}

.da-image-box {
    overflow: hidden;
    height: 100%;
    min-height: 400px;
}

.da-image-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.da-content {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px 48px;
}

.da-badge {
    width: max-content;
    max-width: 100%;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(14,165,233,0.1);
    color: var(--ms-sky);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 18px;
}

.da-badge div {
    font-size: 12px;
    font-weight: 600;
    display: contents;
}

.da-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.2;
    color: var(--ms-gray-900);
    margin-bottom: 20px;
    letter-spacing: -0.3px;
}

.login_page_title {
    margin: 0;
}

.da-description {
    font-size: 14px;
    color: var(--ms-gray-500);
    line-height: 1.7;
    margin-bottom: 40px;
}

.welcome_text {
    max-width: 550px;
}

.da-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.da-btn {
    padding: 13px 32px;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    border: none;
    cursor: pointer;
}

.da-btn-primary {
    background: var(--ms-sky);
    color: #fff;
    box-shadow: 0 4px 16px rgba(14,165,233,0.3);
}

.da-btn-primary:hover {
    background: var(--ms-sky-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(14,165,233,0.4);
}

.da-btn-secondary {
    background: rgba(14,165,233,0.08);
    color: var(--ms-sky-dark);
    border: 1.5px solid rgba(14,165,233,0.2);
}

.da-btn-secondary:hover {
    background: rgba(14,165,233,0.15);
    transform: translateY(-2px);
    border-color: rgba(14,165,233,0.4);
    color: var(--ms-sky-dark);
}

.da-btn:focus {
    outline: 2px solid var(--ms-sky-dark);
    outline-offset: 2px;
}

.error_msg_section {
    margin-top: 20px;
    max-width: 550px;
}

#registrationModal .modal-body:focus {
    outline: 1px solid #000000;
}

/* Fit within one screen (no page scroll) on shorter viewport heights */
@media screen and (max-height: 800px) {
    .design-a {
        padding: 16px 24px;
    }

    .da-image-box {
        min-height: 300px;
    }

    .da-content {
        padding: 24px 40px;
    }

    .da-badge {
        margin-bottom: 12px;
    }

    .da-title {
        font-size: 32px;
        margin-bottom: 20px;
    }

    .da-description {
        margin-bottom: 40px;
    }
}

/* ===== Responsive ===== */
@media (max-width: 900px) {
    .da-card {
        grid-template-columns: 1fr;
        max-width: 520px;
    }

    .da-image-box {
        min-height: 220px;
        max-height: 260px;
    }

    .da-content {
        text-align: center;
        padding: 32px 28px;
    }

    .da-description {
        margin: 0 auto 36px;
    }

    .da-buttons {
        justify-content: center;
    }

    .da-badge {
        margin-left: auto;
        margin-right: auto;
    }
}

@media (max-width: 576px) {
    .da-title {
        font-size: 24px;
    }

    .design-a {
        padding: 24px 16px;
    }

    .da-content {
        padding: 24px 20px;
    }
}

/* Accessibility: Respect user's reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .da-cloud {
        animation: none !important;
        opacity: 0.7;
        transform: translate3d(30vw, 0, 0);
    }

    .da-cloud-2 { transform: translate3d(60vw, 0, 0); }
    .da-cloud-3 { transform: translate3d(80vw, 0, 0); }

    .da-btn {
        transition: none !important;
    }
}
