/* M Media Download Gate - Frontend Styles */

/* Modal Overlay */
.mmedia-dg-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 999999;
}

.mmedia-dg-modal-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
}

/* Modal Content */
.mmedia-dg-modal-content {
  position: relative;
  max-width: 500px;
  margin: 100px auto;
  background: #ffffff;
  border-radius: 20px;
  padding: 3rem;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: mmediaDgSlideIn 0.3s ease-out;
}

@keyframes mmediaDgSlideIn {
  from {
    opacity: 0;
    transform: translateY(-30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Close Button */
.mmedia-dg-modal-close {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  background: transparent;
  border: none;
  font-size: 2rem;
  line-height: 1;
  color: #86868b;
  cursor: pointer;
  padding: 0;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.mmedia-dg-modal-close:hover {
  color: #1d1d1f;
}

/* Modal Header */
.mmedia-dg-modal-header {
  text-align: center;
  margin-bottom: 2rem;
}

.mmedia-dg-modal-header h2 {
  margin: 0 0 0.5rem 0;
  font-size: 1.75rem;
  font-weight: 700;
  color: #1d1d1f;
  letter-spacing: -0.02em;
}

.mmedia-dg-modal-header p {
  margin: 0;
  color: #86868b;
  font-size: 1rem;
}

/* Form */
.mmedia-dg-form-group {
  margin-bottom: 1.5rem;
}

.mmedia-dg-form-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #1d1d1f;
  font-size: 0.875rem;
}

.mmedia-dg-form-group input[type="email"] {
  width: 100%;
  padding: 1rem 1.25rem;
  font-size: 1rem;
  border: 1px solid #e9ecef;
  border-radius: 12px;
  background: #f8f9fa;
  transition: all 0.3s ease;
  font-family: inherit;
}

.mmedia-dg-form-group input[type="email"]:focus {
  outline: none;
  border-color: #2d1f4f;
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(45, 31, 79, 0.1);
}

/* Submit Button */
.mmedia-dg-submit-btn {
  width: 100%;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, #2d1f4f 0%, #3d2f5f 100%);
  color: #ffffff !important;
  border: none;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(45, 31, 79, 0.3);
  font-family: inherit;
}

.mmedia-dg-submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(45, 31, 79, 0.4);
}

.mmedia-dg-submit-btn:disabled {
  opacity: 0.7;
  cursor: not-allowed;
}

/* Spinner */
.mmedia-dg-spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #ffffff;
  border-radius: 50%;
  animation: mmediaDgSpin 0.8s linear infinite;
  margin-right: 8px;
  vertical-align: middle;
}

@keyframes mmediaDgSpin {
  to {
    transform: rotate(360deg);
  }
}

/* Messages */
.mmedia-dg-message {
  padding: 1rem;
  border-radius: 8px;
  margin-top: 1rem;
  font-size: 0.875rem;
}

.mmedia-dg-message.success {
  background: #d4edda;
  color: #155724;
  border: 1px solid #c3e6cb;
}

.mmedia-dg-message.error {
  background: #f8d7da;
  color: #721c24;
  border: 1px solid #f5c6cb;
}

/* Success Screen */
.mmedia-dg-success-content {
  text-align: center;
}

.mmedia-dg-success-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto 1.5rem;
  background: linear-gradient(135deg, #2d1f4f 0%, #3d2f5f 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: #ffffff;
}

.mmedia-dg-success-content h3 {
  margin: 0 0 1rem 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: #1d1d1f;
}

.mmedia-dg-success-message {
  color: #86868b;
  margin-bottom: 2rem;
}

.mmedia-dg-download-btn {
  display: inline-block;
  padding: 1rem 2rem;
  background: linear-gradient(135deg, #2d1f4f 0%, #3d2f5f 100%);
  color: #ffffff !important;
  text-decoration: none;
  border-radius: 12px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(45, 31, 79, 0.3);
}

.mmedia-dg-download-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 25px rgba(45, 31, 79, 0.4);
}

/* Download Button Icon */
.mmedia-download-gate-trigger i.fa-download,
.btn i.fa-download {
  font-size: 0.7rem !important;
  margin-right: 0.375rem !important;
  position: relative !important;
  top: -1px !important;
}

/* Responsive */
@media (max-width: 600px) {
  .mmedia-dg-modal-content {
    margin: 50px 20px;
    padding: 2rem;
  }

  .mmedia-dg-modal-header h2 {
    font-size: 1.5rem;
  }
}
