.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 5px 10px;
    background-color: #2b1005;
    color: white;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.header h1 {
    font-size: 2rem;
    margin: 0;
    flex: 1 1 100%;
}

.header > .button,
.header > .pulse-red,
.header > div {
    margin-top: 5px;
}

@media (max-width: 600px) {
    .header {
        flex-direction: column;
        align-items: flex-start;
        padding: 10px 5px;
    }
    .header h1 {
        font-size: 1.2rem;
        margin-bottom: 8px;
    }
    .button, .pulse-red {
        font-size: 1rem;
        padding: 8px 12px;
        margin: 4px 2px;
        width: auto; /* changed from 100% to auto */
        min-width: 110px; /* ensures buttons are not too small */
        max-width: 100%; /* prevents overflow */
        box-sizing: border-box;
        white-space: nowrap; /* prevents text wrapping */
    }
    .header > div {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        gap: 4px;
        justify-content: flex-start;
    }
}

.button {
    background-color: #af5b4c;
    border: none;
    color: white;
    padding: 5px 10px;
    text-align: center;
    text-decoration: none;
    display: inline-block;
    font-size: 14px;
    margin: 2px 1px;
    cursor: pointer;
    border-radius: 12px;
}

.button:hover {
    background-color: #af814c;
}

.content {
    margin-top: 70px;
    padding: 20px;
}

table {
    border-collapse: collapse;
    width: 100%;
    background-color: #ffffff;
    position: relative;
}

th, td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: center;
}

th {
    background-color: #2b1005;
    color: white;
    position: sticky;
    top: 0;
    z-index: 2;
}

.sticky-row td {
    background-color: #c27251;
    position: sticky;
    top: 57px;
    z-index: 1;
}

.sticky {
    min-width: 80px;
    white-space: normal;
    text-align: center;
    vertical-align: middle;
}

tr:nth-child(even) {
    background-color: #f2f2f2;
}

tr:hover {
    background-color: #ddd;
}

.red {
    background-color: red;
    color: white;
}

.orange {
    background-color: orange;
    color: black;
}

.yellow {
    background-color: yellow;
    color: black;
}

.green {
    background-color: green;
    color: white;
}

.pulse-red {
    animation: pulse-red 0.8s cubic-bezier(0.4,0,0.6,1) infinite;
    background-color: #af5b4c !important;
    color: white !important;
    border: none;
    transition: background-color 0.2s;
    box-shadow: 0 0 0 0 rgba(255,0,0,0.7);
}

@keyframes pulse-red {
    0% {
        background-color: #af5b4c;
        box-shadow: 0 0 0 0 rgba(255,0,0,0.7);
    }
    50% {
        background-color: red;
        box-shadow: 0 0 12px 6px rgba(255,0,0,0.3);
    }
    100% {
        background-color: #af5b4c;
        box-shadow: 0 0 0 0 rgba(255,0,0,0.7);
    }
}

.modal-header {
    background-color: #2b1005;
    color: white;
}

.modal-content {
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.modal-body {
    background-color: #f7f7f7;
    max-width: 400px;
    margin: auto;
    padding: 20px;
    border-radius: 10px;
}

.modal-body table {
    width: 100%;
}

.modal-body td {
    padding: 10px;
    border: 1px solid #ddd;
}

.modal-body tr:nth-child(even) {
    background-color: #e9ecef;
}

.modal-body tr:hover {
    background-color: #dee2e6;
}

.icon-button {
    display: flex;
    align-items: center;
    background-color: transparent;
    border: none;
    cursor: pointer;
    margin-left: 10px;
    padding: 0;
    text-decoration: none;
    color: white;
}

.icon-image {
    width: 80px; /* Updated width */
    height: 50px; /* Updated height */
    vertical-align: middle;
    margin-right: 8px;
}

.icon-title {
    font-size: 18px; /* Adjusted font size */
    font-weight: bold;
    color: white;
}

#donateBtn {
    margin-left: 10px;
}

.modal-dialog {
    /* Remove static positioning for custom placement */
    position: fixed;
    margin: 0;
    top: var(--modal-top, 50%);
    left: var(--modal-left, 50%);
    transform: translate(-50%, -50%);
    max-width: 95vw;
    z-index: 1050;
}

@media (max-width: 600px) {
    .modal-dialog {
        position: fixed;
        margin: 0;
        top: var(--modal-top, 50%);
        left: var(--modal-left, 50%);
        transform: translate(-50%, -50%);
        max-width: 98vw;
        z-index: 1050;
    }
}
