/**
 * Public-facing styles for ZenithStack Lead Magnet Generator.
 *
 * These styles control the opt-in form that visitors see on the frontend.
 * They're designed to be minimal and easily overridable by theme styles.
 * All classes are prefixed with 'almg-' to avoid conflicts.
 *
 * @package AI_Lead_Magnet_Generator
 * @since   1.0.0
 */

/* ─── Opt-in Form Container ─────────────────────────────────────────────── */

.almg-optin-form {
  max-width: 520px;
  margin: 30px auto;
  padding: 32px;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  text-align: center;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

/* ─── Title & Description ───────────────────────────────────────────────── */

.almg-optin-title {
  font-size: 1.5em;
  font-weight: 700;
  margin: 0 0 8px 0;
  color: #1a202c;
  line-height: 1.3;
}

.almg-optin-description {
  font-size: 0.95em;
  color: #4a5568;
  margin: 0 0 22px 0;
  line-height: 1.6;
}

/* ─── Form Fields ───────────────────────────────────────────────────────── */

.almg-optin-fields {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.almg-optin-email {
  flex: 1;
  min-width: 200px;
  padding: 12px 16px;
  border: 2px solid #e2e8f0;
  border-radius: 8px;
  font-size: 15px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  background: #f7fafc;
}

.almg-optin-email:focus {
  border-color: #3182ce;
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(49, 130, 206, 0.15);
}

.almg-optin-submit {
  padding: 12px 24px;
  background: #0073aa;
  color: #ffffff;
  border: none;
  border-radius: 8px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease, transform 0.1s ease;
  white-space: nowrap;
}

.almg-optin-submit:hover {
  opacity: 0.9;
}

.almg-optin-submit:active {
  transform: scale(0.98);
}

.almg-optin-submit:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* ─── Status Messages ───────────────────────────────────────────────────── */

.almg-optin-message {
  margin-top: 15px;
  padding: 12px 16px;
  border-radius: 8px;
  font-size: 14px;
  line-height: 1.5;
}

.almg-optin-message.almg-success {
  background: #f0fff4;
  border: 1px solid #c6f6d5;
  color: #276749;
}

.almg-optin-message.almg-error {
  background: #fff5f5;
  border: 1px solid #fed7d7;
  color: #9b2c2c;
}

/* ─── Privacy Notice ────────────────────────────────────────────────────── */

.almg-optin-privacy {
  font-size: 12px;
  color: #a0aec0;
  margin: 16px 0 0 0;
}

.almg-optin-privacy a {
  color: #718096;
  text-decoration: underline;
}

/* ─── Powered By Branding (Free Tier) ───────────────────────────────────── */

.almg-optin-powered-by {
  font-size: 11px;
  color: #cbd5e0;
  margin: 8px 0 0 0;
  letter-spacing: 0.02em;
}

/* ─── Responsive ────────────────────────────────────────────────────────── */

@media (max-width: 480px) {
  .almg-optin-form {
    padding: 24px 20px;
    margin: 20px 10px;
    border-radius: 10px;
  }

  .almg-optin-fields {
    flex-direction: column;
  }

  .almg-optin-email,
  .almg-optin-submit {
    width: 100%;
  }

  .almg-optin-title {
    font-size: 1.3em;
  }
}
