/* ═════════════════════════════════════════════
   팀 사이트 공통 스타일 — 새 디자인 "경기장 안내판" (2026-10-31)
   사이트 전체가 우리 팀 홈구장의 안내판이에요: 칸 · 페이지 이름은 표지판, 다음 경기는 티켓,
   화면마다 가장 중요한 숫자 하나는 번호판. (설계: docs/superpowers/specs/2026-10-31-team-site-redesign-design.md)

   쓰는 곳: 새 디자인으로 바꾼 팀 페이지 (<head>에 css/site.css + css/pages/<페이지>.css)
   ⚠️ 소개 · 로그인 · 팀 선택 · 관리자 페이지와 아직 안 바꾼 페이지는 css/common.css를 그대로 써요 (이 파일과 따로).

   이 파일의 차례
     1. 글꼴 · 기본         2. 디자인 값 (색 · 글자 · 간격 · 모서리)      3. 바탕
     4. 글꼴 역할 (사이트 전체)                                           5. 페이지 틀 · 페이지 이동
     ── (다음 부분들이 이 사이에 들어와요: 위쪽 메뉴 · 부품 · 알림 창 · 팝업 · 안내) ──
     맨 끝. 작은 화면 (1199 · 1023 · 640)
   겉모습(메뉴 띠 · 홈 칸)은 css/skins/clean/site.css · home.css에 있어요.
   ═════════════════════════════════════════════ */

/* ═══ 1. 글꼴 · 기본 ═══ */
/* 글꼴 파일은 우리 서버(web/fonts)에 있어요 (모두 무료 · 상업적 이용 가능, SIL OFL) */
@import url("../fonts/fonts.css");

/* hidden 속성이 붙은 요소는 어떤 CSS가 있어도 무조건 숨기기 */
[hidden] {
  display: none !important;
}
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* ═══ 2. 디자인 값 ═══
   색 · 글자 · 간격 · 모서리는 여기 이름만 써요 (페이지 CSS에서 숫자를 따로 정하지 않기).
   팀 색은 common.js의 applyTeamColor가 <html>에 넣어요:
     --team(팀 상징색 그대로) · --team-rgb · --team-ink(팀 색 위 글자: 흰색 또는 검정)
     --team-strong(글자를 올리는 팀 색 판: 메뉴 띠 · 티켓 · 주 버튼) · --team-text-light / --team-text-dark(판 위에 팀 색으로 쓰는 글자)
   아직 팀을 모를 때는 PL 보라색이에요. */
:root {
  --pl: #3D195B;
  --team: var(--pl);
  --team-rgb: 61, 25, 91;
  --team-ink: #ffffff;
  --team-strong: var(--pl);
  --team-text-light: var(--pl);
  --team-text-dark: #9481a5;
  --team-text: var(--team-text-light);
  --team-soft: color-mix(in srgb, var(--team) 10%, var(--panel));   /* 우리 팀 줄 바탕 */

  /* 색 (라이트) */
  --ground: #ECEEF1;        /* 페이지 바탕: 콘크리트 같은 연회색 */
  --page-bg: var(--ground); /* 페이지 이동 뼈대가 바탕 밝기를 읽는 이름 (common.js의 pageBackgroundLightness) */
  --panel: #FFFFFF;         /* 판(칸) */
  --panel-2: #F4F5F7;       /* 판 안의 조용한 칸 · 태그 바탕 */
  --panel-3: #E6E8EC;       /* 조용한 칸에 마우스를 올렸을 때 · 눌렀을 때 */
  --avatar-bg: #E3E6EA;     /* 프로필 그림 동그라미 바탕 (인스타그램 · X 기본 프로필처럼, 2026-11-14) */
  --avatar-fig: #AEB4BD;    /* 프로필 그림 실루엣 (머리 + 어깨) */
  --ink: #111214;           /* 글자 · 표지판 */
  --ink-2: #3C3F45;         /* 덜 중요한 글자 */
  --muted: #5D6068;         /* 흐린 글자 (흰 판 6.4:1 · 바탕 5.5:1) */
  --line: #E1E4E8;          /* 줄 사이 얇은 선 (장식) */
  --line-ctl: #8A8F98;      /* 입력칸 · 보통 버튼 테두리 (바탕과 3:1 이상) */
  --rule: #111214;          /* 목록 맨 위 2px 선 (시간표처럼) */
  --sign: #111214;          /* 표지판 판 */
  --sign-ink: #FFFFFF;      /* 표지판 글자 */
  --win: #15803D;           /* 승 · 무 · 패 (흰 글자 4.5:1 이상) */
  --draw: #5D6068;
  --loss: #C81E1E;
  --live: #DC2626;          /* 경기 중 */
  --ok: #15803D;            /* 저장 완료 · 주의 · 오류 글자 */
  --warn: #B45309;
  --danger: #C81E1E;
  /* 평점 단계 색 (경기장 평점 배지 · 선수 페이지 '이번 경기', 다크 모드도 같아요 — 꽉 찬 알약이라 바탕과 상관없이 읽혀요)
     -ink = 그 위 글자색 (4.5:1 이상) */
  --rating-top: #0E7A3F;   --rating-top-ink: #FFFFFF;    /* 8 이상 */
  --rating-good: #4CC07A;  --rating-good-ink: #0B1F12;   /* 7 ~ 7.9 */
  --rating-ok: #F2C230;    --rating-ok-ink: #2A2000;     /* 6.5 ~ 6.9 */
  --rating-low: #F08A2E;   --rating-low-ink: #2A1400;    /* 6 ~ 6.4 */
  --rating-poor: #D0342C;  --rating-poor-ink: #FFFFFF;   /* 6 아래 */
  --shadow-lift: 0 1px 2px rgba(17, 18, 20, 0.04), 0 12px 28px -16px rgba(17, 18, 20, 0.24);   /* 떠오를 때만 */

  /* 글꼴 역할 4가지 (영어 화면은 아래 html[lang="en"]에서 바꿔요)
     --font: 내용 글 · --font-ui: 메뉴 · 버튼 · --font-title: 큰 제목 · 팀 이름 · 번호판 숫자 · --font-article: 기사 제목 */
  --font: "Pretendard Variable", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  --font-ui: "SUIT Variable", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  --font-title: var(--font);
  --font-article: "IBM Plex Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", system-ui, sans-serif;
  --font-num: var(--font-title);
  --num-weight: 900;        /* 번호판 숫자 굵기 (영어 글꼴 Inter는 800) */

  /* 페이지 틀: 모든 페이지가 이 숫자 한 벌만 써요 (내용 양 끝 = 메뉴의 '파코어' 왼쪽 · 마지막 버튼 오른쪽)
     좁은 화면에서 바뀌는 값은 맨 아래 "작은 화면" 부분에 */
  --page-max: 1240px;       /* 내용 폭 */
  --page-gutter: 32px;      /* 화면 양옆 여백 */
  --page-top: 24px;         /* 메뉴 아래 ~ 첫 칸 */
  --page-bottom: 48px;      /* 맨 아래 여백 */
  --panel-gap: 20px;        /* 판끼리 */
  --head-gap: var(--panel-gap);   /* 페이지 이름 ~ 첫 칸: 한 화면 페이지가 판 간격을 줄여도 이 값은 그대로 → 첫 칸 시작 위치가 모든 페이지에서 같아요 */
  --panel-pad: 20px;        /* 판 안쪽 여백 */
  --card-gap: 12px;         /* 판 안의 칸끼리 */

  /* 모서리 규칙 하나: 큰 판 8 · 판 안 칸 6 · 버튼 · 입력칸 · 태그 · 표지판 4 (휴대폰에서 아래에서 올라오는 판만 위 모서리 12) */
  --radius-panel: 8px;
  --radius-card: 6px;
  --radius-ctl: 4px;
  --radius-sheet: 12px;

  /* 메뉴 높이: 띠 + (아이패드 세로만) 메뉴 줄 / 휴대폰은 아래 탭 막대 */
  --band-h: 64px;
  --row-h: 0px;
  --menu-h: calc(var(--band-h) + var(--row-h));
  --tabbar-h: 0px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);   /* 부드럽게 멈추는 움직임 */
}

html[data-theme="dark"] {
  --team-text: var(--team-text-dark);
  --ground: #0E1013;        /* 아스팔트색 바탕 */
  --panel: #17191D;         /* (teams.js의 TEAM_COLOR_DARK_PANEL과 같은 색) */
  --panel-2: #1E2025;
  --panel-3: #272A30;
  --avatar-bg: #2B2E34;
  --avatar-fig: #6E747E;    /* 검은 안경 · 갈색 콧수염도 보이게 한 단계 밝게 */
  --ink: #F1F2F4;
  --ink-2: #C9CCD2;
  --muted: #9499A3;
  --line: #2A2D33;
  --line-ctl: #6B7079;
  --rule: #F1F2F4;
  --sign: #F1F2F4;          /* 다크 모드 표지판은 흰 판 + 검은 글자로 뒤집혀요 */
  --sign-ink: #111214;
  --ok: #4ADE80;
  --warn: #FBBF24;
  --danger: #F87171;
  --shadow-lift: 0 1px 2px rgba(0, 0, 0, 0.4), 0 12px 28px -16px rgba(0, 0, 0, 0.7);
}

/* 영어 화면: 영어 글꼴 뒤에 한국어 글꼴을 이어 둬요 (영어 화면에 한글이 섞여 나와도 같은 역할의 한국어 글꼴로) */
html[lang="en"] {
  --font: "Open Sans", "Pretendard Variable", "Malgun Gothic", system-ui, sans-serif;
  --font-ui: "Inter", "SUIT Variable", "Malgun Gothic", system-ui, sans-serif;
  --font-title: "Inter", "Pretendard Variable", "Malgun Gothic", system-ui, sans-serif;
  --font-article: "Newsreader", "IBM Plex Sans KR", "Malgun Gothic", Georgia, serif;
  --num-weight: 800;
}

/* ═══ 3. 바탕 ═══ */
html {
  background: var(--ground);
  scrollbar-color: var(--line-ctl) transparent;   /* 스크롤바: 막대만 보이고 뒤 바탕은 투명 (안쪽 칸들도 따라가요) */
}
body {
  margin: 0;
  color: var(--ink);
  font: 400 16px/1.6 var(--font);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
/* 키보드로 옮겨 다닐 때 보이는 테두리 (마우스로 누를 때는 안 보여요) */
:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
}
/* 화면에는 안 보이고 화면 읽기 프로그램만 읽는 글자 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
/* 링크는 둘레 글자색 그대로 (밑줄 · 색은 칸마다 정해요), 밑줄은 글자에서 살짝 떨어지게 */
a {
  color: inherit;
  text-underline-offset: 0.2em;
  text-decoration-thickness: 1px;
}
/* 글자를 끌어 고를 때 · 입력 커서: 팀 색 */
::selection {
  background: color-mix(in srgb, var(--team-text) 24%, transparent);
}
input,
textarea {
  caret-color: var(--team-text);
}
/* 숫자: 번호판 글꼴 + 자리를 맞춘 숫자 (바뀌어도 폭이 같아서 흔들리지 않아요) */
.num {
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums;
}

/* ═══ 4. 글꼴 역할 (사이트 전체) ═══
   메뉴 · 버튼: 버튼마다 "font: inherit"이 많아서 !important로 확실하게 (버튼 안의 제목 · 팀 이름은 아래 목록이 이겨요)
   입력칸 · 고르는 칸(select)은 내용 글꼴 그대로 */
.top-menu,
.tab-bar,
.menu-sheet,
button,
input[type="button"],
input[type="submit"] {
  font-family: var(--font-ui) !important;
}
/* 큰 제목 · 팀 이름 · 번호판 숫자 (새로 생기면 여기에 더해요. 칸 안의 작은 제목은 내용 글꼴)
   번호판 숫자(.numboard-num · .ticket-date 등)는 --font-num(= 큰 제목 글꼴)을 부품에서 직접 써요 */
.page-title,
.ticket-team-name,
.home-rank-name {
  font-family: var(--font-title);
}
/* 기사 제목 (홈 뉴스 칸 …) */
.article-title,
.home-news-title {
  font-family: var(--font-article);
}
/* 팀 로고 자리(색 동그라미 + 약자)는 그림처럼: 어느 칸 안에 있어도 메뉴 · 버튼 글꼴 */
.team-badge {
  font-family: var(--font-ui);
}

/* ═══ 5. 페이지 틀 · 페이지 이동 ═══
   메뉴가 있는 페이지의 본문(main)은 모두 같은 폭: 내용 양 끝 = 메뉴 양 끝.
   휴대폰은 아래 탭 막대(--tabbar-h)만큼 아래 여백을 더 둬요 (마지막 내용이 막대에 안 가려지게) */
#top-menu ~ main {
  width: min(var(--page-max), 100% - 2 * var(--page-gutter));
  margin: 0 auto;
  padding: var(--page-top) 0 calc(var(--page-bottom) + var(--tabbar-h));
}

/* 스크롤바 자리: 스크롤바는 스크롤이 있는 페이지에만 생겨요.
   스크롤바가 없는 페이지는 js(common.js의 watchScrollbarSpace)가 <html>에 .no-scrollbar를 붙이고,
   그 폭(--scrollbar-w)만큼 body 오른쪽을 비워요 → '파코어' · 내용 위치는 어느 페이지에서나 같아요.
   위쪽 메뉴는 그 빈자리까지 이어지고, 안쪽 글자 · 버튼은 그만큼 더 안쪽에서 끝나요. */
html.no-scrollbar:has(#top-menu) body {
  padding-right: var(--scrollbar-w);
}
html.no-scrollbar .top-menu {
  margin-right: calc(-1 * var(--scrollbar-w));
}

/* 페이지 이동 (js: common.js의 setupPageChange · skin.js의 "맨 위 막대 이어받기")
   1. 사이트 안 링크를 누르는 순간: 메뉴 아래 내용을 비우고(.page-leaving) 맨 위 막대가 차오르기 시작,
      비운 자리에 갈 페이지 모양의 회색 뼈대(.page-skeleton)가 은은하게 반짝여요
   2. 새 페이지가 준비되면 바로 보이고, 막대는 이어서 페이지를 다 받으면 100% → 사라짐 */
html.page-leaving body > :not(#top-menu, .page-loader, .page-skeleton, .tab-bar) {
  visibility: hidden;
}
/* 뼈대: 칸 자리 · 크기 · 색은 js가 (페이지 맨 위 기준 자리라 화면에 고정) */
.page-skeleton {
  position: fixed;
  inset: 0;
  z-index: 50;              /* 위쪽 메뉴(100) 밑 */
  overflow: hidden;
  pointer-events: none;
}
.page-skeleton i {
  position: absolute;
  /* 반짝임: 화면 전체에 걸친 한 줄기 빛이 왼쪽 → 오른쪽으로 지나가요 (모든 칸이 같은 빛을 나눠 가져요) */
  background-image: linear-gradient(100deg, transparent 40%, rgba(255, 255, 255, 0.45) 50%, transparent 60%);
  background-size: 200vw 100%;
  background-attachment: fixed;
  animation: skeleton-shine 1.2s linear infinite;
}
html[data-theme="dark"] .page-skeleton i {
  background-image: linear-gradient(100deg, transparent 40%, rgba(255, 255, 255, 0.06) 50%, transparent 60%);
}
html[data-motion="reduce"] .page-skeleton i {
  animation: none;
  background-image: none;
}
@keyframes skeleton-shine {
  from { background-position: 100vw 0; }
  to { background-position: -100vw 0; }
}
/* 맨 위 막대: 팀 색 띠 위에 있어서 띠 위 글자색(흰색 또는 검정)으로 */
.page-loader {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;            /* 위쪽 메뉴 · 팝업보다 위 */
  height: 3px;
  background: var(--team-ink);
  transform: scaleX(0);     /* 차오르는 자리는 js가 정해요 */
  transform-origin: left center;
  pointer-events: none;
  transition: opacity 0.2s;
}
.page-loader.is-done {      /* 다 차면 스르르 사라져요 */
  opacity: 0;
}
/* 크롬 · 엣지: 새 페이지가 그려질 때까지 지금 화면(메뉴 + 막대)을 그대로 두고, 준비되면 움직임 없이 바로 바꿔요 (하얀 화면 깜빡임 없이)
   새 페이지 글꼴이 아직이면 그동안 지금 화면을 조금 더 보여 줘요 (js/skin.js) → 글꼴이 바뀌며 깜빡이지 않게 */
@view-transition {
  navigation: auto;
}
::view-transition-group(root),   /* 바깥 틀에도 브라우저 기본 움직임(0.25초)이 있어서 같이 꺼요 → 전환이 바로 끝나요 */
::view-transition-old(root),
::view-transition-new(root) {
  animation: none;
}

/* ═══ 6. 위쪽 메뉴 (새 디자인 팀 페이지 공통, js: common.js의 renderSiteMenu) ═══
   - 띠(.menu-band): 팀 색 판 (바탕색은 css/skins/clean/site.css). 안쪽 '파코어' 왼쪽 ~ 마지막 버튼 오른쪽 = 내용 양 끝
   - 지금 있는 페이지의 메뉴는 표지판처럼 색이 뒤집혀요 (띠 글자색 판 + 팀 색 글자)
   - 아이패드 세로(641~1023): 띠에 로고 · 주요 4곳 + '더 보기' · 동그라미 버튼 (2026-11-12, 흰 메뉴 줄 없앰)
   - 휴대폰(640 이하): 띠에는 로고 · 알림 · ☰만, 아래 탭 막대 + ☰ 메뉴판 (아래 "휴대폰 메뉴") */
.top-menu {
  position: sticky;         /* 스크롤해도 화면 맨 위에 붙어 있기 */
  top: 0;
  z-index: 100;
}
.menu-band {
  position: relative;
  display: flex;
  align-items: center;
  gap: 28px;
  height: var(--band-h);
  /* 띠는 화면 끝까지, 안의 로고 ~ 버튼은 내용 폭에 딱 맞게: 넓으면 남는 폭의 반씩, 좁으면 페이지 옆 여백만큼 */
  padding: 0 max(var(--page-gutter), (100% - var(--page-max)) / 2);
  color: var(--team-ink);
}
/* 스크롤바가 없는 페이지: 띠가 그 빈자리까지 넓어졌으니(위 "스크롤바 자리") 그만큼 빼고 계산해요 */
html.no-scrollbar .menu-band {
  padding-left: max(var(--page-gutter), (100% - var(--scrollbar-w) - var(--page-max)) / 2);
  padding-right: calc(max(var(--page-gutter), (100% - var(--scrollbar-w) - var(--page-max)) / 2) + var(--scrollbar-w));
}

/* '파코어' 로고: 버튼 틀 없이 글자 그림 자체가 버튼 · 띠 위 글자색으로 칠해요 */
.menu-logo {
  display: block;
  flex: none;
  margin-left: -2px;        /* 아래 여백(2px)만큼 당겨서 글자 왼쪽 끝이 내용 왼쪽 끝과 딱 맞게 */
  padding: 4px 2px;
  border-radius: var(--radius-ctl);
  color: inherit;
}
.menu-logo:focus-visible {
  outline: 2px solid var(--team-ink);
  outline-offset: 2px;
}
/* 파코어 로고 (기울어진 F + 공): 그림은 js/common.js의 SITE_LOGO_SVG(SVG, 메뉴를 그릴 때 같이 들어가서 늦게 나오지 않아요) */
.menu-logo-mark {
  display: block;
  height: 30px;
  aspect-ratio: 212.6 / 209.4;
}
.menu-logo-mark svg {
  display: block;
  width: 100%;
  height: 100%;
}
.menu-divider {
  flex: none;
  width: 1px;
  height: 18px;
  background: color-mix(in srgb, var(--team-ink) 40%, transparent);
}

/* 메뉴 7개 (PC · 노트북) */
.menu-links {
  display: flex;
  align-items: center;
  gap: 2px;
  min-width: 0;
}
.menu-links a {
  display: flex;
  flex: none;
  align-items: center;
  height: 40px;
  padding: 0 12px;
  border-radius: var(--radius-ctl);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color 0.15s, color 0.15s;
}
.menu-links a {
  color: var(--team-ink);
}
/* 올리면 옅은 막 · 누르면 더 진한 막 (모양 · 크기 그대로) */
.menu-links a:hover {
  background: color-mix(in srgb, var(--team-ink) 14%, transparent);
}
.menu-links a:active {
  background: color-mix(in srgb, var(--team-ink) 28%, transparent);
}
/* 지금 페이지: 표지판이 뒤집혀요 (띠 글자색 판 + 팀 색 글자) */
.menu-links a.active {
  background: var(--team-ink);
  color: var(--team-strong);
}
.menu-links a:focus-visible {
  outline: 2px solid var(--team-ink);
  outline-offset: 2px;
}
/* 한국어 '팀'은 한 글자 → 누르는 칸을 두 글자 메뉴('선수')와 같은 폭으로, 글자는 가운데 (2026-11-22 사용자 요청)
   보이지 않는 두 글자(::after, 높이 0)가 칸 폭만 잡아요 → 글꼴이 바뀌어도 두 글자 메뉴와 같은 폭. 옆 여백은 다른 메뉴와 같아요 */
html[lang="ko"] .menu-links a[data-key="teams"] {
  flex-direction: column;
  justify-content: center;
}
html[lang="ko"] .menu-links a[data-key="teams"]::after {
  content: '선수';
  height: 0;
  overflow: hidden;
  visibility: hidden;
}
/* 두 묶음(주요 4곳 | 7개) 사이 세로 선: 로고 옆 선과 같은 모양 */
.menu-links .menu-divider {
  margin: 0 10px;
}
/* PL 팬의 '게시판': 자물쇠 + 흐리게 (누르면 안내만, 띠 · 메뉴 줄 같은 모양) */
.menu-links a.is-locked {
  gap: 4px;
  opacity: 0.55;
  cursor: not-allowed;
}
.menu-links a.is-locked svg {
  flex: none;
  width: 16px;
  height: 16px;
}
/* 좁은 PC의 '더 보기 ▾': 평소엔 숨어 있고, 띠에 메뉴가 다 안 들어가면(js의 fitBand → .is-tight) 7개 대신 보여요.
   모양 · 올림 · 누름 · 지금 위치(뒤집힘)는 메뉴 칸과 같아요 */
.menu-more {
  display: none;
  flex: none;
  align-items: center;
  gap: 4px;
  height: 40px;
  margin: 0;
  padding: 0 10px 0 12px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: transparent;
  color: var(--team-ink);
  font: 700 15px/1 var(--font-ui);
  letter-spacing: -0.01em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.menu-more svg {
  width: 16px;
  height: 16px;
}
.menu-more:hover,
.menu-more[aria-expanded="true"] {
  background: color-mix(in srgb, var(--team-ink) 14%, transparent);
}
.menu-more:active {
  background: color-mix(in srgb, var(--team-ink) 28%, transparent);
}
.menu-more.active {
  background: var(--team-ink);
  color: var(--team-strong);
}
.menu-more:focus-visible {
  outline: 2px solid var(--team-ink);
  outline-offset: 2px;
}
.menu-band.is-tight .menu-extra {
  display: none;
}
.menu-band.is-tight .menu-more {
  display: inline-flex;
}
/* '더 보기' 판: 알림 창과 같은 판 모양, 버튼 바로 아래 (왼쪽 위치는 js가 버튼에 맞춰요). 칸 = 그림 + 이름 (휴대폰 ☰ 메뉴판과 같은 목록) */
.menu-more-panel {
  position: absolute;
  top: calc(var(--band-h) - 4px);
  z-index: 5;
  display: grid;
  gap: 2px;
  width: 240px;
  padding: 8px;
  border-radius: var(--radius-panel);
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--line), var(--shadow-lift);
}
.menu-more-panel[hidden] {
  display: none;
}
.menu-more-link {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 44px;
  padding: 0 12px;
  border-radius: var(--radius-ctl);
  color: var(--ink);
  font: 700 15px/1 var(--font-ui);
  text-decoration: none;
  transition: background-color 0.15s, color 0.15s;
}
.menu-more-icon {                  /* 라이트 = 검은 그림, 다크 = 흰 그림 (2026-11-13) */
  display: grid;
  flex: none;
  place-items: center;
  width: 22px;
  height: 22px;
  color: var(--ink);
}
.menu-more-icon svg {
  width: 22px;
  height: 22px;
}
.menu-more-link:hover {
  background: var(--panel-2);
}
.menu-more-link:active {
  background: var(--panel-3);
}
.menu-more-link:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
/* 지금 페이지 = 표지판 판 (메뉴 줄과 같아요) */
.menu-more-link.active {
  background: var(--sign);
  color: var(--sign-ink);
}
.menu-more-link.active .menu-more-icon {
  color: inherit;
}

/* 동그라미 버튼 5개 (소리 · 알림 · 구독 · 공유 · 설정): 띠 위에서 모두 띠 글자색 테두리 · 아이콘으로 통일 */
.menu-small {
  display: flex;
  flex: none;
  align-items: center;
  gap: 8px;
  margin-left: auto;        /* 남는 공간을 왼쪽에 몰아서 오른쪽 끝으로 */
}
.menu-circle {
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 1.5px solid var(--team-ink);
  border-radius: 50%;
  background: transparent;
  color: var(--team-ink);
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
.menu-circle svg {
  display: block;
  width: 20px;
  height: 20px;
}
.menu-circle:hover {
  background: color-mix(in srgb, var(--team-ink) 14%, transparent);
}
.menu-circle:active {
  background: color-mix(in srgb, var(--team-ink) 28%, transparent);
}
.menu-circle:focus-visible {
  outline: 2px solid var(--team-ink);
  outline-offset: 2px;
}
/* 지금 위치면 꽉 찬 동그라미로 뒤집혀요: 설정 페이지의 설정 · 구독 페이지의 구독 · FAQ 페이지의 FAQ · 알림 창이 열린 동안 종 (2026-11-19) */
.menu-settings[aria-current="page"],
.menu-subscribe[aria-current="page"],
.menu-faq[aria-current="page"],
.menu-bell[aria-expanded="true"] {
  background: var(--team-ink);
  color: var(--team-strong);
}
/* PC · 패드: 알림 창이 열린 동안은 종만 선택됨 — 지금 페이지(구독 · FAQ · 설정) 동그라미는 잠시 보통 모양으로 (2026-11-20)
   (휴대폰 띠엔 이 동그라미들이 없어요) */
.menu-band:has(.menu-bell[aria-expanded="true"]) :is(.menu-settings, .menu-subscribe, .menu-faq)[aria-current="page"]:not(:hover) {
  background: transparent;
  color: var(--team-ink);
}
/* 알림(종): 새 알림 = 오른쪽 위 빨간 점 / 긴급 = 빨간 동그라미 + 흰 느낌표 + 종이 흔들려요
   점 둘레는 흰 고리(흰 동그라미 버튼과 같은 색) → 띠가 빨간 팀에서도 점이 따로 보여요 */
.menu-bell {
  position: relative;
}
.menu-badge {
  position: absolute;
  top: -2px;
  right: -2px;
  display: none;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: #ef4444;
  box-shadow: 0 0 0 2px #FFFFFF;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
  line-height: 1;
  pointer-events: none;
}
.menu-bell.has-new .menu-badge {
  display: grid;
  place-items: center;
}
.menu-bell.is-urgent .menu-badge {
  top: -6px;
  right: -6px;
  width: 18px;
  height: 18px;
}
.menu-bell.is-urgent svg {
  transform-origin: 50% 12%;   /* 종 꼭지를 축으로 */
  animation: bell-shake 0.9s ease-in-out infinite;
}
@keyframes bell-shake {
  0%, 100% { rotate: 0deg; }
  8%  { rotate: 26deg; }
  16% { rotate: -24deg; }
  24% { rotate: 22deg; }
  32% { rotate: -20deg; }
  40% { rotate: 16deg; }
  48% { rotate: -12deg; }
  56% { rotate: 8deg; }
  64% { rotate: -4deg; }
  72% { rotate: 0deg; }
}
html[data-motion="reduce"] .menu-bell.is-urgent svg {
  animation: none;
}

/* 손님 막대: 로그인 안 한 사람도 보는 페이지(구독 · 약관)의 맨 위 (js: common.js의 renderGuestMenu, 색은 css/skins/clean/site.css)
   팀 메뉴 띠(.menu-band)와 같은 높이 · 안쪽 폭, 로고 왼쪽 · 로그인 오른쪽 */
.plus-guest-band {
  justify-content: space-between;
}
.plus-guest-login {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: var(--radius-ctl);
  font: 800 15px/1 var(--font-ui);
  text-decoration: none;
}
html:has(.plus-guest-band) {
  --tabbar-h: 0px;                  /* 손님 화면엔 아래 탭 막대가 없어요 → 맨 아래 여백도 그만큼 줄여요 */
}

/* ═══ 7. 휴대폰 메뉴: ☰ 버튼 · 아래 탭 막대 · ☰ 메뉴판 · 짧은 안내 (js: common.js의 makeTabBar · makeMenuSheet · showSiteToast) ═══
   640 이하에서만 보여요 (아래 "작은 화면"). 소파스코어 · FotMob 앱처럼 자주 가는 곳은 아래 탭 막대, 나머지는 ☰ 메뉴판 */
.menu-toggle,
.tab-bar {
  display: none;
}
.menu-toggle {
  flex: none;
  place-content: center;
  gap: 4px;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: var(--radius-ctl);
  background: transparent;
  color: var(--team-ink);
  cursor: pointer;
  transition: background-color 0.15s;
}
.menu-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 1px;
  background: currentColor;
}
.menu-toggle:hover {
  background: color-mix(in srgb, var(--team-ink) 14%, transparent);
}
.menu-toggle:active {
  background: color-mix(in srgb, var(--team-ink) 28%, transparent);
}
.menu-toggle:focus-visible {
  outline: 2px solid var(--team-ink);
  outline-offset: 2px;
}

/* 아래 탭 막대 */
.tab-bar {
  position: fixed;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 90;
  grid-template-columns: repeat(4, minmax(0, 1fr));   /* 메뉴 첫 번째 묶음 4곳 (홈은 '파코어' 로고) */
  height: var(--tabbar-h);
  padding-bottom: env(safe-area-inset-bottom);
  border-top: 1px solid var(--line);
  background: var(--panel);
}
.tab-bar-item {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-decoration: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
  transition: background-color 0.15s, color 0.15s;
}
.tab-bar-item svg {
  width: 24px;
  height: 24px;
}
.tab-bar-item span {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tab-bar-item:active {
  background: var(--panel-2);
}
.tab-bar-item:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -4px;
  border-radius: var(--radius-card);
}
/* 지금 탭: 진한 글자 + 위에 팀 색 막대 (표지판의 "지금 여기") */
.tab-bar-item.is-active {
  color: var(--ink);
}
.tab-bar-item.is-active svg {
  stroke-width: 2.4;
}
.tab-bar-item.is-active::before {
  content: '';
  position: absolute;
  top: -1px;
  left: 50%;
  width: 32px;
  height: 3px;
  border-radius: 0 0 3px 3px;
  background: var(--team-strong);
  translate: -50% 0;
}
/* PL 팬의 게시판 탭: 자물쇠 + 흐리게 (누르면 안내만) */
.tab-bar-item.is-locked {
  opacity: 0.45;
  cursor: not-allowed;
}
/* 3D 축구처럼 화면 아래에 조작 버튼이 있는 페이지는 탭 막대를 숨겨요 (☰은 그대로) */
body.fb-body .tab-bar {
  display: none !important;
}

/* ☰ 메뉴판: 아래에서 올라오는 판 */
.menu-sheet {
  position: fixed;
  inset: auto 0 0;
  width: 100%;
  max-width: none;
  max-height: 85dvh;
  margin: 0;
  padding: 0 16px calc(16px + env(safe-area-inset-bottom));
  overflow-y: auto;
  overscroll-behavior: contain;
  border: 0;
  border-radius: var(--radius-sheet) var(--radius-sheet) 0 0;
  background: var(--ground);
  color: var(--ink);
  transform: translateY(0);
  transition: transform 0.28s cubic-bezier(0.32, 0.72, 0, 1);   /* 아이폰 서랍처럼 빠르게 나와서 부드럽게 멈춰요 */
}
@starting-style {
  .menu-sheet[open] {
    transform: translateY(100%);
  }
}
.menu-sheet.is-closing {
  transform: translateY(100%);
  transition-duration: 0.2s;   /* 닫힐 때는 더 빠르게 (common.js의 SHEET_CLOSE_MS) */
}
.menu-sheet.is-dragging {
  transition: none;            /* 끄는 동안에는 손가락을 바로 따라와요 */
}
.menu-sheet::backdrop {
  background: rgba(17, 18, 20, 0.5);
  transition: opacity 0.28s;
}
@starting-style {
  .menu-sheet[open]::backdrop {
    opacity: 0;
  }
}
.menu-sheet.is-closing::backdrop {
  opacity: 0;
  transition-duration: 0.2s;
}
html[data-motion="reduce"] .menu-sheet,
html[data-motion="reduce"] .menu-sheet::backdrop {
  transition: none;
}
/* 손잡이 줄: 여기를 끌어 내리면 닫혀요 */
.menu-sheet-head {
  position: sticky;
  top: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  background: var(--ground);
  cursor: grab;
  touch-action: none;
}
.menu-sheet-grab {
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: var(--line-ctl);
}
.menu-sheet-close {
  position: absolute;
  top: 4px;
  right: -6px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color 0.15s;
}
.menu-sheet-close svg {
  width: 20px;
  height: 20px;
}
.menu-sheet-close:hover {
  background: var(--panel-3);
}
.menu-sheet-close:active {
  background: color-mix(in srgb, var(--ink) 16%, var(--panel));
}
/* 손가락 기기 (2026-11-13 사용자 요청): 팝업 · 메뉴판이 열릴 때 X로 저절로 가는 포커스의 테두리를 안 보여요 */
@media (hover: none) {
  :is(.dialog-close, .menu-sheet-close, .viewer-close):focus-visible {
    outline: none;
  }
}
/* 메뉴 7개: 두 줄 칸, 왼쪽에 작은 표지판 그림 */
.menu-sheet-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}
.menu-sheet-link {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  height: 60px;
  padding: 0 12px;
  border-radius: var(--radius-card);
  background: var(--panel);
  color: var(--ink);
  font-size: 16px;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-decoration: none;
  transition: background-color 0.15s;
}
.menu-sheet-link:active {
  background: var(--panel-3);
}
.menu-sheet-icon {                 /* 2026-11-13 사용자 요청: 라이트 = 흰 바탕 검은 그림, 다크 = 검은 바탕 흰 그림 (칸 색 그대로 + 글자색 그림) */
  display: grid;
  flex: none;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-ctl);
  background: var(--panel);
  color: var(--ink);
}
.menu-sheet-icon svg {
  width: 18px;
  height: 18px;
}
/* 지금 페이지: 표지판이 뒤집혀요 */
.menu-sheet-link.active {
  background: var(--sign);
  color: var(--sign-ink);
}
.menu-sheet-link.active .menu-sheet-icon {
  background: var(--sign);
  color: var(--sign-ink);
}
/* 소리 · 구독 · 공유 · 설정: 이름이 보이는 네 칸 (띠의 동그라미 모양 규칙보다 먼저) */
.menu-sheet-utils {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.menu-sheet .menu-sheet-util {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  width: auto;
  height: 64px;
  border: 0;
  border-radius: var(--radius-card);
  background: var(--panel);
  color: var(--ink);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
.menu-sheet .menu-sheet-util svg {
  width: 22px;
  height: 22px;
}
.menu-sheet .menu-sheet-util:hover,
.menu-sheet .menu-sheet-util:active {
  background: var(--panel-3);
}
.menu-sheet .menu-sheet-util:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
}
.menu-sheet .menu-settings[aria-current="page"],
.menu-sheet .menu-subscribe[aria-current="page"],
.menu-sheet .menu-faq[aria-current="page"] {
  background: var(--sign);
  color: var(--sign-ink);
}

/* 짧은 안내 (화면 아래, 탭 막대 위) */
.site-toast {
  position: fixed;
  bottom: calc(var(--tabbar-h) + 16px);
  left: 50%;
  z-index: 120;
  max-width: calc(100% - 32px);
  margin: 0;
  padding: 10px 14px;
  border-radius: var(--radius-ctl);
  background: var(--sign);
  color: var(--sign-ink);
  font-size: 14px;
  font-weight: 700;
  opacity: 0;
  translate: -50% 8px;
  pointer-events: none;
  transition: opacity 0.2s, translate 0.2s var(--ease);
}
.site-toast.is-shown {
  opacity: 1;
  translate: -50% 0;
}
html[data-motion="reduce"] .site-toast {
  translate: -50% 0;
  transition: opacity 0.2s;   /* 움직임 없이 나타나기만 */
}

/* ═══ 8. 알림 창 · 팝업 · 공유 창 (js: common.js의 setupMenuNotices · openShareDialog) ═══ */
/* 알림 창: 종 바로 아래, 오른쪽 끝 = 내용 오른쪽 끝. 한 줄 60px × 5줄 높이, 더 많으면(최대 8개) 창 안에서 스크롤 */
.notice-panel {
  --notice-row: 60px;
  position: absolute;
  top: calc(100% + 8px);
  right: max(var(--page-gutter), (100% - var(--page-max)) / 2);
  width: min(360px, 100% - 2 * var(--page-gutter));
  padding: 12px 8px 8px;
  border-radius: var(--radius-panel);
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 0 0 1px var(--line), var(--shadow-lift);
}
html.no-scrollbar .notice-panel {
  right: calc(max(var(--page-gutter), (100% - var(--scrollbar-w) - var(--page-max)) / 2) + var(--scrollbar-w));
}
.notice-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 0 10px 10px;
}
.notice-head h2 {
  margin: 0;
  font: 800 16px/1.3 var(--font-ui);
  letter-spacing: -0.01em;
}
.notice-dev {
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted);
  font-size: 13px;
  text-decoration: underline;
  cursor: pointer;
}
.notice-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
  max-height: calc(var(--notice-row) * 5 + 2px * 4);
  margin: 0;
  padding: 0;
  list-style: none;
  overflow-y: auto;
  overscroll-behavior: contain;   /* 창 끝까지 스크롤해도 뒤 페이지는 안 움직여요 */
  scrollbar-width: thin;
}
.notice-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-content: center;
  column-gap: 10px;
  row-gap: 3px;
  height: var(--notice-row);
  padding: 0 10px;
  border-radius: var(--radius-card);
  color: var(--ink);
  text-decoration: none;
  transition: background-color 0.15s;
}
a.notice-item:hover {
  background: var(--panel-2);
}
a.notice-item:active {
  background: var(--panel-3);
}
.notice-item.unread {             /* 방금 읽은(새) 알림: 옅은 팀 색 줄 */
  background: var(--team-soft);
}
.notice-title {
  overflow: hidden;
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.notice-urgent {
  display: inline-block;
  margin-right: 6px;
  padding: 1px 6px;
  border-radius: var(--radius-ctl);
  background: var(--live);
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  vertical-align: 1px;
}
.notice-time {
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}
.notice-text {
  grid-column: 1 / -1;
  overflow: hidden;
  color: var(--ink-2);
  font-size: 14px;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.notice-empty {
  padding: 28px 10px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}

/* 팝업 기본 모양 (공유 · 기사 크게 보기 · 전술 설명 · 신고 · 프로필 꾸미기 창이 같이 써요)
   PC · 아이패드: 화면 가운데, 0.98 → 1 크기로 나타나요(0.2초) · 휴대폰: 아래에서 올라오는 판 */
.match-dialog {
  width: min(var(--dialog-w, 560px), 100% - 32px);   /* 팝업마다 폭은 --dialog-w로만 (휴대폰에서는 화면 폭) */
  max-height: calc(100dvh - 48px);
  padding: 24px;
  overflow-y: auto;
  border: 0;
  border-radius: var(--radius-panel);
  background: var(--panel);
  color: var(--ink);
  box-shadow: 0 30px 70px -20px rgba(17, 18, 20, 0.45);
  opacity: 1;
  scale: 1;
  transition: opacity 0.2s var(--ease), scale 0.2s var(--ease), translate 0.28s cubic-bezier(0.32, 0.72, 0, 1),
    overlay 0.2s allow-discrete, display 0.2s allow-discrete;
}
.match-dialog:not([open]) {        /* 닫힐 때: 더 빠르게 (0.15초) */
  opacity: 0;
  scale: 0.98;
  transition-duration: 0.15s;
}
@starting-style {
  .match-dialog[open] {
    opacity: 0;
    scale: 0.98;
  }
}
.match-dialog::backdrop {
  background: rgba(17, 18, 20, 0.5);
}
html[data-motion="reduce"] .match-dialog {
  transition: none;
}
/* 팝업 공통 (2026-11-17, js: common.js "팝업 공통") — 모든 크기
   팝업이 떠 있는 동안 뒤 페이지는 스크롤 안 돼요. PC는 스크롤바가 사라진 자리를 watchScrollbarSpace가 바로 채워서 화면이 옆으로 흔들리지 않아요.
   닫기 X는 모든 팝업이 같은 자리 · 크기: 팝업 오른쪽 위(위 24 · 오른쪽 16), PC 36 · 패드 44, 그림 20 (휴대폰은 X 대신 손잡이) */
html:has(dialog:modal),
html:has(dialog:modal) body {
  overflow: hidden;
}
.match-dialog.is-dragging {        /* 휴대폰에서 끄는 동안에는 손가락을 바로 따라와요 */
  transition: none;
}
.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;   /* 제목은 왼쪽, 닫기는 오른쪽 위 */
  gap: 12px;
}
.dialog-header h2 {
  margin: 0;
  font: 800 18px/1.3 var(--font-ui);
  letter-spacing: -0.01em;
}
.dialog-close {
  display: grid;
  flex: none;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-right: -8px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-2);
  font-size: 18px;
  cursor: pointer;
  transition: background-color 0.15s;
}
.dialog-close svg {
  width: 20px;
  height: 20px;
}
.dialog-close:hover {
  background: var(--panel-3);
}
.dialog-close:active {
  background: color-mix(in srgb, var(--ink) 16%, var(--panel));
}

/* 공유 창: 제목(공유 그림 + 공유) → 설명 → 주소 + 링크 복사 → 공유할 곳 (각 회사 로고, js: common.js의 SHARE_LOGOS) */
.share-dialog {
  --dialog-w: 440px;
}
.share-dialog .dialog-header h2 {  /* 제목: 페이지 이름처럼 그림 + 굵은 글자 (2026-11-24 크게) */
  display: flex;
  align-items: center;
  gap: 10px;
  font: 900 26px/1.1 var(--font-title);
  letter-spacing: -0.02em;
}
.share-title-mark {
  display: grid;
  flex: none;
  width: 26px;
  height: 26px;
}
.share-title-mark svg {
  width: 100%;
  height: 100%;
}
.share-desc {
  margin: 8px 0 16px;
  color: var(--ink-2);
  font-size: 15px;
}
.share-link {
  display: flex;
  gap: 8px;
}
.share-link input {
  flex: 1;
  min-width: 0;
  height: 40px;
  padding: 0 12px;
  border: 1.5px solid var(--line-ctl);
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font: inherit;
  font-size: 14px;
}
.share-copy {                      /* 주 버튼: 팀 색 판 */
  flex: none;
  height: 40px;
  padding: 0 16px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: var(--team-strong);
  color: var(--team-ink);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 0.15s;
}
.share-copy:hover {
  background: color-mix(in srgb, var(--team-strong) 88%, #000);
}
.share-copy:active {
  background: color-mix(in srgb, var(--team-strong) 76%, #000);
}
.share-targets {
  display: flex;
  justify-content: center;
  gap: 4px;
  margin-top: 20px;
}
.share-target {                    /* 좁은 휴대폰에서는 한 줄에 맞게 조금씩 좁아져요 */
  display: grid;
  flex: 1 1 0;
  justify-items: center;
  gap: 12px;                        /* 로고 둘레 빈 공간 = 로고 폭의 1/4 이상 (메타 로고 규칙) */
  min-width: 0;
  max-width: 76px;
  padding: 8px 0;
  border: 0;
  border-radius: var(--radius-card);
  background: none;
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s;
}
.share-target:hover {
  background: var(--panel-2);
}
.share-target:active {
  background: var(--panel-3);
}
.share-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  overflow: hidden;
  border-radius: 50%;
  background: #000;                 /* X · 스레드: 공식 색은 검정 · 흰색뿐 */
  color: #fff;
}
.share-mark svg {
  width: 24px;
  height: 24px;
}
.share-logo {                       /* 로고 모양으로 오려 낸 칸 (파일 주소는 js가 mask-image로) */
  width: 24px;
  height: 24px;
  background: currentColor;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  -webkit-mask-size: contain;
  mask-size: contain;
}
.share-x .share-logo {
  width: 21px;                      /* X는 꽉 찬 네모 모양이라 조금 작게 → 스레드와 같은 크기로 보여요 */
}
.share-logo-full {                  /* 페이스북: 파일 자체가 동그라미 로고 */
  display: block;
  width: 100%;
  height: 100%;
}
.share-native .share-mark   { background: #2563eb; }
.share-facebook .share-mark { background: none; }
html[data-theme="dark"] :is(.share-x, .share-threads) .share-mark {
  background: #fff;
  color: #000;
}

/* ═══ 9. 사이트 안내 · 고정 버튼 (js: common.js의 applySiteNotices · showStaffReturnButton · renderDevClock) ═══ */
/* 알림 띠: 메뉴 바로 아래, 표지판 색 */
.site-banner {
  padding: 10px var(--page-gutter);
  background: var(--sign);
  color: var(--sign-ink);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
  text-align: center;
}
/* 사이트 정지 · 점검 중: 화면 전체를 덮어요 (뒤는 바탕색으로 가려요) */
.site-gate-open,
.site-gate-open body {
  overflow: hidden;
}
.site-gate {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: grid;
  place-items: center;
  padding: 24px;
  background: var(--ground);
}
.site-gate-box {
  width: 100%;
  max-width: 440px;
  padding: 28px;
  border-radius: var(--radius-panel);
  background: var(--panel);
  box-shadow: var(--shadow-lift);
}
.site-gate-box h1 {                /* 제목 = 표지판 */
  display: inline-flex;
  margin: 0;
  padding: 8px 14px;
  border-radius: var(--radius-ctl);
  background: var(--sign);
  color: var(--sign-ink);
  font: 800 18px/1.3 var(--font-ui);
  letter-spacing: -0.01em;
}
.site-gate-box p {
  margin: 16px 0 0;
  color: var(--ink-2);
  line-height: 1.7;
  white-space: pre-line;
}
.site-gate-button {
  height: 40px;
  margin-top: 20px;
  padding: 0 18px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: var(--team-strong);
  color: var(--team-ink);
  font-size: 15px;
  font-weight: 800;
  cursor: pointer;
  transition: background-color 0.15s;
}
.site-gate-button:hover {
  background: color-mix(in srgb, var(--team-strong) 88%, #000);
}
.site-gate-button:active {
  background: color-mix(in srgb, var(--team-strong) 76%, #000);
}
/* 관리자 구경 모드: 화면 오른쪽 아래 "관리자 사이트로" (PL 보라 = 관리자 페이지 색) */
.staff-return {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1500;
  padding: 10px 16px;
  border-radius: var(--radius-ctl);
  background: #3D195B;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  box-shadow: var(--shadow-lift);
  transition: background-color 0.15s;
}
.staff-return:hover {
  background: color-mix(in srgb, #3D195B 88%, #000);
}
.staff-return:active {
  background: color-mix(in srgb, #3D195B 76%, #000);
}
/* ⚠️ 개발용 테스트 시계 막대 (DEV_MODE · 흐르는 시계일 때만) */
.dev-clock {
  position: fixed;
  bottom: 16px;
  left: 16px;
  z-index: 200;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 8px 6px 14px;
  border-radius: var(--radius-ctl);
  background: #111214;
  color: #ffffff;
  font-size: 13px;
  box-shadow: var(--shadow-lift);
}
.dev-clock-time {
  margin-right: 4px;
  font-variant-numeric: tabular-nums;   /* 초가 바뀌어도 폭이 그대로 */
}
.dev-clock button {
  padding: 4px 10px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-ctl);
  background: transparent;
  color: #ffffff;
  font: inherit;
  cursor: pointer;
}
.dev-clock button[aria-pressed="true"] {
  background: #ffffff;
  color: #111214;
}

/* ═══ 10. 부품: 표지판 · 경기 티켓 · 번호판 · 번호판 넘김 · 태그 · 팀 배지 (새 디자인의 대표 요소) ═══ */

/* 표지판: 검은 판(다크 모드는 흰 판) + 왼쪽 그림 네모(화살표 · 그림) + 이름 — 칸 이름 · 페이지 이름 */
.sign {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 40px;
  padding: 0 16px 0 6px;
  border-radius: var(--radius-ctl);
  background: var(--sign);
  color: var(--sign-ink);
  font: 800 18px/1 var(--font-ui);
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.sign-mark {
  display: grid;
  flex: none;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: calc(var(--radius-ctl) - 2px);   /* 표지판 안쪽 네모 (바깥 모서리 - 틈) */
  background: var(--sign-ink);
  color: var(--sign);
}
.sign-mark svg {
  display: block;
  width: 18px;
  height: 18px;
  stroke-width: 2.6;
}
/* 밝은 표지판: 팀 색 판 · 검은 쪽지 위 (라이트 · 다크 모두 흰 판) */
.sign--light {
  background: #FFFFFF;
  color: #111214;
}
.sign--light .sign-mark {
  background: var(--team-strong);
  color: var(--team-ink);
}

/* 팀 배지 (로고 자리 — common.js의 makeTeamBadge: 팀 색 동그라미 + 약자). 크기는 --badge-size (20 · 28 · 40 · 72 · 132 단계만) */
.team-badge {
  --badge: var(--team);
  --badge-ink: var(--team-ink);
  display: inline-grid;
  flex: none;
  place-items: center;
  width: var(--badge-size, 40px);
  height: var(--badge-size, 40px);
  border-radius: 50%;
  background: var(--badge);
  color: var(--badge-ink);
  font-size: calc(var(--badge-size, 40px) * 0.27);
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16);
}
.team-badge.has-logo {
  background: var(--panel);
}
.team-badge img {
  width: 72%;
  height: 72%;
  object-fit: contain;
}

/* 경기 티켓: 검은 쪽지 + 절취선(점선 + 양 끝 반원 홈) + 팀 색 판
   크기는 칸마다 변수로: --stub-w(쪽지 폭) · --date-size · --time-size · --ticket-badge · --ticket-name */
.ticket {
  --stub-w: 320px;          /* 큰 날짜(96px)가 두 언어 모두 들어가는 폭 */
  --notch: 18px;
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 0;
}
.ticket-stub {
  position: relative;
  display: flex;
  flex: none;
  flex-direction: column;
  justify-content: flex-end;
  width: var(--stub-w);
  padding: 76px 20px 24px;
  /* 검은 쪽지 (다크 모드는 아래에서 한 단계 밝게). 절취선 양 끝(오른쪽 위 · 아래)에 반원 홈이 뚫려 있어요 (뒤가 비쳐요)
     홈은 mask로 뚫어요: 반투명한 쪽지도 색이 두 번 칠해지지 않게 */
  --stub-color: #111214;
  background: var(--stub-color);
  -webkit-mask:
    radial-gradient(circle at 100% 0, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) top / 100% 51% no-repeat,
    radial-gradient(circle at 100% 100%, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) bottom / 100% 51% no-repeat;
  mask:
    radial-gradient(circle at 100% 0, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) top / 100% 51% no-repeat,
    radial-gradient(circle at 100% 100%, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) bottom / 100% 51% no-repeat;
  color: #FFFFFF;
}
/* 절취선: 쪽지 오른쪽 끝의 점선 */
/* 다크 모드: 바탕(아스팔트색)과 구분되게 쪽지를 한 단계 밝은 검정으로 */
html[data-theme="dark"] .ticket-stub {
  --stub-color: #272A30;
}
.ticket-stub::after {
  content: '';
  position: absolute;
  top: calc(var(--notch) / 2 + 6px);
  right: -2px;
  bottom: calc(var(--notch) / 2 + 6px);
  border-right: 4px dotted var(--ground);
}
.ticket-round {
  margin: 0 0 8px;
  color: #C9CCD2;
  font-size: 15px;
  font-weight: 700;
}
.ticket-date {
  margin: 0;
  font: var(--num-weight) var(--date-size, 96px)/0.86 var(--font-num);
  letter-spacing: -0.04em;
  white-space: nowrap;
}
.ticket-time {
  margin: 8px 0 0;
  font: 800 var(--time-size, 40px)/1 var(--font-num);
  letter-spacing: -0.02em;
}
.ticket-venue {
  margin: 14px 0 0;
  font-size: 15px;
  font-weight: 700;
}
.ticket-body {
  position: relative;
  display: flex;
  flex: 1;
  flex-direction: column;
  justify-content: center;
  gap: 24px;
  min-width: 0;
  padding: 64px 28px 24px;
  /* 팀 색 판. 절취선 양 끝(왼쪽 위 · 아래)에 반원 홈 */
  --body-color: var(--team-strong);
  background: var(--body-color);
  -webkit-mask:
    radial-gradient(circle at 0 0, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) top / 100% 51% no-repeat,
    radial-gradient(circle at 0 100%, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) bottom / 100% 51% no-repeat;
  mask:
    radial-gradient(circle at 0 0, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) top / 100% 51% no-repeat,
    radial-gradient(circle at 0 100%, transparent calc(var(--notch) / 2), #000 calc(var(--notch) / 2 + 0.5px)) bottom / 100% 51% no-repeat;
  color: var(--team-ink);
}
.ticket-teams {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  align-items: start;
  gap: 12px;
}
.ticket-team {
  container-type: inline-size;   /* 팀 이름 글자 크기를 이 칸 폭(cqi)에 맞추려고 */
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  min-width: 0;
  text-align: center;
}
.ticket-team .team-badge {
  --badge-size: var(--ticket-badge, 132px);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.16), 0 0 0 5px var(--team-ink, #FFFFFF);   /* 팀 색 판 위에서 띄우는 링: 보통 흰색, 다크 모드에서 흰 티켓(뉴캐슬 · 풀럼)은 검정 (home.js가 티켓 글자색으로 넣어요) */
}
/* 팀 이름: 칸보다 긴 한 단어(예: Wolverhampton)는 그 이름만 글자를 줄여서 단어 중간에서 안 끊기게 (14px까지)
   --name-em = 가장 긴 단어의 폭(글자 크기 단위, home.js의 fitTicketNames가 재요) → 칸 폭(100cqi) ÷ 그 폭 */
.ticket-team-name {
  margin: 4px 0 0;
  font: 900 var(--ticket-name, 26px)/1.15 var(--font-title);
  font-size: clamp(14px, 100cqi / (var(--name-em, 0) + 0.15), var(--ticket-name, 26px));
  letter-spacing: -0.02em;
  word-break: keep-all;
  overflow-wrap: anywhere;   /* 14px로도 안 들어가면 그때만 끊어요 */
}
/* 두 팀 사이: 경기 전 VS · 경기 중 점수 vs 점수 (배지 가운데 높이에) */
.ticket-vs,
.ticket-score {
  align-self: start;
  margin-top: calc(var(--ticket-badge, 132px) / 2);
  translate: 0 -50%;
  white-space: nowrap;
}
.ticket-vs {
  font: 900 28px/1 var(--font-num);
}
.ticket-score {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}
.ticket-score-num {
  font: var(--num-weight) var(--score-size, 64px)/1 var(--font-num);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
}
.ticket-score-vs {
  font: 900 22px/1 var(--font-num);
}
.ticket-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.ticket-tags .tag {          /* 팀 색 판 위: 글자만 (팀 색 위 글자색) */
  height: auto;
  padding: 0;
  background: transparent;
  color: var(--team-ink);
}

/* 번호판: 화면마다 가장 중요한 숫자 하나 (크기는 --num-size: 40 · 64 · 96 · 128 · 168 단계만) */
.numboard {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.numboard-figure {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 4px 12px;
}
.numboard-num {
  color: var(--team-text);
  font: var(--num-weight) var(--num-size, 96px)/0.8 var(--font-num);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.04em;
}
.numboard-side {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding-bottom: 2px;
}
.numboard-unit {
  font: 900 22px/1 var(--font-title);
}
.numboard-note {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.3;
}

/* 번호판 넘김: 바뀐 자리 글자만 위에서 아래로 0.25초 (js: common.js의 setFlapText) */
.flap-char {
  display: inline-block;
  white-space: pre;         /* 띄어쓰기 칸도 폭을 지켜요 ('0 : 0', '1d to go') */
}
.flap-char.is-flip {
  animation: flap 0.25s var(--ease);
}
@keyframes flap {
  from {
    opacity: 0;
    transform: translateY(-45%);
  }
}
html[data-motion="reduce"] .flap-char.is-flip {
  animation: none;
}

/* 태그: 말머리 · AI 분석 · 경기 페이지에 준비된 것 */
.tag {
  display: inline-flex;
  flex: none;
  align-items: center;
  height: 26px;
  padding: 0 8px;
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
}

/* 경기 중 지금 점수 칩: 순위표 · 홈 순위 칸 · 팀 페이지 순위 주변의 경기 중인 팀 이름 옆 ("2-1 MC 67'", common.js makeLiveChip)
   색은 사이트의 '경기 중' 빨강(--live) 하나, 줄 높이는 그대로 (칩 20px) */
.live-chip {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: 5px;
  height: 20px;
  padding: 0 7px 0 6px;
  border-radius: var(--radius-ctl);
  background: color-mix(in srgb, var(--live) 11%, transparent);
  color: var(--live);
  font: 800 12px/1 var(--font-ui);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  vertical-align: middle;
}
.live-chip::before {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
}
.live-chip-team,
.live-chip-minute {
  font-weight: 700;
}
/* 홈 순위 칸은 좁아서 점수만 (경기 시간은 위 티켓에 있어요) */
.home-rank-row .live-chip-team,
.home-rank-row .live-chip-minute {
  display: none;
}

/* ═══ 11. 페이지 부품: 판 · 페이지 머리 · 작은 표지판 · 버튼 · 아이콘 버튼 · 고르는 탭 · 스위치 · 입력칸 · 시간표 목록 ═══
   부속 페이지(리그테이블 · 경기노트 · 승부예측 · 경기 …)가 같이 써요. 페이지 배치는 css/pages/<페이지>.css
   버튼 반응: 올리면 살짝 진하게 · 누르면 더 진하게 (크기 · 자리는 그대로). 고르는 탭 · 스위치는 올렸을 때만 (고른 상태가 따로 보여서) */

/* 판: 흰 판 (다크는 짙은 회색). 경계는 선 · 그림자 없이 바탕색 차이로만.
   .nm-box는 옛 이름이에요 (next-match.js가 closest('.nm-box')로 찾아서 이름을 그대로 둬요) */
.panel,
.nm-box {
  box-sizing: border-box;
  min-width: 0;
  padding: var(--panel-pad);
  border-radius: var(--radius-panel);
  background: var(--panel);
  color: var(--ink);
}
:is(.panel, .nm-box) h2 {
  margin: 0;
  font: 800 18px/1.3 var(--font-ui);
  letter-spacing: -0.01em;
}
:is(.panel, .nm-box) h3 {
  margin: 0;
  font: 800 15px/1.4 var(--font-ui);
}

/* 페이지 머리: 왼쪽 페이지 이름(그림 + 큰 글자, 상자 없음 + 바로 옆 작은 글) · 오른쪽 끝 그 페이지 도구
   위치 · 크기는 모든 페이지가 같아요(기준: 자료실) → 페이지마다, 화면 높이마다 따로 바꾸지 않기 */
.page-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 16px;
  margin-bottom: var(--head-gap);
}
.page-sign {                       /* .sign과 같이 써요: 판을 없애고 그림 · 글자만 크게 (크기는 --sign-… 세 값으로) */
  gap: 12px;
  height: var(--sign-h, 48px);
  margin: 0;
  padding: 0;
  border-radius: 0;
  background: none;
  color: var(--ink);
  font: 900 var(--sign-font, 40px)/1 var(--font-title);
  letter-spacing: -0.02em;
}
.page-sign .sign-mark {
  width: var(--sign-icon, 36px);
  height: var(--sign-icon, 36px);
  border-radius: 0;
  background: none;
  color: inherit;
}
.page-sign .sign-mark svg {
  width: 100%;
  height: 100%;
}
.page-back {                       /* 페이지 이름 왼쪽 ‹ 돌아가기 (게임 화면 → 게임 목록). 모양은 .round-btn */
  margin-right: -4px;               /* 이름과 사이 12 (머리 틈 16 - 4) */
  text-decoration: none;
}
/* ⓘ 설명 (common.js makeHelpTip): 제목 글자 바로 옆 작은 ⓘ, 누르는 칸은 넓게 · 제목 줄 높이는 그대로 (위아래로 넘쳐요)
   말풍선은 ⓘ 아래 왼쪽 맞춤 (화면 밖으로 나가면 js가 --shift만큼 왼쪽으로). PC는 올리면 · 폰 · 패드는 누르면(.is-open) */
.help-tip {
  position: relative;
  display: inline-flex;
  vertical-align: middle;
  margin: -8px -6px -8px 0;
}
.help-tip-btn {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--muted);
  cursor: help;
  transition: background-color 0.15s, color 0.15s;
}
.help-tip-btn svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}
.help-tip.is-open .help-tip-btn {
  background: var(--panel-2);
  color: var(--ink);
}
.help-tip-btn:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.help-tip-bubble {
  position: absolute;
  top: calc(100% + 2px);
  left: 0;
  z-index: 20;
  box-sizing: border-box;
  width: max-content;
  max-width: min(300px, 100vw - 32px);
  padding: 10px 14px;
  border-radius: var(--radius-card);
  background: var(--panel);
  color: var(--ink-2);
  box-shadow: var(--shadow-lift), 0 0 0 1px var(--line);
  font: 400 13px/1.55 var(--font);
  letter-spacing: 0;
  text-align: left;
  white-space: normal;
  display: none;                    /* 닫혀 있으면 자리도 없이 (안 보이는 말풍선이 화면 밖까지 넓혀 가로 스크롤이 생겨요) */
  translate: var(--shift, 0px) 0;
  transition: opacity 0.15s, translate 0.15s var(--ease);
  pointer-events: none;
}
.help-tip-bubble > * {             /* 옮겨 온 설명 글(p 등)은 말풍선 글자 그대로 */
  margin: 0;
  color: inherit;
  font: inherit;
}
.help-tip.is-open .help-tip-bubble {
  display: block;
}
@starting-style {                    /* 나타날 때 살짝 내려오며 (0.15초) */
  .help-tip-bubble {
    opacity: 0;
    translate: var(--shift, 0px) -4px;
  }
}
@media (hover: hover) and (pointer: fine) {   /* 마우스가 있는 기기: 올리거나 키보드로 오면 */
  .help-tip-btn:hover {
    background: var(--panel-2);
    color: var(--ink);
  }
  .help-tip:hover .help-tip-bubble,
  .help-tip:focus-within .help-tip-bubble {
    display: block;
  }
}
html[data-motion="reduce"] :is(.help-tip-btn, .help-tip-bubble) {
  transition: none;
}
@media (max-width: 1023px) {         /* 패드 · 휴대폰: 누르는 칸 44 (그림 크기 · 제목 줄 높이는 그대로) */
  .help-tip {
    margin: -14px -12px -14px -6px;
  }
  .help-tip-btn {
    width: 44px;
    height: 44px;
  }
  .help-tip.is-open .help-tip-btn {  /* 넓은 누르는 칸이 제목 글자에 겹쳐서 회색 동그라미 대신 그림 색만 진하게 */
    background: transparent;
  }
}
.page-head-note {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
}
.page-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

/* 작은 표지판: 판 제목 등 (그림 네모 24) */
.sign--sm {
  gap: 8px;
  height: 32px;
  padding: 0 12px 0 4px;
  font-size: 15px;
}
.sign--sm .sign-mark {
  width: 24px;
  height: 24px;
}
.sign--sm .sign-mark svg {
  width: 16px;
  height: 16px;
}
/* 글자를 JS가 채우는 판 제목용 작은 표지판: 그림 네모 · 화살표는 ::before · ::after가 그려요 (글자가 바뀌어도 그대로) */
.sign--title,
:is(.panel, .nm-box) .sign--title {
  position: relative;
  display: inline-flex;
  flex: none;
  align-items: center;
  box-sizing: border-box;
  max-width: 100%;
  height: 32px;
  margin: 0;
  padding: 0 12px 0 36px;
  overflow: hidden;
  border-radius: var(--radius-ctl);
  background: var(--sign);
  color: var(--sign-ink);
  font: 800 15px/1 var(--font-ui);
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.sign--title::before,
.sign--title::after {
  content: '';
  position: absolute;
  top: 4px;
  left: 4px;
  width: 24px;
  height: 24px;
}
.sign--title::before {             /* 그림 네모 (표지판 바깥 모서리 - 틈) */
  border-radius: calc(var(--radius-ctl) - 2px);
  background: var(--sign-ink);
}
.sign--title::after {              /* 화살표: PAGE_ICONS.arrow와 같은 선 */
  background: var(--sign);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='M13 6l6 6-6 6'/%3E%3C/svg%3E") center / 16px no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='M13 6l6 6-6 6'/%3E%3C/svg%3E") center / 16px no-repeat;
}

/* 버튼: 주(팀 색 판) · 보통(판 색 + 테두리) · 조용한(바탕 없음) · 위험(빨강). 높이 40, 작게 32(.btn-sm)
   .round-current('이번 라운드' 등)는 옛 페이지 여러 곳이 쓰는 이름이라 작은 보통 버튼과 같은 모양으로 꾸며요 */
.btn-primary,
.btn-plain,
.btn-quiet,
.btn-danger,
.round-current {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  gap: 6px;
  box-sizing: border-box;
  height: 40px;
  margin: 0;
  padding: 0 16px;
  border: 0;
  border-radius: var(--radius-ctl);
  font: 800 15px/1 var(--font-ui);
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s;
}
.btn-sm,
.round-current {
  height: 32px;
  padding: 0 12px;
  font-size: 14px;
}
.btn-primary {
  background: var(--team-strong);
  color: var(--team-ink);
}
.btn-primary:hover {
  background: color-mix(in srgb, var(--team-strong) 88%, #000);
}
.btn-primary:active {
  background: color-mix(in srgb, var(--team-strong) 76%, #000);
}
.btn-plain,
.round-current {
  border: 1.5px solid var(--line-ctl);
  background: var(--panel);
  color: var(--ink);
}
.btn-plain:hover,
.round-current:hover,
.btn-quiet:hover {
  background: var(--panel-2);
}
.btn-plain:active,
.round-current:active,
.btn-quiet:active {
  background: var(--panel-3);
}
.btn-quiet {
  background: transparent;
  color: var(--ink);
}
.btn-danger {
  border: 1.5px solid var(--danger);
  background: var(--panel);
  color: var(--danger);
}
.btn-danger:hover {
  background: color-mix(in srgb, var(--danger) 8%, var(--panel));
}
.btn-danger:active {
  background: color-mix(in srgb, var(--danger) 14%, var(--panel));
}
/* 못 누르는 버튼: 흐리게 + 금지 커서, 올리거나 눌러도 그대로 */
:is(.btn-primary, .btn-plain, .btn-quiet, .btn-danger, .round-current):is(:disabled, [aria-disabled="true"]) {
  opacity: 0.45;
  cursor: not-allowed;
}
.btn-primary:is(:disabled, [aria-disabled="true"]) {
  background: var(--team-strong);
}
:is(.btn-plain, .round-current, .btn-danger):is(:disabled, [aria-disabled="true"]) {
  background: var(--panel);
}
.btn-quiet:is(:disabled, [aria-disabled="true"]) {
  background: transparent;
}

/* 아이콘 버튼: 36 동그라미 (라운드 ‹ ☰ › 버튼은 옅은 회색 바탕) */
.icon-btn,
.panel-icon-btn,
.round-btn,
.round-arrow {
  display: inline-grid;
  flex: none;
  place-items: center;
  box-sizing: border-box;
  width: 36px;
  height: 36px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background-color 0.15s;
}
.round-btn,
.round-arrow {
  background: var(--panel-2);
}
:is(.icon-btn, .panel-icon-btn, .round-btn, .round-arrow) svg {
  width: 20px;
  height: 20px;
}
:is(.round-btn, .round-arrow) svg {   /* HTML에 바로 그린 선 그림 */
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}
:is(.icon-btn, .panel-icon-btn, .round-btn, .round-arrow):hover {
  background: var(--panel-3);
}
:is(.icon-btn, .panel-icon-btn, .round-btn, .round-arrow):active {
  background: color-mix(in srgb, var(--ink) 16%, var(--panel));
}
:is(.icon-btn, .panel-icon-btn, .round-btn, .round-arrow):disabled {
  opacity: 0.35;
  background: transparent;
  cursor: not-allowed;
}
:is(.round-btn, .round-arrow):disabled {
  background: var(--panel-2);
}

/* 고르는 탭 · 칩: 고른 것 = 표지판 색 판(검은 판 · 다크는 흰 판). 넘치면 옆으로 밀어요 */
.chips,
.tab-group,
.mode-toggle {
  display: flex;
  gap: 4px;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}
:is(.chips, .tab-group, .mode-toggle)::-webkit-scrollbar {
  display: none;
}
:is(.chips, .tab-group, .mode-toggle) > button {
  flex: none;
  height: 32px;
  margin: 0;
  padding: 0 12px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font: 800 14px/1 var(--font-ui);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}
:is(.chips, .tab-group, .mode-toggle) > button:not(.active, [aria-pressed="true"], [aria-selected="true"]):hover {
  background: var(--panel-3);
}
:is(.chips, .tab-group, .mode-toggle) > button:is(.active, [aria-pressed="true"], [aria-selected="true"]) {
  background: var(--sign);
  color: var(--sign-ink);
}
:is(.chips, .tab-group, .mode-toggle) > button:focus-visible {   /* 포커스 테두리는 칩 안쪽에 (옆으로 미는 줄이 위아래를 잘라서) */
  outline-offset: -2px;
}

/* 켜기/끄기 스위치: <label class="switch"><input type="checkbox" role="switch"><span>이름</span><span class="switch-track"></span></label>
   사이트에서 하나뿐인 알약 모양. input은 눈에 안 보이게 겹쳐 두고(키보드로 갈 수 있어요) 포커스 테두리는 막대에 */
.switch,
.note-switch {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink-2);
  font: 700 14px/1 var(--font-ui);
  cursor: pointer;
}
/* 이름 자리의 팀 로고 ("우리 팀만" 스위치, common.js fillSwitchBadge) */
.switch-badge {
  display: inline-grid;
}
.switch-badge .team-badge {
  --badge-size: 28px;
}
:is(.switch, .note-switch) input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.switch-track {
  position: relative;
  flex: none;
  width: 40px;
  height: 24px;
  border-radius: 12px;
  background: var(--line-ctl);
  transition: background-color 0.15s;
}
.switch-track::after {             /* 동그라미 */
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #FFFFFF;
  transition: transform 0.15s var(--ease);
}
:is(.switch, .note-switch):hover input:not(:checked) ~ .switch-track {
  background: color-mix(in srgb, var(--line-ctl) 80%, var(--ink));
}
:is(.switch, .note-switch) input:checked ~ .switch-track {
  background: var(--team-strong);
}
:is(.switch, .note-switch):hover input:checked ~ .switch-track {
  background: color-mix(in srgb, var(--team-strong) 88%, #000);
}
:is(.switch, .note-switch) input:checked ~ .switch-track::after {
  background: var(--team-ink);
  transform: translateX(16px);
}
:is(.switch, .note-switch) input:focus-visible ~ .switch-track {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
}
html[data-motion="reduce"] .switch-track,
html[data-motion="reduce"] .switch-track::after {
  transition: none;
}

/* 입력칸: 이름표는 위, 칸은 아래 (안내 글을 이름표 대신 쓰지 않아요) */
.field {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  color: var(--ink-2);
  font: 700 14px/1.3 var(--font-ui);
}
.field :is(textarea, select, input:not([type="checkbox"], [type="radio"])) {
  box-sizing: border-box;
  width: 100%;
  min-height: 40px;
  margin: 0;
  padding: 8px 12px;
  border: 1.5px solid var(--line-ctl);
  border-radius: var(--radius-ctl);
  background: var(--panel);
  color: var(--ink);
  font: 400 15px/1.6 var(--font);
  transition: border-color 0.15s, box-shadow 0.15s;
}
.field :is(select, input:not([type="checkbox"], [type="radio"])) {
  height: 40px;
}
.field textarea {
  resize: vertical;
}
.field select {
  cursor: pointer;
}
.field :is(textarea, input)::placeholder {
  color: var(--muted);
}
.field :is(textarea, select, input:not([type="checkbox"], [type="radio"])):hover {
  border-color: var(--ink-2);
}
.field :is(textarea, select, input:not([type="checkbox"], [type="radio"])):focus {
  border-color: var(--team-text);
  outline: none;
  box-shadow: 0 0 0 1px var(--team-text);   /* 테두리를 한 겹 더 (포커스가 잘 보이게) */
}

/* 시간표 목록 (표 · 목록 공통): 맨 위 굵은 선, 줄 사이 가는 선 — 경기장 전광판의 시간표처럼 */
.timetable {
  margin: 0;
  padding: 0;
  border-top: 2px solid var(--rule);
  list-style: none;
  font-variant-numeric: tabular-nums;
}
table.timetable {
  width: 100%;
  border-collapse: collapse;
}
table.timetable :is(th, td) {
  border-bottom: 1px solid var(--line);
}
table.timetable thead th {
  color: var(--muted);
  font: 700 13px/1.3 var(--font-ui);
  white-space: nowrap;
}
:is(ul, ol).timetable > li {
  border-bottom: 1px solid var(--line);
}
:is(ul, ol).timetable > li:last-child,
table.timetable tbody tr:last-child td {
  border-bottom: 0;
}
.timetable :is(.mine, .my-team) {
  background: var(--team-soft);
}

/* ═══ 12. 커뮤니티 부품: 검색칸 · 페이지 번호 · 말머리 태그 · 글 목록 줄 · 글쓴이 · 프로필 그림 · 빈 칸 · 목록으로 · 오류 글 · 신고 창 · 배지 팝업 ═══
   게시판 · 글 보기 · 글쓰기 · 유저 페이지 · 뉴스가 같이 써요 (줄 · 신고 창 · 배지 팝업은 js/board-store.js, 프로필 그림은 js/avatar.js가 만들어요) */

/* 검색칸: 입력칸 + 돋보기 버튼이 한 덩어리. 올리면 테두리 진하게, 글을 칠 때는 팀 색 테두리 */
/* 검색칸 (2026-11-14 사용자 요청: 인스타그램 검색줄처럼 테두리 없이 안까지 한 가지 색) — 페이지 바탕보다 한 단계 짙은 단색.
   글을 칠 때만 가는 테두리(글자색 계열)로 지금 쓰는 칸을 알려 줘요 */
.site-search {
  --search-fill: color-mix(in srgb, var(--ink) 7%, var(--ground));
  display: flex;
  align-items: center;
  box-sizing: border-box;
  width: min(320px, 100%);
  height: 40px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: var(--search-fill);
  overflow: hidden;
  transition: box-shadow 0.15s;
}
.site-search:focus-within {
  box-shadow: inset 0 0 0 1.5px var(--ink-2);
}
.site-search input {
  flex: 1;
  min-width: 0;
  height: 100%;
  margin: 0;
  padding: 0 0 0 12px;
  border: 0;
  outline: none;
  background: none;
  color: var(--ink);
  font: 15px/1.4 var(--font);
}
.site-search input::placeholder {
  color: var(--muted);
}
.site-search input::-webkit-search-cancel-button {   /* 브라우저 기본 ✕는 숨기고 사이트 ✕ 버튼(.site-search-clear, common.js setupSearchClear)을 써요 */
  display: none;
  -webkit-appearance: none;
  appearance: none;
}
/* ✕(지우기): 글자가 있을 때만, 돋보기 왼쪽 동그라미 버튼 (돋보기와 같은 크기 · 반응, 그림은 조금 작게) */
.site-search-clear {
  display: grid;
  flex: none;
  place-items: center;
  width: 32px;
  height: 32px;
  margin: 0 2px 0 4px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color 0.15s;
}
.site-search-clear[hidden] {
  display: none;
}
.site-search-clear:hover {
  background: color-mix(in srgb, var(--ink) 6%, var(--search-fill));
}
.site-search-clear:active {
  background: color-mix(in srgb, var(--ink) 12%, var(--search-fill));
}
.site-search-clear:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.site-search-clear svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}
.site-search-button {
  display: grid;
  flex: none;
  place-items: center;
  width: 36px;
  height: 36px;
  margin-right: 1px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color 0.15s;
}
.site-search-button:hover {
  background: color-mix(in srgb, var(--ink) 6%, var(--search-fill));
}
.site-search-button:active {
  background: color-mix(in srgb, var(--ink) 12%, var(--search-fill));
}
.site-search-button:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.site-search-button svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

/* 페이지 번호: 네모 칸 36, 지금 쪽 = 표지판 색 (올려도 그대로) */
.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
  margin-top: 24px;
}
.pagination:empty {
  display: none;
}
.pagination button {
  box-sizing: border-box;
  min-width: 36px;
  height: 36px;
  margin: 0;
  padding: 0 8px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font: 800 14px/1 var(--font-ui);
  font-variant-numeric: tabular-nums;
  cursor: pointer;
  transition: background-color 0.15s;
}
.pagination button:not(.active, [aria-current="page"]):hover {
  background: var(--panel-3);
}
.pagination button:not(.active, [aria-current="page"]):active {
  background: color-mix(in srgb, var(--ink) 16%, var(--panel));
}
.pagination button:is(.active, [aria-current="page"]) {
  background: var(--sign);
  color: var(--sign-ink);
}
.pagination button:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
}
.pagination-gap {
  display: grid;
  place-items: center;
  min-width: 24px;
  height: 36px;
  color: var(--muted);
  font-weight: 800;
}

/* 말머리 태그 (목록 · 글 보기): 사이트 태그 모양, 공지 = 팀 색 판 */
.flair {
  display: inline-flex;
  flex: none;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  height: 24px;
  padding: 0 8px;
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font: 700 13px/1 var(--font-ui);
  white-space: nowrap;
}
.post-row .flair {
  min-width: 3.4em;                /* 목록에서는 폭을 맞춰서 제목이 가지런히 */
}
.pinned .flair,
.flair[data-flair="notice"] {
  background: var(--team-strong);
  color: var(--team-ink);
}

/* 글 목록 (게시판 · 유저 페이지): 시간표 모양(.timetable) 줄 — [말머리] 제목 ------ 조회 · 좋아요 · 댓글(팀 색) · 시간 */
.post-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.post-list > li {
  border-bottom: 1px solid var(--line);
}
.post-list > li:last-child {
  border-bottom: 0;
}
.post-list li.pinned {             /* 고정 글(공지 · 평점 글) */
  background: var(--team-soft);
}
.post-row {
  display: flex;
  align-items: center;
  gap: 16px;
  box-sizing: border-box;
  min-height: 52px;
  padding: 8px 12px;
  color: var(--ink);
  text-decoration: none;
  transition: background-color 0.15s;
}
.post-row:hover {                  /* 옅은 막 (공지 줄 색 위에서도 똑같이) */
  background: color-mix(in srgb, var(--ink) 5%, transparent);
}
.post-row:active {
  background: color-mix(in srgb, var(--ink) 9%, transparent);
}
.post-row:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.post-main {
  display: flex;
  flex: 1;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.post-title {
  min-width: 0;
  overflow: hidden;
  font: 600 16px/1.4 var(--font);
  white-space: nowrap;
  text-overflow: ellipsis;
}
.pinned .post-title {
  font-weight: 700;
}
.post-stats {
  display: flex;
  flex: none;
  align-items: center;
  gap: 12px;
  color: var(--muted);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.post-stat-comments {
  color: var(--team-text);
  font-weight: 700;
}

/* 정렬 버튼 (게시판 목록 · 댓글): 버튼 하나(최신순 ↔ 인기순) + 오른쪽 작은 위아래 화살표 그림 = "누르면 바뀌어요" */
.sort-toggle {
  gap: 4px;
}
.sort-toggle::after {
  content: '';
  flex: none;
  width: 16px;
  height: 16px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 4v16M4 8l4-4 4 4M16 20V4M12 16l4 4 4-4'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M8 4v16M4 8l4-4 4 4M16 20V4M12 16l4 4 4-4'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* 글쓴이: (프로필 그림) 닉네임 [배지] — 회원이면 누르면 그 사람 페이지 */
.author-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  color: var(--ink);
  font: 700 14px/1.3 var(--font-ui);
  text-decoration: none;
}
.author-name {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
a.author-link:hover .author-name {
  text-decoration: underline;
  text-underline-offset: 3px;
}
a.author-link:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
  border-radius: var(--radius-ctl);
}

/* 프로필 그림 (그림 자체는 js/avatar.js): 동그라미 + 옅은 바탕. 크기 28 · 40 · 104 · 132 (배지 크기 단계) */
.avatar {
  display: inline-block;
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--avatar-bg);
  vertical-align: middle;
}
.avatar .av-fig {                  /* 실루엣 색 (js/avatar.js 기본 모습) */
  fill: var(--avatar-fig);
}
.avatar svg {
  display: block;
  width: 100%;
  height: 100%;
}
.avatar-sm {
  width: 28px;
  height: 28px;
}
.avatar-md {
  width: 40px;
  height: 40px;
}
.avatar-lg {
  width: 104px;
  height: 104px;
}
.avatar-xl {
  width: 132px;
  height: 132px;
}

/* 빈 · 오류 칸: 판 안 가운데 짧은 문구 (판 밖에 홀로 있으면 .panel도 같이 붙여요) */
.empty-note {
  margin: 0;
  padding: 40px 16px;
  color: var(--ink-2);
  font: 700 15px/1.5 var(--font);
  text-align: center;
}

/* 목록으로 · 게시판으로: 조용한 작은 버튼(.btn-quiet.btn-sm) + 앞에 그린 ‹ (PAGE_ICONS.back과 같은 선) */
.back-link {
  align-self: flex-start;
  gap: 4px;
  padding-left: 6px;
  color: var(--ink);
  text-decoration: none;
}
.back-link::before {
  content: '';
  flex: none;
  width: 18px;
  height: 18px;
  background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 5l-7 7 7 7'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M15 5l-7 7 7 7'/%3E%3C/svg%3E") center / contain no-repeat;
}

/* 오류 글: 무엇이 안 됐는지 한 줄 (빨강, 굵게) */
.error-message {
  margin: 0;
  color: var(--danger);
  font: 700 14px/1.5 var(--font);
}

/* 게시판 쪽 체크 · 동그라미 선택칸: 팀 색 */
.board-area :is(input[type="checkbox"], input[type="radio"]) {
  flex: none;
  width: 18px;
  height: 18px;
  margin: 0;
  accent-color: var(--team-strong);
}

/* 신고 창 (js: board-store.js의 openReportDialog): 이유 줄 44 · 이유를 고르면 차단 칸 · 등록 버튼 폭 가득 */
#report-dialog {
  --dialog-w: 440px;
}
.report-reasons {
  margin: 12px 0;
  padding: 0;
  list-style: none;
}
.report-reasons li {
  border-bottom: 1px solid var(--line);
}
.report-reasons li:last-child {
  border-bottom: 0;
}
.report-reasons label,
.block-option {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--ink);
  font: 600 15px/1.4 var(--font);
  cursor: pointer;
}
.block-option {
  margin: 0 0 12px;
  border-top: 1px solid var(--line);
}
#report-form .error-message {
  margin-bottom: 12px;
}
#report-form [type="submit"] {
  width: 100%;
}

/* 배지 팝업 (js: board-store.js의 showBadgePopup): 새로 얻은 배지 줄 */
.badge-dialog {
  --dialog-w: 400px;
}
.badge-dialog p {
  margin: 12px 0 0;
  color: var(--ink);
  font: 700 15px/1.5 var(--font);
}

/* ═══ 13. 나머지 페이지 부품: 고르는 칩 · 세로 칩 · 도움말 · 알림 · 버튼 줄 · 옆으로 밀기 · 정보 목록 ═══
   설정 · 게임(공 승부 · 3D 축구 · 맞히기) · 선수 · 자료실이 같이 써요 (옛 이름 그대로) */

/* 고르는 칩: <div class="choice-row"><label class="choice"><input type="radio"><span>이름</span></label>…</div>
   진짜 라디오 묶음이라 ← → 로 골라요. 라디오는 눈에 안 보이게 겹쳐 두고, 고른 칩 = 표지판 색 · 포커스 테두리는 칩 안쪽 */
.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-width: 0;
}
.choice {
  position: relative;
  display: inline-flex;
  flex: none;
  align-items: center;
  box-sizing: border-box;
  height: 32px;
  padding: 0 12px;
  border-radius: var(--radius-ctl);
  background: var(--panel-2);
  color: var(--ink-2);
  font: 800 14px/1 var(--font-ui);
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s;
}
.choice input {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}
.choice:not(:has(input:checked, input:disabled)):hover {
  background: var(--panel-3);
}
.choice:has(input:checked) {
  background: var(--sign);
  color: var(--sign-ink);
}
.choice:has(input:focus-visible) {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.choice:has(input:disabled) {
  opacity: 0.45;
  cursor: not-allowed;
}
.choice-column {                   /* 세로 칩: 한 줄씩 (설명이 긴 모드 고르기) */
  flex-direction: column;
  flex-wrap: nowrap;
}
.choice-column .choice {
  height: auto;
  min-height: 44px;
  padding: 10px 12px;
  line-height: 1.35;
  white-space: normal;
}
html[data-motion="reduce"] .choice {
  transition: none;
}

/* 도움말(짧은 설명) · 알림(저장 완료 · 오류) · 버튼 줄 */
.settings-note {
  margin: 6px 0 0;
  color: var(--ink-2);
  font: 14px/1.5 var(--font);
}
.settings-message {                /* 비면 높이 0 (role=status 자리는 그대로) */
  margin: 0;
  color: var(--ink);
  font: 700 14px/1.5 var(--font);
}
.settings-message.error {
  color: var(--danger);
}
.note-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
}

/* 옆으로 밀기 칸 (넓은 표) */
.table-scroll {
  overflow-x: auto;
  scrollbar-width: thin;
}

/* 팀 바꾸기: 페이지 머리 오른쪽의 [배지 · 팀 이름 ▾] 버튼 + 펼치는 20팀 목록 (선수 · 팀 페이지, js: common.js의 setupTeamSwitch)
   <div class="team-picker"><button class="team-switch">…</button><ul class="team-menu"></ul></div> */
.team-picker {
  position: relative;
}
.team-switch {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-sizing: border-box;
  max-width: 100%;
  height: 48px;
  padding: 0 12px 0 8px;
  border: 1px solid var(--line-ctl);
  border-radius: var(--radius-ctl);
  background: var(--panel);
  color: var(--ink);
  font: 800 18px/1 var(--font-title);
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: background-color 0.15s;
}
.team-switch:hover {
  background: var(--panel-2);
}
.team-switch:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: 2px;
}
.team-switch .team-badge {
  --badge-size: 32px;   /* 배지 크기는 이 값 하나로 (글자 크기도 따라가요) */
}
.team-switch-name {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.team-switch-arrow {               /* ▾ 글자 대신 그린 꺾쇠 (열리면 위로) */
  flex: none;
  width: 16px;
  height: 16px;
  overflow: hidden;
  background: var(--ink-2);
  color: transparent;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23000' stroke-width='2.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform 0.2s var(--ease);
}
.team-switch[aria-expanded="true"] .team-switch-arrow {
  transform: rotate(180deg);
}
.team-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 30;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2px;
  box-sizing: border-box;
  width: min(440px, 100vw - 2 * var(--page-gutter));
  margin: 0;
  padding: 8px;
  border-radius: var(--radius-panel);
  background: var(--panel);
  box-shadow: var(--shadow-lift), 0 0 0 1px var(--line);
  list-style: none;
  transform-origin: top right;
  transition: opacity 0.18s var(--ease), translate 0.18s var(--ease);
}
@starting-style {
  .team-menu {
    opacity: 0;
    translate: 0 -6px;
  }
}
.team-menu button {
  display: flex;
  align-items: center;
  gap: 10px;
  box-sizing: border-box;
  width: 100%;
  min-height: 40px;
  padding: 6px 10px;
  border: 0;
  border-radius: var(--radius-ctl);
  background: transparent;
  color: var(--ink-2);
  font: 700 14px/1.3 var(--font-ui);
  text-align: left;
  cursor: pointer;
}
.team-menu button:hover {
  background: var(--panel-2);
  color: var(--ink);
}
.team-menu button:focus-visible {
  outline: 2px solid var(--team-text);
  outline-offset: -2px;
}
.team-menu button.current {
  background: var(--sign);
  color: var(--sign-ink);
}
.team-menu .team-badge {
  flex: none;
  --badge-size: 26px;
}
html[data-motion="reduce"] :is(.team-menu, .team-switch-arrow) {
  transition: none;
}

/* 승 · 무 · 패 작은 사각 칩 (순위표 최근 5경기 · 팀 페이지): 글자가 있어서 색을 못 봐도 읽혀요 */
.form-box {
  display: inline-grid;
  flex: none;                      /* 칸이 좁아도 22px 그대로 */
  place-items: center;
  width: 22px;
  height: 22px;
  border-radius: var(--radius-ctl);
  color: #FFFFFF;
  font: 800 12px/1 var(--font-ui);
}
.form-W { background: var(--win); }
.form-D { background: var(--draw); }
.form-L { background: var(--loss); }

/* 정보 목록 (dl): 이름 | 값, 줄 사이 가는 선 */
.info-list {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  margin: 0;
}
.info-list :is(dt, dd) {
  margin: 0;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}
.info-list dt {
  padding-right: 16px;
  color: var(--muted);
  font: 700 13px/1.5 var(--font-ui);
}
.info-list dd {
  color: var(--ink);
  font: 15px/1.5 var(--font);
  overflow-wrap: anywhere;
}
.info-list :is(dt, dd):nth-last-child(-n + 2) {
  border-bottom: 0;
}

/* PC 한 화면 틀 (홈 · 경기 · 승부예측의 main.fit-screen, 2026-11-01): PC(폭 1024 이상)에서는 스크롤 없이 한 화면
   높이가 낮은 화면일수록 아래 여백 · 판 간격을 줄이고, --fit-h(메뉴 · 위아래 여백을 뺀 높이)에 페이지 칸들을 맞춰요. 높이 580보다 낮은 창만 스크롤
   페이지 이름 · 첫 칸 시작 위치는 줄이지 않아요 (자료실과 같게). 아래 끝은 한 화면 페이지끼리 같아요 (--page-bottom 위)
   main의 높이를 정할 때 --fit-h가 위아래 여백을 뺀 값이라, 칸 높이에 여백을 더하지 않게 content-box로 재요 */
.fit-screen {
  box-sizing: content-box;
  --page-bottom: 32px;
  --fit-h: calc(100dvh - var(--menu-h) - var(--page-top) - var(--page-bottom) - var(--tabbar-h));
  --sign-h: 48px;                  /* 페이지 이름 줄 높이: 이 값으로 칸 높이를 계산해요 */
}
@media (min-width: 1024px) and (max-height: 799px) {
  .fit-screen {
    --page-bottom: 24px;
    --panel-gap: 16px;
  }
}
@media (min-width: 1024px) and (max-height: 699px) {
  .fit-screen {
    --page-bottom: 16px;
    --panel-gap: 12px;
    --panel-pad: 16px;
  }
}

/* 평점 알약 (js: common.js의 makeRatingChip, 단계 = ratingTier) — 크기 · 자리는 쓰는 곳에서 */
.rating-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--rating-bg);
  color: var(--rating-ink);
  font-family: var(--font-num);
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  line-height: 1;
  white-space: nowrap;
}
.rating-chip[data-tier="top"]  { --rating-bg: var(--rating-top);  --rating-ink: var(--rating-top-ink); }
.rating-chip[data-tier="good"] { --rating-bg: var(--rating-good); --rating-ink: var(--rating-good-ink); }
.rating-chip[data-tier="ok"]   { --rating-bg: var(--rating-ok);   --rating-ink: var(--rating-ok-ink); }
.rating-chip[data-tier="low"]  { --rating-bg: var(--rating-low);  --rating-ink: var(--rating-low-ink); }
.rating-chip[data-tier="poor"] { --rating-bg: var(--rating-poor); --rating-ink: var(--rating-poor-ink); }

/* ═══ 맨 끝. 작은 화면 ═══
   화면 단계: 1199 이하(노트북 · 아이패드 가로) · 1023 이하(아이패드 세로) · 640 이하(휴대폰)
   틀 숫자만 바꾸면 메뉴 · 내용이 같은 숫자를 써서 양 끝이 계속 맞아요. 부분별 작은 화면 규칙도 여기 아래에 모아요. */
@media (max-width: 1199px) {
  :root {
    --page-gutter: 24px;
  }
}
@media (max-width: 1023px) {
  :root {
    --band-h: 56px;         /* 팀 색 띠 (로고 · 동그라미 버튼) */
    --row-h: 0px;           /* 띠 아래 흰 메뉴 줄 없음 (2026-11-12, 패드는 띠에 주요 4곳 + '더 보기') */
  }
  .plus-guest-login {
    min-height: 44px;       /* 손님 막대 로그인: 누르는 칸 44 */
  }
}
@media (max-width: 640px) {
  :root {
    --page-gutter: 16px;
    --row-h: 0px;           /* 휴대폰은 메뉴 줄 대신 ☰ 메뉴판 */
    --tabbar-h: calc(64px + env(safe-area-inset-bottom));   /* 아래 탭 막대 (아이폰 아래 여백 포함) */
    --panel-gap: 12px;
    --panel-pad: 16px;
  }
}

/* ── 위쪽 메뉴: 아이패드 세로(641~1023) = 띠에 주요 4곳 + '더 보기' (js fitBand가 늘 .is-tight) ── */
@media (max-width: 1023px) {
  .menu-band {
    gap: 16px;
  }
  .menu-links .menu-divider {
    margin: 0 6px;
  }
  .menu-links a,
  .menu-more {
    padding: 0 10px;
    font-size: 16px;
  }
  .menu-more {
    padding-right: 8px;
  }
  /* 좁은 패드: 휴대폰처럼 알림 · ☰만 ('더 보기' 7개 · 구독 · 공유 · FAQ · 설정은 ☰ 메뉴판에) */
  .menu-band.is-crowded .menu-more,
  .menu-band.is-crowded .menu-links .menu-divider,
  .menu-band.is-crowded .menu-small > :not(.menu-bell) {
    display: none;
  }
  .menu-band.is-crowded .menu-toggle {
    display: grid;
  }
}
/* ── 휴대폰: 띠에는 메뉴가 없어요 (아래 탭 막대 + ☰ 메뉴판) ── */
@media (max-width: 640px) {
  .menu-band .menu-links,
  .menu-band .menu-divider {
    display: none;
  }
}

/* ── 휴대폰 메뉴: 띠에는 로고 · 알림 · ☰만, 아래 탭 막대 ── */
@media (max-width: 640px) {
  .menu-band {
    gap: 12px;
  }
  .menu-small > :not(.menu-bell) {
    display: none;          /* 구독 · 공유 · FAQ · 설정은 ☰ 메뉴판으로 */
  }
  .menu-toggle {
    display: grid;
  }
  .tab-bar {
    display: grid;
  }
}

/* ── 알림 창 · 팝업 · 고정 버튼: 휴대폰 ── */
@media (max-width: 640px) {
  .notice-panel,
  html.no-scrollbar .notice-panel {
    right: 16px;
    left: 16px;
    width: auto;
  }
  /* 팝업은 아래에서 올라오는 판 (위 모서리만 둥글게) */
  .match-dialog {
    inset: auto 0 0;
    width: 100%;
    max-width: none;
    max-height: 85dvh;
    margin: 0;
    padding-bottom: calc(24px + env(safe-area-inset-bottom));
    border-radius: var(--radius-sheet) var(--radius-sheet) 0 0;
    scale: 1;
    translate: 0 0;
  }
  .match-dialog:not([open]) {
    opacity: 1;
    scale: 1;
    translate: 0 100%;
  }
  @starting-style {
    .match-dialog[open] {
      opacity: 1;
      scale: 1;
      translate: 0 100%;
    }
  }
  /* 손잡이 막대: 판을 잡고 아래로 끌면 닫힌다는 표시 (☰ 메뉴판과 같은 모양, 2026-11-17 사용자 요청) */
  .match-dialog::before {
    content: "";
    position: absolute;
    top: 8px;
    left: 50%;
    z-index: 3;
    width: 40px;
    height: 4px;
    margin-left: -20px;
    border-radius: 2px;
    background: var(--line-ctl);
    pointer-events: none;
  }
  /* 휴대폰은 X 버튼이 안 보여요: 바깥 누르기 · 아래로 끌기 · 뒤로 가기(Esc)로 닫아요. 화면 읽기 프로그램용으로는 남아요 */
  dialog.match-dialog .dialog-close,
  .menu-sheet .menu-sheet-close {
    position: absolute;
    width: 1px;
    height: 1px;
    margin: -1px;
    padding: 0;
    overflow: hidden;
    border: 0;
    clip-path: inset(50%);
    white-space: nowrap;
    box-shadow: none;
  }
  .dev-clock {
    bottom: calc(var(--tabbar-h) + 12px);
    left: 8px;
    font-size: 12px;
  }
  .staff-return {
    right: 12px;
    bottom: calc(var(--tabbar-h) + 12px);
  }
}

/* ── 페이지 부품: 휴대폰 ── */
@media (max-width: 640px) {
  .page-sign {
    --sign-h: 40px;
    --sign-font: 32px;
    --sign-icon: 30px;
    gap: 10px;
  }
  .page-tools {                    /* 도구는 표지판 아래 한 줄 전체 */
    flex-basis: 100%;
    margin-left: 0;
  }
  table.timetable tbody td {       /* 손가락으로 누르기 쉬운 높이 */
    height: 44px;
  }
}
/* 커뮤니티 부품: 휴대폰 (글 줄 두 칸 — 1줄 말머리 + 제목, 2줄 작은 정보. 좁은 휴대폰 · 큰 숫자면 정보가 다음 줄로) */
@media (max-width: 640px) {
  .post-row {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
    min-height: 64px;
    padding: 10px 4px;
  }
  .post-stats {
    flex-wrap: wrap;
    gap: 2px 10px;
  }
}
/* 패드 · 휴대폰(손가락): 누르는 곳은 모두 44px 이상 (설계 "같은 사이트" 3-4)
   버튼 · 칩 · 탭 · 페이지 번호 · 동그라미 화살표 · 메뉴 줄은 높이 44로, 메뉴 띠의 동그라미(보이는 36)는 누르는 칸만 44로 넓혀요.
   모양(색 · 모서리 · 글자)은 PC와 같고 크기만 달라요. 검색칸은 칸 전체(44)를 눌러도 입력할 수 있어요 */
@media (max-width: 1023px) {
  .btn-primary,
  .btn-plain,
  .btn-quiet,
  .btn-danger,
  .round-current,
  .btn-sm {
    height: 44px;
  }
  :is(.chips, .tab-group, .mode-toggle) > button,
  .choice {
    min-width: 44px;
    height: 44px;
  }
  .pagination button {
    min-width: 44px;
    height: 44px;
  }
  .pagination-gap {
    height: 44px;
  }
  .round-btn,
  .round-arrow {
    width: 44px;
    height: 44px;
  }
  .dialog-close {
    width: 44px;
    height: 44px;
  }
  .site-search {
    height: 44px;
  }
  .site-search-button {
    width: 40px;
    height: 40px;
  }
  .site-search-clear {             /* 손가락: 보이는 동그라미 32, 누르는 칸은 칸 높이(44) 가득 */
    width: 36px;
    height: 44px;
    margin: 0;
    border-radius: 0;
  }
  .site-search-clear:is(:hover, :active) {
    background: transparent;
  }
  .switch,
  .note-switch {
    min-height: 44px;
  }
  .menu-links a,
  .menu-more {
    height: 44px;
  }
  .menu-logo {
    padding-block: 7px;     /* 로고 그림(30)은 그대로, 누르는 칸만 44 */
    padding-right: 12px;    /* 파코어 로고(정사각형 30)는 폭도 좁아서 오른쪽만 넓혀 누르는 칸 44 × 44 (로고 왼쪽 끝 = 내용 왼쪽 끝 그대로) */
  }
  .menu-circle,
  .menu-toggle {
    position: relative;
  }
  .menu-circle::before,
  .menu-toggle::before {    /* 보이는 동그라미 36 둘레 4px까지 누르는 칸 (이웃 동그라미와는 8px 떨어져 있어서 겹치지 않아요) */
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
  }
  .menu-circle::before {
    inset: -5.5px;          /* 동그라미 테두리(1.5px) 안쪽이 기준이라 그만큼 더 */
  }
  /* ☰ (2026-11-14 피드백): 세 줄의 오른쪽 끝 = 페이지 오른쪽 끝(내용 · 검색칸 끝) → 칸을 줄 폭(18)으로 줄이고,
     알림 동그라미와의 틈은 16 (띠 gap 12 + 4). 누르는 칸은 왼쪽 10.5 + 오른쪽 옆 여백(16)까지 넓혀 44 (알림 칸과 안 겹쳐요).
     칸이 좁아서 눌렀을 때 바탕색 대신 줄이 살짝 흐려져요 */
  .menu-toggle {
    width: 18px;
    margin-left: 4px;
  }
  .menu-toggle::before {
    inset: -4px calc(-1 * var(--page-gutter)) -4px -10.5px;
    border-radius: 0;
  }
  .menu-toggle:hover,
  .menu-toggle:active {
    background: transparent;
  }
  .menu-toggle:active span {
    opacity: 0.6;
  }
  /* 2단계 (2026-11-11): 입력 칸 · 고르기 칸 · 아이콘 버튼도 44 (보이는 모양은 같고 칸 크기만) */
  [data-ui="site"] :is(input:not([type="checkbox"], [type="radio"], [type="hidden"], [type="range"]), select) {
    min-height: 44px;
  }
  .site-search input {
    min-height: 0;          /* 검색칸은 바깥 칸(44)이 누르는 곳 */
  }
  .icon-btn,
  .panel-icon-btn {
    min-width: 44px;
    min-height: 44px;
  }
}

/* ── 팀 바꾸기: 휴대폰 = 페이지 이름과 같은 줄 오른쪽, 테두리 · 바탕 없는 글자 버튼(누르는 칸은 알약 모양 44), 목록은 화면 폭 판 ──
   목록이 떠 있는 동안 뒤 화면은 스크롤 안 돼요 (setupTeamSwitch가 <html>에 .team-menu-open, 2026-11-13 피드백) */
@media (max-width: 640px) {
  .page-head:has(.team-picker) {
    flex-wrap: nowrap;
  }
  .page-head:has(.team-picker) .page-tools {
    flex: 0 1 auto;
    flex-basis: auto;
    min-width: 0;
    margin-left: auto;
  }
  .team-picker {
    min-width: 0;
  }
  .team-switch {
    gap: 6px;
    height: 44px;
    padding: 0 8px 0 6px;
    border-color: transparent;
    border-radius: 999px;
    background: transparent;
    font-size: 16px;
  }
  .team-switch:hover,
  .team-switch[aria-expanded="true"] {
    background: transparent;
  }
  .team-switch:active {
    background: var(--panel-2);
  }
  .team-switch .team-badge {
    --badge-size: 28px;
  }
  .team-menu {
    position: fixed;
    top: auto;
    right: var(--page-gutter);
    left: var(--page-gutter);
    width: auto;
    max-height: calc(100dvh - var(--menu-h) - var(--tabbar-h) - 96px);
    margin-top: 8px;
    overflow-y: auto;
    overscroll-behavior: contain;
  }
  html.team-menu-open,
  html.team-menu-open body {
    overflow: hidden;
  }
}
/* ═══ 폰 · 패드: 누른 뒤 윤곽선 없음 (2026-11-14 사용자 결정, 사이트 전체) ═══
   손가락 · 마우스로 누른 버튼 · 링크 · 고르는 칸에는 포커스 테두리(윤곽선)를 그리지 않아요.
   키보드 Tab으로 다니면 common.js가 <html data-input="keyboard">로 바꿔서 그대로 보여요 (키보드 쓰는 사람이 어디 있는지 알 수 있게).
   글을 쓰는 입력칸의 테두리는 그대로 (어디에 쓰고 있는지 보여야 해서). 다른 규칙보다 앞서야 해서 !important */
@media (max-width: 1023px) {
  html {
    -webkit-tap-highlight-color: transparent;   /* 누를 때 칸이 번쩍 보이지 않게 */
  }
  html:not([data-input="keyboard"]) :is(button, a, select, summary, label, [role="button"], [role="tab"], [tabindex]):is(:focus, :focus-visible),
  html:not([data-input="keyboard"]) :is(.choice, .club-section, .home-box, .profile-rank-mode) {   /* 안쪽 버튼이 골라지면 바깥 칸에 테두리를 그리던 곳 */
    outline: none !important;
  }
  html:not([data-input="keyboard"]) .player-spot.editable:focus-visible:not(.selected) {   /* 경기장 선수 점: 테두리 대신 그림자 고리 */
    box-shadow: none;
  }
}

/* ═════════════════════════════════════════════
   손님 (로그인 전에 팀만 고른 사람, 2026-11-26): 메뉴 띠의 '팀 바꾸기' · 로그인 알약 / 로그인 팝업 / 사이트 안내
   색은 css/skins/clean/site.css. 손님 홈만 써요 (js/common.js getHomeVisitor · js/pages/home-tour.js)
   ═════════════════════════════════════════════ */
.menu-guest-team {
  flex: none;
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 4px;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 700;
  color: inherit;
  text-decoration: none;
  white-space: nowrap;
}
.menu-guest-login {
  flex: none;
  height: 36px;
  padding: 0 16px;
  border: 0;
  border-radius: 999px;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, transform 0.16s var(--ease);
}
.menu-guest-login:active {
  transform: scale(0.97);
}
.menu-band:has(.menu-guest-login) .menu-small:empty {
  display: none;
}
.menu-band:has(.menu-guest-login) .menu-guest-team {
  margin-left: auto;          /* 손님 메뉴에는 동그라미가 없어서 '팀 바꾸기'부터 오른쪽 끝으로 */
}
/* 손님 홈의 게시판 칸: 잠금 모양 없이 가운데 '로그인 후 이용가능' */
.home-guest-note {
  font-weight: 700;
}

/* 로그인 팝업: 화면 가운데 (휴대폰도 가운데, 아래에서 올라오는 판이 아니에요). 안은 로그인 페이지(iframe) */
.login-pop {
  width: min(440px, calc(100vw - 32px));
  height: min(700px, calc(100vh - 32px));
  max-width: none;
  max-height: none;
  margin: auto;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 16px;
}
@supports (height: 100svh) {
  .login-pop {
    height: min(700px, calc(100svh - 32px));
  }
}
.login-pop-frame {
  display: block;
  width: 100%;
  height: 100%;
  border: 0;
}
.login-pop-frame.is-resetting {
  visibility: hidden;          /* 약관 → 로그인 화면으로 되돌리는 동안 (common.js resetLoginFrame) */
}
.login-pop-close {
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}
.login-pop-close svg {
  width: 22px;
  height: 22px;
}
.login-pop[open] {
  animation: login-pop-in 0.22s cubic-bezier(0.23, 1, 0.32, 1);
}
@keyframes login-pop-in {
  from { opacity: 0; transform: scale(0.97); }
}
html[data-motion="reduce"] .login-pop[open] {
  animation: none;
}

/* 사이트 안내: 화면 전체를 덮는 막 + 가리키는 칸 자리의 구멍 + 말풍선 (2026-11-27 마스코트 없앰)
   말풍선 밖 어디를 눌러도 다음 단계라서 손가락 모양 (js/pages/home-tour.js) */
.tour {
  position: fixed;
  inset: 0;
  z-index: 300;
  cursor: pointer;
}
.tour-hole {
  position: fixed;
  border-radius: calc(var(--radius-panel) + 4px);
  pointer-events: none;
  transition: left 0.35s cubic-bezier(0.77, 0, 0.175, 1), top 0.35s cubic-bezier(0.77, 0, 0.175, 1),
    width 0.35s cubic-bezier(0.77, 0, 0.175, 1), height 0.35s cubic-bezier(0.77, 0, 0.175, 1);
}
.tour-card {
  position: fixed;
  width: min(380px, calc(100vw - 24px));
  cursor: auto;
  transition: left 0.35s cubic-bezier(0.77, 0, 0.175, 1), top 0.35s cubic-bezier(0.77, 0, 0.175, 1);
  animation: tour-in 0.3s cubic-bezier(0.23, 1, 0.32, 1);
}
@keyframes tour-in {
  from { opacity: 0; transform: translateY(8px); }
}
.tour-bubble {
  padding: 16px 18px 14px;
  border-radius: 16px;
}
.tour-count {
  margin: 0 0 4px;
  font-family: var(--font-ui);
  font-size: 12px;
  font-weight: 700;
}
.tour-title {
  margin: 0 0 6px;
  font-family: var(--font-title);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.3;
}
.tour-text {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  word-break: keep-all;
}
.tour-actions {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
}
.tour-skip {
  min-height: 44px;
  padding: 0 10px;
  border: 0;
  background: none;
  font-family: var(--font-ui);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}
.tour-next {
  min-width: 96px;
  min-height: 44px;
}
.tour.is-center .tour-card {
  text-align: center;
}
.tour.is-center .tour-actions {
  justify-content: center;
}
html[data-motion="reduce"] .tour-hole,
html[data-motion="reduce"] .tour-card {
  transition: none;
  animation: none;
}
@media (max-width: 1023px) {
  .menu-guest-team {
    display: none;            /* 패드 · 휴대폰: '팀 바꾸기'는 ☰ 메뉴판에 */
  }
  .menu-band:has(.menu-guest-login) .menu-guest-login {
    margin-left: auto;
  }
}
@media (max-width: 640px) {
  .menu-band:has(.menu-guest-login) .menu-guest-login {
    margin-left: auto;        /* 휴대폰은 동그라미가 숨어서 로그인 알약이 오른쪽 끝(☰ 옆)으로 */
  }
}
