/* Overlay */
#consentModal {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 16px;
  z-index: 99991;
}

/* Modal */
#consentModal .cm-container {
  width: 100%;
  max-width: 850px;
  max-height: 80vh;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
}

/* Header */
#consentModal .cm-header {
  padding: 20px;
  border-bottom: 1px solid #e5e7eb;
  flex-shrink: 0;
}

#consentModal .cm-header h2 {
  margin: 0;
  font-size: 24px;
  color: #111827;
}

/* Content */
#consentModal .cm-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  line-height: 1.7;
  color: #374151;
  word-break: break-word;
}

/* Notice */
#consentModal .cm-notice {
  padding: 14px 20px;
  background: #f8fafc;
  border-top: 1px solid #e5e7eb;
  border-bottom: 1px solid #e5e7eb;
  font-size: 14px;
  color: #475569;
  flex-shrink: 0;
}

/* Footer */
#consentModal .cm-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  flex-shrink: 0;
}

/* Buttons */
#consentModal .cm-btn {
  border: none;
  border-radius: 8px;
  padding: 12px 18px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

#consentModal .cm-btn-secondary {
  background: #e5e7eb;
  color: #111827;
}

#consentModal .cm-btn-primary {
  background: #2563eb;
  color: #fff;
}

#consentModal .cm-btn-primary:disabled {
  background: #9ca3af;
  cursor: not-allowed;
}

/* Tablet */
@media (max-width: 768px) {
  #consentModal {
    padding: 12px;
  }

  #consentModal .cm-container {
    max-height: 95vh;
  }

  #consentModal .cm-header {
    padding: 16px;
  }

  #consentModal .cm-content {
    padding: 16px;
  }

  #consentModal .cm-notice {
    padding: 12px 16px;
    font-size: 13px;
  }

  #consentModal .cm-footer {
    padding: 16px;
  }

  #consentModal .cm-header h2 {
    font-size: 20px;
  }
}

/* Mobile */
@media (max-width: 576px) {
  #consentModal .cm-container {
    max-height: 95vh;
    border-radius: 10px;
  }

  #consentModal .cm-header h2 {
    font-size: 18px;
  }

  #consentModal .cm-content {
    font-size: 14px;
  }

  #consentModal .cm-footer {
    flex-direction: column;
    align-items: stretch;
  }

  #consentModal .cm-footer button {
    width: 100%;
  }

  #consentModal .cm-btn {
    min-height: 44px; /* mobile-friendly tap target */
  }
}