/* style.css - สำหรับหน้า Public (index.php, donate_cash.php) */
:root {
    --primary-color: #007bff;
    --secondary-color: #6c757d;
    --success-color: #28a745;
    --light-bg: #f8f9fa;
    --text-color: #343a40;
    --white-color: #ffffff;
    --border-color: #dee2e6;
    --shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
}

body {
    font-family: 'Kanit', sans-serif;
    background-color: var(--light-bg);
    margin: 0;
    padding: 20px;
    color: var(--text-color);
    display: flex;
    justify-content: center;
    align-items: flex-start;
    min-height: 100vh;
}

.container {
    background-color: var(--white-color);
    border-radius: 12px;
    box-shadow: var(--shadow);
    padding: 40px;
    width: 100%;
    max-width: 960px;
    box-sizing: border-box;
    animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(15px); }
    to { opacity: 1; transform: translateY(0); }
}

h1, h2 {
    text-align: center;
    color: var(--text-color);
    font-weight: 600;
}

h1 {
    margin-bottom: 30px;
    font-size: 2.2em;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

h2 {
    margin-top: 40px;
    margin-bottom: 20px;
    font-size: 1.8em;
}

.total-amount {
    font-size: 3em;
    font-weight: 700;
    color: var(--success-color);
    text-align: center;
    margin-bottom: 30px;
}

.button-container {
    text-align: center;
    margin-bottom: 40px;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 25px;
    font-size: 1.1em;
    font-weight: 500;
    text-decoration: none;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    margin: 5px;
}

.btn-primary {
    background-color: var(--success-color);
    color: var(--white-color);
}
.btn-primary:hover {
    background-color: #218838;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(40, 167, 69, 0.2);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white-color);
}
.btn-secondary:hover {
    background-color: #5a6268;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(108, 117, 125, 0.2);
}

.form-group {
    margin-bottom: 20px;
}
.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}
.form-group input, .form-group textarea, .form-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1em;
    font-family: 'Kanit', sans-serif;
    box-sizing: border-box;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.form-group input:focus, .form-group textarea:focus, .form-group select:focus {
    border-color: var(--primary-color);
    outline: 0;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}
.form-text-muted {
    font-size: 0.9em;
    color: #6c757d;
    margin-top: 5px;
    display: block;
}

.alert {
    padding: 15px 20px;
    margin-bottom: 20px;
    border-radius: 8px;
    font-weight: 500;
    text-align: center;
}
.alert-success {
    color: #0f5132;
    background-color: #d1e7dd;
    border-color: #badbcc;
}
.alert-error {
    color: #842029;
    background-color: #f8d7da;
    border-color: #f5c2c7;
}

.table-responsive {
    overflow-x: auto;
}
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 0.95em;
}
table th, table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}
table th {
    background-color: var(--light-bg);
    font-weight: 600;
}
table tbody tr:hover {
    background-color: #f1f3f5;
}

.no-data {
    text-align: center;
    padding: 30px;
    color: var(--secondary-color);
    font-size: 1.1em;
    background-color: #f8f9fa;
    border-radius: 10px;
    margin-top: 20px;
}

@media (max-width: 768px) {
    body { padding: 10px; }
    .container { padding: 20px; }
    .btn, .btn-secondary { width: 100%; margin-bottom: 10px; }
    table thead { display: none; }
    table tr {
        display: block;
        margin-bottom: 15px;
        border: 1px solid var(--border-color);
        border-radius: 8px;
        box-shadow: 0 2px 5px rgba(0,0,0,0.05);
    }
    table td {
        display: block;
        text-align: right;
        padding-left: 50%;
        position: relative;
    }
    table td:before {
        content: attr(data-label);
        position: absolute;
        left: 15px;
        width: 45%;
        padding-right: 10px;
        text-align: left;
        font-weight: 600;
    }
}