.auth-container {
    min-height: 100vh;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.auth-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 500px;
    padding: 2.5rem;
    box-shadow: var(--shadow);
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    color: var(--light);
    font-size: 2rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.auth-header h1 i {
    color: var(--danger);
}

.auth-subtitle {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
}

.auth-tabs {
    display: flex;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 5px;
    margin-bottom: 2rem;
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    border: none;
    background: none;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: var(--transition);
}

.tab-btn.active {
    background: var(--danger);
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.auth-form {
    animation: fadeIn 0.5s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--light);
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.form-group label i {
    color: var(--danger);
}

.form-group input {
    width: 100%;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--light);
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus {
    outline: none;
    border-color: var(--danger);
    box-shadow: 0 0 0 2px rgba(233, 69, 96, 0.2);
}

.form-hint {
    display: block;
    margin-top: 0.5rem;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

.password-input {
    position: relative;
}

.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    font-size: 1rem;
}

.captcha-container {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.captcha-code {
    background: var(--dark);
    color: var(--light);
    padding: 0.8rem 1.5rem;
    border-radius: 8px;
    font-family: monospace;
    font-size: 1.2rem;
    letter-spacing: 2px;
    flex: 1;
    text-align: center;
    border: 1px solid var(--accent);
}

.refresh-captcha {
    background: var(--accent);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition);
}

.refresh-captcha:hover {
    background: var(--danger);
}

.btn-auth {
    width: 100%;
    padding: 1rem;
    background: var(--danger);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: var(--transition);
    margin-top: 1rem;
}

.btn-auth:hover {
    background: #d63050;
    transform: translateY(-2px);
}

.auth-links {
    margin-top: 1.5rem;
    text-align: center;
}

.auth-links a {
    color: var(--danger);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.warning-text {
    background: rgba(233, 69, 96, 0.1);
    border: 1px solid rgba(233, 69, 96, 0.3);
    border-radius: 8px;
    padding: 1rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    font-size: 0.9rem;
}

.warning-text i {
    color: var(--danger);
    margin-top: 0.2rem;
}

.security-notice {
    background: rgba(15, 52, 96, 0.3);
    border: 1px solid var(--accent);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    margin-bottom: 2rem;
}

.security-notice i {
    font-size: 2rem;
    color: var(--danger);
    margin-bottom: 1rem;
}

.password-strength {
    margin-top: 0.5rem;
}

.strength-bar {
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 0.3rem;
}

.strength-bar::after {
    content: '';
    display: block;
    height: 100%;
    width: 0%;
    background: var(--danger);
    transition: width 0.3s ease;
}

.strength-text {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.6);
}

.terms-agreement {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 1.5rem 0;
}

.terms-agreement input[type="checkbox"] {
    width: auto;
}

.terms-agreement label {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
    cursor: pointer;
}

.generated-credentials {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 10px;
    padding: 1.5rem;
    margin-top: 2rem;
    border: 1px solid var(--success);
}

.generated-credentials h3 {
    color: var(--light);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.credential-box {
    background: rgba(0, 0, 0, 0.5);
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
}

@media (max-width: 768px) {
    .credential-item {
        display: flex;
        flex-direction: row !important; /* Force horizontal layout */
        align-items: center;
        justify-content: space-between;
        padding: 0.8rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        flex-wrap: nowrap;
    }
    
    .credential-label {
        color: rgba(255, 255, 255, 0.7);
        font-weight: 500;
        min-width: 80px; /* Reduced from 100px for mobile */
        flex-shrink: 0;
        font-size: 0.9rem;
    }
    
    .credential-value {
        color: var(--light);
        font-family: monospace;
        font-size: 0.95rem !important; /* Slightly smaller font */
        flex: 1;
        padding: 0 0.5rem;
        text-align: right;
        word-break: break-all;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    .copy-btn {
        background: var(--accent);
        color: white;
        border: none;
        width: 36px;
        height: 36px;
        border-radius: 6px;
        cursor: pointer;
        transition: var(--transition);
        flex-shrink: 0;
    }
    
    /* Adjust generated credentials box for mobile */
    .generated-credentials {
        background: rgba(0, 0, 0, 0.3);
        border-radius: 10px;
        padding: 1rem;
        margin-top: 1.5rem;
        border: 1px solid var(--success);
    }
    
    .generated-credentials h3 {
        font-size: 1.1rem;
        margin-bottom: 0.8rem;
    }
    
    .credential-box {
        padding: 0.8rem;
        margin-bottom: 0.8rem;
    }
    
    /* Ensure all credential items are horizontal */
    .credential-item:last-child {
        border-bottom: none;
        margin-bottom: 0;
    }
}

/* For very small screens (iPhone SE) */
@media (max-width: 375px) {
    .credential-item {
        flex-wrap: wrap;
        gap: 0.5rem;
    }
    
    .credential-label {
        min-width: 60px;
        font-size: 0.85rem;
    }
    
    .credential-value {
        font-size: 0.85rem !important;
        order: 3;
        width: 100%;
        text-align: left;
        padding: 0;
        padding-top: 0.3rem;
        white-space: normal; /* Allow wrapping on very small screens */
    }
    
    .copy-btn {
        order: 2;
    }
}

/* Keep desktop layout for larger screens */
@media (min-width: 769px) {
    .credential-item {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.8rem 0;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .credential-label {
        min-width: 100px;
    }
    
    .credential-value {
        font-size: 1.1rem;
        padding: 0 1rem;
    }
}

.copy-btn:hover {
    background: var(--danger);
}

.btn-continue {
    display: block;
    text-align: center;
    background: var(--success);
    color: white;
    padding: 1rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: var(--transition);
    margin-top: 1rem;
}

.btn-continue:hover {
    background: #00a884;
    transform: translateY(-2px);
}

.auth-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.back-home {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: var(--transition);
}

.back-home:hover {
    color: var(--danger);
}

.security-badges {
    display: flex;
    gap: 1rem;
}

.security-badges span {
    background: rgba(255, 255, 255, 0.05);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.6);
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

.auth-sidebar {
    display: none;
    width: 350px;
    margin-left: 2rem;
}

.sidebar-content {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    padding: 2rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-content h2 {
    color: var(--light);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-list {
    margin-bottom: 2rem;
}

.info-item {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1rem;
    border-left: 3px solid var(--danger);
}

.info-item i {
    color: var(--danger);
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
}

.info-item h3 {
    color: var(--light);
    font-size: 1rem;
    margin-bottom: 0.3rem;
}

.info-item p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
}

.emergency-notice {
    background: rgba(233, 69, 96, 0.1);
    border: 1px solid rgba(233, 69, 96, 0.3);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
}

.emergency-notice i {
    color: var(--danger);
    font-size: 2rem;
    margin-bottom: 1rem;
}

.emergency-notice h3 {
    color: var(--light);
    margin-bottom: 0.5rem;
}

.emergency-notice p {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.9rem;
}

@media (min-width: 1200px) {
    .auth-sidebar {
        display: block;
    }
    
    .auth-container {
        padding: 40px;
    }
}

@media (max-width: 768px) {
    .auth-card {
        padding: 1.5rem;
    }
    
    .auth-header h1 {
        font-size: 1.5rem;
    }
    
    .auth-footer {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .security-badges {
        flex-direction: column;
        width: 100%;
    }
}