/* Copied verbatim from apps-script-live/ReportingPortal.html (RP:1). Additions are at the end. */
*{box-sizing:border-box}
body{margin:0;background:#f1f5fa;color:#20334c;font:14px Arial,sans-serif}
header{background:#14243b;color:white;padding:22px 5%;display:flex;justify-content:space-between;align-items:center;gap:20px}
header h1{font-size:23px;margin:0}
header p{margin:6px 0 0;color:#b7c6da}
.shell{max-width:1320px;margin:24px auto;padding:0 22px}
.filters,.card{background:white;border:1px solid #dce5f0;border-radius:12px;padding:18px}
.filters{display:flex;align-items:end;gap:16px;flex-wrap:wrap}
.filters>div{flex:1;min-width:170px}
label{font-size:12px;font-weight:bold;display:block;margin-bottom:7px}
select{width:100%;border:1px solid #ccd8e7;border-radius:7px;background:white;padding:11px;color:#20334c;font:14px Arial}
button{background:#2465c1;color:white;border:0;border-radius:7px;padding:11px 16px;font-weight:bold;cursor:pointer}
button:disabled{opacity:.5;cursor:default}
button.soft{background:#e7eef8;color:#28558a}
a{color:#2271c9}
.cards{display:grid;grid-template-columns:repeat(6,1fr);gap:13px;margin:20px 0}
.stat small{font-size:11px;color:#6b7d93;font-weight:bold;display:block;letter-spacing:.5px}
.stat b{font-size:28px;display:block;margin-top:12px;color:#1f508a}
.stat.accent b{color:#0b937e}
.charts{display:grid;grid-template-columns:1.4fr 1fr;gap:18px;margin:18px 0}
.card h2{font-size:16px;margin:0 0 18px}
.chart svg{width:100%;height:215px}
.legend{font-size:12px;color:#64768c;display:flex;gap:18px}
.legend span:before{content:'●';margin-right:5px;color:var(--color)}
.bar-row{display:grid;grid-template-columns:110px 1fr 60px;gap:12px;align-items:center;margin:17px 0}
.track{height:20px;background:#edf2f8;border-radius:4px;overflow:hidden}
.fill{height:100%;background:#2474cc;min-width:0}
.table-wrap{overflow:auto}
table{border-collapse:collapse;width:100%;font-size:13px}
th,td{padding:12px 10px;border-bottom:1px solid #e8eef5;text-align:left;white-space:nowrap}
th{color:#6a7e96;font-size:11px;text-transform:uppercase}
td.num,th.num{text-align:right}
.muted{color:#6a7d93;font-size:12px}
.actions{display:flex;gap:10px;flex-wrap:wrap;margin:18px 0}
.section{margin:20px 0}
.notice{padding:12px 0;color:#65778d;line-height:1.5}
#error{color:#a62d2d;white-space:pre-wrap}
#report table{font-size:12px}
#report td:first-child{position:sticky;left:0;background:white;font-weight:bold}
.request{padding:15px;border-bottom:1px solid #e4ebf4}
.request p{white-space:pre-wrap;line-height:1.4}
.request textarea{width:100%;border:1px solid #cbd8e7;border-radius:6px;padding:10px;font:14px Arial}
.hidden{display:none}
@media(max-width:1000px){.cards{grid-template-columns:repeat(3,1fr)}
}
@media(max-width:650px){.cards{grid-template-columns:repeat(2,1fr)}
.charts{grid-template-columns:1fr}
header{display:block}
header p{font-size:12px}
.shell{padding:0 12px}
.bar-row{grid-template-columns:90px 1fr 45px}
}

/* --- Additions for the backend-served page (not in the original) --- */
/* "Sign in with Google" link shown on HTTP 401; styled like the original primary button. */
a.signin{display:inline-block;margin-top:10px;background:#2465c1;color:white;border-radius:7px;padding:11px 16px;font-weight:bold;text-decoration:none;white-space:normal}
a.signin:focus{outline:2px solid #14243b;outline-offset:2px}
