/* Reset e Estilo Geral */
body {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    background-image: url(https://static.tibia.com/images/global/header/background-artwork.webp);
    background-position: center top;
    background-color: #051122;
    background-repeat: no-repeat;
    zoom: 130%;    
    font-size: 14px; 
}

/* Estilização Navbar */
.navbar {
    background-color: #0000005e;
    padding: 10px 0;
    display: flex;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.navbar-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.nav-buttons {
    display: flex;
    gap: 10px;
}

/* Botões com imagens */
.image-button {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 120px;
    height: 40px;
    border: none;
    background: none;
    cursor: pointer;
    padding: 0;
    text-align: center;    
    text-decoration: none;
}

.image-button .button-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    cursor: pointer;
}

.image-button .button-img.hover {
    opacity: 0;
    cursor: pointer;
}

.image-button:hover .button-img.hover {
    opacity: 1;
}

.image-button:hover .button-img.default {
    opacity: 0;
}

.image-button span {
    position: relative;
    color: white;
    font-size: 14px;
    font-weight: bold;
    z-index: 1;
    pointer-events: none;
}

/* Layout Principal */
.main-container {
    display: flex;
    justify-content: center;
    padding: 20px;
    gap: 20px;
    max-width: 1200px;
    margin: auto;
    box-sizing: border-box;
}

/* Estilização do Menu Lateral (Sidebar) */
.sidebar {
    width: 200px;
    padding: 20px;
    box-sizing: border-box;
    color: white;
    font-family: Arial, sans-serif;
}

.sidebar ul {
    list-style-type: none;
    padding: 0;
}

.sidebar li {
    margin: 15px 0;
}

.sidebar p {
    color: white;
    font-size: 9px;
    margin-left: 25px;
    font-family: Verdana, Geneva, Tahoma, sans-serif;
}

.sidebar a {
    display: flex;
    align-items: center;
    color: white;
    text-decoration: none;
    font-size: 16px;
    font-weight: bold;
    position: relative;
    padding-left: 10px;
    padding-right: 10px;
    height: 40px;
    background-size: cover;
    background-position: center;
}

.sidebar a .button-img.default {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.sidebar a .button-img.hover {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0;
}

.sidebar a:hover .button-img.default {
    opacity: 0;
}

.sidebar a:hover .button-img.hover {
    opacity: 1;
}

/* Conteúdo Principal */
.content {
    flex: 1;
    background-image: url(../background/background.gif);
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    padding: 20px;
    box-sizing: border-box;
}

/* Footer */
.footer {
    color: rgb(255, 255, 255);
    text-align: center;
    padding: 10px;
    position: relative;
    font-size: 9px;
}

/* Formulário de Login */
.login-container {
    max-width: 400px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #00000052;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.login-container h2 {
    text-align: center;
    margin-bottom: 20px;
}

.login-container label {
    margin-bottom: 8px;
    font-weight: bold;
}

.login-container input {
    width: 95%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: transparent;
}

.error {
    color: red;
    text-align: center;
    margin-bottom: 10px;
    font-weight: bold;
}

.success {    
    color: rgb(56, 184, 56);
}

.login-container p {
    text-align: center;
}

.login-container p a {
    color: #3498db;
    text-decoration: none;
}

.login-container p a:hover {
    text-decoration: underline;
}

/* Formulário de Criar Conta */
.create-account-container {
    max-width: 400px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.create-account-container h2 {
    text-align: center;
    margin-bottom: 20px;
}

.create-account-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
}

.create-account-container input, .create-account-container select {
    width: 95%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #6b3e26;
    border-radius: 4px;
    background-color: transparent;
}

/* Container principal para criar personagem */
.create-character-container {
    max-width: 400px;
    margin: 50px auto;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #000;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
}

.create-character-container h2 {
    text-align: center;
    margin-bottom: 20px;
    color: #6b3e26;
}

.create-character-container p {
    font-weight: bold;
    text-align: center;
}

.create-character-container p.error {
    color: red;
}

.create-character-container p.success {
    color: green;
}

.create-character-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    width: 100%;
}

.create-character-container input,
.create-character-container select {
    width: 95%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: transparent;
}

.create-character-container button {
    width: 80%;
    padding: 10px;
    background-color: #2c3e50;
    color: #fff;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    text-align: center;
    display: flex;
    justify-content: center;
    align-items: center;
}

.create-character-container button:hover {
    background-color: #34495e;
}

/* GAMEMASTERS */
.gamemasters-page {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    border-radius: 8px;
}

h1 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 40px;
    color: #6b3e26;
}

.group-section {
    margin-bottom: 30px;
}

.group-section h2 {
    font-size: 1.5rem;
    color: #6b3e26;
    border-bottom: 2px solid #6b3e26;
    padding-bottom: 5px;
    margin-bottom: 10px;
}

.character-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
}

.character-list li {
    padding: 10px;
    font-size: 1rem;
    border: 1px solid #d0c0a0;
    margin-bottom: 5px;
    border-radius: 4px;
}

.brown-light-form {
    border-radius: 4px;
    color: #6b3e26;
}

.brown-light {
    background-color: #f4e2c6;
    border-radius: 4px;
    color: #6b3e26;
}

.brown-dark {
    background-color: #e0cba9;
    border-radius: 4px;
    color: #6b3e26;
}

.character-list li:nth-child(odd) {
    background-color: #f4e2c6;
}

.character-list li:nth-child(even) {
    background-color: #e0cba9;
}

/* Highscores */
.highscores-container {
    display: flex;
    justify-content: space-between;
}

.highscores-options {    
    width: 13%;
    float: left;
    border: 1px solid #5A2800;
    border-radius: 5px;
    padding-left: 5px;
}

.highscores-options ul {
    list-style-type: none;
    padding: 0;
}

.highscores-options li {
    margin-bottom: 10px;
}

.highscores-options a {
    text-decoration: none;
    color: #6b3e26;
    font-weight: bold;
}

.highscores-options a.active {
    color: #c1a679;
}

.highscores-list {
    float: right;
    width: 85%;
}

.highscores-list table {
    width: 100%;
    border-collapse: collapse;
}

.highscores-list th, .highscores-list td {
    padding: 10px;
    text-align: center;
    color: #6b3e26;
}

.highscores-list th {
    background-color: rgba(107, 62, 38, 0.58);
    color: white;
}

.highscores-list th:nth-child(1), .highscores-list td:nth-child(1) {
    width: 10%;
    text-align: center;
}

.highscores-list th:nth-child(2), .highscores-list td:nth-child(2) {
    width: 60%;
    text-align: center;
}

.highscores-list th:nth-child(3), .highscores-list td:nth-child(3) {
    width: 15%;
    text-align: center;
    font-weight: bold;
}

.highscores-list th:nth-child(4), .highscores-list td:nth-child(4) {
    width: 15%;
    text-align: center;
}

/* Downloads */
.download-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.download-card {
    background-color: #d7ccc8;
    border: 1px solid #3e2723;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: relative;
}

.download-card h2 {
    margin: 0 0 10px;
    color: #3e2723;
}

.download-card p {
    margin: 0 0 10px;
    color: #5d4037;
}

.download-card:hover {
    background-color: #a1887f;
    color: #fff;
}

.image-buttondownload {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: absolute;
    bottom: 20px;
    right: 20px;
    text-decoration: none;
    color: #fff;
    font-weight: bold;           
    width: 120px;
    height: 40px;
}

.button-imgdownload {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: 0;
    transition: opacity 0.3s ease;
}

.button-imgdownload.default {
    opacity: 1;
}

.button-imgdownload.hover {
    opacity: 0;
}

.image-buttondownload:hover .button-imgdownload.default {
    opacity: 0;
}

.image-buttondownload:hover .button-imgdownload.hover {
    opacity: 1;
}

.image-buttondownload span {
    z-index: 1;
    position: relative;
}

/* Server Info */
.info-card {
    background-color: #d7ccc8;
    border: 1px solid #3e2723;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.info-card h2 {
    margin: 0 0 10px;
    color: #3e2723;
}

.info-card p {
    margin: 5px 0;
    color: #5d4037;
    white-space: pre-wrap;            
    font-size: 12px;
}

.info-card:hover {
    background-color: #a1887f;
    color: #fff;
}

/* Logo */
.logo-image {
    max-width: 250px;
    height: auto;
    cursor: pointer;
    text-align: center;
    margin-left: -65px;
    padding-top: -80px;
    margin-top: -70px;
}

/* DASHBOARD */
.dashboard-container {
    max-width: 1200px;
    margin: 5px auto;    
    margin-bottom: 50px;
    background: #e0cba9;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    text-align: center;
    padding: 20px;
}

.account-status {
    margin-top: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f4e2c6;
    color: #5d4037;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.status-info {
    display: flex;
    align-items: center;
}

.status-info img {
    width: 50px;
    height: 50px;
    margin-right: 15px;
}

.status-info p {
    font-size: 18px;
    margin: 0;
}

.premium {
    color: green;
    font-weight: bold;
}

.free {
    color: red;
    font-weight: bold;
}

.status-info .premium-expiry {
    font-size: 8px;
    font-weight: bold;
    margin-top: 10px;
    margin-left: -154px;
    color: #5d4037;
}

.admin-panel a {
    font-size: 8px;
    font-weight: bold;
    margin-top: 10px;
    margin-left: 15px;
    color: #5d4037;    
    text-decoration: none;
}

.status-info .free-account-info {
    font-size: 8px;
    font-weight: bold;
    margin-top: 10px;
    margin-left: -110px;
    color: #333;
}

.actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

/* Formulário de edição */
#edit-form {
    display: flex;
    flex-direction: column;
}

#edit-form label {
    font-size: 16px;
    margin-bottom: 5px;
}

#edit-form input {
    width: 30%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background-color: transparent;
}

.actionsdashboard {
    display: flex;
    gap: 10px;
}

/* LISTA DE PERSONAGENS */
.characters-list-container {
    margin-top: -20px;
}

.characters-list {
    margin-top: 10px;
    min-width: 800px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #e0cba9;
    color: #5d4037;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.character-name {
    font-size: 1.2em;
    font-weight: bold;
    color: #3e2723;
    text-align: left;
}

.character-details {
    font-size: 9px;
    color: #5d4037;
    margin-top: 1px;
    text-align: left;
}

.characters-list h3 {
    margin-bottom: 10px;
}

#character-list {
    list-style: none;
    padding: 0;
}

#character-list li {
    padding: 5px 0;
    border-bottom: 1px solid #ddd;
}

#character-list li:last-child {
    border-bottom: none;
}

/* Histórico de Doações */
.donate-history-section {
    width: 100%;
}

.donate-history-section h3 {
    font-size: 1.5rem;
    color: #6b3e26;
    padding-bottom: 5px;
    margin-bottom: 20px;
}

.donate-table {
    width: 100%;
    border-collapse: collapse;
}

.donate-table th,
.donate-table td {
    padding: 12px;
    border: 1px solid #d0c0a0;
}

.donate-table thead th {
    background-color: #e0cba9;
    color: #6b3e26;
    text-transform: uppercase;
    text-align: center;
}

.donate-table tbody tr:nth-child(odd) {
    background-color: #f4e2c6;
    color: #6b3e26;
}

.donate-table tbody tr:nth-child(even) {
    background-color: #e0cba9;
    color: #6b3e26;
}

.donate-table tbody tr:hover {
    background-color: #d3b998;
}

/* Status de Transações */
.status-approved {
    color: #28a745;
    font-weight: bold;
}

.status-pending {
    color: #ff9800;
    font-weight: bold;
}

.status-cancelled {
    color: #716d6d;
    font-weight: bold;
}

.status-expired {
    color: #716d6d;
    font-weight: bold;
}

.status-refunded {
    color: #6f42c1;
    font-weight: bold;
}

.status-unknown {
    color: #868e96;
    font-weight: bold;
}

/* Transferências de Coins */
.transferHistory {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: #f4e2c6;
    color: #5d4037;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.transfer-sent {
    color: red;
    text-align: center;
    margin: 5px 0;
}

.transfer-received {
    color: green;
    text-align: center;
    margin: 5px 0;
}

.transfer-purchased {
    color: blue;
    text-align: center;
    margin: 5px 0;
}

.transfer-history {
    max-height: 300px;
    overflow-y: auto;
    background: #e0cba9;
    border: 1px solid #e0cba9;
    padding: 10px;
    border-radius: 5px;
}

.transfer-history p {
    text-align: left;
}

/* Modais */
.modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.5);
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: #f4e2c6;
    margin: 5% auto;
    padding: 20px;
    border: none;
    border-radius: 10px;
    width: 80%;
    max-width: 600px;
    position: relative;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s;
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.modal-content h2 {
    color: #6b3e26;
    text-align: center;
}

.close-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 15px;
    top: 10px;
    z-index: 1001;
}

.close-btn:hover,
.close-btn:focus {
    color: #000;
    text-decoration: none;
    cursor: pointer;
}

/* Modal de Exclusão */
.modal-content-delete {
    background-color: #f4e2c6;
    padding: 20px;
    border-radius: 8px;
    width: 400px;
    text-align: center;
}

.modal-content-delete h3 {
    color: rgb(50, 148, 58);
    font-weight: bold;
    text-transform: uppercase;
}

.modal-content-delete h2 {
    color: #6b3e26;
    font-weight: bold;
    text-transform: uppercase;
}

.modal-content-delete p {
    color: red;
    font-weight: bold;
    text-transform: uppercase;
}

.passwordDelete {
    width: 35%;
    padding: 0.75rem;
    background-color: #f4e2c6;
    border: 1px solid #e2cba7;
    border-radius: 0.5rem;
    margin-top: 0.5rem;
    font-size: 1rem;
    font-weight: bold;
}

.passwordDelete:focus {
    border: 1px solid #e2cba7;
    border-radius: 0.5rem;
    background-color: #5a290050;
}

/* Modal de Transferência */
.modalTransfer {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 400px;
    background-color: #f4e2c6;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    z-index: 1000;
}

.modalTransfer-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 999;
}

.modalTransfer.open, .modalTransfer-overlay.open {
    display: block;
}

.modalTransfer-content {
    display: flex;
    flex-direction: column;
    gap: 10px;
    text-align: center;
}

.modalTransfer-content h2, h3 {
    color: #6b3e26;
    font-weight: bold;
    margin-bottom: 10px;
}

.modalTransfer-content p {
    color: #5d4037;
    margin: 0;
}

.modalTransfer-content label {
    font-weight: bold;
    color: #6b3e26;
    margin-top: 10px;
}

.modalTransfer-content input[type="text"],
.modalTransfer-content input[type="number"],
.modalTransfer-content select {
    width: 95%;
    padding: 10px;
    border: 1px solid #6b3e26;
    border-radius: 4px;
    background-color: transparent;
    text-align: center;
    color: #155724;
    font-size: 16px;
}

.modalTransfer-content .coins-input-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 10px;
}

.modalTransfer-content .coins-input-container input[type="number"] {
    width: 80px;
}

.modalTransfer-content input[type="range"] {
    width: 100%;
    margin-top: 10px;
}

.button-container {
    display: inline;
    justify-content: space-evenly;
    margin-top: 20px;
}

/* Mensagens */
.message {
    padding: 10px;
    margin: 10px 0;
    border-radius: 4px;
    text-align: center;
    font-weight: bold;
}

.message.success {
    background-color: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.message.error {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Modal Simple */
.modalContainer {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.modalContent {
    background-color: #f4e2c6;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
    text-align: center;
    width: 400px;
    max-width: 90%;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #6b3e26;
}

#modalContent img {
    width: 90%;
    border: 3px solid #6b3e26;
    border-radius: 9px;
}

/* PIX Payment Info */
.pix-payment-info {
    font-family: Arial, sans-serif;
}

.payment-details {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.payment-details p {
    margin: 8px 0;
    font-size: 14px;
}

.qr-code-section h4,
.pix-code-section h4,
.pix-instructions h4 {
    color: #6b3e26;
    margin-bottom: 10px;
}

.pix-instructions ol {
    color: #004085;
}

.pix-instructions li {
    margin-bottom: 5px;
}

/* Table Container */
.table-container {
    overflow-x: auto;
}

.table-container table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
}

.table-container th,
.table-container td {
    padding: 8px 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.table-container th {
    background-color: #f8f9fa;
    font-weight: bold;
    position: sticky;
    top: 0;
    z-index: 10;
}

/* Responsividade */
@media (max-width: 992px) {
    .navbar {
        flex-direction: column;
        align-items: center;
    }
    .navbar-buttons {
        flex-wrap: wrap;
        gap: 10px;
        justify-content: center;
    }
    .main-container {
        flex-direction: column;
        padding: 10px;
        gap: 15px;
    }
    .sidebar {
        width: 100%;
    }
    .content {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 15px;
    }
    .navbar-buttons button {
        width: 100px;
        text-align: center;
    }
    .main-container {
        padding: 5px;
    }
    .sidebar {
        width: 180px;
    }
    .sidebar a {
        font-size: 14px;
    }
    .modal-content {
        width: 95%;
        margin: 10% auto;
        padding: 15px;
    }
    #historyModal .modal-content {
        width: 98%;
        max-width: none;
    }
}

@media (max-width: 576px) {
    .navbar-buttons button {
        width: 100%;
    }
    .main-container {
        gap: 10px;
    }
    .sidebar ul li {
        margin-bottom: 10px;
    }
    .content {
        padding: 10px;
    }
}

/* Estilos para ícones de origem */
.donate-table td img {
    transition: transform 0.2s ease;
}

.donate-table td img:hover {
    transform: scale(1.1);
}

/* Melhorar aparência da tabela */
.donate-table th:nth-child(1) { width: 25%; } /* Código */
.donate-table th:nth-child(2) { width: 12%; } /* Coins */
.donate-table th:nth-child(3) { width: 15%; } /* Valor */
.donate-table th:nth-child(4) { width: 15%; } /* Status */
.donate-table th:nth-child(5) { width: 20%; } /* Data */
.donate-table th:nth-child(6) { width: 13%; } /* Origem */

/* Responsividade para ícones */
@media (max-width: 768px) {
    .donate-table td img {
        width: 20px !important;
        height: 20px !important;
    }
}

.character-link {
    color: #6b3e26;
    text-decoration: none;
    transition: all 0.3s;
    font-weight: 500;
    display: block;
    width: 100%;
}

.character-link:hover {
    color: #8b4e36;
    text-decoration: underline;
}
