:root {
  color-scheme: light;
  --bg: #f4f7f2;
  --surface: #ffffff;
  --surface-muted: #f0f5ee;
  --surface-strong: #121817;
  --text: #151a18;
  --text-muted: #64706a;
  --line: #dce5dc;
  --accent: #83cf3d;
  --accent-hover: #6fba31;
  --accent-soft: #e8f6d9;
  --brand-cyan: #18b9c4;
  --brand-lime: #c5e52b;
  --brand-green: #73c63b;
  --brand-ink: #101615;
  --brand-gradient: linear-gradient(120deg, var(--brand-cyan), var(--brand-lime));
  --success: #36a85f;
  --success-soft: #dcf4e4;
  --danger: #df4d57;
  --danger-hover: #c63b46;
  --danger-soft: #fbe5e7;
  --warning: #de982a;
  --shadow: 0 24px 70px rgba(23, 39, 30, 0.10);
  --shadow-small: 0 10px 28px rgba(23, 39, 30, 0.075);
  --radius: 24px;
  --radius-small: 14px;
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--bg);
  color: var(--text);
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; background: var(--bg); }
body { min-height: 100vh; margin: 0; background: var(--bg); color: var(--text); }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled, input:disabled, select:disabled { cursor: not-allowed; opacity: .48; }
button, input, select, dialog { color: inherit; }
svg { width: 1.35rem; height: 1.35rem; fill: currentColor; }
[hidden] { display: none !important; }
code { padding: .12rem .35rem; border-radius: .4rem; background: var(--surface-muted); }

:focus-visible { outline: 3px solid color-mix(in srgb, var(--accent) 35%, transparent); outline-offset: 3px; }

.eyebrow { margin: 0 0 .55rem; color: var(--accent); font-size: .72rem; font-weight: 850; letter-spacing: .13em; text-transform: uppercase; }
.brand { display: inline-flex; align-items: center; gap: .8rem; }
.brand__mark { display: grid; width: 2.6rem; height: 2.6rem; place-items: center; border-radius: .85rem; background: linear-gradient(135deg, var(--accent), var(--brand-cyan)); color: white; font-weight: 900; box-shadow: 0 8px 22px rgba(24, 185, 196, .22); }
.brand > div { display: grid; gap: .08rem; }
.brand strong { font-size: .98rem; }
.brand span:not(.brand__mark) { color: var(--text-muted); font-size: .77rem; }
.brand--large .brand__mark { width: 3rem; height: 3rem; }
.brand--large strong { font-size: 1.08rem; }


.splash-screen {
  position: fixed;
  z-index: 100;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 2rem;
  background:
    radial-gradient(circle at 50% 35%, color-mix(in srgb, var(--accent) 18%, transparent), transparent 36%),
    var(--bg);
}
.splash-screen__content {
  display: grid;
  width: min(460px, 100%);
  justify-items: center;
  gap: 1.5rem;
  text-align: center;
}
.splash-screen__content h1 {
  margin: 0;
  font-size: clamp(2rem, 7vw, 3.4rem);
  letter-spacing: -.055em;
}
.splash-screen__content p:last-child {
  max-width: 420px;
  margin-bottom: 0;
  color: var(--text-muted);
  line-height: 1.6;
}
.splash-logo {
  position: relative;
  display: grid;
  width: 6.2rem;
  height: 6.2rem;
  place-items: center;
  border-radius: 2rem;
  background: linear-gradient(135deg, var(--accent), var(--brand-cyan));
  color: white;
  font-size: 2.15rem;
  font-weight: 950;
  box-shadow: 0 25px 65px rgba(24, 185, 196, .28);
}
.splash-logo i {
  position: absolute;
  inset: -.55rem;
  border: 2px solid color-mix(in srgb, var(--accent) 30%, transparent);
  border-radius: 2.4rem;
  animation: splash-ring 2.2s ease-out infinite;
}
.splash-logo i:nth-of-type(2) { animation-delay: .7s; }
.splash-logo i:nth-of-type(3) { animation-delay: 1.4s; }
.splash-progress {
  width: min(260px, 72vw);
  height: .32rem;
  overflow: hidden;
  border-radius: 999px;
  background: var(--line);
}
.splash-progress span {
  display: block;
  width: 42%;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
  animation: splash-progress 1.35s ease-in-out infinite;
}

.login-layout { display: grid; min-height: 100vh; grid-template-columns: minmax(430px, .95fr) 1.05fr; background: var(--surface); }
.login-panel { display: flex; width: min(590px, 100%); min-height: 100vh; padding: clamp(2rem, 5vw, 5rem); flex-direction: column; justify-content: center; }
.login-copy { margin: clamp(3.5rem, 8vh, 6.5rem) 0 2rem; }
.login-copy h1 { max-width: 560px; margin: 0; font-size: clamp(2.7rem, 6vw, 5.6rem); line-height: .95; letter-spacing: -.055em; }
.login-copy > p:last-child { max-width: 520px; margin: 1.3rem 0 0; color: var(--text-muted); font-size: 1.02rem; line-height: 1.65; }
.login-form { display: grid; gap: 1rem; max-width: 500px; }
.field { display: grid; gap: .5rem; }
.field > span { font-size: .82rem; font-weight: 750; }
.field input, .field select { width: 100%; min-height: 3.15rem; padding: .72rem .95rem; border: 1px solid var(--line); border-radius: .85rem; background: var(--surface); box-shadow: 0 1px 0 rgba(0, 0, 0, .02); }
.field input:focus, .field select:focus { border-color: var(--accent); outline: 3px solid color-mix(in srgb, var(--accent) 15%, transparent); }
.remember-control { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 1rem; padding: .4rem 0; cursor: pointer; }
.remember-control > span:first-child { display: grid; gap: .15rem; }
.remember-control strong { font-size: .87rem; }
.remember-control small { color: var(--text-muted); }
.remember-control input { position: absolute; opacity: 0; pointer-events: none; }
.switch { position: relative; width: 3.15rem; height: 1.8rem; border-radius: 999px; background: #cbd0da; transition: background .18s ease; }
.switch::after { position: absolute; top: .21rem; left: .22rem; width: 1.38rem; height: 1.38rem; border-radius: 50%; background: white; box-shadow: 0 2px 6px rgba(0,0,0,.22); content: ""; transition: transform .18s ease; }
.remember-control input:checked + .switch { background: var(--accent); }
.remember-control input:checked + .switch::after { transform: translateX(1.31rem); }
.button, .secondary-button, .danger-button, .text-button, .link-button { border: 0; }
.button { display: inline-flex; min-height: 3.2rem; align-items: center; justify-content: center; gap: .65rem; padding: .8rem 1.15rem; border-radius: .9rem; font-weight: 800; }
.button--primary { background: var(--accent); color: white; box-shadow: 0 12px 28px rgba(115, 198, 59, .24); }
.button--primary:hover { background: var(--accent-hover); }
.button--wide { width: 100%; }
.button__spinner { display: none; width: 1rem; height: 1rem; border: 2px solid rgba(255,255,255,.4); border-top-color: white; border-radius: 50%; animation: spin .8s linear infinite; }
.button.is-loading .button__spinner { display: block; }
.form-message { min-height: 1.3rem; margin: -.2rem 0 0; color: var(--danger); font-size: .86rem; }
.security-note { max-width: 500px; margin: 1.6rem 0 0; color: var(--text-muted); font-size: .75rem; line-height: 1.55; }
.login-visual { position: relative; display: grid; min-height: 100vh; place-items: center; overflow: hidden; background: radial-gradient(circle at 65% 28%, #c5e52b 0, #18b9c4 36%, #171b27 78%); }
.visual-orbit { position: absolute; border: 1px solid rgba(255,255,255,.16); border-radius: 50%; }
.visual-orbit--one { width: 65vw; height: 65vw; }
.visual-orbit--two { width: 38vw; height: 38vw; }
.visual-phone { position: relative; display: grid; width: min(300px, 36vw); aspect-ratio: .58; align-content: start; gap: 1rem; padding: 3rem 2.1rem; border: 1px solid rgba(255,255,255,.25); border-radius: 3rem; background: rgba(255,255,255,.12); box-shadow: 0 40px 100px rgba(0,0,0,.3); backdrop-filter: blur(18px); transform: rotate(8deg); }
.visual-phone__dot { width: 4.2rem; height: 4.2rem; margin: 2rem auto 1rem; border-radius: 50%; background: rgba(255,255,255,.9); }
.visual-phone__line { width: 78%; height: .8rem; margin-inline: auto; border-radius: 999px; background: rgba(255,255,255,.3); }
.visual-phone__line--short { width: 50%; }
.visual-phone__call { display: grid; width: 4.4rem; height: 4.4rem; margin: auto auto 0; place-items: center; align-self: end; border-radius: 50%; background: var(--success); color: white; font-size: 1.2rem; box-shadow: 0 14px 28px rgba(24,163,107,.34); }

.app-shell { min-height: 100vh; padding-bottom: calc(6.8rem + var(--safe-bottom)); }
.topbar { position: sticky; z-index: 20; top: 0; display: flex; min-height: 4.8rem; align-items: center; justify-content: space-between; padding: .75rem clamp(1rem, 4vw, 3.5rem); border-bottom: 1px solid color-mix(in srgb, var(--line) 75%, transparent); background: color-mix(in srgb, var(--bg) 90%, transparent); backdrop-filter: blur(16px); }
.topbar__actions { display: flex; align-items: center; gap: .65rem; }
.icon-button { display: grid; width: 2.65rem; height: 2.65rem; place-items: center; border: 1px solid var(--line); border-radius: .8rem; background: var(--surface); font-size: 1.55rem; }

.presence-control { position: relative; }
.presence-pill {
  display: inline-flex;
  min-height: 2.35rem;
  align-items: center;
  gap: .48rem;
  padding: .45rem .72rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: .78rem;
  font-weight: 800;
  box-shadow: var(--shadow-small);
}
.presence-pill:hover,
.presence-pill[aria-expanded="true"] {
  border-color: color-mix(in srgb, currentColor 30%, var(--line));
}
.presence-pill__dot {
  width: .58rem;
  height: .58rem;
  border-radius: 50%;
  background: currentColor;
}
.presence-pill__chevron {
  margin-left: .05rem;
  color: var(--text-muted);
  font-size: .8rem;
}
.presence-pill--available { color: var(--success); }
.presence-pill--away { color: var(--warning); }
.presence-pill--unavailable { color: var(--danger); }
.presence-pill--invisible { color: var(--text-muted); }

/* États techniques automatiques, affichés dans le même bouton. */
.presence-pill--active,
.presence-pill--conference { color: var(--success); }
.presence-pill--ringing {
  color: var(--danger);
  animation: pulse 1.25s ease-in-out infinite;
}
.presence-pill--connecting { color: var(--warning); }
.presence-pill--error { color: var(--danger); }
.presence-pill--offline { color: var(--text-muted); }
.presence-pill[data-automatic="true"] {
  border-color: color-mix(in srgb, currentColor 24%, var(--line));
}

.presence-menu {
  position: absolute;
  z-index: 55;
  top: calc(100% + .55rem);
  right: 0;
  display: grid;
  width: min(320px, calc(100vw - 1rem));
  gap: .25rem;
  padding: .45rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface);
  box-shadow: var(--shadow);
}
.presence-menu__item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: .7rem;
  padding: .7rem;
  border: 0;
  border-radius: .75rem;
  background: transparent;
  text-align: left;
}
.presence-menu__item:hover,
.presence-menu__item.is-selected {
  background: var(--surface-muted);
}
.presence-menu__dot {
  width: .72rem;
  height: .72rem;
  border-radius: 50%;
  background: var(--text-muted);
}
.presence-menu__dot--available { background: var(--success); }
.presence-menu__dot--away { background: var(--warning); }
.presence-menu__dot--unavailable { background: var(--danger); }
.presence-menu__dot--invisible { background: var(--text-muted); }
.presence-menu__copy {
  display: grid;
  min-width: 0;
  gap: .1rem;
}
.presence-menu__copy strong { font-size: .82rem; }
.presence-menu__copy small {
  color: var(--text-muted);
  font-size: .68rem;
}
.presence-menu__check {
  color: var(--accent);
  opacity: 0;
  font-weight: 900;
}
.presence-menu__item.is-selected .presence-menu__check { opacity: 1; }

.workspace { width: min(1180px, calc(100% - 2rem)); margin: 0 auto; padding: 2rem 0; }
.tabs { display: inline-flex; gap: .35rem; padding: .35rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); box-shadow: var(--shadow-small); }
.tab { display: inline-flex; min-height: 2.75rem; align-items: center; gap: .48rem; padding: .55rem .9rem; border: 0; border-radius: .72rem; color: var(--text-muted); background: transparent; font-weight: 750; }
.tab.is-active { color: var(--accent); background: var(--accent-soft); }
.tab-panel { padding: 2.2rem 0; }
.dialer-layout { display: grid; grid-template-columns: minmax(340px, .82fr) minmax(320px, 1.18fr); gap: 1.5rem; }
.dialer-card, .quick-panel { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.dialer-card { max-width: 580px; padding: clamp(1.4rem, 4vw, 2.6rem); }
.dialer-heading h1, .section-heading h1 { margin: 0; font-size: clamp(1.7rem, 4vw, 2.65rem); line-height: 1.08; letter-spacing: -.04em; }
.number-entry { display: grid; grid-template-columns: 1fr auto; margin: 1.7rem 0; border-bottom: 2px solid var(--line); }
.number-entry:focus-within { border-color: var(--accent); }
.number-entry input { width: 100%; min-width: 0; padding: .8rem .2rem; border: 0; outline: 0; background: transparent; font-size: clamp(1.35rem, 4vw, 2.15rem); font-weight: 650; letter-spacing: .03em; }
.number-entry__clear { border: 0; background: transparent; color: var(--text-muted); font-size: 1.3rem; }
.dialpad { display: grid; grid-template-columns: repeat(3, minmax(74px, 1fr)); gap: .7rem; }
.dialpad button { display: grid; min-height: 4.55rem; place-items: center; align-content: center; gap: .06rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface-muted); transition: transform .12s ease, border-color .12s ease, background .12s ease; }
.dialpad button:hover { border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); background: var(--accent-soft); transform: translateY(-1px); }
.dialpad button:active { transform: scale(.97); }
.dialpad strong { font-size: 1.45rem; }
.dialpad small { color: var(--text-muted); font-size: .58rem; font-weight: 800; letter-spacing: .12em; }
.dialpad.is-disabled { pointer-events: none; opacity: .42; }
.call-button { display: flex; width: 100%; min-height: 3.7rem; align-items: center; justify-content: center; gap: .65rem; margin-top: 1.2rem; border: 0; border-radius: 1rem; background: var(--success); color: white; font-size: 1rem; font-weight: 850; box-shadow: 0 14px 30px rgba(24,163,107,.25); }
.call-button:hover { filter: brightness(.95); }
.quick-panel { padding: clamp(1.4rem, 3vw, 2.1rem); }
.quick-panel__header, .section-heading { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.quick-panel h2 { margin: 0; font-size: 1.55rem; }
.text-button, .link-button { padding: 0; color: var(--accent); background: transparent; font-weight: 750; }
.quick-contacts { display: grid; grid-template-columns: repeat(3, minmax(90px, 1fr)); gap: .8rem; margin-top: 1.5rem; }
.quick-contact { display: grid; min-height: 7.6rem; place-items: center; align-content: center; gap: .65rem; padding: .7rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface-muted); }
.quick-contact span:last-child { max-width: 100%; overflow: hidden; font-size: .78rem; font-weight: 750; text-overflow: ellipsis; white-space: nowrap; }
.avatar { display: grid; width: 2.9rem; height: 2.9rem; flex: 0 0 auto; place-items: center; border-radius: 50%; color: var(--accent); background: var(--accent-soft); font-size: .82rem; font-weight: 900; }
.section-heading { margin-bottom: 1.5rem; }
.secondary-button, .danger-button { min-height: 2.65rem; padding: .58rem .85rem; border-radius: .75rem; font-weight: 750; }
.secondary-button { border: 1px solid var(--line); background: var(--surface); }
.danger-button { background: var(--danger); color: white; }
.danger-button:hover { background: var(--danger-hover); }
.search-box { display: flex; min-height: 3.25rem; align-items: center; gap: .7rem; padding: .6rem .9rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); box-shadow: var(--shadow-small); }
.search-box svg { color: var(--text-muted); }
.search-box input { width: 100%; border: 0; outline: 0; background: transparent; }
.section-message { min-height: 1.3rem; margin: 1rem 0; color: var(--text-muted); font-size: .82rem; }
.contact-list, .history-list { display: grid; gap: .7rem; }
.contact-row { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); }
.contact-row__identity { display: flex; min-width: 190px; align-items: center; gap: .85rem; }
.contact-row__identity > div { display: grid; gap: .15rem; }
.contact-row__identity span { color: var(--text-muted); font-size: .78rem; }
.contact-avatar { position: relative; flex: 0 0 auto; }
.contact-avatar__presence {
  position: absolute;
  right: -.05rem;
  bottom: -.05rem;
  width: .78rem;
  height: .78rem;
  border: 2px solid var(--surface);
  border-radius: 50%;
  background: var(--text-muted);
}
.contact-row__name-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .45rem;
}
.contact-presence {
  display: inline-flex;
  min-height: 1.35rem;
  align-items: center;
  gap: .28rem;
  padding: .12rem .42rem;
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--text-muted);
  font-size: .62rem;
  font-weight: 800;
  white-space: nowrap;
}
.contact-presence__dot {
  width: .42rem;
  height: .42rem;
  border-radius: 50%;
  background: currentColor;
}
.contact-presence--available {
  color: #258b4a;
  background: #e2f5e8;
}
.contact-presence--away {
  color: #b66b00;
  background: #fff0d5;
}
.contact-presence--unavailable {
  color: #c83e49;
  background: #fbe4e7;
}
.contact-presence--busy {
  color: #b93247;
  background: #f8dfe4;
}
.contact-presence--ringing {
  color: #d17800;
  background: #fff0d5;
  animation: pulse 1.25s ease-in-out infinite;
}
.contact-presence--offline {
  color: #66736d;
  background: #e9eeeb;
}
.contact-presence--unknown {
  color: #76817c;
  background: #eef1ef;
}

/* Les pastilles sur les avatars utilisent exactement le même code couleur. */
.contact-avatar__presence {
  background: currentColor;
}
.contact-avatar__presence.contact-presence--available {
  color: #36a85f;
}
.contact-avatar__presence.contact-presence--away {
  color: #de982a;
}
.contact-avatar__presence.contact-presence--unavailable {
  color: #df4d57;
}
.contact-avatar__presence.contact-presence--busy {
  color: #c7354e;
}
.contact-avatar__presence.contact-presence--ringing {
  color: #e28b16;
}
.contact-avatar__presence.contact-presence--offline {
  color: #7c8882;
}
.contact-avatar__presence.contact-presence--unknown {
  color: #96a09b;
}
.contact-row__numbers { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .55rem; }
.phone-chip { display: grid; min-width: 110px; gap: .08rem; padding: .55rem .7rem; border: 0; border-radius: .72rem; color: var(--text); background: var(--surface-muted); text-align: left; }
.phone-chip small { color: var(--text-muted); font-size: .65rem; }
.phone-chip span { font-weight: 700; }
.history-day { margin: 1.3rem .15rem .4rem; color: var(--text-muted); font-size: .78rem; font-weight: 800; text-transform: capitalize; }
.history-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .9rem; padding: .9rem 1rem; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); text-align: left; }
.history-row:hover { border-color: color-mix(in srgb, var(--accent) 35%, var(--line)); }
.history-row--missed { color: var(--danger); }
.history-row__icon { display: grid; width: 2.4rem; height: 2.4rem; place-items: center; border-radius: 50%; background: var(--surface-muted); font-size: 1.2rem; }
.history-row__identity, .history-row__meta { display: grid; gap: .12rem; }
.history-row__identity small, .history-row__meta small { color: var(--text-muted); }
.history-row__meta { justify-items: end; }
.load-more { display: block; margin: 1.2rem auto; }
.empty-state { display: grid; min-height: 180px; place-items: center; align-content: center; padding: 2rem; border: 1px dashed var(--line); border-radius: 1rem; color: var(--text-muted); text-align: center; }
.empty-state strong { color: var(--text); }
.empty-state p { max-width: 420px; margin: .35rem 0 0; }
.empty-state--compact { min-height: 180px; }
.skeleton { min-height: 74px; overflow: hidden; border-radius: 1rem; background: linear-gradient(100deg, var(--surface-muted) 25%, color-mix(in srgb, var(--surface-muted) 35%, var(--surface)) 45%, var(--surface-muted) 65%); background-size: 200% 100%; animation: shimmer 1.3s infinite; }

.call-bar { position: fixed; z-index: 35; right: max(1rem, calc((100vw - 1180px) / 2)); bottom: calc(1rem + var(--safe-bottom)); left: max(1rem, calc((100vw - 1180px) / 2)); display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: 1rem; padding: .8rem 1rem; border: 1px solid rgba(255,255,255,.1); border-radius: 1.25rem; background: color-mix(in srgb, var(--surface-strong) 94%, transparent); color: white; box-shadow: 0 28px 70px rgba(0,0,0,.3); backdrop-filter: blur(16px); }
.call-bar__identity { display: flex; min-width: 0; align-items: center; gap: .75rem; }
.call-bar__identity > div { display: grid; min-width: 0; gap: .04rem; }
.call-bar__identity .avatar { color: white; background: rgba(255,255,255,.16); }
.call-bar__state, .call-bar__number { color: rgba(255,255,255,.66); font-size: .7rem; }
.call-bar__identity strong { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.call-duration { min-width: 4rem; font-variant-numeric: tabular-nums; text-align: center; }
.call-bar__actions { display: flex; gap: .45rem; }
.round-button { display: grid; width: 2.8rem; height: 2.8rem; place-items: center; border: 0; border-radius: 50%; color: white; background: rgba(255,255,255,.13); }
.round-button:hover, .round-button.is-active { background: rgba(255,255,255,.25); }
.round-button--accept { background: var(--success); }
.round-button--hangup { background: var(--danger); }
.call-dtmf { position: absolute; right: 1rem; bottom: calc(100% + .7rem); display: grid; width: 220px; grid-template-columns: repeat(3, 1fr); gap: .35rem; padding: .7rem; border: 1px solid rgba(255,255,255,.12); border-radius: 1rem; background: var(--surface-strong); box-shadow: var(--shadow); }
.call-dtmf button { min-height: 3rem; border: 0; border-radius: .65rem; color: white; background: rgba(255,255,255,.1); font-size: 1.15rem; font-weight: 750; }

.settings-dialog { width: min(580px, calc(100% - 1rem)); max-height: calc(100vh - 1rem); margin-right: .5rem; padding: 0; border: 0; border-radius: 1.4rem; background: var(--surface); box-shadow: var(--shadow); }
.settings-dialog::backdrop { background: rgba(14,18,28,.48); backdrop-filter: blur(4px); }
.settings-sheet { max-height: calc(100vh - 1rem); overflow: auto; padding: 1.3rem; }
.settings-sheet__header { position: sticky; z-index: 2; top: -1.3rem; display: flex; align-items: center; justify-content: space-between; margin: -1.3rem -1.3rem 0; padding: 1.3rem; border-bottom: 1px solid var(--line); background: var(--surface); }
.settings-sheet h2 { margin: 0; font-size: 1.7rem; }
.settings-section { padding: 1.3rem 0; border-bottom: 1px solid var(--line); }
.settings-section h3 { margin: 0 0 1rem; }
.settings-section p { color: var(--text-muted); font-size: .86rem; line-height: 1.55; }
.settings-section .field { margin-bottom: .8rem; }
.settings-actions { display: flex; align-items: center; gap: .8rem; }
.inline-status { color: var(--text-muted); font-size: .78rem; }
.session-details { display: grid; gap: .6rem; }
.session-details div { display: grid; grid-template-columns: 1fr 1.5fr; gap: 1rem; }
.session-details dt { color: var(--text-muted); }
.session-details dd { margin: 0; overflow-wrap: anywhere; text-align: right; }
.settings-warning { padding: .75rem; border-radius: .7rem; background: var(--danger-soft); color: color-mix(in srgb, var(--danger) 78%, var(--text)) !important; }
.diagnostics summary { cursor: pointer; font-weight: 800; }
.diagnostics__actions { display: flex; gap: .5rem; margin: 1rem 0; }
.diagnostics pre { max-height: 280px; overflow: auto; padding: .8rem; border-radius: .75rem; background: var(--surface-strong); color: #dce3f4; font-size: .7rem; white-space: pre-wrap; word-break: break-word; }
.audio-unlock { position: fixed; z-index: 60; top: .7rem; left: 50%; display: flex; align-items: center; gap: .35rem; padding: .6rem .85rem; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); box-shadow: var(--shadow-small); font-size: .78rem; transform: translateX(-50%); }
.toast-region { position: fixed; z-index: 80; top: 1rem; right: 1rem; display: grid; gap: .6rem; }
.toast { max-width: min(390px, calc(100vw - 2rem)); padding: .8rem 1rem; border-radius: .8rem; background: var(--surface-strong); color: white; box-shadow: var(--shadow); }
.toast--error { background: var(--danger); }
.toast--success { background: var(--success); }
.fatal-error { max-width: 700px; margin: 10vh auto; padding: 2rem; border: 1px solid var(--danger); border-radius: 1rem; background: var(--danger-soft); }

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes splash-ring {
  0% { opacity: .65; transform: scale(.82); }
  75%, 100% { opacity: 0; transform: scale(1.28); }
}
@keyframes splash-progress {
  0% { transform: translateX(-125%); }
  55% { transform: translateX(90%); }
  100% { transform: translateX(245%); }
}
@keyframes pulse { 50% { opacity: .55; } }
@keyframes shimmer { to { background-position: -200% 0; } }

@media (max-width: 900px) {
  .login-layout { grid-template-columns: 1fr; }
  .login-panel { width: 100%; padding: 2rem clamp(1.2rem, 8vw, 5rem); }
  .login-copy { margin: 4rem 0 2rem; }
  .login-copy h1 { font-size: clamp(2.8rem, 12vw, 5rem); }
  .login-visual { display: none; }
  .dialer-layout { grid-template-columns: 1fr; }
  .dialer-card { max-width: none; }
  .quick-contacts { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 640px) {
  .topbar { padding-inline: .75rem; }
  .brand > div span { display: none; }
  .presence-pill { padding-inline: .6rem; }
  .presence-pill__chevron { display: none; }
  .workspace { width: min(100% - 1rem, 1180px); padding-top: .8rem; }
  .tabs { position: fixed; z-index: 30; right: .5rem; bottom: calc(.5rem + var(--safe-bottom)); left: .5rem; display: grid; grid-template-columns: repeat(4, 1fr); box-shadow: var(--shadow); }
  .tab { justify-content: center; }
  .tab-panel { padding-top: 1rem; }
  .quick-contacts { grid-template-columns: repeat(3, 1fr); }
  .contact-row { align-items: flex-start; flex-direction: column; }
  .contact-row__numbers { width: 100%; justify-content: flex-start; }
  .phone-chip { flex: 1; }
  .call-bar { right: .5rem; bottom: calc(5.3rem + var(--safe-bottom)); left: .5rem; grid-template-columns: 1fr auto; }
  .call-duration { display: none; }
  .round-button { width: 2.55rem; height: 2.55rem; }
  .call-dtmf { right: 0; }
  .settings-dialog { width: calc(100% - .5rem); height: calc(100% - .5rem); max-height: none; margin: .25rem; }
  .settings-sheet { max-height: 100%; }
  .app-shell { padding-bottom: calc(12rem + var(--safe-bottom)); }
}



@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}


/* Appels vidéo individuels */
.call-actions { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; margin-top: 1.2rem; }
.call-actions .call-button { margin-top: 0; }
.call-button--video { background: var(--accent); box-shadow: 0 14px 30px color-mix(in srgb, var(--accent) 28%, transparent); }
.round-button--video { background: var(--accent); }
.video-stage { position: fixed; z-index: 32; inset: 4.9rem 0 0; overflow: hidden; background: #080a10; color: white; }
.video-stage__remote { width: 100%; height: 100%; object-fit: cover; background: #080a10; }
.video-stage__placeholder { position: absolute; inset: 0; display: grid; place-items: center; align-content: center; gap: .7rem; background: radial-gradient(circle at 50% 35%, #252a3b, #080a10 68%); color: rgba(255,255,255,.72); text-align: center; }
.video-stage__placeholder strong { color: white; font-size: clamp(1.45rem, 4vw, 2.6rem); }
.video-stage__avatar { display: grid; width: 7rem; height: 7rem; place-items: center; border-radius: 50%; background: rgba(255,255,255,.12); font-size: 2.2rem; font-weight: 900; }
.video-stage__topbar { position: absolute; z-index: 2; top: 0; right: 0; left: 0; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1rem 1.2rem 3.5rem; background: linear-gradient(to bottom, rgba(0,0,0,.7), transparent); }
.video-stage__topbar > div { display: flex; align-items: center; gap: .65rem; }
.video-badge { padding: .32rem .55rem; border-radius: 999px; background: rgba(255,255,255,.14); font-size: .72rem; }
.video-stage__local { position: absolute; z-index: 3; right: 1.2rem; bottom: 6.8rem; width: min(25vw, 280px); aspect-ratio: 16 / 9; border: 2px solid rgba(255,255,255,.55); border-radius: 1rem; background: #151925; box-shadow: 0 18px 50px rgba(0,0,0,.4); object-fit: cover; transform: scaleX(-1); }
.video-stage__local.is-screen { width: min(34vw, 440px); transform: none; }
.has-video-call .workspace { visibility: hidden; pointer-events: none; }
.has-video-call .call-bar { z-index: 40; }
.camera-preview { width: 100%; margin-top: 1rem; aspect-ratio: 16 / 9; border-radius: .9rem; background: #0b0e15; object-fit: cover; transform: scaleX(-1); }

@media (max-width: 640px) {
  .call-actions { grid-template-columns: 1fr; }
  .video-stage { inset: 3.9rem 0 0; }
  .video-stage__local { right: .6rem; bottom: 10.5rem; width: 38vw; border-radius: .7rem; }
  .video-stage__local.is-screen { width: 48vw; }
  .video-stage__topbar { padding-inline: .75rem; }
  .call-bar__actions { flex-wrap: wrap; justify-content: flex-end; }
}

/* Conférences vidéo multiparticipants */
.tab { position: relative; }
.tab-badge, .control-badge { display: inline-grid; min-width: 1.2rem; height: 1.2rem; place-items: center; padding: 0 .28rem; border-radius: 999px; background: var(--danger); color: white; font-size: .62rem; font-weight: 900; }
.primary-button { min-height: 3.15rem; padding: .75rem 1.1rem; border: 0; border-radius: .9rem; background: var(--accent); color: white; font-weight: 850; box-shadow: 0 12px 28px color-mix(in srgb, var(--accent) 25%, transparent); }
.primary-button:hover { background: var(--accent-hover); }
.conference-panel { padding-bottom: 8rem; }
.conference-prejoin { display: grid; gap: 1.5rem; }
.conference-hero { display: flex; min-height: 190px; align-items: center; justify-content: space-between; gap: 2rem; overflow: hidden; padding: clamp(1.5rem, 4vw, 2.7rem); border-radius: var(--radius); background: linear-gradient(135deg, #171b27 0%, #187f83 62%, #73c63b 100%); color: white; box-shadow: var(--shadow); }
.conference-hero h1 { margin: 0; font-size: clamp(2rem, 5vw, 3.5rem); letter-spacing: -.045em; }
.conference-hero p:last-child { max-width: 670px; margin-bottom: 0; color: rgba(255,255,255,.72); }
.conference-hero__art { display: grid; width: 190px; flex: 0 0 auto; grid-template-columns: repeat(2, 1fr); gap: .7rem; transform: rotate(6deg); }
.conference-hero__art span { display: grid; aspect-ratio: 1; place-items: center; border: 1px solid rgba(255,255,255,.22); border-radius: 1.2rem; background: rgba(255,255,255,.12); color: rgba(255,255,255,.68); font-size: 1rem; backdrop-filter: blur(8px); }
.conference-join-card { display: grid; grid-template-columns: minmax(300px, 1.15fr) minmax(280px, .85fr); gap: 1.5rem; padding: 1.25rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.conference-preview-wrap { position: relative; display: grid; min-height: 340px; place-items: center; overflow: hidden; border-radius: 1.3rem; background: #090b12; color: white; }
.conference-preview { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.conference-preview__placeholder { display: grid; place-items: center; align-content: center; gap: .65rem; color: rgba(255,255,255,.6); text-align: center; }
.conference-preview__placeholder strong { color: white; }
.conference-preview__button { position: absolute; right: .85rem; bottom: .85rem; border-color: rgba(255,255,255,.22); background: rgba(15,18,28,.72); color: white; backdrop-filter: blur(10px); }
.conference-join-fields { display: flex; padding: .6rem .4rem; flex-direction: column; justify-content: center; gap: .9rem; }
.conference-meeting-picker { display: grid; gap: .65rem; }
.conference-meeting-picker__header { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.conference-meeting-picker__header > div { display: grid; gap: .1rem; }
.conference-meeting-picker__header strong { font-size: .92rem; }
.conference-meeting-picker__header small { color: var(--text-muted); font-size: .7rem; }
.conference-meeting-search { margin: 0; }
.conference-meeting-list { display: grid; max-height: 250px; gap: .5rem; overflow: auto; padding: .1rem .15rem .1rem 0; }
.conference-meeting-card { display: grid; min-height: 4.2rem; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: .65rem; padding: .7rem .75rem; border: 1px solid var(--line); border-radius: .9rem; background: var(--surface-muted); color: var(--text); text-align: left; transition: border-color .15s ease, background .15s ease, transform .15s ease; }
.conference-meeting-card:hover { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); transform: translateY(-1px); }
.conference-meeting-card.is-selected { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 9%, var(--surface)); box-shadow: inset 0 0 0 1px var(--accent); }
.conference-meeting-card__identity { display: grid; min-width: 0; gap: .12rem; }
.conference-meeting-card__identity strong, .conference-meeting-card__identity small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.conference-meeting-card__identity strong { font-size: .82rem; }
.conference-meeting-card__identity small { color: var(--text-muted); font-size: .68rem; }
.conference-meeting-card__meta { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .3rem; }
.conference-meeting-card__meta span { padding: .2rem .38rem; border-radius: 999px; background: var(--surface); color: var(--text-muted); font-size: .56rem; font-weight: 800; }
.conference-meeting-card__check { display: grid; width: 1.45rem; height: 1.45rem; place-items: center; border-radius: 50%; background: var(--accent); color: white; opacity: 0; transform: scale(.8); transition: opacity .15s ease, transform .15s ease; }
.conference-meeting-card.is-selected .conference-meeting-card__check { opacity: 1; transform: scale(1); }
.conference-meeting-message { min-height: 1rem; margin: 0; font-size: .68rem; }
.conference-manual { border-top: 1px solid var(--line); padding-top: .65rem; }
.conference-manual summary { color: var(--text-muted); font-size: .72rem; font-weight: 750; cursor: pointer; }
.conference-manual .field { margin-top: .65rem; }
.conference-options { display: grid; grid-template-columns: 1fr 1fr; gap: .65rem; }
.conference-option { display: flex; min-height: 3rem; align-items: center; gap: .55rem; padding: .65rem .75rem; border: 1px solid var(--line); border-radius: .85rem; background: var(--surface-muted); font-size: .82rem; font-weight: 750; cursor: pointer; }
.conference-option input { accent-color: var(--accent); }
.has-conference .workspace { width: 100%; max-width: none; padding: 0; }
.has-conference .tabs { display: none; }
.has-conference #tab-conference { padding: 0; }
.has-conference .app-shell { padding-bottom: 0; }

.conference-room {
  position: relative;
  display: grid;
  height: min(900px, calc(100dvh - 6.5rem));
  min-height: 560px;
  grid-template-rows: auto minmax(0, 1fr) auto;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #090b12;
  color: white;
  box-shadow: var(--shadow);
}
.has-conference .conference-room {
  height: calc(100dvh - 4.8rem);
  min-height: 0;
  border-right: 0;
  border-left: 0;
  border-radius: 0;
  box-shadow: none;
}
.conference-room:fullscreen {
  width: 100vw;
  height: 100dvh;
  min-height: 0;
  border: 0;
  border-radius: 0;
}

.conference-room__header {
  position: relative;
  z-index: 3;
  display: flex;
  min-height: 5.7rem;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid rgba(255,255,255,.09);
  background: rgba(12,15,23,.88);
  backdrop-filter: blur(14px);
}
.conference-room__header h1 { margin: 0; font-size: 1.35rem; }
.conference-room__header .icon-button {
  border-color: rgba(255,255,255,.15);
  background: rgba(255,255,255,.08);
  color: white;
}
.conference-room__meta {
  display: flex;
  flex-wrap: wrap;
  gap: .8rem;
  margin-top: .3rem;
  color: rgba(255,255,255,.58);
  font-size: .72rem;
}

.conference-room__body {
  position: relative;
  display: grid;
  min-height: 0;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 320px);
  overflow: hidden;
}

.conference-grid {
  position: relative;
  display: grid;
  min-width: 0;
  min-height: 0;
  grid-template-rows: minmax(0, 1fr);
  overflow: hidden;
  background: #080a10;
}
.conference-grid.has-screen-share {
  grid-template-rows: minmax(0, 1fr) clamp(108px, 18vh, 160px);
}

.conference-stage {
  display: grid;
  min-width: 0;
  min-height: 0;
  align-items: stretch;
  justify-items: stretch;
  gap: clamp(.35rem, .7vw, .7rem);
  overflow: hidden;
  padding: clamp(.4rem, .8vw, .8rem);
}
.conference-stage[data-layout="waiting"] {
  grid-template-columns: 1fr;
  grid-template-rows: 1fr;
}
.conference-stage[data-layout="solo"] {
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr);
}
.conference-stage[data-layout="duo"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: minmax(0, 1fr);
}
.conference-stage[data-layout="trio"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="trio"] > .is-primary {
  grid-row: 1 / 3;
}
.conference-stage[data-layout="quartet"] {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="five"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="five"] > .is-primary {
  grid-column: span 2;
  grid-row: span 2;
}
.conference-stage[data-layout="six"] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="seven"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="seven"] > .is-primary {
  grid-column: span 2;
}
.conference-stage[data-layout="eight"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
}
.conference-stage[data-layout="nine"] {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
}
.conference-stage[data-layout="twelve"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(3, minmax(0, 1fr));
}
.conference-stage[data-layout="sixteen"] {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-template-rows: repeat(4, minmax(0, 1fr));
}
.conference-stage[data-layout="dense"] {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  grid-auto-rows: minmax(0, 1fr);
}

.conference-filmstrip {
  display: grid;
  min-width: 0;
  min-height: 0;
  grid-auto-flow: column;
  grid-auto-columns: clamp(150px, 16vw, 230px);
  gap: .5rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: .45rem .7rem .65rem;
  border-top: 1px solid rgba(255,255,255,.08);
  background: #0c0f17;
  scrollbar-width: thin;
}

.conference-grid__waiting {
  position: absolute;
  z-index: 2;
  top: 50%;
  left: 50%;
  display: grid;
  max-width: min(360px, calc(100% - 2rem));
  gap: .25rem;
  padding: .75rem 1rem;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 999px;
  background: rgba(16,20,30,.82);
  color: rgba(255,255,255,.72);
  text-align: center;
  transform: translate(-50%, -50%);
  backdrop-filter: blur(12px);
}
.conference-grid__waiting strong { color: white; font-size: .78rem; }
.conference-grid__waiting span { font-size: .65rem; }

.conference-tile {
  position: relative;
  min-width: 0;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  border: 2px solid transparent;
  border-radius: clamp(.65rem, 1vw, 1rem);
  background: #171b27;
  transition: border-color .15s ease, transform .15s ease;
}
.conference-tile.is-talking {
  border-color: var(--success);
  box-shadow: inset 0 0 0 1px var(--success);
}
.conference-tile.is-primary {
  box-shadow: 0 0 0 1px rgba(255,255,255,.04);
}
.conference-filmstrip .conference-tile {
  min-width: 0;
  min-height: 0;
}
.conference-tile__video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  background: #0b0e15;
}
.conference-stage[data-layout="solo"] .conference-tile__video {
  object-fit: contain;
}
.conference-tile__video.is-mirrored { transform: scaleX(-1); }
.conference-tile.is-screen .conference-tile__video {
  object-fit: contain;
  transform: none;
}
.conference-tile__placeholder {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: radial-gradient(circle, #2b3042 0%, #151925 72%);
}
.conference-tile__avatar {
  display: grid;
  width: clamp(3rem, 8vw, 5rem);
  height: clamp(3rem, 8vw, 5rem);
  place-items: center;
  border-radius: 50%;
  background: rgba(255,255,255,.12);
  font-size: clamp(1rem, 2vw, 1.4rem);
  font-weight: 900;
}
.conference-tile__footer {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 1rem;
  padding: 2.5rem .8rem .7rem;
  background: linear-gradient(transparent, rgba(0,0,0,.78));
}
.conference-tile__footer strong {
  overflow: hidden;
  font-size: clamp(.66rem, .9vw, .82rem);
  text-overflow: ellipsis;
  white-space: nowrap;
}
.conference-tile__badges { white-space: nowrap; }
.conference-tile__fullscreen {
  position: absolute;
  z-index: 4;
  top: .55rem;
  right: .55rem;
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: .5rem;
  background: rgba(8,11,17,.68);
  color: #fff;
  font-size: 1rem;
  line-height: 1;
  cursor: pointer;
  opacity: .72;
  backdrop-filter: blur(8px);
  transition: opacity .15s ease, background .15s ease, transform .15s ease;
}
.conference-tile:hover .conference-tile__fullscreen,
.conference-tile__fullscreen:focus-visible {
  opacity: 1;
  background: rgba(8,11,17,.9);
  transform: scale(1.04);
}
.conference-tile:fullscreen {
  width: 100vw;
  height: 100vh;
  border: 0;
  border-radius: 0;
  background: #05070b;
}
.conference-tile:fullscreen .conference-tile__video {
  object-fit: contain;
}
.conference-tile:fullscreen .conference-tile__placeholder {
  background: #0b0e15;
}
.conference-tile:fullscreen .conference-tile__footer {
  padding: 5rem 1.25rem 1rem;
}
.conference-tile:fullscreen .conference-tile__footer strong {
  font-size: 1rem;
}
.conference-tile:fullscreen .conference-tile__fullscreen {
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  opacity: 1;
  background: rgba(8,11,17,.82);
  font-size: 1.2rem;
}

.conference-side-panel { display: grid; min-width: 0; grid-template-rows: auto minmax(0, 1fr); border-left: 1px solid rgba(255,255,255,.09); background: #11141d; }
.conference-side-panel__section { min-height: 0; padding: 1rem; border-bottom: 1px solid rgba(255,255,255,.08); }
.conference-side-panel h2 { margin: 0 0 .8rem; font-size: .9rem; }
.conference-participant-list { display: grid; max-height: 180px; gap: .4rem; overflow: auto; }
.conference-participant { display: flex; align-items: center; justify-content: space-between; gap: .7rem; padding: .42rem; border-radius: .65rem; }
.conference-participant.is-talking { background: rgba(24,163,107,.16); }
.conference-participant > div { display: flex; min-width: 0; align-items: center; gap: .55rem; }
.conference-participant .avatar { width: 2rem; height: 2rem; color: white; background: rgba(255,255,255,.12); font-size: .62rem; }
.conference-participant > div span:last-child { overflow: hidden; font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.conference-participant__status { flex: 0 0 auto; font-size: .72rem; }
.conference-chat { display: grid; min-height: 300px; grid-template-rows: auto minmax(0, 1fr) auto; }
.conference-chat__messages { display: grid; align-content: start; gap: .6rem; overflow: auto; padding-right: .2rem; }
.conference-chat__messages > p { color: rgba(255,255,255,.45); font-size: .75rem; }
.conference-message { width: fit-content; max-width: 90%; padding: .6rem .7rem; border-radius: .75rem .75rem .75rem .2rem; background: rgba(255,255,255,.09); }
.conference-message--own { margin-left: auto; border-radius: .75rem .75rem .2rem .75rem; background: var(--accent); }
.conference-message header { display: flex; justify-content: space-between; gap: 1rem; color: rgba(255,255,255,.62); font-size: .58rem; }
.conference-message p { margin: .25rem 0 0; font-size: .76rem; overflow-wrap: anywhere; }
.conference-chat__form { display: grid; grid-template-columns: 1fr auto; gap: .4rem; margin-top: .7rem; }
.conference-chat__form input { min-width: 0; padding: .65rem .7rem; border: 1px solid rgba(255,255,255,.12); border-radius: .7rem; background: rgba(255,255,255,.07); color: white; }
.conference-chat__form button { width: 2.5rem; border: 0; border-radius: .7rem; background: var(--accent); color: white; }
.conference-controls { position: sticky; z-index: 4; bottom: 0; display: flex; align-items: center; justify-content: center; gap: .6rem; padding: .8rem; border-top: 1px solid rgba(255,255,255,.09); background: rgba(12,15,23,.92); backdrop-filter: blur(14px); }
.conference-control { position: relative; display: grid; min-width: 4.8rem; min-height: 3.4rem; place-items: center; align-content: center; gap: .1rem; padding: .4rem .65rem; border: 0; border-radius: .85rem; background: rgba(255,255,255,.09); color: white; font-size: .68rem; }
.conference-control > span:first-child { font-size: 1rem; }
.conference-control:hover, .conference-control.is-active { background: rgba(255,255,255,.18); }
.conference-control.is-loading { pointer-events: none; opacity: .7; }
.conference-control.is-loading > span:first-child { animation: pulse 1s ease-in-out infinite; }
.conference-control.is-off { background: rgba(227,77,91,.25); color: #ffd9dd; }
.conference-control--danger { background: var(--danger); }
.conference-control--danger:hover { background: var(--danger-hover); }
.control-badge { position: absolute; top: -.25rem; right: -.2rem; }
.has-conference .call-bar, .has-conference .video-stage { display: none !important; }

@media (max-width: 900px) {
  .conference-join-card { grid-template-columns: 1fr; }
  .conference-preview-wrap { min-height: 300px; }
  .conference-room__body { grid-template-columns: 1fr; }
  .conference-side-panel { position: absolute; z-index: 5; top: 0; right: 0; bottom: 0; width: min(340px, 92vw); border-left: 1px solid rgba(255,255,255,.1); box-shadow: -20px 0 50px rgba(0,0,0,.35); transform: translateX(105%); transition: transform .18s ease; }
  .conference-side-panel.is-open { transform: translateX(0); }
}

@media (max-width: 640px) {
  .tabs { grid-template-columns: repeat(4, 1fr); }
  .tab { padding-inline: .35rem; }
  .tab span:not(.tab-badge) { font-size: .62rem; }
  .conference-hero { min-height: 160px; }
  .conference-hero__art { display: none; }
  .conference-join-card { padding: .7rem; }
  .conference-preview-wrap { min-height: 240px; }
  .conference-options { grid-template-columns: 1fr; }
  .conference-meeting-card { grid-template-columns: minmax(0, 1fr) auto; }
  .conference-meeting-card__meta { display: none; }
  .conference-panel { padding-top: 1rem; }
  .conference-room { height: calc(100dvh - 4.2rem); min-height: 0; border-radius: 0; }
  .conference-room__header { min-height: 4.7rem; padding: .7rem; }
  .conference-stage { padding: .35rem; gap: .35rem; }
  .conference-stage[data-layout="duo"] { grid-template-columns: 1fr; grid-template-rows: repeat(2, minmax(0, 1fr)); }
  .conference-stage[data-layout="trio"] { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(2, minmax(0, 1fr)); }
  .conference-stage[data-layout="trio"] > .is-primary { grid-column: 1 / -1; grid-row: auto; }
  .conference-stage[data-layout="five"] { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(3, minmax(0, 1fr)); }
  .conference-stage[data-layout="five"] > .is-primary { grid-column: 1 / -1; grid-row: auto; }
  .conference-stage[data-layout="six"],
  .conference-stage[data-layout="seven"],
  .conference-stage[data-layout="eight"],
  .conference-stage[data-layout="nine"],
  .conference-stage[data-layout="twelve"],
  .conference-stage[data-layout="sixteen"],
  .conference-stage[data-layout="dense"] {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-rows: minmax(0, 1fr);
  }
  .conference-filmstrip { grid-auto-columns: minmax(125px, 42vw); }
  .conference-controls { gap: .25rem; padding: .55rem .3rem; }
  .conference-control { min-width: 0; flex: 1; padding-inline: .2rem; font-size: .58rem; }
  .conference-side-panel { top: 4.7rem; bottom: 4.5rem; width: 100%; }
}
@media (min-width: 901px) {
  #conference-chat-button { display: none; }
}

/* --------------------------------------------------------------------------
   Réunions v9 : lobby sobre, test média compact et accès invité
   -------------------------------------------------------------------------- */
.conference-prejoin {
  display: grid;
  gap: 1rem;
}
.conference-page-header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1.25rem;
  padding: .2rem 0 .35rem;
}
.conference-page-header h1 {
  margin: .1rem 0 .25rem;
  font-size: clamp(1.8rem, 3vw, 2.65rem);
  letter-spacing: -.045em;
}
.conference-page-header p:last-child {
  max-width: 680px;
  margin: 0;
  color: var(--text-muted);
}
.conference-page-header__actions,
.conference-room__actions {
  display: flex;
  align-items: center;
  gap: .55rem;
  flex: 0 0 auto;
}
.conference-lobby-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(300px, .75fr);
  align-items: start;
  gap: 1rem;
}
.conference-catalog-card,
.conference-device-card,
.guest-meeting-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-small);
}
.conference-catalog-card {
  display: grid;
  min-height: 560px;
  gap: .8rem;
  padding: 1rem;
}
.conference-card-heading,
.conference-selected-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}
.conference-card-heading > div,
.conference-selected-heading > div {
  display: grid;
  min-width: 0;
  gap: .12rem;
}
.conference-card-heading strong,
.conference-selected-heading strong {
  overflow: hidden;
  font-size: .94rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.conference-card-heading small,
.conference-selected-heading small {
  color: var(--text-muted);
  font-size: .68rem;
}
.conference-meeting-list {
  max-height: min(54vh, 560px);
  align-content: start;
}
.conference-device-card {
  position: sticky;
  top: 5.5rem;
  display: grid;
  gap: .9rem;
  padding: 1rem;
}
.copy-link-button,
.preview-toggle {
  border: 1px solid var(--line);
  background: var(--surface-muted);
  color: var(--text);
}
.copy-link-button {
  display: grid;
  width: 2.25rem;
  height: 2.25rem;
  place-items: center;
  border-radius: .7rem;
  font-size: 1.05rem;
}
.copy-link-button:hover,
.preview-toggle:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--line));
  background: color-mix(in srgb, var(--accent) 8%, var(--surface));
}
.device-check-row {
  display: grid;
  grid-template-columns: 150px minmax(0, 1fr);
  align-items: stretch;
  gap: .75rem;
}
.compact-preview {
  position: relative;
  min-height: 108px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: .85rem;
  background: #0d1018;
  color: white;
}
.compact-preview video {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 108px;
  object-fit: cover;
  transform: scaleX(-1);
}
.compact-preview__placeholder {
  display: grid;
  min-height: 108px;
  place-items: center;
  align-content: center;
  gap: .3rem;
  padding: .75rem;
  color: rgba(255,255,255,.72);
  font-size: .68rem;
  text-align: center;
}
.compact-preview__placeholder .video-stage__avatar {
  width: 2.55rem;
  height: 2.55rem;
  font-size: .9rem;
}
.preview-toggle {
  position: absolute;
  right: .4rem;
  bottom: .4rem;
  padding: .28rem .48rem;
  border-color: rgba(255,255,255,.18);
  border-radius: .55rem;
  background: rgba(5,8,14,.72);
  color: white;
  font-size: .6rem;
  font-weight: 800;
  backdrop-filter: blur(8px);
}
.microphone-check {
  display: grid;
  align-content: center;
  gap: .65rem;
  min-width: 0;
  padding: .75rem;
  border: 1px solid var(--line);
  border-radius: .85rem;
  background: var(--surface-muted);
}
.microphone-check__heading {
  display: grid;
  gap: .18rem;
}
.microphone-check__heading strong {
  font-size: .78rem;
}
.microphone-check__heading span {
  color: var(--text-muted);
  font-size: .66rem;
  line-height: 1.35;
}
.audio-meter {
  height: .58rem;
  overflow: hidden;
  border-radius: 999px;
  background: color-mix(in srgb, var(--text-muted) 16%, transparent);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--text-muted) 10%, transparent);
}
.audio-meter > span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--success) 0 68%, var(--warning) 84%, var(--danger) 100%);
  transform-origin: left center;
  transition: width 80ms linear;
}
.microphone-check.is-heard {
  border-color: color-mix(in srgb, var(--success) 50%, var(--line));
}
.microphone-check.is-silent,
.microphone-check.is-error {
  border-color: color-mix(in srgb, var(--danger) 48%, var(--line));
}
.meeting-flags {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
}
.meeting-flags span,
.conference-meeting-card__meta span {
  display: inline-flex;
  align-items: center;
  min-height: 1.4rem;
  padding: .2rem .45rem;
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--text-muted);
  font-size: .58rem;
  font-weight: 850;
}

.guest-layout {
  min-height: 100vh;
  padding: clamp(1rem, 3vw, 2.5rem);
  background:
    radial-gradient(circle at 10% 10%, color-mix(in srgb, var(--accent) 12%, transparent), transparent 32%),
    var(--bg);
}
.guest-lobby {
  width: min(980px, 100%);
  margin: 0 auto;
}
.guest-lobby__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1rem;
}
.guest-meeting-card {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 440px);
  gap: clamp(1.25rem, 4vw, 3.5rem);
  padding: clamp(1.25rem, 4vw, 3rem);
}
.guest-meeting-card__copy {
  align-self: center;
}
.guest-meeting-card__copy h1 {
  margin: .15rem 0 .7rem;
  font-size: clamp(2rem, 5vw, 4rem);
  letter-spacing: -.055em;
}
.guest-meeting-card__copy > p:not(.eyebrow) {
  max-width: 560px;
  color: var(--text-muted);
  line-height: 1.6;
}
.guest-device-check {
  display: grid;
  gap: .85rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface-muted);
}
.guest-device-check .compact-preview {
  aspect-ratio: 16 / 9;
}
.guest-security-note {
  max-width: 680px;
  margin: 1rem auto 0;
  color: var(--text-muted);
  font-size: .7rem;
  text-align: center;
}
.is-guest-session .topbar,
.is-guest-session .tabs {
  display: none;
}
.is-guest-session .workspace {
  width: 100%;
  max-width: none;
  padding: 0;
}
.is-guest-session #tab-conference {
  padding: 0;
}

.conference-create-dialog {
  width: min(560px, calc(100vw - 1rem));
}
.dialog-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.dialog-heading h2 {
  margin: .1rem 0 0;
}
.meeting-type-picker {
  display: grid;
  gap: .55rem;
  margin: 0;
  padding: 0;
  border: 0;
}
.meeting-type-picker legend {
  margin-bottom: .45rem;
  font-size: .75rem;
  font-weight: 850;
}
.meeting-type-picker label {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: .65rem;
  padding: .75rem;
  border: 1px solid var(--line);
  border-radius: .8rem;
  background: var(--surface-muted);
  cursor: pointer;
}
.meeting-type-picker label:has(input:checked) {
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px var(--accent);
}
.meeting-type-picker label > span {
  display: grid;
  gap: .12rem;
}
.meeting-type-picker small {
  color: var(--text-muted);
  font-size: .68rem;
  line-height: 1.4;
}
.meeting-authorization-control {
  border: 1px solid var(--line);
  border-radius: .8rem;
  padding: .75rem;
  background: var(--surface-muted);
}

@media (max-width: 980px) {
  .conference-lobby-grid,
  .guest-meeting-card {
    grid-template-columns: 1fr;
  }
  .conference-device-card {
    position: static;
  }
  .conference-catalog-card {
    min-height: auto;
  }
  .conference-meeting-list {
    max-height: 420px;
  }
}

@media (max-width: 640px) {
  .conference-page-header,
  .guest-lobby__header {
    align-items: stretch;
    flex-direction: column;
  }
  .conference-page-header__actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .device-check-row {
    grid-template-columns: 120px minmax(0, 1fr);
  }
  .guest-meeting-card {
    padding: 1rem;
  }
}

@media (max-width: 460px) {
  .device-check-row {
    grid-template-columns: 1fr;
  }
  .compact-preview,
  .compact-preview video,
  .compact-preview__placeholder {
    min-height: 170px;
  }
}

.meeting-guest-note {
  display: grid;
  gap: .2rem;
  padding: .8rem .9rem;
  border: 1px solid var(--line);
  border-radius: .85rem;
  background: var(--surface-muted);
}
.meeting-guest-note strong { font-size: .8rem; }
.meeting-guest-note small { color: var(--text-muted); font-size: .7rem; line-height: 1.45; }

/* OVEA_V10_THEME_START */
/* OVEA v10 — identité cyan / vert, formes organiques et interface chaleureuse */
html,
body {
  background:
    radial-gradient(circle at 8% 12%, color-mix(in srgb, var(--brand-lime) 13%, transparent), transparent 28rem),
    radial-gradient(circle at 92% 5%, color-mix(in srgb, var(--brand-cyan) 10%, transparent), transparent 30rem),
    var(--bg);
}

::selection {
  background: color-mix(in srgb, var(--brand-lime) 45%, white);
  color: var(--brand-ink);
}

.eyebrow { color: #24883c; }

.brand__mark {
  width: auto;
  min-width: 4.6rem;
  height: 2.55rem;
  padding: 0 .78rem;
  border-radius: 1.2rem 1.2rem .45rem 1.2rem;
  background: var(--brand-gradient);
  color: var(--brand-ink);
  font-size: .94rem;
  font-weight: 950;
  letter-spacing: -.045em;
  text-transform: lowercase;
  box-shadow: 0 9px 24px rgba(24, 185, 196, .18);
}
.brand--large .brand__mark {
  width: auto;
  min-width: 5.6rem;
  height: 3.1rem;
  padding-inline: .9rem;
  font-size: 1.1rem;
}
.brand strong { letter-spacing: -.02em; }

.splash-screen {
  overflow: hidden;
  background:
    radial-gradient(circle at 20% 20%, color-mix(in srgb, var(--brand-lime) 28%, transparent), transparent 24rem),
    radial-gradient(circle at 82% 22%, color-mix(in srgb, var(--brand-cyan) 22%, transparent), transparent 27rem),
    #f8faf6;
}
.splash-screen::before,
.splash-screen::after {
  position: absolute;
  width: 28rem;
  aspect-ratio: 1;
  border-radius: 46% 54% 67% 33% / 46% 38% 62% 54%;
  content: "";
  filter: blur(1px);
  opacity: .15;
  pointer-events: none;
}
.splash-screen::before {
  top: -13rem;
  left: -9rem;
  background: var(--brand-lime);
  transform: rotate(24deg);
}
.splash-screen::after {
  right: -12rem;
  bottom: -17rem;
  background: var(--brand-cyan);
  transform: rotate(-18deg);
}
.splash-screen__content { position: relative; z-index: 1; }
.splash-logo {
  width: 8.4rem;
  height: 5.4rem;
  border-radius: 2.4rem 2.4rem .85rem 2.4rem;
  background: var(--brand-gradient);
  color: var(--brand-ink);
  font-size: 1.85rem;
  letter-spacing: -.065em;
  box-shadow: 0 25px 65px rgba(24, 185, 196, .24);
}
.splash-logo i {
  border-color: color-mix(in srgb, var(--brand-cyan) 34%, transparent);
  border-radius: 2.7rem 2.7rem 1.1rem 2.7rem;
}
.splash-progress span { background: var(--brand-gradient); }

.login-layout { background: #fff; }
.login-panel { position: relative; z-index: 1; }
.login-panel::before {
  position: absolute;
  z-index: -1;
  top: 9%;
  left: -12rem;
  width: 18rem;
  aspect-ratio: 1;
  border-radius: 54% 46% 32% 68% / 42% 62% 38% 58%;
  background: color-mix(in srgb, var(--brand-lime) 13%, transparent);
  content: "";
  transform: rotate(18deg);
}
.login-copy h1 { color: var(--brand-ink); }
.login-visual {
  background:
    radial-gradient(circle at 24% 18%, rgba(255,255,255,.42), transparent 21%),
    linear-gradient(145deg, #18b9c4 0%, #70d282 45%, #c5e52b 100%);
}
.login-visual::before,
.login-visual::after {
  position: absolute;
  content: "";
  border-radius: 45% 55% 66% 34% / 55% 42% 58% 45%;
  background: rgba(255,255,255,.15);
}
.login-visual::before { top: -18%; right: -18%; width: 60%; aspect-ratio: 1; }
.login-visual::after { bottom: -24%; left: -16%; width: 68%; aspect-ratio: 1; transform: rotate(38deg); }
.visual-orbit { border-color: rgba(16, 22, 21, .15); }
.visual-phone {
  border-color: rgba(255,255,255,.52);
  background: rgba(255,255,255,.25);
  box-shadow: 0 40px 100px rgba(21, 52, 40, .23);
}
.visual-phone__dot { background: rgba(255,255,255,.96); }
.visual-phone__line { background: rgba(16, 22, 21, .18); }

.button--primary,
.primary-button {
  background: var(--brand-gradient);
  color: var(--brand-ink);
  box-shadow: 0 13px 30px rgba(115, 198, 59, .22);
}
.button--primary:hover,
.primary-button:hover {
  background: linear-gradient(120deg, #11a9b4, #b2d51e);
  color: var(--brand-ink);
}
.button__spinner { border-color: rgba(16,22,21,.25); border-top-color: var(--brand-ink); }
.secondary-button,
.icon-button,
.copy-link-button,
.preview-toggle { border-color: var(--line); background: rgba(255,255,255,.88); }
.secondary-button:hover,
.icon-button:hover,
.copy-link-button:hover,
.preview-toggle:hover {
  border-color: color-mix(in srgb, var(--brand-cyan) 45%, var(--line));
  background: color-mix(in srgb, var(--brand-lime) 10%, white);
}

.topbar {
  border-bottom-color: color-mix(in srgb, var(--line) 70%, transparent);
  background: color-mix(in srgb, #f8faf6 91%, transparent);
}
.tabs { border-color: color-mix(in srgb, var(--line) 82%, transparent); background: rgba(255,255,255,.92); }
.tab.is-active { background: color-mix(in srgb, var(--brand-lime) 22%, white); color: var(--brand-ink); }
.presence-pill { background: rgba(255,255,255,.94); }
.presence-menu { border-top: 4px solid var(--brand-lime); }

.dialer-card,
.quick-panel,
.contact-row,
.history-row,
.conference-catalog-card,
.conference-device-card,
.guest-meeting-card,
.settings-sheet,
.conference-create-dialog {
  border-color: color-mix(in srgb, var(--line) 85%, transparent);
  box-shadow: var(--shadow-small);
}
.dialer-card,
.quick-panel,
.conference-catalog-card,
.conference-device-card {
  background: linear-gradient(160deg, rgba(255,255,255,.99), rgba(248,251,246,.99));
}
.dialpad button:hover,
.phone-chip:hover {
  border-color: color-mix(in srgb, var(--brand-cyan) 45%, var(--line));
  background: color-mix(in srgb, var(--brand-lime) 12%, white);
}
.call-button { background: var(--brand-ink); }
.call-button--video,
.round-button--video { background: var(--brand-cyan); }
.round-button--accept,
.visual-phone__call { background: var(--brand-green); }

.conference-page-header {
  position: relative;
  overflow: hidden;
  padding: 1.2rem 1.35rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 92% 0%, color-mix(in srgb, var(--brand-cyan) 20%, transparent), transparent 18rem),
    linear-gradient(135deg, #fff, #f1f8e9);
}
.conference-page-header::after {
  position: absolute;
  right: -4rem;
  bottom: -6rem;
  width: 14rem;
  aspect-ratio: 1;
  border-radius: 65% 35% 56% 44% / 45% 58% 42% 55%;
  background: color-mix(in srgb, var(--brand-lime) 24%, transparent);
  content: "";
  pointer-events: none;
}
.conference-page-header > * { position: relative; z-index: 1; }
.conference-meeting-card.is-selected {
  border-color: var(--brand-green);
  background: linear-gradient(135deg, color-mix(in srgb, var(--brand-lime) 16%, white), color-mix(in srgb, var(--brand-cyan) 7%, white));
  box-shadow: inset 0 0 0 1px var(--brand-green);
}
.conference-meeting-card__check { background: var(--brand-gradient); color: var(--brand-ink); }
.audio-meter > span {
  background: linear-gradient(90deg, var(--brand-cyan) 0 30%, var(--brand-green) 58%, var(--brand-lime) 76%, var(--warning) 90%, var(--danger) 100%);
}
.microphone-check.is-heard {
  border-color: var(--brand-green);
  background: color-mix(in srgb, var(--brand-lime) 8%, var(--surface-muted));
}
.meeting-type-picker input:checked + span {
  border-color: var(--brand-cyan);
  background: color-mix(in srgb, var(--brand-cyan) 8%, white);
  box-shadow: inset 0 0 0 1px var(--brand-cyan);
}

.guest-layout {
  background:
    radial-gradient(circle at 8% 10%, color-mix(in srgb, var(--brand-lime) 24%, transparent), transparent 28rem),
    radial-gradient(circle at 94% 8%, color-mix(in srgb, var(--brand-cyan) 18%, transparent), transparent 30rem),
    var(--bg);
}
.guest-meeting-card {
  overflow: hidden;
  background: linear-gradient(145deg, #fff 0%, #fff 66%, color-mix(in srgb, var(--brand-lime) 8%, white) 100%);
}

.settings-dialog::backdrop,
.conference-create-dialog::backdrop { background: rgba(14,24,20,.52); backdrop-filter: blur(7px); }

::-webkit-scrollbar { width: .7rem; height: .7rem; }
::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: color-mix(in srgb, var(--brand-cyan) 38%, var(--line));
  background-clip: padding-box;
}

@media (max-width: 760px) {
  .brand > div span { max-width: 11rem; }
  .conference-page-header { padding: 1rem; }
}
/* OVEA_V10_THEME_END */


/* --------------------------------------------------------------------------
   Logo OVEA officiel — fichier assets/images/logo.svg
   -------------------------------------------------------------------------- */
.brand {
  align-items: center;
}

.brand__logo {
  display: block;
  width: 5.4rem;
  height: auto;
  max-height: 2.55rem;
  flex: 0 0 auto;
  object-fit: contain;
  object-position: left center;
}

.brand--large .brand__logo {
  width: 7.4rem;
  max-height: 3.5rem;
}

.splash-logo {
  display: grid;
  width: min(15rem, 64vw);
  height: auto;
  min-height: 4.5rem;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.splash-logo img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 6rem;
  object-fit: contain;
}

.splash-logo i {
  display: none;
}

@media (max-width: 760px) {
  .brand__logo {
    width: 4.7rem;
    max-height: 2.25rem;
  }

  .brand--large .brand__logo {
    width: 6.6rem;
    max-height: 3.1rem;
  }

  .splash-logo {
    width: min(12rem, 68vw);
  }
}

/* --------------------------------------------------------------------------
   Enregistrement local des appels et conférences
   -------------------------------------------------------------------------- */
.round-button--record {
  position: relative;
}
.record-button__dot {
  display: block;
  width: .85rem;
  height: .85rem;
  border-radius: 50%;
  background: #ff6b75;
  box-shadow: 0 0 0 3px rgba(255,107,117,.13);
}
.round-button--record.is-recording {
  background: #d93f4b;
  box-shadow: 0 0 0 4px rgba(217,63,75,.22);
}
.round-button--record.is-recording .record-button__dot {
  border-radius: .18rem;
  background: #fff;
  animation: recording-pulse 1.4s ease-in-out infinite;
}

.conference-control--record .conference-record-dot {
  color: #ff7a83;
}
.conference-control--record.is-recording {
  background: rgba(223,77,87,.34);
  color: #fff;
}
.conference-control--record.is-recording .conference-record-dot {
  color: #ff5e69;
  animation: recording-pulse 1.4s ease-in-out infinite;
}

.settings-section__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.settings-section__heading h3 {
  margin-bottom: .25rem;
}
.settings-section__heading p {
  max-width: 34rem;
  margin: 0;
}
.recording-list {
  display: grid;
  gap: .55rem;
  margin-top: .8rem;
}
.recording-empty {
  padding: .9rem;
  border: 1px dashed var(--line);
  border-radius: .8rem;
  color: var(--text-muted);
  background: var(--surface-muted);
  font-size: .82rem;
  text-align: center;
}
.recording-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .9rem;
  padding: .8rem;
  border: 1px solid var(--line);
  border-radius: .85rem;
  background: var(--surface-muted);
}
.recording-row__details {
  display: grid;
  min-width: 0;
  gap: .15rem;
}
.recording-row__details strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: .84rem;
}
.recording-row__details span {
  color: var(--text-muted);
  font-size: .7rem;
}
.recording-row__actions {
  display: flex;
  flex: 0 0 auto;
  gap: .4rem;
}
.secondary-button--compact {
  min-height: 2rem;
  padding: .38rem .58rem;
  font-size: .7rem;
}
.recording-delete {
  color: var(--danger);
}

@keyframes recording-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: .55; transform: scale(.88); }
}

@media (max-width: 640px) {
  .recording-row,
  .settings-section__heading {
    align-items: stretch;
    flex-direction: column;
  }
  .recording-row__actions {
    width: 100%;
  }
  .recording-row__actions button {
    flex: 1;
  }
}


/* v11.4.1 — détail explicite des trois pistes d’enregistrement */
.recording-file-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .4rem;
  margin-top: .55rem;
}
.recording-file {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  padding: .48rem;
  border: 1px solid var(--line);
  border-radius: .7rem;
  background: var(--surface);
}
.recording-file__copy {
  display: grid;
  min-width: 0;
  gap: .08rem;
}
.recording-file__copy strong,
.recording-file__copy small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.recording-file__copy strong {
  font-size: .7rem;
}
.recording-file__copy small {
  color: var(--text-muted);
  font-size: .62rem;
}
.recording-file--local { border-left: 3px solid var(--brand-cyan); }
.recording-file--remote { border-left: 3px solid var(--brand-green); }
.recording-file--mixed { border-left: 3px solid var(--brand-lime); }

@media (max-width: 820px) {
  .recording-file-list {
    grid-template-columns: 1fr;
  }
}


/* --------------------------------------------------------------------------
   Transcription temps réel Speaches
   -------------------------------------------------------------------------- */
.transcription-panel {
  position: fixed;
  z-index: 82;
  right: 1.15rem;
  bottom: calc(1.15rem + var(--safe-bottom));
  display: grid;
  width: min(34rem, calc(100vw - 2rem));
  max-height: min(72vh, 42rem);
  grid-template-rows: auto minmax(7rem, 1fr) auto;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--brand-cyan) 30%, var(--line));
  border-radius: 1.2rem;
  background: rgba(255, 255, 255, .97);
  box-shadow: 0 28px 78px rgba(18, 34, 28, .22);
  backdrop-filter: blur(18px);
}

.transcription-panel.is-dragging {
  user-select: none;
  box-shadow: 0 36px 96px rgba(18, 34, 28, .30);
}

.transcription-panel.is-minimized {
  grid-template-rows: auto;
  width: min(24rem, calc(100vw - 2rem));
}

.transcription-panel.is-minimized .transcription-panel__body,
.transcription-panel.is-minimized .transcription-panel__footer {
  display: none;
}

.transcription-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  min-height: 3.6rem;
  padding: .72rem .78rem .72rem 1rem;
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(
      120deg,
      color-mix(in srgb, var(--brand-cyan) 10%, white),
      color-mix(in srgb, var(--brand-lime) 12%, white)
    );
  cursor: grab;
  touch-action: none;
}

.transcription-panel.is-dragging .transcription-panel__header {
  cursor: grabbing;
}

.transcription-panel__heading {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: .7rem;
}

.transcription-panel__heading > div {
  display: grid;
  min-width: 0;
  gap: .08rem;
}

.transcription-panel__heading strong,
.transcription-panel__heading small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.transcription-panel__heading strong {
  font-size: .86rem;
}

.transcription-panel__heading small {
  color: var(--text-muted);
  font-size: .68rem;
}

.transcription-status-dot {
  width: .68rem;
  height: .68rem;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--text-muted);
}

.transcription-status-dot--connecting,
.transcription-status-dot--transcribing,
.transcription-status-dot--finalizing {
  background: var(--warning);
  animation: pulse 1.2s ease-in-out infinite;
}

.transcription-status-dot--listening {
  background: var(--success);
}

.transcription-panel.is-speaking .transcription-status-dot--listening {
  box-shadow: 0 0 0 .36rem color-mix(in srgb, var(--success) 18%, transparent);
}

.transcription-status-dot--completed {
  background: var(--brand-cyan);
}

.transcription-status-dot--error {
  background: var(--danger);
}

.transcription-panel__controls {
  display: flex;
  align-items: center;
  gap: .3rem;
}

.transcription-panel__button {
  display: grid;
  width: 2rem;
  height: 2rem;
  place-items: center;
  border: 0;
  border-radius: .62rem;
  background: rgba(255, 255, 255, .68);
  color: var(--text);
  font-size: 1.15rem;
  line-height: 1;
}

.transcription-panel__button:hover {
  background: white;
}

.transcription-panel__body {
  min-height: 0;
  overflow: auto;
  padding: .72rem .78rem .9rem;
  overscroll-behavior: contain;
  scroll-behavior: smooth;
}

.transcription-empty {
  display: grid;
  min-height: 7rem;
  place-items: center;
  color: var(--text-muted);
  text-align: center;
  font-size: .82rem;
  line-height: 1.55;
}

.transcription-content,
.transcription-partials {
  display: flex;
  flex-direction: column;
  gap: .22rem;
}

.transcription-partials:not([hidden]) {
  margin-top: .22rem;
}

.transcription-turn {
  display: grid;
  grid-template-columns: 6.7rem minmax(0, 1fr);
  align-items: start;
  gap: .48rem;
  padding: .28rem .42rem;
  border-radius: .58rem;
}

.transcription-turn--local {
  background: color-mix(in srgb, var(--brand-lime) 10%, transparent);
}

.transcription-turn--remote {
  background: color-mix(in srgb, var(--brand-cyan) 9%, transparent);
}

.transcription-turn--partial {
  opacity: .72;
}

.transcription-speaker {
  overflow: hidden;
  padding-top: .12rem;
  font-size: .66rem;
  font-weight: 850;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.transcription-turn--local .transcription-speaker {
  color: color-mix(in srgb, var(--brand-lime) 60%, #24352e);
}

.transcription-turn--remote .transcription-speaker {
  color: color-mix(in srgb, var(--brand-cyan) 72%, #183b42);
}

.transcription-segment {
  margin: 0;
  color: var(--text);
  font-size: .86rem;
  line-height: 1.38;
  white-space: pre-wrap;
}

.transcription-segment--partial {
  color: var(--text-muted);
  font-style: italic;
}

.transcription-segment--partial::after {
  display: inline-block;
  width: .36rem;
  height: .82em;
  margin-left: .18rem;
  border-radius: 2px;
  background: var(--brand-cyan);
  content: "";
  vertical-align: -.1em;
  animation: pulse 1s ease-in-out infinite;
}

.transcription-error {
  margin: .55rem 0 0;
  padding: .7rem .8rem;
  border-radius: .75rem;
  background: var(--danger-soft);
  color: var(--danger);
  font-size: .76rem;
  line-height: 1.45;
}

.transcription-panel__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  padding: .65rem .78rem .7rem 1rem;
  border-top: 1px solid var(--line);
  background: var(--surface-muted);
}

.transcription-panel__footer > span {
  overflow: hidden;
  color: var(--text-muted);
  font-size: .64rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.transcription-reopen {
  position: fixed;
  z-index: 81;
  right: 1.15rem;
  bottom: calc(1.15rem + var(--safe-bottom));
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  min-height: 2.65rem;
  padding: .5rem .8rem;
  border: 1px solid color-mix(in srgb, var(--brand-cyan) 38%, var(--line));
  border-radius: 999px;
  background: white;
  color: var(--text);
  font-size: .74rem;
  font-weight: 800;
  box-shadow: var(--shadow);
}

.transcription-reopen:hover {
  background: color-mix(in srgb, var(--brand-lime) 10%, white);
}

@media (max-width: 640px) {
  .transcription-panel {
    right: .5rem !important;
    bottom: calc(.5rem + var(--safe-bottom)) !important;
    left: .5rem !important;
    top: auto !important;
    width: auto;
    max-height: 64vh;
  }

  .transcription-panel.is-minimized {
    width: auto;
  }

  .transcription-panel__header {
    cursor: default;
  }

  .transcription-reopen {
    right: .65rem;
    bottom: calc(.65rem + var(--safe-bottom));
  }
}


.transcription-error.is-warning {
  background: color-mix(in srgb, var(--warning) 12%, white);
  color: color-mix(in srgb, var(--warning) 72%, #4b3511);
}

@media (max-width: 520px) {
  .transcription-turn {
    grid-template-columns: 5.4rem minmax(0, 1fr);
    gap: .38rem;
    padding-inline: .34rem;
  }
}

/* --------------------------------------------------------------------------
   V12 — Transcription multi-participants et tuile virtuelle de conférence
   -------------------------------------------------------------------------- */
.transcription-content,
.transcription-partials {
  gap: .08rem;
}

.transcription-partials:not([hidden]) {
  margin-top: .08rem;
}

.transcription-turn {
  grid-template-columns: minmax(5.4rem, 7.2rem) minmax(0, 1fr);
  gap: .38rem;
  padding: .16rem .34rem;
  border-radius: .45rem;
}

.transcription-speaker {
  padding-top: .08rem;
  font-size: .63rem;
  line-height: 1.18;
}

.transcription-segment {
  font-size: .84rem;
  line-height: 1.3;
}

.conference-transcript-tile {
  display: grid;
  grid-template-rows: auto minmax(0, 1fr) auto;
  border-color: rgba(37, 191, 201, .38);
  background:
    radial-gradient(circle at 100% 0%, rgba(37, 191, 201, .13), transparent 45%),
    linear-gradient(160deg, #101722, #0b111a 72%);
  color: #f4f8f7;
}

.conference-transcript-tile__header,
.conference-transcript-tile__footer {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .55rem;
  background: rgba(9, 15, 22, .88);
}

.conference-transcript-tile__header {
  padding: .48rem .55rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
}

.conference-transcript-tile__identity {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: .48rem;
}

.conference-transcript-tile__identity > div {
  display: grid;
  min-width: 0;
  gap: .02rem;
}

.conference-transcript-tile__identity strong,
.conference-transcript-tile__identity small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.conference-transcript-tile__identity strong {
  font-size: clamp(.66rem, .85vw, .78rem);
}

.conference-transcript-tile__identity small {
  color: rgba(255,255,255,.52);
  font-size: clamp(.52rem, .7vw, .62rem);
}

.conference-transcript-tile__live {
  width: .58rem;
  height: .58rem;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #ff5f68;
  box-shadow: 0 0 0 .22rem rgba(255,95,104,.13);
  animation: recording-pulse 1.4s ease-in-out infinite;
}

.conference-transcript-tile__fullscreen {
  display: grid;
  width: 1.8rem;
  height: 1.8rem;
  flex: 0 0 auto;
  place-items: center;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: .48rem;
  background: rgba(255,255,255,.08);
  color: white;
  font-size: .9rem;
  cursor: pointer;
}

.conference-transcript-tile__fullscreen:hover {
  background: rgba(255,255,255,.16);
}

.conference-transcript-tile__body {
  min-height: 0;
  overflow: auto;
  padding: .38rem .48rem .5rem;
  overscroll-behavior: contain;
  scrollbar-width: thin;
}

.conference-transcript-tile__turn {
  display: grid;
  grid-template-columns: minmax(4.4rem, 6.6rem) minmax(0, 1fr);
  gap: .4rem;
  padding: .18rem .18rem;
  border-bottom: 1px solid rgba(255,255,255,.045);
}

.conference-transcript-tile__turn strong {
  overflow: hidden;
  color: #9edfe4;
  font-size: clamp(.54rem, .72vw, .66rem);
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.conference-transcript-tile__turn p {
  margin: 0;
  color: rgba(255,255,255,.92);
  font-size: clamp(.61rem, .8vw, .76rem);
  line-height: 1.32;
  overflow-wrap: anywhere;
}

.conference-transcript-tile__empty,
.conference-transcript-tile__previous {
  margin: 0;
  padding: .55rem .4rem;
  color: rgba(255,255,255,.48);
  font-size: .62rem;
  line-height: 1.4;
  text-align: center;
}

.conference-transcript-tile__previous {
  padding: .25rem .4rem .4rem;
  font-style: italic;
}

.conference-transcript-tile__footer {
  justify-content: flex-start;
  padding: .32rem .55rem;
  border-top: 1px solid rgba(255,255,255,.07);
  color: rgba(255,255,255,.38);
  font-size: .52rem;
}

.conference-filmstrip .conference-transcript-tile__turn {
  grid-template-columns: 1fr;
  gap: .08rem;
}

.conference-filmstrip .conference-transcript-tile__turn strong {
  font-size: .54rem;
}

.conference-transcript-tile:fullscreen {
  width: 100vw;
  height: 100vh;
  border: 0;
  border-radius: 0;
  background: #0b111a;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__header {
  padding: 1rem 1.25rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__identity strong {
  font-size: 1rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__identity small {
  font-size: .76rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__body {
  width: min(78rem, 100%);
  margin: 0 auto;
  padding: 1.1rem 1.5rem 2rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__turn {
  grid-template-columns: minmax(9rem, 13rem) minmax(0, 1fr);
  gap: 1rem;
  padding: .42rem .25rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__turn strong {
  font-size: .82rem;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__turn p {
  font-size: 1.04rem;
  line-height: 1.45;
}

.conference-transcript-tile:fullscreen .conference-transcript-tile__footer {
  padding: .55rem 1.25rem;
  font-size: .66rem;
}

@media (max-width: 640px) {
  .conference-transcript-tile__turn,
  .conference-transcript-tile:fullscreen .conference-transcript-tile__turn {
    grid-template-columns: 1fr;
    gap: .08rem;
  }
}

/* Contexte client des appels entrants */
.caller-dashboard {
  position: fixed;
  z-index: 34;
  right: max(1rem, calc((100vw - 1180px) / 2));
  bottom: calc(6.4rem + var(--safe-bottom));
  left: max(1rem, calc((100vw - 1180px) / 2));
  display: grid;
  max-height: min(43vh, 360px);
  gap: .9rem;
  overflow: auto;
  padding: 1rem 1.1rem;
  border: 1px solid color-mix(in srgb, var(--brand-cyan) 24%, var(--line));
  border-radius: 1.35rem;
  background: color-mix(in srgb, var(--surface) 96%, transparent);
  box-shadow: 0 22px 60px rgba(23, 39, 30, .18);
  backdrop-filter: blur(18px);
}
.caller-dashboard__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.caller-dashboard__header .eyebrow { margin-bottom: .18rem; color: var(--brand-cyan); }
.caller-dashboard__header h2 { margin: 0; font-size: clamp(1.15rem, 2.5vw, 1.55rem); letter-spacing: -.025em; }
.caller-dashboard__subtitle { margin: .2rem 0 0; color: var(--text-muted); font-size: .8rem; }
.caller-dashboard__number {
  flex: 0 0 auto;
  padding: .42rem .68rem;
  border-radius: 999px;
  background: var(--surface-muted);
  color: var(--text-muted);
  font-size: .78rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.caller-dashboard__status {
  padding: .8rem .9rem;
  border: 1px solid var(--line);
  border-radius: .9rem;
  background: var(--surface-muted);
  color: var(--text-muted);
  font-size: .85rem;
}
.caller-dashboard__status--loading { animation: pulse 1.5s ease-in-out infinite; }
.caller-dashboard__status--error { border-color: color-mix(in srgb, var(--danger) 35%, var(--line)); background: var(--danger-soft); color: var(--danger); }
.caller-dashboard:has(.caller-dashboard__status--error) .caller-identities:not(:empty) {
  padding-top: .15rem;
  border-top: 1px dashed color-mix(in srgb, var(--warning) 42%, var(--line));
}
.caller-dashboard:has(.caller-dashboard__status--error) .caller-identity {
  opacity: .94;
}

.caller-dashboard__content { min-height: 0; }
.caller-identities { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: .75rem; }
.caller-identity {
  --caller-identity-accent: var(--brand-cyan);
  position: relative;
  display: grid;
  min-width: 0;
  gap: .7rem;
  padding: .85rem .9rem .8rem 1rem;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--caller-identity-accent) 28%, var(--line));
  border-radius: 1rem;
  background: linear-gradient(120deg, color-mix(in srgb, var(--caller-identity-accent) 9%, var(--surface)), var(--surface) 58%);
}
.caller-identity::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: .28rem;
  background: var(--caller-identity-accent);
  content: "";
}
.caller-identity--variant-1 { --caller-identity-accent: var(--brand-cyan); }
.caller-identity--variant-2 { --caller-identity-accent: var(--warning); }
.caller-identity--variant-3 { --caller-identity-accent: var(--brand-green); }
.caller-identity--variant-4 { --caller-identity-accent: #936fe0; }
.caller-identity__heading { display: grid; gap: .12rem; }
.caller-identity__heading strong { overflow: hidden; font-size: 1.04rem; text-overflow: ellipsis; white-space: nowrap; }
.caller-identity__label { color: var(--caller-identity-accent); font-size: .67rem; font-weight: 900; letter-spacing: .08em; text-transform: uppercase; }
.caller-identity__accounts { display: flex; flex-wrap: wrap; gap: .42rem; }
.caller-account {
  display: inline-flex;
  min-height: 2rem;
  align-items: center;
  gap: .38rem;
  padding: .35rem .62rem;
  border: 1px solid var(--line);
  border-radius: .72rem;
  background: var(--surface);
  color: var(--text);
  font-size: .78rem;
  font-weight: 750;
  text-align: left;
}
.caller-account:hover { border-color: color-mix(in srgb, var(--caller-identity-accent) 55%, var(--line)); }
.caller-account.is-selected {
  border-color: color-mix(in srgb, var(--caller-identity-accent) 58%, var(--line));
  background: color-mix(in srgb, var(--caller-identity-accent) 13%, var(--surface));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--caller-identity-accent) 16%, transparent);
}
.caller-account__marker { color: var(--caller-identity-accent); font-size: .6rem; }
.caller-account--empty { cursor: default; color: var(--text-muted); }
.caller-identity__meta { overflow: hidden; color: var(--text-muted); font-size: .7rem; text-overflow: ellipsis; white-space: nowrap; }
.caller-workspace {
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.15rem;
  background: var(--surface-muted);
}
.caller-workspace__heading { display: grid; gap: .15rem; padding: 1rem 1.1rem; border-bottom: 1px solid var(--line); background: var(--surface); }
.caller-workspace__heading span { color: var(--text-muted); font-size: .69rem; font-weight: 850; letter-spacing: .08em; text-transform: uppercase; }
.caller-workspace__heading strong { font-size: 1.08rem; }
.caller-workspace__placeholder {
  display: grid;
  min-height: 260px;
  place-items: center;
  align-content: center;
  gap: 1rem;
  padding: 2rem;
  color: var(--text-muted);
  text-align: center;
}
.caller-workspace__placeholder > div { max-width: 470px; }
.caller-workspace__placeholder strong { display: block; margin-bottom: .35rem; color: var(--text); font-size: 1.05rem; }
.caller-workspace__placeholder p { margin: 0; line-height: 1.55; }
.caller-workspace__icon { display: grid; width: 3rem; height: 3rem; place-items: center; border-radius: 1rem; background: var(--surface); color: var(--brand-cyan); font-size: 1.35rem; box-shadow: var(--shadow-small); }

.caller-dashboard[data-mode="active"] {
  top: 5.7rem;
  bottom: calc(6.2rem + var(--safe-bottom));
  max-height: none;
  padding: 1.25rem;
}
.caller-dashboard[data-mode="active"] .caller-dashboard__content {
  display: grid;
  min-height: 0;
  flex: 1;
  grid-template-columns: minmax(280px, .72fr) minmax(0, 1.55fr);
  gap: 1rem;
}
.caller-dashboard[data-mode="active"] .caller-identities {
  align-content: start;
  overflow: auto;
  grid-template-columns: 1fr;
}
.caller-dashboard[data-mode="active"] .caller-workspace { display: block; min-height: 0; overflow: auto; }
.caller-dashboard[data-mode="active"] .caller-workspace__placeholder { min-height: 100%; }

@media (max-width: 760px) {
  .caller-dashboard {
    right: .5rem;
    bottom: calc(10.3rem + var(--safe-bottom));
    left: .5rem;
    max-height: 38vh;
    padding: .85rem;
    border-radius: 1rem;
  }
  .caller-dashboard__header { align-items: stretch; flex-direction: column; gap: .55rem; }
  .caller-dashboard__number { align-self: flex-start; }
  .caller-dashboard[data-mode="active"] {
    top: 4.5rem;
    bottom: calc(10.2rem + var(--safe-bottom));
    max-height: none;
  }
  .caller-dashboard[data-mode="active"] .caller-dashboard__content { grid-template-columns: 1fr; overflow: auto; }
  .caller-dashboard[data-mode="active"] .caller-identities { overflow: visible; }
  .caller-dashboard[data-mode="active"] .caller-workspace { min-height: 280px; }
}

/* --------------------------------------------------------------------------
   Archives rapides et synthèses de transcription
   -------------------------------------------------------------------------- */
.recording-quick-actions {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding-right: .15rem;
}
.recording-quick-actions[hidden] { display: none; }
.primary-button--compact {
  min-height: 2rem;
  padding: .38rem .68rem;
  font-size: .7rem;
}
.transcription-panel__footer-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: .4rem;
}

.call-summary-dialog {
  width: min(1080px, calc(100vw - 2rem));
  max-width: 1080px;
}
.call-summary-form {
  max-height: min(86vh, 900px);
  overflow: auto;
}
.call-summary-layout {
  display: grid;
  grid-template-columns: minmax(280px, .82fr) minmax(0, 1.35fr);
  gap: 1rem;
}
.call-summary-profiles,
.call-summary-result {
  min-width: 0;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 1rem;
  background: var(--surface-muted);
}
.call-summary-profiles h3 {
  margin: 0 0 .2rem;
  font-size: .95rem;
}
.call-summary-profiles p {
  margin: 0;
  color: var(--text-muted);
  font-size: .76rem;
  line-height: 1.45;
}
.call-summary-profile-list {
  display: grid;
  gap: .45rem;
  margin-top: .8rem;
}
.call-summary-profile {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: .65rem;
  padding: .7rem .75rem;
  border: 1px solid var(--line);
  border-radius: .8rem;
  background: var(--surface);
  cursor: pointer;
}
.call-summary-profile:hover {
  border-color: color-mix(in srgb, var(--brand-cyan) 45%, var(--line));
}
.call-summary-profile:has(input:checked) {
  border-color: var(--brand-cyan);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--brand-cyan) 16%, transparent);
}
.call-summary-profile input {
  margin-top: .18rem;
}
.call-summary-profile__copy {
  display: grid;
  gap: .12rem;
}
.call-summary-profile__copy strong {
  font-size: .82rem;
}
.call-summary-profile__copy small {
  color: var(--text-muted);
  font-size: .7rem;
  line-height: 1.35;
}
.call-summary-result {
  display: grid;
  min-height: 24rem;
  align-content: start;
  gap: .8rem;
}
.call-summary-result__heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}
.call-summary-result__heading > div {
  display: grid;
  gap: .2rem;
}
.call-summary-result__heading strong {
  font-size: 1rem;
}
.call-summary-empty {
  display: grid;
  min-height: 18rem;
  place-items: center;
  padding: 1.2rem;
  border: 1px dashed var(--line);
  border-radius: .85rem;
  color: var(--text-muted);
  text-align: center;
  font-size: .8rem;
  line-height: 1.55;
}
.call-summary-result__text {
  max-height: min(58vh, 620px);
  margin: 0;
  padding: 1rem;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: .85rem;
  background: var(--surface);
  color: var(--text);
  font: inherit;
  font-size: .8rem;
  line-height: 1.58;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}
.call-summary-actions {
  display: flex;
  justify-content: flex-end;
  gap: .6rem;
  padding-top: .2rem;
}
.recording-row__downloads {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-top: .45rem;
}
.recording-row__downloads .secondary-button {
  white-space: nowrap;
}
.recording-artifact-badge {
  display: inline-flex;
  align-items: center;
  gap: .25rem;
  color: var(--text-muted);
  font-size: .68rem;
}

@media (max-width: 820px) {
  .recording-quick-actions {
    display: none;
  }
  .call-summary-layout {
    grid-template-columns: 1fr;
  }
  .call-summary-result {
    min-height: 18rem;
  }
  .transcription-panel__footer-actions {
    width: 100%;
    flex-wrap: wrap;
    justify-content: flex-end;
  }
}

/* v12.6 — sidebars séparées Réglages / Archives */
.side-drawer {
  position: fixed;
  z-index: 90;
  top: 0;
  right: 0;
  width: min(580px, 100vw);
  height: 100dvh;
  border-left: 1px solid var(--line);
  background: var(--surface);
  box-shadow: -18px 0 54px rgba(14,18,28,.2);
  overflow: hidden;
}
.side-drawer--archives {
  width: min(760px, 100vw);
}
.side-drawer__sheet {
  max-height: 100dvh;
  height: 100%;
}
.sidebar-scrim {
  position: fixed;
  z-index: 89;
  inset: 0;
  background: rgba(14,18,28,.48);
  backdrop-filter: blur(4px);
}
body.side-drawer-open {
  overflow: hidden;
}
.recording-settings--standalone {
  border-bottom: 0;
}
.recording-row__workflow {
  display: flex;
  flex-wrap: wrap;
  gap: .4rem;
  margin-top: .45rem;
}
.recording-row__job-status {
  margin: .35rem 0 0 !important;
  color: var(--text-muted) !important;
  font-size: .72rem !important;
}
.recording-row__job-status.is-error {
  color: var(--danger) !important;
}

@media (max-width: 640px) {
  .side-drawer,
  .side-drawer--archives {
    width: 100vw;
  }
}

/* Extensions internes et plugins Wazo */
.side-drawer--extensions { width: min(680px, 100vw); }
.extensions-list { display: grid; gap: .75rem; margin-top: .85rem; }
.extension-card { display: grid; gap: .6rem; padding: .9rem; border: 1px solid var(--line); border-radius: .9rem; background: var(--surface); }
.extension-card__header { display: flex; align-items: center; justify-content: space-between; gap: .8rem; }
.extension-card__identity { display: flex; align-items: center; gap: .65rem; min-width: 0; }
.extension-card__identity > div { display: grid; gap: .12rem; min-width: 0; }
.extension-card__identity small, .extension-card > p { color: var(--text-muted); font-size: .72rem; line-height: 1.4; }
.extension-card > p { margin: 0; }
.extension-card__icon { display: grid; place-items: center; flex: 0 0 2.2rem; width: 2.2rem; height: 2.2rem; border-radius: .65rem; background: var(--surface-strong); font-weight: 800; overflow: hidden; }
.extension-card__icon img { width: 100%; height: 100%; object-fit: contain; }
.extension-card__status { font-size: .7rem; font-weight: 700; color: var(--text-muted); }
.extension-card__status--running { color: var(--success); }
.extension-card__status--error, #extensions-status.is-error { color: var(--danger); }
.extension-card__tabs { display: flex; flex-wrap: wrap; gap: .4rem; }
.secondary-button--compact { padding: .42rem .65rem; font-size: .72rem; }
.extension-toggle { position: relative; display: inline-flex; flex: 0 0 auto; }
.extension-toggle input { position: absolute; opacity: 0; pointer-events: none; }
.extension-toggle span { width: 2.55rem; height: 1.45rem; border-radius: 999px; background: var(--line-strong, var(--line)); cursor: pointer; transition: .18s ease; }
.extension-toggle span::after { content: ""; display: block; width: 1.05rem; height: 1.05rem; margin: .2rem; border-radius: 50%; background: var(--surface); box-shadow: 0 1px 4px rgba(0,0,0,.22); transition: .18s ease; }
.extension-toggle input:checked + span { background: var(--brand-cyan); }
.extension-toggle input:checked + span::after { transform: translateX(1.1rem); }
.extension-toggle input:disabled + span { opacity: .5; cursor: wait; }
.plugin-tab-buttons { display: contents; }
.plugin-tab__icon { font-size: .85rem; }
.plugin-stage { min-height: 0; height: calc(100dvh - 9.2rem); margin-top: 2.2rem; overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); }
.plugin-stage__header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .8rem 1rem; border-bottom: 1px solid var(--line); }
.plugin-stage__header h1 { margin: 0; font-size: 1.05rem; }
.plugin-stage__body { width: 100%; height: calc(100% - 4.1rem); min-height: 28rem; }
.plugin-frame { display: block; width: 100%; height: 100%; border: 0; background: var(--surface); }
.plugin-background-frame { display: none !important; }
.plugin-banner { position: fixed; z-index: 86; top: 5.4rem; left: 50%; transform: translateX(-50%); max-width: min(760px, calc(100vw - 2rem)); padding: .7rem 1rem; border: 1px solid var(--line); border-radius: .75rem; background: var(--surface); box-shadow: 0 12px 34px rgba(14,18,28,.18); }
.plugin-modal { width: min(760px, calc(100vw - 2rem)); max-height: 85dvh; padding: 0; border: 1px solid var(--line); border-radius: 1rem; background: var(--surface); color: var(--text); }
.plugin-modal::backdrop { background: rgba(14,18,28,.52); backdrop-filter: blur(3px); }
.plugin-modal__header { display: flex; align-items: center; justify-content: space-between; padding: .8rem 1rem; border-bottom: 1px solid var(--line); }
.plugin-modal__header h2 { margin: 0; font-size: 1rem; }
.plugin-modal__body { min-height: 8rem; max-height: 72dvh; overflow: auto; padding: 1rem; }
.plugin-modal__frame { width: 100%; min-height: 55vh; border: 0; }
@media (max-width: 640px) { .side-drawer--extensions { width: 100vw; } .plugin-stage { height: calc(100dvh - 8rem); margin-top: 1rem; border-radius: .7rem; } }
.context-plugin-buttons, .settings-plugin-buttons { display: flex; flex-wrap: wrap; gap: .45rem; }
.settings-plugin-buttons:empty, .context-plugin-buttons:empty { display: none; }
.settings-plugin-buttons { padding: .7rem 1rem 0; }
.section-heading__actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: .45rem; }
.context-plugin-button { display: inline-flex; align-items: center; gap: .35rem; }
.context-plugin-button__badge { min-width: 1.1rem; padding: .05rem .28rem; border-radius: 999px; background: var(--danger); color: #fff; font-size: .62rem; text-align: center; }
.plugin-banner:has(.plugin-banner__frame) { width: min(900px, calc(100vw - 2rem)); padding: 0; overflow: hidden; }
.plugin-banner__frame { display: block; width: 100%; border: 0; }

/* v0.3.12 — état d'enregistrement partagé et sous-titres par participant */
.conference-tile__caption {
  position: absolute;
  z-index: 3;
  right: clamp(.55rem, 1vw, .85rem);
  bottom: clamp(2.65rem, 5vw, 3.35rem);
  left: clamp(.55rem, 1vw, .85rem);
  max-height: 4.6em;
  overflow: hidden;
  padding: .42rem .58rem;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: .55rem;
  background: rgba(5, 8, 13, .78);
  color: #fff;
  font-size: clamp(.65rem, .9vw, .82rem);
  font-weight: 650;
  line-height: 1.35;
  text-align: center;
  text-wrap: balance;
  backdrop-filter: blur(10px);
  box-shadow: 0 .35rem 1.1rem rgba(0,0,0,.22);
}
.conference-tile__caption.is-partial {
  color: rgba(255,255,255,.82);
  font-style: italic;
}
.conference-filmstrip .conference-tile__caption {
  right: .35rem;
  bottom: 2.15rem;
  left: .35rem;
  max-height: 3.9em;
  padding: .28rem .38rem;
  font-size: .58rem;
}
.conference-tile:fullscreen .conference-tile__caption {
  right: 10%;
  bottom: 5rem;
  left: 10%;
  max-height: 5.2em;
  padding: .7rem 1rem;
  font-size: clamp(1rem, 2vw, 1.5rem);
}
.conference-transcript-tile.is-viewer-focus {
  animation: conference-recording-focus 1.35s ease-out;
}
@keyframes conference-recording-focus {
  0%, 35% { box-shadow: 0 0 0 .28rem rgba(37, 191, 201, .35); }
  100% { box-shadow: 0 0 0 0 rgba(37, 191, 201, 0); }
}
