/* ================== Base Styles ================== */
body {
    font-family: Arial, sans-serif;
    background-color: #fff;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    box-sizing: border-box;
}

/* ================== HEADER ================== */
.top-header {
    height: 90px;
    background-color: #fff;
    border-bottom: 1px solid #eee;
    display: flex;
    align-items: center;
    padding: 0 15px;
    box-sizing: border-box;
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 10;
}

/* Logo */
.logo img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

/* ================== MAIN ================== */
.main-container {
    flex: 1;
    /* Allow main container to take available space */
    display: flex;
    justify-content: center;
    align-items: flex-start;
    padding-top: 100px;
    /* Space for the fixed header */
    padding-bottom: 130px;
    /* Space for the fixed footer */
    overflow-y: auto;
    /* Enable vertical scrolling */
    box-sizing: border-box;
}

/* Login container */
.signup-container {
    width: 95%;
    max-width: 600px;
    padding: 20px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    box-sizing: border-box;
}

/* ================== TYPOGRAPHY ================== */
h1 {
    font-size: 26px;
    text-align: center;
    margin-bottom: 20px;
}

.helper-text {
    font-size: 14px;
    color: #555;
    margin-bottom: 20px;
}

/* ================== FORM ================== */
/* Form group */
.form-group {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

.form-group label {
    margin-bottom: 5px;
    color: #333;
}

.form-group input,
.form-group select {
    background: white;
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
    outline: none;
}

.form-group input:focus,
.form-group input:focus {
    border-color: #0693e3;
}

/* Label row for email + link */
.label-row {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 5px;
}

/* Links */
#login-instead {
	font-size: 14px;
	color: #333;
	margin-bottom: 5px;
	cursor: pointer;
}

#login-instead:hover {
	color: #0693e3;
}

/* DATE INPUT */
/* ================== DATE INPUT FIX ================== */
.date-wrapper {
    position: relative;
    display: inline-block;
}

/* Input styling */
.date-wrapper input[type="date"] {
    width: 100%;
    padding-right: 40px;
    /* space for custom arrow */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    box-sizing: border-box;
    cursor: pointer;
}

/* Chrome / Safari / Edge: hide native arrow visually but keep it clickable */
.date-wrapper input[type="date"]::-webkit-inner-spin-button,
.date-wrapper input[type="date"]::-webkit-clear-button {
    display: none;
}

.date-wrapper input[type="date"]::-webkit-calendar-picker-indicator {
    opacity: 0;
    /* hide it visually */
    position: absolute;
    /* keep clickable area */
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    cursor: pointer;
}

/* Firefox: hide native arrow */
.date-wrapper input[type="date"]::-moz-calendar-picker-indicator {
    color: transparent;
    /* hides arrow but keeps it clickable */
    cursor: pointer;
}

/* Custom arrow */
.date-arrow {
    position: absolute;
    margin-right: 3px;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    pointer-events: none;
    /* click passes through */
    background-image: url("data:image/svg+xml,%3Csvg fill='none' stroke='%23666' stroke-width='2' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}


/* Security question select dropdown */
.form-group select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg fill='none' stroke='%23666' stroke-width='2' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 40px;
}


/* ================== PASSWORD ================== */
.password-container {
    position: relative;
}

#password,
#confirmPassword {
    padding-right: 48px;
    /* space for Show button */
}

/* Toggle password visibility button */
.togglePassword {
    position: absolute;
    right: 12px;
    /* Original far-right position */
    top: 50%;
    transform: translateY(-50%);
    /* Vertically centered */
    background: none;
    border: none;
    cursor: pointer;
    font-size: 13px;
    color: #555;
}

.togglePassword:hover {
    color: #0693e3;
}

.togglePassword:focus {
    outline: none;
}

/* ================== MESSAGES ================== */
.error-msg {
    color: red;
    font-size: 13px;
    margin-top: 6px;
    display: none;
}

.success-msg {
    color: #6da300;
    font-size: 13px;
    margin-top: 6px;
    display: none;
}

.closed-msg {
    color: #cc8800;
    font-size: 13px;
    margin-top: 6px;
    display: none;
}

/* ================== BUTTON ================== */
.button-group {
    margin-top: 20px;
    display: flex;
    gap: 10px;
}

.signup-btn {
    background-color: #000;
    color: #fff;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    flex: 1;
}

.signup-btn:hover {
    background-color: #222;
}

/* ================== FOOTER ================== */
/* ================================
   FOOTER / BOTTOM BAR
================================ */
/* Footer / Bottom Bar */
.bottom-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #fff;
    border-top: 1px solid #eee;
    z-index: 30;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: 0 14px;
    height: 60px;
    box-sizing: border-box;
}

.footer-text {
    font-size: 14px;
    color: #666;
    white-space: nowrap;
}

.language-container select {
    padding: 6px;
    font-size: 14px;
}

html,
body {
    height: 100%;
    overflow: auto;
}

/* ================== RESPONSIVE ================== */
@media (max-width: 768px) {

    html,
    body {
        height: 100%;
        overflow: auto;
        /* Ensure scrolling is enabled */
    }

    .signup-container {
        width: 98%;
        padding: 15px;
        margin-top: 0;
        /* Remove the previous margin-top */
    }

    .main-container {
        overflow-y: auto;
        flex: 1;
        padding-top: 80px;
        padding-bottom: 85px;
    }

    /* ✅ FIXED MOBILE FOOTER */
        .bottom-bar {
            height: auto;
            padding: 10px 12px;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            gap: 6px;
            text-align: center;
        }

        .footer-text {
            font-size: 12px;
            white-space: normal;
        }

        .language-container {
            width: auto;
            display: flex;
            justify-content: center;
        }

        .language-container select {
            width: auto;
            max-width: 90%;
            padding: 6px;
            font-size: 14px;
            text-align: left;
        }

    /* DATE INPUT */
    /* ================== DATE INPUT FIX ================== */
    .date-wrapper {
        position: relative;
        display: inline-block;
    }

    /* Input styling */
    .date-wrapper input[type="date"] {
        width: 100%;
        padding-right: 40px;
        /* space for custom arrow */
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
        box-sizing: border-box;
        cursor: pointer;
    }

    /* Chrome / Safari / Edge: hide native arrow visually but keep it clickable */
    .date-wrapper input[type="date"]::-webkit-inner-spin-button,
    .date-wrapper input[type="date"]::-webkit-clear-button {
        display: none;
    }

    .date-wrapper input[type="date"]::-webkit-calendar-picker-indicator {
        opacity: 0;
        /* hide it visually */
        position: absolute;
        /* keep clickable area */
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        width: 16px;
        height: 16px;
        cursor: pointer;
    }

    /* Firefox: hide native arrow */
    .date-wrapper input[type="date"]::-moz-calendar-picker-indicator {
        color: transparent;
        /* hides arrow but keeps it clickable */
        cursor: pointer;
    }

    /* Custom arrow */
    .date-arrow {
        position: absolute;
        margin-right: 3px;
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        width: 16px;
        height: 16px;
        pointer-events: none;
        /* click passes through */
        background-image: url("data:image/svg+xml,%3Csvg fill='none' stroke='%23666' stroke-width='2' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }


}

@media (max-width: 480px) {
    body {
        display: flex;
        flex-direction: column;
        align-items: center;
        padding: 10px 0;
    }

    .top-header {
        height: 70px;
        padding: 10px 15px;
    }

    .logo img {
        width: 50px;
        height: 50px;
    }

    /* Adjusting the main container to allow scrolling on mobile */
    .main-container {
        overflow-y: auto;
        flex: 1;
        /* Allow this to take the remaining space */
        padding-top: 80px;
        /* Adjust padding to avoid overlap with header */
        padding-bottom: 85px;
        /* Keep space for footer */
    }

    .signup-container {
        width: 98%;
        padding: 15px;
        margin-top: 0;
        /* Remove the previous margin-top */
    }

    /* DATE INPUT */
    /* ================== DATE INPUT FIX ================== */
    .date-wrapper {
        position: relative;
        display: inline-block;
    }

    /* Input styling */
    .date-wrapper input[type="date"] {
        width: 100%;
        padding-right: 40px;
        /* space for custom arrow */
        -webkit-appearance: none;
        -moz-appearance: none;
        appearance: none;
        box-sizing: border-box;
        cursor: pointer;
    }

    /* Chrome / Safari / Edge: hide native arrow visually but keep it clickable */
    .date-wrapper input[type="date"]::-webkit-inner-spin-button,
    .date-wrapper input[type="date"]::-webkit-clear-button {
        display: none;
    }

    .date-wrapper input[type="date"]::-webkit-calendar-picker-indicator {
        opacity: 0;
        /* hide it visually */
        position: absolute;
        /* keep clickable area */
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        width: 16px;
        height: 16px;
        cursor: pointer;
    }

    /* Firefox: hide native arrow */
    .date-wrapper input[type="date"]::-moz-calendar-picker-indicator {
        color: transparent;
        /* hides arrow but keeps it clickable */
        cursor: pointer;
    }

    /* Custom arrow */
    .date-arrow {
        position: absolute;
        margin-right: 3px;
        right: 10px;
        top: 50%;
        transform: translateY(-50%);
        width: 16px;
        height: 16px;
        pointer-events: none;
        /* click passes through */
        background-image: url("data:image/svg+xml,%3Csvg fill='none' stroke='%23666' stroke-width='2' viewBox='0 0 24 24' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 9l6 6 6-6'%3E%3C/path%3E%3C/svg%3E");
        background-size: contain;
        background-repeat: no-repeat;
        background-position: center;
    }


    /* ✅ FIXED MOBILE FOOTER */
    .bottom-bar {
        height: auto;
        padding: 10px 12px;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 6px;
        text-align: center;
    }

    .footer-text {
        font-size: 12px;
        white-space: normal;
    }

    .language-container {
        width: auto;
        display: flex;
        justify-content: center;
    }

    .language-container select {
        width: auto;
        max-width: 90%;
        padding: 6px;
        font-size: 14px;
        text-align: left;
    }
}