/* ============================================================
   Trung tâm ĐTTX Ngắn hạn - Trường CĐ Kỹ thuật Cao Thắng
   Frontend Stylesheet
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Be+Vietnam+Pro:wght@400;500;600;700;800&display=swap');

:root {
    /* Cao Thắng brand */
    --ct-blue: #003B7B;
    --ct-blue-light: #0056b3;
    --ct-blue-dark: #002a5a;
    --ct-red: #D32F2F;
    --ct-gold: #F9A825;

    /* Neutrals */
    --ink: #17202e;
    --steel: #5c6b81;
    --paper: #FAFAF8;
    --white: #ffffff;
    --line: #e6e8ee;
    --line-strong: #d4d8e2;

    --shadow-sm: 0 1px 4px rgba(15,30,60,0.06);
    --shadow-md: 0 6px 24px rgba(15,30,60,0.10);
    --shadow-lg: 0 16px 48px rgba(15,30,60,0.16);

    --radius: 12px;
    --radius-sm: 8px;
    --container: 1200px;

    --font-main: 'Be Vietnam Pro', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    font-family: var(--font-main);
    color: var(--ink);
    background: var(--paper);
    font-size: 15px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font-family: inherit; cursor: pointer; }
ul { list-style: none; }

.container {
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 20px;
}

.eyebrow {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.4px;
    color: var(--ct-gold);
}

.section-title {
    font-size: 26px;
    font-weight: 800;
    color: var(--ct-blue);
    margin: 6px 0 4px;
}

.section-sub {
    color: var(--steel);
    font-size: 14.5px;
    margin-bottom: 24px;
}

.section {
    padding: 48px 0;
}

/* ============================================================
   Header / Navigation
   ============================================================ */
.site-header {
    background: var(--white);
    border-bottom: 1px solid var(--line);
    position: sticky;
    top: 0;
    z-index: 200;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 76px;
    gap: 24px;
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 16px;
    color: var(--ct-blue);
    flex-shrink: 0;
}

.site-logo img { height: 44px; width: auto; }

.site-logo .logo-mark {
    width: 44px;
    height: 44px;
    background: var(--ct-blue);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.site-logo .logo-mark svg { width: 26px; height: 26px; fill: var(--white); }

.site-logo .logo-text {
    line-height: 1.28;
    font-size: 14.5px;
    max-width: 190px;
    white-space: normal;
}

/* Main nav */
.main-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    justify-content: center;
}

.main-nav > li { position: relative; }

.main-nav > li > a {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 14px;
    font-weight: 600;
    font-size: 13.5px;
    color: var(--ink);
    border-radius: 8px;
    transition: all .15s;
    white-space: nowrap;
}

.main-nav > li > a:hover,
.main-nav > li.active > a { background: #eef3fb; color: var(--ct-blue); }

/* Trang chủ = icon-only, gọn gàng theo đúng yêu cầu thiết kế */
.main-nav > li > a.nav-home-icon {
    width: 38px;
    height: 38px;
    padding: 0;
    justify-content: center;
    flex-shrink: 0;
}
.nav-home-icon .home-icon { width: 18px; height: 18px; flex-shrink: 0; }
.nav-home-icon .nav-home-label { display: none; }

.main-nav > li > a .caret {
    width: 8px; height: 8px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    transform: rotate(45deg);
    margin-top: -3px;
    opacity: .6;
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    min-width: 220px;
    background: var(--white);
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--line);
    padding: 8px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-6px);
    transition: all .18s;
}

.main-nav > li:hover .nav-dropdown {
    opacity: 1; visibility: visible; transform: translateY(0);
}

.nav-dropdown a {
    display: block;
    padding: 9px 12px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
}

.nav-dropdown a:hover { background: #f1f5fb; color: var(--ct-blue); }

/* Search box */
.header-search {
    flex-shrink: 0;
}

.header-search form {
    display: flex;
    align-items: center;
    background: #f2f4f8;
    border-radius: 999px;
    padding: 4px 4px 4px 16px;
    width: 240px;
    transition: width .2s;
}

.header-search form:focus-within { width: 280px; background: #eaeef6; }

.header-search input {
    border: none; background: transparent; outline: none;
    font-family: inherit; font-size: 13.5px; flex: 1; color: var(--ink);
}

.header-search button {
    width: 34px; height: 34px; border-radius: 50%;
    background: var(--ct-blue); border: none; color: #fff;
    display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.header-search button svg { width: 16px; height: 16px; fill: #fff; }

.btn-mobile-menu {
    display: none;
    background: none; border: none; font-size: 24px; color: var(--ct-blue);
}

/* ============================================================
   Hero / Banner
   ============================================================ */
.hero-slider {
    position: relative;
    width: 100%;
    aspect-ratio: 1600 / 500;
    max-height: 460px;
    overflow: hidden;
    background: linear-gradient(120deg, var(--ct-blue) 0%, var(--ct-blue-dark) 55%, #001c3d 100%);
}

.hero-slide {
    position: absolute; inset: 0;
    opacity: 0; transition: opacity .6s ease;
}
.hero-slide.active { opacity: 1; }
.hero-slide img { width: 100%; height: 100%; object-fit: cover; }

.hero-fallback {
    position: absolute; inset: 0;
    display: flex; align-items: center;
    background: linear-gradient(120deg, var(--ct-blue) 0%, var(--ct-blue-dark) 60%, #001c3d 100%);
    overflow: hidden;
}

.hero-fallback::before {
    content: '';
    position: absolute; right: -6%; top: -20%;
    width: 60%; height: 140%;
    background: radial-gradient(circle, rgba(249,168,37,0.18) 0%, transparent 65%);
}

.hero-fallback::after {
    content: '';
    position: absolute; left: 8%; bottom: -30%;
    width: 40%; height: 100%;
    border: 60px solid rgba(255,255,255,0.04);
    border-radius: 50%;
}

/* Hoạ tiết bánh răng xưởng nghề - lấp khoảng trống bên phải hero */
.hero-gear {
    position: absolute;
    right: 4%; top: 50%;
    transform: translateY(-50%);
    width: 340px; height: 340px;
    opacity: 0.10;
    pointer-events: none;
}
.hero-gear svg { width: 100%; height: 100%; stroke: #fff; fill: none; stroke-width: 0.6; }
.hero-gear.gear-2 {
    width: 160px; height: 160px;
    right: 22%; top: 20%;
    opacity: 0.08;
    animation: none;
}

@media (max-width: 768px) {
    .hero-gear { display: none; }
}

.hero-fallback-content {
    position: relative;
    color: #fff;
    max-width: 620px;
    padding: 0 20px;
}

.hero-fallback-content .eyebrow { color: var(--ct-gold); }

.hero-fallback-content h1 {
    font-size: clamp(24px, 4vw, 38px);
    font-weight: 800;
    line-height: 1.25;
    margin: 10px 0 14px;
}

.hero-fallback-content p {
    color: rgba(255,255,255,0.82);
    font-size: 15px;
    margin-bottom: 22px;
    max-width: 480px;
}

.hero-dots {
    position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%);
    display: flex; gap: 8px; z-index: 5;
}
.hero-dots button {
    width: 8px; height: 8px; border-radius: 50%;
    background: rgba(255,255,255,0.4); border: none;
}
.hero-dots button.active { background: #fff; width: 22px; border-radius: 5px; }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 24px;
    font-size: 14px; font-weight: 700;
    border-radius: 999px;
    border: 1.5px solid transparent;
    transition: all .15s;
    white-space: nowrap;
}

.btn-primary { background: var(--ct-gold); color: var(--ct-blue-dark); }
.btn-primary:hover { background: #ffb938; transform: translateY(-1px); }

.btn-outline-light { background: transparent; border-color: rgba(255,255,255,0.5); color: #fff; }
.btn-outline-light:hover { background: rgba(255,255,255,0.12); }

.btn-blue { background: var(--ct-blue); color: #fff; }
.btn-blue:hover { background: var(--ct-blue-light); }

.btn-outline-blue { background: transparent; border-color: var(--ct-blue); color: var(--ct-blue); }
.btn-outline-blue:hover { background: #eef3fb; }

.btn-block { width: 100%; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* ============================================================
   Category tab strip (SIGNATURE ELEMENT)
   ============================================================ */
.category-strip-wrap {
    position: relative;
    margin-bottom: 28px;
}

.category-strip {
    display: flex;
    gap: 6px;
    overflow-x: auto;
    padding: 2px 4px 4px 2px;
    scrollbar-width: none;
    scroll-behavior: smooth;
}
.category-strip::-webkit-scrollbar { display: none; }

/* Đệm cuối để tab cuối không chạm sát viền */
.category-strip::after {
    content: '';
    flex: 0 0 4px;
}

/* Gradient mờ 2 mép gợi ý còn nội dung có thể cuộn */
.category-strip-wrap::before,
.category-strip-wrap::after {
    content: '';
    position: absolute;
    top: 0; bottom: 4px;
    width: 36px;
    pointer-events: none;
    z-index: 2;
    transition: opacity .2s;
}
.category-strip-wrap::before {
    left: 0;
    background: linear-gradient(90deg, var(--paper) 10%, transparent);
    opacity: 0;
}
.category-strip-wrap::after {
    right: 0;
    background: linear-gradient(270deg, var(--paper) 10%, transparent);
}
.category-strip-wrap.scrolled-start::before { opacity: 1; }
.category-strip-wrap.scrolled-end::after { opacity: 0; }

.strip-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 30px; height: 30px;
    border-radius: 50%;
    background: var(--white);
    border: 1.5px solid var(--line);
    box-shadow: var(--shadow-sm);
    display: flex; align-items: center; justify-content: center;
    z-index: 3;
    transition: opacity .2s, visibility .2s;
}
.strip-arrow svg { width: 14px; height: 14px; stroke: var(--ct-blue); fill: none; stroke-width: 2.5; }
.strip-arrow.prev { left: -14px; }
.strip-arrow.next { right: -14px; }
.strip-arrow:hover { border-color: var(--ct-blue); }
.strip-arrow[hidden] { display: none; }

.category-tab {
    display: flex; align-items: center; gap: 6px;
    padding: 8px 14px 8px 8px;
    background: var(--white);
    border: 1.5px solid var(--line);
    border-radius: 999px;
    font-weight: 600;
    font-size: 12.5px;
    color: var(--steel);
    flex-shrink: 0;
    transition: all .15s;
    position: relative;
}

.category-tab .tab-icon {
    width: 22px; height: 22px; border-radius: 50%;
    background: #eef1f6;
    display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.category-tab .tab-icon svg { width: 12px; height: 12px; stroke: var(--steel); fill: none; }

.category-tab:hover { border-color: var(--ct-blue); color: var(--ct-blue); }

.category-tab.active {
    background: var(--ct-blue); border-color: var(--ct-blue); color: #fff;
}
.category-tab.active .tab-icon { background: rgba(255,255,255,0.18); }
.category-tab.active .tab-icon svg { stroke: #fff; }

.category-select-mobile { display: none; }

/* ============================================================
   Course grid & cards
   ============================================================ */
.course-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.course-card {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden;
    transition: all .2s;
    display: flex;
    flex-direction: column;
}

.course-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
    border-color: var(--line-strong);
}

.course-card .thumb {
    aspect-ratio: 4/3;
    background: linear-gradient(135deg, #eef1f6, #e2e7f0);
    position: relative;
    overflow: hidden;
}
.course-card .thumb img { width: 100%; height: 100%; object-fit: cover; }

.course-card .thumb-placeholder {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    color: var(--line-strong);
}
.course-card .thumb-placeholder svg { width: 44px; height: 44px; }

.course-card .badge-featured {
    position: absolute; top: 10px; left: 10px;
    background: var(--ct-gold); color: var(--ct-blue-dark);
    font-size: 10.5px; font-weight: 800;
    padding: 4px 10px; border-radius: 999px;
    text-transform: uppercase; letter-spacing: .4px;
}

.course-card .badge-category {
    position: absolute; top: 10px; right: 10px;
    background: rgba(0,59,123,0.85); color: #fff;
    font-size: 10.5px; font-weight: 700;
    padding: 4px 10px; border-radius: 999px;
    backdrop-filter: blur(2px);
}

.course-card .body {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.course-card h3 {
    font-size: 15px;
    font-weight: 700;
    line-height: 1.4;
    color: var(--ink);
    margin-bottom: 12px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 42px;
}

.course-card .meta-row {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 12.5px;
    color: var(--steel);
    font-weight: 600;
    margin-bottom: 14px;
    padding-top: 12px;
    border-top: 1px dashed var(--line);
}

.course-card .meta-row span {
    display: flex; align-items: center; gap: 5px;
}
.course-card .meta-row svg { width: 14px; height: 14px; stroke: var(--ct-blue); fill: none; flex-shrink: 0; }
.course-card .meta-row .price { color: var(--ct-red); font-weight: 800; }

.course-card .btn { margin-top: auto; }

/* ============================================================
   Course detail page
   ============================================================ */
.breadcrumb {
    display: flex; align-items: center; gap: 6px;
    font-size: 13px; color: var(--steel);
    padding: 16px 0;
    flex-wrap: wrap;
}
.breadcrumb a { color: var(--steel); }
.breadcrumb a:hover { color: var(--ct-blue); }
.breadcrumb .sep { opacity: .5; }
.breadcrumb .current { color: var(--ink); font-weight: 600; }

.course-detail-header {
    background: var(--white);
    border-radius: var(--radius);
    border: 1px solid var(--line);
    padding: 28px;
    margin-bottom: 24px;
}

.course-detail-header .category-tag {
    display: inline-block;
    background: #eef3fb; color: var(--ct-blue);
    font-size: 12px; font-weight: 700;
    padding: 5px 12px; border-radius: 999px;
    margin-bottom: 12px;
}

.course-detail-header h1 {
    font-size: 26px; font-weight: 800; color: var(--ink);
    margin-bottom: 14px; line-height: 1.35;
}

.course-detail-header .stat-row {
    display: flex; flex-wrap: wrap; gap: 20px;
    padding-top: 16px; margin-top: 4px;
    border-top: 1px dashed var(--line);
}

.course-detail-header .stat-item {
    display: flex; align-items: center; gap: 8px;
}
.course-detail-header .stat-item .stat-icon {
    width: 36px; height: 36px; border-radius: 8px;
    background: #eef3fb; display: flex; align-items: center; justify-content: center;
    flex-shrink: 0;
}
.course-detail-header .stat-icon svg { width: 18px; height: 18px; stroke: var(--ct-blue); fill: none; }
.course-detail-header .stat-item .label { font-size: 11px; color: var(--steel); }
.course-detail-header .stat-item .value { font-size: 14px; font-weight: 700; color: var(--ink); }

.detail-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 24px;
    align-items: start;
}

.detail-main .content-block {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 24px;
    margin-bottom: 20px;
}

.detail-main .content-block h2 {
    font-size: 17px; font-weight: 800; color: var(--ct-blue);
    margin-bottom: 14px;
    display: flex; align-items: center; gap: 8px;
}
.detail-main .content-block h2::before {
    content: ''; width: 4px; height: 18px;
    background: var(--ct-gold); border-radius: 2px;
}

.detail-main .content-block .rich-content { color: var(--ink); font-size: 14.5px; line-height: 1.75; }
.detail-main .content-block .rich-content p { margin-bottom: 10px; }
.detail-main .content-block .rich-content ul,
.detail-main .content-block .rich-content ol { margin: 10px 0 10px 20px; }

.teacher-card {
    display: flex; align-items: center; gap: 14px;
    padding: 14px;
    background: #f7f9fc;
    border-radius: var(--radius-sm);
}
.teacher-avatar {
    width: 52px; height: 52px; border-radius: 50%;
    background: var(--ct-blue); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 18px; flex-shrink: 0;
}
.teacher-info div { font-size: 13px; color: var(--steel); margin-top: 2px; }
.teacher-info strong { font-size: 15px; color: var(--ink); }

/* Sidebar sticky */
.detail-sidebar { position: sticky; top: 92px; }

.reg-box {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 22px;
    box-shadow: var(--shadow-sm);
}

.reg-box .price-display {
    text-align: center;
    padding: 16px;
    background: linear-gradient(135deg, #fff8e6, #fff3d6);
    border-radius: var(--radius-sm);
    margin-bottom: 18px;
}
.reg-box .price-display .label { font-size: 12px; color: var(--steel); margin-bottom: 4px; }
.reg-box .price-display .amount { font-size: 24px; font-weight: 800; color: var(--ct-red); }

.reg-box .form-group { margin-bottom: 14px; }
.reg-box label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 5px; color: var(--ink); }
.reg-box .form-control {
    width: 100%; padding: 10px 12px; font-size: 14px;
    border: 1.5px solid var(--line); border-radius: 8px; outline: none;
    font-family: inherit; transition: border-color .15s;
}
.reg-box .form-control:focus { border-color: var(--ct-blue); }
.reg-box textarea.form-control { resize: vertical; min-height: 70px; }

.reg-note {
    font-size: 12.5px; color: var(--steel);
    background: #f7f9fc; padding: 10px 12px; border-radius: 8px;
    margin-top: 14px; line-height: 1.5;
}

.reg-success {
    text-align: center; padding: 24px 12px;
}
.reg-success .icon-check {
    width: 56px; height: 56px; border-radius: 50%;
    background: #e8f5e9; color: #2e7d32;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px; font-size: 28px;
}
.reg-success h3 { font-size: 17px; margin-bottom: 8px; color: var(--ink); }
.reg-success p { font-size: 13.5px; color: var(--steel); margin-bottom: 16px; }

.qr-payment-box { text-align: center; margin-top: 16px; }
.qr-payment-box img { max-width: 220px; margin: 0 auto 10px; border: 1px solid var(--line); border-radius: 8px; }
.qr-payment-box .qr-note { font-size: 12.5px; color: var(--steel); }

/* Floating sticky register button (mobile) */
.floating-register {
    display: none;
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 150;
    background: var(--white);
    border-top: 1px solid var(--line);
    padding: 12px 16px;
    box-shadow: 0 -4px 16px rgba(0,0,0,0.08);
}

/* ============================================================
   Chatbot floating widget
   ============================================================ */
.chatbot-fab {
    position: fixed; right: 22px; bottom: 22px; z-index: 300;
    width: 58px; height: 58px; border-radius: 50%;
    background: var(--ct-blue);
    display: flex; align-items: center; justify-content: center;
    box-shadow: var(--shadow-lg);
    border: none;
    transition: transform .2s;
}
.chatbot-fab:hover { transform: scale(1.06); }
.chatbot-fab svg { width: 26px; height: 26px; fill: #fff; }

.chatbot-fab .pulse-dot {
    position: absolute; top: 2px; right: 2px;
    width: 12px; height: 12px; border-radius: 50%;
    background: var(--ct-gold); border: 2px solid #fff;
}

.chatbot-panel {
    position: fixed; right: 22px; bottom: 92px; z-index: 300;
    width: 360px; max-width: calc(100vw - 32px);
    height: 480px; max-height: calc(100vh - 140px);
    background: var(--white);
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    display: none;
    flex-direction: column;
    overflow: hidden;
}
.chatbot-panel.open { display: flex; }

.chatbot-panel .cb-header {
    background: var(--ct-blue); color: #fff;
    padding: 16px; display: flex; align-items: center; justify-content: space-between;
}
.chatbot-panel .cb-header strong { font-size: 14px; display: block; }
.chatbot-panel .cb-header small { opacity: .8; font-size: 12px; }
.chatbot-panel .cb-close { background: none; border: none; color: #fff; font-size: 20px; opacity: .8; }

.chatbot-panel .cb-messages {
    flex: 1; overflow-y: auto; padding: 16px;
    display: flex; flex-direction: column; gap: 10px;
}

.cb-msg { max-width: 85%; padding: 10px 13px; border-radius: 12px; font-size: 13.5px; line-height: 1.5; }
.cb-msg.bot { background: #f1f4f9; align-self: flex-start; border-bottom-left-radius: 4px; }
.cb-msg.user { background: var(--ct-blue); color: #fff; align-self: flex-end; border-bottom-right-radius: 4px; }

.chatbot-panel .cb-input {
    display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--line);
}
.chatbot-panel .cb-input input {
    flex: 1; border: 1.5px solid var(--line); border-radius: 999px;
    padding: 10px 16px; font-size: 13.5px; outline: none; font-family: inherit;
}
.chatbot-panel .cb-input button {
    width: 40px; height: 40px; border-radius: 50%; background: var(--ct-blue);
    border: none; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.chatbot-panel .cb-input button svg { width: 16px; height: 16px; fill: #fff; }

/* ============================================================
   Static page content
   ============================================================ */
.static-page {
    background: var(--white);
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px;
    max-width: 860px;
}
.static-page h1 { font-size: 24px; font-weight: 800; color: var(--ct-blue); margin-bottom: 20px; }
.static-page .rich-content { font-size: 15px; line-height: 1.8; color: var(--ink); }
.static-page .rich-content h2 { font-size: 18px; font-weight: 700; margin: 20px 0 10px; color: var(--ct-blue); }
.static-page .rich-content p { margin-bottom: 12px; }
.static-page .rich-content ul, .static-page .rich-content ol { margin: 10px 0 10px 22px; }

/* ============================================================
   Contact info blocks
   ============================================================ */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 28px;
}
.contact-card {
    background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm);
    padding: 20px; text-align: center;
    transition: all .2s;
}
.contact-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-3px);
    border-color: var(--line-strong);
}
.contact-card .icon {
    width: 44px; height: 44px; border-radius: 50%; background: #eef3fb;
    display: flex; align-items: center; justify-content: center; margin: 0 auto 12px;
    transition: background .2s;
}
.contact-card:hover .icon { background: var(--ct-blue); }
.contact-card:hover .icon svg { stroke: #fff; }
.contact-card .icon svg { width: 22px; height: 22px; stroke: var(--ct-blue); fill: none; transition: stroke .2s; }
.contact-card h4 { font-size: 14px; margin-bottom: 6px; }
.contact-card p { font-size: 13.5px; color: var(--steel); }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
    background: var(--ct-blue-dark);
    color: rgba(255,255,255,0.85);
    margin-top: 60px;
}

.footer-main {
    padding: 48px 0 32px;
    display: grid;
    grid-template-columns: 1.3fr 1fr 1fr 1.3fr;
    gap: 32px;
}

.footer-col { position: relative; }
.footer-col:not(.footer-brand)::before {
    content: '';
    position: absolute;
    left: -16px; top: 4px; bottom: 4px;
    width: 1px;
    background: rgba(255,255,255,0.12);
}

.footer-col h4 {
    color: #fff; font-size: 13.5px; font-weight: 700;
    text-transform: uppercase; letter-spacing: .5px;
    margin-bottom: 16px;
    padding-bottom: 12px;
    position: relative;
}
.footer-col h4::after {
    content: '';
    position: absolute; left: 0; bottom: 0;
    width: 28px; height: 2px;
    background: var(--ct-gold);
}

.footer-col p, .footer-col a {
    font-size: 13.5px; color: rgba(255,255,255,0.7);
    line-height: 2; display: block;
}
.footer-col a:hover { color: var(--ct-gold); }

.footer-brand .site-logo { color: #fff; margin-bottom: 12px; }
.footer-brand p { max-width: 280px; margin-top: 8px; }

.footer-contact-line {
    display: flex;
    align-items: flex-start;
    gap: 9px;
    margin-bottom: 13px;
    font-size: 13.5px;
    color: rgba(255,255,255,0.7);
    line-height: 1.5;
}
.footer-contact-line svg {
    width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px;
    stroke: var(--ct-gold); fill: none; stroke-width: 2;
}

.footer-social { display: flex; gap: 10px; }
.footer-social a {
    width: 36px; height: 36px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: #1877F2;
    transition: transform .15s, opacity .15s;
}
.footer-social a.zalo-btn { background: #0068FF; }
.footer-social a:hover { transform: translateY(-2px); opacity: .9; }
.footer-social a svg { width: 18px; height: 18px; fill: #fff; }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.12);
    padding: 18px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    font-size: 12.5px;
    color: rgba(255,255,255,0.55);
}

/* ============================================================
   Alerts
   ============================================================ */
.alert { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px; }
.alert-success { background: #e8f5e9; color: #2e7d32; }
.alert-error { background: #fdecea; color: var(--ct-red); }

/* ============================================================
   Empty state
   ============================================================ */
.empty-block { text-align: center; padding: 60px 20px; color: var(--steel); }
.empty-block svg { width: 48px; height: 48px; stroke: var(--line-strong); fill: none; margin-bottom: 12px; }

/* ============================================================
   Pagination
   ============================================================ */
.pagination { display: flex; gap: 6px; justify-content: center; margin-top: 32px; }
.pagination a, .pagination span {
    min-width: 38px; height: 38px; display: flex; align-items: center; justify-content: center;
    border-radius: 8px; font-size: 13.5px; font-weight: 600;
    border: 1.5px solid var(--line); color: var(--ink);
}
.pagination a:hover { border-color: var(--ct-blue); color: var(--ct-blue); }
.pagination .active { background: var(--ct-blue); border-color: var(--ct-blue); color: #fff; }

/* ============================================================
   Responsive
   ============================================================ */
/* Mốc trung gian: nav vẫn hiện đầy đủ nhưng thu gọn để không vỡ dòng */
@media (max-width: 1280px) {
    .header-search form { width: 190px; }
    .header-search form:focus-within { width: 220px; }
}

@media (max-width: 1180px) {
    .main-nav > li > a { padding: 10px 10px; font-size: 13px; }
    .site-logo .logo-text { font-size: 13.5px; max-width: 160px; }
}

@media (max-width: 1024px) {
    .course-grid { grid-template-columns: repeat(3, 1fr); }
    .detail-layout { grid-template-columns: 1fr; }
    .detail-sidebar { position: static; }
    .footer-main { grid-template-columns: 1fr 1fr; row-gap: 36px; }
    .footer-col:nth-child(odd)::before { display: none; }
}

/* Nav/search chuyển sang menu hamburger sớm hơn (900px) để tránh vỡ dòng ở màn hình vừa */
@media (max-width: 900px) {
    .main-nav, .header-search { display: none; }
    .btn-mobile-menu { display: block; }
}

@media (max-width: 768px) {
    .course-grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
    .contact-grid { grid-template-columns: 1fr; }
    .footer-main { grid-template-columns: 1fr; gap: 28px; padding: 32px 0 20px; }
    .footer-col::before { display: none; }
    .footer-bottom { flex-direction: column; text-align: center; gap: 14px; }

    .category-strip-wrap { display: none; }
    .category-select-mobile { display: block; margin-bottom: 20px; }
    .category-select-mobile select {
        width: 100%; padding: 12px 14px; font-size: 14px;
        border: 1.5px solid var(--line); border-radius: 10px;
        font-family: inherit; background: var(--white);
    }

    .course-detail-header { padding: 20px; }
    .course-detail-header h1 { font-size: 20px; }
    .course-detail-header .stat-row { gap: 12px; }

    .chatbot-panel { right: 12px; left: 12px; width: auto; bottom: 82px; }
    .chatbot-fab { right: 16px; bottom: 16px; }

    .section { padding: 32px 0; }
    .section-title { font-size: 21px; }
}

@media (max-width: 480px) {
    .course-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
    .course-card h3 { font-size: 13.5px; min-height: 38px; }
    .header-inner { height: 64px; }
    .site-logo .logo-mark { width: 38px; height: 38px; }
    .site-logo .logo-text { font-size: 13px; }
}
