/* ===========================================
   archive-courses US - HERO SECTION
   =========================================== */
.archive-courses-hero {
  position: relative;
  height: 320px;
  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
  align-items: center;
  margin-top: 60px;
}

.archive-courses-hero__banner {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.archive-courses-hero__banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.archive-courses-hero__overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
}

.archive-courses-hero__content {
  position: relative;
  z-index: 2;
  text-align: center;
}

.archive-courses-hero__title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 700;
  color: #ffffff;
  margin: 0 0 16px;
  text-transform: uppercase;
  letter-spacing: 2px;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.archive-courses-hero__subtitle {
  font-size: clamp(18px, 2.5vw, 24px);
  font-weight: 500;
  color: #ffffff;
  margin: 0;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* ===================================================
   VIEW MODE
   =================================================== */
.view-toggle {
  display: flex;
  gap: 4px;
  margin-bottom: 1rem;
  justify-content: flex-end;
}

.btn-view {
  padding: 8px;
  border: 1px solid #ddd;
  background: #fff;
  cursor: pointer;
  border-radius: 4px;
  color: #666;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.btn-view:hover {
  background: #f5f5f5;
  border-color: var(--color-secondary);
}

.btn-view.active {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
  color: #fff;
}

/* ===================================================
   FILTER SIDEBAR
   =================================================== */
/* Archive Courses Layout */
.archive-courses-page {
  /* padding-top: calc(var(--header-height) + 30px); */
  padding-bottom: 60px;
  min-height: 100vh;
}

.archive-courses-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 30px;
}

.filter-sidebar {
  background: #ffffff;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  overflow: hidden;
  height: fit-content;
  position: sticky;
  top: 85px;
}

/* Filter Group */
.filter-group {
  border-bottom: 1px solid #e8e8e8;
}

.filter-group:last-child {
  border-bottom: none;
}

/* Header */
.filter-group-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  cursor: pointer;
  transition: background-color var(--transition-fast);
}

.filter-group-header:hover {
  background-color: #fafafa;
}

.filter-group-title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary);
}

.filter-group-arrow {
  color: var(--color-secondary);
  transition: transform var(--transition-normal);
}

.filter-group.is-open .filter-group-arrow {
  transform: rotate(180deg);
}

/* Content */
.filter-group-content {
  padding: 0 20px 18px;
}

.filter-group.is-open .filter-group-content {
  display: block;
}
/* ==================================================
    Custom Input Search
   ==================================================*/

.gr-search {
  position: relative;
}
.filter-input-search {
  width: 100%;
  padding: 12px 40px 12px 15px; /* chừa chỗ bên phải cho icon */
  border: 1px solid #ddd;
  border-radius: 6px;
  font-size: 13px;
  outline: none;
}

.filter-group-content {
  position: relative;
  /* nếu bạn muốn input full width và icon trong cùng block */
}
.filter-group-content .btn-search {
  position: absolute;
  top: 50%;
  right: 5px;
  transform: translateY(-50%);
  cursor: pointer;
  pointer-events: auto;
  transition: opacity 0.2s;
  padding: 8px;
  width: 30px;
  height: 30px;
  background-color: var(--color-secondary);
  border-radius: 5px;
}
.filter-group-content .btn-search path {
  fill: #fff;
}
.filter-group-content .btn-search:hover {
  opacity: 0.7;
}

/* ===================================================
   CUSTOM CHECKBOX
   =================================================== */
.filter-checkbox {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 0;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-checkbox:hover .checkbox-label {
  color: var(--color-secondary);
}

/* Hide default checkbox */
.filter-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

/* Custom checkbox box */
.checkbox-custom {
  position: relative;
  width: 20px;
  height: 20px;
  min-width: 20px;
  border: 2px solid #d0d0d0;
  border-radius: 4px;
  background: #ffffff;
  transition: all var(--transition-fast);
}

/* Checkmark icon */
.checkbox-custom::after {
  content: "";
  position: absolute;
  top: 0px;
  left: 5px;
  width: 5px;
  height: 10px;
  border: solid #ffffff;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
  transition: transform var(--transition-fast);
}

/* Checked state */
.filter-checkbox input[type="checkbox"]:checked + .checkbox-custom {
  background: var(--color-secondary);
  border-color: var(--color-secondary);
}

.filter-checkbox input[type="checkbox"]:checked + .checkbox-custom::after {
  transform: rotate(45deg) scale(1);
}

/* Focus state */
.filter-checkbox input[type="checkbox"]:focus + .checkbox-custom {
  box-shadow: 0 0 0 3px rgba(57, 166, 83, 0.2);
}

/* Hover state */
.filter-checkbox:hover .checkbox-custom {
  border-color: var(--color-secondary);
}

/* Label */
.checkbox-label {
  font-size: 14px;
  color: var(--color-text-light);
  transition: color var(--transition-fast);
  user-select: none;
}

.filter-checkbox input[type="checkbox"]:checked ~ .checkbox-label {
  color: var(--color-text);
  font-weight: 500;
}

/* ===================================================
   FILTER SIDEBAR RESPONSIVE
   =================================================== */
@media screen and (max-width: 1024px) {
  .filter-sidebar {
    margin-bottom: 24px;
  }
}

@media screen and (max-width: 768px) {
  /* ===========================================
   archive-courses US - HERO SECTION
   =========================================== */

  .archive-courses-hero__title {
    letter-spacing: 1px;
  }

  .filter-group-header {
    padding: 15px;
  }

  .filter-group-content {
    padding: 0 15px 15px;
  }

  .filter-group-title {
    font-size: 15px;
  }

  .checkbox-label {
    font-size: 13px;
  }
}
