/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

/* 首页宽屏样式 */
body.dashboard-page .container {
    max-width: 1200px;
}

body.dashboard-page {
    display: block;
    padding: 20px;
    min-height: 100vh;
}

/* 登录/注册盒子 */
.login-box {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}

/* Logo样式 */
.logo {
    text-align: center;
    margin-bottom: 30px;
}

.logo h1 {
    color: #667eea;
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.logo p {
    color: #666;
    font-size: 1rem;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
    font-size: 0.95rem;
}

.form-group label i {
    margin-right: 8px;
    color: #667eea;
}

.form-group input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8f9fa;
}

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

/* 记住我选项 */
.remember {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}

.remember input {
    width: auto;
    margin-right: 10px;
}

/* 按钮样式 */
.btn {
    width: 100%;
    padding: 14px;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.3);
}

/* 短按钮样式 */
.btn-short {
    width: auto;
    padding: 10px 25px;
    font-size: 1rem;
    text-transform: none;
    letter-spacing: 0;
}

/* 链接样式 */
.register-link {
    text-align: center;
    margin-top: 20px;
}

.register-link a {
    color: #667eea;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

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

/* 消息提示 */
.alert {
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    font-size: 0.95rem;
    font-weight: 500;
}

.alert-success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.alert-warning {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.alert-info {
    background-color: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* 响应式设计 */
@media (max-width: 480px) {
    .login-box {
        padding: 30px 20px;
    }
    
    .logo h1 {
        font-size: 2rem;
    }
    
    .btn {
        padding: 12px;
        font-size: 1rem;
    }
}

/* 首页样式 */
.dashboard {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 30px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    backdrop-filter: blur(10px);
}

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

.user-info h2 {
    color: #333;
    margin-bottom: 10px;
}

.user-info p {
    color: #666;
}

/* 签到卡片 */
.checkin-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 15px;
    padding: 30px;
    text-align: center;
    margin-bottom: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.checkin-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.3);
}

.checkin-card .checkin-status {
    font-size: 4rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.checkin-card .checkin-text {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 20px;
}

.checkin-card.checked {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

/* 签到日历 */
.calendar {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
    margin-bottom: 30px;
    overflow: hidden; /* 防止内容溢出 */
    width: 100%;
    box-sizing: border-box;
}

.calendar h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.3rem;
    text-align: center;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    margin-bottom: 15px;
    width: 100%;
    box-sizing: border-box;
}

.calendar-day {
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9rem;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    word-break: break-all;
    overflow: hidden;
}

.calendar-day.weekday {
    color: #666;
    background: #e9ecef;
}

.calendar-day.date {
    background: white;
    border: 2px solid #e1e5e9;
    cursor: pointer;
    transition: all 0.3s ease;
}

.calendar-day.date:hover {
    border-color: #667eea;
    background: #f0f4ff;
}

.calendar-day.date.checked {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-color: #667eea;
}

.calendar-day.date.today {
    border-color: #f5576c;
    background: #fff0f3;
    color: #f5576c;
}

/* 操作按钮 */
.action-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    margin-bottom: 30px;
}

.action-btn {
    background: white;
    border: 2px solid #e1e5e9;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    color: #333;
}

.action-btn:hover {
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(102, 126, 234, 0.15);
}

.action-btn i {
    font-size: 2rem;
    color: #667eea;
    margin-bottom: 10px;
    display: block;
}

.action-btn .btn-text {
    font-weight: 600;
    font-size: 1rem;
}

.action-btn .btn-desc {
    font-size: 0.85rem;
    color: #666;
    margin-top: 5px;
}

/* 微博区域 */
.posts-section {
    background: #f8f9fa;
    border-radius: 15px;
    padding: 20px;
}

.posts-section h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.3rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.posts-section h3 i {
    color: #667eea;
}

/* 微博卡片 */
.post-card {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 15px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.post-card:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.post-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 15px;
}

.post-user {
    display: flex;
    align-items: center;
    gap: 12px;
}

.post-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
}

.post-username {
    font-weight: 600;
    color: #333;
    font-size: 0.95rem;
}

.post-time {
    font-size: 0.85rem;
    color: #999;
    margin-top: 2px;
}

.post-content {
    color: #555;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.post-actions {
    display: flex;
    gap: 20px;
    padding-top: 15px;
    border-top: 1px solid #f0f0f0;
}

.post-action {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #666;
    cursor: pointer;
    transition: color 0.3s ease;
    font-size: 0.9rem;
}

.post-action:hover {
    color: #667eea;
}

/* 发布微博表单 */
.post-form {
    background: white;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.post-form textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 1rem;
    resize: vertical;
    min-height: 120px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.post-form textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.post-form .form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
}

.post-form .visibility {
    display: flex;
    align-items: center;
    gap: 10px;
}

.post-form .visibility label {
    color: #666;
    font-size: 0.9rem;
    cursor: pointer;
}

/* 导航栏 */
.navbar {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    padding: 15px 30px;
    margin-bottom: 30px;
    border-radius: 15px;
}

.navbar-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #333;
}

.navbar-brand h1 {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-menu {
    display: flex;
    gap: 25px;
    list-style: none;
}

.navbar-menu li a {
    text-decoration: none;
    color: #666;
    font-weight: 500;
    transition: all 0.3s ease;
    position: relative;
    padding: 8px 0;
}

.navbar-menu li a:hover {
    color: #667eea;
}

.navbar-menu li a.active {
    color: #667eea;
}

.navbar-menu li a.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 2px;
}

/* 电脑端隐藏顶部logo */
.top-logo {
    display: none;
}

/* 移动端底部导航 */
@media (max-width: 768px) {
    /* 顶部logo栏 */
    .top-logo {
        display: block !important;
        background: rgba(255, 255, 255, 0.95);
        backdrop-filter: blur(10px);
        box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
        padding: 15px 0;
        margin-bottom: 20px;
        border-radius: 0 0 15px 15px;
        position: relative;
        z-index: 999;
        width: 100%;
        box-sizing: border-box;
    }
    
    .top-logo-container {
        max-width: 1200px;
        margin: 0 auto;
        text-align: center;
    }
    
    .top-logo h1 {
        font-size: 1.8rem;
        font-weight: 700;
        background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
        margin: 0;
    }
    
    /* 固定底部导航 */
    .navbar {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        width: 100%;
        max-width: 100%;
        padding: 10px 0;
        margin-bottom: 0;
        border-radius: 15px 15px 0 0;
        z-index: 1000;
    }
    
    /* 隐藏原品牌logo */
    .navbar-brand {
        display: none;
    }
    
    /* 底部导航菜单 */
    .navbar-container {
        justify-content: center;
    }
    
    .navbar-menu {
        display: flex;
        flex-direction: row;
        gap: 0;
        justify-content: space-around;
        width: 100%;
        padding: 0 10px;
    }
    
    .navbar-menu li {
        width: auto;
        flex: 1;
        text-align: center;
    }
    
    .navbar-menu li a {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 5px;
        padding: 10px 0;
        font-size: 0.8rem;
    }
    
    .navbar-menu li a i {
        font-size: 1.2rem;
    }
    
    /* 调整页面内容，避免被底部导航遮挡 */
    .dashboard {
        padding: 20px 20px 80px 20px;
    }
    
    /* 调整操作按钮布局 */
    .action-buttons {
        grid-template-columns: 1fr;
    }
    
    /* 调整日历样式 */
    .calendar {
        padding: 15px;
    }
    
    .calendar-grid {
        gap: 5px;
        grid-template-columns: repeat(7, 1fr);
        width: 100%;
    }
    
    .calendar-day {
        padding: 8px 4px;
        font-size: 0.8rem;
        min-height: 35px;
    }
    
    .calendar-day.date {
        border-width: 1px;
    }
    
    /* 调整body样式，避免底部导航超出视口 */
    body.dashboard-page {
        padding-bottom: 80px;
    }
}

/* 小屏手机响应式设计 */
@media (max-width: 480px) {
    .calendar {
        padding: 10px;
    }
    
    .calendar h3 {
        font-size: 1.1rem;
        margin-bottom: 15px;
    }
    
    .calendar-grid {
        gap: 3px;
    }
    
    .calendar-day {
        padding: 6px 2px;
        font-size: 0.75rem;
        min-height: 30px;
        border-radius: 6px;
    }
    
    .calendar-day.date {
        font-weight: 500;
    }
}

/* 超小屏手机响应式设计 */
@media (max-width: 360px) {
    .calendar-grid {
        grid-template-columns: repeat(7, minmax(0, 1fr));
    }
    
    .calendar-day {
        padding: 5px 1px;
        font-size: 0.7rem;
        min-height: 25px;
    }
}

/* 设置页面样式 */
.settings-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.settings-section h3 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.2rem;
    font-weight: 600;
}

.settings-form {
    max-width: 600px;
}

.settings-form .form-group {
    margin-bottom: 20px;
}

.settings-form label {
    display: block;
    color: #555;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.95rem;
}

.settings-form input {
    width: 100%;
    padding: 12px;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
}

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

.settings-form input:disabled {
    background-color: #f8f9fa;
    cursor: not-allowed;
    opacity: 0.7;
}

.settings-form small {
    display: block;
    color: #999;
    margin-top: 5px;
    font-size: 0.85rem;
}

.security-info {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.security-info p {
    margin-bottom: 10px;
    color: #555;
    font-size: 0.95rem;
}

.security-info p:last-child {
    margin-bottom: 0;
}