/* ════════════════════════════════════════
   teams.css — 팀 목록·상세·생성
════════════════════════════════════════ */
.page-teams {
  --tm-green: #087853;
  --tm-green-hover: #066044;
  --tm-green-dark: #064634;
  --tm-green-deep: #04231a;
  --tm-green-soft: #e7f3eb;
  --tm-green-line: #cfe1d6;
  --tm-mint: #8cf0bd;
  background: var(--color-background-tertiary); padding: 32px 24px 60px; min-height: 100vh;
}
[data-theme="dark"] .page-teams {
  --tm-green-soft: rgba(140, 240, 189, .10);
  --tm-green-line: rgba(140, 240, 189, .18);
}

.tm-wrap { max-width: 1040px; margin: 0 auto; display: flex; flex-direction: column; gap: 18px; }
.tm-wrap--narrow { max-width: 720px; }

/* [팀 목록 전용] 좌우 끝을 헤더(로고~테마버튼) 폭에 맞춰 정렬 */
.page-teams-list { padding-left: 0; padding-right: 0; }

/* [팀 만들기 전용] 뒤로가기 링크 제거로 상단 여백 축소 */
.page-teams-create { padding-top: 16px; }
.tm-wrap--full {
  max-width: 1440px;
  padding: 0 34px;
  box-sizing: border-box;
}
@media (max-width: 980px) { .tm-wrap--full { padding: 0 18px; } }
@media (max-width: 520px) { .tm-wrap--full { padding: 0 12px; } }

.tm-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.tm-title { font-size: 22px; font-weight: 800; color: var(--color-text-primary); margin: 0; display: flex; align-items: center; gap: 8px; }
.tm-title i { color: #087853; }
.tm-sub { font-size: 13px; color: var(--color-text-secondary); margin: 4px 0 0; }
.tm-back { font-size: 13px; color: var(--color-text-secondary); text-decoration: none; display: inline-flex; align-items: center; gap: 4px; }
.tm-back:hover { color: var(--color-text-primary); }

/* 버튼 */
.tm-btn-primary {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 9px 16px; border: none; border-radius: var(--border-radius-md);
  background: #087853; color: #fff; font-size: 13px; font-weight: 700;
  cursor: pointer; text-decoration: none; white-space: nowrap; transition: background .15s;
}
.tm-btn-primary:hover { background: #066044; }
.tm-btn-primary:disabled { opacity: .5; cursor: not-allowed; }
.tm-btn-ghost {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 8px 15px; border: 1px solid var(--color-border-tertiary);
  border-radius: var(--border-radius-md); background: var(--color-background-secondary);
  color: var(--color-text-secondary); font-size: 13px; font-weight: 600;
  cursor: pointer; text-decoration: none; white-space: nowrap;
}
.tm-btn-ghost:hover:not(:disabled) { color: var(--color-text-primary); border-color: var(--color-text-primary); }
.tm-btn-ghost:disabled { opacity: .55; cursor: default; }
.tm-btn-ok {
  padding: 6px 13px; border: none; border-radius: var(--border-radius-md);
  background: #087853; color: #fff; font-size: 12px; font-weight: 700; cursor: pointer;
}
.tm-btn-ok:hover { background: #066044; }

/* 검색 */
.tm-search { display: flex; gap: 8px; }
.tm-search input {
  flex: 1; padding: 10px 14px; border: 1px solid var(--color-border-tertiary);
  border-radius: var(--border-radius-md); background: var(--color-background-primary);
  color: var(--color-text-primary); font-size: 14px; outline: none;
}
.tm-search input:focus { border-color: #087853; }
.tm-search button {
  padding: 10px 16px; border: none; border-radius: var(--border-radius-md);
  background: var(--color-background-secondary); border: 1px solid var(--color-border-tertiary);
  color: var(--color-text-primary); font-size: 13px; font-weight: 600; cursor: pointer;
  display: inline-flex; align-items: center; gap: 5px;
}

/* 목록 그리드 */
.tm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; }
.tm-card {
  display: flex; gap: 12px; padding: 16px;
  background: var(--color-background-primary); border: 0.5px solid var(--color-border-tertiary);
  border-radius: var(--border-radius-lg); text-decoration: none; transition: border-color .15s, transform .08s;
}
.tm-card:hover { border-color: #087853; transform: translateY(-1px); }
/* 커미셔너용 액션 버튼이 붙는 카드(리그 참가 팀) — 링크 영역과 버튼을 분리 */
.tm-card--actionable { align-items: center; }
.tm-card-linkarea { display: flex; gap: 12px; flex: 1; min-width: 0; text-decoration: none; color: inherit; }
.tm-card-linkarea:hover { text-decoration: none; }
.tm-card-action { flex-shrink: 0; font-size: 12px; padding: 6px 12px; }
.tm-card-logo {
  width: 48px; height: 48px; flex-shrink: 0; border-radius: 12px; overflow: hidden;
  background: rgba(8,120,83,.10); color: #087853;
  display: flex; align-items: center; justify-content: center; font-size: 22px;
}
.tm-card-logo img { width: 100%; height: 100%; object-fit: cover; }
.tm-card-body { min-width: 0; }
.tm-card-name { font-size: 15px; font-weight: 700; color: var(--color-text-primary); }
.tm-card-short { font-size: 12px; color: var(--color-text-secondary); }
.tm-card-meta { font-size: 12px; color: var(--color-text-secondary); margin-top: 5px; display: flex; align-items: center; gap: 4px; }
.tm-card-leaders { display: flex; flex-wrap: wrap; gap: 4px 10px; margin-top: 6px; }
.tm-card-leaders span { font-size: 12px; color: var(--color-text-primary); display: inline-flex; align-items: center; gap: 4px; }
.tm-char-count { margin-top: 4px; text-align: right; font-size: 12px; color: var(--color-text-secondary); }

/* 리그 — 내 개설 요청 배너 */
.lg-myreq { margin: 14px 0; padding: 14px 16px; background: var(--color-background-primary); border: 1px solid var(--color-border-tertiary); border-radius: var(--border-radius-md); }
.lg-myreq-title { font-weight: 800; font-size: 14px; color: var(--color-text-primary); margin-bottom: 8px; display: flex; align-items: center; gap: 6px; }
.lg-myreq-row { display: flex; align-items: center; gap: 8px; padding: 4px 0; font-size: 13px; flex-wrap: wrap; }
.lg-myreq-name { font-weight: 700; color: var(--color-text-primary); }
.lg-myreq-note { color: var(--color-text-secondary); }
.lg-myreq-go { color: var(--color-text-info); font-weight: 700; text-decoration: none; }
.lg-st { font-size: 12px; font-weight: 800; padding: 2px 8px; border-radius: 999px; }
.lg-st-pending { color: var(--color-text-warning); background: var(--color-background-warning); }
.lg-st-ok { color: var(--color-text-success); background: var(--color-background-success); }
.lg-st-no { color: var(--color-text-danger); background: var(--color-background-danger); }
.lg-myreq-cancel {
  font-size: 12px; font-weight: 700; color: var(--color-text-secondary);
  background: none; border: 1px solid var(--color-border-tertiary); border-radius: 999px;
  padding: 2px 10px; cursor: pointer;
}
.lg-myreq-cancel:hover { color: var(--color-text-danger); border-color: var(--color-text-danger); }
.lg-myreq-cancel:disabled { opacity: .5; cursor: default; }
.lg-vote-scope {
  display: inline-block; font-weight: 700; color: #087853;
  background: rgba(8,120,83,.10); padding: 1px 8px; border-radius: 999px;
}
.tm-card-leaders i { color: var(--color-primary); }
.tm-card-desc { font-size: 12px; color: var(--color-text-secondary); margin: 6px 0 0; line-height: 1.4; }

/* 페이저 */
.tm-pager { display: flex; align-items: center; justify-content: center; gap: 14px; margin-top: 6px; }
.tm-page-btn { font-size: 13px; color: var(--color-text-secondary); text-decoration: none; padding: 6px 10px; border: 1px solid var(--color-border-tertiary); border-radius: var(--border-radius-md); }
.tm-page-btn:hover { color: var(--color-text-primary); }
.tm-page-now { font-size: 13px; color: var(--color-text-secondary); }

/* 빈 상태 */
.tm-empty { text-align: center; padding: 56px 20px; color: var(--color-text-secondary); display: flex; flex-direction: column; align-items: center; gap: 12px; }
.tm-empty[hidden] { display: none; }
.tm-empty i { font-size: 40px; opacity: .5; }
.tm-empty-sm { font-size: 13px; color: var(--color-text-secondary); text-align: center; padding: 16px; }

/* 카드(상세·폼 공용) */
.tm-card-title { font-size: 15px; font-weight: 700; color: var(--color-text-primary); margin: 0 0 12px; display: flex; align-items: center; gap: 8px; }
.tm-count { font-size: 12px; font-weight: 700; color: #087853; background: rgba(8,120,83,.10); padding: 1px 8px; border-radius: 999px; }
section.tm-card { background: var(--color-background-primary); border: 0.5px solid var(--color-border-tertiary); border-radius: var(--border-radius-lg); padding: 18px 20px; }
.tm-desc { font-size: 14px; color: var(--color-text-primary); line-height: 1.6; margin: 0; white-space: pre-wrap; }

/* 상세 헤더 */
.tm-detail-head { display: flex; align-items: center; gap: 16px; background: var(--color-background-primary); border: 0.5px solid var(--color-border-tertiary); border-radius: var(--border-radius-lg); padding: 20px; }
.tm-detail-logo { width: 64px; height: 64px; flex-shrink: 0; border-radius: 16px; overflow: hidden; background: rgba(8,120,83,.10); color: #087853; display: flex; align-items: center; justify-content: center; font-size: 30px; }
.tm-detail-logo img { width: 100%; height: 100%; object-fit: cover; }
.tm-detail-info { flex: 1; min-width: 0; }
.tm-detail-name { font-size: 20px; font-weight: 800; color: var(--color-text-primary); margin: 0; }
.tm-detail-short { font-size: 13px; color: var(--color-text-secondary); margin: 2px 0 0; }
.tm-detail-meta { font-size: 12px; color: var(--color-text-secondary); margin: 6px 0 0; display: flex; gap: 6px; align-items: center; }
.tm-detail-action { flex-shrink: 0; }

.tm-badge { font-size: 12px; font-weight: 700; padding: 5px 12px; border-radius: 999px; }
.tm-badge-owner { background: rgba(8,120,83,.12); color: #087853; }

/* 로스터 / 신청 */
.tm-roster, .tm-req-list { display: flex; flex-direction: column; gap: 2px; }
.tm-roster-row, .tm-req-row { display: flex; align-items: center; gap: 11px; padding: 9px 4px; border-bottom: 1px solid var(--color-border-tertiary); }
.tm-roster-row:last-child, .tm-req-row:last-child { border-bottom: none; }
.tm-avatar { width: 34px; height: 34px; flex-shrink: 0; border-radius: 50%; overflow: hidden; background: var(--color-avatar-bg); color: var(--color-avatar-text); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 700; }
.tm-avatar img { width: 100%; height: 100%; object-fit: cover; }
.tm-roster-name, .tm-req-name { flex: 1; min-width: 0; font-size: 14px; font-weight: 600; color: var(--color-text-primary); }
.tm-roster-name small, .tm-req-name small { font-weight: 400; color: var(--color-text-secondary); margin-left: 5px; }
.tm-req-actions { display: flex; gap: 6px; flex-shrink: 0; }
.tm-role { font-size: 11px; font-weight: 700; padding: 2px 9px; border-radius: 999px; flex-shrink: 0; background: var(--color-background-secondary); color: var(--color-text-secondary); }
.tm-role-owner { background: rgba(8,120,83,.12); color: #087853; }
.tm-role-admin, .tm-role-staff { background: var(--color-background-info); color: var(--color-text-info); }

/* 폼 */
.tm-form { display: flex; flex-direction: column; gap: 14px; }
.tm-form-note { font-size: 13px; color: var(--color-text-secondary); margin: 0 0 14px; }
.tm-field { display: flex; flex-direction: column; gap: 6px; }
.tm-label { font-size: 13px; font-weight: 600; color: var(--color-text-primary); }
.tm-label .req { color: var(--color-text-danger); }
.tm-input { width: 100%; padding: 10px 13px; border: 1px solid var(--color-border-tertiary); border-radius: var(--border-radius-md); background: var(--color-background-secondary); color: var(--color-text-primary); font-size: 14px; outline: none; box-sizing: border-box; }
.tm-input:focus { border-color: #087853; background: var(--color-background-primary); }
.tm-textarea { resize: vertical; min-height: 100px; }
.tm-result { font-size: 13px; margin: 0; min-height: 16px; }
.tm-result.err { color: var(--color-text-danger); }
.tm-form-actions { display: flex; gap: 10px; align-items: center; }

@media (max-width: 600px) {
  .tm-detail-head { flex-direction: column; text-align: center; }
  .tm-detail-action { width: 100%; }
}


/* ── 팀 생성: 로고 업로드 / 활동 지역 ─────────────────────── */
.is-hidden { display: none !important; }
.tm-logo-row { display: flex; align-items: center; gap: 16px; }
.tm-logo-preview { position: relative; width: 88px; height: 88px; flex-shrink: 0;
  border-radius: 50%; overflow: hidden; background: var(--color-background-secondary, #f1f3f5);
  border: 1px solid var(--color-border, #e3e3e3);
  display: flex; align-items: center; justify-content: center; }
.tm-logo-img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tm-logo-ph { font-size: 34px; color: var(--color-text-secondary, #9aa0a6); line-height: 0; }
.tm-logo-actions { display: flex; flex-direction: column; gap: 6px; }
.tm-logo-hint { margin: 0; font-size: 12px; color: var(--color-text-secondary, #888); }
.tm-field--row { display: flex; gap: 12px; }
.tm-field--row .tm-col { flex: 1; min-width: 0; }

/* ── 생성 폼: 단계형(stepper) ─────────────────────────────── */
/* 생성 페이지 카드는 세로 정렬 (목록 .tm-card 의 flex-row 상속 방지) */
.tm-wrap--narrow .tm-card { display: block; }

.tm-stepper { display: flex; align-items: flex-start; margin: 4px 0 26px; }
.tm-step { display: flex; flex-direction: column; align-items: center; gap: 7px; flex-shrink: 0; }
.tm-step-circle {
  width: 34px; height: 34px; border-radius: 50%;
  border: 2px solid var(--color-border-tertiary);
  background: transparent; color: var(--color-text-secondary);
  font-size: 14px; font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  transition: all .35s;
}
.tm-step-circle .ti { font-size: 16px; }
.tm-step-label { font-size: 11px; color: var(--color-text-secondary); white-space: nowrap; font-weight: 500; transition: color .35s; }
.tm-step.active .tm-step-circle,
.tm-step.done .tm-step-circle { border-color: #087853; background: #087853; color: #fff; }
.tm-step.active .tm-step-label { color: #087853; font-weight: 700; }
.tm-step.done .tm-step-label { color: #087853; font-weight: 600; }
.tm-step-connector { flex: 1; height: 2px; background: var(--color-border-tertiary); margin: 17px 6px 0; align-self: flex-start; transition: background .35s; }
.tm-step-connector.done { background: #087853; }

.tm-panel { display: flex; flex-direction: column; gap: 14px; }
.tm-panel[hidden] { display: none; }
.tm-panel-title { font-size: 15px; font-weight: 700; color: var(--color-text-primary); margin: 0; }
.tm-panel-desc { font-size: 13px; color: var(--color-text-secondary); margin: -6px 0 4px; line-height: 1.6; }

/* 단계 이동 버튼 */
.tm-step-nav { display: flex; gap: 10px; align-items: center; margin-top: 6px; }
.tm-step-nav .tm-spacer { flex: 1; }

/* 확인 단계 요약 */
.tm-review { display: flex; flex-direction: column; gap: 0; border: 1px solid var(--color-border-tertiary);
  border-radius: var(--border-radius-md); background: var(--color-background-secondary); overflow: hidden; }
.tm-review-row { display: flex; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--color-border-tertiary); }
.tm-review-row:last-child { border-bottom: none; }
.tm-review-key { flex-shrink: 0; width: 96px; font-size: 13px; font-weight: 600; color: var(--color-text-secondary); }
.tm-review-val { flex: 1; min-width: 0; font-size: 13px; color: var(--color-text-primary); word-break: break-word; white-space: pre-wrap; }
.tm-review-logo { width: 56px; height: 56px; border-radius: 50%; overflow: hidden; flex-shrink: 0;
  background: var(--color-background-primary); border: 1px solid var(--color-border-tertiary);
  display: flex; align-items: center; justify-content: center; }
.tm-review-logo img { width: 100%; height: 100%; object-fit: cover; }

@media (max-width: 600px) {
  .tm-step-label { display: none; }
  .tm-field--row { flex-direction: column; }
}


/* ════════════════════════════════════════
   팀 목록(list.html) 전용 — 히어로 다이아몬드 필드 · 검색/필터 탭 · 카드 그리드
════════════════════════════════════════ */

/* ── 히어로 배너 ── */
.tm-hero {
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: 1.1fr .55fr auto; align-items: end; gap: 28px;
  min-height: 176px; padding: 28px 32px;
  border: 1px solid var(--color-border-tertiary); border-top: 3px solid var(--tm-green);
  background: var(--color-background-primary);
  box-shadow: 0 12px 28px rgba(6,70,52,.08);
}
.tm-hero-eyebrow { margin: 0; color: var(--tm-green); font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.tm-hero h1 { margin: 8px 0 0; font-size: 30px; line-height: 1.18; letter-spacing: -.03em; color: var(--color-text-primary); }
.tm-hero h1 span { color: var(--tm-green); }
.tm-hero-desc { max-width: 420px; margin: 10px 0 0; color: var(--color-text-secondary); font-size: 13px; line-height: 1.7; }

.tm-hero-diamond-wrap { position: relative; align-self: stretch; min-height: 122px; border-left: 1px solid var(--color-border-tertiary); }
.tm-diamond-field {
  position: absolute; inset: 8px 0 8px 32px;
  background: linear-gradient(130deg, var(--tm-green-dark), var(--tm-green));
  clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%);
  box-shadow: 0 12px 22px rgba(8,120,83,.22);
}
.tm-diamond-field::before, .tm-diamond-field::after {
  content: ""; position: absolute; inset: 22%; border: 1px solid rgba(255,255,255,.48); transform: rotate(45deg);
}
.tm-diamond-field::after { inset: 42%; background: var(--tm-green-soft); border: 0; }
.tm-diamond-field i { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: #fff; box-shadow: 0 0 0 4px rgba(255,255,255,.16); }
.tm-diamond-field i:nth-child(1) { top: 17%; left: 47%; }
.tm-diamond-field i:nth-child(2) { right: 17%; top: 47%; }
.tm-diamond-field i:nth-child(3) { bottom: 17%; left: 47%; }
.tm-diamond-field i:nth-child(4) { left: 17%; top: 47%; }

.tm-field-summary {
  position: absolute; right: 0; bottom: 0; padding: 9px 12px;
  border: 1px solid var(--tm-green-line); background: var(--color-background-primary);
  box-shadow: 0 8px 17px rgba(17,70,46,.10);
}
.tm-field-summary span { display: block; color: var(--color-text-secondary); font-size: 8px; font-weight: 800; letter-spacing: .12em; }
.tm-field-summary strong { display: block; margin-top: 3px; color: var(--tm-green); font-size: 25px; line-height: .8; font-weight: 800; }
.tm-field-summary p { margin: 5px 0 0; color: var(--color-text-secondary); font-size: 7px; font-weight: 800; letter-spacing: .08em; }

.tm-hero-create {
  align-self: start; display: inline-flex; align-items: center; gap: 8px;
  padding: 11px 16px; border: 0; background: var(--tm-green);
  box-shadow: 0 9px 17px rgba(8,120,83,.20); color: #fff; font-size: 12px; font-weight: 800;
  cursor: pointer; text-decoration: none; white-space: nowrap;
}
.tm-hero-create:hover { background: var(--tm-green-hover); }
.tm-hero-create:active { transform: scale(.98); }
.tm-hero-create i { display: grid; place-items: center; width: 16px; height: 16px; border: 1px solid rgba(255,255,255,.6); font-size: 15px; font-style: normal; line-height: 1; }

@media (max-width: 900px) {
  .tm-hero { grid-template-columns: 1fr auto; }
  .tm-hero-diamond-wrap { display: none; }
}
@media (max-width: 600px) {
  .tm-hero { display: flex; flex-direction: column; align-items: stretch; min-height: 0; padding: 22px 20px; gap: 16px; }
  .tm-hero h1 { font-size: 24px; }
  .tm-hero-create { align-self: stretch; justify-content: center; }
}

/* ── 검색 + 필터 탭 ── */
.tm-controls { display: flex; align-items: center; gap: 12px; margin-top: 4px; }
.tm-search-box {
  display: flex; align-items: center; flex: 1; gap: 9px; padding: 0 14px;
  border: 1px solid var(--color-border-tertiary); background: var(--color-background-primary); color: var(--color-text-secondary);
}
.tm-search-box i { font-size: 18px; }
.tm-search-box input { width: 100%; height: 44px; border: 0; background: transparent; color: var(--color-text-primary); font-size: 13px; outline: 0; }
.tm-search-box input::placeholder { color: var(--color-text-secondary); }
.tm-search-clear { display: none; border: 0; background: transparent; color: var(--color-text-secondary); font-size: 17px; cursor: pointer; }
.tm-search-box.has-value .tm-search-clear { display: block; }

.tm-filter-tabs { display: flex; gap: 6px; flex-shrink: 0; }
.tm-filter-tab {
  display: flex; align-items: center; gap: 6px; height: 44px; padding: 0 13px;
  border: 1px solid var(--color-border-tertiary); background: var(--color-background-primary);
  color: var(--color-text-secondary); font-size: 11px; font-weight: 800; cursor: pointer; white-space: nowrap;
}
.tm-filter-tab b { display: grid; place-items: center; min-width: 17px; height: 17px; border-radius: 50%; background: var(--color-background-secondary); color: var(--color-text-secondary); font-size: 9px; font-weight: 800; }
.tm-filter-tab.active { border-color: var(--tm-green); background: var(--tm-green); color: #fff; }
.tm-filter-tab.active b { background: rgba(255,255,255,.18); color: #fff; }

@media (max-width: 600px) {
  .tm-controls { align-items: stretch; flex-direction: column; }
  .tm-filter-tabs { overflow-x: auto; }
  .tm-filter-tab { flex: 1; justify-content: center; min-width: max-content; }
}

/* ── 목록 섹션 헤더 ── */
.tm-list-head { display: flex; align-items: end; justify-content: space-between; margin-top: 30px; }
.tm-list-head h2 { margin: 5px 0 0; font-size: 21px; letter-spacing: -.03em; color: var(--color-text-primary); }
.tm-list-head p { margin: 0; color: var(--color-text-secondary); font-size: 11px; }
.tm-directory-section { margin-top: 32px; }
.tm-directory-section .tm-list-head { margin-top: 0; }
.tm-directory-section--internal {
  margin-top: 38px; padding: 22px;
  border: 1px solid rgba(10, 125, 89, .2); border-top: 3px solid var(--tm-green);
  background:
    linear-gradient(135deg, rgba(10, 125, 89, .07), transparent 42%),
    var(--color-background-primary);
  box-shadow: 0 12px 34px rgba(25, 62, 43, .05);
}
.tm-directory-section--internal .tm-list-card { border-top-color: var(--tm-green); }
[data-theme="dark"] .tm-directory-section--internal {
  border-color: rgba(94, 205, 157, .26);
  background: linear-gradient(135deg, rgba(39, 153, 112, .14), transparent 46%), var(--color-background-primary);
}

/* ── 팀 카드 그리드(간단 정보형) ── */
.tm-list-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; margin-top: 14px; }
.tm-list-card {
  position: relative; overflow: hidden; display: block;
  border: 1px solid var(--color-border-tertiary); border-top: 3px solid #c5d8cb;
  background: var(--color-background-primary); text-decoration: none;
  box-shadow: 0 8px 22px rgba(25,62,43,.045);
  transition: transform .2s ease, box-shadow .2s ease;
}
.tm-list-card:hover { z-index: 1; transform: translateY(-4px); box-shadow: 0 16px 32px rgba(13,76,49,.13); }
/* 커미셔너용 액션 버튼이 붙는 카드(리그 참가 팀) — 카드 자체는 div, 링크 영역만 a로 분리 */
.tm-list-card-linkarea { display: block; text-decoration: none; color: inherit; }
.tm-list-card-action {
  display: block; width: calc(100% - 36px); margin: 10px 18px 16px; padding: 7px 0;
  border: 1px solid var(--color-border-tertiary); border-radius: var(--border-radius-md);
  background: var(--color-background-secondary); color: var(--color-text-secondary);
  font-size: 12px; font-weight: 700; cursor: pointer; text-align: center; transition: background .15s, color .15s;
}
.tm-list-card-action:hover { background: var(--color-background-danger); color: var(--color-text-danger); border-color: transparent; }
.tm-list-card.is-mine { border-top-color: var(--tm-green); }
.tm-list-card[hidden] { display: none; }

.tm-list-card-head { display: flex; align-items: center; gap: 12px; padding: 18px 18px 14px; border-bottom: 1px solid var(--color-border-tertiary); }
.tm-list-card-head h3 { margin: 0; color: var(--color-text-primary); font-size: 17px; font-weight: 800; letter-spacing: -.03em; }
.tm-my-tag {
  display: inline-flex; align-items: center; justify-content: center;
  margin-left: 4px; padding: 2px 6px;
  background: var(--tm-green); color: #fff;
  font-size: 9px; font-weight: 800; letter-spacing: .04em;
  vertical-align: middle;
}
.tm-list-badge { display: grid; place-items: center; width: 40px; height: 40px; flex-shrink: 0; border-radius: 50%; overflow: hidden; font-size: 15px; font-weight: 800; }
.tm-list-badge img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tm-list-badge-1 { background: #d9ebbe; color: #1b613c; }
.tm-list-badge-2 { background: #d8e9ff; color: #1262aa; }
.tm-list-badge-3 { background: #d8f1e4; color: #168354; }
.tm-list-badge-4 { background: #ffd5cc; color: #aa402a; }
.tm-list-badge-5 { background: #ede0ff; color: #7540ad; }
.tm-list-badge-6 { background: #fde8c4; color: #a16a10; }
[data-theme="dark"] .tm-list-badge-1 { background: rgba(217,235,190,.18); color: #b6e08a; }
[data-theme="dark"] .tm-list-badge-2 { background: rgba(216,233,255,.18); color: #7fb8ff; }
[data-theme="dark"] .tm-list-badge-3 { background: rgba(216,241,228,.18); color: #6fdfb0; }
[data-theme="dark"] .tm-list-badge-4 { background: rgba(255,213,204,.18); color: #ff9d84; }
[data-theme="dark"] .tm-list-badge-5 { background: rgba(237,224,255,.18); color: #c6a4ff; }
[data-theme="dark"] .tm-list-badge-6 { background: rgba(253,232,196,.18); color: #f0be6b; }

.tm-list-info { display: grid; grid-template-columns: 1fr 1fr; gap: 0; margin: 0; padding: 0 18px; }
.tm-list-info > div { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 0; border-top: 1px solid var(--color-border-tertiary); }
.tm-list-info > div:nth-child(-n+2) { border-top: 0; }
.tm-list-info > div:nth-child(odd) { padding-right: 12px; border-right: 1px solid var(--color-border-tertiary); }
.tm-list-info > div:nth-child(even) { padding-left: 12px; }
.tm-list-info dt { color: var(--color-text-secondary); font-size: 10px; font-weight: 700; }
.tm-list-info dd { margin: 0; color: var(--color-text-primary); font-size: 12px; font-weight: 800; letter-spacing: -.02em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

@media (max-width: 900px) { .tm-list-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) {
  .tm-list-head { margin-top: 26px; }
  .tm-directory-section { margin-top: 26px; }
  .tm-directory-section--internal { margin-top: 30px; padding: 16px; }
  .tm-list-grid { grid-template-columns: 1fr; gap: 12px; }
  .tm-list-card-head { padding: 16px; }
  .tm-list-info { padding: 0 16px; }
  .tm-list-info > div { padding: 11px 0; }
}


/* ════════════════════════════════════════
   팀 만들기(create.html) 전용 — 히어로 배너 · 단계 캡션 · 로고 필드 · 안내 카드 · 확인 보드
   (로고 미리보기/확인 배지는 요청에 따라 다이아몬드가 아닌 기존 원형 유지)
════════════════════════════════════════ */

.tm-create-hero {
  position: relative; overflow: hidden; isolation: isolate;
  display: flex; align-items: end; justify-content: space-between; gap: 28px;
  min-height: 168px; margin-top: 2px; padding: 26px 30px;
  background: linear-gradient(118deg, var(--tm-green-deep), var(--tm-green) 67%, #0b9b6e);
  color: #fff; box-shadow: 0 16px 34px rgba(7,70,50,.17);
}
.tm-create-hero::after {
  content: ""; position: absolute; right: 0; bottom: 0; width: 47%; height: 100%;
  background:
    radial-gradient(circle at 68% 20%, rgba(255,255,255,.18), transparent 2px),
    radial-gradient(circle at 30% 80%, rgba(255,255,255,.14), transparent 2px);
  background-size: 22px 22px; opacity: .5;
}
.tm-create-hero > div:first-child { position: relative; z-index: 1; }
.tm-create-hero-eyebrow { margin: 0; color: #b1e7c7; font-size: 10px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.tm-create-hero h1 { margin: 7px 0 0; font-size: 28px; line-height: 1.2; letter-spacing: -.02em; }
.tm-create-hero h1 span { color: var(--tm-mint); }
.tm-create-hero-desc { max-width: 440px; margin: 9px 0 0; color: #d0eadc; font-size: 12px; line-height: 1.7; }

.tm-create-diamond {
  position: relative; z-index: 1; flex-shrink: 0;
  width: 122px; height: 122px; transform: rotate(45deg);
  border: 1px solid rgba(255,255,255,.52); box-shadow: 0 0 0 16px rgba(255,255,255,.07);
}
.tm-create-diamond::before { content: ""; position: absolute; inset: 24px; border: 1px solid rgba(255,255,255,.45); }
.tm-create-diamond i { position: absolute; width: 8px; height: 8px; border-radius: 50%; background: #e9fff2; box-shadow: 0 0 0 4px rgba(233,255,242,.14); }
.tm-create-diamond i:nth-child(1) { top: -4px; left: 50%; }
.tm-create-diamond i:nth-child(2) { top: 50%; right: -4px; }
.tm-create-diamond i:nth-child(3) { bottom: -4px; left: 50%; }
.tm-create-diamond i:nth-child(4) { top: 50%; left: -4px; }
.tm-create-diamond b { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%) rotate(-45deg); color: #fff; font-size: 32px; font-weight: 800; letter-spacing: -.04em; }

@media (max-width: 700px) {
  .tm-create-hero { align-items: flex-start; min-height: 0; padding: 22px 20px; }
  .tm-create-hero h1 { font-size: 24px; }
  .tm-create-diamond { display: none; }
}

/* ── 스테퍼: STEP 0N 캡션(기존 라벨 위, 라벨과 별개 요소라 league 재사용 스테퍼엔 영향 없음) ── */
.tm-step-caption-mini { display: block; font-size: 8px; font-weight: 800; letter-spacing: .1em; color: var(--color-text-secondary); }
.tm-step.active .tm-step-caption-mini, .tm-step.done .tm-step-caption-mini { color: var(--tm-green); }

/* ── 단계 헤더(번호+제목+설명) ── */
.tm-panel-header { display: flex; align-items: flex-start; gap: 11px; margin-bottom: 4px; }
.tm-panel-marker { display: grid; place-items: center; width: 25px; height: 25px; flex-shrink: 0; background: var(--tm-green-soft); color: var(--tm-green); font-size: 10px; font-weight: 800; }
.tm-panel-header h2 { margin: 0; font-size: 19px; letter-spacing: -.03em; color: var(--color-text-primary); }
.tm-panel-header p { margin: 6px 0 0; color: var(--color-text-secondary); font-size: 12px; }
.tm-disabled-contact {
  display: flex; align-items: center; gap: 10px; padding: 11px 13px;
  background: var(--tm-green-soft); border: 1px solid var(--tm-green-line);
  border-radius: var(--border-radius-md); color: var(--tm-green);
}
.tm-disabled-contact > i { flex-shrink: 0; font-size: 19px; }
.tm-disabled-contact div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.tm-disabled-contact small { color: var(--color-text-secondary); font-size: 11px; }
.tm-disabled-contact a { color: var(--tm-green-dark); font-size: 13px; font-weight: 700; overflow-wrap: anywhere; }
.tm-disabled-contact a:hover { color: var(--tm-green-hover); }

/* ── 로고 등록 필드(원형 유지) ── */
.tm-logo-field { display: flex; align-items: center; gap: 15px; padding: 14px; border: 1px solid var(--color-border-tertiary); background: var(--color-background-secondary); }
.tm-logo-actions { display: flex; flex-direction: column; gap: 8px; }
.tm-upload-btn {
  display: inline-flex; align-items: center; align-self: flex-start; gap: 8px;
  padding: 8px 10px; border: 1px solid var(--tm-green-line); background: var(--color-background-primary);
  color: var(--tm-green); font-size: 11px; font-weight: 800; cursor: pointer;
}
.tm-upload-btn:hover { background: var(--tm-green-soft); }
.tm-upload-btn i { font-size: 15px; }
.tm-logo-hint { margin: 0; color: var(--color-text-secondary); font-size: 10px; }

@media (max-width: 700px) { .tm-logo-field { align-items: flex-start; flex-direction: column; } }

/* ── 안내 카드(구단주 권한 / 팀 소개 팁) ── */
.tm-note { display: flex; gap: 10px; margin-top: 16px; padding: 12px 14px; border-left: 3px solid var(--tm-green); background: var(--tm-green-soft); color: var(--color-text-secondary); }
.tm-note span { display: grid; place-items: center; width: 22px; height: 22px; flex-shrink: 0; background: var(--color-background-primary); color: var(--tm-green); font-size: 13px; }
.tm-note p { margin: 0; font-size: 11px; line-height: 1.65; }
.tm-note b { color: var(--color-text-primary); }

.tm-step-caption { color: var(--color-text-secondary); font-size: 10px; font-weight: 800; letter-spacing: .1em; white-space: nowrap; }

/* ── 확인 단계 보드(팀 생성 전용, 원형 배지) ── */
.tm-confirm-board { border: 1px solid var(--color-border-tertiary); background: var(--color-background-secondary); }
.tm-confirm-top { display: flex; align-items: center; gap: 12px; padding: 16px 17px; border-bottom: 1px solid var(--color-border-tertiary); }
.tm-confirm-badge {
  display: grid; place-items: center; width: 48px; height: 48px; flex-shrink: 0; overflow: hidden;
  border-radius: 50%; background: var(--tm-green); color: #fff; font-size: 15px; font-weight: 800;
}
.tm-confirm-badge img { width: 100%; height: 100%; object-fit: cover; display: block; }
.tm-confirm-top p { margin: 0; color: var(--color-text-secondary); font-size: 8px; font-weight: 800; letter-spacing: .1em; }
.tm-confirm-top h3 { margin: 4px 0 0; color: var(--color-text-primary); font-size: 17px; letter-spacing: -.02em; }
.tm-confirm-info { display: grid; grid-template-columns: 1fr 1fr; margin: 0; padding: 0 17px; }
.tm-confirm-info > div { display: flex; justify-content: space-between; gap: 13px; padding: 13px 0; border-top: 1px solid var(--color-border-tertiary); }
.tm-confirm-info > div:nth-child(-n+2) { border-top: 0; }
.tm-confirm-info > div:nth-child(odd) { padding-right: 14px; border-right: 1px solid var(--color-border-tertiary); }
.tm-confirm-info > div:nth-child(even) { padding-left: 14px; }
.tm-confirm-info .full { grid-column: 1/-1; display: block; padding-left: 0; border-right: 0; }
.tm-confirm-info dt { color: var(--color-text-secondary); font-size: 10px; font-weight: 700; }
.tm-confirm-info dd { margin: 0; color: var(--color-text-primary); font-size: 12px; font-weight: 800; text-align: right; }
.tm-confirm-info .full dd { margin-top: 6px; color: var(--color-text-secondary); font-size: 11px; font-weight: 500; line-height: 1.6; text-align: left; }

@media (max-width: 600px) {
  .tm-confirm-info { grid-template-columns: 1fr; padding: 0 14px; }
  .tm-confirm-info > div, .tm-confirm-info > div:nth-child(-n+2), .tm-confirm-info > div:nth-child(odd), .tm-confirm-info > div:nth-child(even) { padding: 11px 0; border-top: 1px solid var(--color-border-tertiary); border-right: 0; }
  .tm-confirm-info > div:first-child { border-top: 0; }
  .tm-confirm-info .full { grid-column: auto; }
}
