/* Login Page Styles - Following Spread Hive Theme */

/* Login Section */
.login-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    padding: 120px 20px 60px;
    overflow: hidden;
}

.login-background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

/* Crypto Animation (reusing from main styles) */
.crypto-animation {
    position: absolute;
    width: 100%;
    height: 100%;
}

.crypto-particle {
    position: absolute;
    width: 4px;
    height: 4px;
    background: #667eea;
    border-radius: 50%;
    animation: float 6s ease-in-out infinite;
}

.crypto-particle:nth-child(1) {
    top: 20%;
    left: 20%;
    animation-delay: 0s;
}

.crypto-particle:nth-child(2) {
    top: 60%;
    left: 80%;
    animation-delay: 2s;
}

.crypto-particle:nth-child(3) {
    top: 80%;
    left: 40%;
    animation-delay: 4s;
}

.crypto-particle:nth-child(4) {
    top: 40%;
    left: 60%;
    animation-delay: 1s;
}

.crypto-particle:nth-child(5) {
    top: 70%;
    left: 10%;
    animation-delay: 3s;
}

.crypto-particle:nth-child(6) {
    top: 30%;
    left: 90%;
    animation-delay: 5s;
}

.crypto-particle:nth-child(7) {
    top: 90%;
    left: 70%;
    animation-delay: 2.5s;
}

.crypto-particle:nth-child(8) {
    top: 10%;
    left: 30%;
    animation-delay: 1.5s;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0px) scale(1);
        opacity: 0.7;
    }
    50% {
        transform: translateY(-20px) scale(1.2);
        opacity: 1;
    }
}

/* Floating Elements */
.floating-elements {
    position: absolute;
    width: 100%;
    height: 100%;
}

.floating-coin {
    position: absolute;
    width: 60px;
    height: 60px;
    background: rgba(102, 126, 234, 0.1);
    border: 2px solid rgba(102, 126, 234, 0.3);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: float 8s ease-in-out infinite;
}

.floating-coin:nth-child(1) {
    top: 15%;
    left: 15%;
    animation-delay: 0s;
}

.floating-coin:nth-child(2) {
    top: 25%;
    right: 20%;
    animation-delay: 2s;
}

.floating-coin:nth-child(3) {
    bottom: 20%;
    left: 25%;
    animation-delay: 4s;
}

.floating-coin i {
    font-size: 24px;
    color: #667eea;
}

.trading-line {
    position: absolute;
    height: 2px;
    background: linear-gradient(90deg, transparent, #667eea, transparent);
    animation: trading 10s linear infinite;
}

.trading-line:nth-child(4) {
    top: 40%;
    left: 0;
    width: 200px;
    animation-delay: 0s;
}

.trading-line:nth-child(5) {
    top: 60%;
    right: 0;
    width: 150px;
    animation-delay: 3s;
}

.trading-line:nth-child(6) {
    bottom: 30%;
    left: 50%;
    width: 100px;
    animation-delay: 6s;
}

@keyframes trading {
    0% {
        transform: translateX(-100%);
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Geometric Shapes */
.geometric-shapes {
    position: absolute;
    width: 100%;
    height: 100%;
}

.shape {
    position: absolute;
    border: 2px solid rgba(102, 126, 234, 0.2);
    animation: rotate 20s linear infinite;
}

.shape-1 {
    top: 10%;
    right: 10%;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    animation-delay: 0s;
}

.shape-2 {
    bottom: 15%;
    right: 15%;
    width: 60px;
    height: 60px;
    transform: rotate(45deg);
    animation-delay: 5s;
}

.shape-3 {
    top: 50%;
    left: 10%;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    animation-delay: 10s;
}

.shape-4 {
    top: 70%;
    left: 20%;
    width: 50px;
    height: 50px;
    transform: rotate(30deg);
    animation-delay: 15s;
}

@keyframes rotate {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

/* Login Container */
.login-container {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 450px;
}

.login-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 24px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, #667eea, #764ba2);
}

/* Login Header */
.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-bottom: 30px;
    font-size: 28px;
    font-weight: 700;
    color: white;
}

.login-logo i {
    color: #667eea;
    font-size: 32px;
}

.login-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 12px;
}

.login-header p {
    font-size: 1.125rem;
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
}

/* Login Form */
.login-form {
    margin-bottom: 30px;
}

.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
    margin-bottom: 8px;
    font-size: 14px;
}

.form-group label i {
    color: #667eea;
    font-size: 16px;
}

.form-group input {
    width: 100%;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.08);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: white;
    font-size: 16px;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

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

/* Password Input */
.password-input {
    position: relative;
}

.password-toggle {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.password-toggle:hover {
    color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.1);
}

/* Form Options */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}

.checkbox-container {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.8);
    font-size: 14px;
    cursor: pointer;
}

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

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 4px;
    position: relative;
    transition: all 0.2s ease;
}

.checkbox-container input[type="checkbox"]:checked + .checkmark {
    background: #667eea;
    border-color: #667eea;
}

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

.forgot-password {
    color: #667eea;
    text-decoration: none;
    font-size: 14px;
    transition: all 0.2s ease;
}

.forgot-password:hover {
    color: #764ba2;
    text-decoration: underline;
}

/* Login Button */
.login-btn {
    width: 100%;
    padding: 16px 24px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 12px;
    transition: all 0.3s ease;
}

.login-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(102, 126, 234, 0.4);
}

/* Login Footer */
.login-footer {
    text-align: center;
    padding-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.login-footer p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 20px;
    font-size: 14px;
}

.signup-link {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
}

.signup-link:hover {
    color: #764ba2;
    text-decoration: underline;
}

.security-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
}

.security-info i {
    color: #22c55e;
    font-size: 14px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .login-section {
        padding: 100px 20px 40px;
    }
    
    .login-card {
        padding: 30px 25px;
        border-radius: 20px;
    }
    
    .login-header h1 {
        font-size: 2rem;
    }
    
    .login-header p {
        font-size: 1rem;
    }
    
    .form-group input {
        padding: 14px 16px;
        font-size: 16px;
    }
    
    .form-options {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .floating-coin {
        width: 40px;
        height: 40px;
    }
    
    .floating-coin i {
        font-size: 18px;
    }
    
    .shape {
        display: none;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: 25px 20px;
    }
    
    .login-header h1 {
        font-size: 1.75rem;
    }
    
    .login-logo {
        font-size: 24px;
    }
    
    .login-logo i {
        font-size: 28px;
    }
    
    .crypto-particle {
        display: none;
    }
    
    .trading-line {
        display: none;
    }
}

/* Loading State */
.login-btn.loading {
    position: relative;
    color: transparent;
}

.login-btn.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 20px;
    height: 20px;
    border: 2px solid transparent;
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Error States */
.form-group.error input {
    border-color: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1);
}

.form-group.error .error-message {
    color: #ef4444;
    font-size: 12px;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.form-group.error .error-message i {
    font-size: 14px;
}

/* Success Animation */
.login-card.success {
    animation: successPulse 0.6s ease-in-out;
}

@keyframes successPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}
