body {
  font-family: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif !important;
  background-color: #f1f5f9 !important;
  color: #0f172a !important;
  display: flex !important;
  flex-direction: column !important;
  padding-top: 60px !important;
  background-image: 
    linear-gradient(180deg, rgba(248, 250, 252, 0.85) 0%, rgba(226, 232, 240, 0.95) 100%),
    url("/images/confusa-blue.png") !important;
  background-repeat: no-repeat !important;
  background-position: center center !important;
  background-size: cover !important;
  background-attachment: fixed !important;
  overflow-x: hidden !important;
}

/* Container Principal */
.propostas-container {
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding: 3rem 1.5rem;
    flex: 1;
}

.propostas-card {
    background: rgba(255, 255, 255, 0.8) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 18px !important;
    padding: 2.25rem !important;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.04) !important;
}

.propostas-title {
    font-family: 'Kanit', sans-serif !important;
    font-size: 2rem !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    letter-spacing: -0.5px !important;
    margin-bottom: 0.5rem !important;
}

/* Estatísticas Rápidas (Dashboard) */
#info-jogos {
    display: grid !important;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)) !important;
    gap: 15px !important;
    width: 100% !important;
    margin-bottom: 1.5rem !important;
}

.infoblock {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    background: #ffffff !important;
    border: 1px solid rgba(0,0,0,0.06) !important;
    border-radius: 12px !important;
    padding: 12px 16px !important;
    box-shadow: 0 4px 6px rgba(0,0,0,0.01) !important;
    transition: transform 0.2s ease, box-shadow 0.2s ease !important;
}

.infoblock:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 12px rgba(0,0,0,0.03) !important;
}

.infoblock .material-symbols-outlined {
    font-size: 1.75rem !important;
    color: #0284c7 !important;
    background: rgba(2, 132, 199, 0.08) !important;
    padding: 8px !important;
    border-radius: 10px !important;
}

.infoblock .informacao {
    font-family: 'Kanit', sans-serif !important;
    font-size: 1.25rem !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    line-height: 1.2 !important;
}

.infoblock .informacao.menor {
    font-size: 1.1rem !important;
}

.infoblock .informacao.micro {
    font-size: 0.75rem !important;
    color: #64748b !important;
    font-weight: 500 !important;
}

.infoblock div {
    display: flex !important;
    flex-direction: column !important;
}

/* Modais Modernizados */
.modal {
    display: none;
    position: fixed;
    z-index: 1050;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
}

.modal-content {
    background-color: #ffffff;
    margin: 8% auto;
    padding: 24px;
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.modal-content label {
    display: block;
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    color: #475569;
    margin-bottom: 6px;
    font-size: 0.9rem;
}

.modal-content .form-control {
    width: 100%;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,0.1);
    background: #fff;
    margin-bottom: 20px;
    font-size: 0.95rem;
    outline: none;
}

.modal-content .form-control:focus {
    border-color: #0284c7;
}

.submitbtn {
    display: block;
    width: 100%;
    padding: 12px;
    background: #0284c7;
    color: #fff;
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
    text-align: center;
}

.submitbtn:hover {
    background: #0369a1;
}

.cancelbtn {
    display: block;
    width: 100%;
    padding: 11px;
    background: transparent;
    color: #64748b;
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    font-size: 0.95rem;
    border: 1.5px solid rgba(0,0,0,0.12);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
    text-align: center;
    margin-top: 8px;
    letter-spacing: 0.02em;
}

.cancelbtn:hover {
    background: #fee2e2;
    color: #dc2626;
    border-color: rgba(220, 38, 38, 0.3);
}

/* Abas (Tabs) */
.tab {
    display: flex;
    gap: 8px;
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 12px;
    padding: 6px;
    margin-bottom: 25px;
}

.tab a {
    flex: 1;
    padding: 12px 0;
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    font-size: 1rem;
    color: #64748b !important;
    text-decoration: none;
    border-radius: 8px;
    background: transparent;
    transition: all 0.2s ease;
    text-align: center;
}

.tab a:hover {
    background: rgba(0, 0, 0, 0.03);
    color: #1e293b !important;
}

.tab a.active {
    background: #0284c7;
    color: #ffffff !important;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.2);
}

/* Elenco drag/drop list styles */
#Elenco {
    display: flex;
    flex-wrap: wrap;
    gap: 25px;
    margin-top: 20px;
}

.tableHolder {
    flex: 1;
    min-width: 300px;
    background: #ffffff;
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.02);
}

.tableHolder table {
    width: 100%;
    border-collapse: collapse;
}

.tableHolder caption {
    font-family: 'Kanit', sans-serif;
    font-size: 1.15rem;
    font-weight: 600;
    color: #1e293b;
    padding: 10px 0;
    text-align: left;
    border-bottom: 2px solid #0284c7;
    margin-bottom: 12px;
}

/* Specific colors for lists */
#tabelaTitulares caption { border-bottom-color: #10b981; }
#tabelaReservas caption { border-bottom-color: #3b82f6; }
#tabelaSuplentes caption { border-bottom-color: #94a3b8; }

.tableHolder tr {
    border-bottom: 1px solid rgba(0,0,0,0.05);
    cursor: pointer;
    transition: background 0.2s;
}

.tableHolder tr:hover {
    background: rgba(0,0,0,0.01);
}

.tableHolder tr.selected {
    background: rgba(2, 132, 199, 0.15) !important;
    border-left: 4px solid #0284c7 !important;
    color: #0369a1 !important;
}

.tableHolder td {
    padding: 10px 8px;
    font-size: 0.9rem;
    color: #475569;
}

/* Center controls in Elenco tab */
#Elenco > div:not(.tableHolder) {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 12px;
    padding: 10px;
}

#Elenco > div:not(.tableHolder) a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: #0284c7;
    border: 1px solid rgba(2,132,199,0.2);
    transition: all 0.2s ease;
    box-shadow: 0 4px 10px rgba(2, 132, 199, 0.15);
}

#Elenco > div:not(.tableHolder) a:hover {
    background: #0369a1;
    transform: scale(1.1);
}

#Elenco > div:not(.tableHolder) a span {
    font-size: 1.4rem !important;
    color: #ffffff !important;
    height: auto !important;
    width: auto !important;
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Posicionamento - Tactical Field */
#sortable {
    position: relative;
    height: 600px;
    width: 750px;
    background-image: url(/images/campo2.png?9);
    background-size: cover;
    background-position: center;
    border-radius: 16px;
    box-shadow: inset 0 0 100px rgba(0,0,0,0.2), 0 10px 30px rgba(0,0,0,0.15);
    margin: 0 auto;
    overflow: hidden;
}

div[id*="draggable"] {
    height: 85px !important;
    width: 130px !important;
    float: left !important;
    margin: 10px !important;
    padding: 0 !important;
    list-style-type: none !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-end !important;
    position: relative; /* Sem !important para permitir que o jQuery UI sobrescreva a posição para absolute durante o arrasto */
    box-sizing: border-box !important;
    touch-action: none !important; /* Impede a rolagem e movimentação da página ao arrastar no celular/touch */
}

div[id*="draggable"] img {
    margin: 0 auto !important;
    display: block !important;
}

div[id*="draggable"] p {
    text-align: center !important;
    font-weight: 700 !important;
    outline: 1px solid transparent !important;
    overflow: hidden !important;
    width: 100% !important;
    font-size: 0.78rem !important;
    padding: 4px 6px !important;
    border-radius: 6px !important;
    margin: 0 !important;
    opacity: 1 !important; /* Remove qualquer transparência do elemento p */
    color: #ffffff !important; /* Texto sempre branco para contraste total */
    box-shadow: 0 2px 5px rgba(0,0,0,0.3) !important;
}

/* Goleiro (nondraggable28) precisa de flex-column igual aos draggables */
#nondraggable28 {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: flex-end !important;
    position: relative !important;
    box-sizing: border-box !important;
    float: left !important;
    height: 85px !important;
    width: 130px !important;
    margin: 10px !important;
    margin-top: -10px !important;
    padding: 0 !important;
}

.goleiro p {
    background: #eab308 !important; /* Amarelo sólido */
    border: 1px solid #ca8a04 !important;
    color: #ffffff !important;
    text-align: center !important;
    font-weight: 700 !important;
    overflow: hidden !important;
    width: 100% !important;
    font-size: 0.78rem !important;
    padding: 4px 6px !important;
    border-radius: 6px !important;
    margin: 0 !important;
    opacity: 1 !important;
    box-shadow: 0 2px 5px rgba(0,0,0,0.3) !important;
}

.pos-zaga p {
    background: #2563eb !important; /* Azul sólido */
    border: 1px solid #1d4ed8 !important;
    color: #ffffff !important;
}

.pos-zaga-meio p {
    background: linear-gradient(to right, #2563eb, #059669) !important; /* Degrade: Azul (Zaga) -> Verde (Meia) */
    border: none !important;
    color: #ffffff !important;
}

.pos-meio p {
    background: #059669 !important; /* Verde sólido */
    border: 1px solid #047857 !important;
    color: #ffffff !important;
}

.pos-meio-ataque p {
    background: linear-gradient(to right, #059669, #dc2626) !important; /* Degrade: Verde (Meia) -> Vermelho (Atacante) */
    border: none !important;
    color: #ffffff !important;
}

.pos-ataque p {
    background: #dc2626 !important; /* Vermelho sólido */
    border: 1px solid #b91c1c !important;
    color: #ffffff !important;
}

/* Badges e Textos explicativos dos atacantes Am (Movimentação) e Aa (Área) */
.Am, .Aa {
    position: absolute !important;
    top: 2px !important;
    right: 2px !important;
    font-size: 0.72rem !important;
    font-weight: 800 !important;
    padding: 2px 5px !important;
    border-radius: 4px !important;
    color: #ffffff !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
    z-index: 10 !important;
    text-shadow: none !important;
    min-width: 22px !important;
    text-align: center !important;
}

.Am {
    background: #f59e0b !important; /* Laranja/Amber */
    border: 1px solid #d97706 !important;
}
.Am::after {
    content: "Am" !important;
    display: inline-block !important;
}

.Aa {
    background: #ef4444 !important; /* Vermelho */
    border: 1px solid #dc2626 !important;
}
.Aa::before {
    content: "Aa" !important;
    display: inline-block !important;
}

/* Cobradores / Capitao */
#cobradoresCapitao {
    background: #ffffff;
    width: 100%;
    max-width: 500px;
    border: 1px solid rgba(0,0,0,0.08);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.02);
    margin: 30px auto 0 auto;
}

#cobradoresCapitao label {
    display: block;
    font-family: 'Kanit', sans-serif;
    font-weight: 600;
    font-size: 0.9rem;
    color: #475569;
    margin-bottom: 6px;
}

#cobradoresCapitao select {
    display: block;
    width: 100%;
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid rgba(0,0,0,0.1);
    background: #fff;
    margin-bottom: 20px;
    font-size: 0.95rem;
    color: #1e293b;
    outline: none;
    transition: border-color 0.2s;
}

#cobradoresCapitao select:focus {
    border-color: #0284c7;
}

/* Tabela de Jogadores */
#tabelaElenco {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

#tabelaElenco th {
    font-family: 'Kanit', sans-serif;
    color: #64748b;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(0,0,0,0.08);
    padding: 12px 10px;
    text-align: left;
}

#tabelaElenco tr {
    border-bottom: 1px solid rgba(0,0,0,0.05);
    transition: background 0.2s ease;
}

#tabelaElenco tr:hover {
    background: rgba(0, 0, 0, 0.01);
}

#tabelaElenco td {
    padding: 12px 10px;
    vertical-align: middle;
}

.playerThumb {
    height: 55px;
    width: 55px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(0,0,0,0.08);
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.jersey-icon {
    width: 30px;
    height: 30px;
    display: inline-flex;
    justify-content: center;
    align-items: center;
    background-image: url("data:image/svg+xml,%3Csvg width='800px' height='800px' viewBox='0 -63.5 1151 1151' version='1.1' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M902.984598 1024h-653.972493a27.200282 27.200282 0 0 1-27.200282-27.200282v-562.13916l-5.945204 7.16274a27.200282 27.200282 0 0 1-38.300588 3.561942L9.830959 306.184559a27.200282 27.200282 0 0 1-3.561942-38.300587L220.490667 9.831011A27.200282 27.200282 0 0 1 241.421931 0.000052h174.599905a27.200282 27.200282 0 0 1 13.341091 3.497179l146.143229 82.248472L711.002418 3.885806a27.200282 27.200282 0 0 1 14.066431-3.885754H910.56182a27.200282 27.200282 0 0 1 20.931264 9.830959l214.22165 258.052961a27.200282 27.200282 0 0 1-3.561942 38.300587l-167.735072 139.239539a27.200282 27.200282 0 0 1-38.300588-3.561942l-5.945204-7.162741v562.139161a27.200282 27.200282 0 0 1-27.18733 27.161424z m-626.772211-54.400564h599.57193V359.354634A27.200282 27.200282 0 0 1 923.915863 341.946454l36.694476 44.206934 125.872543-104.48794L897.816545 54.400616H732.633118l-142.568335 86.121273a27.200282 27.200282 0 0 1-27.407522 0.427433L408.885 54.400616H254.193111L65.500869 281.704305l125.872543 104.487941L228.08084 341.946454a27.200282 27.200282 0 0 1 48.131547 17.369323z' fill='%23cccccc' /%3E%3Cpath d='M574.54767 144.498312H336.946731a13.600141 13.600141 0 0 1-11.190973-21.31984l72.158462-104.526798a13.600141 13.600141 0 0 1 22.381946 15.45235l-57.431452 83.194006h211.682956a13.600141 13.600141 0 0 1 0 27.200282z' fill='%23cccccc' /%3E%3Cpath d='M802.900513 144.498312H565.312527a13.600141 13.600141 0 0 1 0-27.200282h211.682956l-57.431453-83.194006a13.600141 13.600141 0 0 1 22.381947-15.45235l72.158462 104.526798a13.600141 13.600141 0 0 1-11.190973 21.31984zM366.19351 92.234913H220.853337a13.600141 13.600141 0 0 1 0-27.200282h145.327221a13.600141 13.600141 0 0 1 0 27.200282z' fill='%23cccccc' /%3E%3Cpath d='M922.504039 97.143916H777.150913a13.600141 13.600141 0 0 1 0-27.200282h145.327221a13.600141 13.600141 0 1 1 0 27.200282z' fill='%23cccccc' /%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
    background-size: contain;
    font-size: 0.75rem;
    font-weight: 700;
    color: #475569;
    padding-top: 4px;
    margin-right: 5px;
    vertical-align: middle;
}

.inlineButton {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.05);
    color: #475569;
    transition: all 0.2s;
    cursor: pointer;
}

.inlineButton:hover {
    background: rgba(0, 0, 0, 0.08);
}

.inlineButton.azul {
    color: #0284c7;
    background: rgba(2, 132, 199, 0.08);
}

.inlineButton.azul:hover {
    background: rgba(2, 132, 199, 0.15);
}

.inlineButton.vermelho {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.08);
}

.inlineButton.vermelho:hover {
    background: rgba(239, 68, 68, 0.15);
}

.inlineButton.positive {
    color: #10b981;
    background: rgba(16, 185, 129, 0.08);
}

.inlineButton.positive:hover {
    background: rgba(16, 185, 129, 0.15);
}

/* Mobile responsive card layouts */
@media screen and (max-width: 1024px) {
    #Elenco {
        flex-direction: column;
    }
    
    #Elenco > div:not(.tableHolder) {
        flex-direction: row;
        flex-wrap: wrap;
    }
}

/* Universal Card-Grid Layout for Player List */
#tabelaElenco thead {
    display: none !important;
}

#tabelaElenco tbody {
    display: grid !important;
    grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)) !important;
    gap: 20px !important;
    padding: 10px 0 !important;
    width: 100% !important;
}

#tabelaElenco tr {
    display: flex !important;
    flex-direction: column !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 16px !important;
    padding: 18px !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.02) !important;
    position: relative !important;
    gap: 0 !important;
    transition: all 0.2s ease !important;
}

#tabelaElenco tr:hover {
    transform: translateY(-4px) !important;
    box-shadow: 0 10px 20px rgba(0,0,0,0.06) !important;
}

/* Starters, Reserves, and Bench Custom Visual Styles */
#tabelaElenco tr.titular {
    border-left: 5px solid #10b981 !important; /* Emerald */
    background: linear-gradient(135deg, #ffffff 0%, rgba(16, 185, 129, 0.02) 100%) !important;
}

#tabelaElenco tr.reserva {
    border-left: 5px solid #3b82f6 !important; /* Blue */
    background: linear-gradient(135deg, #ffffff 0%, rgba(59, 130, 246, 0.02) 100%) !important;
}

#tabelaElenco tr.suplente {
    border-left: 5px solid #94a3b8 !important; /* Slate */
    background: linear-gradient(135deg, #ffffff 0%, rgba(148, 163, 184, 0.02) 100%) !important;
}

/* Image opacities for non-starters */
#tabelaElenco tr.reserva .playerThumb {
    opacity: 0.85 !important;
}
#tabelaElenco tr.suplente .playerThumb {
    opacity: 0.55 !important;
}
#tabelaElenco tr.suplente td {
    color: #64748b !important;
}

#tabelaElenco td {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 10px 0 !important;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
    width: 100% !important;
    text-align: left !important;
    background: transparent !important;
    box-sizing: border-box !important;
}

#tabelaElenco td.cell-value,
#tabelaElenco td .cell-value {
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    flex: 1 !important;
    text-align: right !important;
    color: #1e293b;
    font-weight: 500;
}

/* Player Image (First Column) */
#tabelaElenco tr td:first-child {
    order: -3;
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    border-bottom: none !important;
    padding: 0 !important;
    margin-bottom: 10px !important;
}

#tabelaElenco tr td:first-child::before {
    display: none !important;
}

/* Player Name / Position (Second Column) */
#tabelaElenco tr td:nth-child(2) {
    order: -2;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    border-bottom: 2px solid rgba(0,0,0,0.08) !important;
    padding-bottom: 12px !important;
    margin-bottom: 8px !important;
    justify-content: center !important;
    text-align: center !important;
}

#tabelaElenco tr td:nth-child(2)::before {
    display: none !important;
}

#tabelaElenco tr td:nth-child(2) a {
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    text-align: center !important;
    color: #0284c7 !important;
}

/* Botões de Opções no rodapé do Card */
#tabelaElenco tr td:last-child {
    display: flex !important;
    width: 100% !important;
    justify-content: center !important;
    align-items: center !important;
    border-bottom: none !important;
    padding-top: 15px !important;
    margin-top: auto !important; /* Push options to the very bottom */
}

#tabelaElenco tr td:last-child::before {
    display: none !important; /* Oculta a label "OPÇÕES" no card */
}

#tabelaElenco tr td:last-child .cell-value {
    display: flex !important;
    justify-content: center !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    width: 100% !important;
    flex: none !important;
}

#tabelaElenco td::before {
    content: attr(data-label);
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: inline-block;
    margin-right: 15px;
    flex-shrink: 0;
}

/* Bandeiras de Nacionalidade */
.bandeira {
    height: 18px !important;
    width: auto !important;
    vertical-align: middle !important;
    border-radius: 3px !important;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15) !important;
    margin-right: 6px !important;
    display: inline-block;
}

/* Campos de Edição da Tabela de Jogadores */
#tabelaElenco input:not([type="file"]),
#tabelaElenco select {
    padding: 6px 10px !important;
    border-radius: 6px !important;
    border: 1px solid rgba(0,0,0,0.15) !important;
    background: #ffffff !important;
    color: #1e293b !important;
    font-size: 0.85rem !important;
    font-family: 'Montserrat', sans-serif !important;
    outline: none !important;
    max-width: 140px !important;
    width: 100% !important;
    box-sizing: border-box !important;
    transition: border-color 0.2s, box-shadow 0.2s !important;
    text-align: right !important;
}

#tabelaElenco input:focus,
#tabelaElenco select:focus {
    border-color: #0284c7 !important;
    box-shadow: 0 0 0 2px rgba(2, 132, 199, 0.1) !important;
}

/* Destaque nos campos editáveis */
#tabelaElenco .editavel {
    background: rgba(2, 132, 199, 0.05) !important;
    border: 1px dashed #0284c7 !important;
    padding: 2px 6px !important;
    border-radius: 4px !important;
    color: #0f172a !important;
}

/* Impedir que a coluna de nome quebre em duas linhas */
#tabelaElenco td.nomeJogador {
    min-width: unset !important;
    white-space: nowrap !important;
}

/* Alinhamento de textos das tabelas na aba Elenco */
.tableHolder th,
.tableHolder td {
    text-align: center !important;
}

/* Estilo para a sigla/texto de Posição */
.posicao {
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    color: #64748b !important;
    letter-spacing: 0.5px !important;
    display: inline-block !important;
    margin-top: 3px !important;
}

/* Correção de alinhamento do uniforme e fotos no campinho */
div[id*="draggable"] img {
    margin: 0 auto !important;
    display: block !important;
}

/* Container de mídia (Uniforme + Foto do Jogador) no campinho */
.pitch-player-media {
    display: inline-flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 4px !important;
    width: 100% !important;
    margin-bottom: 3px !important;
}

.pitch-player-media img.pitch-uniform {
    height: 52px !important;
    width: auto !important;
    display: block !important;
    margin: 0 !important;
}

.pitch-player-media img.pitch-photo {
    height: 38px !important;
    width: 38px !important;
    flex-shrink: 0 !important;
    aspect-ratio: 1 / 1 !important;
    border-radius: 50% !important;
    object-fit: cover !important;
    border: 1.5px solid #ffffff !important;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2) !important;
    display: block !important;
    margin: 0 !important;
}

/* Capitão e Cobradores Form styles */
#cobradoresCapitao {
    margin-top: 30px !important;
    padding: 24px !important;
    background: rgba(15, 23, 42, 0.02) !important;
    border: 1px solid rgba(0, 0, 0, 0.08) !important;
    border-radius: 12px !important;
}

#formCapitaoCobrancas {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
    width: 100% !important;
}

#cobradoresCapitao label {
    font-family: 'Kanit', sans-serif !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    color: #1e293b !important;
    margin-bottom: 2px !important;
}

#cobradoresCapitao select {
    padding: 10px 14px !important;
    border-radius: 8px !important;
    border: 1px solid rgba(0,0,0,0.15) !important;
    background: #ffffff; /* Sem !important para permitir o background de alerta em vermelho (lightcoral) injetado pelo jQuery */
    color: #1e293b !important;
    font-size: 0.9rem !important;
    margin-bottom: 8px !important;
    outline: none !important;
    transition: all 0.2s !important;
}

#cobradoresCapitao select:focus {
    border-color: #0284c7 !important;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.1) !important;
}

#cobradoresCapitao .submit-btn {
    align-self: center !important;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important;
    color: #ffffff !important;
    border: none !important;
    padding: 12px 36px !important;
    border-radius: 8px !important;
    font-family: 'Kanit', sans-serif !important;
    font-weight: 600 !important;
    font-size: 1rem !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2) !important;
    margin-top: 15px !important;
    min-width: 200px !important;
}

#cobradoresCapitao .submit-btn:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 15px rgba(16, 185, 129, 0.3) !important;
    filter: brightness(1.1) !important;
}

#cobradoresCapitao .submit-btn:active {
    transform: translateY(0) !important;
}

/* Custom CSS fixes for mobile and usability */

/* 1. Prevent overlapping/collision of info in table cells and override legacy styles */
#tabelaElenco td,
#tabelaElenco td.nopadding {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    padding: 10px 0 !important;
    gap: 12px !important;
    flex-wrap: wrap !important;
    width: 100% !important;
    text-align: left !important;
    box-sizing: border-box !important;
}

#tabelaElenco td span {
    text-align: inherit;
    display: inline-block;
}

#tabelaElenco td.cell-value,
#tabelaElenco td .cell-value {
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    text-align: right !important;
    flex: 1 !important;
    flex-wrap: wrap !important;
    gap: 4px !important;
    color: #1e293b;
    font-weight: 500;
}

/* 2. Elenco Inline Actions */
.actions-cell {
    display: flex !important;
    gap: 6px !important;
    align-items: center !important;
    justify-content: center !important;
    border-bottom: none !important;
}
.quick-move-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 28px !important;
    height: 28px !important;
    border-radius: 6px !important;
    background: rgba(2, 132, 199, 0.08) !important;
    color: #0284c7 !important;
    text-decoration: none !important;
    transition: all 0.2s ease !important;
}
.quick-move-btn:hover {
    background: #0284c7 !important;
    color: #ffffff !important;
    transform: scale(1.1) !important;
}
.quick-move-btn.demote-titular-btn,
.quick-move-btn.demote-reserva-btn {
    background: rgba(245, 158, 11, 0.08) !important;
    color: #d97706 !important;
}
.quick-move-btn.demote-titular-btn:hover,
.quick-move-btn.demote-reserva-btn:hover {
    background: #f59e0b !important;
    color: #ffffff !important;
}
.quick-move-btn span {
    font-size: 1.1rem !important;
}

/* 3. Mobile responsive styles under 768px */
@media screen and (max-width: 768px) {
    /* Center header meta blocks (uniforms, stadium, and presentation button) */
    .team-header-flex-wrapper {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    .team-header-title-container {
        flex-direction: column !important;
        align-items: center !important;
        text-align: center !important;
    }
    .team-header-title-container .propostas-title {
        text-align: center !important;
    }
    .team-header-meta-container {
        justify-content: center !important;
        width: 100% !important;
    }

    /* Elenco tab mobile tweaks - hide middle action buttons as we now have inline sets */
    #Elenco > div:not(.tableHolder) {
        display: none !important;
    }
    .tableHolder {
        padding: 12px !important;
    }

    /* Transform Elenco tables to modern cards */
    .tableHolder table,
    .tableHolder tbody,
    .tableHolder tr {
        display: flex !important;
        flex-direction: column !important;
        width: 100% !important;
    }
    
    .tableHolder thead {
        display: none !important;
    }
    
    .tableHolder tr {
        background: #ffffff !important;
        border: 1px solid rgba(0, 0, 0, 0.08) !important;
        border-radius: 12px !important;
        padding: 16px !important;
        margin-bottom: 15px !important;
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.02) !important;
        box-sizing: border-box !important;
    }
    
    #tabelaTitulares tr {
        border-left: 4px solid #10b981 !important;
    }
    #tabelaReservas tr {
        border-left: 4px solid #3b82f6 !important;
    }
    #tabelaSuplentes tr {
        border-left: 4px solid #94a3b8 !important;
    }
    
    .tableHolder td {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 8px 0 !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.04) !important;
        font-size: 0.85rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }
    
    .tableHolder td.nomeJogador {
        justify-content: center !important;
        flex-direction: column !important;
        border-bottom: 2px solid rgba(0,0,0,0.06) !important;
        padding-bottom: 10px !important;
        margin-bottom: 6px !important;
        text-align: center !important;
    }
    .tableHolder td.nomeJogador::before {
        display: none !important;
    }
    
    .tableHolder td:last-child {
        border-bottom: none !important;
        justify-content: center !important;
        padding-top: 10px !important;
    }
    .tableHolder td:last-child::before {
        display: none !important;
    }
    
    .tableHolder td::before {
        content: attr(data-label);
        font-family: 'Montserrat', sans-serif;
        font-size: 0.75rem;
        font-weight: 700;
        color: #64748b;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        display: inline-block;
        margin-right: 15px;
        flex-shrink: 0;
    }

    .propostas-card {
        padding: 15px !important;
    }

    /* Tactical pitch responsiveness (Fit 100% on screen width to avoid drag conflicts) */
    .pitch-scroll-wrapper {
        display: flex !important;
        justify-content: center !important;
        width: 100% !important;
        overflow-x: hidden !important;
    }
    #sortable {
        display: grid !important;
        grid-template-columns: repeat(5, 1fr) !important;
        grid-template-rows: repeat(6, 1fr) !important;
        width: 100% !important;
        max-width: 340px !important;
        height: 270px !important;
        border-radius: 12px !important;
        padding: 4px !important;
        box-sizing: border-box !important;
        margin: 0 auto !important;
    }
    #sortable > div {
        float: none !important;
        width: 100% !important;
        height: 100% !important;
        margin: 0 !important;
        padding: 3px !important; /* tiny spacing inside grid cell */
        display: flex !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        box-sizing: border-box !important;
        position: relative !important;
        min-width: 0 !important; /* CRITICAL FIX: prevents columns from expanding to fit text length */
        overflow: hidden !important;
    }
    /* Hide uniforms and player photos in tactical field for mobile simplification */
    .pitch-player-media {
        display: none !important;
    }
    #sortable > div p, .goleiro p {
        font-size: 0.52rem !important;
        padding: 2px !important;
        border-radius: 4px !important;
        text-overflow: ellipsis !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        width: 100% !important;
        box-sizing: border-box !important;
        margin: 0 !important;
        /* Esports diagonal style to fit longer names dynamically */
        transform: rotate(-8deg) !important;
        text-align: center !important;
    }
    /* Adjust badges (Am / Aa style) positions (keep them inside the box to avoid clipping) */
    .Am, .Aa {
        font-size: 0.48rem !important;
        padding: 0 2px !important;
        top: 2px !important;
        right: 2px !important;
        min-width: 12px !important;
    }
}
