* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #ff9a9e 0%, #fecfef 50%, #fecfef 100%);
    min-height: 100vh;
}

.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

.auth-card {
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    width: 100%;
    max-width: 400px;
    text-align: center;
}

.auth-card h2 {
    color: #ff6b6b;
    margin-bottom: 20px;
    font-size: 24px;
}

.auth-tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.tab-btn {
    flex: 1;
    padding: 10px;
    border: none;
    background: none;
    cursor: pointer;
    font-size: 16px;
    color: #666;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: #ff6b6b;
    border-bottom: 2px solid #ff6b6b;
}

.form-group {
    margin-bottom: 15px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #666;
    font-weight: bold;
}

.form-group input {
    width: 100%;
    padding: 10px;
    border: 2px solid #f0f0f0;
    border-radius: 10px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #ff6b6b;
}

.btn {
    width: 100%;
    padding: 12px;
    background: #ff6b6b;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
}

.btn:hover {
    background: #ff5252;
}

.chat-container {
    display: flex;
    height: 100vh;
}

.sidebar {
    width: 250px;
    background: white;
    border-right: 1px solid #f0f0f0;
    padding: 20px;
}

.user-info {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f0f0f0;
}

.avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    margin-right: 15px;
    object-fit: cover;
}

.user-info h3 {
    color: #333;
    margin-bottom: 5px;
}

.settings-link {
    color: #ff6b6b;
    text-decoration: none;
    font-size: 14px;
}

.friends-list h4 {
    color: #666;
    margin-bottom: 15px;
}

#friends-list {
    list-style: none;
}

#friends-list li {
    display: flex;
    align-items: center;
    padding: 10px;
    border-radius: 10px;
    margin-bottom: 10px;
    cursor: pointer;
    transition: background 0.3s ease;
}

#friends-list li:hover {
    background: #f5f5f5;
}

#friends-list li img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-right: 10px;
}

.chat-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: #f8f9fa;
}

.chat-header {
    background: white;
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
    text-align: center;
}

.chat-header h2 {
    color: #333;
}

.messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
}

.message {
    margin-bottom: 15px;
    max-width: 70%;
    padding: 12px 16px;
    border-radius: 18px;
    position: relative;
}

.message.sent {
    background: #ff6b6b;
    color: white;
    align-self: flex-end;
    margin-left: auto;
    border-bottom-right-radius: 4px;
}

.message.received {
    background: white;
    color: #333;
    align-self: flex-start;
    border-bottom-left-radius: 4px;
}

.message-input {
    background: white;
    padding: 20px;
    border-top: 1px solid #f0f0f0;
    display: flex;
}

.message-input input {
    flex: 1;
    padding: 12px;
    border: 2px solid #f0f0f0;
    border-radius: 25px;
    font-size: 16px;
    margin-right: 10px;
}

.message-input button {
    background: #ff6b6b;
    color: white;
    border: none;
    border-radius: 50%;
    width: 48px;
    height: 48px;
    cursor: pointer;
    font-size: 18px;
    transition: background 0.3s ease;
}

.message-input button:hover {
    background: #ff5252;
}

.settings-container {
    max-width: 600px;
    margin: 50px auto;
    background: white;
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.settings-container h2 {
    color: #ff6b6b;
    margin-bottom: 30px;
    text-align: center;
}

.settings-form {
    display: flex;
    flex-direction: column;
}

.avatar-upload {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 30px;
}

.avatar-upload img {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    margin-bottom: 15px;
    object-fit: cover;
}

.avatar-upload input {
    margin-top: 10px;
}

.error {
    color: red;
    margin-top: 10px;
    font-size: 14px;
}

.success {
    color: green;
    margin-top: 10px;
    font-size: 14px;
}