.calendar-table td {
    vertical-align: middle;
    text-align: center;
    width: 14.28%;
    padding: 4px 0;
    transition: background-color 0.15s ease;
    cursor: default;
    vertical-align: top;          /* 关键：顶部对齐 */
    padding: 4px;
    box-sizing: border-box;
}
/* 鼠标悬停时仅当前单元格变色 */
.calendar-table td:hover {
    background-color: #e9ecef;
}
.date-number {
    font-size: 1.6rem;
    font-weight: 700;
    color: #2c3e50;
    line-height: 1.3;
}
.date-lunar {
    font-size: 0.75rem;
    color: #9aa5b1;
    line-height: 1.3;
}
.date-ganzhi {
    font-size: 0.7rem;
    line-height: 1.3;
    color: #6c5b7b;
    font-weight: 600;

}
.date-festival {
    font-size: 0.7rem;
    line-height: 1.3;
    color: #e74c3c; 
    padding: 2px 2px 2px 2px;
    display: block;     /* 适应内容宽度 */
    margin-top: 1px;
}
.other-month {
    opacity: 0.4;
}
.cur-day {
    opacity: 0.4;
}
.calendar-header {
    font-weight: 600;
    background-color: #f8f9fa;
}
.card-header h4 {
    font-weight: 500;
}


/* 今日格子背景色（淡蓝色） */
.calendar-table td.today {
    background-color: #fff3cd !important;  /* 浅绿色，表示今天 */
    border-color: #ffc107;
    box-shadow: 0 0 0 1px #ffc107;          /* 绿色边框强调 */
}

/* 若需要与其他状态（如悬停）区分，可叠加 */
.calendar-table td.today .date-number {
    color: #155724;                         /* 深绿色数字 */
    font-weight: 700;
}

/* 保持其他元素颜色清晰 */
.calendar-table td.today .date-lunar {
    color: #155724;
}
.calendar-table td.today .date-ganzhi {
    color: #155724;
}







.custom-box {
    background: #ffffff;
    border: 1px solid #d6cec0;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}
.text-gan {
    color: #1f543e;   /* 天干绿色调 */
}
.text-zhi {
    color: #a63c2c;   /* 地支红色调 */
}
.badge-yi {
    display: inline-block;
    background-color: #e8f5e9;   /* 极淡绿 */
    color: #1e4620;              /* 深绿色文字（保留可读性） */
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.badge-ji {
    display: inline-block;
    background-color: #ffebee;   /* 极淡红 */
    color: #6d1a1a;              /* 深红色文字 */
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}
.pillar-label {
    font-size: 0.7rem;
    color: #887a6b;
    margin-top: 2px;
}
.divider-custom {
    border-top: 1px solid #e8e0d6;
}
@media (max-width: 576px) {
    .pillar-group {
        min-width: 40px;
    }
}










.card-custom {
    max-width: 780px;
    margin: 0 auto;
    border-radius: 16px;
    border: 1px solid #d0d0d0;
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.06);
    overflow: hidden;
}
/* 网格容器：每个单元格有边框 */
.grid-row {
    --bs-gutter-x: 0;
    --bs-gutter-y: 0;
}
.grid-row > [class*="col-"],
.grid-row > .col,
.grid-row > .col-auto {
    border-right: 1px solid #d0d0d0;
    border-bottom: 1px solid #d0d0d0;
    padding: 8px 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.grid-row > [class*="col-"]:last-child,
.grid-row > .col:last-child,
.grid-row > .col-auto:last-child {
    border-right: none;
}
/* 最后一行无底边框（但内部子元素有分隔线） */
.grid-row:last-child > [class*="col-"],
.grid-row:last-child > .col,
.grid-row:last-child > .col-auto {
    border-bottom: none;
}
/* 特殊：时辰左侧固定宽度 */
.hour-label {
    flex: 0 0 55px;
    border-right: 1px solid #d0d0d0;
    border-bottom: 1px solid #d0d0d0;
    padding: 8px 4px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
.hour-grid {
    display: flex;
    flex-wrap: nowrap;
    width: 100%;
}
.hour-grid .hour-item {
    flex: 1 0 0;
    text-align: center;
    padding: 8px 0;
    border-right: 1px solid #d0d0d0;
    font-size: 12px;
}
.hour-grid .hour-item:last-child {
    border-right: none;
}
.hour-highlight {
    font-weight: 700;
    background-color: #fff3cd !important;  /* 浅绿色，表示今天 */
    border-color: #ffc107;
    box-shadow: 0 0 0 1px #ffc107;          /* 绿色边框强调 */
    color: #155724;    
    
}
/* 侧边固定宽度（建除、星宿） */
.side-col {
    flex: 0 0 60px;
    border-right: 1px solid #d0d0d0;
    border-bottom: 1px solid #d0d0d0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 8px 0;
}
.side-col:last-child {
    border-right: none;
}
/* 文字颜色 */
.primary-text {
    color: #ff7846;
    font-weight: 600;
}
.default-text {
    color: #333;
}
.vertical-text {
    writing-mode: vertical-lr;
    letter-spacing: 2px;
    font-size: 13px;
    line-height: 1.6;
}

.fc-t{
    font-weight: 600;
    font-size: 13px;
    padding: 2px 0;
    color: #ff7846;
}

.fc-d{
    font-size: 13px;
    padding: 2px 0;
    color: #333;
}