@import url("https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=DM+Sans:wght@400;500;600;700;800&family=Noto+Sans+TC:wght@400;500;600;700;900&display=swap");

:root {
  color-scheme: light;
  --ink: #342a22;
  --muted: #806f5e;
  --paper: #f4ede1;
  --white: #fffaf2;
  --line: #dfd1bd;
  --accent: #b8613f;
  --green: #69764d;
  --sage: #dce2ce;
  --sand: #e9decc;
  --mono: "DM Mono", monospace;
  --sans: "DM Sans", "Noto Sans TC", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 84px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
button, input { font: inherit; }
a { color: inherit; text-decoration: none; }
button { color: inherit; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.site-header { height: 82px; padding: 0 7.1%; display: flex; align-items: center; justify-content: space-between; background: var(--sand); color: var(--ink); border-bottom: 1px solid var(--line); }
.brand-cluster { display: flex; align-items: center; gap: 16px; }
.brand { display: inline-flex; align-items: center; gap: 10px; }
.student-credit { padding-left: 14px; border-left: 1px solid #c5b59f; color: #17130f; font-size: 13px; font-weight: 800; line-height: 1.55; white-space: nowrap; }
.brand-mark { width: 36px; height: 36px; border: 1px solid var(--green); color: var(--green); display: grid; place-items: center; font-size: 19px; font-weight: 800; transform: skew(-7deg); }
.brand-name { font-size: 16px; font-weight: 800; letter-spacing: .06em; line-height: 1; }
.brand-name > span { color: var(--green); }
.brand-name small { display: block; margin-top: 5px; font-family: var(--mono); color: #827362; font-size: 8px; font-weight: 400; letter-spacing: .12em; }
.main-nav { height: 100%; display: flex; align-items: center; gap: 36px; }
.nav-link { height: 100%; display: flex; align-items: center; color: #827362; font-size: 13px; transition: color .2s; }
.nav-link:hover, .nav-link.active { color: var(--ink); }
.nav-link.active { box-shadow: inset 0 -2px var(--green); }
.header-cta { padding: 11px 16px; border: 1px solid #c5b59f; font-size: 12px; transition: background .2s, color .2s; }
.header-cta span { padding-left: 12px; color: var(--green); }
.header-cta:hover { background: var(--green); color: var(--white); }
.header-cta:hover span { color: var(--ink); }

.hero { position: relative; min-height: 570px; padding: 82px 11.5% 74px; overflow: hidden; display: grid; grid-template-columns: 1fr 1fr; align-items: center; background: var(--sand); color: var(--ink); }
.hero::before { position: absolute; inset: 0; content: ""; opacity: .3; background-image: linear-gradient(rgba(99,76,51,.1) 1px, transparent 1px), linear-gradient(90deg, rgba(99,76,51,.1) 1px, transparent 1px); background-size: 56px 56px; mask-image: linear-gradient(90deg, transparent, black 62%); }
.hero-copy { position: relative; z-index: 1; padding-bottom: 12px; }
.eyebrow { margin: 0 0 22px; color: var(--muted); font: 10px var(--mono); letter-spacing: .12em; }
.hero .eyebrow { color: #806f5e; }
.eyebrow-line { display: inline-block; width: 25px; height: 1px; margin: 0 10px 3px 0; background: var(--accent); }
.hero h1 { margin: 0; font-size: clamp(48px, 6vw, 78px); line-height: 1.16; letter-spacing: -.06em; font-weight: 800; }
.accent-text { color: var(--accent); }
.hero-description { max-width: 380px; margin: 24px 0 27px; color: #706151; font-size: 14px; line-height: 1.9; }
.primary-button { display: inline-flex; align-items: center; gap: 26px; padding: 14px 18px; background: var(--green); color: var(--white); font-size: 13px; font-weight: 700; transition: transform .2s, background .2s; }
.primary-button:hover { transform: translateY(-2px); background: #53633a; }
.primary-button span { font-size: 17px; }
.hero-note { display: flex; align-items: center; gap: 9px; margin-top: 31px; color: #806f5e; font: 10px var(--mono); letter-spacing: .04em; }
.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 0 4px #69764d1a; }
.hero-art { position: relative; justify-self: center; width: min(100%, 470px); height: 420px; }
.hero-orbit { position: absolute; left: 50%; top: 50%; border: 1px solid #cbbca6; border-radius: 50%; transform: translate(-50%, -50%); }
.orbit-one { width: 370px; height: 370px; }
.orbit-two { width: 300px; height: 300px; border-style: dashed; border-color: #c4b39b; }
.hero-number { position: absolute; z-index: 0; left: 50%; top: 46%; transform: translate(-50%, -50%); color: #d7c9b4; font: 800 260px/.8 var(--sans); letter-spacing: -.1em; }
.hero-player { position: absolute; z-index: 1; left: 50%; bottom: -7px; width: 94%; height: 100%; transform: translateX(-50%); display: flex; align-items: end; justify-content: center; overflow: hidden; }
.hero-player img { display: block; width: 100%; height: 100%; object-fit: contain; object-position: center bottom; filter: drop-shadow(0 10px 20px #65533b30); }
.hero-card { position: absolute; z-index: 2; left: -9px; bottom: 18px; display: grid; gap: 5px; padding: 14px 18px; min-width: 212px; background: var(--white); color: var(--ink); box-shadow: 0 8px 26px #65533b24; }
.hero-card-label { color: var(--accent); font: 9px var(--mono); letter-spacing: .13em; }
.hero-card strong { font-size: 16px; }
.hero-card > span:last-child { color: var(--muted); font-size: 11px; }
.hero-side-label { position: absolute; right: 0; top: 45%; writing-mode: vertical-rl; color: #806f5e; font: 9px var(--mono); letter-spacing: .13em; }
.hero-sticker { position: absolute; top: 26px; right: 27px; z-index: 2; width: 58px; height: 58px; display: grid; place-content: center; border-radius: 50%; background: var(--accent); color: white; text-align: center; font: 10px/1.35 var(--mono); transform: rotate(12deg); }
.hero-index { position: absolute; right: 7%; bottom: 26px; color: #806f5e; font: 10px var(--mono); letter-spacing: .1em; }

.ticker { height: 54px; padding: 0 5%; display: flex; justify-content: space-around; align-items: center; gap: 24px; overflow: hidden; background: var(--sage); color: var(--ink); white-space: nowrap; font: 10px var(--mono); letter-spacing: .1em; }
.ticker i { color: var(--accent); font-size: 15px; font-style: normal; }
.page-shell { width: min(1120px, 82%); margin: 0 auto; }
.players-section { padding-top: 94px; padding-bottom: 102px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; margin-bottom: 37px; }
.section-heading .eyebrow { margin-bottom: 13px; }
.section-heading h2 { margin: 0; font-size: clamp(37px, 4.5vw, 54px); line-height: 1.1; letter-spacing: -.06em; }
.section-intro { margin: 0 0 4px; color: var(--muted); font-size: 13px; line-height: 1.8; }
.directory-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 13px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.filter-list { display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.filter-button { padding: 9px 13px; border: 1px solid transparent; background: transparent; color: #73746b; cursor: pointer; font-size: 12px; transition: .2s; }
.filter-button:hover { color: var(--ink); border-color: var(--line); }
.filter-button.active { border-color: var(--ink); background: var(--ink); color: var(--white); }
.filter-button span { margin-left: 5px; color: #d5dfa8; font: 9px var(--mono); }
.filter-button.favorites-filter { margin-left: 10px; }
.filter-button.favorites-filter span { color: var(--accent); font-size: 15px; vertical-align: -1px; }
.filter-button.favorites-filter.active span { color: var(--sage); }
.search-box { width: 205px; height: 36px; display: flex; align-items: center; gap: 8px; padding: 0 9px; border: 1px solid var(--line); background: var(--white); }
.search-box svg { width: 15px; fill: none; stroke: #77786e; stroke-width: 1.7; }
.search-box input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--ink); font-size: 11px; }
.search-box input::placeholder { color: #999a90; }
.search-box:focus-within { border-color: var(--ink); outline: 2px solid #1719131c; }
.search-box kbd { color: #9a9b91; font: 10px var(--mono); }
.results-meta { display: flex; justify-content: space-between; margin: 17px 0; color: #85867d; font: 10px var(--mono); letter-spacing: .02em; }
.results-meta span:last-child span { color: var(--accent); }
.player-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px 16px; }
.player-card { min-width: 0; border: 1px solid #e6e5dc; background: var(--white); cursor: pointer; transition: transform .22s, box-shadow .22s, border-color .22s; }
.player-card:hover { transform: translateY(-5px); border-color: #c7c7bc; box-shadow: 0 12px 24px #1719130d; }
.player-image { position: relative; height: 222px; overflow: hidden; display: flex; align-items: end; justify-content: center; background: #ece2d3; }
.player-image::before { position: absolute; inset: 0; content: ""; background: radial-gradient(ellipse at 50% 84%, #dbcebb 0, #ece2d3 53%, transparent 54%); }
.player-image::after { position: absolute; right: -21px; bottom: -62px; width: 176px; height: 176px; content: ""; border: 1px solid #d5c7b1; border-radius: 50%; }
.player-image > img { position: relative; z-index: 1; display: block; width: 100%; height: 100%; object-fit: contain; object-position: center bottom; transition: transform .35s; }
.player-card:hover .player-image > img { transform: scale(1.05); }
.card-number { position: absolute; z-index: 0; top: 12px; left: 14px; color: #d7c9b5; font: 800 48px/.9 var(--sans); }
.card-position { position: absolute; z-index: 2; left: 11px; bottom: 11px; padding: 5px 8px; background: var(--green); color: var(--ink); font: 9px var(--mono); letter-spacing: .06em; }
.favorite-button { position: absolute; z-index: 3; top: 11px; right: 11px; width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid #fff9; border-radius: 50%; background: #fffaf2eb; color: #806f5e; cursor: pointer; font-size: 19px; line-height: 1; transition: color .2s, background .2s, transform .2s; }
.favorite-button:hover { transform: scale(1.08); color: var(--accent); }
.favorite-button.is-favorite { background: var(--accent); color: white; }
.card-info { padding: 15px 15px 16px; }
.card-team { margin-bottom: 9px; color: #898a81; font: 9px var(--mono); letter-spacing: .06em; }
.card-name { margin: 0; font-size: 17px; line-height: 1.35; letter-spacing: -.03em; }
.card-name-local { margin: 4px 0 13px; color: #7a7b71; font-size: 11px; }
.card-footer { display: flex; align-items: center; justify-content: space-between; padding-top: 11px; border-top: 1px solid #ecebe3; }
.card-style { color: #77786e; font-size: 10px; }
.card-arrow { color: var(--accent); font-size: 17px; transition: transform .2s; }
.player-card:hover .card-arrow { transform: translate(2px, -2px); }
.empty-state { padding: 60px 10px; text-align: center; color: var(--muted); font-size: 14px; }

.manifesto { padding: 70px 9%; background: #ebe2d3; }
.manifesto-inner { position: relative; width: min(920px, 100%); margin: auto; display: grid; grid-template-columns: 1fr 1.2fr; align-items: center; gap: 18px 70px; }
.manifesto-mark { position: absolute; top: -50px; left: -35px; color: #d7c9b5; font: 150px/.9 Georgia, serif; }
.manifesto .eyebrow { margin-bottom: 15px; }
.manifesto h2 { position: relative; margin: 0; font-size: clamp(37px, 4.5vw, 52px); line-height: 1.22; letter-spacing: -.06em; }
.manifesto-copy { margin: 12px 0 0; color: #706151; font-size: 13px; line-height: 2; }
.site-footer { min-height: 110px; padding: 25px 7.1%; display: flex; align-items: center; justify-content: space-between; gap: 20px; background: var(--sand); color: var(--ink); border-top: 1px solid var(--line); }
.footer-brand .brand-mark { width: 31px; height: 31px; font-size: 16px; }
.footer-brand .brand-name { font-size: 14px; }
.site-footer > p { margin: 0; color: #806f5e; font-size: 10px; }
.site-footer > p span { margin-left: 14px; color: #897a68; font: 9px var(--mono); }
.back-to-top { color: var(--green); font: 10px var(--mono); }

.player-dialog { width: min(720px, calc(100% - 32px)); max-width: none; max-height: min(650px, calc(100% - 32px)); padding: 0; border: 0; background: var(--paper); color: var(--ink); box-shadow: 0 24px 90px #0005; }
.player-dialog::backdrop { background: #11130fbd; backdrop-filter: blur(4px); }
.dialog-close { position: absolute; z-index: 3; top: 15px; right: 15px; width: 38px; height: 38px; border: 1px solid #c9c9bd; border-radius: 50%; background: var(--white); cursor: pointer; font-size: 25px; line-height: 1; }
.dialog-content { min-height: 400px; display: grid; grid-template-columns: 41% 1fr; }
.dialog-portrait { position: relative; min-height: 400px; display: flex; align-items: end; overflow: hidden; background: #ece2d3; }
.dialog-portrait::before { position: absolute; inset: auto 5% 2% 5%; height: 70%; content: ""; border: 1px solid #d5c7b1; border-radius: 50% 50% 0 0; }
.dialog-portrait img { position: relative; z-index: 1; width: 100%; max-height: 100%; object-fit: contain; object-position: center bottom; }
.dialog-copy { padding: 60px 34px 32px; align-self: center; }
.dialog-copy .eyebrow { margin-bottom: 11px; }
.dialog-copy h2 { margin: 0; font-size: 32px; letter-spacing: -.05em; }
.dialog-local-name { margin: 4px 0 20px; color: #7a7b71; font-size: 13px; }
.dialog-team-brand { display: flex; align-items: center; gap: 9px; margin: -7px 0 13px; color: #625341; font-size: 11px; font-weight: 600; }
.dialog-team-brand img { width: 30px; height: 30px; object-fit: contain; }
.dialog-meta { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 19px; }
.dialog-meta span { padding: 6px 9px; background: var(--green); font: 9px var(--mono); }
.dialog-stats { margin: 0 0 17px; padding: 12px 13px; border: 1px solid var(--line); background: #fffaf280; }
.stats-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 10px; }
.stats-heading strong { font-size: 11px; }
.stats-heading > span, .stats-source { color: #897a68; font: 9px var(--mono); }
.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px 6px; }
.stat-item { display: grid; gap: 3px; }
.stat-item > span { color: #827362; font-size: 9px; }
.stat-item > strong { font: 600 14px var(--mono); }
.stats-message { margin: 0; color: #706151; font-size: 11px; line-height: 1.7; }
.stats-source { margin: 10px 0 0; text-align: right; }
.dialog-bio { margin: 0; color: #5e5f57; font-size: 12px; line-height: 1.9; }
.dialog-highlights { margin: 22px 0 0; padding: 15px 0 0; border-top: 1px solid var(--line); list-style: none; }
.dialog-highlights li { display: flex; gap: 9px; margin-top: 9px; color: #53544c; font-size: 11px; line-height: 1.6; }
.dialog-highlights li::before { content: "✳"; color: var(--accent); }

@media (max-width: 900px) {
  .site-header { padding: 0 5%; }
  .hero { min-height: 520px; padding: 65px 7%; }
  .hero-art { transform: scale(.9); }
  .page-shell { width: 88%; }
  .player-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .player-image { height: 230px; }
  .filter-list { gap: 2px; }
  .filter-button { padding: 8px 9px; }
}
@media (max-width: 640px) {
  html { scroll-padding-top: 68px; }
  .site-header { height: 68px; padding: 0 5%; }
  .brand-cluster { gap: 8px; }
  .brand-mark { width: 31px; height: 31px; }
  .brand-name { font-size: 14px; }
  .brand-name small { font-size: 7px; }
  .student-credit { padding-left: 8px; font-size: 11px; }
  .main-nav { display: none; }
  .header-cta { padding: 9px 10px; font-size: 10px; }
  .hero { min-height: auto; padding: 55px 8% 35px; grid-template-columns: 1fr; }
  .hero h1 { font-size: clamp(47px, 14vw, 68px); }
  .hero-description { max-width: 340px; margin-top: 18px; font-size: 13px; }
  .hero-note { margin-top: 22px; }
  .hero-art { width: 100%; height: 340px; margin-top: 14px; transform: none; }
  .orbit-one { width: 300px; height: 300px; }
  .orbit-two { width: 238px; height: 238px; }
  .hero-number { font-size: 215px; }
  .hero-card { left: 0; bottom: 10px; min-width: 188px; padding: 12px 14px; }
  .hero-side-label { right: 4px; }
  .hero-sticker { top: 12px; right: 24px; width: 50px; height: 50px; }
  .hero-index { right: 6%; bottom: 12px; }
  .ticker { height: 46px; justify-content: flex-start; gap: 20px; }
  .ticker span:nth-of-type(3), .ticker i:nth-of-type(2) { display: none; }
  .page-shell { width: 88%; }
  .players-section { padding-top: 66px; padding-bottom: 70px; }
  .section-heading { align-items: start; gap: 15px; margin-bottom: 23px; }
  .section-heading h2 { font-size: 40px; }
  .section-intro { padding-top: 15px; font-size: 11px; }
  .directory-toolbar { align-items: stretch; flex-direction: column-reverse; gap: 11px; padding: 12px 0; }
  .search-box { width: 100%; height: 40px; }
  .filter-list { gap: 3px; }
  .filter-button { padding: 8px 9px; font-size: 10px; }
  .filter-button.favorites-filter { margin-left: 0; }
  .results-meta { font-size: 9px; }
  .player-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px 10px; }
  .player-image { height: clamp(155px, 48vw, 215px); }
  .card-info { padding: 11px 10px 12px; }
  .card-name { font-size: 14px; }
  .card-name-local { margin: 3px 0 10px; font-size: 10px; }
  .card-team { font-size: 8px; }
  .card-style { font-size: 9px; }
  .card-number { top: 10px; left: 10px; font-size: 39px; }
  .favorite-button { top: 8px; right: 8px; width: 29px; height: 29px; }
  .manifesto { padding: 58px 9%; }
  .manifesto-inner { grid-template-columns: 1fr; gap: 15px; }
  .manifesto-mark { left: -15px; top: -35px; font-size: 115px; }
  .manifesto h2 { font-size: 43px; }
  .manifesto-copy { margin-top: 0; font-size: 12px; }
  .site-footer { min-height: 130px; padding: 22px 6%; display: grid; grid-template-columns: 1fr auto; gap: 15px; }
  .site-footer > p { grid-column: 1 / -1; grid-row: 2; }
  .site-footer > p span { display: block; margin: 6px 0 0; }
  .back-to-top { grid-column: 2; grid-row: 1; }
  .dialog-content { grid-template-columns: 1fr; }
  .dialog-portrait { min-height: 230px; height: 230px; }
  .dialog-portrait img { height: 100%; }
  .dialog-copy { padding: 25px 24px 26px; }
  .dialog-copy h2 { font-size: 27px; }
  .stats-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 9px 4px; }
  .stat-item > span { font-size: 8px; }
  .stat-item > strong { font-size: 12px; }
  .dialog-close { top: 10px; right: 10px; width: 34px; height: 34px; }
}
@media (max-width: 380px) {
  .brand { gap: 6px; }
  .brand-name { font-size: 12px; }
  .brand-name small { display: none; }
  .brand-cluster { gap: 6px; }
  .student-credit { padding-left: 6px; font-size: 9px; }
  .header-cta { padding: 8px; font-size: 9px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
