/* ===== 登入頁面樣式 ===== */

/* 容器 */
.auth-container {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--bg-primary) 0%, var(--accent-light) 100%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    position: relative;
    overflow-x: hidden;
}

.auth-container::before {
    content: '';
    position: fixed;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 107, 107, 0.03) 0%, transparent 70%);
    z-index: -1;
    animation: float 20s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    33% { transform: translate(30px, -30px) rotate(120deg); }
    66% { transform: translate(-20px, 20px) rotate(240deg); }
}

/* 頁首 */
.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-logo {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.logo-image {
    width: 80px;
    height: 80px;
    border-radius: 20px;
    box-shadow: 0 8px 24px var(--shadow-medium);
}

.logo-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--white);
    margin: 0;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.logo-subtitle {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
    font-weight: 500;
}

/* 表單容器 */
.auth-form-container {
    width: 100%;
    max-width: 420px;
}

.auth-form-card {
    background: var(--white);
    border-radius: 24px;
    padding: 3rem 2.5rem;
    box-shadow: 
        0 20px 60px rgba(44, 62, 80, 0.08),
        0 8px 24px rgba(255, 107, 107, 0.12),
        inset 0 1px 0 rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(20px);
    position: relative;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.auth-form-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
    z-index: 1;
}

/* 移除 hover 效果以優化手機體驗 */

/* Email 已存在提示樣式 */
.email-exists-help {
    margin-top: 0.5rem;
}

.email-exists-help p {
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.email-exists-help .login-options {
    margin: 1rem 0;
}

.option-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
    color: var(--text-secondary);
}

.option-item i {
    color: var(--accent-primary);
    width: 16px;
    text-align: center;
}

.help-actions {
    margin-top: 1rem;
    text-align: center;
}

.help-actions .btn {
    font-size: 0.875rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.2s ease;
}

.help-actions .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(255, 107, 107, 0.3);
}

/* 表單標題 */
.form-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.form-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.form-subtitle {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0;
    line-height: 1.5;
}

/* 表單 */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-primary);
}

.input-group {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 1rem;
    color: var(--text-light);
    font-size: 1rem;
    z-index: 1;
}

.form-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3rem;
    border: 2px solid var(--bg-secondary);
    border-radius: 12px;
    background: var(--white);
    font-size: 0.9rem;
    color: var(--text-primary);
    transition: all 0.3s ease;
    box-sizing: border-box;
}

.form-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(255, 112, 67, 0.1);
}

.form-input::placeholder {
    color: var(--text-light);
}

.password-toggle {
    position: absolute;
    right: 1rem;
    background: none;
    border: none;
    color: var(--text-light);
    cursor: pointer;
    font-size: 1rem;
    transition: all 0.3s ease;
}

/* 移除 hover 效果以優化手機體驗 */

/* 表單選項 */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.5rem;
}

.checkbox-container {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.checkbox-container input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 16px;
    height: 16px;
    border: 2px solid var(--bg-secondary);
    border-radius: 4px;
    margin-right: 0.5rem;
    position: relative;
    transition: all 0.3s ease;
    background: var(--white);
}

.checkbox-container input[type="checkbox"]:checked + .checkmark {
    background: var(--primary);
    border-color: var(--primary);
}

.checkbox-container input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--white);
    font-size: 0.7rem;
    font-weight: bold;
}

.forgot-password {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: all 0.3s ease;
}

/* 移除 hover 效果以優化手機體驗 */

/* 按鈕 */
.btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: #FF6B6B !important;
    color: var(--white) !important;
}

/* 移除 hover 效果以優化手機體驗 */

.btn-block {
    width: 100%;
}

.btn-loading {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* 分隔線 */
.auth-divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.auth-divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--bg-secondary);
}

.auth-divider span {
    background: var(--white);
    padding: 0 1rem;
    color: var(--text-light);
    font-size: 0.8rem;
}

/* 社群登入 */
.social-login {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.btn-social {
    background: var(--white);
    color: var(--text-primary);
    border: 2px solid var(--bg-secondary);
    justify-content: center;
    gap: 0.75rem;
}

/* 移除 hover 效果以優化手機體驗 */

/* 頁尾 */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--bg-secondary);
}

.auth-footer p {
    margin: 0;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.auth-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
}

/* 移除 hover 效果以優化手機體驗 */

/* 錯誤狀態 */
.form-input.error {
    border-color: #f44336;
    box-shadow: 0 0 0 3px rgba(244, 67, 54, 0.1);
}

.error-message {
    color: #f44336;
    font-size: 0.8rem;
    margin-top: 0.5rem;
    margin-bottom: 0.5rem;
    display: block;
}

/* 成功狀態 */
.success-message {
    color: #4caf50;
    font-size: 0.8rem;
    margin-top: 0.25rem;
}

/* 載入動畫 */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fa-spinner {
    animation: spin 1s linear infinite;
}

/* 響應式設計 */
@media (max-width: 480px) {
    .auth-container {
        padding: 1rem;
    }
    
    .auth-form-card {
        padding: 1.5rem;
        border-radius: 20px;
    }
    
    .logo-title {
        font-size: 2rem;
    }
    
    .form-title {
        font-size: 1.3rem;
    }
}

/* 動畫效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-form-card {
    animation: fadeInUp 0.6s ease;
}

.form-group {
    animation: fadeInUp 0.6s ease;
}

.form-group:nth-child(1) { animation-delay: 0.1s; }
.form-group:nth-child(2) { animation-delay: 0.2s; }
.form-group:nth-child(3) { animation-delay: 0.3s; }
.form-group:nth-child(4) { animation-delay: 0.4s; } 