/* ================================================================
   CL THEME — Trang chủ (11/2026): Hero, Tin tức, Môn phái,
   Xếp hạng, Top nạp, Cộng đồng. Cuộn thường, không fullpage.
   ================================================================ */

/* ---------- Khung section ---------- */
.cl-hsec { position: relative; padding: 88px 0; scroll-margin-top: var(--cl-header-h); }
.cl-hsec:nth-of-type(even) { background: linear-gradient(180deg, var(--cl-ink-800), var(--cl-ink-700)); }
.cl-hsec .cl-heading { margin-bottom: 40px; }
.cl-hsec .cl-title { margin: 0; }
.cl-hsec__more { margin-top: 36px; }

/* ---------- Hero ---------- */
.cl-hero {
    position: relative;
    display: flex;
    align-items: flex-end;
    min-height: max(640px, 100vh);
    padding: calc(var(--cl-header-h) + 40px) 0 56px;
    overflow: hidden;
    isolation: isolate;
    text-align: center;
}
.cl-hero__bg {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: var(--img-hero) center 30% / cover no-repeat, var(--cl-bg-plain);
}
.cl-hero__bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(13, 4, 0, 0.35) 0%, rgba(13, 4, 0, 0) 30%, rgba(22, 8, 0, 0.55) 62%, var(--cl-ink-700) 100%);
}
.cl-hero__inner { display: flex; flex-direction: column; align-items: center; gap: 28px; }
.cl-hero__brand { display: flex; flex-direction: column; align-items: center; }
.cl-hero__logo { width: clamp(96px, 11vw, 140px); height: auto; filter: drop-shadow(0 6px 20px rgba(0, 0, 0, 0.6)); }
.cl-hero__title {
    margin: 10px 0 0 !important;
    font-size: clamp(40px, 6vw, 76px) !important;
    font-weight: 800 !important;
    line-height: 1.05 !important;
    text-transform: uppercase;
    background: var(--cl-grad-gold-text);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent !important;
    filter: drop-shadow(0 4px 16px rgba(0, 0, 0, 0.7));
}
.cl-hero__tagline {
    margin: 8px 0 0;
    font-size: clamp(14px, 1.4vw, 18px);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--cl-text-strong);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.8);
}
.cl-hero__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.cl-hero__actions .cl-btn { min-width: 180px; }
.cl-hero__download { min-width: 220px !important; }

.cl-hero__stats {
    display: flex;
    margin: 0;
    padding: 0;
    list-style: none;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: rgba(13, 4, 0, 0.75);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}
.cl-hero__stats li {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    padding: 12px 22px;
    text-align: left;
}
.cl-hero__stats li + li { border-left: 1px solid var(--cl-gold-a20); }
.cl-hero__stats span { font-size: 12px; text-transform: uppercase; color: var(--cl-text-dim); }
.cl-hero__stats strong { font-size: 16px; color: var(--cl-orange); white-space: nowrap; }

/* ---------- Tin tức ---------- */
.cl-hnews__grid {
    display: grid;
    grid-template-columns: minmax(0, 3fr) minmax(0, 2fr);
    gap: 24px;
}
.cl-hnews__slider {
    position: relative;
    aspect-ratio: 16 / 9;
    overflow: hidden;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: var(--cl-bg-plain);
}
.cl-hnews__slider .cl-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.6s var(--cl-ease), visibility 0.6s;
}
.cl-hnews__slider .cl-slide.is-active { opacity: 1; visibility: visible; }
.cl-hnews__slider .cl-slide a, .cl-hnews__slider .cl-slide img { display: block; width: 100%; height: 100%; }
.cl-hnews__slider .cl-slide img { object-fit: cover; }
.cl-hnews__arrow {
    position: absolute;
    top: 50%;
    z-index: 2;
    display: grid;
    place-items: center;
    width: 40px; height: 40px;
    margin-top: -20px;
    border: 1px solid var(--cl-gold-a50);
    border-radius: 50%;
    background: rgba(13, 4, 0, 0.7);
    color: var(--cl-orange);
    font-size: 16px;
    cursor: pointer;
    opacity: 0;
    transition: opacity var(--cl-dur) var(--cl-ease), background var(--cl-dur) var(--cl-ease);
}
.cl-hnews__slider:hover .cl-hnews__arrow, .cl-hnews__arrow:focus-visible { opacity: 1; }
.cl-hnews__arrow:hover { background: var(--cl-grad-gold); color: #2a1100; }
.cl-hnews__arrow--prev { left: 12px; }
.cl-hnews__arrow--next { right: 12px; }
.cl-hnews__dots {
    position: absolute;
    left: 0; right: 0; bottom: 12px;
    z-index: 2;
    display: flex;
    justify-content: center;
    gap: 8px;
}
.cl-hnews__dot {
    width: 10px; height: 10px;
    padding: 0;
    border: 0;
    border-radius: 999px;
    background: rgba(255, 247, 232, 0.5);
    cursor: pointer;
    transition: width var(--cl-dur) var(--cl-ease), background var(--cl-dur) var(--cl-ease);
}
.cl-hnews__dot.is-active { width: 26px; background: var(--cl-orange); }

.cl-hnews__board {
    display: flex;
    flex-direction: column;
    min-width: 0;
    padding: 20px;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: rgba(13, 4, 0, 0.55);
}
.cl-hnews__tabs { margin-bottom: 12px; }
.cl-hnews__tabs .cl-tab { min-height: 32px; padding: 0 14px; font-size: 13px; }
.cl-hnews__list { margin: 0; padding: 0; list-style: none; }
.cl-hnews__item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 4px;
    border-bottom: 1px dashed var(--cl-gold-a20);
    color: var(--cl-text) !important;
}
.cl-hnews__list li:last-child .cl-hnews__item { border-bottom: 0; }
.cl-hnews__item .cl-tag { flex: none; }
.cl-hnews__title {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 15px;
    transition: color var(--cl-dur) var(--cl-ease);
}
.cl-hnews__item:hover .cl-hnews__title { color: var(--cl-orange); }
.cl-hnews__date { flex: none; font-size: 13px; color: var(--cl-text-dim); }
.cl-hnews__empty { padding: 32px 0; text-align: center; color: var(--cl-text-dim); }

/* ---------- Môn phái ---------- */
.cl-faction__box {
    display: grid;
    grid-template-columns: 220px minmax(0, 1fr);
    gap: 24px;
}
.cl-faction__tabs { display: flex; flex-direction: column; gap: 10px; }
.cl-faction__tab {
    min-height: 52px;
    padding: 0 20px;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: rgba(13, 4, 0, 0.6);
    color: var(--cl-text-strong);
    font-family: var(--cl-font-body);
    font-size: 16px;
    font-weight: 700;
    text-align: left;
    text-transform: uppercase;
    cursor: pointer;
    transition: background var(--cl-dur) var(--cl-ease), color var(--cl-dur) var(--cl-ease), border-color var(--cl-dur) var(--cl-ease);
}
.cl-faction__tab:hover { border-color: var(--cl-orange); color: var(--cl-orange); }
.cl-faction__tab.is-active { background: var(--cl-grad-gold); border-color: transparent; color: #2a1100; }

.cl-faction__stage { min-width: 0; }
.cl-faction__media {
    position: relative;
    aspect-ratio: 16 / 8;
    overflow: hidden;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: var(--cl-bg-plain);
}
.cl-faction__media img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 25%; }
.cl-faction__text { padding: 22px 4px 0; }
.cl-faction__name {
    margin: 0 0 10px !important;
    font-size: clamp(24px, 2.6vw, 32px) !important;
    font-weight: 800 !important;
    text-transform: uppercase;
    background: var(--cl-grad-gold-text);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent !important;
}
.cl-faction__desc { max-width: 820px; color: var(--cl-text); font-size: 16px; line-height: 1.75; }

/* ---------- Xếp hạng (bảng hiện luôn) ---------- */
.cl-hrank__box { max-width: 960px; margin: 0 auto; }
.cl-hrank__tabs { justify-content: center; margin-bottom: 20px; }
.cl-hrank__tabs .cl-tab { min-height: 42px; padding: 0 26px; font-size: 15px; }
.cl-hrank .cl-table-wrap {
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: rgba(13, 4, 0, 0.55);
}
.cl-hrank__table th, .cl-hrank__table td { text-align: center; }
.cl-hrank__table th:first-child, .cl-hrank__table td:first-child { width: 90px; }
.cl-hrank__name { font-weight: 700; color: var(--cl-text-strong) !important; }
.cl-hrank__table .cl-orange { font-weight: 700; }
.cl-hrank__empty { padding: 36px 12px !important; color: var(--cl-text-dim) !important; }

/* ---------- Top nạp ---------- */
.cl-htop__podium {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    gap: 20px;
    max-width: 760px;
    margin: 0 auto;
}
.cl-htop__place {
    display: flex;
    flex: 1 1 0;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 0;
    text-align: center;
}
.cl-htop__medal {
    display: grid;
    place-items: center;
    width: 72px; height: 72px;
    border-radius: 50%;
    font-size: 30px;
    font-weight: 800;
    color: #2a1100;
    box-shadow: 0 0 0 4px rgba(13, 4, 0, 0.8), 0 0 0 5px currentColor, 0 10px 26px rgba(0, 0, 0, 0.5);
}
.cl-htop__place--1 .cl-htop__medal { width: 92px; height: 92px; font-size: 38px; background: linear-gradient(135deg, #ffe17a, #d4a017); }
.cl-htop__place--2 .cl-htop__medal { background: linear-gradient(135deg, #f4f4f4, #a9adb3); }
.cl-htop__place--3 .cl-htop__medal { background: linear-gradient(135deg, #ff9a6b, #c0392b); color: #fff; }
.cl-htop__name {
    max-width: 100%;
    margin-top: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--cl-text-strong);
    font-size: 17px;
}
.cl-htop__amount { color: var(--cl-orange); font-weight: 700; }
.cl-htop__step {
    width: 100%;
    margin-top: 10px;
    border: 1px solid var(--cl-gold-a30);
    border-bottom: 0;
    border-radius: var(--cl-radius) var(--cl-radius) 0 0;
    background: linear-gradient(180deg, rgba(212, 175, 55, 0.22), rgba(13, 4, 0, 0.4));
}
.cl-htop__place--1 .cl-htop__step { height: 120px; }
.cl-htop__place--2 .cl-htop__step { height: 84px; }
.cl-htop__place--3 .cl-htop__step { height: 60px; }

.cl-htop__list {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px 24px;
    max-width: 900px;
    margin: 28px auto 0;
    padding: 0;
    list-style: none;
}
.cl-htop__list li {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border: 1px solid var(--cl-gold-a20);
    border-radius: var(--cl-radius);
    background: rgba(13, 4, 0, 0.55);
}
.cl-htop__no {
    display: grid;
    place-items: center;
    width: 30px; height: 30px;
    flex: none;
    border-radius: 50%;
    background: rgba(212, 175, 55, 0.16);
    color: var(--cl-gold-200);
    font-weight: 700;
    font-size: 14px;
}
.cl-htop__lname { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--cl-text-strong); }
.cl-htop__lamount { flex: none; color: var(--cl-orange); font-weight: 700; }

/* ---------- Cộng đồng ---------- */
.cl-hcom__grid { display: grid; gap: 20px; justify-content: center; }
.cl-hcom__grid--1 { grid-template-columns: minmax(0, 360px); }
.cl-hcom__grid--2 { grid-template-columns: repeat(2, minmax(0, 340px)); }
.cl-hcom__grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cl-hcom__grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cl-hcom__card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 30px 20px 24px;
    border: 1px solid var(--cl-gold-a30);
    border-radius: var(--cl-radius);
    background: linear-gradient(180deg, rgba(58, 29, 10, 0.7), rgba(13, 4, 0, 0.7));
    color: var(--cl-text) !important;
    text-align: center;
    transition: border-color var(--cl-dur) var(--cl-ease), transform var(--cl-dur) var(--cl-ease);
}
.cl-hcom__card:hover { border-color: var(--cl-orange); transform: translateY(-4px); }
.cl-hcom__icon {
    display: grid;
    place-items: center;
    width: 60px; height: 60px;
    margin-bottom: 6px;
    border-radius: 50%;
    background: var(--cl-grad-gold);
    color: #2a1100;
    font-size: 28px;
}
.cl-hcom__card strong { color: var(--cl-text-strong); font-size: 18px; }
.cl-hcom__card > span:not(.cl-hcom__icon):not(.cl-hcom__go) { font-size: 14px; color: var(--cl-text-dim); }
.cl-hcom__go { margin-top: 8px; color: var(--cl-orange); font-size: 13px; font-weight: 700; text-transform: uppercase; }

/* ---------- Responsive ---------- */
@media (max-width: 1023px) {
    .cl-hsec { padding: 64px 0; }
    .cl-hnews__grid { grid-template-columns: minmax(0, 1fr); }
    .cl-faction__box { grid-template-columns: minmax(0, 1fr); }
    .cl-faction__tabs { flex-direction: row; overflow-x: auto; padding-bottom: 4px; }
    .cl-faction__tab { flex: none; min-height: 42px; font-size: 14px; }
    .cl-hcom__grid--3, .cl-hcom__grid--4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
    .cl-hero { min-height: 600px; padding-bottom: 36px; }
    .cl-hero__actions { gap: 10px; }
    .cl-hero__actions .cl-btn { min-width: 0; flex: 1 1 140px; padding: 0 16px; }
    .cl-hero__download { flex-basis: 100% !important; order: -1; }
    .cl-hero__stats { width: 100%; }
    .cl-hero__stats li { flex: 1; padding: 10px 12px; }
    .cl-htop__podium { gap: 10px; }
    .cl-htop__medal { width: 52px; height: 52px; font-size: 22px; }
    .cl-htop__place--1 .cl-htop__medal { width: 64px; height: 64px; font-size: 28px; }
    .cl-htop__name { font-size: 14px; }
    .cl-htop__amount { font-size: 13px; }
    .cl-htop__list { grid-template-columns: minmax(0, 1fr); }
    .cl-hcom__grid--2, .cl-hcom__grid--3, .cl-hcom__grid--4 { grid-template-columns: minmax(0, 1fr); }
}
