:root { --ink:#192632; --muted:#506172; --paper:#fff7ee; --white:#fff; --edge:#ccd6df; --blue:#075da8; --blue-fill:#0871cb; --pale:#ebf5ff; --danger:#9a2631; }
* { box-sizing:border-box; }
[hidden] { display:none !important; }
body { margin:0; color:#000; background:var(--paper); font:16px -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif; }
.account-dialog, .account-card, #cookie-notice { line-height:1.45; }
a { color:var(--blue); }
button, select { font:inherit; }
button { cursor:pointer; }
button:disabled { cursor:default; opacity:.65; }
:focus-visible { outline:3px solid var(--blue); outline-offset:3px; }
#header { position:relative; z-index:12; display:flex; align-items:center; justify-content:space-between; min-height:102px; padding:8px; background:var(--white); box-shadow:0 .25em .75em #ccc; }
#logo { margin:0 .5em; font-size:1em; line-height:1; }
#logo img { display:block; width:210px; height:auto; }
#logo a { position:relative; display:block; }
@media (prefers-reduced-motion:no-preference) {
  #logo:has(.logo-spin) img { clip-path:inset(0 0 0 29.7%); }
  .logo-spin { position:absolute; inset:0 auto 0 0; width:29.7%; background:url('/static/omoraa-logo.png') left center / 336.7% 100% no-repeat; transform-origin:62% 50%; animation:omoraa-spin 5s infinite; }
  @keyframes omoraa-spin { 0%, 82% { transform:rotate(0); } 100% { transform:rotate(360deg); } }
}
.header-tools { align-self:flex-start; display:flex; align-items:center; gap:8px; }
#presence-count { font-size:.8rem; color:#43586b; white-space:nowrap; margin-right:4px; padding-top:3px; }
#presence-count .presence-dot { color:#168c52; }
#presence-count .presence-changed { display:inline-block; animation:presence-pulse .45s ease-out; }
@keyframes presence-pulse { 50% { transform:translateY(-3px); color:#0871cb; } }
@media (prefers-reduced-motion:reduce) { #presence-count .presence-changed { animation:none; } }
@media (max-width:560px) { .header-tools { flex-wrap:wrap; justify-content:flex-end; } #presence-count { flex-basis:100%; text-align:right; } }
#translate-start { display:inline-flex; align-items:center; gap:5px; padding:2px 5px; color:#111; border:1px solid #ccc; background:white; font:14px Arial,sans-serif; }
#translate-start span:last-child { color:#777; border-left:1px solid #ccc; padding-left:5px; }
#translate-status { display:block; font-size:.75rem; max-width:195px; }
iframe.omoraa-language-menu { left:auto !important; right:8px; width:min(750px,calc(100% - 24px)) !important; height:min(50vh,420px) !important; }
.header-tools select { color:#111; padding:2px 6px; background:var(--white); border:1px solid #ccc; font-size:.85em; }
#account-menu { position:relative; }
#account-menu summary { display:grid; place-items:center; width:40px; height:40px; border:1px solid var(--edge); border-radius:50%; overflow:hidden; background:var(--pale); color:var(--blue); font-weight:700; cursor:pointer; list-style:none; }
#account-menu summary::-webkit-details-marker { display:none; }
#avatar { width:100%; height:100%; object-fit:cover; }
.account-card { position:absolute; z-index:12; right:0; top:calc(100% + 8px); width:min(240px,calc(100vw - 32px)); padding:12px; background:var(--white); border:1px solid var(--edge); border-radius:8px; box-shadow:0 6px 24px #19263220; }
.account-card > * { display:block; width:100%; padding:6px; text-align:left; }
.account-card button { border:0; background:transparent; color:var(--blue); }
.danger, .account-card .danger { color:var(--danger); }
.legal-page { width:min(840px,calc(100% - 32px)); margin:clamp(24px,6vh,64px) auto 0; padding:clamp(18px,4vw,38px); background:var(--white); border:1px solid var(--edge); border-radius:12px; box-shadow:0 5px 16px #19263209; overflow-wrap:anywhere; }
.legal-page h1 { margin:0 0 8px; font-size:clamp(24px,4vw,34px); line-height:1.16; }
#intro {
  width:min(738px, calc(100% - 16px)); margin:1em auto .5em; padding:.5em .5em 1em;
  line-height:1.5; background:var(--white); border:1px solid #ccc; border-radius:.5em; box-shadow:inset 0 0 .5em #bbb;
}
#mobilesitenote { margin:10px 0; height:3.5em; line-height:3.5em; text-align:center; font-size:.9em; font-weight:700; color:#555; }
.omoraa-intro-illustration { text-align:center; }
.omoraa-intro-illustration img { max-width:100%; height:auto; }
#introtext p { margin:1em 0; }
#topterms { margin:0; padding-bottom:.75em; text-align:center; font-size:.6666em; line-height:1; font-weight:700; color:#555; }
#monitoringnotice { max-width:36em; margin:.5em auto 1em; border:1px solid #ccc; border-radius:.5em; box-shadow:0 0 .75em #bfdeff; background:#bfdeff; text-align:center; }
#monitoringnotice h2 { margin:0; padding:.3134em .2em; font-size:1.595em; line-height:1; }
#monitoringnotice h2 img { vertical-align:top; }
#monitoringnotice .content { font-size:.9em; padding-bottom:.555em; }
#monitoringnotice .content a { margin-left:.55em; }
.omoraa-home-actions { display:grid; grid-template-columns:minmax(0,400px) minmax(0,280px); gap:28px; justify-content:center; }
.omoraa-home-actions h2 { text-align:center; margin:0 0 .2em; font-size:1.25em; font-weight:400; }
#topic-input {
  display:block; appearance:none; width:100%; min-width:0; height:49px; padding:0 .5em;
  border:1px solid #ccc; border-radius:.16em; background:linear-gradient(#fff,#f8f8f8);
  color:#303030; text-align:center; font:clamp(14px,2.1vw,21px) "Lucida Grande",Lucida,sans-serif;
}
#topic-list { display:flex; flex-wrap:wrap; gap:6px; margin:8px 0 0; padding:0; list-style:none; }
#topic-list:empty { display:none; }
#topic-list li, #topic-list button { max-width:100%; overflow-wrap:anywhere; }
#topic-status { overflow-wrap:anywhere; }
#topic-list button { background:var(--pale); border:1px solid var(--edge); color:var(--blue); font-size:.86rem; border-radius:16px; padding:4px 10px; }
.mode-buttons { display:flex; align-items:center; justify-content:center; gap:.45em; }
.mode-separator { font-size:.9em; font-weight:700; color:#555; }
.omoraa-chat-button {
  display:block; width:124px; height:50px; padding:0; border:0; border-radius:5px;
  background:linear-gradient(#78baff,#0680eb); color:#fff; font:400 22px -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
}
.omoraa-chat-button:hover { background:linear-gradient(#58a9ff,#006acb); }
.omoraa-chat-button:active { background:linear-gradient(#006acb,#58a9ff); }
.home-primary { background:var(--blue-fill); color:var(--white); border:1px solid var(--blue); border-radius:6px; padding:9px 14px; min-height:44px; font-weight:650; }
.home-primary:hover:not(:disabled) { background:var(--blue); }
.home-primary:disabled { opacity:1; color:#526373; background:#edf0f3; border-color:var(--edge); }
#footer { margin:.5em .5em 0; padding-bottom:108px; color:#555; font-size:.75rem; }
#footer nav { display:flex; flex-wrap:wrap; gap:8px 16px; }
#cookie-notice + #footer { width:min(738px,calc(100% - 24px)); margin:5px auto 0; padding-bottom:3px; }
#cookie-notice {
  display:grid; grid-template-columns:34px minmax(0,1fr) auto; align-items:center; gap:10px 12px;
  width:min(738px,calc(100% - 24px)); margin:8px auto 0; padding:10px 14px;
  border:1px solid #c8dbed; border-radius:12px; background:linear-gradient(110deg,#eef7ff,#fff 62%);
  box-shadow:0 3px 10px #27446412; color:#24394d; font-size:.84rem;
}
#intro[hidden] ~ #cookie-notice { display:none; }
.remember-mark { display:grid; place-items:center; width:34px; height:34px; border-radius:10px; background:#d7ebff; }
.remember-mark::after {
  content:''; width:12px; height:16px; border-radius:2px;
  background:#1170b9; clip-path:polygon(0 0,100% 0,100% 100%,50% 75%,0 100%);
}
#cookie-notice p { margin:0; }
#cookie-notice strong { display:block; font-size:15px; line-height:20px; }
#cookie-notice small { font-size:12px; color:#475f75; }
#cookie-notice small a { margin-left:4px; }
#cookie-notice div { display:flex; flex-wrap:wrap; gap:8px; }
#cookie-notice button {
  min-height:38px; min-width:78px; padding:6px 12px; border:1px solid #a9bfd4;
  background:white; color:#21567f; border-radius:8px; font-weight:600;
}
#cookie-notice button:hover { background:#e4f2ff; }
@media (prefers-reduced-motion:no-preference) {
  #cookie-notice { animation:remember-in 220ms ease-out both; }
  #cookie-notice button { transition:background-color 150ms,transform 150ms; }
  #cookie-notice button:active { transform:scale(.97); }
  @keyframes remember-in { from { opacity:0; transform:translateY(6px); } to { opacity:1; transform:none; } }
}
.dialog-actions button:not(.home-primary) { min-height:40px; padding:6px 12px; border:1px solid var(--edge); border-radius:5px; background:var(--white); }
.account-dialog { width:min(400px,calc(100% - 32px)); max-height:calc(100dvh - 34px); padding:clamp(14px,4vw,20px); color:var(--ink); border:1px solid var(--edge); border-radius:12px; }
.account-dialog::backdrop { background:#19263255; }
.account-dialog h2 { font-size:1.32rem; margin:0 0 8px; line-height:1.22; }
.account-dialog p { margin:0 0 14px; }
#access-declarations label { display:flex; align-items:center; gap:12px; min-height:44px; margin-bottom:4px; cursor:pointer; }
#access-declarations input { flex:none; width:17px; height:17px; margin:0 2px 0 3px; }
.access-privacy { color:var(--muted); font-size:.86rem; }
.dialog-actions { display:flex; justify-content:flex-end; align-items:stretch; flex-wrap:wrap; gap:8px; }
#access-guest { flex:1 0 100%; }
#access-guest-note { flex:1 0 100%; margin-top:-3px; color:var(--muted); text-align:center; font-size:.86rem; }
#access-guest[hidden], #access-guest-note[hidden] { display:none; }
#account-status, #access-status { padding:8px 10px; background:var(--pale); border-radius:5px; overflow-wrap:anywhere; }
.legal-page { line-height:1.65; }
.legal-page h2 { font-size:1.15rem; margin:20px 0 4px; }
.legal-page p, .legal-page ul { margin:4px 0 12px; }
#topic-expand { margin-top:5px; }
@media (max-width:700px) {
  #header { min-height:0; flex-wrap:wrap; gap:4px 10px; }
  #logo { margin:0; }
  #logo img { width:min(45vw,210px); }
  #mobilesitenote { height:auto; line-height:1.4; padding:1em 0; margin:.5em 0; }
}
@media (max-width:560px) {
  .omoraa-home-actions { grid-template-columns:minmax(0,1fr); gap:.75em; }
  #monitoringnotice h2 { font-size:1.2em; }
  #monitoringnotice h2 img { width:20px; height:20px; }
  #topic-input { font-size:1rem; }
  .mode-buttons { flex-wrap:wrap; }
  #footer { padding-bottom:.5em; }
}
@media (max-width:620px) {
  #cookie-notice { grid-template-columns:32px minmax(0,1fr); }
  #cookie-notice div { grid-column:1/-1; }
  #cookie-notice button { flex:1; min-height:44px; }
}

#report-status-reference { display:block; box-sizing:border-box; width:100%; margin:8px 0; padding:8px; font:inherit; }
#report-status-help { font-size:.85em; color:#53677c; }
#report-status-result:not([hidden]) { background:#eef6ff; padding:10px; border-radius:4px; overflow-wrap:anywhere; }
