/* ===== 註冊頁面樣式 ===== */

/* 容器 */
.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 效果以優化手機體驗 */

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

.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;
}

.form-subtitle-small {
    font-size: 0.85rem;
    color: var(--text-light);
    margin: 0.5rem 0 0 0;
    line-height: 1.4;
    font-weight: 400;
}

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

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    margin: 0;
}

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

.form-help {
    font-size: 0.8rem;
    color: var(--text-light);
    margin-top: 0.25rem;
    line-height: 1.4;
}

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

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

.form-input {
    width: 100%;
    padding: 0.75rem 1rem 0.75rem 3.5rem;
    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 效果以優化手機體驗 */

/* 密碼強度指示器 */
.password-strength {
    margin-top: 0.5rem;
}

.strength-bar {
    height: 4px;
    border-radius: 2px;
    background: var(--bg-secondary);
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.strength-fill {
    height: 100%;
    transition: all 0.3s ease;
    border-radius: 2px;
}

.strength-fill.weak { background: #f44336; width: 25%; }
.strength-fill.fair { background: #ff9800; width: 50%; }
.strength-fill.good { background: #ffc107; width: 75%; }
.strength-fill.strong { background: #4caf50; width: 100%; }

.strength-text {
    font-size: 0.75rem;
    color: var(--text-light);
}

/* 表單選項 */
.form-options {
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.checkbox-container {
    margin-bottom: 0.5rem;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--text-secondary);
    line-height: 1.4;
}

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

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

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

.checkbox-label 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;
}

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

/* 條款狀態容器 */
.terms-status-container {
    margin-top: 0.5rem;
    width: 100%;
}

/* 條款狀態樣式 */
.terms-status {
    display: block;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #6c757d;
    font-weight: 500;
    line-height: 1.4;
}

.terms-status.text-success {
    color: #28a745;
}

.terms-status i {
    margin-right: 0.5rem;
}

/* 手機版條款狀態優化 */
@media (max-width: 768px) {
    .terms-status {
        font-size: 0.8rem;
        margin-top: 0.75rem;
        padding: 0.5rem;
        background: rgba(108, 117, 125, 0.1);
        border-radius: 6px;
        border-left: 3px solid #6c757d;
    }
    
    .terms-status.text-success {
        background: rgba(40, 167, 69, 0.1);
        border-left-color: #28a745;
    }
}

@media (max-width: 480px) {
    .terms-status {
        font-size: 0.75rem;
        margin-top: 0.5rem;
        padding: 0.4rem;
        border-radius: 4px;
    }
}

@media (max-width: 360px) {
    .terms-status {
        font-size: 0.7rem;
        padding: 0.3rem;
        margin-top: 0.4rem;
    }
}

/* 移除 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;
}

/* 錯誤狀態 */
.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: 768px) {
    .auth-container {
        padding: 1.5rem 1rem;
    }
    
    .auth-form-card {
        padding: 2rem 1.5rem;
        border-radius: 20px;
    }
    
    .logo-title {
        font-size: 2.2rem;
    }
    
    .form-title {
        font-size: 1.4rem;
    }
    
    .form-subtitle {
        font-size: 0.95rem;
    }
    
    .form-subtitle-small {
        font-size: 0.85rem;
    }
    
    .form-group {
        margin-top: 1.2rem;
    }
    
    .form-label {
        font-size: 0.9rem;
    }
    
    .form-input {
        font-size: 0.95rem;
        padding: 0.8rem 1rem 0.8rem 3.5rem;
    }
    
    .form-help {
        font-size: 0.8rem;
    }
    
    .checkbox-label {
        font-size: 0.85rem;
        line-height: 1.3;
    }
    
    .terms-status {
        font-size: 0.8rem;
        margin-top: 0.75rem;
        padding: 0.5rem;
        background: rgba(108, 117, 125, 0.1);
        border-radius: 6px;
        border-left: 3px solid #6c757d;
    }
    
    .terms-status.text-success {
        background: rgba(40, 167, 69, 0.1);
        border-left-color: #28a745;
    }
}

@media (max-width: 480px) {
    .auth-container {
        padding: 1rem 0.5rem;
    }
    
    .auth-form-card {
        padding: 1.5rem 1rem;
        border-radius: 16px;
    }
    
    .logo-title {
        font-size: 1.8rem;
    }
    
    .form-title {
        font-size: 1.3rem;
    }
    
    .form-subtitle {
        font-size: 0.9rem;
    }
    
    .form-subtitle-small {
        font-size: 0.8rem;
    }
    
    .form-group {
        margin-top: 1rem;
    }
    
    .form-label {
        font-size: 0.85rem;
    }
    
    .form-input {
        font-size: 0.9rem;
        padding: 0.75rem 0.9rem 0.75rem 3.5rem;
    }
    
    .form-help {
        font-size: 0.75rem;
    }
    
    .checkbox-label {
        font-size: 0.8rem;
        line-height: 1.2;
    }
    
    .terms-status {
        font-size: 0.75rem;
        margin-top: 0.5rem;
        padding: 0.4rem;
        border-radius: 4px;
    }
    
    .btn {
        padding: 0.7rem 1.2rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 360px) {
    .auth-container {
        padding: 0.5rem;
    }
    
    .auth-form-card {
        padding: 1.2rem 0.8rem;
        border-radius: 12px;
    }
    
    .logo-title {
        font-size: 1.6rem;
    }
    
    .form-title {
        font-size: 1.2rem;
    }
    
    .form-subtitle {
        font-size: 0.85rem;
    }
    
    .form-subtitle-small {
        font-size: 0.75rem;
    }
    
    .form-group {
        margin-top: 0.8rem;
    }
    
    .form-label {
        font-size: 0.8rem;
    }
    
    .form-input {
        font-size: 0.85rem;
        padding: 0.7rem 0.8rem 0.7rem 3.5rem;
    }
    
    .form-help {
        font-size: 0.7rem;
    }
    
    .checkbox-label {
        font-size: 0.75rem;
    }
    
    .terms-status {
        font-size: 0.7rem;
        padding: 0.3rem;
        margin-top: 0.4rem;
    }
    
    .btn {
        padding: 0.65rem 1rem;
        font-size: 0.85rem;
    }
}

/* 手機版觸控優化 */
@media (hover: none) and (pointer: coarse) {
    .form-input {
        min-height: 44px;
        touch-action: manipulation;
        padding-left: 2.5rem;
    }
    
    .btn {
        min-height: 44px;
        touch-action: manipulation;
    }
    
    .checkbox-label {
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    .checkmark {
        min-width: 20px;
        min-height: 20px;
    }
}

/* 橫向手機版優化 */
@media (max-width: 768px) and (orientation: landscape) {
    .auth-container {
        padding: 1rem;
    }
    
    .auth-form-card {
        max-width: 90%;
        margin: 0 auto;
    }
    
    .form-group {
        margin-top: 1rem;
    }
}

/* 動畫效果 */
@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; }
.form-group:nth-child(5) { animation-delay: 0.5s; } 