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

body {
    font-family: 'Microsoft YaHei', sans-serif;
    background-color: #f5f5f5;
    color: #333;
}

.container {
    width: 100%;
    max-width: none;
    margin: 0 auto;
    padding: 20px;
    padding-top: 120px; /* 为固定header留出更多空间 */
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: white;
    padding: 15px 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    margin-bottom: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
}

.header > h1 {
    color: #2c3e50;
    font-size: 1.4rem;
    margin: 0;
}

/* 日期选择器样式 */
.date-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.date-picker-group {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.date-picker-group label {
    font-size: 0.7rem;
    color: #7f8c8d;
    font-weight: bold;
}

.date-input {
    padding: 6px 8px;
    border: 2px solid #bdc3c7;
    border-radius: 6px;
    font-size: 0.7rem;
    width: auto;
    min-width: auto;
}

/* 套餐选择器样式 */
.combo-filter-row {
    width: 100%;
    margin: 0 0 20px 0;
}

.combo-filter-panel {
    display: flex;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 0;
    width: 100%;
}

.combo-type-tabs {
    display: flex;
    gap: 10px;
}

.combo-type-tab {
    padding: 6px 14px;
    border: 1px solid #d7dde4;
    border-radius: 999px;
    background: #f6f8fa;
    color: #4a4f5b;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s ease;
}

.combo-type-tab:hover {
    background: #e8ecf2;
    border-color: #c0c7d4;
}

.combo-type-tab.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 10px rgba(118, 75, 162, 0.3);
}

.combo-tags-container {
    flex: 1;
    min-width: 320px;
    background: #fff;
    border: 1px solid #e2e6ef;
    border-radius: 12px;
    padding: 12px 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.04);
}

.combo-tags-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    max-height: 140px;
    overflow-y: auto;
    padding-right: 4px;
}

.combo-tag {
    padding: 6px 12px;
    border-radius: 999px;
    font-size: 0.75rem;
    border: 1px solid transparent;
    background: #f2f4f7;
    color: #4a4f5b;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.combo-tag:hover {
    background: #e1e6ef;
}

.combo-tag.active {
    background: linear-gradient(135deg, #ff9966 0%, #ff5e62 100%);
    color: #fff;
    box-shadow: 0 4px 12px rgba(255, 94, 98, 0.35);
}

.combo-tag.daily-combo::after {
    content: '·当日';
    margin-left: 4px;
    font-size: 0.65rem;
    color: #f1c40f;
}

.combo-tag.no-daily-combo {
    opacity: 0.85;
}

/* 应用按钮样式 */
.apply-btn {
    padding: 8px 16px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 0.8rem;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

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

.apply-btn:active {
    transform: translateY(0);
}

/* 日期和星期几上下排列的样式 */
.date-weekday-row {
    display: block;
    margin-bottom: 5px;
}

.card-date {
    font-size: 0.65rem; /* 再减小二号 */
    font-weight: bold;
    display: block;
    margin-bottom: 2px;
}

.card-weekday {
    font-size: 0.7rem; /* 减小二号 */
    opacity: 0.9;
    display: block;
}

.meal-tabs {
    display: flex;
    gap: 8px;
    padding: 0;
    background: transparent;
    border-radius: 0;
    margin: 0;
}

.tab-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 18px;
    background-color: #ecf0f1;
    color: #7f8c8d;
    font-size: 0.7rem;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.tab-btn:hover {
    background-color: #bdc3c7;
    color: white;
}

.tab-btn.active {
    background-color: #3498db;
    color: white;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 20px;
    margin-bottom: 30px;
    width: 100%;
}

.calendar-card {
    background: white;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    width: 100%;
}

.calendar-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.card-header {
    border: 2px solid #e74c3c; /* 红框线 */
    background: white;
    color: #2c3e50;
    padding: 12px;
    border-radius: 12px;
    margin-bottom: 15px;
    text-align: center;
}

.dish-list {
    list-style: none;
}

.dish-item {
    padding: 6px 10px;
    margin-bottom: 6px;
    background-color: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid #27ae60;
    font-size: 0.85em;
}

.dish-category {
    font-weight: bold;
    color: #000000; /* 黑色 */
    margin-right: 5px;
    font-size: 0.85em;
}

.dish-name {
    color: #e74c3c; /* 红色 */
    font-size: 0.85em;
}

.no-dishes {
    color: #95a5a6;
    font-style: italic;
    padding: 10px;
    text-align: center;
}

.loading, .error {
    text-align: center;
    padding: 40px;
}

.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3498db;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

.error p {
    color: #e74c3c;
    font-size: 1.1rem;
}

/* 对话框样式 */
.combo-dialog {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.dialog-content {
    background: white;
    border-radius: 15px;
    width: 90%;
    max-width: 600px; /* 加宽窗体 */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    animation: slideIn 0.3s ease;
}

.dialog-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.dialog-header h3 {
    margin: 0;
    font-size: 1.5rem;
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 2rem;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.2s ease;
}

.close-btn:hover {
    transform: scale(1.2);
}

.dialog-body {
    padding: 30px;
    font-size: 1.1rem;
    line-height: 1.6;
    color: #333;
}

.dialog-body p {
    margin: 0;
    white-space: pre-line;
}

/* 动画效果 */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { 
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to { 
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* 套餐菜品项点击效果 */
.dish-item {
    padding: 6px 10px;
    margin-bottom: 6px;
    background-color: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid #27ae60;
    font-size: 0.85em;
    cursor: pointer;
    transition: all 0.2s ease;
}

/* 将所有第一个子元素的li边框从蓝色改为绿色 */
body > div:nth-child(1) > ul > li:nth-child(1) {
    border-left-color: #27ae60 !important;
}

/* 确保日历网格中所有第一个菜品项也改为绿色边框 */
.calendar-card ul > li:nth-child(1) {
    border-left-color: #27ae60;
}

/* 统一所有套餐标题样式 */

/* 统一所有卡片的header样式 */

.dish-item:hover {
    background-color: #e3f2fd;
    border-left-color: #2196f3;
    transform: translateX(3px);
}

.dish-item:active {
    transform: scale(0.98);
}

/* 套餐头部样式 - 全局统一 */
.combo-header {
    padding: 8px 12px;
    background-color: #f0f8ff;
    border-radius: 8px;
    margin-bottom: 8px;
    text-align: center;
}

.combo-header strong {
    color: #2c3e50;
    font-size: 0.9rem;
    font-weight: bold;
}

/* 仅桌面版样式，已移除响应式代码 */