.lich-thien-phuc-container {
    max-width: 1200px;
    margin: 0 auto;
    overflow: hidden;
    box-sizing: border-box;
    width: 100%;
}

/* Responsive padding for smaller screens */
@media (max-width: 768px) {
    .lich-thien-phuc-container {
        padding-top: 30px;
    }
}

@media (max-width: 576px) {
    .lich-thien-phuc-container {
        padding-top: 20px;
    }
}

/* Phần giới thiệu */
.lich-intro {
    padding: 12px 0 4px 0;
}

/* Toggle button cho intro */
.intro-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 20px;
    margin: 15px 0;
    background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.875rem;
    /* 14px - var(--text-sm) */
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(211, 47, 47, 0.3);
}

.intro-toggle-btn:hover {
    background: linear-gradient(135deg, #b71c1c 0%, #8b0000 100%);
    box-shadow: 0 4px 12px rgba(211, 47, 47, 0.4);
    transform: translateY(-2px);
}

.intro-toggle-btn .toggle-icon {
    transition: transform 0.3s ease;
    font-size: 0.75rem;
    /* 12px - var(--text-xs) */
}

.intro-toggle-btn.expanded .toggle-icon {
    transform: rotate(180deg);
}

/* Collapsible content */
.intro-collapsible {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.3s ease, padding 0.3s ease;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
}

.intro-collapsible.expanded {
    max-height: 3000px;
    opacity: 1;
    padding-top: 10px !important;
    padding-bottom: 10px !important;
}

.lich-intro h1,
.lich-intro h2 {
    font-size: 1.875rem;
    /* 30px - var(--text-3xl) */
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 10px 0;
    text-align: center;
}

.slogan {
    font-style: italic;
    text-align: center;
    color: #d32f2f;
    font-size: 1rem;
    /* 16px - var(--text-base) */
    margin-bottom: 30px;
}

.intro-content {
    background: #f8f9fa;
    padding: 10px;
    border-radius: 8px;
    margin-top: 20px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.intro-content h3 {
    font-size: 1.25rem;
    /* 20px - var(--text-xl) */
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 15px 0;
}

.intro-content p {
    font-size: 0.9375rem;
    /* 15px - close to var(--text-sm) */
    line-height: 1.7;
    color: #495057;
    margin: 0 0 15px 0;
}

.intro-content ul {
    margin: 15px 0;
    padding-left: 25px;
}

.intro-content li {
    font-size: 0.9375rem;
    /* 15px */
    line-height: 1.8;
    color: #495057;
    margin-bottom: 8px;
}

.intro-content li strong {
    color: #d32f2f;
}

.intro-section {
    margin-top: 20px;
    padding: 18px 20px;
    border-top: none;
    background: #FAF6F0;
    border-radius: 12px;
}

.intro-section:first-of-type {
    border-top: none;
    margin-top: 0;
}

.intro-section h4 {
    font-size: 1.125rem;
    /* 18px - var(--text-lg) */
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 12px 0;
}

.intro-note {
    background: #FEF3C7;
    padding: 15px 18px;
    border-radius: 10px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    margin-top: 15px;
    font-size: 0.875rem;
    /* 14px - var(--text-sm) */
    line-height: 1.6;
}

.intro-source {
    margin-top: 20px;
    padding: 15px 18px;
    border-top: none;
    background: #ECFDF5;
    border-radius: 10px;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    font-size: 0.8125rem;
    /* 13px - close to var(--text-sm) */
    color: #065F46;
}

.intro-source a {
    color: #d32f2f;
    text-decoration: none;
}

.intro-source a:hover {
    text-decoration: underline;
}

/* Controls wrapper */
.lich-controls-wrapper {
    background: #FAF6F0;
    padding: 18px 22px;
    border-radius: 14px;
    margin: 15px 0;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

.controls-title {
    font-size: 1rem;
    /* 16px - var(--text-base) */
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 12px 0;
    text-align: center;
}

.lich-controls {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.control-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    align-items: stretch;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

.lich-controls .control-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: #FFFFFF;
    padding: 14px;
    border-radius: 12px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    transition: all 0.3s ease;
    min-height: 100%;
    box-sizing: border-box;
}

.lich-controls .control-group:hover {
    border: none;
    box-shadow: 0 8px 26px rgba(153, 27, 27, 0.08);
}

.lich-controls .control-group label {
    font-size: 0.8125rem;
    /* 13px */
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0;
    display: block;
    line-height: 1.3;
}

.input-wrapper {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.input-hint {
    font-size: 0.76rem;
    font-weight: 500;
    color: #64748b;
    font-style: normal;
    margin-top: 4px;
    line-height: 1.4;
}

.date-input-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.date-select-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.date-separator {
    font-size: 1.125rem;
    /* 18px - var(--text-lg) */
    color: #6c757d;
    font-weight: 600;
}

.day-select,
.month-select {
    flex: 1;
    min-width: 90px;
}

.year-input {
    flex: 1;
    min-width: 100px;
}

/* Input và Select styles */
.lich-controls input[type="date"],
.lich-controls input[type="number"],
.lich-controls select {
    height: 42px;
    border-radius: 10px;
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
    font-family: inherit;
    background: #FAF6F0;
    border: 1px solid rgba(153, 27, 27, 0.14);
    color: #1e293b;
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.04);
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

.lich-controls input[type="date"]:focus,
.lich-controls input[type="number"]:focus,
.lich-controls select:focus {
    outline: none;
    border-color: rgba(153, 27, 27, 0.35);
    box-shadow: 0 0 0 3px rgba(185, 28, 28, 0.14);
    background: #FFFFFF;
}

.lich-controls input[type="date"]:hover,
.lich-controls input[type="number"]:hover,
.lich-controls select:hover {
    border-color: rgba(153, 27, 27, 0.28);
    background: #FAF6F0;
}

.month-select {
    flex: 1;
    min-width: 120px;
}

.year-input {
    flex: 1;
    min-width: 100px;
}

/* Style cho optgroup trong select */
.purpose-select optgroup {
    font-weight: 700;
    font-size: 0.8125rem;
    /* 13px */
    color: #495057;
    background: #f8f9fa;
    padding: 5px 0;
}

.purpose-select option {
    font-weight: 400;
    padding: 8px 12px;
    font-size: 0.8125rem;
    /* 13px */
}

.purpose-select {
    width: 100%;
}

/* Button */
.control-submit {
    display: flex;
    flex-direction: column;
    gap: 10px;
    justify-content: flex-end;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

.btn-view-calendar {
    height: 42px;
    background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
    color: white;
    border: none;
    padding: 0 20px;
    border-radius: 10px;
    font-size: 0.875rem;
    /* 14px - var(--text-sm) */
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    box-shadow: 0 2px 8px rgba(185, 28, 28, 0.25);
    white-space: nowrap;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.btn-view-calendar:hover {
    background: linear-gradient(135deg, #b71c1c 0%, #8b0000 100%);
    box-shadow: 0 6px 16px rgba(211, 47, 47, 0.4);
    transform: translateY(-2px);
}

.btn-view-calendar:active {
    transform: translateY(0);
    box-shadow: 0 2px 6px rgba(211, 47, 47, 0.3);
}

/* Responsive */
@media (max-width: 768px) {
    .control-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .lich-controls {
        gap: 10px;
    }

    .lich-controls .control-group {
        padding: 10px;
    }

    .date-input-wrapper,
    .date-select-wrapper {
        flex-wrap: wrap;
        gap: 8px;
    }

    .day-select,
    .month-select,
    .year-input {
        flex: 1;
        min-width: 80px;
    }

    .lich-intro h2 {
        font-size: 1.5rem;
        /* 24px */
    }

    .intro-content {
        padding: 20px;
    }

    .lich-controls-wrapper {
        padding: 12px 15px;
    }

    .controls-title {
        font-size: 0.9375rem;
        /* 15px */
        margin-bottom: 10px;
    }

    .intro-source {
        text-align: center;
    }

    .btn-view-calendar {
        padding: 9px 20px;
        font-size: 0.875rem;
        /* 14px */
    }

    /* Calendar responsive */
    .lich-thien-phuc-container {
        box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
    }

    .lich-intro {
        margin-bottom: 20px;
    }

    .lich-intro h2 {
        font-size: 1.25rem;
        /* 20px */
    }

    .intro-content {
        padding: 15px;
    }

    .lich-controls-wrapper {
        padding: 12px 10px;
        margin: 10px 0;
    }

    .lich-table {
        font-size: 0.6875rem;
        /* 11px */
        border-spacing: 4px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        display: table !important;
        table-layout: fixed;
    }

    /* Ẩn header row trên mobile */
    .lich-table .table-header-row {
        display: none;
    }

    .lich-table thead {
        display: none;
    }

    .lich-table tbody {
        display: table-row-group !important;
        width: 100%;
        box-sizing: border-box;
    }

    .lich-table th {
        padding: 8px 4px;
        font-size: 0.625rem;
        /* 10px */
    }

    /* Trên mobile: 2 cột 1 hàng */
    .lich-table tr {
        display: table-row !important;
        width: 100%;
        box-sizing: border-box;
    }

    .lich-table td {
        display: table-cell !important;
        width: 50% !important;
        max-width: 50% !important;
        box-sizing: border-box;
        padding: 0 !important;
        vertical-align: top;
    }

    /* Override theme CSS cho entry-content trên mobile */
    .entry-content .lich-table td,
    .entry-content .lich-table th {
        padding: 0 !important;
    }

    .lich-day {
        border-radius: 10px;
        border: none;
        box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
        transition: transform .2s ease, box-shadow .2s ease;
    }

    .lich-day:hover {
        transform: translateY(-1px);
        box-shadow: 0 8px 24px rgba(15, 23, 42, 0.09);
    }


    /* Phân biệt ngày dương và ngày âm trên mobile - sử dụng rule cụ thể trong day-header */
    /* Note: day-level, day-info, day-info-item sử dụng rule desktop, không cần override riêng */

    .calendar-legend {
        padding: 10px 8px;
        margin: 12px 0;
    }

    .calendar-legend h4 {
        font-size: 0.8125rem;
        /* 13px */
        margin-bottom: 8px;
    }

    .legend-items {
        gap: 8px;
        margin-bottom: 8px;
    }

    .legend-item {
        font-size: 0.625rem;
        /* 10px */
        gap: 5px;
    }

    .legend-color {
        width: 18px;
        height: 18px;
    }

    .legend-note {
        font-size: 0.625rem;
        /* 10px */
        margin-top: 8px;
        padding-top: 8px;
    }

    /* Navigation responsive */
    .nav-bar a {
        padding: 8px 10px !important;
        margin: 0 3px !important;
        min-width: 80px !important;
    }

    .nav-bar a .nav-label {
        font-size: 0.75rem;
        /* 12px */
    }

    .nav-bar a .nav-date {
        font-size: 0.625rem;
        /* 10px */
    }
}

/* Bài viết cuối trang */
.lich-article-footer {
    margin-top: 40px;
    padding: 30px;
    background: #FAF6F0;
    border-radius: 14px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
    position: relative !important;
    z-index: 1 !important;
}

.lich-article {
    margin: 0 auto;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: hidden !important;
    width: 100%;
    box-sizing: border-box;
    padding: 0;
}

.lich-article section {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    height: auto !important;
    overflow: visible !important;
}

.lich-article h2 {
    font-size: 1.75rem;
    /* 28px */
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 25px;
    text-align: center;
    padding-bottom: 12px;
    border-bottom: none;
}

.lich-article section {
    margin-bottom: 30px;
}

.lich-article h3 {
    font-size: 1.375rem;
    /* 22px */
    font-weight: 700;
    color: #d32f2f;
    margin-bottom: 15px;
    margin-top: 25px;
}

.lich-article h4 {
    font-size: 1.125rem;
    /* 18px */
    font-weight: 600;
    color: #333;
    margin-bottom: 12px;
    margin-top: 20px;
}

.lich-article p {
    font-size: 1rem;
    /* 16px */
    line-height: 1.8;
    color: #555;
    margin-bottom: 15px;
    text-align: justify;
}

.lich-article ul,
.lich-article ol {
    margin: 15px 0;
    padding-left: 30px;
}

.lich-article li {
    font-size: 1rem;
    /* 16px */
    line-height: 1.8;
    color: #555;
    margin-bottom: 10px;
}

.lich-article li strong {
    color: #d32f2f;
    font-weight: 600;
}

@media (max-width: 768px) {
    .lich-article-footer {
        padding: 15px 10px;
        margin-top: 20px;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        height: auto !important;
        overflow: hidden !important;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .lich-article {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        height: auto !important;
        overflow: hidden !important;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
        padding: 0;
    }

    .lich-article section {
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
        height: auto !important;
        overflow: hidden !important;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .lich-article h2 {
        font-size: 1.5rem;
        /* 22px - var(--text-2xl) */
        display: block !important;
        visibility: visible !important;
    }

    .lich-article h3 {
        font-size: 1.125rem;
        /* 18px */
        display: block !important;
        visibility: visible !important;
    }

    .lich-article h4 {
        font-size: 1rem;
        /* 16px */
        display: block !important;
        visibility: visible !important;
    }

    .lich-article p,
    .lich-article li {
        font-size: 0.875rem;
        /* 14px */
        display: block !important;
        visibility: visible !important;
    }

    .lich-article ul,
    .lich-article ol {
        display: block !important;
        visibility: visible !important;
    }
}

/* ===== CALENDAR TABLE 2 CỘT - Giống mẫu ===== */
.lich-table-2col {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background: #FFFFFF;
    border-radius: 16px;
    overflow: hidden;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.lich-table-2col thead th {
    background: #FEF3C7;
    color: #78350F;
    padding: 15px;
    font-weight: 700;
    font-size: 0.875rem;
    /* 14px */
    text-align: center;
    border: none;
    text-transform: uppercase;
}

.lich-table-2col thead .col-date {
    width: 200px;
    border-right: none;
}

.lich-table-2col thead .col-info {
    text-align: left;
    padding-left: 20px;
}

/* Mỗi hàng trong table */
.lich-day-row {
    border: none;
    cursor: pointer;
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

.lich-day-row:nth-child(even) {
    background: #FAF6F0;
}

.lich-day-row:hover {
    background: #F7F4EF;
}

.lich-day-row.today {
    background: #FEF3C7 !important;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.lich-day-row.today .date-cell::before {
    content: 'HÔM NAY';
    text-align: center;
    display: block;
    background: #d32f2f;
    color: white;
    font-weight: 700;
    padding: 3px 10px;
    margin-bottom: 10px;
    border-radius: 10px;
    z-index: 10;
}


.lich-day-row.today .info-cell {
    border-right: none;
}

@media (max-width: 768px) {
    .lich-day-row.today {
        border: none !important;
        position: relative;
        z-index: 2;
        box-shadow: 0 8px 26px rgba(185, 28, 28, 0.14);
    }

    .lich-day-row.today::before {
        content: "HÔM NAY";
        position: absolute;
        top: 10px;
        right: 10px;
        background: #d32f2f;
        color: white;
        font-size: 0.625rem;
        /* 10px */
        font-weight: 700;
        padding: 3px 10px;
        border-radius: 10px;
        z-index: 10;
    }
}

/* Cột trái: Ngày */
.date-cell {
    width: 200px;
    padding: 15px;
    text-align: center;
    vertical-align: top;
    border-right: none;
    background: #FAF6F0;
}

@media (max-width: 768px) {
    .lich-table-2col {
        display: block !important;
        background: transparent !important;
        box-shadow: none !important;
    }

    .lich-table-2col tbody {
        display: block !important;
    }

    .lich-table-2col thead {
        display: none;
    }

    .lich-table-2col .lich-day-row {
        display: flex !important;
        flex-direction: column !important;
        margin-bottom: 20px;
        border: none;
        border-radius: 14px;
        overflow: hidden;
        background: #FFFFFF;
        box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    }

    .date-cell {
        display: block !important;
        width: 100% !important;
        border-right: none;
        border-bottom: none;
        padding: 20px 15px;
        background: #FAF6F0;
    }

    .info-cell {
        display: block !important;
        width: 100% !important;
        padding: 15px !important;
    }

    .day-solar-big {
        font-size: 3.25rem !important;
        /* 52px */
    }

    .day-lunar-big {
        font-size: 2.625rem !important;
        /* 42px */
    }
}

/* Badge level ở đầu - 7 cấp độ theo chú thích */
.level-badge-top {
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 0.8125rem;
    /* 13px */
    font-weight: 700;
    margin-bottom: 15px;
    display: inline-block;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    color: white;
}

/* 1. Rất Tốt (Đại Lợi) - Xanh lá đậm */
.level-badge-top.rat-tot {
    background: #51cf66;
    box-shadow: 0 3px 6px rgba(81, 207, 102, 0.4);
}

/* 2. Tương đối Tốt (Tiểu Cát) - Xanh lá nhạt */
.level-badge-top.tuong-doi-tot {
    background: #74c69d;
    box-shadow: 0 3px 6px rgba(116, 198, 157, 0.4);
}

/* 3. Trên Trung Bình - Xanh dương */
.level-badge-top.tren-trung-binh {
    background: #4dabf7;
    box-shadow: 0 3px 6px rgba(77, 171, 247, 0.4);
}

/* 4. Trung Bình - Vàng */
.level-badge-top.trung-binh {
    background: #ffd43b;
    color: #333;
    box-shadow: 0 3px 6px rgba(255, 212, 59, 0.4);
}

/* 5. Dưới Trung Bình (Tiểu Hung) - Cam */
.level-badge-top.duoi-trung-binh {
    background: #ffb74d;
    box-shadow: 0 3px 6px rgba(255, 183, 77, 0.4);
}

/* 6. Tương đối Xấu - Hồng */
.level-badge-top.tuong-doi-xau {
    background: #ff8fa3;
    box-shadow: 0 3px 6px rgba(255, 143, 163, 0.4);
}

/* 7. Cực Xấu (Đại Kỵ) - Đỏ */
.level-badge-top.cuc-xau {
    background: #ff6b6b;
    box-shadow: 0 3px 6px rgba(255, 107, 107, 0.4);
}


/* Ngày dương + âm nằm ngang (2 cột) */
.date-dual-row {
    display: flex;
    justify-content: space-around;
    gap: 10px;
    margin-bottom: 15px;
}

.date-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 5px;
    text-align: center;
}

.lich-duong-label,
.lich-am-label {
    background: #1565c0;
    color: white;
    padding: 3px 6px;
    border-radius: 4px;
    font-size: 0.625rem;
    /* 10px */
    font-weight: 600;
}

.lich-am-label {
    background: #6a1b9a;
}

.day-solar-big,
.day-lunar-big {
    font-size: 2.625rem;
    /* 42px */
    font-weight: 700;
    color: #c62828;
    line-height: 1;
    margin: 3px 0;
}

.day-lunar-big {
    padding-top: 5px;
    font-size: 2.25rem;
    /* 36px */
    color: #6a1b9a;
}

.month-label,
.month-lunar-label {
    font-size: 0.75rem;
    /* 12px */
    color: #666;
    font-weight: 500;
}

/* Sao xấu + Tiết khí */
.date-extra-info {
    margin: 10px 0;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.extra-item {
    padding: 5px 8px;
    border-radius: 5px;
    font-size: 0.6875rem;
    /* 11px */
    font-weight: 600;
    text-align: left;
}

.extra-item.bad {
    background: #ffebee;
    color: #c62828;
}

.extra-item.neutral {
    background: #e8f5e9;
    color: #2e7d32;
}

.holiday-badge {
    background: #ff5252;
    color: white;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.6875rem;
    /* 11px */
    font-weight: 600;
    margin-top: 8px;
}

/* Responsive: Mobile quay lại dọc */
@media (max-width: 768px) {
    .date-dual-row {
        flex-direction: row;
        /* Giữ ngang trên mobile nhưng cân đối lại */
        justify-content: center;
        gap: 30px;
        margin-bottom: 10px;
    }

    .date-column {
        align-items: center;
    }
}

@media (max-width: 480px) {
    .date-dual-row {
        gap: 15px;
    }

    .day-solar-big {
        font-size: 2.875rem !important;
        /* 46px */
    }

    .day-lunar-big {
        font-size: 2.375rem !important;
        /* 38px */
    }
}

/* Cột phải: Thông tin */
.info-cell {
    padding: 20px;
    vertical-align: top;
}

.day-title {
    font-size: 1.0625rem;
    /* 17px */
    font-weight: 700;
    color: #c62828;
    margin-bottom: 12px;
    line-height: 1.4;
}

.basic-info {
    font-size: 0.875rem;
    /* 14px */
    margin-bottom: 10px;
    color: #444;
}

.gio-tot-line {
    font-size: 0.8125rem;
    /* 13px */
    margin-bottom: 10px;
    color: #555;
}

/* Mâm cúng suggestions - dạng inline tags */
.day-mam-suggestions {
    margin: 10px 0;
    line-height: 2;
}

.day-mam-suggestions .mam-title {
    font-weight: 600;
    color: #333;
    margin-right: 5px;
}

/* Mâm cúng ở cột trái - Gọn và đẹp */
.mam-cung-left {
    margin-top: 20px;
    padding: 14px;
    background: #FAF6F0;
    border-radius: 10px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.mam-title-small {
    font-size: 0.6875rem;
    /* 11px */
    font-weight: 700;
    color: #1565c0;
    margin-bottom: 8px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.mam-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
}

.mam-tag-small {
    display: inline-block;
    background: #e3f2fd;
    color: #1565c0;
    padding: 3px 10px;
    border-radius: 12px;
    font-size: 0.6875rem;
    /* 11px */
    white-space: nowrap;
    font-weight: 500;
    border: none;
}

.mam-tag-small.mam-priority {
    background: #FEF3C7;
    color: #92400E;
    font-weight: 600;
    border: none;
}

.mam-tag-small.mam-special {
    background: #fce4ec;
    color: #c2185b;
    font-weight: 600;
    border: none;
}

/* Link xem chi tiết - Đơn giản, không nền */
.detail-link {
    display: inline-block;
    color: #1565c0;
    text-decoration: none;
    font-size: 0.75rem;
    /* 12px */
    font-weight: 600;
}

.detail-link:hover {
    text-decoration: underline;
    color: #0d47a1;
}

.mam-tag {
    display: inline-block;
    background: #e3f2fd;
    color: #1565c0;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 0.75rem;
    /* 12px */
    margin: 2px;
    white-space: nowrap;
    border: none;
}

.mam-tag.mam-priority {
    background: #FEF3C7;
    color: #92400E;
    font-weight: 600;
    border: none;
}

.mam-tag.mam-special {
    background: #fce4ec;
    color: #c2185b;
    font-weight: 600;
    border: none;
}

.btn-mam-cung {
    display: inline-block;
    background: #d32f2f;
    color: white;
    padding: 4px 12px;
    border-radius: 15px;
    text-decoration: none;
    font-size: 0.875rem;
    /* 14px */
    font-weight: 600;
    margin-left: 5px;
    border: none;
}

.btn-mam-cung:hover {
    background: #b71c1c;
}

/* Lời khuyên - Không có badge */
.advice-section {
    margin: 16px 0;
    padding: 16px 20px;
    background: #FAF6F0;
    border-radius: 12px;
    border: none;
    position: relative;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.advice-gioTot {
    color: #1565c0;
    margin-bottom: 8px;
    font-size: 0.8125rem;
    /* 13px */
    font-weight: 500;
}

.advice-text {
    color: #555;
    font-size: 0.8125rem;
    /* 13px */
    line-height: 1.8;
}

/* Highlight các từ khóa quan trọng về ngày */
.advice-text strong {
    font-weight: 700;
    color: #d32f2f;
}

/* Tô màu background cho các loại ngày - Tốt */

/* Highlight inline cho các từ "Ngày" kèm mô tả */


/* Thông tin tuổi - Tốt/Hung với tuổi */
.birth-info-section {
    margin: 12px 0;
    padding: 10px 12px;
    border-radius: 6px;
    font-size: 0.8125rem;
    /* 13px */
    line-height: 1.5;
}

/* Birth marks - Tam Hợp (Rất tốt) - Xanh Lá */
.birth-tam-hop {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #51cf66, #37b24d);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(81, 207, 102, 0.4), 0 0 0 3px rgba(81, 207, 102, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-green 2s ease-in-out infinite;
}

/* Birth marks - Lục Hợp (Tốt) - Xanh Dương */
.birth-luc-hop {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #339af0, #1c7ed6);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(51, 154, 240, 0.4), 0 0 0 3px rgba(51, 154, 240, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-blue 2s ease-in-out infinite;
}

/* Birth marks - Xung (Hung) - Đỏ */
.birth-xung {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4), 0 0 0 3px rgba(255, 107, 107, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-red 2s ease-in-out infinite;
}

/* Birth marks - Bình thường - Xanh dương nhạt */
.birth-neutral {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #10c6fd, #1576f5);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4), 0 0 0 3px rgba(255, 107, 107, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-red 2s ease-in-out infinite;
}

/* Animations */
@keyframes glow-pulse-green {

    0%,
    100% {
        box-shadow: 0 6px 20px rgba(81, 207, 102, 0.4), 0 0 0 3px rgba(81, 207, 102, 0.2);
    }

    50% {
        box-shadow: 0 8px 25px rgba(81, 207, 102, 0.6), 0 0 0 4px rgba(81, 207, 102, 0.3);
    }
}

@keyframes glow-pulse-blue {

    0%,
    100% {
        box-shadow: 0 6px 20px rgba(51, 154, 240, 0.4), 0 0 0 3px rgba(51, 154, 240, 0.2);
    }

    50% {
        box-shadow: 0 8px 25px rgba(51, 154, 240, 0.6), 0 0 0 4px rgba(51, 154, 240, 0.3);
    }
}

@keyframes glow-pulse-red {

    0%,
    100% {
        box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4), 0 0 0 3px rgba(255, 107, 107, 0.2);
    }

    50% {
        box-shadow: 0 8px 25px rgba(255, 107, 107, 0.6), 0 0 0 4px rgba(255, 107, 107, 0.3);
    }
}

/* Legacy classes for backwards compatibility */
.birth-good-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #51cf66, #37b24d);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(81, 207, 102, 0.4), 0 0 0 3px rgba(81, 207, 102, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-green 2s ease-in-out infinite;
}

.birth-bad-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #ff6b6b, #ee5a6f);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4), 0 0 0 3px rgba(255, 107, 107, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-red 2s ease-in-out infinite;
}

.birth-neutral-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #10c6fd, #1576f5);
    border-radius: 25px;
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4), 0 0 0 3px rgba(255, 107, 107, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-red 2s ease-in-out infinite;
}

/* Màu sắc theo mức độ */
.lich-day-row.rat-tot-dai-loi .date-cell {
    background: #c8e6c9 !important;
}

.lich-day-row.tuong-doi-tot-tieu-cat .date-cell {
    background: #fff9c4 !important;
}

.lich-day-row.cuc-xau-dai-ky .date-cell {
    background: #ffcdd2 !important;
}

/* Calendar Table Styles */
.lich-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 3px;
    background: #f8f9fa;
    table-layout: fixed;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin: 20px 0;
    display: table !important;
}

.lich-table tbody {
    display: table-row-group !important;
}

.lich-table tr {
    display: table-row !important;
}

.lich-table td {
    width: 14.28%;
    display: table-cell !important;
    vertical-align: top;
    padding: 0 !important;
}

.lich-day-empty {
    width: 14.28%;
    display: table-cell !important;
    padding: 0 !important;
    border: none;
    background: transparent;
}

/* Override theme CSS cho entry-content */
.entry-content .lich-table td,
.entry-content .lich-table th {
    padding: 0 !important;
}

.lich-table th {
    background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
    color: white;
    padding: 12px 8px !important;
    font-weight: 700;
    font-size: 0.875rem;
    /* 14px */
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.lich-day {
    padding: 8px 6px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    box-sizing: border-box;
    position: relative;
    vertical-align: top;
    height: 280px !important;
    min-height: 280px !important;
    max-height: 280px !important;
    width: 100%;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    border-radius: 12px;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.lich-day:hover {
    border: none !important;
    box-shadow: 0 8px 26px rgba(185, 28, 28, 0.18) !important;
    transform: translateY(-2px);
    z-index: 2;
}

/* ===== NGÀY HIỆN TẠI (TODAY) ===== */
.lich-day.today,
.lich-day-item.today {
    border: none !important;
    box-shadow: 0 0 0 4px rgba(211, 47, 47, 0.25), 0 8px 26px rgba(211, 47, 47, 0.3) !important;
    position: relative;
    z-index: 5;
    animation: todayPulse 2s ease-in-out infinite;
}

.lich-day.today::before,
.lich-day-item.today::before {
    content: "HÔM NAY";
    position: absolute;
    top: 10px;
    right: 10px;
    background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
    color: white;
    font-size: 0.6875rem;
    /* 11px */
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 15px;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(211, 47, 47, 0.5);
    z-index: 10;
    letter-spacing: 0.5px;
}

.lich-day.today:hover,
.lich-day-item.today:hover {
    animation: none;
    border: none !important;
    box-shadow: 0 0 0 5px rgba(211, 47, 47, 0.35), 0 10px 28px rgba(211, 47, 47, 0.4) !important;
}

@keyframes todayPulse {

    0%,
    100% {
        box-shadow: 0 0 0 4px rgba(211, 47, 47, 0.25), 0 6px 22px rgba(211, 47, 47, 0.3);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(211, 47, 47, 0.12), 0 8px 26px rgba(211, 47, 47, 0.4);
    }
}

/* Today style cho mobile */
@media (max-width: 768px) {

    .lich-day.today::before,
    .lich-day-item.today::before {
        font-size: 0.5625rem;
        /* 9px */
        padding: 2px 8px;
        top: 8px;
        right: 8px;
    }

    .lich-day.today,
    .lich-day-item.today {
        border: none !important;
    }
}

/* Phân biệt ngày dương và ngày âm - CSS trong day-header */
/* Note: Tất cả day-solar và day-lunar đều nằm trong day-header, nên chỉ cần rule cụ thể .day-header .day-solar và .day-header .day-lunar */

.lich-day .day-level {
    font-weight: 700;
    font-size: 0.625rem;
    /* 10px */
    display: block;
    line-height: 1.2;
    margin: 3px 0;
    padding: 2px 4px;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
    color: inherit !important;
}

.lich-day .day-info {
    margin-top: 4px;
    padding-top: 3px;
    border-top: none;
    font-size: 0.5625rem;
    /* 9px */
    line-height: 1.3;
}

.lich-day .day-info-item {
    display: block;
    margin: 2px 0;
    padding: 2px 4px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 3px;
    font-size: 0.5625rem;
    /* 9px */
    line-height: 1.3;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    color: inherit !important;
    font-weight: 500;
}

.lich-day .day-info-item.hoang-dao {
    background: rgba(81, 207, 102, 0.5);
    color: #0b3b1f !important;
    font-weight: 700;
}

.lich-day .day-info-item.hac-dao {
    background: rgba(255, 107, 107, 0.4);
    color: #5f0f0f !important;
    font-weight: 700;
}

.lich-day .day-info-item.day-score {
    background: rgba(255, 193, 7, 0.5);
    color: #856404 !important;
    font-weight: 700;
}

.lich-day .day-info-item.day-good-hours {
    background: rgba(81, 207, 102, 0.4);
    color: #0b3b1f !important;
    font-weight: 600;
}

.lich-day .day-info-item.day-bad-star {
    background: rgba(255, 107, 107, 0.4);
    color: #5f0f0f !important;
    font-weight: 600;
}

.lich-day .day-info-item.day-solar-term {
    background: rgba(74, 171, 247, 0.4);
    color: #0b2f52 !important;
    font-weight: 600;
}

.lich-day.rat-tot-dai-loi,
.lich-day.dai-loi,
.lich-day.dai-loi-rat-tot,
.lich-day.rat-tot {
    background: #51cf66 !important;
    color: #0b3b1f;
}

/* Rất Tốt xanh đậm */
.lich-day.tuong-doi-tot-tieu-cat,
.lich-day.tot {
    background: #74c69d !important;
    color: #0f3d2c;
}

/* Tiểu Cát xanh lục */
.lich-day.tren-trung-binh-binh-hoa,
.lich-day.tren-trung-binh {
    background: #4dabf7 !important;
    color: #0b2f52;
}

/* Bình Hòa xanh lam */
.lich-day.trung-binh-binh-thuong,
.lich-day.trung-binh {
    background: #ffd43b !important;
    color: #7f4f00;
}

/* Bình Thường vàng đậm */
.lich-day.duoi-trung-binh-tieu-hung,
.lich-day.duoi-trung-binh {
    background: #ffb74d !important;
    color: #7c2d00;
}

/* Tiểu Hung cam */
.lich-day.tuong-doi-xau-hung,
.lich-day.xau {
    background: #ff8fa3 !important;
    color: #7d1220;
}

/* Hung hồng đậm */
.lich-day.cuc-xau-dai-ky,
.lich-day.rat-xau {
    background: #ff6b6b !important;
    color: #5f0f0f;
}

/* Đại Kỵ đỏ đậm */

/* Các nhãn cũ/legacy để không bị thiếu màu */
.lich-day.rat-tot {
    background: #c6f6d5 !important;
    color: #22543d;
}

.lich-day.tot {
    background: #d4edda !important;
    color: #2f855a;
}

.lich-day.trung-binh {
    background: #fff3cd !important;
    color: #8b6f00;
}

.lich-day.tren-trung-binh {
    background: #e6fffa !important;
    color: #285e61;
}

.lich-day.duoi-trung-binh {
    background: #ffe6e6 !important;
    color: #a94442;
}

.lich-day.xau {
    background: #f8d7da !important;
    color: #8a1c1c;
}

.lich-day.rat-xau {
    background: #f5c6cb !important;
    color: #721c24;
}

/* Fallback */
.lich-day.fallback,
.lich-day.unknown {
    background: #f1f1f1 !important;
    color: #333 !important;
}

.lich-day.fallback strong,
.lich-day.fallback small,
.lich-day.fallback .day-level,
.lich-day.fallback .day-info-item,
.lich-day.unknown strong,
.lich-day.unknown small,
.lich-day.unknown .day-level,
.lich-day.unknown .day-info-item {
    color: #333 !important;
}

/* Calendar Legend - Tối ưu gọn hơn */
.calendar-legend {
    background: #FAF6F0;
    padding: 16px 18px;
    border-radius: 12px;
    margin: 15px 0;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    box-sizing: border-box;
}

.calendar-legend h4 {
    font-size: 0.875rem;
    /* 14px */
    font-weight: 700;
    color: #1a1a1a;
    margin: 0 0 10px 0;
    text-align: center;
}

.legend-items {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin-bottom: 10px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.75rem;
    /* 12px */
}

.legend-color {
    width: 20px;
    height: 20px;
    border-radius: 5px;
    border: none;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
    flex-shrink: 0;
}

.legend-color.rat-tot {
    background: #51cf66;
}

.legend-color.tuong-doi-tot {
    background: #74c69d;
}

.legend-color.tren-trung-binh {
    background: #4dabf7;
}

.legend-color.trung-binh {
    background: #ffd43b;
}

.legend-color.duoi-trung-binh {
    background: #ffb74d;
}

.legend-color.tuong-doi-xau {
    background: #ff8fa3;
}

.legend-color.cuc-xau {
    background: #ff6b6b;
}

.legend-text {
    color: #495057;
    font-weight: 500;
}

.legend-note {
    font-size: 0.6875rem;
    /* 11px */
    color: #475569;
    text-align: center;
    margin: 10px 0 0 0;
    padding: 10px 14px;
    background: #FFFFFF;
    border-radius: 8px;
    border-top: none;
    line-height: 1.5;
}

.legend-note strong {
    color: #d32f2f;
}

/* Phân tích ngày sinh */
.lich-day.birth-xung {
    border: none !important;
    box-shadow: 0 0 0 2px rgba(255, 107, 107, 0.5), 0 6px 22px rgba(15, 23, 42, 0.045) !important;
}

.lich-day.birth-good {
    border: none !important;
    box-shadow: 0 0 0 2px rgba(81, 207, 102, 0.5), 0 6px 22px rgba(15, 23, 42, 0.045) !important;
}

/* GOOD MARK - Xanh lá */
.birth-good-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #51cf66, #37b24d);
    border-radius: 25px;
    box-shadow:
        0 6px 20px rgba(81, 207, 102, 0.4),
        0 0 0 3px rgba(81, 207, 102, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-green 2s ease-in-out infinite;
}

.birth-good-mark::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: rgba(255, 255, 255, 0.3);
    transform: skewX(-20deg);
    animation: slide 3s infinite;
}

.birth-good-mark:hover {
    background: linear-gradient(135deg, #40c057, #2f9e44);
    box-shadow:
        0 8px 30px rgba(81, 207, 102, 0.6),
        0 0 0 5px rgba(81, 207, 102, 0.3);
    transform: scale(1.05);
}

/* WARNING - Đỏ */
.birth-warning {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    /* 13px */
    color: #fff !important;
    font-weight: 900;
    padding: 8px 18px;
    background: linear-gradient(135deg, #ff6b6b, #fa5252);
    border-radius: 25px;
    box-shadow:
        0 6px 20px rgba(255, 107, 107, 0.4),
        0 0 0 3px rgba(255, 107, 107, 0.2);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    vertical-align: middle;
    line-height: 1;
    position: relative;
    overflow: hidden;
    animation: glow-pulse-red 2s ease-in-out infinite;
}

.birth-warning::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 50%;
    height: 100%;
    background: rgba(255, 255, 255, 0.3);
    transform: skewX(-20deg);
    animation: slide 3s infinite;
}

.birth-warning:hover {
    background: linear-gradient(135deg, #fa5252, #f03e3e);
    box-shadow:
        0 8px 30px rgba(255, 107, 107, 0.6),
        0 0 0 5px rgba(255, 107, 107, 0.3);
    transform: scale(1.05);
}

/* KEYFRAMES - Dùng chung cho cả 2 */
@keyframes slide {
    0% {
        left: -100%;
    }

    50%,
    100% {
        left: 150%;
    }
}

@keyframes glow-pulse-green {

    0%,
    100% {
        box-shadow:
            0 6px 20px rgba(81, 207, 102, 0.4),
            0 0 0 3px rgba(81, 207, 102, 0.2);
    }

    50% {
        box-shadow:
            0 6px 25px rgba(81, 207, 102, 0.6),
            0 0 0 4px rgba(81, 207, 102, 0.4);
    }
}

@keyframes glow-pulse-red {

    0%,
    100% {
        box-shadow:
            0 6px 20px rgba(255, 107, 107, 0.4),
            0 0 0 3px rgba(255, 107, 107, 0.2);
    }

    50% {
        box-shadow:
            0 6px 25px rgba(255, 107, 107, 0.6),
            0 0 0 4px rgba(255, 107, 107, 0.4);
    }
}

/* Modal chi tiết */
.lich-modal .modal-content,
#lich-modal .modal-content {
    max-height: 80vh;
    overflow: auto;
}

.lich-detail-wrap {
    font-size: 0.9375rem;
    /* 15px */
    line-height: 1.5;
    color: #222;
}

.lich-detail-wrap .ld-header h3 {
    margin-top: 0;
    margin-bottom: 8px;
}

.lich-detail-wrap .ld-quote {
    font-style: italic;
    color: #555;
    margin-bottom: 12px;
}

.lich-detail-wrap .ld-meta p {
    margin: 3px 0;
}

.lich-detail-wrap .ld-block {
    margin-top: 16px;
    padding: 12px;
    background: #f7f7f7;
    border-radius: 6px;
}

.lich-detail-wrap .ld-block h4 {
    margin: 0 0 6px 0;
    font-size: 1rem;
    /* 16px */
}

.lich-detail-wrap .ld-section {
    margin-top: 16px;
    padding: 12px;
    background: #f9f9f9;
    border-radius: 6px;
}

.lich-detail-wrap .ld-section h4 {
    margin: 0 0 8px 0;
    font-size: 1rem;
    /* 16px */
}

.lich-detail-wrap .ld-summary {
    border: none;
    background: #ECFDF5;
    border-radius: 10px;
}

/* Summary box (dạng thẻ tóm tắt) */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background: white;
    margin: 15% auto;
    padding: 20px;
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
}

.close {
    color: #aaa;
    float: right;
    font-size: 1.75rem;
    /* 28px */
    font-weight: bold;
    cursor: pointer;
}

.lich-form,
.lich-convert,
.lich-60year,
.lich-huong {
    display: none;
}

/* ============================================
   STYLES MỚI CHO LỊCH TỐI ƯU BÁN MÂM CÚNG
   ============================================ */

/* TẦNG 1: KẾT LUẬN */
.lich-day .day-header {
    padding-bottom: 5px;
    flex-shrink: 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    min-height: 40px;
}

.lich-day .day-header .day-solar {
    display: block;
    margin: 0;
    flex-shrink: 0;
    font-size: 1.625rem;
    /* 26px */
    font-weight: 700;
    color: #1a1a1a;
    line-height: 1.2;
}

.lich-day .day-header .day-lunar {
    font-size: 0.8125rem;
    /* 13px */
    font-weight: 600;
    color: #7a1f1f;
    background: #FEF3C7;
    border: none;
    border-radius: 999px;
    padding: 3px 10px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, .6);
}



.lich-day .day-header .day-lunar::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, transparent 100%);
    border-radius: 4px;
    pointer-events: none;
}

.lich-day .day-conclusion {
    text-align: left;
    background: #FFFFFF;
    border-radius: 8px;
    border: none;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.04);
    padding: 6px;
}

.conclusion-main.good {
    background: #ECFDF5;
    color: #1b5e20;
    border: none;
    border-radius: 6px;
}

.conclusion-main.bad {
    background: #fdecea;
    color: #8e0000;
    border: none;
    border-radius: 6px;
}


.lich-day .conclusion-icon {
    font-size: 1.125rem;
    /* 18px */
    font-weight: 900;
    line-height: 1;
}

/* Gộp chung conclusion-icon và conclusion-text cho good/bad */
.lich-day .conclusion-main.good .conclusion-icon,
.lich-day .conclusion-main.good .conclusion-text {
    color: #2e7d32;
}

.lich-day .conclusion-main.bad .conclusion-icon,
.lich-day .conclusion-main.bad .conclusion-text {
    color: #c62828;
}

.lich-day .conclusion-text {
    flex: 1;
    font-size: 0.8125rem;
    /* 13px */
    font-weight: 700;
}

/* Gộp chung conclusion-time và conclusion-level vì có cùng style */
.lich-day .conclusion-time,
.lich-day .conclusion-level {
    font-size: 0.6875rem;
    /* 11px */
    color: #495057;
    font-weight: 600;
    margin: 0;
    padding: 5px;
    min-height: 20px;
    line-height: 1.4;
    display: flex;
    align-items: center;
}

/* TẦNG 2: GỢI Ý MÂM CÚNG */
.day-mam-suggestions {
    background: #FAF6F0;
    border: none;
    border-radius: 8px;
    padding: 6px;
}

.mam-title {
    font-size: 0.75rem;
    /* 12px */
    font-weight: 700;
    color: #8b1a1a;
}


.lich-day .mam-list {
    list-style: none;
    padding: 0;
    margin: 3px 0 4px 0;
    overflow: visible;
}

.lich-day .mam-list li {
    text-align: left;
    font-size: 0.625rem;
    /* 10px */
    color: #495057;
    margin: 2px 0;
    padding: 1px 0 1px 10px;
    line-height: 1.4;
    position: relative;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.lich-day .mam-list li:before {
    content: '•';
    position: absolute;
    left: 0;
    color: #1e293b;
    font-weight: 700;
    font-size: 0.625rem;
    /* 10px */
    bottom: 1px;
}

/* Highlight mâm cúng ưu tiên (phù hợp với type được chọn) */
.lich-day .mam-list li.mam-priority {
    background: #ff6b00;
    border-radius: 3px;
    font-size: 0.5625rem;
    /* 9px */
    margin: 2px 0;
    padding: 1px 0 1px 10px;
    line-height: 1.4;
    position: relative;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.lich-day .mam-list li.mam-priority:before {
    color: #ff6b00;
    font-weight: 900;
    font-size: 0.625rem;
    /* 10px */
}

/* Highlight mâm cúng đặc biệt (ngày lễ) */
.lich-day .mam-list li.mam-special {
    font-weight: 900;
    color: #d32f2f;
    background: rgb(92 210 112);
    border-radius: 3px;
    font-size: 0.625rem;
    /* 10px */
    margin: 2px 0;
    padding: 1px 0 1px 10px;
    line-height: 1.4;
    position: relative;
    word-wrap: break-word;
    overflow-wrap: break-word;
    white-space: normal;
}

.lich-day .mam-list li.mam-special::after {
    content: '';
}

.lich-day .btn-mam-cung {
    display: inline-block;
    width: 22px;
    height: 22px;
    padding: 0;
    background: rgba(0, 0, 0, 0.05);
    color: #1a1a1a;
    text-align: center;
    text-decoration: none;
    font-size: 0.875rem;
    /* 14px */
    font-weight: 700;
    line-height: 22px;
    border-radius: 50%;
    margin-top: 4px;
    transition: all 0.3s ease;
    border: none;
    flex-shrink: 0;
}

.lich-day .btn-mam-cung:hover {
    background: rgba(0, 0, 0, 0.1);
    border: none;
    transform: translateX(2px);
    color: #1a1a1a;
    text-decoration: none;
}

/* TẦNG 3: CHI TIẾT (THU GỌN) */
.lich-day .day-details-toggle {
    margin-top: auto;
    border-top: none;
    padding-top: 4px;
    flex-shrink: 0;
}

.lich-day .toggle-details {
    width: 100%;
    padding: 4px 6px;
    background: rgba(0, 0, 0, 0.05);
    border: none;
    border-radius: 4px;
    font-size: 0.6875rem;
    /* 11px */
    font-weight: 600;
    color: #495057;
    cursor: pointer;
    transition: all 0.2s ease;
    min-height: 22px;
    line-height: 1.3;
}

.lich-day .toggle-details:hover {
    background: rgba(0, 0, 0, 0.1);
    border: none;
}

.lich-day .day-details-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    margin-top: 6px;
    padding: 0 4px;
}

.lich-day .day-details-toggle.expanded .day-details-content {
    max-height: 500px;
    padding: 6px 4px;
}

.lich-day .detail-item {
    font-size: 0.6875rem;
    /* 11px */
    margin: 4px 0;
    padding: 3px 6px;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 3px;
    line-height: 1.4;
}

.lich-day .detail-item strong {
    color: #495057;
    margin-right: 4px;
    font-size: 0.6875rem;
    /* 11px */
}

/* Thông tin tuổi đang lọc */
.birth-info-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.birth-info-header h3 {
    margin: 0 0 15px 0;
    font-size: 1.375rem;
    /* 22px */
    font-weight: 700;
}

.birth-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 15px;
}

.birth-info-description {
    background: rgba(255, 255, 255, 0.15);
    padding: 15px;
    border-radius: 8px;
    font-size: 0.875rem;
    /* 14px */
    line-height: 1.6;
}

/* Responsive cho mobile */
@media (max-width: 768px) {
    .birth-info-header {
        padding: 15px;
        margin-bottom: 15px;
    }

    .birth-info-header h3 {
        font-size: 1.125rem;
        /* 18px */
        margin-bottom: 12px;
    }

    .birth-info-grid {
        grid-template-columns: 1fr;
        gap: 10px;
        margin-bottom: 12px;
    }

    .birth-info-description {
        padding: 12px;
        font-size: 0.8125rem;
        /* 13px */
    }

    .lich-day {
        height: 200px !important;
        min-height: 200px !important;
        max-height: 200px !important;
        padding: 8px 4px;
    }

    .lich-day .day-header {
        min-height: 36px;
        gap: 3px;
        padding-bottom: 4px;
    }

    .lich-day .day-header .day-solar {
        font-size: 1.5rem;
        /* 24px */
    }

    .lich-day .day-header .day-lunar {
        font-size: 0.6875rem;
        /* 11px */
        padding: 2px 6px;
        max-width: 95%;
        letter-spacing: 0.3px;
    }

    .lich-day .day-conclusion {
        min-height: 65px;
        padding: 7px 5px;
        gap: 5px;

    }

    .lich-day .conclusion-main {
        font-size: 0.75rem;
        /* 12px */
        min-height: 24px;
        padding: 5px 6px;
        line-height: 1.3;
    }

    .lich-day .conclusion-icon {
        font-size: 1rem;
        /* 16px */
    }

    .lich-day .conclusion-time,
    .lich-day .conclusion-level {
        font-size: 0.625rem;
        /* 10px */
        min-height: 18px;
        padding: 4px 6px;
        line-height: 1.3;
    }

    .lich-day .btn-mam-cung {
        font-size: 0.75rem;
        /* 12px */
        padding: 0;
        width: 24px;
        height: 24px;
        line-height: 24px;
        margin-top: 2px;
        min-width: 24px;
        flex-shrink: 0;
    }

    .lich-day .mam-list li {
        font-size: 0.594rem;
        /* 9.5px */
        line-height: 1.3;
    }

    .mam-title {
        font-size: 0.6875rem;
        /* 11px */
    }
}

/* Responsive cho màn hình rất nhỏ (điện thoại nhỏ) */
@media (max-width: 480px) {
    .lich-day .btn-mam-cung {
        font-size: 0.6875rem;
        /* 11px */
        width: 22px;
        height: 22px;
        line-height: 22px;
        margin-top: 2px;
    }
}

/* Responsive cho màn hình tablet */
@media (min-width: 769px) and (max-width: 1024px) {
    .lich-day .btn-mam-cung {
        font-size: 0.8125rem;
        /* 13px */
        width: 24px;
        height: 24px;
        line-height: 24px;
    }
}

/* Loading indicator */
.lich-loading {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    min-height: 300px;
    text-align: center;
    visibility: visible !important;
    opacity: 1 !important;
    z-index: 999;
    position: relative;
    background: #fffdfb;
    width: 100%;
    box-sizing: border-box;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: none;
    background: conic-gradient(from 0deg, transparent 0%, #d32f2f 100%);
    -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0);
    mask: radial-gradient(farthest-side, transparent calc(100% - 4px), #000 0);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

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

    100% {
        transform: rotate(360deg);
    }
}

.loading-text {
    font-size: 1rem;
    /* 16px */
    color: #666;
    font-weight: 500;
    margin-top: 10px;
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
}

@media (max-width: 768px) {
    .lich-loading {
        padding: 40px 15px;
        min-height: 200px;
        display: flex !important;
        visibility: visible !important;
        opacity: 1 !important;
        z-index: 999;
    }

    .loading-spinner {
        width: 40px;
        height: 40px;
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .loading-text {
        font-size: 0.875rem;
        /* 14px */
        display: block !important;
        visibility: visible !important;
        opacity: 1 !important;
    }
}

/* Toggle button cho footer */
.footer-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 20px;
    margin: 15px 0;
    background: linear-gradient(135deg, #d32f2f 0%, #b71c1c 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.875rem;
    /* 14px */
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(211, 47, 47, 0.3);
}

.footer-toggle-btn:hover {
    background: linear-gradient(135deg, #b71c1c 0%, #8b0000 100%);
    box-shadow: 0 4px 12px rgba(211, 47, 47, 0.4);
    transform: translateY(-2px);
}

.footer-toggle-btn .toggle-icon {
    transition: transform 0.3s ease;
    font-size: 0.75rem;
    /* 12px */
}

.footer-toggle-btn.expanded .toggle-icon {
    transform: rotate(180deg);
}

/* Collapsible footer content */
.footer-collapsible {
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.5s ease, opacity 0.3s ease, padding 0.3s ease;
}

.footer-collapsible.expanded {
    max-height: 5000px;
    /* High enough to show all content */
    opacity: 1;
    padding-top: 15px;
    padding-bottom: 25px;
}

.lich-article-footer {
    margin-top: 40px;
    padding-top: 20px;
    border: none;
}

/* TỐI ƯU CHI TIẾT CHO MOBILE */
@media (max-width: 768px) {
    .modal-content {
        width: 95% !important;
        margin: 10% auto !important;
        padding: 15px !important;
    }

    .advice-section {
        padding: 10px !important;
        font-size: 0.781rem !important;
        /* 12.5px */
    }

    .mam-tag-small {
        padding: 2px 8px !important;
        font-size: 0.656rem !important;
        /* 10.5px */
    }

    .day-title {
        font-size: 0.9375rem !important;
        /* 15px */
        margin-bottom: 8px !important;
    }

    .basic-info {
        font-size: 0.8125rem !important;
        /* 13px */
    }

    .detail-link {
        font-size: 0.6875rem !important;
        /* 11px */
    }
}

/* ===== BREADCRUMBS (Synchronized with Theme) ===== */
.post-breadcrumbs {
    margin: 0 auto 2rem;
    padding: 0.75rem 1.25rem;
    background: #FAF6F0;
    backdrop-filter: blur(8px);
    border-radius: 12px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    width: 100%;
    max-width: 1200px;
    box-sizing: border-box;
}

.post-breadcrumbs ol {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
}

.post-breadcrumbs li {
    display: flex;
    align-items: center;
    color: #64748b;
}

.post-breadcrumbs li a {
    color: #475569;
    text-decoration: none;
    transition: color 0.2s ease;
}

.post-breadcrumbs li a:hover {
    color: #ff6d38;
}

.post-breadcrumbs li:not(:last-child)::after {
    content: '/';
    margin-left: 0.5rem;
    color: #cbd5e1;
    font-weight: 300;
}

.post-breadcrumbs li:last-child {
    color: #ff6d38;
    font-weight: 600;
}

/* ===== FLOATING ACTION UI (Moved from detail-template.php) ===== */
.floating-bubbles {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 20px;
    padding: 12px 20px;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border: none;
    box-shadow: 0 -4px 22px rgba(15, 23, 42, 0.06);
    z-index: 9999;
}

.floating-bubble {
    color: white;
    position: relative;
    flex: 1;
    max-width: 300px;
    min-width: 140px;
    height: 56px;
    padding: 0 20px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    text-decoration: none;
    box-sizing: border-box;
}

.floating-bubble.bubble-home {
    background: linear-gradient(135deg, #4DABF7 0%, #1971C2 100%);
    box-shadow: 0 2px 10px rgba(25, 113, 194, 0.3);
}

.floating-bubble.bubble-home:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(25, 113, 194, 0.4);
}

.floating-bubble.bubble-calendar {
    background: linear-gradient(135deg, #FF6B6B 0%, #C92A2A 100%);
    box-shadow: 0 2px 10px rgba(201, 42, 42, 0.3);
}

.floating-bubble.bubble-calendar:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(201, 42, 42, 0.4);
}

.floating-bubble:active {
    transform: translateY(0);
}

.bubble-icon {
    font-size: 1.5rem;
    /* 24px */
    line-height: 1;
    flex-shrink: 0;
}

.bubble-text {
    color: white;
    font-size: 0.9375rem;
    /* 15px */
    font-weight: 600;
    white-space: nowrap;
}

@media (max-width: 768px) {
    .floating-bubbles {
        padding: 10px 12px;
        gap: 10px;
    }

    .floating-bubble {
        min-width: 0;
        max-width: none;
        height: 50px;
        padding: 0 12px;
    }

    .bubble-icon {
        font-size: 1.25rem;
        /* 20px */
    }

    .bubble-text {
        font-size: 0.8125rem;
        /* 13px */
    }
}

@media (max-width: 480px) {
    .floating-bubbles {
        padding: 8px 8px;
        gap: 8px;
    }

    .floating-bubble {
        height: 48px;
        padding: 0 10px;
        gap: 6px;
    }

    .bubble-icon {
        font-size: 1.125rem;
        /* 18px */
    }

    .bubble-text {
        font-size: 0.6875rem;
        /* 11px */
    }
}

@media (max-width: 360px) {
    .floating-bubbles {
        padding: 8px 6px;
        gap: 6px;
    }

    .floating-bubble {
        padding: 0 8px;
        gap: 4px;
    }

    .bubble-icon {
        font-size: 1rem;
        /* 16px */
    }

    .bubble-text {
        font-size: 0.625rem;
        /* 10px */
    }
}

/* =========================================
   DATE CONVERTER STYLES
   ========================================= */
.lich-converter-wrapper {
    margin-bottom: 20px;
    background: #FFFFFF;
    padding: 20px;
    border-radius: 12px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    color: #333;
}

.converter-controls .converter-inputs {
    display: flex;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.lich-converter-wrapper select,
.lich-converter-wrapper input {
    height: 42px;
    border-radius: 10px;
    padding: 0 12px;
    font-size: 0.9rem;
    font-weight: 600;
    background: #FAF6F0;
    border: 1px solid rgba(153, 27, 27, 0.14);
    color: #1e293b;
    box-sizing: border-box;
}

.converter-inputs #conv-type {
    font-weight: 600;
    min-width: 140px;
}

.converter-inputs .date-group {
    display: flex;
    gap: 5px;
    align-items: center;
}

.converter-inputs #btn-convert {
    height: 42px;
    padding: 0 16px;
    white-space: nowrap;
    background: linear-gradient(135deg, #b91c1c 0%, #991b1b 100%);
    color: #fff;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
    box-sizing: border-box;
}

.converter-inputs #btn-convert:hover {
    background: linear-gradient(135deg, #991b1b 0%, #7f1d1d 100%);
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .converter-controls .converter-inputs {
        flex-wrap: wrap;
    }

    .converter-inputs #conv-type {
        width: 100%;
    }

    .converter-inputs .date-group {
        width: 100%;
        justify-content: space-between;
    }

    .converter-inputs .date-group select,
    .converter-inputs .date-group input {
        flex: 1;
    }

    .converter-inputs #btn-convert {
        width: 100%;
        margin-top: 5px;
    }
}

/* =========================================
   BIRTH INFO STYLES
   ========================================= */
.birth-info-header {
    background: #FAF6F0;
    padding: 15px;
    border-radius: 12px;
    border: none;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    color: #333;
    margin-bottom: 15px;
}

.birth-info-header h3 {
    margin-top: 0;
    font-size: 16px;
    color: #333;
    border: none;
    padding-bottom: 8px;
    margin-bottom: 10px;
    font-weight: 700;
}

.birth-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    font-size: 14px;
    color: #333;
}

.birth-info-grid div strong {
    color: #000;
    font-weight: 600;
}

.birth-info-description {
    margin-top: 10px;
    font-style: italic;
    color: #555;
    font-size: 14px;
    line-height: 1.5;
    border: none;
    background: #FFFFFF;
    border-radius: 8px;
    padding: 10px 12px;
}

.birth-info-description strong {
    color: #333;
}

/* Mobile responsive for birth info */
@media (max-width: 600px) {
    .birth-info-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== FILTER SUITABILITY STYLES ===== */
/* Ngày không phù hợp với mục đích lọc - làm mờ đi */
.lich-day-row.not-suitable {
    /* opacity: 0.4; -- Removed as requested */
    /* filter: grayscale(100%); -- Removed as requested */
    background: #fff;
    /* Reset to white or default */
    transition: all 0.3s ease;
}

.lich-day-row.not-suitable:hover {
    /* opacity: 0.8; -- Removed */
    /* filter: grayscale(20%); -- Removed */
    background: #f9f9f9;
    /* Slight hover effect only */
}

/* Style cho ngày phù hợp với mục đích đang lọc */
.lich-day-row.is-suitable td {
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
    background: #ECFDF5 !important;
    border: none;
}

.lich-day-row.is-suitable td:first-child {
    border: none;
}

/* Badge phù hợp/không phù hợp (được thêm bởi JS vào .day-title) */
.suitability-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.6875rem;
    padding: 3px 10px;
    border-radius: 12px;
    font-weight: 700;
    margin-left: 8px;
    vertical-align: middle;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.06);
    border: none;
}

.suitability-badge.suitable {
    background: #ECFDF5;
    color: #065f46;
    border: none;
}

.suitability-badge.not-suitable-badge {
    background: #F7F4EF;
    color: #757575;
    border: none;
}

/* Mobile responsive for suitability badges */
@media (max-width: 768px) {
    .suitability-badge {
        font-size: 0.5625rem;
        padding: 2px 6px;
        margin-left: 5px;
    }

    .lich-day-row.is-suitable td {
        box-shadow: 0 4px 14px rgba(15, 23, 42, 0.045);
    }
}

/* =====================================================================
   THANH ĐIỀU HƯỚNG TIỆN ÍCH MỞ RỘNG (LINK PHỤ — ĐỒNG BỘ GIAO DIỆN)
   ===================================================================== */
.ltp-subnav-box {
    background: #FFFFFF;
    border: none;
    border-radius: 14px;
    padding: 16px 18px;
    margin: 16px 0;
    text-align: left;
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.ltp-subnav-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border: none;
}

.ltp-subnav-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.92rem;
    font-weight: 700;
    color: #7f1d1d;
    line-height: 1.4;
}

.ltp-subnav-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #b91c1c;
    display: inline-block;
    flex-shrink: 0;
}

.ltp-subnav-badge {
    font-size: 0.74rem;
    background: #FEF3C7;
    color: #991b1b;
    border: none;
    padding: 3px 10px;
    border-radius: 999px;
    font-weight: 600;
    white-space: nowrap;
}

.ltp-subnav-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.ltp-subnav-item {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 4px;
    padding: 10px 13px;
    background: #FAF6F0;
    border: none;
    border-radius: 10px;
    text-decoration: none !important;
    transition: all 0.18s ease;
    text-align: left;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.03);
}

.ltp-subnav-item:hover {
    background: #FEF3C7;
    border: none;
    transform: translateY(-1px);
    box-shadow: 0 6px 22px rgba(15, 23, 42, 0.045);
}

.ltp-subnav-item.ltp-subnav-item-highlight {
    background: #FEF3C7;
    border: none;
}

.ltp-subnav-item-top {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
}

.ltp-subnav-icon-wrap {
    width: 22px;
    height: 22px;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    border: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.ltp-subnav-icon-wrap img {
    width: 22px;
    height: 22px;
    object-fit: contain;
    display: block;
}

.ltp-subnav-name {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.3;
    flex: 1;
}

.ltp-subnav-item:hover .ltp-subnav-name {
    color: #991b1b;
}

.ltp-subnav-arrow {
    font-size: 0.82rem;
    color: #b91c1c;
    font-weight: 700;
    opacity: 0.75;
    transition: transform 0.18s ease;
    flex-shrink: 0;
}

.ltp-subnav-item:hover .ltp-subnav-arrow {
    transform: translateX(2px);
    opacity: 1;
}

.ltp-subnav-desc {
    font-size: 0.74rem;
    color: #64748b;
    font-weight: 400;
    line-height: 1.35;
}

@media (max-width: 992px) {
    .ltp-subnav-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .ltp-subnav-grid {
        grid-template-columns: 1fr;
    }
    .ltp-subnav-box {
        padding: 12px 14px;
    }
}

/* =====================================================================
   ĐỒNG BỘ CĂN LỀ KHUNG 100%, ZERO OVERFLOW & BORDER-RADIUS HÀI HÒA
   ===================================================================== */
.lich-thien-phuc-container {
    overflow-x: clip !important;
    max-width: 1200px;
    width: 100%;
    box-sizing: border-box;
}

.lich-thien-phuc-container > .lich-seo-section,
.lich-thien-phuc-container > .lich-article-footer,
.lich-thien-phuc-container > .tp-hoi-ai,
.lich-thien-phuc-container > #hoi-ai,
.lich-thien-phuc-container .tp-hoi-ai {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    box-sizing: border-box !important;
}

.lich-thien-phuc-container > .tp-hoi-ai,
.lich-thien-phuc-container > #hoi-ai {
    margin-top: 28px !important;
    margin-bottom: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
}

.lich-thien-phuc-container .tp-hoi-ai__card {
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 14px !important;
    box-sizing: border-box !important;
}

.lich-thien-phuc-container details {
    border-radius: 14px !important;
    overflow: hidden !important;
    box-sizing: border-box !important;
}

.lich-thien-phuc-container details > summary {
    border-radius: 0 !important;
    box-sizing: border-box !important;
}

