/* =========================================
   BUTTONS, TABS & INPUTS
   ========================================= */
.reset-all-btn {
    background-color: #16162A;
    color: #FF5252;
    border: 1px solid #FF5252;
    border-radius: 8px;
    padding: 0 16px;
    font-size: 13px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    height: 32px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: auto;
    margin-bottom: 2px;
}

.reset-all-btn:hover {
    background-color: #FF5252;
    color: #FFF;
    box-shadow: 0 0 8px rgba(255, 82, 82, 0.5);
}

.btn-danger {
    flex: 1;
    padding: 10px;
    background: #FF5252;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
}

.btn-secondary {
    flex: 1;
    padding: 10px;
    background: #2A2A4A;
    color: #fff;
    border: none;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
}

.main-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 2px solid #2A2A4A;
    padding-bottom: 8px;
    align-items: flex-end;
}

.main-tab {
    flex: 1;
    background: transparent;
    border: none;
    color: #8888BB;
    font-size: 16px;
    font-weight: bold;
    padding: 8px 0;
    cursor: pointer;
    transition: color 0.3s;
}

.main-tab.active {
    color: #FFD700;
    border-bottom: 3px solid #FFD700;
    margin-bottom: -11px;
}

.toggle-container {
    display: flex;
    background-color: #16162A;
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 16px;
    border: 1px solid #2A2A4A;
}

.toggle-container input[type="radio"] {
    display: none;
}

.toggle-container label {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    font-size: 14px;
    font-weight: bold;
    color: #8888BB;
    cursor: pointer;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.toggle-container input[type="radio"]:checked+label {
    background-color: #7B3FF2;
    color: #FFFFFF;
}

.lang-toggle {
    display: flex;
    gap: 4px;
    background-color: #16162A;
    padding: 4px;
    border-radius: 8px;
    border: 1px solid #2A2A4A;
    width: max-content;
}

.lang-btn {
    background: transparent;
    border: none;
    color: #8888BB;
    font-size: 12px;
    font-weight: bold;
    cursor: pointer;
    padding: 4px 10px;
    border-radius: 4px;
    transition: background 0.3s, color 0.3s;
}

.lang-btn.active {
    background-color: #7B3FF2;
    color: #FFFFFF;
}

/* Configuração dos Selects */
select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    border-radius: 8px;
    padding-right: 32px;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237B3FF2' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
}

select option {
    border-radius: 8px;
    background-color: #16162A;
    color: #E8E8FF;
    padding: 8px;
}

.mini-select,
.mini-tick,
.tick-display,
#team-tower-percent {
    background-color: #1E1E38;
    color: #E8E8FF;
    border: 1px solid #4A4A6A;
    border-radius: 8px;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: bold;
    outline: none;
    box-sizing: border-box;
    transition: border-color 0.2s, box-shadow 0.2s;
    text-align: center;
}

.mini-select:focus,
.mini-tick:focus,
.tick-display:focus,
#team-tower-percent:focus {
    border-color: #7B3FF2;
    box-shadow: 0 0 6px rgba(123, 63, 242, 0.4);
}

.slot-input {
    width: 100%;
    padding: 6px 28px 6px 10px;
    border-radius: 8px;
    border: 1px solid #4A4A6A;
    background-color: #1E1E38;
    color: #E8E8FF;
    font-size: 12px;
    text-align: center;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
    margin: 0;
}

.slot-input:focus {
    border-color: #7B3FF2;
    box-shadow: 0 0 6px rgba(123, 63, 242, 0.4);
}

.slot-input:disabled {
    background-color: #16162A !important;
    border-color: transparent !important;
    color: #4A4A6A !important;
    -webkit-text-fill-color: #4A4A6A !important;
    cursor: not-allowed;
}

.slot-input[type="number"]::-webkit-inner-spin-button,
.slot-input[type="number"]::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.slot-input[type="number"] {
    -moz-appearance: textfield;
}

/* FIXADO O ALINHAMENTO DO SELECT DE TORRE E LÍDER */
.leader-select {
    width: auto;
    max-width: 180px;
    padding: 6px 28px 6px 10px;
    font-size: 14px;
    font-weight: bold;
    color: #FFD700;
    background-color: #1E1E38;
    border: 1px solid #4A4A6A;
    border-radius: 8px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23FFD700' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-size: 16px;
    text-align: left;
}

#team-tower-percent.leader-select {
    text-align: left;
    text-align-last: left;
    padding-left: 12px;
}

.custom-checkbox-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 8px;
    width: 100%;
    cursor: pointer;
    justify-content: center;
}

.custom-checkbox-wrapper input {
    display: none;
}

.checkmark {
    width: 18px;
    height: 18px;
    background-color: #1E1E38;
    border: 2px solid #2A2A4A;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.custom-checkbox-wrapper input:checked+.checkmark {
    background-color: #7B3FF2;
    border-color: #7B3FF2;
}

.custom-checkbox-wrapper input:checked+.checkmark::after {
    content: '✔';
    color: white;
    font-size: 12px;
}

.checkbox-label {
    font-size: 11px;
    color: #8888BB;
    text-align: left;
}

.custom-number-wrapper {
    position: relative;
    width: 100%;
    margin-bottom: 5px;
}

.custom-spinners {
    position: absolute;
    right: 3px;
    top: 3px;
    bottom: 3px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    width: 20px;
}

.spin-up,
.spin-down {
    flex: 1;
    background-color: #2A2A4A;
    border-radius: 4px;
    cursor: pointer;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 14px;
    transition: background-color 0.2s;
}

.spin-up:hover,
.spin-down:hover {
    background-color: #4A4A6A;
}

.spin-up {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237B3FF2' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m18 15-6-6-6 6'/%3E%3C/svg%3E");
}

.spin-down {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237B3FF2' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
}

/* FIXADO O CENTRALIZAMENTO DA LINHA */
.global-settings {
    display: flex;
    justify-content: center;
    margin-bottom: 5px !important;
    gap: 12px;
}

.toolbar-line {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 10px;
    margin-bottom: 5px !important;
    background: #16162A;
    padding: 10px;
    border-radius: 8px;
    overflow: hidden;
}

.toolbar-line label {
    font-size: 12px;
    color: #FFD700;
    font-weight: bold;
    text-transform: uppercase;
    white-space: nowrap;
}

.toolbar-line input[type="number"],
.toolbar-line input[type="text"] {
    width: 70px !important;
    max-width: 70px !important;
}

@media (max-width: 850px) {
    .mini-select {
        width: 75px !important;
    }

    .slot-input {
        width: 100%;
    }
}