/* 全局样式 */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Arial', sans-serif;
}

body {
    background-color: #f5f5f5;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.header {
    text-align: center;
    margin-bottom: 30px;
}

.logo {
    width: 80px;
    height: 80px;
    margin-bottom: 10px;
}

/* 登录/注册表单 */
.login-box {
    background: white;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 1px solid #ddd;
}

.tab {
    padding: 10px 20px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 16px;
    color: #666;
}

.tab.active {
    color: #1a73e8;
    border-bottom: 2px solid #1a73e8;
}

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

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

.form-group input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.btn {
    display: block;
    width: 100%;
    padding: 12px;
    background: #1a73e8;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    margin-top: 20px;
}

.btn:hover {
    background: #0d62c9;
}

.error {
    color: #d32f2f;
    margin-top: 15px;
    padding: 10px;
    background: #ffebee;
    border-radius: 4px;
    display: none;
}

.error.show {
    display: block;
}

.success {
    color: #388e3c;
    background: #e8f5e9;
}

.third-party {
    margin-top: 30px;
    text-align: center;
}

.third-party p {
    color: #666;
    margin-bottom: 15px;
    position: relative;
}

.third-party p::before,
.third-party p::after {
    content: "";
    display: inline-block;
    width: 30%;
    height: 1px;
    background: #ddd;
    vertical-align: middle;
    margin: 0 10px;
}

.provider-btn {
    display: inline-flex;
    align-items: center;
    padding: 8px 15px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 4px;
    cursor: pointer;
}

.provider-btn img {
    width: 20px;
    height: 20px;
    margin-right: 8px;
}

.footer {
    text-align: center;
    margin-top: 30px;
    color: #666;
    font-size: 14px;
}

/* 邮箱界面样式 */
.mail-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.mail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    background: white;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.brand {
    display: flex;
    align-items: center;
}

.brand h1 {
    margin-left: 10px;
    font-size: 20px;
}

.user-info {
    display: flex;
    align-items: center;
}

.user-info span {
    margin-right: 15px;
}

.mail-layout {
    display: flex;
    flex: 1;
    overflow: hidden;
}

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

.sidebar .btn {
    margin-bottom: 20px;
}

.folders li {
    padding: 10px 0;
    cursor: pointer;
    list-style: none;
}

.folders li:hover {
    color: #1a73e8;
}

.folders li.active {
    color: #1a73e8;
    font-weight: bold;
}

.mail-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.mail-list {
    flex: 1;
    overflow-y: auto;
    background: white;
}

.mail-item {
    display: flex;
    padding: 15px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

.mail-item.unread {
    font-weight: bold;
    background: #f0f7ff;
}

.mail-item:hover {
    background: #f5f5f5;
}

.mail-sender {
    width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mail-subject {
    flex: 1;
    margin: 0 15px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mail-preview {
    width: 300px;
    color: #666;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.mail-date {
    width: 100px;
    text-align: right;
    color: #666;
}

.mail-view {
    flex: 1;
    padding: 20px;
    background: white;
    overflow-y: auto;
}

.mail-view-header {
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 1px solid #eee;
}

.mail-view-header h2 {
    margin-bottom: 10px;
}

.mail-meta {
    display: flex;
    justify-content: space-between;
    color: #666;
}

.mail-content {
    white-space: pre-wrap;
    margin-bottom: 20px;
}

.mail-actions {
    display: flex;
    gap: 10px;
}

.compose-form {
    flex: 1;
    padding: 20px;
    background: white;
}

.compose-form .form-group {
    margin-bottom: 15px;
}

.compose-form label {
    display: block;
    margin-bottom: 5px;
    font-weight: bold;
}

.compose-form input,
.compose-form textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
}

.compose-form textarea {
    min-height: 200px;
    resize: vertical;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.empty {
    text-align: center;
    padding: 50px;
    color: #666;
}