[hidden] { display:none !important; }
.header-actions { display:flex; align-items:center; justify-content:flex-end; gap:12px; margin-left:auto; min-width:0; flex-wrap:wrap; }
.account-bar { display:flex; gap:8px; flex-wrap:wrap; align-items:center; justify-content:flex-end; font-size:14px; }
.auth-dialog button, .account-bar button, .account-bar a, .history-controls button, .history-controls select, .history-controls input, .load-more { min-height:44px; border:1px solid #dfdfd8; border-radius:12px; padding:10px 14px; font:inherit; background:#fff; color:#242b39; cursor:pointer; }
.account-bar a { display:inline-flex; align-items:center; text-decoration:none; }
.account-bar button:hover, .account-bar a:hover, .load-more:hover { border-color:#3059d9; color:#3059d9; }
button:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible { outline:3px solid #3059d9; outline-offset:3px; }
button:disabled { opacity:.55; cursor:not-allowed; }
.account-identity { display:flex; gap:8px; align-items:center; min-width:0; }
.account-email { max-width:190px; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; }
.account-role { color:#3059d9; background:#e7edff; border-radius:8px; padding:5px 9px; white-space:nowrap; }
.account-note { flex-basis:100%; margin:16px 0 0; color:#626873; font-size:12px; line-height:1.7; }
.account-message { flex-basis:100%; margin:0; color:#885020; }
.history-shell { max-width:1160px; width:calc(100% - 48px); margin:auto; }
.history-page { margin:0; background:#faf9f5; color:#242b39; font:16px/1.6 'Avenir Next','Segoe UI','PingFang SC',sans-serif; }
.history-header { display:flex; flex-wrap:wrap; gap:12px; padding:16px 0; justify-content:space-between; align-items:center; min-height:90px; border-bottom:1px solid #dfdfd8; }
.history-header a { color:#3059d9; text-decoration:none; min-height:44px; display:flex; align-items:center; }
.history-header select { min-height:44px; padding:8px; border:1px solid #dfdfd8; border-radius:10px; background:white; font:inherit; }
.history-page h1 { font-size:clamp(28px,4vw,42px); line-height:1.2; margin:36px 0 12px; }
.history-page h2 { font-size:20px; margin:0 0 12px; }
.history-muted { color:#626873; }
.history-panel { background:white; border:1px solid #dfdfd8; padding:24px; border-radius:20px; margin:24px 0; }
.history-controls { display:flex; flex-wrap:wrap; align-items:center; gap:12px; margin:20px 0; }
.history-controls label { display:flex; align-items:center; gap:8px; }
.history-stats { display:grid; grid-template-columns:repeat(3,1fr); gap:16px; margin:24px 0; }
.history-stat { background:#e7edff; padding:20px; border-radius:16px; }
.history-stat strong { display:block; font-size:32px; }
.history-chart { width:100%; height:260px; min-height:180px; }
.table-scroll { overflow:auto; max-height:650px; }
table { border-collapse:collapse; width:100%; font-size:13px; }
caption { text-align:left; color:#626873; padding-bottom:12px; }
th, td { text-align:left; padding:12px; border-bottom:1px solid #dfdfd8; vertical-align:top; }
th { background:#faf9f5; white-space:nowrap; }
td { min-width:90px; }
td.signature { min-width:200px; max-width:250px; overflow-wrap:anywhere; font-family:monospace; }
td.browser { min-width:230px; max-width:300px; overflow-wrap:anywhere; }
.load-more { margin-top:16px; }
.history-status { padding:20px 0; }
@media(max-width:600px) { .history-shell { width:calc(100% - 32px); } .history-panel { padding:16px; } .history-stats { grid-template-columns:1fr; gap:10px; } .history-stat { padding:12px 16px; } .history-stat strong { font-size:26px; } }

.history-status:empty { display:none; }

.account-note a { display:inline; min-height:0; padding:0; border:0; background:none; border-radius:0; color:#3059d9; text-decoration:underline; }

footer { flex-wrap:wrap; }
.account-bar .auth-signin { background:transparent; border-color:transparent; }
.account-bar .auth-signup { background:#3059d9; border-color:#3059d9; color:#fff; }
.account-bar .auth-signup:hover { background:#2547b6; color:#fff; }
.auth-dialog { box-sizing:border-box; width:min(420px, calc(100% - 32px)); max-height:calc(100dvh - 48px); padding:36px 28px 24px; border:1px solid #dfdfd8; border-radius:24px; background:#fff; color:#242b39; box-shadow:0 24px 80px #242b3933; font:16px/1.6 'Avenir Next','Segoe UI','PingFang SC',sans-serif; }
.auth-dialog::backdrop { background:#18203366; backdrop-filter:blur(4px); }
.auth-dialog h2 { margin:0 40px 8px 0; font-size:28px; line-height:1.3; letter-spacing:-.5px; }
.auth-intro { margin:0 0 24px; color:#626873; font-size:14px; }
.auth-dialog .auth-close { position:absolute; top:12px; right:12px; width:44px; height:44px; padding:0; border:0; background:transparent; font-size:28px; }
.auth-dialog .auth-close:hover { background:#f4f5f8; }
.auth-dialog .auth-provider { display:flex; align-items:center; gap:14px; width:100%; min-height:54px; margin:12px 0; padding:12px 16px; font-size:14px; font-weight:600; text-align:left; transition:background .18s,border-color .18s; }
.auth-dialog .auth-provider:hover { background:#f4f6ff; border-color:#3059d9; }
.auth-privacy { display:inline-flex; align-items:center; min-height:44px; margin-top:8px; color:#626873; font-size:12px; text-decoration:underline; }
.auth-dialog .account-message { margin:16px 0 0; font-size:14px; }
@media(max-width:600px) { .header-actions { gap:8px; } .account-bar { gap:4px; } .account-bar button, .account-bar a { padding:10px 12px; } .account-identity { flex-basis:100%; justify-content:flex-end; } .account-email { max-width:170px; } }
@media(prefers-reduced-motion:reduce) { .auth-dialog * { transition:none !important; } }
