@import url('https://fonts.googleapis.com/css2?family=Urbanist:ital,wght@0,100..900;1,100..900&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Urbanist', sans-serif;
}

body {
    background: linear-gradient(90deg,rgba(0, 0, 255, 0.3) 0%, rgba(237, 237, 237, 1) 47%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
}

.login-form {
    display: flex;
    width: 80vh;
    flex-direction: column;
    justify-content: center;
    padding: 40px 120px;
    margin: 0 auto;
    margin-bottom: 10vh;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 10px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 
        0 8px 32px rgba(30, 58, 138, 0.15),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
    position: relative;
    z-index: 1;
    min-height: auto;
    height: auto;
}


.login-title {
    text-align: center;
    margin-top: 0;
    margin-bottom: 40px;
    font-size: 2.5rem;
    font-weight: 550;
    color: #104ffe;
    text-shadow: 0 2px 4px rgba(255, 255, 255, 0.5);
    letter-spacing: -0.02em;
    position: relative;
    z-index: 1;
    border-bottom: 2px solid #104ffe;
}

/* Style for input labels */
.login-form label {
    width: 100%;
    color: rgb(0, 0, 150);
}

.login-form label:first-of-type {
    margin-top: 0;
}

.login-form input {
    width: 100%;
    padding: 4px;
    margin-bottom: 5px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border: 1px solid rgb(0, 0, 150);
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    color: #100000;
    outline: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 
        0 2px 8px rgba(30, 58, 138, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.6);
    height: 28px;
}

.login-form input::placeholder {
    color: #64748b;
    font-weight: 400;
}

.login-form input:focus {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(59, 130, 246, 0.6);
    box-shadow: 
        0 4px 16px rgba(59, 130, 246, 0.15),
        0 0 0 3px rgba(59, 130, 246, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    transform: translateY(-1px);
}

.login-form p {
    margin: 15px 0;
    color: #1e3a8a;
    font-weight: 500;
    font-size: 0.95rem;
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.5);
}

.submit-button, 
.login-form button {
    width: 100%;
    padding: 16px 24px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 600;
    letter-spacing: 0.025em;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    margin-top: 10px;
    box-shadow: 
        0 4px 16px rgba(59, 130, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.submit-button::before,
.login-form button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.submit-button:hover,
.login-form button:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1e40af 100%);
    box-shadow: 
        0 6px 24px rgba(59, 130, 246, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.submit-button:hover::before,
.login-form button:hover::before {
    left: 100%;
}

.submit-button:active,
.login-form button:active {
    transform: translateY(0);
    box-shadow: 
        0 2px 8px rgba(59, 130, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

/* Enhanced focus states for accessibility */
.submit-button:focus,
.login-form button:focus {
    outline: none;
    box-shadow: 
        0 6px 24px rgba(59, 130, 246, 0.4),
        0 0 0 3px rgba(59, 130, 246, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

.register-form{
    width: 90vh !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0%;
}

.register-form>.full-name-form{
    display: flex;
    justify-content: space-between;
}

ul.errorlist {
    list-style-type: none;
    padding: 0;
    margin: 0 0 10px 0;
    color: #dc2626;
    font-weight: 700;
    text-align: left;
    opacity: 0.7;
}

/* Help text that is a list, e.g. the password rules */
.login-form .field-help {
    display: block;
    text-align: left;
    margin-bottom: 10px;
}

.login-form .field-help ul {
    padding-left: 1.2rem;
    margin-top: 4px;
}

/* Responsive adjustments */
/* Responsive adjustments - improved for multiple breakpoints and accessibility */

/* Very large screens: constrain width so form doesn't become too wide */
@media (min-width: 1200px) {
    .login-form {
        width: min(720px, 60vw);
        padding: 56px 120px;
        border-radius: 16px;
        box-shadow:
            0 12px 48px rgba(30, 58, 138, 0.12),
            inset 0 1px 0 rgba(255, 255, 255, 0.45);
    }

    .login-title {
        font-size: clamp(2.25rem, 2.5vw, 3rem);
    }
}

/* Desktop / small laptop */
@media (max-width: 1199px) and (min-width: 721px) {
    .login-form {
        width: min(680px, 85vw);
        padding: 44px 80px;
        border-radius: 14px;
    }

    .login-title {
        font-size: clamp(2rem, 2.2vw, 2.5rem);
    }

    .login-form input {
        height: 36px;
        font-size: 0.95rem;
    }
}

/* Tablet and narrow laptops */
@media (max-width: 720px) and (min-width: 481px) {
    .login-form {
        width: min(640px, 94vw);
        margin: 2vh auto;
        padding: 32px 28px;
        box-shadow:
            0 10px 36px rgba(30, 58, 138, 0.10),
            inset 0 1px 0 rgba(255, 255, 255, 0.45);
    }

    .login-form label {
        font-size: 1rem;
    }

    .login-form input {
        padding: 10px 14px;
        font-size: 1rem;
        height: 44px;
    }

    .submit-button,
    .login-form button {
        padding: 14px 20px;
        font-size: 1rem;
        border-radius: 12px;
    }
}

/* Mobile (small phones) */
@media (max-width: 480px) {
    body {
        background: linear-gradient(180deg, rgba(0, 0, 255, 0.18) 0%, rgba(237, 237, 237, 1) 60%);
    }

    .login-title {
        font-size: 1.6rem;
        margin-bottom: 18px;
        border-bottom: 1px solid rgba(16, 79, 254, 0.15);
        padding-bottom: 6px;
    }

    .login-form {
        width: calc(100vw - 32px);
        max-width: 420px;
        padding: 22px 16px;
        margin: 4vh auto;
        border-radius: 12px;
        backdrop-filter: blur(12px);
    }

    .login-form label {
        display: block;
        text-align: left;
        margin-bottom: 6px;
        color: rgb(0, 0, 120);
    }

    .login-form input {
        width: 100%;
        padding: 12px 14px;
        height: 48px;
        font-size: 1rem;
        border-radius: 10px;
    }

    .submit-button,
    .login-form button {
        width: 100%;
        padding: 16px 18px;
        font-size: 1.05rem;
        border-radius: 12px;
        margin-top: 12px;
    }

    .login-form p,
    ul.errorlist {
        text-align: left;
        padding-left: 4px;
    }
}

/* Landscape small devices: use a compact layout */
@media (max-height: 420px) and (orientation: landscape) {
    .login-form {
        padding: 18px 26px;
        margin: 2vh auto;
    }

    .login-title {
        font-size: 1.5rem;
        margin-bottom: 12px;
    }

    .login-form input {
        height: 40px;
    }

    .submit-button,
    .login-form button {
        padding: 12px 16px;
    }
}

/* Respect users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    .login-form input,
    .submit-button,
    .login-form button {
        transition: none !important;
        transform: none !important;
    }

    .submit-button::before,
    .login-form button::before {
        transition: none !important;
    }
}

/* Divider between credentials form and social login */
.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 15px 0;
    color: #64748b;
    font-weight: 500;
    font-size: 0.9rem;
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    border-bottom: 1px solid rgba(0, 0, 150, 0.2);
}

.auth-divider:not(:empty)::before {
    margin-right: .75em;
}

.auth-divider:not(:empty)::after {
    margin-left: .75em;
}

/* Google Sign-In Button styling */
.btn-google {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 12px 24px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 150, 0.2);
    background-color: #ffffff;
    color: #1e3a8a;
    font-size: 1rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(30, 58, 138, 0.05);
}

.btn-google:hover {
    background-color: #f8fafc;
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.1);
    color: #1d4ed8;
    transform: translateY(-1px);
}

.btn-google:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(30, 58, 138, 0.05);
}

.google-icon {
    width: 20px;
    height: 20px;
    object-fit: contain;
}