:root {
  --wa-primary: #25D366;
  --wa-dark: #075E54;
  --wa-teal: #128C7E;
  --wa-bg: #F0F2F5;
  --wa-card-bg: #FFFFFF;
  --wa-text: #111B21;
  --wa-text-muted: #667781;
  --wa-border: #E9EDEF;
  --danger-color: #EA4335;
  --warning-bg: #FFF3CD;
  --warning-text: #856404;
  --warning-border: #FFEBAA;
  --live-bg: #E8F5E9;
  --live-text: #1B5E20;
  --live-border: #A5D6A7;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
}

body {
  background-color: var(--wa-bg);
  color: var(--wa-text);
  line-height: 1.5;
  min-height: 100vh;
}

.app-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* Header */
.app-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--wa-card-bg);
  padding: 18px 24px;
  border-radius: 12px;
  box-shadow: 0 1px 3px rgba(11, 20, 26, 0.08);
}

.header-brand {
  display: flex;
  align-items: center;
  gap: 16px;
}

.whatsapp-logo {
  width: 44px;
  height: 44px;
  color: var(--wa-primary);
}

.header-brand h1 {
  font-size: 22px;
  font-weight: 600;
  color: var(--wa-dark);
}

.subtext {
  font-size: 13px;
  color: var(--wa-text-muted);
}

/* Mode Banner */
.mode-banner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 24px;
  border-radius: 12px;
  transition: all 0.3s ease;
  border: 1px solid transparent;
}

.demo-banner {
  background-color: var(--warning-bg);
  color: var(--warning-text);
  border-color: var(--warning-border);
}

.live-banner {
  background-color: var(--live-bg);
  color: var(--live-text);
  border-color: var(--live-border);
}

.banner-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 4px;
}

.banner-desc {
  font-size: 13px;
  opacity: 0.9;
}

.mode-switch-group {
  display: flex;
  background: rgba(0, 0, 0, 0.08);
  border-radius: 8px;
  padding: 4px;
  gap: 4px;
}

.mode-btn {
  border: none;
  background: transparent;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  color: inherit;
  transition: background-color 0.2s;
}

.mode-btn.active {
  background-color: #FFFFFF;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.15);
  color: var(--wa-text);
}

/* Layout Grid */
.main-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

@media (max-width: 900px) {
  .main-content {
    grid-template-columns: 1fr;
  }
}

/* Cards */
.card {
  background-color: var(--wa-card-bg);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 1px 3px rgba(11, 20, 26, 0.08);
  border: 1px solid var(--wa-border);
}

.card-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--wa-dark);
  margin-bottom: 6px;
}

.card-desc {
  font-size: 13px;
  color: var(--wa-text-muted);
  margin-bottom: 20px;
}

/* Form Controls */
.form-group {
  margin-bottom: 18px;
}

.form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--wa-text);
}

.input-with-button {
  display: flex;
  gap: 8px;
}

input[type="tel"],
input[type="text"],
input[type="password"] {
  flex: 1;
  padding: 12px 14px;
  font-size: 15px;
  border: 1px solid var(--wa-border);
  border-radius: 8px;
  background-color: #FAFAFA;
  color: var(--wa-text);
  outline: none;
  transition: border-color 0.2s;
}

input:focus {
  border-color: var(--wa-teal);
  background-color: #FFFFFF;
}

/* Buttons */
.btn-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 14px 20px;
  font-size: 16px;
  font-weight: 600;
  color: #FFFFFF;
  background-color: var(--wa-primary);
  border: none;
  border-radius: 8px;
  cursor: pointer;
  box-shadow: 0 2px 4px rgba(37, 211, 102, 0.3);
  transition: transform 0.1s, background-color 0.2s;
}

.btn-call:hover:not(:disabled) {
  background-color: #20BA5A;
}

.btn-call:disabled {
  background-color: #B2D8C0;
  cursor: not-allowed;
  box-shadow: none;
}

.btn-secondary {
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--wa-dark);
  background-color: #EFEFEF;
  border: 1px solid var(--wa-border);
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s;
}

.btn-secondary:hover {
  background-color: #E2E2E2;
}

.btn-small {
  padding: 6px 12px;
  font-size: 12px;
  border: 1px solid var(--wa-border);
  background: #FFFFFF;
  border-radius: 6px;
  cursor: pointer;
}

.phone-icon {
  width: 20px;
  height: 20px;
}

/* Permission Status Box */
.permission-status-box {
  background-color: #F8F9FA;
  border: 1px solid var(--wa-border);
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 20px;
}

.perm-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.perm-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--wa-text);
}

.badge {
  font-size: 11px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 12px;
  text-transform: uppercase;
}

.badge-gray { background-color: #E0E0E0; color: #424242; }
.badge-green { background-color: #C8E6C9; color: #2E7D32; }
.badge-red { background-color: #FFCDD2; color: #C62828; }
.badge-amber { background-color: #FFE082; color: #E65100; }

.perm-desc {
  font-size: 12px;
  color: var(--wa-text-muted);
}

.cpr-action-box {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--wa-border);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.btn-cpr {
  padding: 8px 12px;
  background-color: #E1F5FE;
  color: #0277BD;
  border: 1px solid #B3E5FC;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}

.btn-cpr:hover {
  background-color: #B3E5FC;
}

.cpr-tip {
  font-size: 11px;
  color: var(--wa-text-muted);
}

/* Active Call Screen */
.active-call-card {
  margin-top: 20px;
  padding: 20px;
  background: #0B141A;
  color: #FFFFFF;
  border-radius: 12px;
  text-align: center;
}

.active-call-notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
  text-align: left;
  font-size: 13px;
  line-height: 1.4;
}

.active-call-notice p {
  margin: 4px 0 0;
  font-size: 12px;
  opacity: 0.9;
}

.notice-icon {
  font-size: 20px;
  line-height: 1;
}

.demo-notice {
  background-color: #2D2305;
  border: 1px solid #FFC107;
  color: #FFF3CD;
}

.demo-notice strong {
  color: #FFD54F;
}

.live-notice {
  background-color: #062817;
  border: 1px solid #25D366;
  color: #D4EDDA;
}

.live-notice strong {
  color: #25D366;
}

.btn-echo.muted {
  background: #54656F;
}

.active-call-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.active-callee {
  font-size: 16px;
  font-weight: 600;
}

.call-state-pill {
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 12px;
  background-color: rgba(37, 211, 102, 0.2);
  color: var(--wa-primary);
  font-weight: 600;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { opacity: 0.6; }
  50% { opacity: 1; }
  100% { opacity: 0.6; }
}

.call-timer {
  font-size: 32px;
  font-family: monospace;
  font-weight: 700;
  margin: 12px 0;
  color: #E9EDEF;
}

/* Microphone Meter */
.audio-meter-container {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 14px 0 20px 0;
  font-size: 12px;
  color: #8696A0;
}

.meter-bar-track {
  flex: 1;
  height: 6px;
  background: #202C33;
  border-radius: 3px;
  overflow: hidden;
}

.meter-bar-fill {
  height: 100%;
  width: 0%;
  background: var(--wa-primary);
  transition: width 0.05s ease;
}

.active-call-controls {
  display: flex;
  justify-content: center;
  gap: 16px;
}

.btn-circle {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: none;
  background: #202C33;
  color: #FFFFFF;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s;
}

.btn-circle:hover {
  background: #3B4A54;
}

.btn-hangup {
  background-color: var(--danger-color);
}

.btn-hangup:hover {
  background-color: #D32F2F;
}

/* Terminal Inspector */
.inspector-card {
  display: flex;
  flex-direction: column;
}

.inspector-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.terminal-stream {
  flex: 1;
  min-height: 420px;
  max-height: 520px;
  background: #0B141A;
  color: #D1D7DB;
  font-family: 'Consolas', 'Courier New', monospace;
  font-size: 12px;
  padding: 14px;
  border-radius: 8px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.log-line {
  word-break: break-all;
  white-space: pre-wrap;
  line-height: 1.4;
}

.log-line.system-line { color: #8696A0; }
.log-line.webrtc-line { color: #53BDEB; }
.log-line.meta-line { color: #25D366; }
.log-line.error-line { color: #F15C6D; }

/* Modal */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
}

.modal-card {
  background: #FFFFFF;
  border-radius: 12px;
  width: 520px;
  max-width: 90vw;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
  display: flex;
  flex-direction: column;
}

.modal-header {
  padding: 18px 24px;
  border-bottom: 1px solid var(--wa-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header h3 {
  font-size: 18px;
  color: var(--wa-dark);
}

.btn-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--wa-text-muted);
}

.modal-body {
  padding: 20px 24px;
}

.modal-info {
  font-size: 13px;
  color: var(--wa-text-muted);
  margin-bottom: 16px;
}

.modal-footer {
  padding: 16px 24px;
  border-top: 1px solid var(--wa-border);
}

/* ==========================================
   Call Type Switcher & 1-Click Video UI
   ========================================== */
.call-type-toggle-group {
  display: flex;
  background: #F0F2F5;
  border-radius: 8px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 20px;
}

.call-type-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 10px;
  border: none;
  background: transparent;
  color: var(--wa-text-muted);
  font-size: 13px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.call-type-btn:hover {
  color: var(--wa-dark);
}

.call-type-btn.active {
  background: #FFFFFF;
  color: var(--wa-dark);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.btn-video {
  background-color: #00A884;
}

.btn-video:hover:not(:disabled) {
  background-color: #008f6f;
}

.video-info-box {
  background: #F0FDF4;
  border: 1px solid #BBF7D0;
  border-radius: 8px;
  padding: 14px 16px;
  margin-bottom: 18px;
}

.video-info-header {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: #166534;
  margin-bottom: 6px;
}

.video-info-box p {
  font-size: 13px;
  color: #15803D;
  line-height: 1.5;
  margin: 0;
}

/* Active Video Card */
.active-video-card {
  margin-top: 20px;
  background: #111B21;
  border-radius: 12px;
  padding: 16px;
  color: #E9EDEF;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.active-video-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  padding-bottom: 10px;
  border-bottom: 1px solid #202C33;
}

.active-video-title {
  font-size: 16px;
  font-weight: 600;
  color: #E9EDEF;
}

.active-video-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  color: #25D366;
  background: rgba(37, 211, 102, 0.15);
  padding: 3px 8px;
  border-radius: 10px;
  margin-top: 4px;
}

.btn-hangup-small {
  background-color: #EA0038;
  color: #FFFFFF;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
}

.btn-hangup-small:hover {
  background-color: #C80030;
}

.video-share-bar {
  background: #202C33;
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 12px;
}

.share-url-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.share-label {
  font-size: 12px;
  color: #8696A0;
  white-space: nowrap;
}

.share-url-input {
  flex: 1;
  background: #111B21;
  border: 1px solid #2A3942;
  color: #25D366;
  font-family: monospace;
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 6px;
  outline: none;
}

.video-invite-status {
  font-size: 12px;
  color: #8696A0;
  margin-top: 6px;
}

.video-invite-status.success {
  color: #25D366;
}

.video-invite-status.warning {
  color: #FFA000;
}

/* Native Video Stage */
.native-video-stage {
  position: relative;
  width: 100%;
  height: 480px;
  background: #000;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}

.agent-remote-container {
  width: 100%;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

#agentRemoteVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.agent-waiting-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #111B21;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px;
  color: #8696A0;
  z-index: 2;
}

.agent-waiting-overlay .waiting-spinner {
  width: 44px;
  height: 44px;
  border: 3px solid rgba(0, 168, 132, 0.2);
  border-top-color: #00A884;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 14px;
}

.waiting-tip {
  font-size: 12px;
  color: #25D366;
  margin-top: 10px;
  background: rgba(37, 211, 102, 0.1);
  padding: 6px 14px;
  border-radius: 20px;
}

.agent-local-pip {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 130px;
  height: 95px;
  background: #202C33;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  border: 2px solid #00A884;
  z-index: 5;
}

#agentLocalVideo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scaleX(-1);
}

.pip-label {
  position: absolute;
  bottom: 4px;
  left: 6px;
  font-size: 10px;
  background: rgba(0, 0, 0, 0.6);
  padding: 1px 5px;
  border-radius: 4px;
  color: #E9EDEF;
}

.agent-video-controls {
  position: absolute;
  bottom: 14px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 12px;
  z-index: 5;
  background: rgba(17, 27, 33, 0.75);
  backdrop-filter: blur(8px);
  padding: 6px 14px;
  border-radius: 30px;
}

.agent-btn-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: #202C33;
  color: #E9EDEF;
  font-size: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
}

.agent-btn-circle:hover {
  background: #3B4A54;
}

.agent-btn-circle.active-mute {
  background: #EA0038;
}

/* ==========================================
   Live Recording Badges & Animations
   ========================================== */
.live-rec-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(234, 67, 53, 0.15);
  color: #EA4335;
  border: 1px solid rgba(234, 67, 53, 0.4);
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.rec-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background-color: #EA4335;
  display: inline-block;
  animation: pulseRec 1.2s infinite;
}

@keyframes pulseRec {
  0% { transform: scale(0.9); opacity: 0.7; box-shadow: 0 0 0 0 rgba(234, 67, 53, 0.7); }
  70% { transform: scale(1.1); opacity: 1; box-shadow: 0 0 0 5px rgba(234, 67, 53, 0); }
  100% { transform: scale(0.9); opacity: 0.7; box-shadow: 0 0 0 0 rgba(234, 67, 53, 0); }
}

/* ==========================================
   Saved Recordings Tab & Grid
   ========================================== */
.recordings-toolbar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 16px;
}

.recordings-search-box input {
  width: 100%;
  padding: 10px 14px;
  font-size: 14px;
  border: 1px solid var(--wa-border);
  border-radius: 8px;
  background: #F0F2F5;
  outline: none;
}

.recordings-search-box input:focus {
  border-color: var(--wa-teal);
  background: #FFFFFF;
}

.recordings-filter-group {
  display: flex;
  gap: 6px;
  align-items: center;
}

.rec-filter-btn {
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid var(--wa-border);
  background: #FAFAFA;
  color: var(--wa-text-muted);
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.2s;
}

.rec-filter-btn.active {
  background: var(--wa-teal);
  color: #FFFFFF;
  border-color: var(--wa-teal);
}

.btn-refresh-rec {
  margin-left: auto;
  padding: 6px 10px;
  background: #F0F2F5;
  border: 1px solid var(--wa-border);
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  transition: background 0.2s;
}

.btn-refresh-rec:hover {
  background: #E2E8F0;
}

.recordings-empty {
  text-align: center;
  padding: 40px 20px;
  background: #F8FAFC;
  border: 1px dashed #CBD5E1;
  border-radius: 12px;
  margin-top: 10px;
}

.recordings-empty .empty-icon {
  font-size: 40px;
  margin-bottom: 8px;
}

.recordings-empty h4 {
  font-size: 16px;
  color: var(--wa-dark);
  margin-bottom: 6px;
}

.recordings-empty p {
  font-size: 13px;
  color: var(--wa-text-muted);
  max-width: 400px;
  margin: 0 auto;
}

.recordings-loading {
  text-align: center;
  padding: 30px;
}

.recordings-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 520px;
  overflow-y: auto;
  padding-right: 4px;
}

.recording-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px;
  background: #FFFFFF;
  border: 1px solid var(--wa-border);
  border-radius: 10px;
  transition: all 0.2s ease;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.recording-card:hover {
  border-color: var(--wa-primary);
  box-shadow: 0 4px 12px rgba(37, 211, 102, 0.12);
  transform: translateY(-1px);
}

.rec-card-thumbnail {
  position: relative;
  width: 58px;
  height: 58px;
  border-radius: 10px;
  background: #0B141A;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  flex-shrink: 0;
  cursor: pointer;
  overflow: hidden;
}

.rec-card-thumbnail.voice-thumb {
  background: #128C7E;
}

.rec-card-thumbnail:hover .play-overlay-icon {
  opacity: 1;
  transform: scale(1.1);
}

.play-overlay-icon {
  position: absolute;
  opacity: 0.8;
  font-size: 20px;
  transition: all 0.2s;
}

.rec-card-details {
  flex: 1;
  min-width: 0;
}

.rec-card-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 4px;
}

.rec-card-recipient {
  font-size: 15px;
  font-weight: 600;
  color: var(--wa-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rec-type-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
  letter-spacing: 0.3px;
}

.badge-video {
  background: #E8F5E9;
  color: #1B5E20;
}

.badge-voice {
  background: #E0F2FE;
  color: #0369A1;
}

.rec-card-meta-row {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--wa-text-muted);
}

.rec-card-meta-row span {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.rec-card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-play-rec {
  padding: 7px 14px;
  background: var(--wa-primary);
  color: #FFFFFF;
  font-size: 13px;
  font-weight: 600;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: background 0.2s;
}

.btn-play-rec:hover {
  background: #20BA5A;
}

.btn-delete-rec {
  padding: 6px 10px;
  background: transparent;
  color: #8696A0;
  border: 1px solid transparent;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.2s;
}

.btn-delete-rec:hover {
  background: #FEE2E2;
  color: #DC2626;
  border-color: #FECACA;
}

/* ==========================================
   Playback Theater Modal
   ========================================== */
.playback-modal-card {
  width: 760px;
  max-width: 95vw;
  background: #111B21;
  color: #E9EDEF;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

.playback-header-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.playback-modal-card .modal-header {
  border-bottom: 1px solid #202C33;
  padding: 16px 20px;
}

.playback-modal-card .modal-header h3 {
  color: #FFFFFF;
  font-size: 18px;
  margin: 0;
}

.playback-subdate {
  font-size: 12px;
  color: #8696A0;
}

.playback-modal-body {
  padding: 16px 20px;
  background: #0B141A;
}

.playback-media-stage {
  width: 100%;
  background: #000000;
  border-radius: 10px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 380px;
  max-height: 480px;
}

.playback-media-stage video {
  width: 100%;
  max-height: 480px;
  outline: none;
}

.audio-playback-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 50px 20px;
  gap: 20px;
  width: 100%;
}

.audio-wave-visual {
  text-align: center;
}

.audio-icon-large {
  font-size: 54px;
  display: block;
  margin-bottom: 8px;
}

.audio-wave-visual h4 {
  font-size: 18px;
  color: #25D366;
}

.audio-playback-container audio {
  width: 100%;
  max-width: 440px;
}

.playback-meta-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid #202C33;
  font-size: 13px;
}

.playback-meta-row .meta-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.playback-meta-row .meta-label {
  font-size: 11px;
  color: #8696A0;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.code-span {
  font-family: monospace;
  color: #53BDEB;
  font-size: 12px;
}

.playback-modal-footer {
  border-top: 1px solid #202C33;
  background: #111B21;
  padding: 14px 20px;
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.btn-danger-small {
  padding: 8px 14px;
  background: transparent;
  color: #EF4444;
  border: 1px solid #7F1D1D;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.2s;
}

.btn-danger-small:hover {
  background: #7F1D1D;
  color: #FFFFFF;
}

/* ==========================================
   Inline Recipient Edit & Resend
   ========================================== */
.btn-edit-callee {
  background: rgba(255, 255, 255, 0.1);
  color: #53BDEB;
  border: 1px solid rgba(83, 189, 235, 0.3);
  border-radius: 4px;
  padding: 2px 8px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-edit-callee:hover {
  background: rgba(83, 189, 235, 0.2);
  color: #FFFFFF;
}

.inline-edit-box {
  background: #111B21;
  border: 1px solid #2A3942;
  border-radius: 8px;
  padding: 10px 14px;
  margin: 12px 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.inline-edit-label {
  font-size: 12px;
  color: #8696A0;
}

.inline-edit-input-group {
  display: flex;
  gap: 8px;
}

.inline-edit-input-group input {
  flex: 1;
  background: #202C33;
  border: 1px solid #2A3942;
  color: #FFFFFF;
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 13px;
  outline: none;
}

.inline-edit-input-group input:focus {
  border-color: #25D366;
}
