/* LEW_ShowBracket — árbol eliminatorio play-offs */

.LEW_Bracket {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 32px;
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    position: relative; /* SVG connector overlay */
}

.LEW_Bracket_Column {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 420px;
}

.LEW_Bracket_ColumnLabel {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #888;
    padding: 8px 0 12px;
    text-align: center;
}

/* Slot wrappers: stretch vertically to fill column space */
.LEW_Bracket_Column--QF .LEW_Bracket_SlotWrapper { flex: 1; }
.LEW_Bracket_Column--SF .LEW_Bracket_SlotWrapper { flex: 2; }
.LEW_Bracket_Column--F  .LEW_Bracket_SlotWrapper { flex: 4; }

.LEW_Bracket_SlotWrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    padding: 6px 4px;
    box-sizing: border-box;
}

/* Match card */
.LEW_Bracket_Match {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    width: 100%;
    max-width: 420px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.09);
    position: relative;
    z-index: 1;
}

.LEW_Bracket_Match--empty {
    background: #f7f7f7;
    border-style: dashed;
    border-color: #d0d0d0;
    min-height: 70px;
}

.LEW_Bracket_SlotLabel {
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.06em;
    color: #bbb;
    text-align: center;
    padding: 7px 0 3px;
    text-transform: uppercase;
}

/* Team row */
.LEW_Bracket_Team {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 7px;
    padding: 7px 10px;
    border-top: 1px solid #f0f0f0;
}

.LEW_Bracket_Team:first-of-type {
    border-top: none;
}

.LEW_Bracket_Team--winner {
    background: #f0f8ee;
}

.LEW_Bracket_TeamLogo {
    width: 30px;
    height: 30px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.LEW_Bracket_TeamLogo img {
    max-width: 30px;
    max-height: 30px;
    object-fit: contain;
    display: block;
}

.LEW_Bracket_TeamLogoPlaceholder {
    width: 24px;
    height: 24px;
    background: #e8e8e8;
    border-radius: 50%;
}

.LEW_Bracket_TeamName {
    flex: 1;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    min-width: 140px;
}

.LEW_Bracket_TeamWins {
    font-size: 13px;
    font-weight: 700;
    color: #aaa;
    min-width: 16px;
    text-align: center;
}

.LEW_Bracket_TeamWins--winner {
    color: #4caf50;
}

.LEW_Bracket_GameScore {
    font-size: 17px;
    font-weight: 700;
    color: #bbb;
    width: 36px;
    text-align: center;
    flex-shrink: 0;
}

.LEW_Bracket_GameScore--winner {
    color: #4caf50;
}

a.LEW_Bracket_GameScore,
a.LEW_Bracket_DateCell {
    text-decoration: none;
    cursor: pointer;
}

a.LEW_Bracket_GameScore:hover,
a.LEW_Bracket_DateCell:hover {
    background: #f0f4ff;
    border-radius: 4px;
}

/* Dates row — right-aligned to match score columns */
.LEW_Bracket_Dates {
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
    gap: 7px;
    padding: 3px 10px 7px 10px;
    border-top: 1px solid #f0f0f0;
}

.LEW_Bracket_DateCell {
    width: 36px;
    font-size: 13px;
    font-weight: 500;
    color: #ccc;
    text-align: center;
    flex-shrink: 0;
    line-height: 1.2;
    white-space: nowrap;
}

/* Connector div — unused, SVG handles all connectors */
.LEW_Bracket_Connector {
    display: none;
}

/* Empty state */
.LEW_Bracket_Empty {
    padding: 24px;
    text-align: center;
    color: #aaa;
    font-size: 14px;
}

/* Responsive */
@media (max-width: 600px) {
    .LEW_Bracket_Column {
        min-width: 220px;
    }
    .LEW_Bracket_Match {
        max-width: 220px;
    }
    .LEW_Bracket_TeamName {
        font-size: 11px;
    }
    .LEW_Bracket_GameScore {
        width: 26px;
        font-size: 12px;
    }
    .LEW_Bracket_DateCell {
        width: 26px;
    }
}
