/* ============================================================
   Influeri — Creator Cards · Profile-card showcase
   Additive layer. Reuses .creator card + tokens from styles.css and
   the tcm-* showcase chrome from trending-creators.css.
   All new treatment classes are prefixed cc- (creator-cards).
   White-mode discipline; pink->gold (--grad) used as accent only.
   ============================================================ */

.cc {
  --r-card: 16px;
  --shadow-card: 0 1px 2px rgba(11, 11, 11, 0.06), 0 12px 26px -14px rgba(11, 11, 11, 0.22);
  --shadow-lift: 0 4px 10px rgba(11, 11, 11, 0.06), 0 22px 44px -18px rgba(11, 11, 11, 0.28);
}

/* responsive grid scaffold shared by the card treatments */
.cc-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.cc-grid--2 { grid-template-columns: repeat(2, 1fr); }

/* ============================================================
   01 · CLASSIC — canonical .creator card in a tidy grid
   ============================================================ */
.cc-grid--classic .creator { width: 100%; }

/* ============================================================
   02 · MATCH-SCORE — gradient conic "% match" ring
   ============================================================ */
.cc-match {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 22px 22px 18px;
  background: var(--white);
  border: 1px solid rgba(11, 11, 11, 0.05);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
  transition: transform 0.16s ease, box-shadow 0.2s ease;
}
.cc-match:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.cc-match__top {
  display: flex;
  align-items: center;
  gap: 16px;
  width: 100%;
  margin-bottom: 16px;
}
.cc-match__ring {
  --pct: 0;
  flex: none;
  position: relative;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  /* the gradient sweeps to --pct% of the circle, rest is a soft track */
  background:
    conic-gradient(from -90deg, #0b0b0b 0%, #8a8a8a calc(var(--pct) * 1%), rgba(11, 11, 11, 0.07) 0);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.cc-match__hole {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  line-height: 1;
}
.cc-match__pct {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 18px;
  background: #0b0b0b;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
}
.cc-match__hole i { font-style: normal; font-size: 10px; color: var(--text); margin-top: 2px; }
.cc-match__avatar {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  padding: 2.5px;
  background: #0b0b0b;
  display: inline-flex;
}
.cc-match__avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 2.5px solid var(--white);
  display: block;
}
.cc-match__name { margin: 0; font-weight: 700; font-size: 16px; color: var(--primary); }
.cc-match__handle { margin: 2px 0 0; font-size: 13px; color: var(--text); }
.cc-match__tag { margin: 8px 0 0; font-size: 12.5px; color: #8a8a8a; }
.cc-match__foot {
  display: flex;
  gap: 16px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  width: 100%;
  font-size: 12.5px;
  color: var(--text);
}

/* ============================================================
   03 · STAT-BAR — followers / engagement / reach mini-bars
   ============================================================ */
.cc-stats {
  padding: 18px 20px 20px;
  background: var(--white);
  border: 1px solid rgba(11, 11, 11, 0.05);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
  transition: transform 0.16s ease, box-shadow 0.2s ease;
}
.cc-stats:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.cc-stats__head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.cc-stats__avatar { width: 46px; height: 46px; padding: 2px; }
.cc-stats__avatar img { border-width: 2px; }
.cc-stats__name { margin: 0; font-weight: 700; font-size: 15px; color: var(--primary); }
.cc-stats__handle { margin: 2px 0 0; font-size: 12.5px; color: var(--text); }
.cc-stats__row {
  display: grid;
  grid-template-columns: 78px 1fr auto;
  align-items: center;
  gap: 12px;
  margin-top: 11px;
}
.cc-stats__label { font-size: 12px; color: var(--text); }
.cc-stats__track {
  height: 8px;
  border-radius: 999px;
  background: rgba(11, 11, 11, 0.07);
  overflow: hidden;
}
.cc-stats__fill {
  display: block;
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: #0b0b0b;
  transition: width 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}
.cc-stats__val {
  font-weight: 700;
  font-size: 12.5px;
  color: var(--primary);
  font-variant-numeric: tabular-nums;
  min-width: 44px;
  text-align: right;
}

/* ============================================================
   04 · GLASS / ELEVATED — frosted hover-lift card
   ============================================================ */
.cc-glass {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 28px 22px 22px;
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92), rgba(255, 255, 255, 0.72));
  border: 1px solid rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-card);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  overflow: hidden;
  outline: none;
  transition: transform 0.22s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.28s ease;
}
/* faint neutral halo wash that strengthens on hover */
.cc-glass::before {
  content: "";
  position: absolute;
  inset: -40% 30% auto -30%;
  height: 70%;
  background: radial-gradient(60% 60% at 50% 0, rgba(11, 11, 11, 0.06), transparent 70%);
  opacity: 0.6;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.cc-glass:hover, .cc-glass:focus-visible {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lift);
}
.cc-glass:hover::before, .cc-glass:focus-visible::before { opacity: 1; }
.cc-glass__avatar {
  position: relative;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  padding: 3px;
  background: #0b0b0b;
  display: inline-flex;
  margin-bottom: 14px;
}
.cc-glass__avatar img {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--white);
  display: block;
}
.cc-glass__name { position: relative; margin: 0; font-weight: 700; font-size: 17px; color: var(--primary); }
.cc-glass__handle { position: relative; margin: 3px 0 0; font-size: 13px; color: var(--text); }
.cc-glass__tag {
  position: relative;
  margin: 10px 0 0;
  font-size: 12px;
  font-weight: 600;
  color: var(--primary);
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(11, 11, 11, 0.07);
}
.cc-glass__foot {
  position: relative;
  display: flex;
  gap: 24px;
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  width: 100%;
  justify-content: center;
}
.cc-glass__foot span { display: flex; flex-direction: column; font-size: 11.5px; color: var(--text); }
.cc-glass__foot b {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 16px;
  color: var(--primary);
  margin-bottom: 2px;
}

/* ============================================================
   05 · EXPANDABLE — hover/focus reveals platforms + recent posts
   ============================================================ */
.cc-exp {
  background: var(--white);
  border: 1px solid rgba(11, 11, 11, 0.05);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
  overflow: hidden;
  outline: none;
  transition: transform 0.16s ease, box-shadow 0.2s ease;
}
.cc-exp:hover, .cc-exp:focus-visible { box-shadow: var(--shadow-lift); }
.cc-exp__head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
}
.cc-exp__avatar { width: 48px; height: 48px; padding: 2px; }
.cc-exp__avatar img { border-width: 2px; }
.cc-exp__id { flex: 1; min-width: 0; }
.cc-exp__name { margin: 0; font-weight: 700; font-size: 15px; color: var(--primary); }
.cc-exp__handle { margin: 2px 0 0; font-size: 12.5px; color: var(--text); }
.cc-exp__chev {
  flex: none;
  color: var(--text);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}
/* the drawer: collapsed via grid-rows 0fr, opens to 1fr (smooth, no JS height) */
.cc-exp__drawer {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.cc-exp__inner { overflow: hidden; min-height: 0; padding: 0 18px; }
.cc-exp:hover .cc-exp__drawer,
.cc-exp:focus-visible .cc-exp__drawer,
.cc-exp.is-open .cc-exp__drawer { grid-template-rows: 1fr; }
.cc-exp:hover .cc-exp__inner,
.cc-exp:focus-visible .cc-exp__inner,
.cc-exp.is-open .cc-exp__inner { padding-bottom: 18px; }
.cc-exp:hover .cc-exp__chev,
.cc-exp:focus-visible .cc-exp__chev,
.cc-exp.is-open .cc-exp__chev { transform: rotate(180deg); }
.cc-exp__lbl {
  margin: 8px 0 8px;
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #9a9a9a;
}
.cc-exp__chips { display: flex; flex-wrap: wrap; gap: 7px; }
.cc-exp__chip {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--primary);
  padding: 5px 11px;
  border-radius: 999px;
  background: var(--white);
  border: 1px solid var(--line);
}
.cc-exp__posts { display: flex; gap: 8px; }
.cc-exp__post {
  flex: 1;
  aspect-ratio: 1 / 1;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--line);
}
.cc-exp__post img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ============================================================
   06 · COMPACT LIST-ROW — dense scannable directory rows
   ============================================================ */
.cc-rows { display: flex; flex-direction: column; gap: 10px; }
.cc-row {
  display: grid;
  grid-template-columns: 30px 46px minmax(0, 1fr) auto auto auto;
  align-items: center;
  gap: 16px;
  padding: 12px 18px;
  background: var(--white);
  border: 1px solid rgba(11, 11, 11, 0.05);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  transition: transform 0.14s ease, box-shadow 0.2s ease;
}
.cc-row:hover { transform: translateX(3px); box-shadow: var(--shadow-lift); }
.cc-row__rank {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 14px;
  color: #b9b9b9;
  text-align: center;
  font-variant-numeric: tabular-nums;
}
.cc-row__avatar { width: 46px; height: 46px; padding: 2px; }
.cc-row__avatar img { border-width: 2px; }
.cc-row__id { min-width: 0; display: flex; flex-direction: column; }
.cc-row__name { font-weight: 700; font-size: 15px; color: var(--primary); }
.cc-row__handle {
  font-size: 12.5px;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cc-row__stat { display: flex; flex-direction: column; text-align: right; }
.cc-row__stat b { font-weight: 700; font-size: 14px; color: var(--primary); font-variant-numeric: tabular-nums; }
.cc-row__stat i { font-style: normal; font-size: 11px; color: #9a9a9a; }
.cc-row__match {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  color: var(--text);
  white-space: nowrap;
}
.cc-row__match b {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 13px;
  color: #fff;
  background: #0b0b0b;
  padding: 4px 9px;
  border-radius: 999px;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 920px) {
  .cc-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .cc-row { grid-template-columns: 26px 42px minmax(0, 1fr) auto auto; }
  .cc-row__stat--hide { display: none; }
}
@media (max-width: 560px) {
  .cc-grid, .cc-grid--2 { grid-template-columns: 1fr; }
  .cc-row { grid-template-columns: 24px 40px minmax(0, 1fr) auto; }
  .cc-row__stat { display: none; }
}

/* ============================================================
   Reduced motion — freeze reveals; bars/rings show final state
   (JS already paints final values when reduced; this guards the CSS
   transitions so nothing animates).
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .cc-match, .cc-stats, .cc-glass, .cc-exp, .cc-row { transition: none !important; }
  .cc-match:hover, .cc-stats:hover, .cc-glass:hover, .cc-exp:hover, .cc-row:hover { transform: none; }
  .cc-stats__fill { transition: none !important; }
  .cc-exp__drawer { transition: none !important; }
  .cc-exp__chev { transition: none !important; }
  /* keep the expandable usable without hover motion: open via click/focus only */
  .cc-exp:hover .cc-exp__drawer { grid-template-rows: 0fr; }
  .cc-exp:hover .cc-exp__inner { padding-bottom: 0; }
  .cc-exp.is-open .cc-exp__drawer { grid-template-rows: 1fr; }
  .cc-exp.is-open .cc-exp__inner { padding-bottom: 18px; }
  .cc-glass { -webkit-backdrop-filter: none; backdrop-filter: none; }
}
