* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial;
  background: #f5f6ff;
  color: #1f2937;
}

/* ===== HEADER ===== */
.cx-top {
  background: #ffffff;
  border-bottom: 1px solid #e5e7eb;
}

.cx-top-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 0;
}

.cx-container {
  width: min(1100px, 92%);
  margin: auto;
}

.cx-brand {
  display: flex;
  gap: 12px;
  align-items: center;
}

.cx-logo {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #6a5ae0, #fc5cc5);
  color: #fff;
  font-weight: 900;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cx-title {
  font-weight: 800;
}

.cx-subtitle {
  font-size: 13px;
  color: #6b7280;
}

.cx-back {
  text-decoration: none;
  background: #ede9fe;
  padding: 8px 14px;
  border-radius: 12px;
  font-weight: 700;
  color: #6a5ae0;
}

/* ===== HERO ===== */
.cx-hero {
  margin: 20px 0;
  padding: 20px;
  border-radius: 18px;
  background: linear-gradient(135deg, #ece9ff, #fde7f4);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cx-hero h1 {
  margin: 0 0 6px;
}

.cx-tip {
  background: #ffffffaa;
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 13px;
}

/* ===== CONTROLS ===== */
.cx-controls {
  background: #ffffff;
  padding: 18px;
  border-radius: 18px;
  box-shadow: 0 10px 30px rgba(0,0,0,.08);
}

.cx-levels {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
}

.cx-pill {
  border: none;
  background: #ede9fe;
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 800;
  cursor: pointer;
  color: #6a5ae0;
}

.cx-pill.active {
  background: linear-gradient(135deg, #6a5ae0, #fc5cc5);
  color: #fff;
}

.cx-search {
  width: 100%;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid #e5e7eb;
  margin-bottom: 14px;
}

.cx-filters {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.cx-filters select {
  padding: 8px 12px;
  border-radius: 12px;
}

.cx-check {
  font-weight: 700;
}

.cx-count {
  margin-top: 10px;
  color: #6b7280;
  font-weight: 700;
}

/* ===== GRID ===== */
.cx-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  margin: 20px 0;
}

.cx-card {
  background: #ffffff;
  border-radius: 18px;
  padding: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,.1);
  display: flex;
  flex-direction: column;
  transition: transform .2s;
}

.cx-card:hover {
  transform: translateY(-4px);
}

.cx-tags {
  display: flex;
  gap: 8px;
  margin-bottom: 8px;
}

.cx-tag {
  font-size: 11px;
  font-weight: 800;
  padding: 4px 10px;
  border-radius: 999px;
  background: #ede9fe;
  color: #6a5ae0;
}

.cx-tag.ext {
  background: #fde7f4;
  color: #c026d3;
}

.cx-card h3 {
  margin: 6px 0;
}

.cx-meta {
  font-size: 13px;
  color: #6b7280;
}

.cx-desc {
  margin: 10px 0;
  flex: 1;
}

.cx-btn {
  display: block;
  text-align: center;
  padding: 12px;
  border-radius: 14px;
  background: linear-gradient(135deg, #6a5ae0, #fc5cc5);
  color: #fff;
  font-weight: 800;
  text-decoration: none;
}

/* ===== EMPTY ===== */
.cx-empty {
  display: none;
  text-align: center;
  padding: 40px;
  color: #6b7280;
}

.cx-empty.show {
  display: block;
}

/* ===== FOOTER ===== */
.cx-footer {
  text-align: center;
  padding: 20px;
  color: #6b7280;
}
