/* Reset CSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body */
body {
    font-family: tahoma;
    background: url('/banner.png') no-repeat center center/cover;
    color: white;
    text-align: center;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.header {
    background: rgba(0, 0, 0, 0.8);
    padding: 5px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.header .logo {
    font-size: 24px;
    font-weight: bold;
}

/* Navigation */
.nav a {
    color: white;
    text-decoration: none;
    padding: 10px;
    background-color: #007BFF;
    border-radius: 5px;
}

.nav a:hover {
    background-color: #004494;
}

/* Menu */
.menu-btn {
    background: none;
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    padding: 10px;
}

.menu-container {
    position: absolute;
    top: 60px;
    right: 10px;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 5px;
    display: none;
    flex-direction: column;
    width: 200px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.menu-container a {
    color: white;
    text-decoration: none;
    padding: 10px;
    display: block;
}

.menu-container a:hover {
    background: rgba(255, 255, 255, 0.2);
}

.show-menu {
    display: flex;
}

/* Container */
.container {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: flex-start; /* Thay đổi từ center sang flex-start */
    min-height: 80vh;
    padding: 20px;
    gap: 20px;
    flex-wrap: wrap;
}

/* Content */
.content {
    background: rgba(0, 0, 0, 0.7);
    padding: 20px;
    border-radius: 10px;
    max-width: 800px;
    width: 100%;
}

.form-container {
    background: rgba(0, 0, 0, 0.6);
    padding: 20px;
    border-radius: 10px;
    width: 90%;
    max-width: 500px; /* Wider form, capped at 500px */
    text-align: center;
    color: white;
    box-shadow: 0 0 10px rgba(255, 255, 255, 0.2);
}

/* Form Elements */
input, select {
    width: 100%;
    padding: 10px;
    margin: 5px 0;
    border: 1px solid #ccc;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.1);
    color: white;
}

input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

select {
    border: none;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 10px 20px;
    margin: 10px;
    text-decoration: none;
    color: white;
    background-color: #007BFF;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn:hover {
    background-color: #0056b3;
}

.btn-home {
    background-color: #28a745;
}

.btn-home:hover {
    background-color: #218838;
}

.btn-logout {
    background-color: #DC3545;
}

.btn-logout:hover {
    background-color: #992332;
}

.btn-admin {
    background-color: #FFC107;
    color: black;
}

.btn-admin:hover {
    background-color: #c5862a;
}

/* === STYLE MỚI === */
.btn-details {
    background-color: #5cb85c; /* Màu xanh lá cây */
    width: calc(100% - 20px); /* Trừ đi margin */
    text-align: center;
}
.btn-details:hover {
    background-color: #4cae4c;
}
/* === KẾT THÚC STYLE MỚI === */

.btn-small {
    padding: 5px 10px;
    font-size: 14px;
}

.button-group {
    display: flex;
    justify-content: center;
    gap: 10px;
}

/* Footer */
.footer {
    background: rgba(0, 0, 0, 0.8);
    padding: 10px;
    width: 100%;
    margin-top: auto;
}

.footer a {
    color: #ddd;
    text-decoration: none;
    margin: 0 10px;
}

.footer a:hover {
    color: #fff;
}

/* Messages */
.message {
    margin: 10px 0;
    font-weight: bold;
}

.success {
    color: #28a745;
}

.error {
    color: #DC3545;
}

.warning {
    color: orange;
}

/* Toggle Password */
.toggle-password {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 18px;
    user-select: none;
}

/* Dashboard Specific */
.info, .update-form {
    background: rgba(0, 0, 0, 0.6);
    padding: 20px;
    border-radius: 10px;
    width: 45%;
    min-width: 300px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 15px 0;
    background: rgba(0, 0, 0, 0.8);
    border-radius: 10px;
    padding: 10px;
}

table, th, td {
    border: 1px solid white;
}

th, td {
    padding: 10px;
    text-align: center;
}

/* === STYLE MỚI === */
/* Áp dụng riêng cho bảng nạp tiền */
table.donation-table th, 
table.donation-table td {
    text-align: left;
    padding-left: 15px;
}
table.donation-table td:last-child {
    text-align: right;
    padding-right: 15px;
    font-weight: bold;
    color: #5cb85c; /* Màu xanh lá */
}
/* Căn giữa cho nút */
table.donation-table tr:last-child td {
    text-align: center;
    padding: 0;
}
/* === KẾT THÚC STYLE MỚI === */


/* Nạp tiền Specific */
.responsive-img {
    width: 80%;
    height: auto;
}

/* Media Queries */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
        align-items: center;
    }
    .info, .update-form {
        width: 90%;
        margin-bottom: 20px;
    }
    table {
        border: none;
        background: transparent;
    }
    table tr {
        display: block;
        margin-bottom: 10px;
        background: rgba(0, 0, 0, 0.6);
        padding: 10px;
        border-radius: 10px;
    }
    table th {
        display: block;
        text-align: left;
        font-weight: bold;
    }
    table td {
        display: block;
        text-align: left;
    }
    
    /* === STYLE MỚI (Responsive) === */
    table.donation-table td:last-child {
        text-align: left; /* Reset cho mobile */
        padding-right: 15px;
    }
    table.donation-table tr:last-child td {
        text-align: left; /* Reset cho mobile */
        padding: 10px; /* Thêm padding lại */
    }
    .btn-details {
        width: 100%; /* Full width trên mobile */
        margin: 0;
    }
    /* === KẾT THÚC STYLE MỚI === */

    .toggle-password {
        right: 40px;
    }
}
