/**
 * Copyright © ProPlayerFC. All rights reserved.
 * Fixed bottom navigation (mobile only) — bar preta, ícones e labels brancos.
 * Espaço para o conteúdo não ficar sob a barra: ver ProPlayerFC_Base::css/main-content.css (.page-wrapper).
 */

@media (max-width: 767px) {
    :root {
        /* Altura útil da faixa (labels em 2–3 linhas em pt_BR + item central maior) + folga */
        --ppfc-mobile-bottom-nav-space: 92px;
    }
}

.ppfc-mobile-bottom-nav-root {
    display: none;
}

@media (max-width: 767px) {
    .ppfc-mobile-bottom-nav-root {
        display: block;
    }
}

@media (min-width: 768px) {
    .ppfc-mobile-bottom-nav-root {
        display: none !important;
    }
}

/*
 * Mantém a barra acima do conteúdo comum, mas abaixo de praticamente todos os modais
 * (tournament-view, tournament-manage, confirm-modal, custom-dialog, etc.).
 * Empilhamento extra em mobile: ProPlayerFC_Base::css/main-content.css
 */
.ppfc-mobile-bottom-nav {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 600;
    background: #000;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    box-shadow: 0 -4px 24px rgba(0, 0, 0, 0.35);
}

.ppfc-mobile-bottom-nav__items {
    list-style: none;
    margin: 0;
    padding: 4px 2px 5px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 0;
    width: 100%;
    box-sizing: border-box;
}

.ppfc-mobile-bottom-nav__item {
    flex: 1 1 0;
    min-width: 0;
    max-width: 25%;
    text-align: center;
}

/* Três itens (visitante): distribuir em toda a largura */
.ppfc-mobile-bottom-nav__items--guest .ppfc-mobile-bottom-nav__item {
    max-width: 33.333%;
}

.ppfc-mobile-bottom-nav__link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    gap: 2px;
    min-height: 40px;
    padding: 2px 1px;
    color: #fff !important;
    text-decoration: none !important;
    background: none;
    border: none;
    width: 100%;
    max-width: 100%;
    cursor: pointer;
    font-family: inherit;
    -webkit-tap-highlight-color: transparent;
    box-sizing: border-box;
}

.ppfc-mobile-bottom-nav__link:hover,
.ppfc-mobile-bottom-nav__link:focus {
    color: #fff !important;
    opacity: 0.92;
    outline: none;
}

.ppfc-mobile-bottom-nav__link--active .ppfc-mobile-bottom-nav__icon,
.ppfc-mobile-bottom-nav__link--active .ppfc-mobile-bottom-nav__label {
    color: #fff;
    opacity: 1;
}

.ppfc-mobile-bottom-nav__link--active {
    opacity: 1;
}

.ppfc-mobile-bottom-nav__icon {
    font-size: 18px;
    line-height: 1;
    color: #fff;
    opacity: 0.9;
    flex-shrink: 0;
}

.ppfc-mobile-bottom-nav__label {
    font-size: 8.5px;
    font-weight: 600;
    line-height: 1.2;
    color: #fff;
    letter-spacing: 0.02em;
    max-width: 100%;
    padding: 0 1px;
    margin: 0 auto;
    display: block;
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    -webkit-hyphens: auto;
}

/* Destaque central — Criar */
.ppfc-mobile-bottom-nav__item--create .ppfc-mobile-bottom-nav__link {
    position: relative;
}

.ppfc-mobile-bottom-nav__item--create .ppfc-mobile-bottom-nav__icon {
    font-size: 20px;
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.85);
    margin-bottom: 1px;
}

/* Quarto item: mesmo peso visual dos demais; ícone alinhado à faixa de ícones */
.ppfc-mobile-bottom-nav__item--my-tournaments .ppfc-mobile-bottom-nav__icon {
    font-size: 18px;
}
