/*
 * Strony wejścia na platformę (host app.<domena>), makieta wariant A z docs/zmiany: logowanie, reset hasła,
 * nowe hasło, „sprawdź skrzynkę” i brak dostępu. Dwie kolumny po 50%: po lewej logo, formularz i adres pomocy,
 * po prawej żółty panel z listą społeczności platformy. Poniżej 1040 px panel schodzi pod formularz.
 * Kolory to tokeny --p-entry-* (theme-tokens.css): strony wejścia nie należą do żadnej społeczności.
 */
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
    font-family: Inter, system-ui, -apple-system, sans-serif;
    color: var(--p-entry-ink);
    background: var(--p-entry-bg);
    -webkit-font-smoothing: antialiased;
}
.visually-hidden {
    position: absolute !important;
    width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
    clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.ico { display: block; flex-shrink: 0; width: 18px; height: 18px; }

.scene {
    --pad-x: clamp(24px, 6vw, 96px);
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: auto 1fr auto;
    min-height: 100vh;
    min-height: 100dvh;
}

/* ---------- Lewa kolumna ---------- */
.scene-logo { grid-column: 1; grid-row: 1; justify-self: start; display: inline-flex; margin: 48px var(--pad-x) 0; }
.scene-logo img { display: block; width: auto; height: 48px; }
.scene-logo:focus-visible { outline: 2px solid var(--p-entry-ink); outline-offset: 4px; border-radius: 4px; }

.scene-col {
    grid-column: 1;
    grid-row: 2;
    align-self: center;
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
    max-width: calc(520px + 2 * var(--pad-x));
    padding: 48px var(--pad-x);
}
.scene-form { display: flex; flex-direction: column; gap: 20px; margin: 0; }
.scene-head { display: flex; flex-direction: column; gap: 12px; margin-bottom: 12px; }

.scene-title { margin: 0; font-size: 36px; font-weight: 800; line-height: 1.1; letter-spacing: -.02em; text-wrap: balance; }
.scene-lead { margin: 0; font-size: 17px; line-height: 1.55; color: var(--p-entry-ink-2); }
.scene-lead strong { color: var(--p-entry-ink); font-weight: 600; }
.scene-sub { margin: 0; font-size: 20px; font-weight: 600; line-height: 1.4; }

.scene-field { display: flex; flex-direction: column; gap: 8px; }
.scene-field label { font-size: 14px; font-weight: 600; }
.scene-label-row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.scene-field input {
    height: 52px;
    padding: 0 16px;
    border: 1.5px solid var(--p-entry-field-border);
    border-radius: 10px;
    background: var(--p-entry-bg);
    color: var(--p-entry-ink);
    font: inherit;
    font-size: 16px;
}
.scene-field input::placeholder { color: var(--p-entry-placeholder); }
.scene-field input:focus { outline: none; border-color: var(--p-entry-ink); box-shadow: 0 0 0 3px var(--p-entry-focus-ring); }
.scene-field input[aria-invalid="true"] { border-color: var(--p-error-field-border); }

.scene-error, .scene-note { padding: 12px 16px; border-radius: 10px; font-size: 14px; font-weight: 500; line-height: 1.45; }
.scene-error { background: var(--p-error-bg); color: var(--p-error-ink); }
.scene-error[hidden] { display: none; }
.scene-note { background: var(--p-entry-note-bg); color: var(--p-entry-ink); }

.scene-remember { display: flex; align-items: center; gap: 10px; min-height: 44px; font-size: 15px; cursor: pointer; }
.scene-remember input { width: 20px; height: 20px; margin: 0; accent-color: var(--p-entry-ink); }

.scene-link, .scene-help a { color: var(--p-entry-ink); font-size: 14px; font-weight: 500; text-underline-offset: 3px; }
.scene-link:hover, .scene-help a:hover { color: var(--p-entry-ink-strong); }
.scene-link:focus-visible, .scene-help a:focus-visible { outline: 2px solid var(--p-entry-ink); outline-offset: 3px; border-radius: 2px; }

.scene-btn, .scene-btn2 {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    height: 56px;
    border-radius: 10px;
    font: inherit;
    font-size: 15px;
    cursor: pointer;
    text-decoration: none;
    transition: background-color .15s ease-out, transform .1s ease-out;
}
.scene-btn {
    border: 0;
    background: var(--p-entry-accent);
    color: var(--p-entry-ink);
    font-weight: 800;
    letter-spacing: .06em;
    text-transform: uppercase;
}
.scene-btn .ico { stroke-width: 2.5; }
.scene-btn:hover { background: var(--p-entry-accent-hover); color: var(--p-entry-ink); }
.scene-btn2 { border: 1.5px solid var(--p-entry-field-border); background: var(--p-entry-bg); color: var(--p-entry-ink); font-weight: 600; }
.scene-btn2:hover { background: var(--p-entry-soft); }
.scene-btn:active, .scene-btn2:active { transform: scale(.98); }
.scene-btn:focus-visible, .scene-btn2:focus-visible { outline: 3px solid var(--p-entry-focus-ring); outline-offset: 2px; }
.scene-btn[aria-disabled="true"] { opacity: .5; }
.scene-btn.is-first { margin-top: 12px; }

.scene-back {
    display: inline-flex;
    align-self: flex-start;
    align-items: center;
    gap: 8px;
    color: var(--p-entry-ink-2);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}
.scene-back .ico { width: 16px; height: 16px; }
.scene-back:hover { color: var(--p-entry-ink); }
.scene-tile {
    display: grid;
    place-items: center;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: var(--p-entry-accent);
}
.scene-tile .ico { width: 26px; height: 26px; }

/* Warunki nowego hasła (js/platform-entry.js zapala je na żywo). */
.scene-checks { display: flex; flex-direction: column; gap: 10px; margin: 0; padding: 0; list-style: none; font-size: 14px; }
.scene-check { display: flex; align-items: center; gap: 10px; color: var(--p-entry-ink-3); transition: color .2s; }
.scene-check-dot {
    display: grid;
    place-items: center;
    width: 20px;
    height: 20px;
    border: 1.5px solid var(--p-entry-field-border);
    border-radius: 50%;
    color: transparent;
}
.scene-check-dot .ico { width: 12px; height: 12px; }
.scene-check.is-ok { color: var(--p-entry-ink); }
.scene-check.is-ok .scene-check-dot { background: var(--p-entry-accent); border-color: var(--p-entry-accent); color: var(--p-entry-ink); }

.scene-help { grid-column: 1; grid-row: 3; margin: 0; padding: 0 var(--pad-x) 48px; font-size: 13px; color: var(--p-entry-ink-3); }
.scene-help a { font-size: inherit; }

/* ---------- Prawa kolumna: społeczności platformy ---------- */
.scene-side {
    grid-column: 2;
    grid-row: 1 / 4;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 48px var(--pad-x);
    background: var(--p-entry-accent);
}
.scene-side-inner { display: flex; flex-direction: column; gap: 24px; width: 100%; max-width: 520px; }
.scene-side-title { margin: 0; font-size: 32px; font-weight: 800; line-height: 1.15; letter-spacing: -.02em; }
.scene-side-list { display: flex; flex-direction: column; gap: 12px; margin: 0; padding: 0; list-style: none; }
.scene-side-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 22px;
    border-radius: 14px;
    background: var(--p-entry-card);
    font-size: 18px;
    font-weight: 700;
}
.scene-side-check {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--p-entry-accent);
    color: var(--p-entry-ink);
}
.scene-side-check .ico { width: 16px; height: 16px; }

/* ---------- Węższe ekrany: panel pod formularzem (makieta: flex-wrap przy 2 × 520 px) ---------- */
@media (max-width: 1039px) {
    .scene { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto auto auto; }
    .scene-col { align-self: start; }
    .scene-side { grid-column: 1; grid-row: 4; }
}
@media (max-width: 600px) {
    .scene-logo { margin-top: 32px; }
    .scene-logo img { height: 40px; }
    .scene-col { padding-top: 40px; padding-bottom: 32px; }
    .scene-title { font-size: 30px; }
    .scene-side-title { font-size: 26px; }
    .scene-side-item { padding: 14px 16px; font-size: 16px; }
}

@media (prefers-reduced-motion: reduce) {
    .scene-btn, .scene-btn2, .scene-check { transition: none; }
}
