:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "Yu Gothic UI", Meiryo, sans-serif;
  --ink:#111827; --muted:#6b7280; --line:#e5e7eb; --bg:#f6f7f9; --card:#fff; --navy:#0f1d2c;
}
* { box-sizing:border-box; }
[hidden] { display:none!important; }
body { margin:0; min-height:100vh; background:var(--bg); color:var(--ink); }
button,input { font:inherit; }
a { color:inherit; }
.admin-guard { position:fixed; inset:0; z-index:100; display:grid; place-items:center; align-content:center; gap:12px; background:#fff; color:var(--muted); transition:opacity .2s ease; }
.admin-guard p { margin:0; font-size:12px; }
.spinner { width:28px; height:28px; border:3px solid #e5e7eb; border-top-color:#334155; border-radius:50%; animation:spin .8s linear infinite; }
@keyframes spin { to { transform:rotate(360deg); } }
.admin-header { min-height:64px; padding:0 max(20px,calc((100vw - 1180px)/2)); display:flex; align-items:center; justify-content:space-between; gap:20px; border-bottom:1px solid var(--line); background:#fff; }
.admin-header > div { display:flex; align-items:center; gap:14px; }
.brand { text-decoration:none; font-size:13px; font-weight:900; letter-spacing:.09em; }
.section-name { padding-left:14px; border-left:1px solid var(--line); color:#707783; font-size:11px; }
.admin-actions { color:#737b86; font-size:10px; }
.admin-actions a { text-decoration:none; font-weight:700; color:#3c4755; }
.admin-main { width:min(100% - 32px,1180px); margin:0 auto; padding:28px 0 60px; }
.toolbar { display:flex; justify-content:space-between; align-items:end; gap:20px; margin-bottom:18px; }
.toolbar > div:first-child { display:grid; gap:7px; }
.eyebrow { color:#89919b; font:700 9px/1 ui-monospace,SFMono-Regular,Menlo,monospace; letter-spacing:.13em; }
.toolbar strong { font-size:24px; letter-spacing:-.03em; }
.toolbar-actions { display:flex; gap:8px; }
.search input { width:min(340px,42vw); height:40px; border:1px solid #d8dce1; border-radius:9px; outline:none; padding:0 12px; background:#fff; font-size:12px; }
.search input:focus { border-color:#8294aa; box-shadow:0 0 0 3px rgba(80,105,135,.09); }
.toolbar button { min-width:70px; height:40px; border:1px solid #d8dce1; border-radius:9px; background:#fff; color:#334155; cursor:pointer; font-size:11px; font-weight:700; }
.toolbar button:hover { background:#f8fafc; }
.error-box { margin-bottom:14px; padding:12px 14px; border:1px solid #efc7c7; border-radius:9px; background:#fff4f4; color:#a14343; font-size:12px; }
.empty-state { padding:60px 20px; border:1px dashed #d5d9df; border-radius:14px; text-align:center; color:#8a929d; font-size:12px; background:#fff; }
.submission-list { display:grid; gap:10px; }
.submission-card { border:1px solid var(--line); border-radius:13px; background:var(--card); overflow:hidden; box-shadow:0 5px 18px rgba(15,23,42,.035); }
.submission-card summary { list-style:none; cursor:pointer; padding:15px 16px; display:grid; grid-template-columns:minmax(220px,1.5fr) 120px 160px 24px; gap:14px; align-items:center; }
.submission-card summary::-webkit-details-marker { display:none; }
.submission-card summary:hover { background:#fafbfc; }
.summary-main { min-width:0; }
.summary-main strong { display:block; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; font-size:13px; }
.summary-main small { display:block; margin-top:4px; color:#8a929c; font-size:9px; }
.type-badge,.mirror-badge { justify-self:start; padding:5px 8px; border-radius:999px; background:#eef2f6; color:#536273; font-size:9px; font-weight:700; white-space:nowrap; }
.mirror-badge.ok { background:#e6f5ec; color:#397253; }
.summary-date { color:#727b86; font-size:10px; }
.chevron { color:#9aa1aa; font-size:14px; transition:transform .15s ease; }
details[open] .chevron { transform:rotate(90deg); }
.detail { padding:0 16px 17px; border-top:1px solid #eef0f2; }
.detail-grid { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); border-left:1px solid #eceef0; border-top:1px solid #eceef0; margin-top:15px; }
.detail-cell { min-height:66px; padding:11px; border-right:1px solid #eceef0; border-bottom:1px solid #eceef0; }
.detail-cell span { display:block; margin-bottom:5px; color:#969da6; font-size:9px; }
.detail-cell strong { display:block; color:#374151; font-size:11px; line-height:1.5; overflow-wrap:anywhere; }
.notes { margin-top:12px; padding:12px; border:1px solid #eceef0; border-radius:9px; background:#fafafa; }
.notes span { color:#969da6; font-size:9px; }
.notes p { margin:6px 0 0; color:#4b5563; font-size:11px; line-height:1.65; white-space:pre-wrap; overflow-wrap:anywhere; }
.detail-actions { margin-top:12px; display:flex; justify-content:flex-end; }
.copy-info { min-height:36px; padding:0 12px; border:1px solid #d8dce1; border-radius:8px; background:#fff; color:#344152; cursor:pointer; font-size:10px; font-weight:700; }
.copy-toast { position:fixed; z-index:1000; left:50%; top:50%; transform:translate(-50%,-50%); min-width:190px; padding:14px 18px; display:flex; justify-content:center; gap:9px; border-radius:12px; background:rgba(15,29,44,.95); color:#fff; box-shadow:0 18px 50px rgba(0,0,0,.25); font-size:12px; font-weight:700; }
.copy-toast span { color:#7bdaa4; }
.sr-only { position:absolute; width:1px; height:1px; overflow:hidden; clip:rect(0 0 0 0); white-space:nowrap; }
@media(max-width:760px){
  .admin-header { padding:0 16px; }
  #admin-email { display:none; }
  .admin-main { width:calc(100% - 24px); padding-top:20px; }
  .toolbar { align-items:stretch; flex-direction:column; }
  .toolbar-actions { width:100%; }
  .search { flex:1; }
  .search input { width:100%; }
  .submission-card summary { grid-template-columns:1fr auto 18px; gap:9px; }
  .summary-date { grid-column:1/2; grid-row:2; }
  .mirror-badge { grid-column:2; grid-row:2; }
  .type-badge { grid-column:2; grid-row:1; }
  .chevron { grid-column:3; grid-row:1/3; }
  .detail-grid { grid-template-columns:1fr 1fr; }
}
@media(max-width:430px){ .detail-grid { grid-template-columns:1fr; } }
