/* Shared screen presentation for the operator panel, sign-in and public registration. */
@media screen {
    :root {
        --entry-title: clamp(1.4rem, 1.15rem + 1vw, 1.85rem);
        --entry-heading: 1.125rem;
        --entry-gutter: clamp(16px, 2.5vw, 40px);
        --entry-inset: clamp(16px, 2vw, 24px);
        --entry-card-radius: 14px;
        --entry-control-radius: 8px;
    }
    body { font-family: Inter, "Segoe UI", Arial, sans-serif; line-height: 1.5; }
    .panel-shell > main.wrap, .panel-shell > main.wrap:has(.gate-workspace, .gate-history-page) {
        width: 100%; padding: clamp(22px, 2.4vw, 38px) var(--entry-gutter) 60px;
    }
    main h1, .gate-title h1, .auth-card h1, .market h1 {
        font-size: var(--entry-title); line-height: 1.2; letter-spacing: -.035em; overflow-wrap: anywhere;
    }
    main h2, .market .question h2 { font-size: var(--entry-heading); line-height: 1.35; }
    .titleline { flex-wrap: wrap; gap: 12px 20px; align-items: center; margin-bottom: 22px; }
    .gate-workspace .titleline, .gate-history-page .titleline { margin: 0; }
    .panel, .auth-card, .market .form-card, .market .result { border-radius: var(--entry-card-radius); }
    .panel + .panel { margin-top: 18px; }
    .invites-page > .panel, .gate-workspace > .panel { margin: 0; }
    .panelhead { padding: 16px var(--entry-inset); gap: 12px 18px; }
    .panel:not(.editor,.stack) > h2 { padding: 16px var(--entry-inset); }
    .panel:not(.editor,.stack) > p:not([class]) { padding: 12px var(--entry-inset); }
    .editor, .panel.stack:not(.editor) { padding: var(--entry-inset); }
    .stack { gap: 16px; }
    .stack label, .gh-filters label { font-size: .9rem; }
    :where(.stack, .search, .gh-form, .gate-search) :where(input,select,textarea), .market .answer {
        font-family: inherit; border-radius: var(--entry-control-radius);
    }
    .stack textarea { max-width: 100%; }
    .formactions { flex-wrap: wrap; gap: 8px; }
    .btn, .market .primary-action, .market .back-action { border-radius: var(--entry-control-radius); }
    .btn.primary, .market .primary-action { min-height: 44px; background-color: var(--blue); color: white; font-weight: 650; }
    .btn.primary:hover, .market .primary-action:hover { background-color: #064967; }
    .stack input:not([type]):focus-visible, .stack select:focus-visible, .stack textarea:focus-visible,
    .market .answer:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
    .tablewrap { max-width: 100%; }
    .tablewrap th { font-weight: 650; text-align: start; }
    .stack label.registration-switch { position: relative; display: flex; align-items: center; gap: 10px; min-height: 44px; cursor: pointer; }
    .registration-switch input[type=checkbox] { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
    .switch-track { flex: none; display: inline-flex; align-items: center; width: 44px; height: 26px; padding: 2px; border: 1px solid #718491; border-radius: 20px; background: #718491; }
    .switch-track::before { content: ""; width: 20px; height: 20px; border-radius: 50%; background: white; }
    .registration-switch :checked + .switch-track { background: var(--blue); border-color: var(--blue); }
    .registration-switch :checked + .switch-track::before { margin-left: auto; }
    .registration-switch :focus-visible + .switch-track { outline: 3px solid var(--blue); outline-offset: 3px; }
}
@media screen and (max-width: 650px) {
    .titleline { flex-direction: column; align-items: flex-start; }
    .panelhead { align-items: flex-start; }
    .panelhead > .search, .panelhead > .client-tools, .panelhead > form { max-width: 100%; }
    .editor .formactions > .btn { max-width: 100%; }
    .panel .tablewrap { overscroll-behavior-x: contain; }
}
