*{box-sizing:border-box}
body{
    margin:0;
    font-family:Arial,sans-serif;
    background:#0b1220;
    color:#fff;
}
.app{
    max-width:1200px;
    margin:0 auto;
    padding:20px;
}
.topbar{
    display:flex;
    justify-content:space-between;
    align-items:flex-start;
    gap:16px;
    margin-bottom:18px;
    flex-wrap:wrap;
}
.topbar h1{
    margin:0 0 6px;
    font-size:34px;
}
.subtitle{
    margin:0;
    color:#94a3b8;
}
.status-pill{
    background:#1e293b;
    padding:10px 14px;
    border-radius:999px;
    color:#cbd5e1;
}
.stats-grid{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:14px;
    margin-bottom:18px;
}
.stat-card{
    background:#111827;
    border:1px solid #1f2937;
    border-radius:18px;
    padding:18px;
}
.stat-label{
    display:block;
    color:#94a3b8;
    font-size:13px;
    margin-bottom:8px;
}
.stat-value{
    font-size:34px;
    font-weight:800;
}
.stat-value.small{
    font-size:20px;
    line-height:1.2;
}
.main-grid{
    display:grid;
    grid-template-columns:1.15fr .85fr;
    gap:18px;
}
.panel{
    background:#111827;
    border:1px solid #1f2937;
    border-radius:18px;
    padding:18px;
}
#reader{
    width:100%;
    min-height:360px;
    overflow:hidden;
    border-radius:14px;
    background:#000;
}
.camera-hint{
    margin-top:12px;
    color:#94a3b8;
}
.result{
    border-radius:18px;
    padding:22px;
    min-height:170px;
}
.result #resultTitle{
    font-size:34px;
    font-weight:900;
    margin-bottom:10px;
    text-align:center;
}
.result #resultDetail{
    white-space:pre-line;
    font-size:17px;
    line-height:1.5;
    text-align:center;
}
.neutral{
    background:#334155;
}
.ok{
    background:#166534;
}
.bad{
    background:#b91c1c;
}
.info-box{
    margin-top:16px;
    background:#0f172a;
    border-radius:14px;
    padding:14px;
}
.info-row{
    padding:8px 0;
    border-bottom:1px solid #1e293b;
}
.info-row:last-child{
    border-bottom:none;
}
.actions{
    display:flex;
    gap:10px;
    flex-wrap:wrap;
    margin-top:16px;
}
.btn{
    display:inline-block;
    text-decoration:none;
    border:none;
    cursor:pointer;
    border-radius:12px;
    padding:12px 16px;
    font-weight:700;
    background:#2563eb;
    color:#fff;
}
.btn.secondary{background:#475569}
.btn.dark{background:#020617}
.raw-response{
    margin-top:16px;
    background:#020617;
    color:#93c5fd;
    border-radius:14px;
    padding:14px;
    min-height:90px;
    overflow:auto;
    white-space:pre-wrap;
    font-size:12px;
}
@media (max-width:960px){
    .stats-grid{grid-template-columns:repeat(2,1fr)}
    .main-grid{grid-template-columns:1fr}
}
@media (max-width:560px){
    .stats-grid{grid-template-columns:1fr}
    .topbar h1{font-size:28px}
    .stat-value{font-size:30px}
}
