:root { color-scheme: light; font-family: system-ui, sans-serif; color: #21202b; }
[hidden] { display: none !important; }
.shell { margin: 0; height: 100dvh; display: grid; grid-template-rows: auto minmax(0, 1fr) auto; background: #f8f6ef; }
.shell header { background: #232142; color: white; padding: .7rem max(1rem, env(safe-area-inset-left)); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .25rem 1rem; }
.shell h1 { font-size: 1.1rem; margin: 0; }
.shell output { font-size: .85rem; font-variant-numeric: tabular-nums; }
.shell main { min-height: 0; position: relative; overflow: auto; }
.shell iframe { border: 0; display: block; width: 100%; height: 100%; background: white; }
.shell section { max-width: 24rem; margin: 2rem auto; padding: 0 1rem; }
.shell form, .shell label { display: grid; gap: .5rem; }
.shell form { gap: 1rem; }
.shell input, .shell button, .shell summary { font: inherit; min-height: 44px; box-sizing: border-box; }
.shell input { width: 100%; padding: .5rem; }
.shell button, .shell summary { cursor: pointer; padding: .5rem; }
.shell nav { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .25rem; padding: .35rem .35rem max(.35rem, env(safe-area-inset-bottom)); border-top: 1px solid #d6d0c2; background: #f8f6ef; }
.shell nav button, .shell nav a, .shell summary { border: 0; border-radius: .4rem; background: #eeece4; color: #232142; }
.shell nav a { display: grid; place-items: center; min-height: 44px; }
.shell nav button:focus-visible, .shell summary:focus-visible { outline: 2px solid #49428c; outline-offset: -2px; }
.shell details { position: relative; }
.shell summary { display: grid; place-items: center; list-style: none; }
.shell summary::-webkit-details-marker { display: none; }
.shell details div { position: absolute; z-index: 1; bottom: calc(100% + .6rem); right: 0; display: grid; gap: .25rem; width: 12rem; max-height: 65dvh; overflow: auto; padding: .5rem; background: white; box-shadow: 0 4px 24px #0003; }
body:not(.shell) { margin: 0; padding: .8rem; overflow-wrap: anywhere; }
body:not(.shell) table { max-width: 100%; }
body:not(.shell) img { max-width: 100%; }
body:not(.shell) input, body:not(.shell) select, body:not(.shell) button { font-size: 16px; min-height: 44px; max-width: 100%; }
#relay-feedback { position: sticky; top: 0; z-index: 2; margin: 0; background: #f8f6ef; color: #232142; }
