/* 日程 App 样式文件 (灰色系) */
#schedule {
    background: #f9f9f9;
    padding-bottom: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    color: #333;
}

/* 顶部导航 */
#schedule .nav-bar {
    background: rgba(249, 249, 249, 0.9) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: none !important;
    padding-bottom: 10px !important;
    padding-top: max(env(safe-area-inset-top), 10px) !important;
}

/* 页眉区域 (周历或健康头部) */
#schedule-header-area {
    background: #f9f9f9;
    padding: 5px 20px 5px !important;
    margin-bottom: 0px;
    flex-shrink: 0;
}

/* --- 日程周历部分 --- */
.calendar-header {
    margin-bottom: 15px;
}
.calendar-date-display {
    font-size: 22px;
    font-weight: 700;
    color: #4a4a4a; /* 深灰色 */
    letter-spacing: 0.5px;
}
.calendar-actions .calendar-action-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #eaeaea;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-left: 10px;
    color: #666;
    font-size: 14px;
    cursor: pointer;
    background: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.02);
    transition: all 0.2s;
}
.calendar-actions .calendar-action-btn:active {
    transform: scale(0.95);
    background: #f5f5f5;
}

.calendar-week-strip {
    background: #fff;
    border-radius: 20px;
    padding: 15px 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}
.calendar-day-item {
    width: 40px;
    height: 56px;
    border-radius: 14px;
    position: relative;
    color: #8c8c8c;
    transition: all 0.3s;
}
.calendar-day-item.active {
    background: #4a4a4a; /* 深灰色 */
    color: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}
.calendar-day-item.active .day-name {
    color: rgba(255, 255, 255, 0.8);
}
.calendar-day-item.active .day-number {
    color: #fff;
}
.calendar-day-item .day-name {
    font-size: 11px;
    margin-bottom: 4px;
    font-weight: 500;
}
.calendar-day-item .day-number {
    font-size: 16px;
    font-weight: 600;
}
.calendar-day-item .day-dot {
    position: absolute;
    bottom: -8px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: #fff;
}

/* --- 主内容区通用 --- */
#schedule-main-content {
    background: #f9f9f9;
}

/* --- 待办时间轴 (全新设计) --- */
.timeline-container {
    padding: 10px 0;
    position: relative;
}
.timeline-item {
    margin-bottom: 25px;
    position: relative;
    display: flex;
    align-items: flex-start;
    z-index: 2;
}
.timeline-time-col {
    width: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
    flex-shrink: 0;
}
.timeline-time {
    font-size: 13px;
    font-weight: 600;
    color: #555;
    background: #f9f9f9;
    padding: 4px 0;
    z-index: 3;
}
.timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #555;
    background: #fff;
    margin: 8px 0;
    z-index: 3;
}
.timeline-card-col {
    flex: 1;
    padding-left: 15px;
}
.timeline-card {
    background: #fff;
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.03);
    transition: transform 0.2s, box-shadow 0.2s;
    position: relative;
}
/* 取消事件模块上的圆 */
/* .timeline-card::before { ... } */
.timeline-card:active {
    transform: scale(0.98);
}
.timeline-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    letter-spacing: 0.5px;
}

/* --- 表单样式 --- */
.schedule-form-input {
    width: 100%;
    padding: 12px 16px;
    background: #f5f5f5;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    font-size: 15px;
    color: #333;
    outline: none;
    box-sizing: border-box;
    margin-bottom: 15px;
}
.schedule-form-textarea {
    width: 100%;
    padding: 12px 16px;
    background: #f5f5f5;
    border: 1px solid #eaeaea;
    border-radius: 12px;
    font-size: 14px;
    color: #333;
    outline: none;
    resize: none;
    box-sizing: border-box;
    margin-bottom: 15px;
}
.schedule-mode-select {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}
.schedule-mode-btn {
    flex: 1;
    padding: 10px;
    text-align: center;
    background: #f5f5f5;
    border: 1px solid #eaeaea;
    border-radius: 10px;
    font-size: 14px;
    color: #666;
    cursor: pointer;
    transition: all 0.2s;
}
.schedule-mode-btn.active {
    background: #e8e8e8;
    color: #333;
    border-color: #d0d0d0;
    font-weight: 600;
}

/* --- 健康页眉与卡片 --- */
.health-nav-tabs {
    display: flex;
    gap: 15px;
    margin-bottom: 5px;
    background: #fff;
    padding: 4px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.02);
}
.health-nav-tab {
    flex: 1;
    text-align: center;
    padding: 8px 0;
    font-size: 15px;
    color: #888;
    font-weight: 600;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s;
}
.health-nav-tab.active {
    background: #fff;
    color: #333;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.health-header-card {
    display: flex;
    align-items: center;
    background: #fff;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.02);
}
.health-circle-chart {
    width: 100px;
    height: 100px;
    margin-right: 20px;
}
.health-svg {
    width: 100%;
    height: 100%;
}
.health-circle-inner {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
}
.health-circle-label {
    font-size: 10px;
    color: #999;
    margin-bottom: 2px;
}
.health-circle-value {
    font-size: 18px;
    font-weight: 800;
    color: #333;
    margin-bottom: 4px;
}
.health-circle-badge {
    font-size: 9px;
    background: #f5f5f5;
    color: #666;
    padding: 2px 6px;
    border-radius: 8px;
    font-weight: 600;
}
.health-info-right {
    flex: 1;
}
.health-info-title {
    font-size: 16px;
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}
.health-info-sub {
    font-size: 12px;
    color: #888;
    margin-bottom: 12px;
}
.health-legend-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}
.legend-item {
    font-size: 11px;
    color: #666;
    display: flex;
    align-items: center;
}
.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 4px;
    margin-right: 6px;
}

.health-calendar-card {
    background: #fff;
    border-radius: 20px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.02);
}
.health-cal-header {
    margin-bottom: 20px;
    padding: 0 10px;
}
.health-cal-week {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    font-size: 12px;
    color: #999;
    margin-bottom: 15px;
}
.health-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    text-align: center;
}
.health-cal-day {
    aspect-ratio: 1/1;
    border-radius: 12px;
    font-size: 14px;
    color: #333;
    font-weight: 500;
}
.bg-predict { background: #ffe6eb; color: #555; } /* 淡粉 预测/经期 */
.bg-fertile { background: #f0f8ff; color: #555; } /* 淡蓝 易孕 */
.bg-ovulation { background: #fffacd; color: #555; } /* 淡黄 排卵 */
.bg-safe { background: #f3e5f5; color: #555; } /* 淡紫 安全期 */
.bg-body-checked { background: #e6f7ff; color: #333; font-weight: bold; } /* 淡蓝 已打卡 */
.ring-active {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #e0e0e0;
}

.health-tips-card {
    background: #fff;
    border-radius: 20px;
    padding: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.03);
    border: 1px solid rgba(0,0,0,0.02);
}
.health-tips-dot {
    width: 8px; height: 8px; border-radius: 50%; background: #ffb6c1; margin-right: 8px;
}
.health-tips-title {
    font-size: 15px; font-weight: 600; color: #555; margin-bottom: 12px;
}
.health-tips-text {
    font-size: 13px; color: #666; line-height: 1.6; letter-spacing: 0.5px;
}


/* --- 底部 Tab Bar --- */
.schedule-tab-bar {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 85px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid rgba(0,0,0,0.05);
    padding: 10px 20px env(safe-area-inset-bottom);
    z-index: 100;
}
.schedule-tab-item {
    flex: 1;
    color: #b2b2b2;
    cursor: pointer;
    transition: color 0.3s;
}
.schedule-tab-item.active {
    color: #333;
}
.schedule-tab-item.active .schedule-tab-icon {
    background: #e8e8e8;
}
.schedule-tab-icon {
    font-size: 20px;
    margin-bottom: 4px;
    width: 44px; 
    height: 32px; 
    border-radius: 16px;
    transition: background 0.3s;
}
.schedule-tab-item span {
    font-size: 10px;
    font-weight: 500;
}
.schedule-fab {
    position: absolute;
    right: 20px;
    top: -75px; 
    width: 56px;
    height: 56px;
    border-radius: 28px;
    background: #555; /* 灰色 */
    color: #fff;
    font-size: 22px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    cursor: pointer;
    transition: transform 0.2s;
    z-index: 110;
}
.schedule-fab:active {
    transform: scale(0.9);
}

/* --- 详情页弹窗 --- */
#schedule-detail-overlay {
    background: rgba(0,0,0,0.4);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
}
.schedule-detail-card {
    background: #fff;
    width: 320px;
    border-radius: 32px;
    padding: 30px 24px;
    position: relative;
    box-shadow: 0 24px 48px rgba(0,0,0,0.15);
    animation: popupFade 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
@keyframes popupFade {
    from { opacity: 0; transform: scale(0.95) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}
.detail-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 32px;
    height: 32px;
    border-radius: 16px;
    background: #f5f5f5;
    display: flex; justify-content: center; align-items: center;
    color: #888;
    cursor: pointer;
}
.detail-header {
    margin-bottom: 30px;
    padding-right: 40px;
}
.detail-title {
    font-size: 18px; font-weight: 700; color: #333;
}
.detail-status {
    font-size: 12px; color: #666; background: #f0f0f0; padding: 4px 10px; border-radius: 10px;
}

.detail-main-info {
    align-items: center;
    margin-bottom: 30px;
}
.detail-icon-large {
    width: 80px; height: 80px; border-radius: 24px; background: #f5f6f8; font-size: 40px; margin-bottom: 16px; box-shadow: inset 0 2px 8px rgba(0,0,0,0.02);
}
.detail-title-large {
    font-size: 22px; font-weight: 800; color: #333; margin-bottom: 8px; text-align: center;
}
.detail-time-display {
    font-size: 14px; color: #666; font-family: monospace;
}

.detail-section {
    margin-bottom: 20px;
}
.detail-section-title {
    font-size: 13px; color: #999; font-weight: 600; margin-bottom: 10px; letter-spacing: 1px;
}

.detail-feedback-card {
    background: #fdfdfd; border: 1px solid #eaeaea; border-radius: 16px; padding: 16px;
}
.empty-feedback {
    padding: 30px 0; color: #999; font-size: 13px;
}
.feedback-header { margin-bottom: 10px; }
.feedback-title { font-size: 14px; font-weight: 600; color: #333; }
.feedback-score { font-size: 18px; font-weight: 800; color: #666; }
.feedback-comment { font-size: 14px; color: #444; line-height: 1.6; margin-bottom: 10px; font-style: italic; }
.feedback-whisper { font-size: 12px; color: #888; background: #f5f5f5; padding: 8px 12px; border-radius: 8px; }

.detail-btn {
    flex: 1; padding: 14px 0; border-radius: 16px; font-size: 15px; font-weight: 600; cursor: pointer; border: none; transition: transform 0.2s;
}
.detail-btn:active { transform: scale(0.95); }
.btn-delete { background: #fff; border: 1px solid #ffe5e5; color: #ff3b30; margin-right: 10px; }
.btn-primary { background: #444; color: #fff; box-shadow: 0 8px 20px rgba(0,0,0,0.1); }
