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

body {
    font-family: 'Arial', sans-serif;
    background: #f8f9fa;
    color: #1a1a1a;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    max-width: 800px;
    width: 100%;
}

h1 { font-size: 1.8rem; margin-bottom: 8px; }
h2 { font-size: 1.3rem; margin-bottom: 12px; color: #333; }

.subtitle { color: #666; font-size: 0.9rem; margin-bottom: 24px; }

/* Join screen */
.join-screen { text-align: center; }
.join-screen input {
    font-size: 1.1rem;
    padding: 12px 20px;
    border: 2px solid #1a1a1a;
    width: 300px;
    margin: 16px 0;
    display: block;
    margin-left: auto;
    margin-right: auto;
}
.join-screen button { margin-top: 8px; }

/* Buttons */
button {
    font-size: 1rem;
    padding: 12px 24px;
    background: #1a1a1a;
    color: white;
    border: none;
    cursor: pointer;
    font-weight: bold;
}
button:hover { background: #333; }
button:disabled { background: #ccc; cursor: not-allowed; }

/* Waiting */
.waiting { text-align: center; }
.waiting .pulse {
    display: inline-block;
    width: 12px; height: 12px;
    background: #e85d04;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
    margin-right: 8px;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.3; } }

/* Question */
.question-screen { display: none; }
.question-number { font-size: 0.8rem; color: #666; text-transform: uppercase; letter-spacing: 1px; margin-bottom: 8px; }
.product-name { font-size: 1.4rem; font-weight: bold; margin-bottom: 4px; }
.product-desc { font-size: 0.85rem; color: #555; margin-bottom: 16px; }
.scenario {
    background: #fff;
    border-left: 4px solid #e85d04;
    padding: 16px;
    margin-bottom: 20px;
    font-size: 1rem;
    line-height: 1.5;
}

/* Vote buttons */
.vote-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.vote-btn {
    padding: 16px;
    font-size: 0.95rem;
    border: 2px solid #ddd;
    background: #fff;
    color: #1a1a1a;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s;
}
.vote-btn:hover { border-color: #1a1a1a; background: #f5f5f5; }
.vote-btn.selected { border-color: #e85d04; background: #fff3e0; }
.vote-btn .label { font-weight: bold; display: block; margin-bottom: 4px; }
.vote-btn .desc { font-size: 0.8rem; color: #666; }

.vote-btn.negligible.selected { border-color: #4caf50; background: #e8f5e9; }
.vote-btn.minor.selected { border-color: #ff9800; background: #fff8e1; }
.vote-btn.serious.selected { border-color: #f44336; background: #ffe0b2; }
.vote-btn.critical.selected { border-color: #9c27b0; background: #ffebee; }

/* Voted confirmation */
.voted-msg { text-align: center; margin-top: 20px; color: #4caf50; font-weight: bold; display: none; }

/* Results */
.results-screen { display: none; }
.tier-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin: 20px 0; }
.tier-col { padding: 12px; text-align: center; min-height: 120px; }
.tier-col h3 { font-size: 0.8rem; margin-bottom: 8px; }
.tier-col .products { font-size: 0.85rem; line-height: 1.6; }
.tier-r1 { background: #e8f5e9; }
.tier-r2 { background: #fffde7; }
.tier-r3 { background: #fbe9e7; }
.tier-r4 { background: #f3e5f5; }

.summary-text {
    background: #fff;
    border: 1px solid #e0e0e0;
    padding: 20px;
    margin-top: 16px;
    white-space: pre-wrap;
    line-height: 1.6;
    font-size: 0.95rem;
}

/* Facilitator */
.facilitator { max-width: 900px; }
.participant-list { margin: 12px 0; font-size: 0.9rem; color: #555; }
.vote-chart { margin: 16px 0; }
.bar-row { display: flex; align-items: center; margin-bottom: 6px; }
.bar-label { width: 100px; font-size: 0.85rem; font-weight: bold; }
.bar-track { flex: 1; height: 28px; background: #eee; position: relative; }
.bar-fill { height: 100%; transition: width 0.3s; display: flex; align-items: center; padding-left: 8px; font-size: 0.8rem; color: #fff; font-weight: bold; }
.bar-fill.negligible { background: #4caf50; }
.bar-fill.minor { background: #ff9800; }
.bar-fill.serious { background: #f44336; }
.bar-fill.critical { background: #9c27b0; }

.controls { margin: 20px 0; }
.controls button { margin-right: 10px; }

.timer { font-size: 1.2rem; font-weight: bold; color: #e85d04; margin-left: 16px; }
