/* CSS สำหรับหน้าเข้าสู่ระบบและสมัครสมาชิก */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 3rem 1rem;
    min-height: calc(100vh - 300px);
}

.auth-card {
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: var(--border-radius);
    padding: 2.5rem;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.auth-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.auth-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.auth-header h1 {
    color: var(--accent-color);
    margin-bottom: 0.75rem;
    font-size: 2rem;
    position: relative;
    display: inline-block;
}

.auth-header h1::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: var(--accent-color);
    border-radius: 3px;
}

.auth-header p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.auth-form {
    margin-bottom: 2rem;
}

.form-group {
    margin-bottom: 1.75rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.75rem;
    color: var(--text-color);
    font-weight: 500;
}

.input-wrapper {
    position: relative;
}

.input-wrapper input {
    width: 100%;
    padding: 1rem 3rem 1rem 1rem;
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius-sm);
    color: var(--text-color);
    font-size: 1rem;
    transition: var(--transition);
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(212, 166, 95, 0.2);
}

.input-wrapper input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

.input-wrapper .input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--accent-color);
}

.input-wrapper input {
    padding-left: 2.75rem;
}

.input-wrapper .toggle-password {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0;
    font-size: 1.1rem;
    transition: var(--transition);
}

.input-wrapper .toggle-password:hover {
    color: var(--accent-color);
}

.error-message {
    color: var(--danger-color);
    font-size: 0.9rem;
    margin-top: 0.5rem;
    padding-left: 0.5rem;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.remember-me, .terms-agree {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-secondary);
    cursor: pointer;
}

.remember-me input, .terms-agree input {
    width: 18px;
    height: 18px;
    accent-color: var(--accent-color);
    cursor: pointer;
}

.forgot-password {
    color: var(--accent-color);
    font-size: 0.95rem;
    transition: var(--transition);
}

.forgot-password:hover {
    text-decoration: underline;
}

.btn-submit {
    width: 100%;
    padding: 1rem;
    background-color: var(--accent-color);
    color: var(--primary-color);
    border: none;
    border-radius: var(--border-radius-sm);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
}

.btn-submit:hover {
    background-color: #e5b76f;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.btn-submit:active {
    transform: translateY(-1px);
}

.btn-submit::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 5px;
    height: 5px;
    background: rgba(255, 255, 255, 0.4);
    opacity: 0;
    border-radius: 100%;
    transform: scale(1, 1) translate(-50%);
    transform-origin: 50% 50%;
}

.btn-submit:focus:not(:active)::after {
    animation: ripple 1s ease-out;
}

@keyframes ripple {
    0% {
        transform: scale(0, 0);
        opacity: 0.5;
    }
    20% {
        transform: scale(25, 25);
        opacity: 0.3;
    }
    100% {
        opacity: 0;
        transform: scale(40, 40);
    }
}

.social-login {
    position: relative;
    text-align: center;
    margin: 2.5rem 0;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.social-login p {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    font-size: 0.95rem;
}

.social-buttons {
    display: flex;
    gap: 1.5rem;
}

.btn-social {
    flex: 1;
    padding: 0.9rem;
    border: none;
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    cursor: pointer;
    transition: var(--transition);
    font-weight: 500;
    text-decoration: none;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.2);
}

.btn-social:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 12px rgba(0, 0, 0, 0.3);
}

.facebook {
    background-color: #3b5998;
    color: white;
}

.google {
    background-color: #db4437;
    color: white;
}

.auth-footer {
    text-align: center;
    color: var(--text-secondary);
}

.auth-footer a {
    color: var(--accent-color);
    font-weight: 500;
    transition: var(--transition);
}

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

/* Password strength indicator */
.password-strength {
    margin-top: 0.75rem;
    margin-bottom: 0.75rem;
}

.strength-bar {
    height: 5px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 0.4rem;
}

.strength-progress {
    height: 100%;
    width: 0%;
    transition: width 0.3s ease, background-color 0.3s ease;
}

.strength-progress.weak {
    width: 25%;
    background-color: #f44336;
}

.strength-progress.medium {
    width: 50%;
    background-color: #ff9800;
}

.strength-progress.strong {
    width: 75%;
    background-color: #4caf50;
}

.strength-progress.very-strong {
    width: 100%;
    background-color: #2196f3;
}

.strength-text {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: block;
}

/* แถบแจ้งเตือน (alert) */
.alert {
    padding: 1.25rem;
    border-radius: var(--border-radius-sm);
    margin-bottom: 2rem;
    font-size: 0.95rem;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
    position: relative;
}

.alert-success {
    background-color: rgba(76, 175, 80, 0.1);
    border-left: 4px solid #4caf50;
    color: #4caf50;
}

.alert-danger {
    background-color: rgba(244, 67, 54, 0.1);
    border-left: 4px solid #f44336;
    color: #f44336;
}

.alert-warning {
    background-color: rgba(255, 152, 0, 0.1);
    border-left: 4px solid #ff9800;
    color: #ff9800;
}

.alert-info {
    background-color: rgba(33, 150, 243, 0.1);
    border-left: 4px solid #2196f3;
    color: #2196f3;
}

.alert ul {
    margin: 0.5rem 0 0;
    padding-left: 1.5rem;
}

.alert ul li {
    margin-bottom: 0.25rem;
}

.alert ul li:last-child {
    margin-bottom: 0;
}

/* เอฟเฟกต์เคลื่อนไหว */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.auth-card {
    animation: fadeIn 0.5s ease-out;
}

/* รองรับการแสดงผลบนอุปกรณ์เคลื่อนที่ */
@media (max-width: 576px) {
    .auth-card {
        padding: 1.75rem;
    }
    
    .auth-header h1 {
        font-size: 1.75rem;
    }
    
    .auth-header p {
        font-size: 1rem;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .social-buttons {
        flex-direction: column;
    }
    
    .btn-submit {
        padding: 0.9rem;
        font-size: 1rem;
    }
    
    .btn-social {
        padding: 0.8rem;
    }
}

/* สำหรับอุปกรณ์ที่มีความสูงต่ำ */
@media (max-height: 700px) {
    .auth-container {
        padding: 2rem 1rem;
        min-height: auto;
    }
    
    .auth-card {
        padding: 1.5rem;
    }
    
    .auth-header {
        margin-bottom: 1.5rem;
    }
    
    .form-group {
        margin-bottom: 1.25rem;
    }
}

/* สำหรับการพิมพ์ */
@media print {
    .auth-container {
        min-height: auto;
        padding: 0;
    }
    
    .auth-card {
        box-shadow: none;
        border: 1px solid #ccc;
        max-width: 100%;
    }
    
    .btn-submit, .social-login, .btn-social {
        display: none;
    }
}