/* === ELLE PANEL — Right-Side Slide-In (Voice + Camera) === */

.elle-panel {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 350px;
  max-width: 100vw;
  z-index: 260;
  background:
    linear-gradient(180deg, rgba(10, 10, 15, 0.98) 0%, rgba(8, 8, 12, 0.99) 100%);
  border-left: 1px solid rgba(212, 175, 55, 0.2);
  box-shadow: -16px 0 50px rgba(0, 0, 0, 0.7), inset 1px 0 0 rgba(212, 175, 55, 0.06);
  display: flex;
  flex-direction: column;
  transform: translateX(0);
  transition: transform 0.3s ease, opacity 0.25s ease;
  backdrop-filter: blur(12px);
  overflow: hidden;
}

.elle-panel-hidden {
  transform: translateX(110%);
  opacity: 0;
  pointer-events: none;
}

/* === HEADER === */
.elle-panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px 10px;
  border-bottom: 1px solid rgba(212, 175, 55, 0.1);
  flex-shrink: 0;
}

.elle-panel-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.elle-panel-title {
  font-family: 'Georgia', serif;
  font-style: italic;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 3px;
  color: #e8c07a;
  text-shadow: 0 0 14px rgba(212, 175, 55, 0.25);
}

/* Recording dot — red pulse */
.elle-panel-rec-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: transparent;
  transition: background 0.3s ease;
}

.elle-panel-rec-dot.elle-rec-active {
  background: #ef4444;
  box-shadow: 0 0 6px rgba(239, 68, 68, 0.6);
  animation: elle-rec-pulse 1.2s ease-in-out infinite;
}

@keyframes elle-rec-pulse {
  0%, 100% { opacity: 1; box-shadow: 0 0 6px rgba(239, 68, 68, 0.5); }
  50% { opacity: 0.4; box-shadow: 0 0 12px rgba(239, 68, 68, 0.8); }
}

/* Header control buttons */
.elle-panel-header-controls {
  display: flex;
  align-items: center;
  gap: 6px;
}

.elle-panel-ctrl-btn {
  background: transparent;
  border: 1px solid rgba(212, 175, 55, 0.15);
  color: #7a7a8a;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
  font-size: 18px;
  line-height: 1;
}

.elle-panel-ctrl-btn:hover {
  color: #e8e8ec;
  border-color: rgba(212, 175, 55, 0.35);
  background: rgba(212, 175, 55, 0.05);
}

.elle-panel-ctrl-btn.elle-ctrl-active {
  color: #d4af37;
  border-color: #d4af37;
  background: rgba(212, 175, 55, 0.12);
}

.elle-panel-close {
  font-size: 20px;
}

/* === BODY === */
.elle-panel-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding: 0;
}

/* === AVATAR SECTION === */
.elle-avatar-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px 16px 12px;
  flex-shrink: 0;
}

.elle-avatar-circle {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  border: 2px solid rgba(212, 175, 55, 0.4);
  background:
    radial-gradient(circle at 35% 30%, rgba(255, 217, 138, 0.9) 0%, rgba(212, 175, 55, 0.75) 45%, rgba(40, 30, 15, 0.9) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow:
    0 0 20px rgba(212, 175, 55, 0.3),
    inset 0 0 14px rgba(255, 217, 138, 0.35);
  animation: elle-avatar-breathe 4s ease-in-out infinite;
}

.elle-avatar-letter {
  font-family: 'Georgia', serif;
  font-style: italic;
  font-weight: 700;
  font-size: 30px;
  color: #0a0a10;
  text-shadow: 0 1px 0 rgba(255, 217, 138, 0.5);
}

@keyframes elle-avatar-breathe {
  0%, 100% { box-shadow: 0 0 20px rgba(212, 175, 55, 0.25), inset 0 0 14px rgba(255, 217, 138, 0.3); }
  50% { box-shadow: 0 0 30px rgba(212, 175, 55, 0.45), inset 0 0 18px rgba(255, 217, 138, 0.45); }
}

.elle-avatar-status {
  margin-top: 8px;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #d4af37;
  text-align: center;
}

/* === CAMERA SECTION === */
.elle-camera-section {
  position: relative;
  width: 100%;
  aspect-ratio: 4/3;
  max-height: 240px;
  background: #050508;
  border-top: 1px solid rgba(212, 175, 55, 0.08);
  border-bottom: 1px solid rgba(212, 175, 55, 0.08);
  overflow: hidden;
  flex-shrink: 0;
}

.elle-camera-section video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 0;
}

.elle-camera-section.elle-camera-off video {
  display: none;
}

.elle-camera-off-label {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #4a4a5a;
}

.elle-camera-section:not(.elle-camera-off) .elle-camera-off-label {
  display: none;
}

.elle-camera-overlay {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.elle-camera-frame-count {
  font-size: 10px;
  color: rgba(212, 175, 55, 0.7);
  font-weight: 600;
  letter-spacing: 1px;
  background: rgba(0, 0, 0, 0.6);
  padding: 2px 6px;
  border-radius: 3px;
}

/* === ANALYSIS SECTION === */
.elle-analysis-section {
  flex: 1;
  padding: 14px 16px 20px;
  overflow-y: auto;
  min-height: 100px;
}

.elle-analysis-label {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: #d4af37;
  margin-bottom: 8px;
}

.elle-analysis-text {
  font-size: 13px;
  line-height: 1.65;
  color: #e8e8ec;
  white-space: pre-wrap;
  font-family: 'SF Mono', 'Fira Code', 'Cascadia Code', 'JetBrains Mono', monospace;
}

/* === RESPONSIVE === */
@media (max-width: 480px) {
  .elle-panel {
    width: 100vw;
    border-left: none;
  }

  .elle-camera-section {
    max-height: 200px;
  }

  .elle-avatar-circle {
    width: 60px;
    height: 60px;
  }

  .elle-avatar-letter {
    font-size: 24px;
  }

  .elle-avatar-section {
    padding: 14px 16px 8px;
  }
}

@media (min-width: 481px) and (max-width: 768px) {
  .elle-panel {
    width: 100vw;
  }
}

/* === SCROLLBAR inside panel === */
.elle-panel-body::-webkit-scrollbar {
  width: 4px;
}

.elle-panel-body::-webkit-scrollbar-track {
  background: transparent;
}

.elle-panel-body::-webkit-scrollbar-thumb {
  background: rgba(212, 175, 55, 0.15);
  border-radius: 2px;
}

.elle-panel-body::-webkit-scrollbar-thumb:hover {
  background: rgba(212, 175, 55, 0.3);
}
