/* Call view isolated styles: clean translucent layout */

.call-overlay {
  --ivory: #f5f3ef;
  --ink: #1e1a17;
  --rose: #f47f9f;
  --amber: #d7b08a;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  display: none;
  overflow: hidden;
  z-index: 20000;
  color: var(--ivory);
  background: #0f0e0d;
  font-family: "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
}

.call-overlay.active {
  display: block;
}

.call-overlay::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(circle at 18% 12%, rgba(255, 207, 157, 0.18), transparent 34%),
    radial-gradient(circle at 86% 82%, rgba(171, 132, 104, 0.16), transparent 40%),
    linear-gradient(180deg, rgba(11, 10, 9, 0.4), rgba(11, 10, 9, 0.78));
}

.call-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  filter: saturate(0.84) contrast(0.9) brightness(0.72);
}

.call-audio-unlock {
  position: absolute;
  inset: 0;
  z-index: 70;
  display: none;
  align-items: center;
  justify-content: center;
  background: rgba(8, 7, 6, 0.48);
  backdrop-filter: blur(8px);
}

.call-audio-unlock.show {
  display: flex;
}

.call-audio-card {
  width: min(280px, 82vw);
  border-radius: 18px;
  background: rgba(17, 14, 11, 0.78);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.42);
  padding: 20px;
  text-align: center;
}

.call-audio-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 6px;
}

.call-audio-desc {
  font-size: 12px;
  color: rgba(245, 243, 239, 0.72);
  margin-bottom: 12px;
}

.call-audio-btn {
  border: none;
  border-radius: 999px;
  padding: 8px 16px;
  background: linear-gradient(180deg, #e3bc96, #be8f67);
  color: #20160f;
  font-weight: 600;
  cursor: pointer;
}

.call-min-btn {
  position: absolute;
  top: calc(var(--safe-top, 0px) + 14px);
  left: 14px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: none;
  background: rgba(19, 16, 12, 0.52);
  color: var(--ivory);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 40;
  cursor: pointer;
  backdrop-filter: blur(6px);
}

.call-network-pill {
  position: absolute;
  top: calc(var(--safe-top, 0px) + 15px);
  left: 64px;
  z-index: 35;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  padding: 6px 10px;
  background: rgba(20, 16, 13, 0.42);
  backdrop-filter: blur(6px);
}

.call-network-bars {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
}

.call-network-bars i {
  display: block;
  width: 3px;
  background: #d9b18b;
  border-radius: 2px;
}

.call-network-bars i:nth-child(1) { height: 5px; }
.call-network-bars i:nth-child(2) { height: 8px; }
.call-network-bars i:nth-child(3) { height: 11px; }

.call-network-text {
  font-size: 11px;
  color: rgba(245, 243, 239, 0.82);
}

.call-info {
  position: absolute;
  top: calc(var(--safe-top, 0px) + 78px);
  left: 18px;
  right: 128px;
  z-index: 25;
}

.call-name {
  margin: 0;
  font-size: clamp(27px, 6.2vw, 38px);
  line-height: 1.08;
  font-weight: 600;
  text-shadow: 0 2px 14px rgba(0, 0, 0, 0.4);
}

.call-meta {
  margin-top: 8px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(20, 16, 13, 0.38);
  backdrop-filter: blur(6px);
}

.call-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #e0b68d;
  box-shadow: 0 0 10px rgba(224, 182, 141, 0.65);
}

.call-status {
  margin: 0;
  font-size: 13px;
  color: rgba(245, 243, 239, 0.9);
}

/* keep self preview at top-right */
.local-video {
  position: absolute;
  top: calc(var(--safe-top, 0px) + 14px);
  right: 14px;
  width: min(32vw, 120px);
  aspect-ratio: 3 / 4;
  z-index: 38;
  border-radius: 15px;
  object-fit: cover;
  background: #090909;
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.5);
}

.call-overlay.video-off .local-video {
  filter: grayscale(0.95) brightness(0.36);
}

.call-lyric-stream {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 212px;
  max-height: 31vh;
  overflow-y: auto;
  z-index: 24;
  padding: 10px 10px 4px;
  border-radius: 14px;
  background: linear-gradient(180deg, rgba(20, 16, 13, 0.34), rgba(20, 16, 13, 0.2));
  backdrop-filter: blur(5px);
}

.call-lyric-stream::-webkit-scrollbar {
  width: 4px;
}

.call-lyric-stream::-webkit-scrollbar-thumb {
  background: rgba(245, 243, 239, 0.28);
  border-radius: 3px;
}

.call-lyric-line {
  margin: 0 0 7px;
  font-size: 13px;
  line-height: 1.45;
  color: rgba(245, 243, 239, 0.92);
  word-break: break-word;
}

.call-lyric-line.user {
  color: #f4d4b4;
}

.call-lyric-line.assistant {
  color: #fcfbfa;
}

.call-lyric-line.system {
  color: rgba(245, 243, 239, 0.67);
}

.call-composer {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 126px;
  z-index: 45;
}

.call-composer-top {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.call-composer textarea {
  height: 48px;
  max-height: 48px;
  resize: none;
  border: none;
  border-radius: 12px;
  background: rgba(20, 16, 13, 0.48);
  color: var(--ivory);
  padding: 12px;
  font-size: 14px;
  outline: none;
  backdrop-filter: blur(4px);
}

.call-composer textarea::placeholder {
  color: rgba(245, 243, 239, 0.54);
}

.call-composer-top > button {
  min-width: 58px;
  height: 48px;
  padding: 0 14px;
  border: none;
  border-radius: 12px;
  background: rgba(235, 188, 149, 0.9);
  color: #23180f;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.22);
}

/* button wrapper line removed */
.call-controls {
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 22px;
  height: 88px;
  padding: 0 16px;
  border-radius: 22px;
  border: none;
  background: rgba(20, 16, 13, 0.34);
  backdrop-filter: blur(8px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.36);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  z-index: 50;
}

.call-btn {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: none;
  color: #f8f6f2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  position: relative;
  transition: transform 0.16s ease, opacity 0.16s ease;
  backdrop-filter: blur(8px);
}

.call-btn:active {
  transform: scale(0.94);
}

.call-btn.camera {
  order: 1;
  background: rgba(28, 23, 18, 0.6);
}

.call-btn.hangup {
  order: 2;
  width: 68px;
  height: 68px;
  background: linear-gradient(180deg, #ff85a2, #ef5f86);
  box-shadow: 0 10px 22px rgba(239, 95, 134, 0.38);
}

.call-btn.video-toggle {
  order: 3;
  background: rgba(196, 153, 119, 0.72);
  color: #2b1c10;
}

.call-btn.video-toggle.is-off {
  background: rgba(28, 23, 18, 0.56);
  color: rgba(245, 243, 239, 0.62);
}

.call-btn.video-toggle.is-off::after {
  content: "";
  position: absolute;
  width: 30px;
  height: 2px;
  background: rgba(245, 243, 239, 0.58);
  transform: rotate(-45deg);
}

.call-btn-label {
  display: none;
}

.call-mini-close {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: none;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  font-size: 16px;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 90;
}

.call-overlay.voice-mode .local-video,
.call-overlay.voice-mode .call-btn.camera,
.call-overlay.voice-mode .call-btn.video-toggle,
.call-overlay.voice-mode .call-network-pill {
  display: none;
}

.call-overlay.voice-mode .call-info {
  right: 14px;
}

.call-overlay.voice-mode .call-controls {
  justify-content: center;
}

.call-overlay.voice-mode .call-btn.hangup {
  width: 72px;
  height: 72px;
}

.call-overlay.minimized {
  width: 150px;
  height: 200px;
  top: calc(var(--safe-top, 0px) + 12px);
  right: 12px;
  left: auto;
  bottom: auto;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 18px 34px rgba(0, 0, 0, 0.3);
  cursor: move;
}

.call-overlay.minimized::before {
  display: none;
}

.call-overlay.minimized .call-min-btn,
.call-overlay.minimized .call-info,
.call-overlay.minimized .call-network-pill,
.call-overlay.minimized .call-controls,
.call-overlay.minimized .call-lyric-stream,
.call-overlay.minimized .call-composer {
  display: none;
}

.call-overlay.minimized .local-video {
  top: 8px;
  right: 8px;
  width: 134px;
  height: 184px;
  border-radius: 12px;
}

.call-overlay.minimized .call-mini-close {
  display: inline-flex;
}
