:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --success-gradient: linear-gradient(135deg, #10b981 0%, #059669 100%);
    --card-shadow: 0 20px 60px rgba(0, 0, 0, 0.1);
}

* {
    font-family: 'Inter', sans-serif;
}

body {
    min-height: 100vh;
    background: linear-gradient(135deg, #f5f7fa 0%, #e4e8f0 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.password-card {
    background: white;
    border-radius: 24px;
    box-shadow: var(--card-shadow);
    max-width: 460px;
    width: 100%;
    overflow: hidden;
}

.card-header-custom {
    background: var(--primary-gradient);
    padding: 35px 30px;
    text-align: center;
    color: white;
    transition: all 0.5s ease;
}

.card-header-custom.success-header {
    background: var(--success-gradient);
}

.card-header-custom .icon-circle {
    width: 75px;
    height: 75px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 18px;
    backdrop-filter: blur(10px);
}

.card-header-custom .icon-circle i {
    font-size: 32px;
}

.card-header-custom h2 {
    font-weight: 700;
    margin-bottom: 6px;
    font-size: 1.5rem;
}

.card-header-custom p {
    opacity: 0.9;
    margin: 0;
    font-size: 14px;
}

.card-body-custom {
    padding: 35px 30px;
}

.form-section {
    display: none;
}

.form-section.active {
    display: block;
    animation: fadeInUp 0.5s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

.form-label {
    font-weight: 600;
    color: #374151;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-control {
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 15px;
    transition: all 0.3s ease;
}

.form-control:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.input-group .form-control {
    border-left: none;
}

.input-group .form-control:focus {
    border-left: none;
}

.input-group-text {
    background: #f9fafb;
    border: 2px solid #e5e7eb;
    border-right: none;
    border-radius: 12px 0 0 12px;
}

.input-group:focus-within .input-group-text {
    border-color: #667eea;
}

.btn-primary-custom {
    background: var(--primary-gradient);
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    font-weight: 600;
    font-size: 15px;
    width: 100%;
    color: white;
    transition: all 0.3s ease;
}

.btn-primary-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
    color: white;
}

.btn-primary-custom:active {
    transform: translateY(0);
}

.btn-success-custom {
    background: var(--success-gradient);
    border: none;
    border-radius: 12px;
    padding: 14px 28px;
    font-weight: 600;
    font-size: 15px;
    width: 100%;
    color: white;
    transition: all 0.3s ease;
}

.btn-success-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.4);
    color: white;
}

/* OTP Input Styles */
.otp-container {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin: 25px 0;
}

.otp-input {
    width: 50px;
    height: 58px;
    text-align: center;
    font-size: 22px;
    font-weight: 700;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.otp-input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    outline: none;
}

.otp-input.filled {
    border-color: #667eea;
    background: rgba(102, 126, 234, 0.05);
}

.resend-text {
    text-align: center;
    color: #6b7280;
    font-size: 14px;
    margin-top: 20px;
}

.resend-text a {
    color: #667eea;
    font-weight: 600;
    text-decoration: none;
}

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

.resend-text a.disabled {
    color: #9ca3af;
    pointer-events: none;
}

/* Password Strength Indicator */
.password-strength {
    margin-top: 10px;
}

.strength-bars {
    display: flex;
    gap: 6px;
    margin-bottom: 6px;
}

.strength-bar {
    height: 4px;
    flex: 1;
    background: #e5e7eb;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.strength-bar.weak {
    background: #ef4444;
}

.strength-bar.medium {
    background: #f59e0b;
}

.strength-bar.strong {
    background: #10b981;
}

.strength-text {
    font-size: 12px;
    font-weight: 500;
}

.strength-text.weak {
    color: #ef4444;
}

.strength-text.medium {
    color: #f59e0b;
}

.strength-text.strong {
    color: #10b981;
}

/* Password Toggle */
.password-toggle {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #9ca3af;
    cursor: pointer;
    padding: 0;
    z-index: 10;
}

.password-toggle:hover {
    color: #667eea;
}

.password-wrapper {
    position: relative;
}

.password-wrapper .form-control {
    padding-right: 45px;
}

/* Password Requirements */
.password-requirements {
    margin-top: 15px;
    padding: 15px;
    background: #f9fafb;
    border-radius: 12px;
}

.password-requirements h6 {
    font-size: 12px;
    font-weight: 600;
    color: #6b7280;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.requirement {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: #9ca3af;
    margin-bottom: 6px;
    transition: all 0.3s ease;
}

.requirement:last-child {
    margin-bottom: 0;
}

.requirement i {
    font-size: 14px;
}

.requirement.valid {
    color: #10b981;
}

.requirement.valid i::before {
    content: "\f26b";
}

/* Success Section */
.success-icon {
    width: 90px;
    height: 90px;
    background: var(--success-gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    animation: scaleIn 0.5s ease, pulse 2s infinite;
}

.success-icon i {
    font-size: 42px;
    color: white;
}

@keyframes scaleIn {
    0% {
        transform: scale(0);
    }

    50% {
        transform: scale(1.1);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }

    50% {
        box-shadow: 0 0 0 15px rgba(16, 185, 129, 0);
    }
}

.success-title {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin-bottom: 10px;
}

.success-text {
    color: #6b7280;
    margin-bottom: 25px;
    font-size: 14px;
    line-height: 1.6;
}

/* Progress Steps */
.progress-steps {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 25px;
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #e5e7eb;
    transition: all 0.3s ease;
}

.step-dot.active {
    background: #667eea;
    width: 28px;
    border-radius: 5px;
}

.step-dot.completed {
    background: #10b981;
}

/* Email Display */
.email-display {
    background: #f3f4f6;
    padding: 10px 18px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 15px;
    font-weight: 500;
    color: #374151;
    font-size: 14px;
}

.back-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #6b7280;
    text-decoration: none;
    font-size: 14px;
    margin-top: 20px;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: #667eea;
}

/* Loading Spinner */
.spinner-border-sm {
    width: 18px;
    height: 18px;
    margin-right: 8px;
}

/* Error message */
.error-message {
    color: #ef4444;
    font-size: 13px;
    margin-top: 8px;
    display: none;
}

.error-message.show {
    display: block;
}

/* Shake animation */
@keyframes shake {

    0%,
    100% {
        transform: translateX(0);
    }

    25% {
        transform: translateX(-5px);
    }

    75% {
        transform: translateX(5px);
    }
}

.shake {
    animation: shake 0.3s ease;
}

/* Match indicator */
.match-indicator {
    font-size: 12px;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.match-indicator.match {
    color: #10b981;
}

.match-indicator.no-match {
    color: #ef4444;
}

/* Confetti animation for success */
.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    background: #667eea;
    animation: confetti-fall 3s ease-in-out infinite;
}

@keyframes confetti-fall {
    0% {
        transform: translateY(-100%) rotate(0deg);
        opacity: 1;
    }

    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}