/*
Path: \bhoga\assets\css\form-login.css
*/
/* Bhoga Auth Form Styles */
.bhoga-auth-container {
    max-width: 400px;
    margin: 0 auto;
    padding: 1rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

.bhoga-auth-wrapper {
    background: #fcfcfc;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

/* Toggle Switch */
.bhoga-auth-toggle {
    margin-bottom: 2rem;
}

.bhoga-toggle-button {
    width: 100%;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    outline: none;
}

.bhoga-toggle-track {
    position: relative;
    width: 100%;
    height: 44px;
    background: #e5e5e5;
    border-radius: 22px;
    padding: 4px;
    transition: all 0.3s ease;
}

.bhoga-toggle-slider {
    position: absolute;
    top: 4px;
    left: 4px;
    width: calc(50% - 4px);
    height: 36px;
    background: #e85a5a;
    border-radius: 18px;
    transition: transform 0.3s ease;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    font-weight: 500;
}

.bhoga-toggle-button[aria-pressed="true"] .bhoga-toggle-slider {
    transform: translateX(100%);
}

.bhoga-toggle-labels {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 1;
    padding: 0 1rem;
}

.bhoga-toggle-label {
    flex: 1;
    text-align: center;
    font-size: 14px;
    font-weight: 500;
    transition: opacity 0.3s ease;
    color: #666;
    opacity: 1;
}

/* Hide the active label (under the slider) */
.bhoga-toggle-button:not([aria-pressed="true"]) .bhoga-toggle-label.register-label {
    opacity: 0;
}

.bhoga-toggle-button[aria-pressed="true"] .bhoga-toggle-label.login-label {
    opacity: 0;
}

/* Forms Container */
.bhoga-forms-container {
    position: relative;
    overflow: hidden;
}

.bhoga-form-wrapper {
    width: 100%;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s ease;
    position: absolute;
    top: 0;
    left: 0;
    z-index: 1;
}

.bhoga-form-wrapper.active {
    opacity: 1;
    transform: translateX(0);
    position: relative;
    z-index: 10;
}

/* Input Groups */
.bhoga-input-group {
    margin-bottom: 1.5rem;
    margin-top: 5px;
}

.bhoga-input-wrapper {
    position: relative;
    background: white;
    border: 1px solid #100c17;
    border-radius: 4px;
    z-index: 1;
}

.bhoga-input {
    width: 100%;
    padding: 0.75rem;
    border: none;
    background: transparent;
    font-size: 14px;
    color: #100c17;
    outline: none;
    height: 44px;
    position: relative;
    z-index: 2;
    box-sizing: border-box;
}

.bhoga-input::placeholder {
    color: transparent;
}

.bhoga-input:focus::placeholder {
    color: #999;
}

.bhoga-label {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    padding: 0 0.75rem;
    font-size: 14px;
    color: #100c17;
    pointer-events: none;
    transition: all 0.3s ease;
    background: transparent;
    z-index: 1;
    box-sizing: border-box;
}

/* Float label when input is focused OR has content */
.bhoga-input:focus ~ .bhoga-label,
.bhoga-input:not(:placeholder-shown) ~ .bhoga-label,
.bhoga-input-wrapper.has-value .bhoga-label {
    transform: translate(8px, -12px) scale(0.75);
    background: #fcfcfc;
    padding: 0 6px;
    width: auto;
    height: auto;
    z-index: 3;
    color: #100c17;
}

/* Focused state color */
.bhoga-input:focus ~ .bhoga-label {
    color: #e85a5a;
}

/* Password Toggle */
.bhoga-password-toggle {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 4;
}

.bhoga-eye-icon {
    width: 20px;
    height: 20px;
}

/* Form Options */
.bhoga-form-options {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.bhoga-form-options.register-options {
    gap: 0.75rem;
}

.bhoga-forgot-password {
    align-self: flex-end;
    color: #e85a5a;
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    position: relative;
}

.bhoga-forgot-password:hover {
    text-decoration: underline;
}

.bhoga-checkbox-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    cursor: pointer;
    font-size: 14px;
    line-height: 1.4;
}

.bhoga-checkbox {
    width: 20px;
    height: 20px;
    border: 1px solid #100c17;
    border-radius: 2px;
    accent-color: #100c17;
    cursor: pointer;
    margin: 0;
    flex-shrink: 0;
    margin-top: 2px;
}

.bhoga-checkbox-text {
    color: #100c17;
    user-select: none;
}

.bhoga-checkbox-text a {
    color: #e85a5a;
    text-decoration: underline;
}

/* Submit Button */
.bhoga-submit-button {
    width: 100%;
    padding: 0.75rem 1.25rem;
    background: #e85a5a;
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 44px;
}

.bhoga-submit-button:hover {
    background: #d54545;
    box-shadow: 0 2px 8px rgba(232, 90, 90, 0.3);
}

.bhoga-submit-button:active {
    transform: translateY(1px);
}

/* Responsive Design */
@media (max-width: 480px) {
    .bhoga-auth-container {
        padding: 0.5rem;
    }
    
    .bhoga-auth-wrapper {
        padding: 1rem;
    }
    
    .bhoga-toggle-track {
        height: 40px;
    }
    
    .bhoga-toggle-slider {
        height: 32px;
        font-size: 13px;
    }
    
    .bhoga-input {
        height: 40px;
        font-size: 13px;
    }
    
    .bhoga-checkbox-text {
        font-size: 13px;
    }
    
    .bhoga-submit-button {
        min-height: 40px;
        font-size: 13px;
    }
}

/* Focus States for Accessibility */
.bhoga-toggle-button:focus-visible {
    outline: 2px solid #e85a5a;
    outline-offset: 2px;
}

.bhoga-input:focus {
    border-color: #e85a5a;
    box-shadow: 0 0 0 1px #e85a5a;
}

.bhoga-submit-button:focus-visible {
    outline: 2px solid #e85a5a;
    outline-offset: 2px;
}

.bhoga-checkbox:focus-visible {
    outline: 2px solid #e85a5a;
    outline-offset: 2px;
}

/* Animation for form switching */
.bhoga-forms-container {
    min-height: 300px;
}

.register-form.active .bhoga-forms-container {
    min-height: 400px;
}

/* Error States */
.woocommerce-error {
    background: #fee;
    border: 1px solid #e85a5a;
    border-radius: 4px;
    padding: 0.75rem;
    margin-bottom: 1rem;
    color: #c33;
    font-size: 14px;
}

.woocommerce-message {
    background: #efe;
    border: 1px solid #5a5;
    border-radius: 4px;
    padding: 0.75rem;
    margin-bottom: 1rem;
    color: #363;
    font-size: 14px;
}