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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    background: linear-gradient(135deg, #000000 0%, #000000 100%);
    /* background: linear-gradient(135deg, #C91F3C 0%, #2a5298 100%); */
    min-height: 100vh;
    padding: 20px;
    padding-bottom: 80px; /* Space for fixed footer */
}

.container {
    max-width: 1400px;
    margin: 0 auto;
}

header {
    background: #EAEAEB;
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    margin-bottom: 30px;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

h1 {
    color: #C91F3C;
    font-size: 3em;
    margin-bottom: 0;
    font-weight: 800;
}

.donations-display {
    position: absolute;
    top: 50%;
    right: 30px;
    transform: translateY(-50%);
    background: linear-gradient(135deg, #C91F3C 0%, #C91F3C 100%);
    color: #EAEAEB;
    padding: 20px 30px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.3);
    min-width: 200px;
}

.donations-label {
    font-size: 0.9em;
    opacity: 1;
    margin-bottom: 5px;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.donations-amount {
    font-size: 2.5em;
    font-weight: 900;
    text-shadow: 2px 2px 4px #EAEAEB,;
    animation: countUp 0.5s ease-out;
}

@keyframes countUp {
    from {
        transform: scale(1.2);
        opacity: 0.5;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.donations-updated {
    font-size: 0.75em;
    opacity: 0.8;
    margin-top: 5px;
}


@media (max-width: 768px) {
    header {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    h1 {
        font-size: 2em;
        margin-bottom: 16px;
    }
    .donations-display {
        position: static;
        transform: none;
        margin: 0 0 10px 0;
        max-width: 90vw;
        width: 100%;
    }
}

footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    padding: 15px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1000;
}

.status {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 20px;
    background: #f0f0f0;
    border-radius: 25px;
    font-size: 0.85em;
    transition: opacity 0.3s, transform 0.3s;
}

.status.hidden {
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ccc;
    animation: pulse 2s infinite;
}

.status-dot.connected {
    background: #10b981;
}

footer.hidden {
    opacity: 0;
    transform: scale(0.1);
    pointer-events: none;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.view-toggle {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-top: 20px;
}

.view-toggle button {
    padding: 10px 25px;
    border: 2px solid #C91F3C;
    background: #EAEAEB;
    color: #C91F3C;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s;
}

.view-toggle button.active {
    background: #C91F3C;
    color: #EAEAEB;
}

.view-toggle button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Highlight View Styles */
.highlight-view {
    display: none;
}

.highlight-view.active {
    display: block;
}

/* Donations View Styles */
.donations-view {
    display: none;
}

.donations-view.active {
    display: block;
}

.highlight-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 60px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    text-align: center;
    color: #EAEAEB;
    animation: highlightPulse 0.5s ease-out;
    margin-bottom: 30px;
}

@keyframes highlightPulse {
    0% {
        transform: scale(0.95);
        opacity: 0;
    }
    50% {
        transform: scale(1.02);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.highlight-label {
    font-size: 1.2em;
    opacity: 0.9;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.highlight-item {
    font-size: 4em;
    font-weight: 800;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.highlight-bid {
    font-size: 5em;
    font-weight: 900;
    margin-bottom: 20px;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.4);
}

.highlight-bidder {
    font-size: 2em;
    font-weight: 600;
    margin-bottom: 15px;
    opacity: 0.95;
}

.highlight-time {
    font-size: 1.1em;
    opacity: 0.8;
}

.new-bid-badge {
    display: inline-block;
    background: #10b981;
    color: #EAEAEB;
    padding: 8px 20px;
    border-radius: 20px;
    font-size: 1em;
    font-weight: bold;
    margin-top: 20px;
    animation: badgePulse 2s infinite;
}

@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
}

/* Donations List Styles */
.donations-list {
    display: grid;
    gap: 15px;
    margin-top: 30px;
    max-height: 600px;
    overflow-y: auto;
}

.donation-item {
    background: rgba(255, 255, 255, 0.15);
    padding: 20px;
    border-radius: 12px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s;
}

.donation-item:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-2px);
}

.donation-item.new-donation {
    background: rgba(16, 185, 129, 0.3);
    border-color: rgba(16, 185, 129, 0.5);
    animation: donationPulse 0.5s ease-out;
}

@keyframes donationPulse {
    0% {
        transform: scale(0.95);
        opacity: 0;
    }
    50% {
        transform: scale(1.02);
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.donation-amount {
    font-size: 2.5em;
    font-weight: 900;
    margin-bottom: 8px;
}

.donation-donor {
    font-size: 1.3em;
    font-weight: 600;
    opacity: 0.95;
    margin-bottom: 5px;
}

.donation-time {
    font-size: 0.9em;
    opacity: 0.75;
}

/* Table View Styles */
.table-view {
    display: none;
}

.table-view.active {
    display: block;
}

.bids-table {
    background: #EAEAEB;
    border-radius: 15px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
    overflow: hidden;
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: linear-gradient(135deg, #C91F3C 0%, #C91F3C 100%);
    color: #EAEAEB;
}

th {
    padding: 20px;
    text-align: left;
    font-weight: 600;
    font-size: 1.1em;
    text-transform: uppercase;
    letter-spacing: 1px;
}

th:nth-child(3) {
    text-align: right;
}

tbody tr {
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.3s;
}

tbody tr:hover {
    background: #f8f9fa;
}

tbody tr:last-child {
    border-bottom: none;
}

td {
    padding: 20px;
    font-size: 1.1em;
}

.item-cell {
    font-weight: 600;
    color: #C91F3C;
}

.bid-cell {
    font-weight: 700;
    color: #10b981;
    font-size: 1.3em;
    text-align: right;
}

.bidder-cell {
    color: #666;
    font-style: italic;
}

@media (max-width: 600px) {
    .item-cell,
    .bidder-cell {
        padding: 6px 8px;
    }
    .bid-cell {
        text-align: left;
        padding: 6px 8px;
    }
    th:nth-child(3) {
        text-align: left;
    }
}

.empty-state {
    background: #EAEAEB;
    padding: 80px;
    border-radius: 15px;
    text-align: center;
    color: #999;
    box-shadow: 0 10px 40px rgba(0,0,0,0.2);
}

.empty-state h3 {
    margin-bottom: 10px;
    color: #666;
    font-size: 2em;
}

.empty-state p {
    font-size: 1.2em;
}

/* Loading spinner */
.spinner {
    border: 4px solid rgba(255,255,255,0.3);
    border-top: 4px solid #EAEAEB;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
