/* Student Authentication Pages Styling */
@import url('/css/fonts.css');

:root {
    --auth-button-width: 220px;
}

/* Override Bootstrap container to full width for auth pages */
.auth-page {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background-color: #f5f5f5;
}

.auth-container {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Background illustration */
.auth-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background-image: url('/img/student-login-bg.png');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-color: #f5f5f5;
}

/* Logo container and positioning */
.auth-logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: -60px; /* Negative margin creates overlap */
    z-index: 1;
}

.auth-logo {
    max-width: 800px;
    width: 100%;
    height: auto;
    object-fit: contain;
}

/* Form container */
.auth-form-container {
    background: transparent;
    padding: 2rem;
    border-radius: 16px;
    max-width: 600px;
    width: 100%;
    position: relative;
    z-index: 10;
}

/* Form title */
.auth-form-title {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'Delight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    color: #333;
    margin-bottom: 1rem;
    text-align: left;
    display: block;
}

/* Input group with inline button */
.auth-input-group {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.auth-input-group .form-control {
    flex: 1;
    height: 56px;
    border-radius: 28px;
    border: 2px solid #333;
    padding: 0 1.5rem;
    font-size: 1rem;
    font-weight: 400;
    font-family: 'Delight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    background: white;
    transition: border-color 0.2s;
}

.auth-input-group .form-control:focus {
    border-color: #3967F6;
    box-shadow: 0 0 0 3px rgba(57, 103, 246, 0.1);
    outline: none;
}

.btn-submit {
    height: 56px;
    width: var(--auth-button-width);
    border-radius: 28px;
    background: #3967F6;
    color: white;
    border: none;
    font-size: 1.5rem;
    font-weight: 700;
    font-family: 'Delight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: background 0.2s;
    white-space: nowrap;
}

.btn-submit:hover {
    background: #4A6FEE;
}

.btn-submit:active {
    background: #3A5FDE;
}

/* Arrow icon */
.btn-submit::after {
    content: "→";
    font-weight: 700;
    font-size: 1.75rem;
}

/* Error messages */
.auth-error {
    color: #721c24;
    font-size: 0.9rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    text-align: left;
    background: #f8d7da;
    border-radius: 8px;
    padding: 0.05rem;
}

/* Success messages */
.auth-success-message {
    color: #155724;
    background: #d4edda;
    padding: 0.5rem;
    border-radius: 8px;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
}

/* Forgot password link */
.auth-forgot-link {
    text-align: center;
    margin-top: 1rem;
    font-size: 0.9rem;
}

.auth-forgot-link a {
    color: #333;
    text-decoration: none;
    border-bottom: 1px solid #333;
}

.auth-forgot-link a:hover {
    color: #5B7FFF;
    border-bottom-color: #5B7FFF;
}

/* Validation styling */
.field-validation-error {
    color: #dc3545;
    font-size: 0.9rem;
    margin-top: 0.25rem;
    display: block;
}

.input-validation-error {
    border-color: #dc3545 !important;
}

/* For username-only input groups, reserve the same width as the button so inputs line up */
.auth-input-group.no-button::after {
    content: "";
    flex: 0 0 var(--auth-button-width);
}

/* Modal styling */
.auth-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
}

.auth-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.auth-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    border-radius: 20px;
    padding: 2.5rem;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    z-index: 10000;
}

.auth-modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: transparent;
    border: none;
    font-size: 2rem;
    line-height: 1;
    color: #666;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    transition: color 0.2s;
}

.auth-modal-close:hover {
    color: #333;
}

.auth-modal-title {
    font-family: 'Delight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    font-size: 1.75rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 1rem;
    text-align: center;
}

.auth-modal-text {
    font-family: 'Delight', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial;
    font-size: 1.1rem;
    font-weight: 400;
    color: #555;
    line-height: 1.6;
    text-align: center;
    margin-bottom: 1.5rem;
}

/* Question and warning variants inside modals */
.auth-modal-question {
    text-align: center;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.auth-modal-warning {
    display: flex;
    gap: 0.5rem;
    align-items: flex-start;
    background: #fff4e5;
    border: 1px solid #ffd89b;
    color: #663c00;
    padding: 0.6rem 0.75rem;
    border-radius: 8px;
    font-size: 0.98rem;
    margin-bottom: 1rem;
}

.auth-warning-icon { font-size: 1.2rem; line-height: 1; }
.auth-warning-text { flex: 1; }

/* Subtle reminder used in success step */
/* reminder styling removed — using standard modal text styles */

.auth-modal-button {
    width: 100%;
    margin: 0;
}
