body {
    font-family: Arial, Helvetica, sans-serif;
    margin: 0;
    padding: 0;
    background-color: #f5f5f5;
}

.container {
    max-width: 800px;
    margin: 2rem auto;
    background: #fff;
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    position: relative;
}

h1, h2 {
    color: #333;
}

button {
    background-color: #0069d9;
    color: #fff;
    border: none;
    padding: 0.6rem 1.2rem;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background-color: #0053a6;
}

input, select, textarea {
    width: 100%;
    padding: 0.5rem;
    margin-top: 0.3rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc;
    border-radius: 4px;
}

/* Attendee poll form alignment */
.question {
    margin-bottom: 1rem;
}

.question p {
    margin: 0 0 0.5rem 0;
}

label.option-line {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0;
}

label.option-line input[type="radio"] {
    width: auto;
    margin: 0;
}

label.option-line .option-text {
    line-height: 1.3;
}

#vote-form button[type="submit"] {
    margin-top: 0.75rem;
}

/* Simple top-right timer text with label */
#timer {
    position: absolute;
    top: 0.5rem;
    right: 0.75rem;
    font-weight: 600;
    color: #333;
    background: #eef3ff;
    border: 1px solid #dbe3ff;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-variant-numeric: tabular-nums;
}
#timer::before {
    /* Icon + label before the numeric time */
    content: 'Time Remaining: ';
    color: #2a3b8f;
    margin-right: 0.35rem;
    padding-left: 18px; /* space for the icon */
    background-repeat: no-repeat;
    background-size: 14px 14px;
    background-position: left center;
    background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' width='14' height='14' fill='none' stroke='%232a3b8f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><circle cx='12' cy='13' r='8'/><path d='M12 9v4l3 2'/><path d='M9 2h6'/></svg>");
}

/* Status dots for admin list */
.status-dot {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    box-shadow: 0 0 8px currentColor;
    margin-left: 0.25rem;
}
.status-dot.active { color: #2e7d32; background-color: #2e7d32; }
.status-dot.inactive { color: #b00020; background-color: #b00020; }
.status-dot.expired { color: #f57c00; background-color: #f57c00; }

/* Collapsible block */
.collapsible { display: none; }
.collapsible.open { display: block; }

/* (replaced icon with text label via ::before) */

/* Admin row actions alignment */
.row-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}
.row-actions button {
    padding: 0.4rem 0.8rem;
}

/* Per-row collapsible panels styling */
.poll-row {
    margin-bottom: 0.75rem;
}
.poll-row .row-results,
.poll-row .row-leaderboard {
    background: #fafafa;
    border: 1px solid #eee;
    border-radius: 6px;
    padding: 0.5rem;
}
.poll-row pre.json {
    background: #f7f7f7;
    border: 1px solid #eee;
    border-radius: 6px;
    padding: 0.5rem;
}
.row-leaderboard ol {
    margin: 0;
    padding-left: 1.25rem;
}
.row-leaderboard strong {
    font-weight: 600;
}

/* Ensure status label aligns nicely */
.poll-row .status-label {
    vertical-align: middle;
}

/* Compact button for inline actions */
.mini-btn {
    background-color: #0069d9;
    color: #fff;
    border: none;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
}
.mini-btn:disabled { opacity: 0.7; cursor: default; }

/* Badges */
.badge {
    display: inline-block;
    padding: 0.15rem 0.5rem;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
}
.badge.offline {
    background: #fff3cd;
    color: #8a6d3b;
    border: 1px solid #ffeeba;
}

/* Validation highlight */
.invalid-block {
    border: 1px solid #b00020 !important;
    background: #fff8f8 !important;
    border-radius: 6px;
}