/* Hero */
.cf-hero {
    background: linear-gradient(135deg, #1a1a2e 0%, #2d2d4e 100%);
    padding: 40px 0 36px;
    margin-bottom: 0;
}

.cf-hero-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.cf-hero-text {
    flex: 1;
    min-width: 260px;
}

.cf-hero-title {
    font-size: 26px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 10px;
    line-height: 1.25;
}

.cf-hero-sub {
    font-size: 14px;
    color: rgba(255, 255, 255, .65);
    margin: 0;
    line-height: 1.6;
    max-width: 520px;
}

.cf-hero-stats {
    display: flex;
    align-items: center;
    gap: 24px;
    background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .12);
    border-radius: 12px;
    padding: 16px 24px;
    flex-shrink: 0;
}

.cf-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.cf-stat-num {
    font-size: 22px;
    font-weight: 700;
    color: #F4622A;
    line-height: 1;
}

.cf-stat-lbl {
    font-size: 11px;
    color: rgba(255, 255, 255, .5);
    white-space: nowrap;
    letter-spacing: .03em;
}

.cf-stat-sep {
    width: 1px;
    height: 36px;
    background: rgba(255, 255, 255, .15);
}

@media (max-width: 768px) {
    .cf-hero-stats {
        width: 100%;
        justify-content: space-around;
        padding: 14px 16px;
    }

    .cf-hero-title {
        font-size: 20px;
    }
}

/* ===== Course Table Wrap ===== */
.cft-wrap {
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #ebebeb;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}

/* Top bar */
.cft-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-bottom: 1px solid #f0f0f0;
    gap: 12px;
    flex-wrap: wrap;
    background: #fafafa;
}

.cft-topbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.cft-count {
    font-size: 13px;
    color: #888;
}

.cft-count strong {
    color: #333;
    font-weight: 600;
}

.cft-filter-tags {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}

.cft-filter-tag {
    background: #fff0eb;
    color: #c04010;
    font-size: 11px;
    font-weight: 600;
    padding: 2px 9px;
    border-radius: 20px;
    border: 1px solid #ffd0be;
}

.cft-cal-links {
    display: flex;
    gap: 8px;
}

.cft-cal-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    font-weight: 500;
    color: #666;
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 5px 12px;
    text-decoration: none;
    transition: all .15s;
}

.cft-cal-btn:hover {
    background: #F4622A;
    color: #fff;
    border-color: #F4622A;
}

/* Column headers */
.cft-col-header {
    display: grid;
    grid-template-columns: 2.2fr 1.4fr 1.2fr 0.9fr;
    padding: 10px 24px;
    background: #f4f4f6;
    gap: 16px;
}

.cft-col-header span {
    font-size: 10.5px;
    font-weight: 700;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.cft-fees-hdr {
    text-align: right;
}

/* Rows */
.cft-row {
    display: grid;
    grid-template-columns: 2.2fr 1.4fr 1.2fr 0.9fr;
    align-items: center;
    gap: 16px;
    padding: 18px 24px;
    transition: background .14s;
    text-decoration: none;
    color: inherit;
}

.cft-row:hover {
    background: #fff8f6;
}

.cft-divider {
    height: 1px;
    background: #f2f2f2;
    margin: 0 24px;
}

/* Course cell */
.cft-cell-course {}

.cft-course-name {
    display: block;
    font-size: 13.5px;
    font-weight: 600;
    color: #1a1a2e;
    line-height: 1.4;
    margin-bottom: 7px;
    transition: color .14s;
}

.cft-row:hover .cft-course-name {
    color: #F4622A;
}

.cft-course-meta {
    display: flex;
    align-items: center;
    gap: 5px;
    flex-wrap: wrap;
}

.cft-cat-pill {
    font-size: 10.5px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    background: #ede9fe;
    color: #5b3fd4;
}

.cft-hrdc-pill {
    font-size: 10px;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 20px;
    background: #d4edda;
    color: #155724;
    letter-spacing: .04em;
}

.cft-dur-pill {
    font-size: 10.5px;
    font-weight: 500;
    color: #888;
    display: flex;
    align-items: center;
    gap: 3px;
}

/* Date cell */
.cft-cell-date {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.cft-date-text {
    font-size: 12.5px;
    font-weight: 500;
    color: #333;
    line-height: 1.3;
}

.cft-tbc {
    font-size: 12.5px;
    color: #bbb;
    font-style: italic;
}

.cft-mode {
    display: inline-block;
    font-size: 10.5px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 20px;
    width: fit-content;
}

.cft-mode-f2f {
    background: #e3f9f0;
    color: #1a7a50;
}

.cft-mode-online {
    background: #e4f0fb;
    color: #1a5ca0;
}

.cft-mode-hybrid {
    background: #fef3e2;
    color: #b07000;
}

/* Location cell */
.cft-cell-loc {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.cft-loc-name {
    font-size: 12.5px;
    font-weight: 500;
    color: #333;
}

.cft-loc-country {
    font-size: 11px;
    color: #999;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Price cell */
.cft-cell-price {
    text-align: right;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 1px;
}

.cft-price-reg {
    font-size: 14.5px;
    font-weight: 700;
    color: #1a1a2e;
    white-space: nowrap;
}

.cft-price-early {
    font-size: 14.5px;
    font-weight: 700;
    color: #1a7a50;
    white-space: nowrap;
}

.cft-price-was {
    font-size: 11px;
    color: #d04040;
    text-decoration: line-through;
    white-space: nowrap;
}

.cft-price-label {
    font-size: 10px;
    color: #1a7a50;
    font-weight: 600;
    background: #e3f9f0;
    padding: 1px 6px;
    border-radius: 20px;
    margin-top: 2px;
}

/* Empty state */
.cft-empty {
    padding: 64px 24px;
    text-align: center;
}

.cft-empty i {
    font-size: 32px;
    color: #ddd;
    display: block;
    margin-bottom: 12px;
}

.cft-empty p {
    font-size: 14px;
    color: #aaa;
    margin-bottom: 12px;
}

.cft-reset-link {
    font-size: 13px;
    color: #F4622A;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid #F4622A;
}

/* Footer */
.cft-footer {
    padding: 16px 24px;
    border-top: 1px solid #f0f0f0;
}

/* Responsive */
@media (max-width: 768px) {

    .cft-col-header,
    .cft-row {
        grid-template-columns: 1fr 1fr;
        padding: 14px 16px;
        gap: 12px;
    }

    .cft-col-header span:nth-child(3),
    .cft-col-header span:nth-child(4) {
        display: none;
    }

    .cft-cell-loc {
        display: none;
    }

    .cft-cell-price {
        align-items: flex-end;
    }
}

/* ===== Sidebar ===== */
.cf-sidebar {
    display: flex;
    flex-direction: column;
    gap: 0;
    background: #fff;
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid #ebebeb;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .04);
}

.cf-sidebar-section {
    border-bottom: 1px solid #f0f0f0;
}

.cf-sidebar-section:last-child {
    border-bottom: none;
}

/* Search */
.cf-search-section {
    padding: 16px;
}

.cf-search-box {
    display: flex;
    align-items: center;
    background: #f7f8fa;
    border: 1.5px solid #e8e8e8;
    border-radius: 10px;
    padding: 0 4px 0 12px;
    gap: 8px;
    transition: border-color .15s;
}

.cf-search-box:focus-within {
    border-color: #F4622A;
    background: #fff;
}

.cf-search-icon {
    color: #bbb;
    font-size: 13px;
    flex-shrink: 0;
}

.cf-search-box input {
    border: none;
    background: transparent;
    flex: 1;
    font-size: 13.5px;
    color: #333;
    padding: 10px 0;
    outline: none;
}

.cf-search-box input::placeholder {
    color: #bbb;
}

.cf-search-box button {
    background: #F4622A;
    color: #fff;
    border: none;
    border-radius: 7px;
    padding: 7px 14px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
    white-space: nowrap;
}

.cf-search-box button:hover {
    background: #d94f1e;
}

/* Section headers */
.cf-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 13px 16px;
    cursor: pointer;
    user-select: none;
    transition: background .12s;
}

.cf-section-header:hover {
    background: #fafafa;
}

.cf-section-title {
    font-size: 12.5px;
    font-weight: 700;
    color: #1a1a2e;
    text-transform: uppercase;
    letter-spacing: .07em;
}

.cf-toggle-icon {
    font-size: 11px;
    color: #bbb;
    transition: transform .2s;
}

.cf-section-header.collapsed .cf-toggle-icon {
    transform: rotate(-90deg);
}

.cf-section-body {
    padding: 4px 16px 14px;
}

.cf-section-body.hidden {
    display: none;
}

/* Checkbox items */
.cf-checkbox-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 0;
    cursor: pointer;
}

.cf-checkbox-item input[type="checkbox"],
.cf-checkbox-item input[type="radio"] {
    width: 15px;
    height: 15px;
    accent-color: #F4622A;
    flex-shrink: 0;
    cursor: pointer;
}

.cf-checkbox-label {
    font-size: 13px;
    color: #444;
    display: flex;
    align-items: center;
    gap: 6px;
    flex: 1;
    line-height: 1.3;
}

.cf-count-badge {
    margin-left: auto;
    background: #f0f0f4;
    color: #888;
    font-size: 10.5px;
    font-weight: 600;
    padding: 1px 7px;
    border-radius: 20px;
}

/* HRDC badges */
.cf-hrdc-badge {
    font-size: 11.5px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 20px;
}

.cf-hrdc-badge.yes {
    background: #e4f6ee;
    color: #1a7a4a;
}

.cf-hrdc-badge.no {
    background: #fce8e8;
    color: #b03030;
}

.cf-clear-radio {
    background: none;
    border: none;
    font-size: 11.5px;
    color: #F4622A;
    cursor: pointer;
    padding: 4px 0;
    margin-top: 4px;
    text-decoration: underline;
}

/* Pill group (Duration) */
.cf-pill-group {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding-top: 2px;
}

.cf-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 5px 13px;
    border: 1.5px solid #e4e4e4;
    border-radius: 20px;
    font-size: 12.5px;
    font-weight: 500;
    color: #555;
    cursor: pointer;
    transition: all .15s;
    background: #fafafa;
}

.cf-pill input {
    display: none;
}

.cf-pill:hover {
    border-color: #F4622A;
    color: #F4622A;
    background: #fff6f3;
}

.cf-pill.active {
    border-color: #F4622A;
    background: #F4622A;
    color: #fff;
}

/* Month grid */
.cf-month-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 5px;
    padding-top: 2px;
}

.cf-month-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px 4px;
    border: 1.5px solid #e4e4e4;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 500;
    color: #555;
    cursor: pointer;
    transition: all .15s;
    background: #fafafa;
    text-align: center;
}

.cf-month-item input {
    display: none;
}

.cf-month-item:hover:not(.cf-month-dim) {
    border-color: #F4622A;
    color: #F4622A;
    background: #fff6f3;
}

.cf-month-item.active {
    border-color: #F4622A;
    background: #F4622A;
    color: #fff;
}

.cf-month-dim {
    opacity: .35;
    cursor: default;
}

/* Clear all */
.cf-sidebar-clear {
    padding: 12px 16px;
    border-top: 1px solid #f0f0f0;
}

.cf-clear-all-btn {
    width: 100%;
    background: #fff6f3;
    color: #F4622A;
    border: 1.5px solid #fcd8cb;
    border-radius: 8px;
    padding: 8px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background .15s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.cf-clear-all-btn:hover {
    background: #fce9e2;
}