/* =========================================================
   MOBILELEGENDSPEDIA - EVENT DETAIL
========================================================= */

.event-detail-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 285px;
    gap: 14px;
    align-items: start;
}

.event-detail-main,
.event-detail-sidebar {
    min-width: 0;
}

/* HERO */

.event-hero {
    display: grid;
    grid-template-columns: 145px minmax(0, 1fr);
    min-height: 190px;
    background: #fff;
    border: 1px solid #d4d7da;
}

.event-logo {
    min-height: 190px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: #eef0f2;
    border-right: 1px solid #d4d7da;
}

.event-logo img {
    max-width: 105px;
    max-height: 105px;
    object-fit: contain;
}

.event-logo-placeholder {
    color: #9ba0a6;
    font-size: 30px;
    font-weight: 900;
}

.event-info {
    padding: 17px 18px;
}

.event-tier {
    margin-bottom: 3px;
    color: #8b8f95;
    font-size: 8px;
    font-weight: 900;
    text-transform: uppercase;
}

.event-info h1 {
    margin: 0 0 12px;
    color: #22252a;
    font-size: 25px;
    font-weight: 900;
    letter-spacing: -.4px;
}

.event-meta-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-top: 1px solid #e2e4e7;
}

.event-meta-grid > div {
    padding: 9px 10px 8px 0;
}

.event-meta-grid span {
    display: block;
    margin-bottom: 3px;
    color: #969aa0;
    font-size: 7px;
    font-weight: 800;
    text-transform: uppercase;
}

.event-meta-grid strong {
    color: #2b2e33;
    font-size: 9px;
}

.event-champion {
    width: min(320px,100%);
    margin-top: 10px;
    padding: 8px 10px;
    display: flex;
    align-items: center;
    gap: 9px;
    background: #f8f9fa;
    border: 1px solid #e0e2e4;
}

.event-champion img {
    width: 29px;
    height: 29px;
    object-fit: contain;
}

.event-champion span,
.event-champion strong {
    display: block;
}

.event-champion span {
    color: #969aa0;
    font-size: 7px;
    text-transform: uppercase;
}

.event-champion strong {
    margin-top: 2px;
    color: #2a2d32;
    font-size: 10px;
}

/* TABS */

.event-tabs {
    display: flex;
    margin: 12px 0;
    overflow-x: auto;
    background: #fff;
    border: 1px solid #d4d7da;
}

.event-tabs a {
    min-height: 38px;
    padding: 0 13px;
    display: flex;
    align-items: center;
    white-space: nowrap;
    border-right: 1px solid #ddd;
    color: #555960;
    font-size: 8px;
    font-weight: 900;
}

.event-tabs a:hover {
    background: #f1f2f4;
    color: #d62531;
}

.event-section {
    scroll-margin-top: 15px;
}

/* STAGES */

.event-stage-row {
    min-height: 52px;
    padding: 9px 12px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border-bottom: 1px solid #eee;
}

.event-stage-row strong,
.event-stage-row span {
    display: block;
}

.event-stage-row strong {
    color: #2b2e33;
    font-size: 10px;
}

.event-stage-row span {
    margin-top: 2px;
    color: #8c9096;
    font-size: 8px;
    text-transform: capitalize;
}

.event-stage-row em {
    padding: 3px 5px;
    background: #eef0f2;
    color: #777b82;
    font-size: 7px;
    font-style: normal;
    font-weight: 900;
}

/* STANDINGS */

.standings-table {
    overflow-x: auto;
}

.standings-head,
.standings-row {
    min-width: 690px;
    display: grid;
    grid-template-columns: 38px minmax(180px,1fr) 44px 44px 44px 48px 48px 48px 58px;
    align-items: center;
}

.standings-head {
    padding: 8px 10px;
    background: #f3f4f5;
    color: #858990;
    font-size: 7px;
    font-weight: 900;
    text-transform: uppercase;
}

.standings-row {
    min-height: 46px;
    padding: 6px 10px;
    border-bottom: 1px solid #eee;
    color: #34373c;
    font-size: 8px;
}

.standings-row:hover {
    background: #fafafb;
}

.standings-team {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 7px;
}

.standings-team img {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    object-fit: contain;
}

.standings-team strong {
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* BRACKET */

.bracket-scroll {
    overflow-x: auto;
}

.bracket-grid {
    min-width: calc(var(--round-count) * 210px);
    display: grid;
    grid-template-columns: repeat(var(--round-count), 200px);
    gap: 10px;
    padding: 12px;
    align-items: start;
}

.bracket-round-title {
    margin-bottom: 8px;
    color: #777b82;
    font-size: 8px;
    font-weight: 900;
    text-align: center;
    text-transform: uppercase;
}

.bracket-match {
    margin-bottom: 10px;
    background: #fff;
    border: 1px solid #d8dade;
}

.bracket-team {
    min-height: 31px;
    padding: 5px 7px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 6px;
    border-bottom: 1px solid #eee;
}

.bracket-team span {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 5px;
    color: #33363b;
    font-size: 8px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.bracket-team img {
    width: 18px;
    height: 18px;
    flex: 0 0 18px;
    object-fit: contain;
}

.bracket-team strong {
    color: #25282d;
    font-size: 9px;
}

.bracket-match-link {
    display: block;
    padding: 5px;
    color: #3976aa;
    font-size: 7px;
    font-weight: 800;
    text-align: center;
}

/* MATCH / RESULT */

.event-match-row {
    position: relative;
    min-height: 66px;
    padding: 10px 12px 22px;
    display: grid;
    grid-template-columns: minmax(0,1fr) 50px minmax(0,1fr);
    gap: 8px;
    align-items: center;
    border-bottom: 1px solid #eee;
}

.event-match-row:hover {
    background: #fafafb;
}

.event-match-team {
    min-width: 0;
    display: flex;
    align-items: center;
    gap: 7px;
    color: #2e3136;
    font-size: 9px;
    font-weight: 800;
}

.event-match-team.right {
    justify-content: flex-end;
}

.event-match-team img {
    width: 24px;
    height: 24px;
    flex: 0 0 24px;
    object-fit: contain;
}

.event-match-team span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.event-match-row > strong {
    color: #d62531;
    font-size: 11px;
    text-align: center;
}

.event-match-meta {
    position: absolute;
    right: 12px;
    bottom: 5px;
    color: #92969c;
    font-size: 7px;
}

/* TEAMS */

.event-team-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0,1fr));
}

.event-team-card {
    min-height: 112px;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-right: 1px solid #eee;
    border-bottom: 1px solid #eee;
    text-align: center;
}

.event-team-card:hover {
    background: #fafafb;
}

.event-team-card img,
.event-team-placeholder {
    width: 46px;
    height: 46px;
    margin-bottom: 7px;
    object-fit: contain;
}

.event-team-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #eef0f2;
    color: #979ba1;
    font-size: 12px;
    font-weight: 900;
}

.event-team-card strong {
    color: #2c2f34;
    font-size: 9px;
}

.event-team-card span {
    margin-top: 3px;
    color: #91959b;
    font-size: 7px;
}

/* EMPTY / SIDEBAR */

.event-empty {
    padding: 26px 15px;
    color: #888c92;
    font-size: 8px;
    text-align: center;
}

.event-empty.compact {
    padding: 12px 5px;
}

.event-summary-grid {
    display: grid;
    grid-template-columns: repeat(3,1fr);
}

.event-summary-grid > div {
    padding: 12px 4px;
    text-align: center;
    border-right: 1px solid #eee;
}

.event-summary-grid > div:last-child {
    border-right: 0;
}

.event-summary-grid strong,
.event-summary-grid span {
    display: block;
}

.event-summary-grid strong {
    color: #292c31;
    font-size: 17px;
}

.event-summary-grid span {
    margin-top: 3px;
    color: #888c92;
    font-size: 7px;
    text-transform: uppercase;
}

@media (max-width: 850px) {
    .event-detail-layout {
        display: block;
    }

    .event-detail-sidebar {
        margin-top: 12px;
    }
}

@media (max-width: 650px) {
    .event-hero {
        grid-template-columns: 100px minmax(0,1fr);
    }

    .event-logo {
        min-height: 180px;
        padding: 9px;
    }

    .event-logo img {
        max-width: 72px;
        max-height: 72px;
    }

    .event-info {
        padding: 13px;
    }

    .event-info h1 {
        font-size: 20px;
    }

    .event-meta-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    .event-team-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }

    .event-match-row {
        grid-template-columns: minmax(0,1fr) 42px minmax(0,1fr);
    }
}