:root {
  --ink: #18294a;
  --blue: #2349aa;
  --blue-deep: #193983;
  --paper: #faf6ea;
  --sheet: #fffdf5;
  --yellow: #ffdb69;
  --coral: #ef8e79;
  --muted: #525d69;
  --rule: #c6c4b5;
  --display: var(--oh-font-display, "Bricolage Grotesque", sans-serif);
  --body: "DM Sans", sans-serif;
  --arrow: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12h15m-6-6 6 6-6 6'/%3E%3C/svg%3E");
  --handset: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='1.8' stroke-linejoin='round'%3E%3Cpath d='M6.8 3.1 9 7.6a1.2 1.2 0 0 1-.2 1.3l-1.5 1.7a13.3 13.3 0 0 0 6 6l1.8-1.4a1.2 1.2 0 0 1 1.3-.2l4.4 2.2a1.2 1.2 0 0 1 .6 1.3l-.4 2c-.2.9-1.1 1.6-2 1.5C10 21.4 2.6 14 2 5c-.1-.9.6-1.8 1.5-2l2-.4a1.2 1.2 0 0 1 1.3.5Z'/%3E%3C/svg%3E");
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; color: var(--ink); background: var(--paper); font: 450 1rem/1.48 var(--body); }
h1,h2,h3,p,ol,ul { margin: 0; }
h1,h2,h3 { line-height: 1.05; overflow-wrap: anywhere; }
h1,h2 { font-family: var(--display); font-weight: 780; letter-spacing: -.035em; }
h2 { font-size: 1.8rem; }
h3 { font-size: 1.05rem; }
button,input,select { font: inherit; }
button,a,summary { -webkit-tap-highlight-color: transparent; }
button,summary,select,input[type=range] { cursor: pointer; }
a { color: var(--blue); text-underline-offset: .23em; }
button { color: inherit; }
::selection { color: var(--ink); background: var(--yellow); }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; }
.skip { position: absolute; top: 0; left: 15px; z-index: 4; padding: 11px 16px; transform: translateY(-130%); background: var(--sheet); }
.skip:focus { transform: translateY(5px); }
.topbar { background: var(--blue); color: var(--sheet); }
.bar-inner,.console { width: min(calc(100% - 2 * clamp(16px, 4vw, 32px)),1050px); margin-inline: auto; }
.bar-inner { display: flex; min-height: 65px; justify-content: space-between; align-items: center; gap: 4px 18px; flex-wrap: wrap; }
.brand { display: inline-flex; align-items: center; min-height: 44px; }
.brand img { display: block; width: 82px; height: auto; }
.topbar nav { display: flex; flex-wrap: wrap; gap: 0 16px; align-items: center; }
.topbar nav a,.topbar nav button { display: inline-flex; align-items: center; min-height: 44px; color: inherit; background: none; border: 0; padding: 4px 0; text-decoration: none; font-size: .88rem; font-weight: 650; }
.topbar :focus-visible,#call :focus-visible { outline-color: var(--yellow); }
.console { container-type: inline-size; padding-block-end: clamp(32px,6vw,64px); }
#alerts:not(:empty) { margin-block: 16px 6px; background: var(--yellow); padding: 11px 15px; border-radius: 5px; font-weight: 550; overflow-wrap: anywhere; }
.auth-layout { display: grid; grid-template-columns: minmax(0,1.18fr) minmax(0,1fr); align-items: center; gap: clamp(28px,6vw,84px); width: min(100%,950px); margin: clamp(32px,7vh,76px) auto 0; }
.book-outer { position: relative; isolation: isolate; padding-right: 12px; }
.book-cover { position: relative; min-height: clamp(248px,29vw,355px); display: flex; flex-direction: column; justify-content: space-between; gap: 24px; padding: clamp(24px,3vw,38px) 25px clamp(22px,3vw,34px) clamp(30px,4vw,45px); background: var(--blue); color: var(--paper); border-radius: 6px 20px 20px 6px; box-shadow: 0 9px 12px -12px #18294a80; }
.book-cover::before { content: ""; position: absolute; inset: 0 auto 0 13px; border-left: 1px solid #153579; border-right: 1px solid #4162bc; }
.book-cover h1 { max-width: 100%; font-size: clamp(2.45rem,5.6vw,4.2rem); line-height: .94; }
.book-cover h1 span,.guide h1 span { color: var(--yellow); }
.book-tabs { position: absolute; top: 15%; right: 0; bottom: 13%; width: 20px; display: flex; flex-direction: column; gap: 6px; z-index: -1; }
.book-tabs i { flex: 1; background: var(--yellow); border-radius: 0 8px 8px 0; }
.book-tabs i:nth-child(2) { background: var(--coral); }
.book-tabs i:nth-child(3) { background: #8dcbb7; }
.portraits { display: flex; width: min(100%,265px); align-items: center; gap: 4px; isolation: isolate; padding: 6px; }
.portraits span { display: block; flex: 1 1 0; min-width: 0; overflow: hidden; padding: 4px 4px 10px; background: #f7e6bd; transform: rotate(-8deg); box-shadow: 1px 3px 6px #132f672b; }
.portraits img { width: 100%; height: auto; aspect-ratio: 1; display: block; object-fit: contain; }
.portraits span:nth-child(2) { margin-bottom: 4px; z-index: 1; transform: rotate(3deg); background: #fff4d1; }
.portraits span:nth-child(3) { transform: rotate(10deg); background: #f4cfbb; }
.auth-panel h2 { font-size: 2.7rem; }
.auth-panel>p:not(.browser-note) { max-width: 35ch; margin-top: 12px; }
.auth-panel form { margin-top: 25px; }
.auth-panel .browser-note { margin-top: 20px; border-top: 1px solid var(--rule); padding-top: 12px; max-width: 42ch; font-size: .87rem; color: var(--muted); }
form,label { display: grid; }
form { gap: 15px; }
label { gap: 6px; font-size: .9rem; font-weight: 650; }
.auth-panel form { gap: 9px; }
input:not([type=range]):not([type=checkbox]),select {
  width: 100%; min-width: 0; min-height: 47px; border: 1px solid #868c8a; border-radius: 6px; padding: 10px 12px; color: var(--ink); background: var(--sheet); font-size: 1rem; caret-color: var(--blue);
}
input::placeholder { color: #647073; }
input[type=file]::file-selector-button { border: 0; border-radius: 3px; background: #eae7dc; padding: 4px 8px; font: inherit; color: inherit; }
input[type=range],input[type=checkbox] { accent-color: var(--blue); }
input[type=range] { min-height: 31px; }
input[type=checkbox] { width: 19px; height: 19px; margin: 0; }
.button,.btn-call { max-width: 100%; overflow-wrap: anywhere; display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 45px; width: fit-content; border: 1px solid #9a9f99; border-radius: 7px; background: var(--sheet); text-decoration: none; font-weight: 650; padding: 9px 14px; line-height: 1.25; transition: transform 110ms ease-out, background-color 130ms ease-out; }
.primary,.btn-call { background: var(--blue); color: var(--sheet); border-color: var(--blue); }
.auth-panel .button.primary { width: 100%; justify-content: space-between; margin-top: 5px; padding-inline: 16px; }
.continue::after,.btn-call::before { content: ""; flex: none; width: 19px; height: 19px; background: currentColor; mask: var(--arrow) center/contain no-repeat; }
.btn-call::before { mask-image: var(--handset); width: 16px; height: 16px; }
button:active:enabled,.button:active { transform: translateY(1px); }
button:disabled { opacity: .58; cursor: wait; }
.link-button { width: fit-content; padding: 5px 0; min-height: 44px; border: 0; background: none; color: var(--blue); text-decoration: underline; text-underline-offset: .22em; font-size: .91rem; font-weight: 650; }
.fine { font-size: .86rem; line-height: 1.45; color: var(--muted); }
#workspace { width: min(100%,940px); margin: 0 auto; }
.desk-header { display: flex; justify-content: space-between; align-items: end; gap: 25px; padding-block: 36px 22px; }
.desk-header h1 { font-size: 3.5rem; }
#role { width: fit-content; margin-top: 8px; color: var(--muted); font-size: .95rem; }
.house-switch { width: min(255px,38%); flex: none; }
.connection { padding: 12px 0; border-block: 1px solid var(--rule); display: flex; align-items: baseline; gap: 5px 14px; flex-wrap: wrap; color: var(--muted); font-size: .86rem; }
.connection strong { color: var(--ink); }
.connection strong::before { content: ""; display: inline-block; width: 8px; height: 8px; border: 1px solid currentColor; border-radius: 50%; margin-right: 7px; }
.connection[data-connected=true] strong::before { background: #367556; border-color: #367556; }
.line-grid { display: grid; grid-template-columns: minmax(0,1.15fr) minmax(0,.85fr); gap: clamp(30px,5vw,70px); padding-block: 28px 16px; }
.call-list,.activity,.admin { min-width: 0; }
.line-grid h2,.admin>h2 { position: relative; align-self: start; display: table; font-size: 1.48rem; background: var(--yellow); border-radius: 6px 12px 0 0; padding: 8px 16px 9px; }
.activity h2 { background: #e7d8c8; }
.admin>h2 { background: #b7d6ca; }
#destinations,.activity ol,.admin>details:first-of-type { border-top: 1px solid var(--ink); }
#destinations { background: var(--sheet); }
.dest { display: grid; grid-template-columns: auto minmax(0,1fr) auto; align-items: center; gap: 5px 12px; padding: 12px; border-bottom: 1px solid var(--rule); }
.dest>div { display: grid; gap: 2px; min-width: 0; }
.dest strong { font-size: 1.06rem; line-height: 1.22; overflow-wrap: anywhere; }
.dest small,.activity small { color: var(--muted); font-size: .83rem; }
.dest .btn-call { justify-self: end; }
.avatar { width: 49px; height: 49px; flex: none; border-radius: 50%; object-fit: cover; }
.avatar.home { width: 69px; height: 53px; border-radius: 0; object-fit: contain; }
#destinations>p { padding: 14px; }
.no-dest { display: grid; grid-template-columns: 84px minmax(0,1fr); gap: 4px 14px; align-items: center; padding: 16px; border-bottom: 1px solid var(--rule); }
.no-dest img { grid-row: span 2; width: 84px; height: auto; }
.no-dest p { font-size: .92rem; }
.no-dest button { justify-self: start; }
.activity ol,#contacts { list-style: none; padding: 0; }
.activity li { display: flex; align-items: center; gap: 12px; padding: 12px 3px; border-bottom: 1px solid var(--rule); }
.activity li div { display: grid; gap: 2px; min-width: 0; overflow-wrap: anywhere; }
.call-direction { width: 31px; height: 31px; flex: none; display: grid; place-content: center; background: #e4e8ef; color: var(--blue); border-radius: 50%; }
.call-direction::before { content: ""; width: 17px; height: 17px; background: currentColor; mask: var(--arrow) center/contain no-repeat; transform: rotate(-45deg); }
.call-direction.incoming::before { transform: rotate(135deg); }
.activity li.log-empty { color: var(--muted); border: none; padding-block: 17px; font-size: .94rem; }
.admin { padding-top: 16px; }
.admin details { border-bottom: 1px solid var(--rule); }
.admin summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; list-style: none; padding: 14px 4px; min-height: 51px; font-weight: 680; }
.admin summary::-webkit-details-marker { display: none; }
.admin summary::after { content: ""; width: 9px; height: 9px; flex: none; border: solid var(--blue); border-width: 0 1.7px 1.7px 0; transform: translate(-5px,-2px) rotate(45deg); }
.admin details[open]>summary::after { transform: translate(-5px,2px) rotate(225deg); }
.details-body { padding: 0 4px 17px; }
.details-body>p { max-width: 58ch; margin-bottom: 10px; }
#settings { max-width: 450px; padding-top: 6px; }
.check { display: flex; align-items: center; gap: 9px; min-height: 40px; }
.times { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,8.5em),1fr)); gap: 12px; }
#contacts li { display: flex; gap: 10px; align-items: center; border-top: 1px solid var(--rule); padding: 7px 0; }
#contacts span { overflow-wrap: anywhere; }
#contacts .avatar { width: 37px; height: 37px; }
#contacts li>.link-button { margin-left: auto; }
.move-up { width: 44px; min-height: 44px; background: transparent; border: 0; color: var(--blue); font-size: 1.18rem; }
.button-row,.memberships,.call-buttons { display: flex; flex-wrap: wrap; gap: 9px; }
.button-row { margin-top: 9px; }
.memberships { border-top: 1px solid var(--rule); padding-top: 6px; margin-top: 30px; gap: 4px 26px; }
.invite-preview,.empty { border-radius: 8px; background: #f9eab5; padding: 20px; margin-bottom: 18px; }
.invite-preview p,.empty p { margin-top: 7px; max-width: 54ch; }
.invite-preview .button,.invite-preview>.link-button { margin: 10px 12px 0 0; }
.invite-preview label { margin-top: 12px; max-width: 285px; }
.empty { background: #ebe9dc; display: flex; align-items: center; gap: 22px; }
.empty img { width: min(24%,160px); height: auto; }
#pending-invites h3 { margin-top: 16px; }
.pending-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; border-bottom: 1px solid var(--rule); font-size: .88rem; }
.pending-row span { overflow-wrap: anywhere; }
dialog { width: min(92vw,440px); max-height: 90dvh; overflow: auto; border: 0; border-radius: 12px; padding: 23px; color: var(--ink); background: var(--sheet); box-shadow: 0 18px 60px #11244748; }
dialog::backdrop { background: #111b32a6; }
.dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.dialog-heading h2 { font-size: clamp(1.2rem,calc(.95rem + 2vw),1.8rem); }
.close { display: grid; place-items: center; width: 44px; height: 44px; flex: none; background: #eeeadd; border: 0; border-radius: 50%; }
.close span { position: relative; width: 16px; height: 16px; }
.close span::before,.close span::after { content: ""; height: 2px; width: 18px; background: currentColor; position: absolute; top: 7px; left: -1px; transform: rotate(45deg); }
.close span::after { transform: rotate(-45deg); }
.dialog-portrait { display: block; width: 83px; height: 83px; border-radius: 50%; object-fit: cover; margin-bottom: 1px; }
.danger,#edit-error { color: #92352d; }
#edit-error:not(:empty) { margin-top: 12px; }
#edit-content>label,#edit-content>.button,#edit-content>.link-button { margin-top: 12px; }
.invite-code { font-weight: 650; overflow-wrap: anywhere; }
#call { padding: 0; width: min(92vw,365px); color: var(--sheet); background: var(--blue); }
.call-view { display: flex; flex-direction: column; max-height: 88dvh; text-align: center; }
.call-identity { min-height: 0; overflow-y: auto; padding: clamp(12px,3dvh,27px) 16px 6px; }
#call-phase { color: var(--yellow); font-size: 1rem; font-weight: 650; }
.call-view h2 { margin-top: 7px; font-size: clamp(1.45rem,calc(1.2rem + 2.2vw),2.15rem); line-height: 1.05; }
.call-photo { width: min(149px,24dvh,66%); height: auto; aspect-ratio: 1; border-radius: 50%; background: var(--sheet); margin: clamp(9px,2dvh,18px) auto; display: block; object-fit: contain; }
#call-detail { font-size: .91rem; }
.call-buttons { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,4em),1fr)); flex-shrink: 0; padding: 8px 12px clamp(12px,2.5dvh,22px); }
.call-buttons .button { width: 100%; padding-inline: 6px; }
.answer { background: var(--yellow); color: var(--ink); border-color: var(--yellow); }
.end { color: var(--ink); background: #ffae95; border-color: #ffae95; }
.secondary { color: var(--sheet); background: transparent; border-color: #c5d0ea; }
.guide-title { display: grid; grid-template-columns: 1.3fr .7fr; align-items: center; gap: 20px; padding-block: 35px 24px; border-bottom: 1px solid var(--ink); }
.guide h1 { font-size: 3.4rem; }
.guide h1 span { color: var(--blue); }
.guide-title p,.guide-columns p { max-width: 55ch; margin-top: 10px; }
.guide-title img { width: min(100%,270px); height: auto; justify-self: end; }
.guide-columns { display: grid; grid-template-columns: 1.15fr .85fr; gap: 35px; padding-top: 24px; }
.guide-steps { list-style: none; counter-reset: steps; padding: 0; margin-top: 15px; }
.guide-steps li { position: relative; padding: 14px 0 15px 39px; border-top: 1px solid var(--rule); counter-increment: steps; }
.guide-steps li::before { content: counter(steps); position: absolute; left: 0; top: 12px; color: var(--blue); font: 750 1.4rem var(--display); }
.guide-steps li p { margin: 5px 0 0; font-size: .94rem; }
.guide-columns aside { align-self: start; padding: 22px; background: #faebba; border-radius: 6px; }
.install-actions { display: grid; gap: 8px; }
.install-actions:not(:empty),#web-install { margin-top: 16px; }
@media (hover:hover) and (pointer:fine) {
  .primary:hover,.btn-call:hover { background: var(--blue-deep); }
  .topbar nav a:hover,.topbar nav button:hover { text-decoration: underline; text-underline-offset: .24em; }
  .button:not(.primary):not(.end):not(.answer):not(.secondary):hover,.close:hover { background: #e9e5d7; }
  .admin summary:hover,.link-button:hover { color: var(--blue-deep); }
}
@container (max-width: 41em) {
  .auth-layout { grid-template-columns: minmax(0,1fr); gap: 24px; max-width: 510px; margin-top: 24px; }
  .book-cover { min-height: 128px; flex-flow: row wrap; justify-content: space-between; align-items: center; gap: 8px 14px; padding: 18px 16px 18px 29px; border-radius: 5px 14px 14px 5px; }
  .book-cover h1 { flex: 0 1 auto; font-size: clamp(1.85rem,7vw,2.65rem); line-height: 1; }
  .portraits { flex: 0 1 132px; max-width: 100%; }
  .portraits span { padding: 2px 2px 5px; }
  .book-tabs { right: 1px; }
  .auth-panel h2 { font-size: 2rem; }
  .auth-panel form { margin-top: 16px; }
  .auth-panel>p:not(.browser-note) { margin-top: 7px; }
  .desk-header { padding: 22px 0 16px; flex-direction: column; align-items: start; gap: 10px; }
  .desk-header h1,.guide h1 { font-size: 2.55rem; }
  #role { margin-top: 5px; }
  .house-switch { width: 100%; }
  .line-grid,.guide-columns { grid-template-columns: minmax(0,1fr); gap: 22px; }
  .line-grid { padding-block: 20px 8px; }
  .line-grid h2,.admin>h2 { font-size: 1.32rem; }
  .connection { display: grid; gap: 2px; }
  .empty { gap: 12px; padding: 15px; }
  .empty img { width: 26%; }
  .empty h2,.invite-preview h2 { font-size: 1.45rem; }
  .no-dest { grid-template-columns: 60px minmax(0,1fr); }
  .no-dest img { width: 60px; }
  .guide-title { grid-template-columns: minmax(0,1fr) 26%; padding-block: 24px 18px; }
  .guide-columns { gap: 18px; }
}
@container (max-width: 20em) {
  .dest { column-gap: 8px; }
  .dest .avatar.home { width: 47px; height: 38px; }
  .btn-call { padding-inline: 10px; }
}
@container (max-width: 15em) {
  .empty { display: block; }
  .empty img { margin-block-end: 12px; }
  .no-dest { grid-template-columns: minmax(0,1fr); }
  .no-dest img { grid-row: auto; }
  .dest { grid-template-columns: auto minmax(0,1fr); }
  .dest .btn-call { grid-column: 2; justify-self: start; }
  .guide-title { grid-template-columns: minmax(0,1fr); }
  .guide-title img { width: 100px; justify-self: start; }
}
@media(max-width:610px) {
  .bar-inner { min-height: 55px; }
  .brand img { width: 71px; }
}
@media(prefers-reduced-motion:reduce) { *,*::before,*::after { transition: none !important; } }
