[hidden] { display:none !important; }
.entry-buttons {display:flex;gap:10px;flex-wrap:wrap;margin-top:20px;}
.entry-buttons button {border:1px solid #8ba6b4;border-bottom:4px solid #6c8ba0;border-radius:12px;background:#3c72d8;color:white;padding:12px 18px;font-weight:750;}
.entry-buttons button:last-child {background:#e4ecee;color:#203348;}
.help {margin-top:18px;font-size:13px;line-height:1.8;color:#4b6677;}
.help summary {cursor:pointer;}
#communicator {padding-top:16px;font-size:13px;line-height:1.6;}
#communicator label {display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:12px 0;}
#communicator label>span {width:100%;}
#communicator label.check {flex-wrap:nowrap;align-items:flex-start;}
#communicator label.check>span {width:auto;}
#communicator input,#communicator select,#communicator textarea {font:inherit;max-width:100%;}
#communicator select,#communicator textarea {width:100%;padding:9px;color:#eef6fa;background:#142b40;border:1px solid #7793aa;border-radius:7px;}
#communicator textarea {resize:vertical;}
#communicator input[type=range] {flex:1;width:100%;accent-color:#72d6e4;min-height:30px;}
#communicator input[type=checkbox] {flex:0 0 20px;width:20px;height:20px;accent-color:#3c72d8;}
#communicator button {border:1px solid #9abacc;border-radius:9px;background:#d9e8ee;color:#182b3f;padding:10px;min-height:44px;font-weight:700;font-size:12px;}
#communicator button:disabled {opacity:.45;cursor:not-allowed;}
.comm-nav,.comm-actions,.calibration-controls {display:flex;flex-wrap:wrap;gap:7px;}
.comm-nav button {flex:1;}
#communicator .comm-nav button[aria-pressed=true] {background:#3974cf;color:#fff;}
.comm-note {color:#bdd0dc;font-size:12px;}
#communicator .comm-warning {border-left:3px solid #f1b489;padding-left:10px;color:#f1d5b9;}
#communicator h2 {font-size:13px;font-weight:700;margin:16px 0 8px;}
#communicator output,#morse-preview {display:block;overflow-wrap:anywhere;white-space:pre-wrap;}
#morse-preview {max-height:90px;overflow:auto;margin-top:8px;color:#8ee1e6;letter-spacing:1px;}
#receive-result,#receive-candidate,#text-preview {padding:9px;background:#0a1c2d;border:1px solid #52738e;border-radius:7px;min-height:40px;}
#communicator .stop {background:#ef8e83;border-color:#ffb6a9;color:#241b26;flex:1;}
#start-send,#start-receive {flex:2;}
#light-patch {width:96px;height:96px;background:#07111b;border:1px solid #7393a7;border-radius:8px;margin:14px auto;}
#light-fullscreen {position:fixed;inset:0;z-index:10000;background:#07111b;}
#light-fullscreen .light-controls {position:absolute;left:0;right:0;bottom:0;background:#07111b;color:#fff;text-align:center;padding:16px 16px max(16px,env(safe-area-inset-bottom));}
#light-stop {min-height:56px;min-width:160px;padding:12px 28px;border:2px solid #ffb6a9;border-radius:12px;background:#ef8e83;color:#241b26;font:700 18px system-ui;}
body.light-active {overflow:hidden;}
#test-signal {width:100%;margin-top:9px;}
#comm-status {border-top:1px solid #526f87;padding-top:12px;min-height:48px;}
#pulse-wave {width:100%;height:80px;}
#viewfinder {position:relative;margin:12px 0;}
#camera {display:block;width:100%;border-radius:8px;}
.roi {position:absolute;left:47.5%;top:47.5%;width:5%;height:5%;box-sizing:border-box;pointer-events:none;border:2px solid #ffe0a3;}
#signal-level {width:100%;}
body.communicating .viz,body.communicating .screen-center {display:none;}
body.communicating .rig {transform:none;}
body.communicating .rig-zone {align-self:start;}
body.communicating .rig-zone::before,body.communicating .rig-zone::after {display:none;}
@media(max-width:900px) {.entry-buttons {justify-content:center;}.help {text-align:left;}}

#receive-candidate {border-color:#e2b76b;color:#ffe4aa;}
#s6-lab {margin:16px 0;padding:10px;border:1px solid #7393a7;border-radius:8px;}
#s6-lab output {white-space:pre-wrap;overflow-wrap:anywhere;}
.s6-table {overflow-x:auto;max-width:100%;}
.s6-table table {width:100%;font-size:12px;border-collapse:collapse;}
.s6-table th,.s6-table td {padding:6px;border-bottom:1px solid #526f87;}
#s6-preview {white-space:pre-line;}

.s6-table th,.s6-table td {white-space:nowrap;font-size:11px;padding:5px 3px;}
.writing-buttons {display:grid;grid-template-columns:1fr 1fr;gap:6px;margin:10px 0;}
.writing-buttons button {min-width:0;overflow-wrap:anywhere;min-height:44px;}
#writing-all {grid-column:1/-1;}

#writing-stop {grid-column:1/-1;background:#9d5c61;color:#fff;}
