body {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    font-family: 'serif';
}
.auth {
    position: relative;
    width: 100%;
    height: 100vh;
    background-image: linear-gradient(#477ff0, #99c2bc);
}
.auth_background {
    text-align: center;
    padding-top: 10%;
}
.auth_background button {
    line-height: 0;
    color: #000000;
    font-size: medium;
    padding: 3px 12px;
    background-color: #22222211;
    border: 0.3vh outset #95b1df3b;
    min-width: 7.5rem;
    height: 1.5rem;
}
.auth_background input {
    background-color: #202f332b;
    border: 0.3vh inset #4c84b3a6;
}
/* input:-internal-autofill-selected {
    background-color: #202f332b !important;
    color: #df1a1a !important;
} */
.errorlist {
    color: #ff0000;
    font-size: 1.2rem;
    font-weight: bold;
    list-style: none;
}
.messages {
    font-size: 1.2rem;
    font-weight: bold;
    list-style: none;
    padding: 1.5rem 0;
}
/* エラーのメッセージ (ログインの失敗が続いたときのロックの理由: main/login_lockout.py)
   はフォームのエラーと同じ赤 */
.messages .alert.error {
    color: #ff0000;
}
/* 警告のメッセージ (views.py の messages.warning: 登録前のデータがもう消えていた・カードの登録の
   前にログインかアカウントの登録が要る) は、ほかのページの警告 (user_errors.js の WarningTip) と
   同じ黄色の ! の印を先頭に付ける。文は黒のまま (警告の文には色を付けない。青い地で黄色の文字は
   読みにくい。2026-10-26)。読み上げでは ! ではなく Warning: と読む */
.messages .alert.warning::before {
    content: "!";
    content: "!" / "Warning: ";
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 1.1em;
    height: 1.1em;
    margin-right: 0.3em;
    border-radius: 50%;
    background-color: #f0b429;
    color: #1f2937;
    font-family: system-ui, -apple-system, 'Segoe UI', sans-serif;
    font-size: 0.85em;
    font-weight: 800;
    line-height: 1;
    vertical-align: 0.1em;
}
/* 仮ユーザーの登録の確認画面 (guest_activation.html): 引き継ぐデータセットの一覧 */
.guest_datasets {
    list-style: none;
    margin: 1rem auto;
    padding: 0 1rem;
    max-width: 32rem;
    text-align: left;
}
.guest_dataset {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.4rem 0;
}
.guest_dataset_thumb {
    flex: none;
    width: 4rem;
    height: 3rem;
    object-fit: cover;
    background-color: #202f332b;
}
/* /conversion のファイル (サムネイルが無い) は拡張子を出す */
.guest_dataset_badge {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    font-weight: bold;
}
.guest_dataset_text {
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.guest_dataset_name {
    overflow-wrap: anywhere;
}
.guest_dataset_meta {
    font-size: 0.85rem;
}
/* 登録画面の規約への同意のチェックボックス (メールでの登録と Google での登録のボタンの上) */
.auth_agreement {
    margin: 1rem auto;
    padding: 0 1rem;
    max-width: 32rem;
    font-size: 0.85rem;
    line-height: 1.5;
}
.auth_agreement input[type="checkbox"] {
    vertical-align: -0.1em;
}
.auth_agreement .errorlist {
    margin: 0.4rem 0 0;
    padding: 0;
}
/* チェックを入れるまで押せない (signup_agreement.js) */
.auth_background button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}
.auth_or {
    margin: 0.6rem 0;
}
.auth_background .auth_google_button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    height: auto;
    padding: 4px 12px;
}
.auth_google_button .google-icon {
    top: 0;
}
/* Sign up with Google をチェック無しで押したときの規約の確認 (signup_agreement.js)。
   地・縁・文字はほかのページのライトのダイアログ (new_preuploader.css の dialog.np_dialog。地は
   --np-bright-dialog-bg) と同じ */
.auth_agreement_dialog {
    box-sizing: border-box;
    width: 90%;
    max-width: 28rem;
    padding: 1.2rem 1.6rem 1.4rem;
    color: #000000;
    background: linear-gradient(#538cff, #81caff);
    background-origin: border-box;
    border: 3px solid transparent;
    border-radius: 10px;
}
.auth_agreement_dialog::backdrop {
    background: rgba(0, 0, 0, 0.55);
}
.auth_agreement_dialog a {
    color: #08205c;
}
.auth_agreement_dialog .auth_agreement {
    margin: 0;
    padding: 0;
}
.auth_dialog_title {
    margin: 0 0 1rem;
    font-size: 1.15rem;
}
.auth_dialog_buttons {
    display: flex;
    justify-content: center;
    gap: 0.8rem;
    margin-top: 1.2rem;
}
.guest_note {
    margin: 1rem auto;
    padding: 0 1rem;
    max-width: 32rem;
    font-size: 0.9rem;
}

/* --------------------------------------------------------------------------
 * インライン style 属性からの移行用ユーティリティクラス。
 * CSP style-src から 'unsafe-inline' を除去する対応。ファイル末尾に置くことで
 * .auth_background 等の既存クラス（padding-top:10%）を後勝ちで上書きする。
 * -------------------------------------------------------------------------- */
.pt-12 { padding-top: 12%; }
.pt-15 { padding-top: 15%; }
.pt-1rem { padding-top: 1rem; }
.ml-1_5rem { margin-left: 1.5rem; }
.mt-3_5rem { margin-top: 3.5rem; }
.google-icon { margin-right: 5px; position: relative; top: 3px; }