/* Klikka – Startseite für Bildschirme (ohne Login). Hell/Dunkel über die Variablen aus app.css. */

html, body { overflow: auto; }
body.start-page { background: var(--bg); color: var(--text); }
body.playing { background: #000; overflow: hidden; }
.screen-start[hidden] { display: none; }

.screen-start {
    min-height: 100vh; min-height: 100dvh;
    display: flex; flex-direction: column; align-items: center;
    gap: clamp(.9rem, 2.5vh, 1.6rem); padding: clamp(1rem, 3vh, 2rem) 1.25rem .5rem; text-align: center;
}
.screen-brand { margin-top: auto; }
.screen-brand img { height: clamp(40px, 7vh, 72px); width: auto; }

.screen-card {
    background: var(--surface); border-radius: 20px; box-shadow: var(--shadow);
    padding: clamp(1.1rem, 3vh, 2.25rem); display: grid; gap: 1rem; justify-items: center; align-items: center;
    width: min(92vw, 560px);
}
.screen-card[hidden] { display: none; }

/* QR-Code immer dunkel auf weiß – auch im Dunkelmodus gut scannbar */
.qr { background: #fff; border-radius: 14px; padding: .6rem; width: min(70vw, 46vh, 340px); aspect-ratio: 1; }
.qr svg { width: 100%; height: 100%; display: block; }

.waiting-info { display: grid; gap: 1rem; justify-items: center; }
.code-box { display: grid; gap: .15rem; }
.code-label { font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-weight: 700;
    font-size: clamp(2rem, 6vw, 3.4rem); letter-spacing: .14em; color: var(--text); white-space: nowrap;
}
.code-timer { min-height: 1.2em; }
.screen-lead { margin: 0; font-size: 1.05rem; max-width: 30rem; }

/* Querformat (Beamer, Laptop): QR links, Code rechts – passt auch auf 1280×720 und 1024×768 */
@media (orientation: landscape) and (min-width: 700px) {
    #waiting { grid-template-columns: auto minmax(16rem, 1fr); width: min(92vw, 900px); text-align: left; gap: clamp(1.2rem, 4vw, 3rem); }
    #waiting .waiting-info { justify-items: start; }
    #waiting .qr { width: min(52vh, 360px); }
}

.connected-mark {
    width: 4.5rem; height: 4.5rem; border-radius: 50%; display: grid; place-items: center;
    background: var(--accent); color: var(--on-accent); font-size: 2.2rem; font-weight: 700;
}
.connected h1 { margin: 0; font-size: 1.6rem; }

.screen-actions { display: flex; flex-wrap: wrap; gap: .6rem .8rem; align-items: center; justify-content: center; }
.screen-actions .button[hidden] { display: none; }
.screen-actions kbd { background: var(--code); border: 1px solid var(--line); color: var(--text); }

.screen-footer {
    margin-top: auto; display: flex; justify-content: center; align-items: center;
    gap: 1.2rem; padding: .6rem; font-size: .95rem;
}
.screen-footer a { color: var(--accent-ink); text-decoration: none; font-weight: 600; }
.screen-footer a:hover { text-decoration: underline; }
