/* Compact Authentication Pages Styles */

:root {
    --primary-pink: #ff6b9d;
    --primary-blue: #4a90e2;
    --light-pink: #fff0f5;
    --light-blue: #f0f8ff;
    --dark-pink: #cc557d;
    --dark-blue: #3a7bc8;
    --white: #ffffff;
    --off-white: #fafafa;
    --light-gray: #f5f7fa;
    --medium-gray: #a0aec0;
    --text-dark: #1a202c;
    --text-light: #4a5568;
    --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 20px rgba(0, 0, 0, 0.1);
    --radius-sm: 8px;
    --radius-md: 12px;
    --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Global Image Auto-Fit - Prevents overflow */
img {
    max-width: 100%;
    height: auto;
    object-fit: cover;
    display: block;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, var(--light-pink) 0%, var(--light-blue) 50%, var(--off-white) 100%);
    min-height: 100vh;
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px;
    overflow: hidden;
}

.auth-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    max-width: 1000px;
    max-height: 90vh;
    background: white;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.auth-left {
    padding: 28px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    max-height: 90vh;
}

.auth-header {
    text-align: center;
    margin-bottom: 15px;
}

.auth-logo {
    width: 100px;
    height: auto;
    margin-bottom: 15px;
    margin-left: auto;
    margin-right: auto;
    cursor: pointer;
    transition: transform 0.2s ease;
}

.auth-logo:hover {
    transform: scale(1.05);
}

.auth-header h1 {
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 4px;
    font-weight: 700;
}

.auth-header p {
    color: var(--text-light);
    font-size: 0.85rem;
    line-height: 1.3;
}

.auth-form {
    flex: 1;
}

.form-step {
    display: none;
}

.form-step.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

.form-step h2 {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin-bottom: 15px;
    text-align: center;
    font-weight: 600;
}

.form-step:first-child {
    margin-top: 3px;
}

.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: none;
    margin-bottom: 5px;
    font-weight: 500;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.form-group label.terms-checkbox {
    display: flex;
}

/* Terms and Conditions Checkbox */
.terms-group {
    margin-bottom: 16px;
    margin-top: 18px;
}

.terms-checkbox {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-size: 0.85rem;
    gap: 10px;
}

.terms-checkbox input[type="checkbox"] {
    width: 14px;
    height: 14px;
    margin-top: 2px;
    cursor: pointer;
    flex-shrink: 0;
}

.terms-text {
    color: var(--text-light);
    line-height: 1.4;
}

.terms-text a {
    color: var(--primary-pink);
    text-decoration: none;
    font-weight: 500;
}

.terms-text a:hover {
    text-decoration: underline;
}

.input-with-icon {
    position: relative;
}

.input-with-icon i:first-child {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--medium-gray);
    font-size: 0.9rem;
}

.input-with-icon .toggle-password {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--medium-gray);
    cursor: pointer;
    font-size: 0.9rem;
}

.input-with-icon input {
    width: 100%;
    padding: 9px 12px 9px 32px;
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-sm);
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    transition: var(--transition);
    background: var(--off-white);
}

/* Password input needs extra right padding for toggle icon */
.input-with-icon input[type="password"],
.input-with-icon input[type="password"] + .toggle-password ~ input {
    padding-right: 40px;
}

.input-with-icon input:focus {
    outline: none;
    border-color: var(--primary-pink);
    background: white;
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
}

.help-text {
    display: block;
    margin-top: 5px;
    font-size: 0.8rem;
    color: var(--text-light);
}

/* Compact OTP Input Styles */
.otp-inputs {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 18px 0;
}

.otp-input {
    width: 42px;
    height: 48px;
    text-align: center;
    font-size: 1.2rem;
    font-weight: 600;
    border: 2px solid #e2e8f0;
    border-radius: var(--radius-sm);
    font-family: 'Poppins', sans-serif;
    transition: var(--transition);
    background: var(--off-white);
}

.otp-input:focus {
    outline: none;
    border-color: var(--primary-pink);
    background: white;
    box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
}

.timer {
    text-align: center;
    margin: 12px 0;
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-pink);
}

.resend-section {
    text-align: center;
    margin-top: 15px;
}

.resend-section p {
    color: var(--text-light);
    margin-bottom: 10px;
    font-size: 0.85rem;
}

/* Compact Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 9px 16px;
    border: none;
    border-radius: var(--radius-sm);
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(-100%);
    transition: var(--transition);
}

.btn:hover::before {
    transform: translateX(100%);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-pink), var(--primary-blue));
    color: white;
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.btn-link {
    background: none;
    color: var(--primary-pink);
    text-decoration: underline;
    padding: 0;
    font-size: 0.9rem;
}

.btn-link:hover {
    color: var(--dark-pink);
}

.btn-block {
    width: 100%;
}

/* Form Options - Remember me and Forgot Password */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 20px 0 25px;
    gap: 12px;
}

.checkbox-option {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text-light);
}

.checkbox-option input[type="checkbox"] {
    display: none;
}

.checkbox-option .checkmark {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid #cbd5e1;
    border-radius: 3px;
    margin-right: 8px;
    transition: all 0.2s ease;
}

.checkbox-option input[type="checkbox"]:checked + .checkmark {
    background: linear-gradient(135deg, var(--primary-pink), var(--primary-blue));
    border-color: var(--primary-pink);
}

.forgot-password {
    color: var(--primary-pink);
    text-decoration: none;
    font-size: 0.9rem;
    transition: var(--transition);
}

.forgot-password:hover {
    text-decoration: underline;
}

/* Form footer */
.auth-footer {
    text-align: center;
    margin-top: 15px;
    padding-top: 10px;
    border-top: 1px solid #edf2f7;
}

.auth-footer p {
    color: var(--text-light);
    font-size: 0.85rem;
}

.auth-footer a {
    color: var(--primary-pink);
    text-decoration: none;
    font-weight: 500;
}

.auth-footer a:hover {
    text-decoration: underline;
}

/* Right Side Features - More compact */
.auth-right {
    background: linear-gradient(135deg, var(--primary-pink), var(--primary-blue));
    padding: 25px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    max-height: 90vh;
}

.auth-features {
    color: white;
    max-width: 300px;
}

.feature-item {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.feature-item:last-child {
    margin-bottom: 0;
}

.feature-item i {
    font-size: 1.3rem;
    min-width: 35px;
    text-align: center;
}

.feature-item h3 {
    font-size: 1rem;
    margin-bottom: 6px;
    font-weight: 600;
}

.feature-item p {
    color: rgba(255, 255, 255, 0.9);
    line-height: 1.4;
    font-size: 0.85rem;
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateX(15px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Loading spinner */
.spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Verification text */
.verification-text {
    text-align: center;
    color: var(--text-light);
    margin: 12px 0;
    font-size: 0.95rem;
    line-height: 1.4;
}

/* Compact Responsive Design */
@media (max-width: 992px) {
    .auth-container {
        grid-template-columns: 1fr;
        max-width: 500px;
        margin: 0 auto;
        min-height: 100vh;
    }
    
    .auth-right {
        display: none;
    }
    
    .auth-left {
        padding: 30px 25px;
        width: 100%;
        min-height: 100vh;
        display: flex;
        flex-direction: column;
    }
    
    .auth-content {
        flex: 1;
        display: flex;
        flex-direction: column;
    }
    
    .auth-header {
        margin-bottom: 25px;
        text-align: center;
    }
    
    .logo-placeholder {
        width: 80px;
        height: 80px;
        margin: 0 auto 15px;
    }
    
    .auth-header h1 {
        font-size: 1.8rem;
        margin-bottom: 8px;
    }
    
    .auth-header p {
        font-size: 1rem;
    }
    
    .form-step h2 {
        margin-bottom: 20px;
        font-size: 1.5rem;
        text-align: center;
    }
    
    .form-step p {
        text-align: center;
        margin-bottom: 25px;
        font-size: 1rem;
    }
    
    .form-group {
        margin-bottom: 20px;
    }
    
    .form-control {
        padding: 14px 18px;
        font-size: 1.05rem;
    }
    
    .btn {
        padding: 14px 20px;
        font-size: 1.05rem;
        margin: 25px 0;
    }
    
    .auth-footer {
        margin-top: auto;
        padding-top: 20px;
        text-align: center;
    }
}

@media (max-width: 576px) {
    body {
        padding: 0;
        margin: 0;
    }
    
    .auth-container {
        max-width: 100%;
        margin: 0;
    }
    
    .auth-left {
        padding: 25px 20px;
        min-height: 100vh;
    }
    
    .logo-placeholder {
        width: 70px;
        height: 70px;
        margin-bottom: 12px;
    }
    
    .auth-header h1 {
        font-size: 1.6rem;
        margin-bottom: 6px;
    }
    
    .auth-header p {
        font-size: 0.95rem;
    }
    
    .form-step h2 {
        font-size: 1.3rem;
        margin-bottom: 18px;
    }
    
    .form-step p {
        font-size: 0.95rem;
        margin-bottom: 20px;
    }
    
    .form-group {
        margin-bottom: 18px;
    }
    
    .form-control {
        padding: 12px 16px;
        font-size: 1rem;
    }
    
    .password-toggle {
        padding: 12px;
        font-size: 1.1rem;
    }
    
    .terms-group {
        margin: 20px 0;
    }
    
    .terms-checkbox {
        display: flex;
        align-items: flex-start;
        gap: 12px;
        cursor: pointer;
    }
    
    .terms-checkbox input[type="checkbox"] {
        width: 14px;
        height: 14px;
        margin-top: 2px;
        flex-shrink: 0;
    }
    
    .terms-text {
        font-size: 0.9rem;
        line-height: 1.4;
        color: var(--text-light);
    }
    
    .otp-inputs {
        gap: 8px;
        margin: 25px 0;
    }
    
    .otp-input {
        width: 45px;
        height: 55px;
        font-size: 1.4rem;
    }
    
    .resend-section {
        margin: 20px 0;
    }
    
    .resend-timer {
        font-size: 0.9rem;
    }
    
    .btn {
        padding: 12px 18px;
        font-size: 1rem;
        margin: 20px 0;
    }
    
    .auth-footer {
        padding-top: 15px;
    }
    
    .auth-footer p {
        font-size: 0.9rem;
        margin-bottom: 6px;
    }
    
    .back-to-home {
        margin-top: 20px;
        padding: 12px;
        font-size: 1rem;
    }
    
    /* Prevent zoom on input focus */
    input, select, textarea {
        font-size: 16px;
    }
    
    /* Better touch targets */
    .password-toggle, .back-to-home {
        min-height: 44px;
    }
    
    .terms-label {
        min-height: 24px;
        display: flex;
        align-items: center;
    }
}

@media (max-width: 400px) {
    .auth-left {
        padding: 20px 15px;
    }
    
    .logo-placeholder {
        width: 60px;
        height: 60px;
        margin-bottom: 10px;
    }
    
    .auth-header h1 {
        font-size: 1.4rem;
        margin-bottom: 5px;
    }
    
    .auth-header p {
        font-size: 0.9rem;
    }
    
    .form-step h2 {
        font-size: 1.2rem;
        margin-bottom: 15px;
    }
    
    .form-step p {
        font-size: 0.9rem;
        margin-bottom: 18px;
    }
    
    .form-group {
        margin-bottom: 16px;
    }
    
    .form-control {
        padding: 10px 14px;
        font-size: 0.95rem;
    }
    
    .password-toggle {
        padding: 10px;
        font-size: 1rem;
    }
    
    .terms-label {
        font-size: 0.85rem;
        padding-left: 28px;
    }
    
    .terms-checkbox {
        display: flex;
        align-items: flex-start;
        gap: 10px;
        cursor: pointer;
    }
    
    .terms-checkbox input[type="checkbox"] {
        width: 14px;
        height: 14px;
        margin-top: 2px;
        flex-shrink: 0;
    }
    
    .terms-text {
        font-size: 0.85rem;
        line-height: 1.4;
    }
    
    .otp-inputs {
        gap: 6px;
        margin: 20px 0;
    }
    
    .otp-input {
        width: 40px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .resend-section {
        margin: 15px 0;
    }
    
    .resend-timer {
        font-size: 0.85rem;
    }
    
    .btn {
        padding: 10px 16px;
        font-size: 0.95rem;
        margin: 18px 0;
    }
    
    .auth-footer p {
        font-size: 0.85rem;
    }
    
    .back-to-home {
        margin-top: 18px;
        padding: 10px;
        font-size: 0.95rem;
    }
    
    /* Optimize for very small screens */
    input, select, textarea {
        font-size: 16px;
    }
    
    .form-control::placeholder {
        font-size: 0.9rem;
    }
    
    .auth-content {
        gap: 5px;
    }
}
