/* ChatDuo chat applet: the refresh skin. Host-side, loaded after chatduo-chat.css and chat-host.css.
   Look and feel only. It changes no markup, no copy and no behaviour: chatduo-chat.js is untouched, and this file
   only restyles classes the applet already renders (applet 2.0.0; the class list it depends on is in
   docs/chat-skin-classes.md, checked by tools/check-skin.mjs). Scoped under html[data-cdr] like duo.css, so the same
   kill switch removes it. Geometry the applet computes in JavaScript (video sizes, the chat screen's top and
   height) is left alone; so are the fixed layers' positions.

   Colour roles: you are the blue-teal bubble, the stranger is the sun-yellow one, as in the drawings.
   The old red "Stranger:" read as an error state; nothing in a chat is red now except Report. */

html[data-cdr] #chatduo-chat {
  --cd-accent: #21346C; --cd-accent-ink: #fff; --cd-accent-2: #FFBF24; --cd-radius: 16px;
  --cd-ink: #111; --cd-muted: #5a5a66; --cd-line: #DCE6EC; --cd-you: #21346C; --cd-stranger: #8A5200; --cd-danger: #B42318;
}
html[data-cdr] .cd :focus-visible { outline: 3px solid #21346C; outline-offset: 3px; }

/* ---------- Buttons (start panel, dialogs, post-chat) ---------- */
html[data-cdr] .cd .cd-btn {
  border: 2.5px solid #111; border-radius: 999px; background: #111; color: #fff; font-weight: 800; letter-spacing: .03em;
  box-shadow: 4px 4px 0 #16BAF6; transition: transform .12s cubic-bezier(.2, .8, .2, 1), box-shadow .12s cubic-bezier(.2, .8, .2, 1); -webkit-tap-highlight-color: transparent;
}
html[data-cdr] .cd .cd-btn:hover { filter: none; transform: translate(-1px, -1px); box-shadow: 5px 5px 0 #16BAF6; }
html[data-cdr] .cd .cd-btn:active { filter: none; transform: translate(4px, 4px); box-shadow: 0 0 0 #16BAF6; }
html[data-cdr] .cd .cd-btn:disabled, html[data-cdr] .cd .cd-btn[aria-disabled=true] { opacity: .42; transform: none; box-shadow: none; }

/* ---------- Start panel ---------- */
html[data-cdr] .cd .cd-start { max-width: none; padding: 0; text-align: left; position: relative; z-index: 1; }
html[data-cdr] .cd .cd-notice { display: inline-flex; margin: 0 10px 12px 0; padding: 5px 12px 4px; border: 2px solid #111; border-radius: 999px; font-size: 12px; font-weight: 800; letter-spacing: .07em; line-height: 1.3; text-transform: uppercase; vertical-align: middle; }
html[data-cdr] .cd .cd-online { display: inline-flex; align-items: center; margin: 0 0 12px; min-height: 1.4em; font-size: 14px; font-weight: 600; color: #3f3f4a; vertical-align: middle; white-space: pre; }
html[data-cdr] .cd .cd-online::before { content: ""; flex: none; width: 25px; height: 10px; margin-right: 8px; background: radial-gradient(circle at 5px 50%, #16BAF6 0 5px, transparent 5.6px), radial-gradient(circle at 20px 50%, #FFBF24 0 5px, transparent 5.6px); animation: cds-beat 1.6s ease-in-out infinite; }
html[data-cdr] .cd .cd-online:empty::before { display: none; }
html[data-cdr] .cd .cd-online strong { color: #111; font-weight: 800; }
html[data-cdr] .cd .cd-modes { justify-content: flex-start; gap: 12px 14px; }
html[data-cdr] .cd .cd-modes .cd-or { font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: #6b6b73; }
html[data-cdr] .cd .cd-modes .cd-btn { height: 62px; min-width: 150px; padding: 0 28px 0 24px; gap: 11px; font-size: 19px; text-transform: uppercase; }
html[data-cdr] .cd .cd-modes .cd-btn.cd-text { min-width: 214px; }
html[data-cdr] .cd .cd-modes .cd-btn.cd-video { background: linear-gradient(135deg, #24D5B5, #16BAF6); color: #14224d; box-shadow: 4px 4px 0 #111; }
html[data-cdr] .cd .cd-modes .cd-btn.cd-video:hover { box-shadow: 5px 5px 0 #111; } html[data-cdr] .cd .cd-modes .cd-btn.cd-video:active { box-shadow: 0 0 0 #111; }
html[data-cdr] .cd .cd-modes .cd-btn::before { content: ""; flex: none; width: 25px; height: 25px; background: currentColor; -webkit-mask: var(--cds-ic) center / contain no-repeat; mask: var(--cds-ic) center / contain no-repeat; }
html[data-cdr] .cd .cd-modes .cd-btn.cd-text { --cds-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M7.500 2.500h9a4 4 0 0 1 4 4v6a4 4 0 0 1-4 4h-5.300l-5.600 5 1-5.300a4 4 0 0 1-3.100-3.900V6.500a4 4 0 0 1 4-4z'/%3E%3C/svg%3E"); }
html[data-cdr] .cd .cd-modes .cd-btn.cd-video { --cds-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5.500 5.500h7a3.500 3.500 0 0 1 3.500 3.500v.800l4.600-2.700a1 1 0 0 1 1.500.900v8a1 1 0 0 1-1.500.900L16 14.200v.800a3.500 3.500 0 0 1-3.500 3.500h-7A3.500 3.500 0 0 1 2 15V9a3.500 3.500 0 0 1 3.500-3.500z'/%3E%3C/svg%3E"); }
html[data-cdr] .cd .cd-free { margin: 14px 0 0; font-size: 13.5px; font-weight: 700; color: #3f3f4a; }
html[data-cdr] .cd .cd-videostatus, html[data-cdr] .cd .cd-adult { font-size: 13.5px; }
html[data-cdr] .cd .cd-interests { margin-top: 22px; }
html[data-cdr] .cd .cd-interests h2 { margin: 0 0 9px; text-align: left; font-size: 16px; font-weight: 800; letter-spacing: -.005em; color: #111; }
html[data-cdr] .cd .cd-tageditor { min-height: 52px; padding: 7px 12px; border: 2px solid #C9D6DE; border-radius: 16px; transition: border-color .15s, box-shadow .15s; }
html[data-cdr] .cd .cd-tageditor:focus-within { border-color: #111; box-shadow: 4px 4px 0 #16BAF6; }
html[data-cdr] .cd .cd-taginput:focus-visible { outline: 0; }
html[data-cdr] .cd .cd-tag { padding: .22em .3em .22em .8em; background: #21346C; font-weight: 700; }
html[data-cdr] .cd .cd-chips { justify-content: flex-start; gap: 8px; margin-top: 11px; }
html[data-cdr] .cd .cd-chip { padding: 7px 15px; border: 2px solid #DCE6EC; border-radius: 999px; background: #fff; font-size: 14px; font-weight: 700; color: #111; transition: border-color .15s, background-color .15s, transform .12s; }
html[data-cdr] .cd .cd-chip:hover { border-color: #111; background: #F1FAFD; color: #111; transform: translateY(-1px); }
html[data-cdr] .cd .cd-chip:active { transform: translateY(1px); }
html[data-cdr] .cd .cd-uselikes { text-align: left; font-size: 14px; }
html[data-cdr] .cd .cd-langrow { justify-content: flex-start; margin-top: 16px; font-size: 14px; font-weight: 600; color: #5a5a66; }
html[data-cdr] .cd .cd-langrow select { padding: 7px 12px; border: 2px solid #DCE6EC; border-radius: 999px; background: #fff; font-weight: 700; color: #111; }
html[data-cdr] .cd .cd-ban { padding: 16px 18px; border: 2px solid #B42318; border-radius: 18px; }
html[data-cdr] .cd .cd-lock { max-width: none; margin: 0 0 4px; padding: 0; border: 0; }
html[data-cdr] .cd .cd-lock h2 { font-size: 22px; font-weight: 800; letter-spacing: -.02em; }
html[data-cdr] .cd .cd-lockinput { height: 50px; border: 2px solid #C9D6DE; border-radius: 14px; }
html[data-cdr] .cd .cd-lock .cd-btn.cd-lockbtn { height: 50px; padding: 0 22px; text-transform: uppercase; font-size: 14px; }
/* phones: the mode buttons come straight after the notice; the counter line follows them. Visual order only
   (flex order): the markup and the reading order of the applet are untouched. */
html[data-cdr] .cd.cd-mobile .cd-start { display: flex; flex-direction: column; }
html[data-cdr] .cd.cd-mobile .cd-start > * { order: 6; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-lock { order: 0; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-notice { order: 1; align-self: flex-start; margin-right: 0; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-ban { order: 2; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-modes { order: 3; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-online { order: 4; align-self: flex-start; margin: 14px 0 0; }
html[data-cdr] .cd.cd-mobile .cd-start > .cd-free { order: 5; margin-top: 8px; }
@media (max-width: 520px) {
  html[data-cdr] .cd .cd-modes { gap: 12px; }
  html[data-cdr] .cd .cd-modes .cd-or { display: none; }
  html[data-cdr] .cd .cd-modes .cd-btn, html[data-cdr] .cd .cd-modes .cd-btn.cd-text { flex: 1 1 0; min-width: 0; height: 60px; padding: 0 10px; font-size: 17px; gap: 8px; }
  html[data-cdr] .cd .cd-modes .cd-btn::before { width: 22px; height: 22px; }
}

/* ---------- Dialogs: the 18+ gate, Report, Block, "End your chat?" ---------- */
@keyframes cds-fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes cds-rise { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes cds-sheet { from { transform: translateY(100%); } to { transform: none; } }
@keyframes cds-beat { 0%, 70%, 100% { transform: scale(.78); opacity: .6; } 35% { transform: scale(1); opacity: 1; } }
html[data-cdr] .cd .cd-overlay { background: rgba(17, 20, 40, .62); animation: cds-fade .18s ease-out; }
html[data-cdr] .cd .cd-dialog { padding: 26px 26px 20px; border: 2.5px solid #111; border-radius: 28px; box-shadow: 8px 8px 0 #111; animation: cds-rise .24s cubic-bezier(.2, .8, .2, 1); }
html[data-cdr] .cd .cd-dialog h2 { margin: 0 2.2em .7em 0; font-size: 24px; line-height: 1.15; font-weight: 800; letter-spacing: -.02em; }
html[data-cdr] .cd .cd-close { top: 16px; right: 16px; width: 40px; height: 40px; line-height: 36px; border: 2px solid #DCE6EC; font-size: 24px; color: #111; }
html[data-cdr] .cd .cd-close:hover { background: #F1FAFD; border-color: #111; }
html[data-cdr] .cd .cd-gatebox { gap: 12px; padding: 14px 16px; border: 2px solid #DCE6EC; border-radius: 18px; background: #F8FCFE; font-weight: 600; line-height: 1.45; transition: border-color .15s, background-color .15s; }
html[data-cdr] .cd .cd-gatebox input { width: 26px; height: 26px; accent-color: #21346C; }
html[data-cdr] .cd .cd-gatebox.cd-invalid { border-color: #B42318; background: #fff6f5; }
html[data-cdr] .cd .cd-dialog .cd-btn { height: 48px; padding: 0 22px; font-size: 15px; text-transform: uppercase; }
html[data-cdr] .cd .cd-dialog .cd-btn.cd-gatebtn { height: 58px; margin-top: 14px; font-size: 17px; }
html[data-cdr] .cd .cd-dialog .cd-btn.cd-secondary { background: #fff; color: #111; border-color: #111; box-shadow: 4px 4px 0 #111; }
html[data-cdr] .cd .cd-dialog .cd-btn.cd-secondary:active { box-shadow: 0 0 0 #111; }
html[data-cdr] .cd .cd-dialog .cd-btn.cd-dangerbtn { background: #B42318; border-color: #111; box-shadow: 4px 4px 0 #111; }
html[data-cdr] .cd .cd-dialog .cd-btn.cd-dangerbtn:active { box-shadow: 0 0 0 #111; }
html[data-cdr] .cd .cd-gatelinks { margin-top: 16px; font-size: 13px; }
html[data-cdr] .cd .cd-dialog .cd-reasons label { margin: 0 0 8px; padding: 12px 14px; border: 2px solid #DCE6EC; border-radius: 14px; font-weight: 600; transition: border-color .15s, background-color .15s; }
html[data-cdr] .cd .cd-dialog .cd-reasons input { width: 20px; height: 20px; accent-color: #21346C; }
html[data-cdr] .cd .cd-dialog .cd-row { margin-top: 16px; gap: 12px; }
/* standalone :has() rules (a browser without :has() drops only these) */
html[data-cdr] .cd .cd-gatebox:has(input:checked) { border-color: #111; background: #E9F8FD; }
html[data-cdr] .cd .cd-dialog .cd-reasons label:has(input:checked) { border-color: #111; background: #FFF6DC; }
/* on phones every dialog is a bottom sheet: the checkbox and the button sit under the thumb */
html[data-cdr] .cd.cd-mobile .cd-overlay { align-items: flex-end; padding: 0; }
html[data-cdr] .cd.cd-mobile .cd-dialog { width: 100%; padding: 24px 20px calc(20px + env(safe-area-inset-bottom, 0px)); border-width: 2.5px 0 0; border-radius: 28px 28px 0 0; box-shadow: none; animation: cds-sheet .26s cubic-bezier(.2, .8, .2, 1); }
html[data-cdr] .cd.cd-mobile .cd-dialog .cd-row { flex-direction: column-reverse; }
html[data-cdr] .cd.cd-mobile .cd-dialog .cd-row .cd-btn { width: 100%; height: 52px; }

/* ---------- Chat screen ---------- */
html[data-cdr] .cd .cd-chat { background: #F4F9FC; }
html[data-cdr] .cd .cd-logwrap { border: 2px solid #DCE6EC; border-radius: 22px 22px 0 0; background: #fff; }
html[data-cdr] .cd .cd-log { top: 10px; left: 12px; padding-right: 12px; }
html[data-cdr] .cd .cd-item { padding-bottom: 7px; }
/* wide screens: a text chat reads as one column, not two edges of the window */
html[data-cdr] .cd:not(.cd-mobile) .cd-chat:not(.cd-video) .cd-log { padding-left: max(0px, calc(50% - 452px)); padding-right: max(12px, calc(50% - 440px)); }
/* system lines: quiet, centred */
html[data-cdr] .cd p.cd-status { width: fit-content; max-width: 92%; margin: 4px auto 3px; padding: 7px 15px; border-radius: 16px; background: #EEF6FA; color: #3f3f4a; font-size: 13.5px; font-weight: 700; line-height: 1.4; text-align: center; }
html[data-cdr] .cd div.cd-status { color: #111; font-weight: 400; }
html[data-cdr] .cd .cd-status small { font-size: .92em; font-weight: 600; }
/* messages are bubbles on every layout; the "You:" and "Stranger:" labels stay */
html[data-cdr] .cd .cd-line { width: fit-content; max-width: min(76%, 660px); padding: 8px 15px 10px; border-radius: 20px; font-size: 16px; line-height: 1.42; }
html[data-cdr] .cd .cd-line .cd-who { display: block; margin-bottom: 1px; font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; opacity: .78; }
html[data-cdr] .cd .cd-line.cd-you { margin-left: auto; border-bottom-right-radius: 6px; background: linear-gradient(135deg, #24D5B5, #16BAF6); color: #0f1c40; }
html[data-cdr] .cd .cd-line.cd-you .cd-who { color: #14224d; }
html[data-cdr] .cd .cd-line.cd-stranger { border-bottom-left-radius: 6px; background: #FFBF24; color: #111; }
html[data-cdr] .cd .cd-line.cd-stranger .cd-who { color: #3d2a00; }
html[data-cdr] .cd .cd-typing { width: fit-content; padding: 7px 14px; border-radius: 18px 18px 18px 6px; background: #FFE9AE; color: #5c4200; font-size: 13px; font-weight: 700; animation: cds-beat 1.4s ease-in-out infinite; }
/* the label shows once per run of messages (still read out for every message) */
html[data-cdr] .cd .cd-item:has(> .cd-line.cd-you) + .cd-item > .cd-line.cd-you .cd-who,
html[data-cdr] .cd .cd-item:has(> .cd-line.cd-stranger) + .cd-item > .cd-line.cd-stranger .cd-who { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* Report and Block are buttons you can see */
html[data-cdr] .cd .cd-tools { gap: 8px; padding: 0 12px; border: 2px solid #DCE6EC; border-top: 0; background: #fff; }
html[data-cdr] .cd .cd-tools::before { content: ""; width: 86px; height: 24px; margin-right: auto; background: url(../img/logo.svg) left center / contain no-repeat; opacity: .5; }
html[data-cdr] .cd .cd-tools a { display: inline-flex; align-items: center; gap: 6px; padding: 4px 13px 4px 10px; border: 2px solid #DCE6EC; border-radius: 999px; font-size: 13px; font-weight: 800; color: #111; text-decoration: none; transition: border-color .15s, background-color .15s; }
html[data-cdr] .cd .cd-tools a::before { content: ""; width: 15px; height: 15px; background: currentColor; -webkit-mask: var(--cds-ic) center / contain no-repeat; mask: var(--cds-ic) center / contain no-repeat; }
html[data-cdr] .cd .cd-tools a.cd-report { color: #B42318; border-color: #F1C9C4; --cds-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M5 22a1 1 0 0 1-1-1V4.200a1 1 0 0 1 .600-.900c5.200-2.500 8.400 2.200 12.900.300a1 1 0 0 1 1.500.900v9.300a1 1 0 0 1-.600.900c-4.700 2.300-7.900-1.700-12.400-.300V21a1 1 0 0 1-1 1z'/%3E%3C/svg%3E"); }
html[data-cdr] .cd .cd-tools a.cd-block { --cds-ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill-rule='evenodd' d='M12 2a10 10 0 1 0 0 20 10 10 0 0 0 0-20zM5 12a7 7 0 0 1 11.200-5.600L6.400 16.200A7 7 0 0 1 5 12zm2.800 5.600l9.800-9.800A7 7 0 0 1 7.800 17.600z'/%3E%3C/svg%3E"); }
html[data-cdr] .cd .cd-tools a:hover { text-decoration: none; border-color: currentColor; background: #F8FCFE; }
html[data-cdr] .cd .cd-tools a[aria-disabled=true] { color: #9aa5b1; border-color: #E6ECF0; }
/* the bar: Stop, the message, Send */
html[data-cdr] .cd .cd-stopwrap, html[data-cdr] .cd .cd-sendwrap { border: 0; background: transparent; overflow: visible; padding: 8px 4px 6px 0; margin: 0; }
html[data-cdr] .cd .cd-sendwrap { padding: 8px 4px 6px 10px; }
html[data-cdr] .cd .cd-stopwrap { margin-right: 10px; }
html[data-cdr] .cd .cd-stop, html[data-cdr] .cd .cd-send { width: 6.6em; height: 100%; border: 2.5px solid #111; border-radius: 20px; background: #fff; color: #111; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; box-shadow: 4px 4px 0 #111; transition: transform .12s, box-shadow .12s, background-color .15s; -webkit-tap-highlight-color: transparent; }
html[data-cdr] .cd .cd-stop:hover:enabled, html[data-cdr] .cd .cd-send:hover:enabled { background: #fff; transform: translate(-1px, -1px); box-shadow: 5px 5px 0 #111; }
html[data-cdr] .cd .cd-stop:active:enabled, html[data-cdr] .cd .cd-send:active:enabled { transform: translate(4px, 4px); box-shadow: 0 0 0 #111; }
html[data-cdr] .cd .cd-send { background: linear-gradient(135deg, #24D5B5, #16BAF6); color: #14224d; }
html[data-cdr] .cd .cd-send:hover:enabled { background: linear-gradient(135deg, #24D5B5, #16BAF6); }
html[data-cdr] .cd .cd-stop:disabled, html[data-cdr] .cd .cd-send:disabled { background: #EEF2F5; color: #8a94a0; border-color: #C9D6DE; box-shadow: none; }
html[data-cdr] .cd .cd-stopwrap.cd-new { background: transparent; }
html[data-cdr] .cd .cd-stopwrap.cd-new .cd-stop { background: #111; color: #fff; box-shadow: 4px 4px 0 #16BAF6; }
html[data-cdr] .cd .cd-stopwrap.cd-new .cd-stop:hover:enabled { background: #111; box-shadow: 5px 5px 0 #16BAF6; }
html[data-cdr] .cd .cd-stopwrap.cd-new .cd-stop:active:enabled { box-shadow: 0 0 0 #16BAF6; }
html[data-cdr] .cd .cd-stopwrap.cd-really .cd-stop { background: #FFBF24; }
html[data-cdr] .cd .cd-stopwrap.cd-really.cd-anim { background: transparent; }
html[data-cdr] .cd .cd-stopwrap.cd-really.cd-anim .cd-stop { background: #111; color: #fff; }
html[data-cdr] .cd .cd-hint { font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: currentColor; opacity: .55; }
html[data-cdr] .cd .cd-msgwrap { margin: 8px 0 6px; padding: 10px 16px; border: 2px solid #C9D6DE; border-radius: 20px; background: #fff; transition: border-color .15s, box-shadow .15s; }
html[data-cdr] .cd .cd-msgwrap:focus-within { border-color: #111; box-shadow: 4px 4px 0 #16BAF6; }
html[data-cdr] .cd .cd-msg:focus-visible { outline: 0; }
html[data-cdr] .cd .cd-exit { height: 34px; padding: 0 14px; border: 2px solid #111; border-radius: 999px; background: #fff; color: #111; font-weight: 800; font-size: 13px; }
/* after a chat: what next, as one card */
html[data-cdr] .cd .cd-rows { width: fit-content; max-width: 100%; margin: 12px 0 6px; padding: 18px 20px 12px; border: 2.5px solid #111; border-radius: 22px; background: #fff; box-shadow: 6px 6px 0 #FFBF24; font-size: 15px; font-weight: 600; }
html[data-cdr] .cd .cd-rows .cd-r { gap: 10px 12px; margin-bottom: 10px; }
html[data-cdr] .cd .cd-rows .cd-btn { height: 48px; padding: 0 24px; font-size: 15px; text-transform: uppercase; }
html[data-cdr] .cd .cd-great { padding: 4px 12px; border-radius: 999px; font-weight: 800; }
html[data-cdr] .cd .cd-rows .cd-pill { padding: 8px 16px; border: 2px solid #111; border-radius: 999px; color: #111; font-weight: 800; }
html[data-cdr] .cd .cd-rows .cd-pill[aria-pressed=true] { background: #111; color: #fff; }
html[data-cdr] .cd .cd-errbtns .cd-btn { height: 48px; padding: 0 22px; font-size: 14px; text-transform: uppercase; }
html[data-cdr] .cd .cd-errbtns .cd-btn.cd-secondary { background: #fff; color: #111; border-color: #111; box-shadow: 4px 4px 0 #111; }
/* "This is your 3rd completed chat this week.": the line after "Great chat?" becomes a small badge */
html[data-cdr] .cd .cd-rows .cd-r:has(.cd-great) + .cd-r:not(:has(*)) { display: inline-flex; padding: 6px 14px; border-radius: 999px; background: #E9F8FD; color: #14224d; font-weight: 800; font-size: 13.5px; }

/* ---------- Video ---------- */
html[data-cdr] .cd .cd-chat.cd-video { background: #1C1C22; }
html[data-cdr] .cd .cd-self, html[data-cdr] .cd .cd-other { background: #111116; border-radius: 20px; outline: 2px solid #34343c; outline-offset: -2px; }
html[data-cdr] .cd .cd-selfctl button { height: 42px; padding: 0 16px; border: 1.5px solid rgba(255, 255, 255, .38); border-radius: 999px; background: rgba(17, 17, 22, .72); font-weight: 800; font-size: 13px; letter-spacing: .02em; }
html[data-cdr] .cd .cd-selfctl button[aria-pressed=true] { background: #FFBF24; border-color: #111; color: #111; }
html[data-cdr] .cd .cd-watermark { width: 104px; height: 30px; font-size: 0; background: url(../img/logo.svg) left center / contain no-repeat; filter: brightness(0) invert(1); opacity: .86; text-shadow: none; }
html[data-cdr] .cd .cd-pulse i { width: 20px; height: 20px; background: linear-gradient(135deg, #24D5B5, #16BAF6); }
html[data-cdr] .cd .cd-pulse i + i { background: #FFBF24; }
html[data-cdr] .cd .cd-swipehint { width: fit-content; margin: 0 auto; padding: 7px 16px; border-radius: 999px; background: rgba(17, 17, 22, .66); text-shadow: none; font-size: 13.5px; }
html[data-cdr] .cd .cd-chat.cd-video .cd-logwrap { background: #232329; border-color: #34343c; border-top-left-radius: 22px; }
html[data-cdr] .cd .cd-chat.cd-video .cd-tools { background: #232329; border-color: #34343c; }
html[data-cdr] .cd .cd-chat.cd-video .cd-tools::before { filter: brightness(0) invert(1); opacity: .6; }
html[data-cdr] .cd .cd-chat.cd-video .cd-tools a { color: #fff; border-color: #44444e; }
html[data-cdr] .cd .cd-chat.cd-video .cd-tools a.cd-report { color: #ff9a8f; border-color: #6d3b37; }
html[data-cdr] .cd .cd-chat.cd-video .cd-tools a:hover { background: #2A2A2F; }
html[data-cdr] .cd .cd-chat.cd-video p.cd-status { background: #2A2A2F; color: #d9d9e2; }
html[data-cdr] .cd .cd-chat.cd-video div.cd-status { color: #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-status a, html[data-cdr] .cd .cd-chat.cd-video .cd-rows a { color: #8fe3ff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-rows { background: #2A2A2F; border-color: #fff; color: #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-rows .cd-pill { background: transparent; border-color: #fff; color: #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-rows .cd-pill[aria-pressed=true] { background: #fff; color: #111; }
html[data-cdr] .cd .cd-chat.cd-video .cd-msgwrap { background: #2A2A2F; border-color: #44444e; }
html[data-cdr] .cd .cd-chat.cd-video .cd-msgwrap:focus-within { border-color: #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-msg { color: #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-msg::placeholder { color: #a3a3b2; }
html[data-cdr] .cd .cd-chat.cd-video .cd-stop { background: #2A2A2F; color: #fff; border-color: #fff; box-shadow: 4px 4px 0 #16BAF6; }
html[data-cdr] .cd .cd-chat.cd-video .cd-stop:hover:enabled { background: #2A2A2F; box-shadow: 5px 5px 0 #16BAF6; }
html[data-cdr] .cd .cd-chat.cd-video .cd-stopwrap.cd-new .cd-stop { background: #fff; color: #111; }
html[data-cdr] .cd .cd-chat.cd-video .cd-stopwrap.cd-really .cd-stop { background: #FFBF24; color: #111; }
html[data-cdr] .cd .cd-chat.cd-video .cd-send { border-color: #fff; box-shadow: 4px 4px 0 #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-send:active:enabled { box-shadow: 0 0 0 #fff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-stop:disabled, html[data-cdr] .cd .cd-chat.cd-video .cd-send:disabled { background: #2A2A2F; color: #7d7d8c; border-color: #44444e; box-shadow: none; }
html[data-cdr] .cd .cd-chat.cd-video .cd-typing { background: #4a3c12; color: #ffe9ae; }
html[data-cdr] .cd .cd-chat.cd-video .cd-exit { background: #2A2A2F; color: #fff; border-color: #fff; }
/* the slim site header goes dark with the room (standalone :has() rules) */
html[data-cdr].cd-in-chat:has(.cd-chat.cd-video:not([hidden])) #navigation { background: #1C1C22; border-bottom-color: #2A2A2F; }
html[data-cdr].cd-in-chat:has(.cd-chat.cd-video:not([hidden])) #navigation .main-logo { filter: brightness(0) invert(1); }

/* ---------- Phone layout ---------- */
html[data-cdr] .cd.cd-mobile .cd-chat { background: #F4F9FC; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video { background: #1C1C22; }
html[data-cdr] .cd.cd-mobile .cd-other, html[data-cdr] .cd.cd-mobile .cd-self { border-radius: 0; outline: 0; }
html[data-cdr] .cd.cd-mobile .cd-self { border-radius: 0 0 0 16px; outline: 2px solid rgba(255, 255, 255, .5); outline-offset: -2px; }
html[data-cdr] .cd.cd-mobile .cd-logwrap { border: 0; border-radius: 0; background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-logwrap { background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-log { top: 0; left: 0; padding: 10px 12px 0; }
html[data-cdr] .cd.cd-mobile .cd-tools { justify-content: flex-end; gap: 8px; min-height: 46px; padding: 0 12px; border: 0; background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-tools a { padding: 7px 14px 7px 11px; background: #fff; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-tools { background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-tools a { background: #2A2A2F; }
html[data-cdr] .cd.cd-mobile .cd-bar { padding: 8px 10px; gap: 8px; border-top: 2px solid #DCE6EC; background: #fff; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-bar { border-top-color: #34343c; background: #232329; }
html[data-cdr] .cd.cd-mobile .cd-stopwrap, html[data-cdr] .cd.cd-mobile .cd-sendwrap { padding: 0 4px 4px 0; margin: 0; border: 0; background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-stopwrap.cd-new { background: transparent; }
html[data-cdr] .cd.cd-mobile .cd-stop, html[data-cdr] .cd.cd-mobile .cd-send { width: 5em; border-radius: 999px; font-size: 14px; box-shadow: 3px 3px 0 #111; }
html[data-cdr] .cd.cd-mobile .cd-stopwrap.cd-new .cd-stop { box-shadow: 3px 3px 0 #16BAF6; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-stop { box-shadow: 3px 3px 0 #16BAF6; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-send { box-shadow: 3px 3px 0 #fff; }
html[data-cdr] .cd.cd-mobile .cd-stop:disabled, html[data-cdr] .cd.cd-mobile .cd-send:disabled { box-shadow: none; }
html[data-cdr] .cd.cd-mobile .cd-msgwrap { margin: 0 0 4px; padding: 0 16px; border: 2px solid #C9D6DE; border-radius: 999px; background: #fff; }
html[data-cdr] .cd.cd-mobile .cd-chat.cd-video .cd-msgwrap { background: #2A2A2F; border-color: #44444e; }
html[data-cdr] .cd.cd-mobile .cd-msgwrap:focus-within { box-shadow: none; }
@media (max-height: 499px) { html[data-cdr] .cd.cd-mobile .cd-bar { padding: 4px 8px; } }
html[data-cdr] .cd .cd-group { max-width: 86%; margin-bottom: 6px; }
html[data-cdr] .cd .cd-group .cd-glabel { padding: 0 6px 3px; font-size: 10.5px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
html[data-cdr] .cd .cd-group .cd-bubble, html[data-cdr] .cd .cd-group .cd-bubble:first-of-type, html[data-cdr] .cd .cd-group .cd-bubble:last-of-type { width: fit-content; max-width: 100%; margin-bottom: 3px; padding: 9px 15px 10px; border: 0; border-radius: 20px; font-size: 16px; line-height: 1.4; }
html[data-cdr] .cd .cd-group.cd-you .cd-bubble { margin-left: auto; background: linear-gradient(135deg, #24D5B5, #16BAF6); color: #0f1c40; }
html[data-cdr] .cd .cd-group.cd-you .cd-bubble:last-of-type { border-bottom-right-radius: 6px; }
html[data-cdr] .cd .cd-group.cd-stranger .cd-bubble { background: #FFBF24; color: #111; }
html[data-cdr] .cd .cd-group.cd-stranger .cd-bubble:last-of-type { border-bottom-left-radius: 6px; }
html[data-cdr] .cd .cd-chat.cd-video .cd-group.cd-you .cd-glabel { color: #8fe3ff; }
html[data-cdr] .cd .cd-chat.cd-video .cd-group.cd-stranger .cd-glabel { color: #ffd166; }
html[data-cdr] .cd.cd-mobile .cd-rows { margin-left: auto; margin-right: auto; }
html[data-cdr] .cd.cd-mobile .cd-typing { margin: 0; }

@media (prefers-reduced-motion: reduce) { html[data-cdr] .cd *, html[data-cdr] .cd *::before, html[data-cdr] .cd *::after { animation: none !important; transition: none !important; } }

/* ---------- Reserved height of the start panel (layout shift) ----------
   Same idea as chat-host.css, with this skin's numbers: the panel's measured height per width, low end of each
   range. Re-measure with the site's own tools/measure-panel.js after any change to the start panel's skin
   (tools/visual-check.js warns when the two drift apart). */
/*CDR-RESERVE-START*/
/* Measured 16 November 2026 (px), home and landing pages: desktop 306 at every width from 600 up; touch screens
   521-767: 366; 481-520: 364; 391-480: 410; 361-390: 429; 341-360: 455; 331-340: 473; 330 and narrower: 519. */
html[data-cdr] #chatduo-chat { min-height: 306px; }
@media only screen and (max-width: 767px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 364px; } }
@media only screen and (max-width: 480px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 410px; } }
@media only screen and (max-width: 390px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 429px; } }
@media only screen and (max-width: 360px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 455px; } }
@media only screen and (max-width: 340px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 473px; } }
@media only screen and (max-width: 330px) and (pointer: coarse) { html[data-cdr] #chatduo-chat { min-height: 519px; } }
/*CDR-RESERVE-END*/
