/* Reset and base styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
    min-height: 100vh;
}

/* Header */
.header {
    background: white;
    border-bottom: 1px solid #e0e0e0;
    padding: 16px 24px;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
}

.logo-title {
    font-size: 24px;
    font-weight: 600;
    color: #4285f4;
    margin: 0;
}

/* Main container */
.forgot-password-container {
    background-color: #f5f5f5;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 80px 20px 40px 20px;
}

/* White card container */
.forgot-password-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 420px;
    padding: 48px 32px 32px 32px;
    text-align: center;
    /* Add the fade in animation */
    animation: fadeInUp 0.5s ease;
}

/* Fade in animation - same as register form */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Title section */
.title-section {
    margin-bottom: 40px;
}

.page-title {
    font-size: 24px;
    font-weight: 600;
    color: #202124;
    margin-bottom: 12px;
}

.subtitle-text {
    font-size: 15px;
    color: #5f6368;
    font-weight: 400;
    line-height: 1.5;
    max-width: 320px;
    margin: 0 auto;
}

/* Success message */
.success-message {
    background-color: #e8f5e8;
    border: 1px solid #c3e6c3;
    color: #2e7d32;
    padding: 16px 20px;
    border-radius: 8px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    text-align: left;
    font-size: 14px;
    line-height: 1.4;
    transition: opacity 0.3s ease;
}

.success-icon {
    width: 20px;
    height: 20px;
    margin-right: 12px;
    flex-shrink: 0;
}

/* Form styles */
.forgot-password-form {
    margin-bottom: 32px;
}

.form-group {
    margin-bottom: 32px;
    text-align: left;
}

.form-label {
    display: block;
    font-size: 14px;
    color: #202124;
    margin-bottom: 8px;
    font-weight: 500;
}

.input-field {
    width: 100%;
    height: 52px;
    padding: 0 16px;
    border: 1px solid #dadce0;
    border-radius: 4px;
    font-size: 16px;
    background: white;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    outline: none;
    color: #202124;
}

.input-field:focus {
    border-color: #4285f4;
    box-shadow: 0 1px 6px rgba(66, 133, 244, 0.28);
}

.input-field::placeholder {
    color: #9aa0a6;
}

/* Primary button */
.btn-primary {
    width: 100%;
    height: 52px;
    background: #ea4335;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 32px;
    transition: background-color 0.2s ease, box-shadow 0.2s ease;
    letter-spacing: 0.25px;
}

.btn-primary:hover {
    background: #d33b2c;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.btn-primary:disabled {
    background: #9aa0a6;
    cursor: not-allowed;
    box-shadow: none;
}

.btn-primary .btn-icon {
    width: 18px;
    height: 18px;
    margin-right: 10px;
}

/* Spinning animation for loading state */
.animate-spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Links section */
.links-section {
    text-align: center;
}

.back-to-login {
    font-size: 14px;
    color: #5f6368;
    margin-bottom: 20px;
}

.back-to-login a {
    color: #1a73e8;
    text-decoration: none;
    font-weight: 500;
}

.back-to-login a:hover {
    text-decoration: underline;
}

/* Divider */
.divider {
    margin: 24px 0;
    position: relative;
    text-align: center;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: #dadce0;
}

.divider span {
    background: white;
    color: #5f6368;
    font-size: 13px;
    padding: 0 16px;
    position: relative;
}

.register-link {
    font-size: 14px;
    color: #5f6368;
    margin-bottom: 20px;
}

.register-link a {
    color: #34a853;
    text-decoration: none;
    font-weight: 500;
}

.register-link a:hover {
    text-decoration: underline;
}

.help-text {
    font-size: 13px;
    color: #5f6368;
    line-height: 1.5;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 6px;
}

.help-text a {
    color: #1a73e8;
    text-decoration: none;
    font-weight: 500;
}

.help-text a:hover {
    text-decoration: underline;
}

/* Error messages */
.error-message {
    color: #d93025;
    font-size: 13px;
    margin-top: 8px;
    text-align: left;
    display: flex;
    align-items: center;
}

.error-message::before {
    content: '⚠';
    margin-right: 6px;
    font-size: 14px;
}

/* Responsive design */
@media (max-width: 480px) {
    .header {
        padding: 12px 16px;
    }

    .forgot-password-container {
        padding: 70px 16px 40px 16px;
    }

    .forgot-password-card {
        padding: 32px 24px 24px 24px;
        max-width: 100%;
    }

    .page-title {
        font-size: 20px;
    }

    .subtitle-text {
        font-size: 14px;
    }

    .input-field {
        font-size: 16px;
        height: 48px;
    }

    .btn-primary {
        height: 48px;
        font-size: 14px;
    }

    .help-text {
        padding: 12px;
        font-size: 12px;
    }
}

/* Focus states for better accessibility */
.input-field:focus,
.btn-primary:focus {
    outline: 2px solid #4285f4;
    outline-offset: 2px;
}

/* Form validation states */
.input-field.error {
    border-color: #d93025;
}

.input-field.error:focus {
    border-color: #d93025;
    box-shadow: 0 1px 6px rgba(217, 48, 37, 0.28);
}

/* Enhanced visual feedback */
.forgot-password-card {
    position: relative;
    overflow: hidden;
}

.forgot-password-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
}

/* Smooth transitions for better UX */
* {
    transition: all 0.2s ease;
}

.input-field:hover {
    border-color: #5f6368;
}

.success-message {
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}