/* ==========================================================================
   AUTHENTICATION & FORMS - Common styles for auth pages and forms
   ========================================================================== */

/* Common Section Layouts */
.auth-section {
    padding: 80px 0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    min-height: calc(100vh - 400px);
    display: flex;
    align-items: center;
}

.auth-container {
    max-width: 500px;
    margin: 0 auto;
    background: white;
    padding: 50px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
}

.auth-container-wide {
    max-width: 700px;
}

/* Headers */
.auth-header {
    text-align: center;
    margin-bottom: 40px;
}

.auth-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--secondary-color), var(--accent-color));
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
}

.auth-icon-large {
    width: 100px;
    height: 100px;
    font-size: 2.5rem;
}

.auth-icon-success {
    background: linear-gradient(135deg, var(--success-color), var(--success-color-dark));
    animation: successPulse 2s ease-in-out infinite;
}

@keyframes successPulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(42, 157, 143, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 20px rgba(42, 157, 143, 0);
    }
}

.auth-header h1 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 10px;
}

.auth-header-large h1 {
    font-size: 2.5rem;
}

.auth-header p {
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.6;
}

/* Form Elements */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.form-group label.required::after {
    content: " *";
    color: var(--primary-color);
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    transition: all 0.3s;
    font-family: 'Roboto', sans-serif;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(230, 57, 70, 0.1);
}

.form-control.error {
    border-color: var(--error-color);
}

.form-text {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: 5px;
    display: block;
}

.form-help-text {
    font-size: 0.875rem;
    color: var(--text-light);
    margin-top: 5px;
    display: block;
}

/* Form Checkboxes */
.form-check {
    display: flex;
    align-items: flex-start;
    margin-bottom: 25px;
}

.form-check-input {
    margin-top: 4px;
    margin-right: 10px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.form-check-label {
    font-size: 0.95rem;
    color: var(--text-dark);
    cursor: pointer;
}

.form-check-label a {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Buttons */
.btn-auth-submit {
    width: 100%;
    padding: 15px;
    background: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.125rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    margin-top: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-auth-submit:hover {
    background: #0d1b2a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 53, 87, 0.4);
}

.btn-auth-submit:disabled {
    background: var(--border-color);
    cursor: not-allowed;
    transform: none;
}

/* Action Buttons (for success pages) */
.action-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    margin-top: 30px;
    flex-wrap: wrap;
}

.btn-action {
    padding: 15px 35px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 1.125rem;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.btn-action-large {
    padding: 18px 40px;
}

.btn-primary {
    background: var(--secondary-color);
    color: white;
}

.btn-primary:hover {
    background: #0d1b2a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 53, 87, 0.4);
}

.btn-secondary {
    background: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background: #0d1b2a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(29, 53, 87, 0.3);
}

/* Links and Dividers */
.auth-links {
    text-align: center;
    margin-top: 25px;
    font-size: 1rem;
    color: var(--text-light);
}

.auth-links a {
    color: var(--secondary-color);
    font-weight: 600;
    text-decoration: none;
}

.auth-links a:hover {
    text-decoration: underline;
}

.divider {
    text-align: center;
    margin: 25px 0;
    color: var(--text-light);
}

/* Info Boxes */
.info-box {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    border-left: 4px solid var(--accent-color);
}

.info-box p {
    margin: 0;
    color: var(--text-light);
    font-size: 0.9rem;
    line-height: 1.6;
}

.info-box strong {
    color: var(--text-dark);
    font-size: 1.125rem;
}

.info-box i {
    color: var(--accent-color);
    margin-right: 8px;
}

.info-box-success {
    border-left-color: var(--success-color);
}

.info-box-success i {
    color: var(--success-color);
}

/* Email Box (special info box) */
.email-box {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    border-left: 4px solid var(--success-color);
}

.email-box p {
    margin: 0;
    color: var(--text-light);
    font-size: 1rem;
    line-height: 1.6;
}

.email-box strong {
    color: var(--text-dark);
    font-size: 1.125rem;
}

.email-box i {
    color: var(--success-color);
    margin-right: 10px;
}

/* Next Steps Box */
.next-steps {
    background: #fff5f5;
    padding: 25px;
    border-radius: 8px;
    margin: 30px 0;
    text-align: left;
}

.next-steps h3 {
    color: var(--text-dark);
    margin-bottom: 15px;
    font-size: 1.25rem;
}

.next-steps ol {
    padding-left: 20px;
    color: var(--text-light);
}

.next-steps li {
    margin-bottom: 10px;
    line-height: 1.6;
}

/* Security Tips */
.security-tips {
    background: var(--warning-bg);
    border-left: 4px solid var(--warning-color);
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    text-align: left;
}

.security-tips h3 {
    color: var(--warning-text);
    margin-bottom: 15px;
    font-size: 1.125rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.security-tips ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.security-tips li {
    color: var(--warning-text);
    margin-bottom: 10px;
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 0.95rem;
}

.security-tips li i {
    color: var(--warning-color);
    margin-top: 3px;
}

/* Password Requirements */
.password-requirements {
    background: var(--bg-light);
    padding: 15px;
    border-radius: 6px;
    margin-top: 10px;
    font-size: 0.875rem;
}

.password-requirements ul {
    margin: 0;
    padding-left: 20px;
}

.password-requirements li {
    color: var(--text-light);
    margin-bottom: 5px;
}

/* Error Messages */
.error-message {
    background: var(--error-bg);
    border-left: 4px solid var(--error-color);
    padding: 12px 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    color: var(--error-color);
    font-size: 0.95rem;
}

.error-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.error-list li {
    margin-bottom: 5px;
}

/* Error Box (for invalid links, etc.) */
.error-box {
    background: var(--error-bg);
    border: 1px solid var(--error-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 25px;
    text-align: center;
}

.error-box i {
    font-size: 3rem;
    color: var(--error-color);
    margin-bottom: 15px;
}

.error-box h3 {
    color: var(--error-text);
    margin-bottom: 10px;
}

.error-box p {
    color: var(--error-text);
    margin-bottom: 20px;
}

.btn-retry {
    background: var(--primary-color);
    color: white;
    padding: 12px 30px;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s;
    display: inline-block;
}

.btn-retry:hover {
    background: #d62839;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(230, 57, 70, 0.3);
}

/* Form Name Grid (for side-by-side fields) */
.form-name-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .auth-section {
        padding: 40px 0;
    }

    .auth-container {
        padding: 30px 20px;
    }

    .auth-header h1 {
        font-size: 1.75rem;
    }

    .auth-header-large h1 {
        font-size: 2rem;
    }

    .action-buttons {
        flex-direction: column;
    }

    .btn-action {
        width: 100%;
        justify-content: center;
    }

    .form-name-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }
}

@media (max-width: 480px) {
    .auth-icon {
        width: 70px;
        height: 70px;
        font-size: 1.75rem;
    }

    .auth-icon-large {
        width: 90px;
        height: 90px;
        font-size: 2.25rem;
    }
}