1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
|
* { box-sizing: border-box; margin: 0; padding: 0; }
html { height: 100%; overflow-y: scroll; }
body { min-height: 900px; font-family: var(--font-family); background: var(--color-background); color: var(--color-text); }
body.poll-view { height: 100%; overflow: hidden; }
.navbar { background: var(--color-navbar-bg); color: var(--color-navbar-text); padding: 0.9rem 0 0.8rem 0; }
.navbar-inner { max-width: var(--layout-max-width); margin: 0 auto; padding: 0 2rem; display: flex; justify-content: space-between; align-items: center; }
.navbar a { color: var(--color-navbar-text); text-decoration: none; }
.brand-group { display: flex; align-items: center; gap: 0.75rem; padding-left: 1rem; }
.brand { font-weight: bold; font-size: var(--font-size-lg); }
.theme-toggle { background: none; border: none; cursor: pointer; color: var(--color-navbar-text); padding: 0.25rem; display: flex; align-items: center; justify-content: center; opacity: 0.8; transition: opacity 0.2s; }
.theme-toggle:hover { opacity: 1; }
.theme-toggle .icon-sun { display: none; }
.theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
[data-theme="dark"] .theme-toggle .icon-moon { display: none; }
.nav-right { display: flex; align-items: center; gap: 1rem; padding-right: 1rem; }
.user-info { background: rgba(255,255,255,0.2); padding: 0.25rem 0.75rem; border-radius: 1rem; font-size: var(--font-size-sm); }
.container { max-width: var(--layout-max-width); margin: 0 auto; padding: 0 2rem; }
body.poll-view .container { padding: 1rem 2rem; height: calc(100vh - 52px); min-height: 848px; display: flex; flex-direction: column; overflow: hidden; }
body:not(.poll-view) .container { padding-top: 2rem; padding-bottom: 2rem; }
.btn { padding: 0.5rem 1rem; border: none; border-radius: var(--layout-border-radius-sm); cursor: pointer; font-size: var(--font-size-base); }
.btn-primary { background: var(--color-primary); color: white; }
.btn-primary:hover { background: var(--color-primary-hover); }
.hero { text-align: center; padding: 3rem 2rem 2rem; }
.hero h1 { font-size: var(--font-size-xl); margin-bottom: 1rem; }
.hero p { font-size: var(--font-size-lg); color: var(--color-text-muted); margin-bottom: 2rem; }
.my-polls-section { margin-top: 2rem; }
.my-polls-section h2 { margin-bottom: 1rem; }
.polls-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
@media (max-width: 800px) { .polls-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 500px) { .polls-grid { grid-template-columns: 1fr; } }
.poll-card { display: block; background: var(--color-surface); padding: 1.25rem; border-radius: var(--layout-border-radius); box-shadow: var(--shadow-sm); text-decoration: none; color: var(--color-text); transition: box-shadow 0.2s, transform 0.2s; }
.poll-card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.poll-card h3 { margin: 0 0 0.5rem; font-size: 1.1rem; color: var(--color-primary); }
.participant-count { font-size: var(--font-size-sm); color: var(--color-text-muted); }
.no-polls, .loading { color: var(--color-text-light); font-style: italic; grid-column: 1 / -1; }
.dashboard { max-width: 800px; margin: 0 auto; }
.dashboard h1 { margin-bottom: 2rem; }
.create-poll, .polls-list { background: var(--color-surface); padding: var(--layout-spacing); border-radius: var(--layout-border-radius); margin-bottom: var(--layout-spacing); box-shadow: var(--shadow-sm); }
.create-poll h2, .polls-list h2 { margin-bottom: var(--layout-spacing-sm); font-size: var(--font-size-lg); }
.create-poll input, .create-poll textarea { width: 100%; padding: 0.75rem; margin-bottom: 1rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-base); }
.create-poll textarea { resize: vertical; min-height: 80px; }
.date-picker-section { margin-bottom: 1rem; }
.date-picker-section label { display: block; font-weight: 600; margin-bottom: 0.5rem; }
.date-picker-section .calendar-nav { margin-bottom: 0.5rem; }
.date-picker-section .calendar { margin-bottom: 0.5rem; }
.date-picker-section .hint { margin-top: 0; margin-bottom: 1rem; }
.polls-list ul { list-style: none; }
.polls-list li { padding: 0.75rem 0; border-bottom: 1px solid var(--color-border-light); }
.polls-list li:last-child { border-bottom: none; }
.polls-list a { color: var(--color-primary); text-decoration: none; }
.poll-header { background: var(--color-surface); padding: var(--layout-spacing); border-radius: var(--layout-border-radius); margin-bottom: var(--layout-spacing); box-shadow: var(--shadow-sm); }
.poll-title-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.5rem; }
.poll-title-row h1 { margin: 0; }
.poll-desc { color: var(--color-text-muted); margin-bottom: 1rem; white-space: pre-line; }
.participants-section { margin-bottom: 0.5rem; display: flex; align-items: center; gap: 0.5rem; flex-wrap: wrap; }
.join-section { margin-bottom: 1rem; display: flex; align-items: center; gap: 0.5rem; }
.join-section input { padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); background: var(--color-input-bg); color: var(--color-text); }
.participants-label { font-weight: 600; color: var(--color-text-muted); }
.participants-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.participant { background: var(--color-primary-light); padding: 0.25rem 0.75rem; border-radius: 1rem; font-size: var(--font-size-sm); cursor: pointer; transition: background 0.15s; }
.participant:hover { background: var(--color-primary); color: white; }
.participant.filtered { background: var(--color-primary); color: white; }
.participant.current-user { background: var(--color-primary-light); color: var(--color-text); box-shadow: inset 0 0 0 2px var(--color-primary); font-weight: 600; }
.participant.current-user:hover { background: var(--color-primary); color: white; }
.participant.current-user.filtered { background: var(--color-primary); color: white; box-shadow: inset 0 0 0 2px var(--color-primary-light); }
.no-participants { color: var(--color-text-light); font-style: italic; }
.share-link { display: flex; gap: 0.5rem; }
.share-link input { flex: 1; padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); background: var(--color-input-bg); color: var(--color-text); }
.status-message { display: none; padding: 0.75rem 1rem; border-radius: var(--layout-border-radius-sm); margin-bottom: var(--layout-spacing); text-align: center; }
.status-message.success { background: var(--color-success-bg); color: var(--color-success); }
.status-message.error { background: var(--color-error-bg); color: var(--color-error); }
.poll-page { display: flex; flex-direction: column; height: calc(100vh - 60px); min-height: 816px; overflow: hidden; position: relative; }
.loading-overlay { position: absolute; top: 0; left: 0; right: 0; bottom: 0; background: var(--color-background); display: flex; align-items: center; justify-content: center; z-index: 100; transition: opacity 0.3s ease-out; }
.loading-overlay.fade-out { opacity: 0; pointer-events: none; }
.loading-overlay.fade-out .loading-spinner { display: none; }
.loading-spinner { width: 48px; height: 48px; border: 4px solid var(--color-border); border-top-color: var(--color-primary); border-radius: 50%; animation: spin 0.8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.poll-header { flex-shrink: 0; }
.poll-content { display: grid; grid-template-columns: 1fr 320px 200px; grid-template-rows: auto 1fr; gap: var(--layout-spacing); flex: 1; min-height: 0; margin-bottom: 1rem; }
.poll-content > .panel { min-height: 0; display: flex; flex-direction: column; overflow: hidden; }
.results-panel { grid-row: span 2; }
.time-panel { grid-row: span 2; }
.notes-panel { grid-column: 2; padding: var(--layout-spacing-sm); }
/* Day-wise poll layout (no time panel) */
.poll-content.day-wise { grid-template-columns: 1fr 400px; grid-template-rows: auto 1fr; }
.poll-content.day-wise .results-panel { grid-row: 1 / -1; grid-column: 1; }
.poll-content.day-wise .calendar-panel { grid-row: 1; grid-column: 2; }
.poll-content.day-wise .notes-panel { grid-row: 2; grid-column: 2; }
/* Tablet breakpoint */
@media (max-width: 1000px) {
body { min-height: 1000px; }
body.poll-view .container { min-height: 948px; }
.poll-page { min-height: 916px; }
.poll-content {
display: flex;
flex-direction: column;
flex-wrap: wrap;
height: 700px;
overflow-y: auto;
}
.poll-content > .panel { max-height: none; width: calc(50% - 0.75rem); }
.results-panel { height: calc(80% - 0.75rem); min-height: 0; order: 0; }
.notes-panel { height: calc(20% - 0.75rem); display: flex; order: 1; }
.calendar-panel { height: auto; min-height: 478px; order: 2; }
.time-panel { height: auto; flex: 1; max-height: calc(100% - 478px - 1.5rem); order: 3; }
/* Day-wise tablet layout */
.poll-content.day-wise { display: flex; flex-wrap: nowrap; flex-direction: column; height: auto; }
.poll-content.day-wise > .panel { width: 100%; }
.poll-content.day-wise .results-panel { height: auto; min-height: 300px; max-height: 500px; order: 0; flex: 0 0 auto; }
.poll-content.day-wise .calendar-panel { min-height: auto; order: 1; flex: 0 0 auto; }
.poll-content.day-wise .notes-panel { height: auto; min-height: 100px; order: 2; flex: 1 1 auto; }
}
/* Small tablet breakpoint */
@media (max-width: 750px) {
.poll-content { height: auto; flex-wrap: nowrap; }
.poll-content > .panel { width: 100%; height: auto; max-height: none; }
.results-panel { min-height: 300px; max-height: 400px; }
.calendar-panel { min-height: 478px; }
.time-panel { min-height: 200px; max-height: 300px; }
.notes-panel { display: none; }
}
.panel { background: var(--color-surface); padding: var(--layout-spacing); border-radius: var(--layout-border-radius); box-shadow: var(--shadow-sm); }
.panel h2 { margin-bottom: var(--layout-spacing-sm); font-size: 1.1rem; flex-shrink: 0; }
.panel-header + * { margin-top: 0; }
.calendar-nav { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.calendar-nav button { background: none; border: 1px solid var(--color-border); padding: 0.25rem 0.5rem; cursor: pointer; border-radius: var(--layout-border-radius-sm); color: var(--color-text-muted); }
.calendar-nav button:hover { background: var(--color-primary-light); }
.calendar { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.calendar .day-header { text-align: center; font-size: var(--font-size-xs); font-weight: 600; color: var(--color-text-muted); padding: 0.25rem; }
.calendar .day { text-align: center; padding: 0.5rem; cursor: pointer; border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-sm); user-select: none; }
.calendar .day:hover { background: var(--color-primary-light); }
.calendar .day.has-avail { background: var(--color-primary-light); }
.calendar .day.heat-1 { background: var(--heat-1); }
.calendar .day.heat-2 { background: var(--heat-2); }
.calendar .day.heat-3 { background: var(--heat-3); }
.calendar .day.heat-4 { background: var(--heat-4); }
.calendar .day.best-slot { font-weight: 700; }
.calendar .day.today { text-decoration: underline; }
.calendar .day.selected { box-shadow: inset 0 0 0 2px var(--color-primary); }
.calendar .day.selected.has-avail { background: var(--color-primary-light); }
.calendar .day.other-month { color: #ccc; }
.calendar .day.other-month.not-allowed { opacity: 0.25; }
.hint { font-size: var(--font-size-xs); color: var(--color-text-light); margin-top: 0.5rem; display: flex; justify-content: space-between; align-items: center; }
.hint-centered { justify-content: center; }
.hint-centered .hint-help { display: none; }
.hint-help { width: 14px; height: 14px; border-radius: 50%; color: var(--color-text-muted); display: inline-flex; align-items: center; justify-content: center; font-size: 11px; cursor: help; position: relative; padding-top: 1px; }
.hint-help path {
fill: #8888;
}
.hint-help:hover::after { content: attr(title); position: fixed; background: var(--color-surface); color: var(--color-text); border: 1px solid var(--color-border); padding: 0.5rem; border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-xs); white-space: pre; z-index: 1000; transform: translateY(-100%) translateY(-8px); box-shadow: var(--shadow-md); }
.calendar .day.preview { background: var(--color-primary-light); outline: 2px dashed var(--color-primary); }
.calendar .day.preview-remove { background: var(--color-error-bg); outline: 2px dashed var(--color-error); }
.reset-btn { background: none; border: none; font-size: 1.1rem; cursor: pointer; color: var(--color-text-muted); vertical-align: middle; margin-left: 0.5rem; }
.reset-btn:hover { color: var(--color-error); }
.calendar-actions { margin-top: var(--layout-spacing-sm); display: flex; flex-direction: column; gap: 0.5rem; }
.calendar-actions .guest-info { display: flex; gap: 0.5rem; }
.calendar-actions .guest-info input { padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); flex: 1; background: var(--color-input-bg); color: var(--color-text); }
.time-grid { display: flex; flex-direction: column; gap: 2px; flex: 1; overflow-y: auto; min-height: 200px; padding-right: 6px; }
.time-slot { padding: 0.35rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); cursor: pointer; text-align: center; font-size: var(--font-size-xs); user-select: none; position: relative; }
.time-slot:hover:not(.disabled) { background: var(--color-primary-light); }
.time-slot.has-avail { background: var(--color-primary-light); }
.time-slot.heat-1 { background: var(--heat-1); }
.time-slot.heat-2 { background: var(--heat-2); }
.time-slot.heat-3 { background: var(--heat-3); }
.time-slot.heat-4 { background: var(--heat-4); }
.time-slot.best-slot { font-weight: 700; }
.time-arrow { position: absolute; left: 0px; top: 50%; transform: translateY(-50%); width: 0; height: 0; border-top: 7px solid transparent; border-bottom: 7px solid transparent; border-left: 10px solid var(--color-primary); }
.time-slot.selected { box-shadow: inset 0 0 0 2px var(--color-primary); }
.time-slot.selected.has-avail { background: var(--color-primary-light); }
.time-slot.preview { background: var(--color-primary-light); outline: 2px dashed var(--color-primary); }
.time-slot.preview-remove { background: var(--color-error-bg); outline: 2px dashed var(--color-error); }
.time-slot.disabled, .calendar .day.disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }
.calendar .day.not-allowed { color: #bbb; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.results-panel { padding: var(--layout-spacing-sm); }
.results-panel #results-table { flex: 1; display: block; overflow-y: auto; width: 100%; padding-right: 6px; }
.results-panel thead { position: sticky; top: 0; background: var(--color-surface); z-index: 1; }
.calendar-panel .calendar { flex-shrink: 0; }
.calendar-panel .calendar-actions { flex-shrink: 0; }
#results-table { width: 100%; border-collapse: collapse; }
#results-table th, #results-table td { padding: 0.5rem; text-align: left; border-bottom: 1px solid var(--color-border-light); font-size: var(--font-size-sm); }
#results-table th:first-child, #results-table td:first-child { white-space: nowrap; width: 1%; }
#results-table th:nth-child(2), #results-table td:nth-child(2) { white-space: nowrap; width: 1%; padding-left: 1rem; padding-right: 1rem; text-align: center; }
#results-table th { font-weight: 600; background: var(--color-background); }
#results-table tr:hover { background: var(--color-background); }
#results-table tr.best-slot td:first-child { font-weight: 700; }
.attendee-list { display: flex; gap: 4px; overflow-x: auto; white-space: nowrap; padding-bottom: 2px; }
.attendee { display: inline-flex; align-items: center; gap: 4px; background: var(--color-primary-light); padding: 2px 8px; border-radius: 12px; font-size: var(--font-size-xs); cursor: pointer; flex-shrink: 0; }
.attendee:hover { background: var(--color-primary); color: white; }
.attendee.filtered { background: var(--color-primary); color: white; }
.attendee img { width: 20px; height: 20px; border-radius: 50%; }
.conflict { color: var(--color-error); }
.count { font-weight: 600; color: var(--color-success); }
.attendees-mode-toggle { cursor: pointer; padding: 0.25rem 0.5rem; border-radius: var(--layout-border-radius-sm); transition: all 0.2s; opacity: 0.5; }
.attendees-mode-toggle:hover { opacity: 0.8; }
.attendees-mode-toggle.active { opacity: 1; font-weight: 600; background: var(--color-primary-light); }
.attendees-mode-separator { opacity: 0.3; margin: 0 0.25rem; }
#results-table th[data-sort] { cursor: pointer; user-select: none; }
#results-table th[data-sort]:hover { opacity: 0.7; }
.sortable-header { display: inline-flex; align-items: center; gap: 0.25rem; }
.sortable-header .sort-arrow { font-size: 0.75em; min-width: 0.75em; color: var(--color-primary); }
.submit-section { margin-top: var(--layout-spacing); background: var(--color-surface); padding: var(--layout-spacing); border-radius: var(--layout-border-radius); box-shadow: var(--shadow-sm); display: flex; gap: 1rem; align-items: center; flex-wrap: wrap; }
.guest-info { display: flex; gap: 0.5rem; flex: 1; }
.guest-info input { padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); flex: 1; background: var(--color-input-bg); color: var(--color-text); }
#submit-btn { padding: 0.75rem 2rem; min-width: 180px; }
#submit-btn.success { background: var(--color-success); }
#submit-btn .btn-text { display: inline; }
#submit-btn .btn-check { display: none; }
#submit-btn.success .btn-text { display: none; }
#submit-btn.success .btn-check { display: inline; }
.panel-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: var(--layout-spacing-sm); }
.panel-header h2 { margin-bottom: 0; }
.view-switch { display: flex; align-items: center; gap: 0.5rem; cursor: pointer; user-select: none; }
.view-switch input { display: none; }
.switch-slider { width: 36px; height: 20px; background: var(--color-border); border-radius: 10px; position: relative; transition: background 0.2s; }
.switch-slider::after { content: ''; position: absolute; width: 16px; height: 16px; background: white; border-radius: 50%; top: 2px; left: 2px; transition: transform 0.2s; }
.view-switch input:checked + .switch-slider { background: var(--color-primary); }
.view-switch input:checked + .switch-slider::after { transform: translateX(16px); }
.switch-label { font-size: var(--font-size-sm); color: var(--color-text-muted); }
.calendar .day.has-availability { position: relative; }
.calendar .day.has-availability::after { content: ''; position: absolute; bottom: 2px; left: 50%; transform: translateX(-50%); width: 4px; height: 4px; background: var(--color-success); border-radius: 50%; }
.calendar .day.highlight-flash { animation: flash-day 0.6s ease-out; }
.calendar .day.selected.highlight-flash { animation: flash-day-selected 0.6s ease-out; }
.time-slot.highlight-flash { animation: flash-time 0.6s ease-out; }
.time-slot.selected.highlight-flash { animation: flash-time-selected 0.6s ease-out; }
@keyframes flash-day { 0%, 100% { box-shadow: none; } 50% { box-shadow: inset 0 0 0 3px var(--color-primary); } }
@keyframes flash-day-selected { 0%, 100% { box-shadow: inset 0 0 0 2px var(--color-primary); } 50% { box-shadow: inset 0 0 0 2px var(--color-primary), 0 0 0 4px var(--color-primary-light); } }
@keyframes flash-time { 0%, 100% { box-shadow: none; } 50% { box-shadow: inset 0 0 0 3px var(--color-primary); } }
@keyframes flash-time-selected { 0%, 100% { box-shadow: inset 0 0 0 2px var(--color-primary); } 50% { box-shadow: inset 0 0 0 2px var(--color-primary), 0 0 0 4px var(--color-primary-light); } }
#results-table tbody tr { cursor: pointer; }
#results-table tbody tr:hover { background: var(--color-primary-light); }
#results-table tbody tr.slot-greyed { opacity: 0.4; }
#results-table tbody tr.slot-chosen { background: var(--color-primary-light); }
#results-table tbody tr.slot-chosen:hover { background: var(--color-primary-light); }
.note-input { width: 100%; padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-sm); margin-bottom: 0.5rem; background: var(--color-input-bg); color: var(--color-text); }
.note-input::placeholder { color: var(--color-text-light); }
.notes-panel h2 { margin-bottom: 0.5rem; }
.notes-pane-content { flex: 1; overflow-y: auto; font-size: var(--font-size-sm); word-break: break-word; overflow-wrap: break-word; }
.notes-pane-empty { color: var(--color-text-light); font-style: italic; }
.notes-pane-content .note-item { padding: 0.5rem; margin-bottom: 0.5rem; background: var(--color-background); border-radius: var(--layout-border-radius-sm); border-left: 3px solid var(--color-primary); }
.notes-pane-content .note-item:last-child { margin-bottom: 0; }
.notes-pane-content .note-author { font-weight: 700; color: var(--color-text); }
.note-indicator { margin-left: 0.25rem; }
.checkbox-option { display: flex; align-items: center; gap: 0.5rem; margin-bottom: 1rem; cursor: pointer; user-select: none; }
.checkbox-option input[type="checkbox"] { width: 18px; height: 18px; min-width: 18px; margin: 0; cursor: pointer; }
.checkbox-option span { line-height: 1.2; }
.btn-small { padding: 0.3rem 0.75rem; font-size: var(--font-size-sm); }
.poll-title-row { display: flex; align-items: center; gap: 1rem; margin-bottom: 0.5rem; flex-wrap: wrap; }
.poll-title-row h1 { margin: 0; flex-shrink: 0; }
.poll-title-row .share-link { flex: 1; max-width: 400px; display: flex; gap: 0.5rem; }
.poll-title-row .share-link input { flex: 1; padding: 0.35rem 0.5rem; font-size: var(--font-size-sm); border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); background: var(--color-background); color: var(--color-text-muted); }
.participants-section .join-section { margin: 0; margin-left: auto; }
.admin-section { display: flex; gap: 0.5rem; margin-left: auto; }
.btn-danger { background: var(--color-error); color: white; }
.btn-danger:hover { background: #b91c1c; }
.locked-notice { margin-left: auto; padding: 0.35rem 0.75rem; background: var(--color-primary-light); color: var(--color-text-muted); border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-sm); }
.modal-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; z-index: 1000; }
.modal { background: var(--color-surface); padding: var(--layout-spacing); border-radius: var(--layout-border-radius); box-shadow: var(--shadow-md); max-width: 400px; width: 90%; position: relative; }
.modal-close { position: absolute; top: 0.5rem; right: 0.75rem; background: none; border: none; font-size: 1.5rem; cursor: pointer; color: var(--color-text-muted); line-height: 1; padding: 0.25rem; }
.modal-close:hover { color: var(--color-text); }
.modal h3 { margin: 0 0 0.5rem; }
.modal-subtitle { color: var(--color-text-muted); font-size: var(--font-size-sm); margin-bottom: 1rem; }
.modal-subtitle a { color: var(--color-primary); }
.modal-large { max-width: 500px; }
.modal-large .calendar { margin-bottom: 0.5rem; }
.modal .form-label { font-size: var(--font-size-sm); color: var(--color-text-muted); margin-bottom: 0.5rem; display: block; }
.modal .checkbox-option { display: flex; align-items: center; gap: 0.5rem; font-size: var(--font-size-sm); cursor: pointer; margin-top: 0.5rem; }
.modal textarea { width: 100%; padding: 0.5rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); font-family: inherit; resize: vertical; min-height: 60px; background: var(--color-input-bg); color: var(--color-text); margin-bottom: 0.75rem; }
.modal .calendar-nav { margin-bottom: 0.5rem; }
.modal .calendar-nav button { background: var(--color-surface); color: var(--color-text); }
.modal-form { margin-bottom: 1rem; }
.modal-form input[type="text"] { width: 100%; padding: 0.75rem; border: 1px solid var(--color-border); border-radius: var(--layout-border-radius-sm); font-size: var(--font-size-base); background: var(--color-input-bg); color: var(--color-text); margin-bottom: 0.75rem; }
.modal-actions { display: flex; gap: 0.5rem; align-items: center; }
.modal-error { flex: 1; color: var(--color-error); font-size: var(--font-size-sm); }
.modal-actions .btn { min-width: 80px; text-align: center; }
/* ========== MOBILE STYLES ========== */
@media (max-width: 768px) {
/* Navbar */
.navbar { padding: 0.6rem 0; }
.navbar-inner { padding: 0 1rem; }
.brand-group { padding-left: 0; gap: 0.5rem; }
.brand { font-size: 1rem; }
.theme-toggle { padding: 0.2rem; }
.theme-toggle svg { width: 16px; height: 16px; }
.nav-right { gap: 0.75rem; padding-right: 0; font-size: var(--font-size-sm); }
.user-info { padding: 0.2rem 0.5rem; font-size: var(--font-size-xs); }
/* Container */
.container { padding: 0 1rem; }
body.poll-view .container { padding: 0.75rem 1rem; height: auto; min-height: calc(100vh - 44px); overflow: visible; }
body:not(.poll-view) .container { padding: 1rem; }
body.poll-view { height: auto; overflow: auto; }
/* Hero */
.hero { padding: 2rem 1rem 1.5rem; }
.hero h1 { font-size: 1.75rem; }
.hero p { font-size: 1rem; margin-bottom: 1.5rem; }
/* Polls grid */
.polls-grid { grid-template-columns: 1fr; }
.poll-card { padding: 1rem; }
/* Dashboard */
.dashboard { padding: 0; }
.dashboard h1 { font-size: 1.5rem; margin-bottom: 1rem; }
.create-poll { padding: var(--layout-spacing-sm); }
/* Poll page layout */
.poll-page { height: auto; min-height: calc(100vh - 44px); }
.poll-header { padding: var(--layout-spacing-sm); margin-bottom: 0.75rem; }
.poll-header h1 { font-size: 1.25rem; }
.poll-desc { font-size: var(--font-size-sm); margin-bottom: 0.75rem; }
/* Participants section */
.participants-section { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
.participants-section .join-section { margin-left: 0; width: 100%; }
.participants-section .join-section #join-btn { width: 100%; }
.admin-section { margin-left: 0; width: 100%; }
.admin-section .btn { flex: 1; }
.locked-notice { margin-left: 0; width: 100%; text-align: center; }
.participants-list { max-width: 100%; }
/* Poll content grid - reorder for mobile workflow */
.poll-content {
display: flex;
flex-direction: column;
gap: 0.75rem;
overflow: visible;
margin-bottom: 0.75rem;
}
.poll-content > .panel { max-height: none; order: 0; }
.calendar-panel { order: 1; }
.time-panel { order: 2; }
.results-panel { order: 3; }
.notes-panel { order: 4; }
/* Panels */
.panel { padding: var(--layout-spacing-sm); }
.panel h2 { font-size: 1rem; margin-bottom: 0.5rem; }
.panel-header { margin-bottom: 0.5rem; }
.panel-header h2 { font-size: 1rem; }
/* Calendar - larger touch targets */
.calendar { gap: 3px; }
.calendar .day { padding: 0.6rem 0.25rem; font-size: var(--font-size-sm); min-height: 38px; }
.calendar .day-header { font-size: 0.7rem; padding: 0.25rem 0; }
.calendar-nav { margin-bottom: 0.75rem; }
.calendar-nav button { padding: 0.4rem 0.75rem; }
/* Time grid - better for touch */
.time-panel { max-height: 350px; }
.time-grid { max-height: 280px; min-height: 150px; padding-right: 4px; }
.time-slot { padding: 0.5rem 0.35rem; font-size: var(--font-size-sm); min-height: 36px; }
/* Results panel */
.results-panel { max-height: 400px; }
.results-panel #results-table { max-height: 340px; }
#results-table th, #results-table td { padding: 0.4rem; font-size: var(--font-size-xs); }
#results-table th:nth-child(2), #results-table td:nth-child(2) { padding-left: 0.5rem; padding-right: 0.5rem; }
.attendee { padding: 2px 6px; font-size: 0.65rem; }
.attendee img { width: 16px; height: 16px; }
/* Notes panel */
.notes-panel { max-height: 200px; }
.notes-pane-content { font-size: var(--font-size-xs); }
/* Hints */
.hint { font-size: 0.65rem; margin-top: 0.4rem; }
.hint-help { display: none; }
/* Calendar actions */
.calendar-actions { margin-top: 0.75rem; gap: 0.5rem; }
.note-input { padding: 0.6rem; font-size: var(--font-size-sm); }
/* Buttons */
#submit-btn { width: 100%; padding: 0.85rem 1rem; font-size: var(--font-size-base); min-width: auto; }
.btn { padding: 0.6rem 1rem; }
.btn-small { padding: 0.4rem 0.75rem; }
.reset-btn { font-size: 1rem; margin-left: 0.25rem; }
/* View switch */
.view-switch { gap: 0.35rem; }
.switch-slider { width: 32px; height: 18px; }
.switch-slider::after { width: 14px; height: 14px; }
.view-switch input:checked + .switch-slider::after { transform: translateX(14px); }
.switch-label { font-size: var(--font-size-xs); }
/* Modal */
.modal { padding: var(--layout-spacing-sm); width: 95%; }
.modal h3 { font-size: 1.1rem; }
.modal-subtitle { font-size: var(--font-size-xs); }
.modal-form input { padding: 0.65rem; }
.modal-actions { flex-wrap: wrap; }
.modal-error { width: 100%; margin-bottom: 0.5rem; }
.modal-actions .btn { flex: 1; min-width: auto; padding: 0.75rem; }
/* Share link in title row */
.poll-title-row { flex-direction: column; align-items: flex-start; gap: 0.5rem; }
.poll-title-row .share-link { max-width: 100%; width: 100%; }
.poll-title-row .share-link input { font-size: var(--font-size-xs); }
}
|