:root {
    color-scheme: dark;
    --background: #08090a;
    --surface: #111315;
    --surface-raised: #17191c;
    --surface-muted: #202328;
    --border: #2c3036;
    --border-bright: #3b4048;
    --text: #f7f7f8;
    --text-soft: #b6bac2;
    --text-muted: #7e848e;
    --orange: #ed772e;
    --orange-soft: #f29a60;
    --green: #53d69c;
    --blue: #6fa8ff;
    --red: #ff6d75;
    --yellow: #f2cf62;
    --shadow: 0 22px 60px rgba(0, 0, 0, .35);
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-width: 320px;
    background: var(--background);
    color: var(--text);
    font-family: Inter, "Pretendard GOV Variable", "PingFang SC", "Microsoft YaHei", sans-serif;
    line-height: 1.5;
}

button,
input,
select {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

a {
    color: inherit;
}

.shell {
    width: min(1240px, calc(100% - 40px));
    margin: 0 auto;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 30;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    background: rgba(8, 9, 10, .88);
    backdrop-filter: blur(18px);
}

.nav-shell {
    height: 66px;
    display: flex;
    align-items: center;
    gap: 36px;
}

.brand {
    display: inline-flex;
    align-items: baseline;
    color: #fff;
    font-size: 1.35rem;
    font-weight: 900;
    letter-spacing: -.06em;
    text-decoration: none;
}

.brand-mark,
.brand-dot {
    color: var(--orange);
}

.brand-dot {
    padding: 0 1px;
}

.primary-nav {
    display: flex;
    align-self: stretch;
    gap: 26px;
}

.primary-nav a {
    position: relative;
    display: flex;
    align-items: center;
    color: var(--text-muted);
    font-size: .88rem;
    font-weight: 700;
    text-decoration: none;
    transition: color .18s ease;
}

.primary-nav a:hover,
.primary-nav a.active {
    color: var(--text);
}

.primary-nav a.active::after {
    content: "";
    position: absolute;
    inset: auto 0 -1px;
    height: 2px;
    background: var(--orange);
}

.source-pill {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 7px 11px;
    border: 1px solid var(--border);
    border-radius: 999px;
    color: var(--text-soft);
    background: rgba(255, 255, 255, .025);
    font-size: .72rem;
    font-weight: 700;
    letter-spacing: .03em;
}

.source-pulse {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--green);
    box-shadow: 0 0 0 4px rgba(83, 214, 156, .12);
}

.hero-section {
    position: relative;
    min-height: 316px;
    overflow: hidden;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
    background:
        radial-gradient(circle at 75% 40%, rgba(237, 119, 46, .18), transparent 34%),
        linear-gradient(135deg, #0d0e10 0%, #15100d 100%);
}

.hero-grid {
    position: absolute;
    inset: 0;
    opacity: .24;
    background-image:
        linear-gradient(rgba(255, 255, 255, .04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, .04) 1px, transparent 1px);
    background-size: 42px 42px;
    mask-image: linear-gradient(90deg, #000, transparent 86%);
}

.hero-content {
    position: relative;
    min-height: 316px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
}

.eyebrow {
    margin: 0 0 9px;
    color: var(--orange-soft);
    font-size: .7rem;
    font-weight: 900;
    letter-spacing: .2em;
}

h1,
h2,
h3,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 13px;
    font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
    font-size: clamp(3.4rem, 8vw, 6.4rem);
    font-weight: 500;
    line-height: .9;
    letter-spacing: .005em;
    text-transform: uppercase;
}

.hero-copy {
    max-width: 620px;
    margin-bottom: 0;
    color: var(--text-soft);
    font-size: 1rem;
}

.update-card {
    width: min(300px, 100%);
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, .1);
    border-radius: 12px;
    background: rgba(8, 9, 10, .6);
    box-shadow: var(--shadow);
}

.update-card span,
.update-card strong,
.update-card a {
    display: block;
}

.update-card span {
    margin-bottom: 4px;
    color: var(--text-muted);
    font-size: .72rem;
}

.update-card strong {
    margin-bottom: 14px;
    font-size: .94rem;
}

.update-card a {
    color: var(--orange-soft);
    font-size: .78rem;
    font-weight: 700;
    text-decoration: none;
}

.metrics {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    margin-top: -30px;
    position: relative;
    z-index: 2;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--surface);
    box-shadow: var(--shadow);
}

.metrics article {
    min-height: 112px;
    padding: 20px 24px;
    display: grid;
    align-content: center;
    border-right: 1px solid var(--border);
}

.metrics article:last-child {
    border-right: 0;
}

.metric-label {
    color: var(--text-soft);
    font-size: .8rem;
}

.metrics strong {
    margin: 1px 0 -2px;
    font-size: 2.1rem;
    line-height: 1.1;
}

.metrics small {
    color: var(--text-muted);
    font-size: .59rem;
    font-weight: 800;
    letter-spacing: .13em;
}

.featured-wrap,
.content-section {
    padding-top: 64px;
}

.section-heading {
    margin-bottom: 20px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
}

.section-heading h2 {
    margin-bottom: 0;
    font-size: 1.55rem;
    letter-spacing: -.035em;
}

.quiet-button {
    padding: 0;
    border: 0;
    color: var(--text-soft);
    background: transparent;
    cursor: pointer;
    font-size: .82rem;
}

.quiet-button span {
    margin-left: 5px;
    color: var(--orange);
}

.featured-card {
    position: relative;
    min-height: 250px;
    padding: 30px;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(300px, .7fr);
    gap: 38px;
    border: 1px solid var(--border);
    border-radius: 14px;
    background:
        radial-gradient(circle at 18% 0%, rgba(237, 119, 46, .17), transparent 32%),
        linear-gradient(135deg, #17191c, #0e1012);
}

.featured-card::after {
    content: "OW";
    position: absolute;
    right: -22px;
    bottom: -72px;
    color: rgba(255, 255, 255, .025);
    font-family: Impact, sans-serif;
    font-size: 15rem;
    line-height: 1;
    pointer-events: none;
}

.featured-main,
.featured-side {
    position: relative;
    z-index: 1;
}

.badge-row {
    margin-bottom: 18px;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
}

.status-badge,
.tier-badge,
.region-badge {
    display: inline-flex;
    align-items: center;
    min-height: 24px;
    padding: 3px 8px;
    border-radius: 5px;
    font-size: .64rem;
    font-weight: 900;
    letter-spacing: .045em;
    text-transform: uppercase;
}

.status-badge.ongoing {
    color: #0b1b14;
    background: var(--green);
}

.status-badge.upcoming {
    color: #111b2d;
    background: var(--blue);
}

.status-badge.completed {
    color: var(--text-soft);
    background: var(--surface-muted);
}

.tier-badge {
    color: #1a1109;
    background: var(--orange-soft);
}

.region-badge {
    border: 1px solid var(--border-bright);
    color: var(--text-soft);
}

.featured-card h3 {
    max-width: 680px;
    margin-bottom: 10px;
    font-size: clamp(1.8rem, 4vw, 2.65rem);
    line-height: 1.05;
    letter-spacing: -.045em;
}

.featured-meta,
.card-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 9px 18px;
    color: var(--text-muted);
    font-size: .78rem;
}

.featured-description {
    max-width: 650px;
    margin: 20px 0 0;
    color: var(--text-soft);
    font-size: .86rem;
}

.featured-side {
    align-self: stretch;
    padding-left: 30px;
    display: grid;
    align-content: center;
    gap: 16px;
    border-left: 1px solid var(--border);
}

.progress-label {
    display: flex;
    justify-content: space-between;
    color: var(--text-soft);
    font-size: .76rem;
}

.progress-track {
    height: 7px;
    overflow: hidden;
    border-radius: 999px;
    background: var(--surface-muted);
}

.progress-track i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: linear-gradient(90deg, var(--orange), var(--orange-soft));
}

.featured-facts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.featured-facts div {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: rgba(0, 0, 0, .16);
}

.featured-facts span,
.featured-facts strong {
    display: block;
}

.featured-facts span {
    color: var(--text-muted);
    font-size: .65rem;
}

.featured-facts strong {
    margin-top: 2px;
    font-size: .9rem;
}

.result-count {
    color: var(--text-muted);
    font-size: .75rem;
}

.filter-bar {
    margin-bottom: 24px;
    display: grid;
    grid-template-columns: minmax(260px, 1fr) repeat(3, minmax(130px, auto));
    gap: 10px;
}

.filter-bar input,
.filter-bar select {
    width: 100%;
    height: 42px;
    border: 1px solid var(--border);
    border-radius: 8px;
    outline: none;
    color: var(--text);
    background: var(--surface);
    transition: border-color .18s ease, background .18s ease;
}

.filter-bar input:focus,
.filter-bar select:focus {
    border-color: var(--orange);
    background: var(--surface-raised);
}

.filter-bar select {
    padding: 0 34px 0 12px;
}

.search-control {
    position: relative;
}

.search-control input {
    padding: 0 14px 0 40px;
}

.search-icon {
    position: absolute;
    top: 13px;
    left: 15px;
    width: 14px;
    height: 14px;
    border: 2px solid var(--text-muted);
    border-radius: 50%;
}

.search-icon::after {
    content: "";
    position: absolute;
    width: 6px;
    height: 2px;
    right: -5px;
    bottom: -2px;
    transform: rotate(45deg);
    background: var(--text-muted);
}

.tournament-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.tournament-card {
    min-height: 236px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--border);
    border-radius: 10px;
    color: inherit;
    background: var(--surface);
    cursor: pointer;
    text-align: left;
    transition: transform .18s ease, border-color .18s ease, background .18s ease;
}

.tournament-card:hover {
    transform: translateY(-3px);
    border-color: var(--border-bright);
    background: var(--surface-raised);
}

.tournament-card h3 {
    margin: 17px 0 10px;
    font-size: 1.08rem;
    line-height: 1.3;
    letter-spacing: -.025em;
}

.card-meta {
    display: grid;
    gap: 4px;
}

.card-footer {
    margin-top: auto;
    padding-top: 19px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    border-top: 1px solid var(--border);
}

.card-stat span,
.card-stat strong {
    display: block;
}

.card-stat span {
    color: var(--text-muted);
    font-size: .64rem;
}

.card-stat strong {
    font-size: .87rem;
}

.card-arrow {
    color: var(--orange);
    font-size: 1.2rem;
}

.schedule-section {
    padding-bottom: 82px;
}

.segmented {
    padding: 3px;
    display: flex;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.segmented button {
    padding: 7px 13px;
    border: 0;
    border-radius: 5px;
    color: var(--text-muted);
    background: transparent;
    cursor: pointer;
    font-size: .74rem;
    font-weight: 700;
}

.segmented button.active {
    color: var(--text);
    background: var(--surface-muted);
}

.match-list {
    display: grid;
    gap: 8px;
}

.match-card {
    min-height: 86px;
    padding: 13px 18px;
    display: grid;
    grid-template-columns: minmax(160px, .75fr) minmax(320px, 1.4fr) minmax(150px, .7fr);
    align-items: center;
    gap: 20px;
    border: 1px solid var(--border);
    border-radius: 9px;
    background: var(--surface);
}

.match-context strong,
.match-context span {
    display: block;
}

.match-context strong {
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: .78rem;
}

.match-context span,
.match-extra {
    color: var(--text-muted);
    font-size: .68rem;
}

.match-teams {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 13px;
}

.match-team {
    font-size: .88rem;
    font-weight: 800;
}

.match-team:first-child {
    text-align: right;
}

.match-score {
    min-width: 62px;
    padding: 8px 10px;
    border-radius: 6px;
    color: var(--text);
    background: var(--surface-muted);
    text-align: center;
    font-weight: 900;
}

.match-extra {
    text-align: right;
}

.loading-state,
.empty-state {
    padding: 70px 20px;
    border: 1px dashed var(--border);
    border-radius: 10px;
    color: var(--text-muted);
    text-align: center;
}

.loading-state span {
    width: 7px;
    height: 7px;
    margin: 0 3px;
    display: inline-block;
    border-radius: 50%;
    background: var(--orange);
    animation: loading 1s infinite alternate;
}

.loading-state span:nth-child(2) {
    animation-delay: .2s;
}

.loading-state span:nth-child(3) {
    animation-delay: .4s;
}

.loading-state p {
    margin: 12px 0 0;
    font-size: .78rem;
}

@keyframes loading {
    to {
        opacity: .25;
        transform: translateY(-6px);
    }
}

.detail-panel {
    position: fixed;
    inset: 0;
    z-index: 50;
    display: none;
}

.detail-panel.open {
    display: block;
}

.detail-backdrop {
    position: absolute;
    inset: 0;
    width: 100%;
    border: 0;
    background: rgba(0, 0, 0, .7);
    backdrop-filter: blur(5px);
}

.detail-sheet {
    position: absolute;
    inset: 22px 22px 22px auto;
    width: min(760px, calc(100% - 44px));
    padding: 34px;
    overflow-y: auto;
    border: 1px solid var(--border-bright);
    border-radius: 14px;
    background: #0d0f11;
    box-shadow: var(--shadow);
    animation: sheet-in .22s ease-out;
}

@keyframes sheet-in {
    from {
        opacity: 0;
        transform: translateX(24px);
    }
}

.detail-close {
    position: sticky;
    top: 0;
    z-index: 2;
    margin: -18px -18px 0 auto;
    width: 38px;
    height: 38px;
    display: block;
    border: 1px solid var(--border);
    border-radius: 50%;
    color: var(--text-soft);
    background: var(--surface);
    cursor: pointer;
    font-size: 1.45rem;
}

.detail-title {
    max-width: 630px;
    margin: 22px 0 13px;
    font-size: clamp(1.8rem, 5vw, 2.8rem);
    line-height: 1.05;
    letter-spacing: -.045em;
}

.detail-info-grid {
    margin: 25px 0;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    border: 1px solid var(--border);
    border-radius: 9px;
}

.detail-info-grid div {
    padding: 13px;
    border-right: 1px solid var(--border);
}

.detail-info-grid div:last-child {
    border-right: 0;
}

.detail-info-grid span,
.detail-info-grid strong {
    display: block;
}

.detail-info-grid span {
    color: var(--text-muted);
    font-size: .62rem;
}

.detail-info-grid strong {
    margin-top: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    font-size: .8rem;
}

.detail-block {
    margin-top: 30px;
}

.detail-block h3 {
    margin-bottom: 13px;
    font-size: .9rem;
    letter-spacing: .02em;
    text-transform: uppercase;
}

.detail-match {
    margin-bottom: 7px;
    padding: 12px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.detail-match span:first-child {
    text-align: right;
}

.detail-match small {
    display: block;
    color: var(--text-muted);
    font-size: .6rem;
}

.team-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
}

.team-card {
    padding: 13px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--surface);
}

.team-card strong {
    display: block;
    margin-bottom: 6px;
    font-size: .8rem;
}

.team-card p {
    margin: 0;
    color: var(--text-muted);
    font-size: .68rem;
}

.source-button {
    margin-top: 28px;
    width: 100%;
    padding: 12px 16px;
    display: block;
    border: 1px solid var(--orange);
    border-radius: 8px;
    color: var(--orange-soft);
    text-align: center;
    text-decoration: none;
    font-size: .78rem;
    font-weight: 800;
}

.site-footer {
    padding: 34px 0;
    border-top: 1px solid var(--border);
    color: var(--text-muted);
    background: #060708;
}

.footer-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    font-size: .68rem;
}

.footer-content strong {
    color: var(--text-soft);
}

.footer-content p {
    margin: 2px 0 0;
}

.footer-content a {
    color: var(--orange-soft);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

body.panel-open {
    overflow: hidden;
}

@media (max-width: 960px) {
    .metrics {
        grid-template-columns: repeat(2, 1fr);
    }

    .metrics article:nth-child(2) {
        border-right: 0;
    }

    .metrics article:nth-child(-n + 2) {
        border-bottom: 1px solid var(--border);
    }

    .featured-card {
        grid-template-columns: 1fr;
    }

    .featured-side {
        padding: 22px 0 0;
        border-top: 1px solid var(--border);
        border-left: 0;
    }

    .tournament-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .filter-bar {
        grid-template-columns: 1fr 1fr;
    }

    .search-control {
        grid-column: 1 / -1;
    }

    .match-card {
        grid-template-columns: 1fr;
        gap: 9px;
    }

    .match-extra {
        text-align: left;
    }
}

@media (max-width: 680px) {
    .shell {
        width: min(100% - 24px, 1240px);
    }

    .nav-shell {
        height: 58px;
        gap: 18px;
    }

    .primary-nav {
        gap: 14px;
    }

    .primary-nav a {
        font-size: .76rem;
    }

    .source-pill {
        display: none;
    }

    .hero-content {
        min-height: 300px;
        padding: 56px 0 72px;
        display: block;
    }

    .update-card {
        margin-top: 28px;
    }

    .metrics {
        margin-top: -34px;
    }

    .metrics article {
        min-height: 93px;
        padding: 14px 16px;
    }

    .metrics strong {
        font-size: 1.65rem;
    }

    .featured-wrap,
    .content-section {
        padding-top: 48px;
    }

    .featured-card {
        min-height: 0;
        padding: 22px;
    }

    .featured-facts {
        grid-template-columns: 1fr 1fr;
    }

    .tournament-grid,
    .filter-bar {
        grid-template-columns: 1fr;
    }

    .search-control {
        grid-column: auto;
    }

    .section-heading {
        align-items: center;
    }

    .tournament-heading {
        align-items: end;
    }

    .match-teams {
        gap: 8px;
    }

    .match-team {
        font-size: .75rem;
    }

    .detail-sheet {
        inset: 8px;
        width: auto;
        padding: 22px;
    }

    .detail-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .detail-info-grid div:nth-child(2) {
        border-right: 0;
    }

    .detail-info-grid div:nth-child(-n + 2) {
        border-bottom: 1px solid var(--border);
    }

    .team-list {
        grid-template-columns: 1fr;
    }

    .footer-content {
        display: block;
    }

    .footer-content > p {
        margin-top: 14px;
    }
}
