/* OK Salute Newsletter — stili shortcode.
   Tutti i selettori sono scoped su .oksnl-* per non collidere con il tema WP.
*/

.oksnl-container {
  max-width: 720px;
  margin: 0 auto;
  padding: 16px 0;
  color: #1f2937;
  /* Font-family esplicito (non `inherit`): se il tema o Gutenberg wrappa
     l'output shortcode dentro un <code>/<pre>, evitiamo che l'intera card
     erediti il monospace del blocco genitore. */
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
}

.oksnl-container,
.oksnl-container * {
  font-family: inherit;
}

.oksnl-container * {
  box-sizing: border-box;
}

.oksnl-card {
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, .06);
  padding: 28px;
  margin-bottom: 20px;
}

.oksnl-card h2 {
  margin-top: 0;
  color: #003c80;
  font-size: 20px;
}

.oksnl-lead {
  color: #4b5563;
  font-size: 14px;
  margin-bottom: 24px;
}

.oksnl-container label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 14px;
}

.oksnl-container input[type=email],
.oksnl-container input[type=text] {
  width: 100%;
  padding: 10px 12px;
  font-size: 15px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background: #fff;
}

.oksnl-container input[type=email]:focus,
.oksnl-container input[type=text]:focus {
  outline: 2px solid #0057b7;
  border-color: #0057b7;
}

.oksnl-consents {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 20px 0;
}

.oksnl-consent {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 12px;
  background: #f9fafb;
  border-radius: 8px;
  border-left: 3px solid #d1d5db;
}

.oksnl-consent-required {
  border-left-color: #dc2626;
  background: #fef2f2;
}

.oksnl-consent input[type=checkbox] {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.oksnl-consent-body {
  flex: 1;
  font-size: 14px;
}

.oksnl-consent-title {
  font-weight: 600;
  color: #111827;
  margin-bottom: 4px;
}

.oksnl-req-badge {
  font-size: 11px;
  color: #dc2626;
  margin-left: 6px;
  font-weight: 700;
  text-transform: uppercase;
}

.oksnl-consent-text {
  color: #4b5563;
  line-height: 1.45;
}

.oksnl-consent-text a {
  color: #0057b7;
  text-decoration: underline;
}

.oksnl-honeypot {
  position: absolute;
  left: -9999px;
  height: 0;
  overflow: hidden;
}

.oksnl-btn {
  display: inline-block;
  padding: 12px 24px;
  background: #0057b7;
  color: #fff;
  border: 0;
  border-radius: 6px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.oksnl-btn:hover:not(:disabled) {
  background: #003c80;
}

.oksnl-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.oksnl-btn-danger {
  background: #dc2626;
}

.oksnl-btn-danger:hover:not(:disabled) {
  background: #991b1b;
}

.oksnl-alert {
  padding: 14px 18px;
  border-radius: 6px;
  border-left: 4px solid;
  margin-bottom: 20px;
}

.oksnl-alert-success {
  background: #dcfce7;
  color: #14532d;
  border-left-color: #16a34a;
}

.oksnl-alert-error {
  background: #fee2e2;
  color: #7f1d1d;
  border-left-color: #dc2626;
}

.oksnl-alert-info {
  background: #dbeafe;
  color: #1e3a8a;
  border-left-color: #1e40af;
}

.oksnl-state-subscribed {
  color: #16a34a;
  font-weight: 600;
}

.oksnl-state-unsubscribed {
  color: #dc2626;
  font-weight: 600;
}

.oksnl-unsubscribe-box {
  margin-top: 28px;
  padding: 16px;
  background: #fef2f2;
  border-radius: 8px;
  border-left: 3px solid #dc2626;
}

.oksnl-unsubscribe-box[hidden] {
  display: none;
}

.oksnl-unsubscribe-title {
  font-weight: 600;
  color: #7f1d1d;
  margin-bottom: 6px;
}

.oksnl-unsubscribe-text {
  color: #4b5563;
  font-size: 14px;
  margin-bottom: 12px;
}

@media (max-width: 600px) {
  .oksnl-card {
    padding: 20px 16px;
  }
}
