* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    overflow: hidden;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: url('/static/images/ideogram-v3.0_A_full_screen_cinematic_scene_of_hardworking_farmers_harvesting_ripe_coffee_bean-0.jpg') center center / cover no-repeat;
    height: 100vh;
    height: 100dvh;
}

.container {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    display: flex;
    justify-content: center;
    align-items: center;
}

.login-card {
    width: 100%;
    height: 100vh;
    height: 100dvh;
    background: transparent;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.header-section {
    background: transparent;
    text-align: center;
    padding: 15px 20px 12px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.header-top {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.btn-header {
    background: rgba(255,255,255,0.95);
    color: #000;
    text-decoration: none;
    padding: 10px 18px;
    border-radius: 25px;
    font-size: 13px;
    font-weight: 700;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
    transition: all 0.3s ease;
}

.btn-header:hover {
    background: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #000;
}

.main-title {
    font-size: 32px;
    font-weight: 700;
    font-style: italic;
    color: #000000;
    margin-bottom: 2px;
    line-height: 1;
    text-shadow: 0 1px 3px rgba(255,255,255,0.8);
}

.subtitle {
    font-size: 14px;
    font-weight: 600;
    color: #000000;
    text-shadow: 0 1px 3px rgba(255,255,255,0.8);
}

.messages {
    list-style: none;
    margin: 0 0 15px 0;
    padding: 0;
}

.messages li {
    padding: 10px 14px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
}

.messages .error {
    background: #FFE5E5;
    color: #C00;
}

.messages .success {
    background: #E5FFE5;
    color: #070;
}

.form-container {
    background: #FFFFFF;
    border-radius: 30px 30px 0 0;
    padding: 25px 25px 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.form-title {
    font-size: 20px;
    font-weight: 700;
    color: #000000;
    margin-bottom: 6px;
    text-align: center;
}

.form-subtitle {
    font-size: 11px;
    color: #888888;
    text-align: center;
    margin-bottom: 20px;
    line-height: 1.4;
    padding: 0 5px;
}

#loginForm {
    flex: 1;
    display: flex;
    flex-direction: column;
}

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

.form-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #000000;
    margin-bottom: 6px;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #F5F5F5;
    border-radius: 10px;
    padding: 0 12px;
    height: 46px;
    border: 1px solid transparent;
    transition: all 0.3s ease;
}

.input-wrapper:focus-within {
    border-color: #F5B942;
    background: #FFFFFF;
    box-shadow: 0 0 0 2px rgba(245, 185, 66, 0.2);
}

.input-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 8px;
    flex-shrink: 0;
}

.toggle-password {
    cursor: pointer;
}

.country-code {
    font-size: 13px;
    font-weight: 600;
    color: #000000;
    margin-right: 8px;
    padding-right: 8px;
    border-right: 2px solid #DDDDDD;
    flex-shrink: 0;
}

.input-wrapper input {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 13px;
    color: #000000;
    outline: none;
    padding: 0;
}

.input-wrapper input::placeholder {
    color: #999999;
}

.btn-primary {
    width: 100%;
    background: #F5B942;
    border: none;
    border-radius: 25px;
    padding: 14px;
    font-size: 15px;
    font-weight: 700;
    color: #000000;
    cursor: pointer;
    margin-top: 8px;
    margin-bottom: 10px;
    transition: all 0.3s ease;
}

.btn-primary:hover {
    background: #E5A932;
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(245, 185, 66, 0.5);
}

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

.btn-secondary {
    width: 100%;
    background: transparent;
    border: none;
    padding: 8px;
    font-size: 14px;
    font-weight: 600;
    color: #000000;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    color: #F5B942;
}

/* Desktop/Tablet styles */
@media (min-width: 481px) {
    html, body {
        overflow: auto;
    }

    body {
        background: url('/static/images/lucid-origin_A_futuristic_robot_standing_in_front_of_a_glowing_financial_technology_backgroun-0.jpg') center center / cover no-repeat fixed;
        padding: 20px;
        height: auto;
        min-height: 100vh;
    }

    .container {
        max-width: 400px;
        height: auto;
        min-height: auto;
        margin: 0 auto;
    }

    .login-card {
        min-height: auto;
        height: auto;
        border-radius: 30px;
        border: 4px solid #000000;
        overflow: hidden;
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.2);
    }

    .header-section {
        padding: 30px 30px 20px;
    }

    .logo {
        width: 80px;
        height: 80px;
        margin-bottom: 12px;
    }

    .main-title {
        font-size: 42px;
    }

    .subtitle {
        font-size: 16px;
    }

    .form-container {
        border-radius: 25px 25px 0 0;
        margin-top: -15px;
        padding: 30px 30px 35px;
    }

    .form-title {
        font-size: 24px;
    }

    .form-subtitle {
        font-size: 12px;
        margin-bottom: 25px;
    }

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

    .form-group label {
        font-size: 14px;
        margin-bottom: 8px;
    }

    .input-wrapper {
        height: 52px;
        padding: 0 16px;
    }
}

/* Small phones */
@media (max-height: 600px) {
    .header-section {
        padding: 10px 20px 8px;
    }

    .logo {
        width: 50px;
        height: 50px;
        margin-bottom: 5px;
    }

    .main-title {
        font-size: 26px;
    }

    .subtitle {
        font-size: 12px;
    }

    .form-container {
        padding: 18px 20px 15px;
    }

    .form-title {
        font-size: 18px;
        margin-bottom: 4px;
    }

    .form-subtitle {
        font-size: 10px;
        margin-bottom: 12px;
    }

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

    .form-group label {
        font-size: 11px;
        margin-bottom: 4px;
    }

    .input-wrapper {
        height: 40px;
    }

    .btn-primary {
        padding: 12px;
        font-size: 14px;
    }

    .btn-secondary {
        padding: 6px;
        font-size: 12px;
    }
}
