.external-link-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
  font-family: system-ui, 'Segoe UI', Roboto, sans-serif;
}
.external-link-modal-overlay.active {
  opacity: 1;
  visibility: visible;
}
.external-link-modal {
  background: white;
  width: 90%;
  max-width: 1100px;
  max-height: 85vh;
  border-radius: 20px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: modalFadeIn 0.2s ease-out;
}
@keyframes modalFadeIn {
  from { opacity: 0; transform: scale(0.96); }
  to { opacity: 1; transform: scale(1); }
}
.external-link-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid #e9ecef;
  background: #ffffff;
}
.external-link-modal-header h3 {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 600;
  color: #1e293b;
  display: flex;
  align-items: center;
  gap: 8px;
}
.external-link-close-btn {
  background: transparent;
  border: none;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
  width: 34px;
  height: 34px;
  border-radius: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #5f6c84;
  transition: all 0.2s;
}
.external-link-close-btn:hover {
  background: #f1f5f9;
  color: #dc2626;
}
.external-link-modal-body {
  flex: 1;
  overflow-y: auto;
  padding: 0;
  background: #f8fafc;
  min-height: 400px;
  position: relative;
}
.external-link-iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}
.external-link-fallback {
  padding: 30px 24px;
  text-align: center;
  color: #334155;
}
.external-link-fallback p {
  margin-bottom: 20px;
  font-size: 1rem;
}
.external-link-fallback button {
  background: #2563eb;
  border: none;
  color: white;
  padding: 10px 24px;
  border-radius: 40px;
  font-size: 0.9rem;
  cursor: pointer;
  transition: 0.2s;
  font-weight: 500;
}
.external-link-fallback button:hover {
  background: #1d4ed8;
  transform: translateY(-1px);
}
.external-link-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 100%;
  min-height: 300px;
  gap: 16px;
  color: #3b82f6;
}
.external-link-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid #e2e8f0;
  border-top-color: #2563eb;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@media (max-width: 640px) {
  .external-link-modal {
    width: 95%;
    max-height: 90vh;
    border-radius: 16px;
  }
  .external-link-modal-header h3 {
    font-size: 1rem;
  }
}