/* SalaryPro Calculators — WordPress Plugin Styles */
.sp-wrap {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  max-width: 860px;
  margin: 0 auto;
  color: #1e293b;
  line-height: 1.6;
}
.sp-wrap * { box-sizing: border-box; }

/* Card */
.sp-card {
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 28px;
  margin-bottom: 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,.07);
}
.sp-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #0f172a;
  margin: 0 0 20px;
}

/* Grid */
.sp-grid { display: grid; gap: 16px; }
.sp-grid-2 { grid-template-columns: 1fr 1fr; }
.sp-grid-3 { grid-template-columns: 1fr 1fr 1fr; }
@media (max-width: 640px) {
  .sp-grid-2, .sp-grid-3 { grid-template-columns: 1fr; }
}

/* Fields */
.sp-field label {
  display: block;
  font-size: .82rem;
  font-weight: 600;
  color: #475569;
  margin-bottom: 5px;
}
.sp-field input,
.sp-field select {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 10px 12px;
  font-size: .92rem;
  color: #1e293b;
  background: #fff;
  transition: border .15s, box-shadow .15s;
  outline: none;
}
.sp-field input:focus,
.sp-field select:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59,130,246,.15);
}

/* Results */
.sp-result-primary {
  background: #2563eb;
  color: #fff;
  border-radius: 12px;
  padding: 22px 24px;
  margin-bottom: 16px;
}
.sp-result-primary .sp-result-label {
  font-size: .82rem;
  font-weight: 500;
  opacity: .8;
  margin-bottom: 4px;
}
.sp-result-primary .sp-result-value {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.2;
}
.sp-result-primary .sp-result-note {
  font-size: .78rem;
  opacity: .7;
  margin-top: 4px;
}

.sp-result-secondary {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 16px;
}
.sp-result-secondary .sp-result-label {
  font-size: .78rem;
  font-weight: 600;
  color: #64748b;
  margin-bottom: 4px;
}
.sp-result-secondary .sp-result-value {
  font-size: 1.3rem;
  font-weight: 700;
  color: #0f172a;
}
.sp-result-secondary .sp-result-note {
  font-size: .72rem;
  color: #94a3b8;
  margin-top: 2px;
}

/* Hint */
.sp-hint {
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 10px;
  padding: 16px 20px;
  font-size: .88rem;
  color: #1d4ed8;
  display: none;
}
.sp-hint.active { display: flex; align-items: center; gap: 10px; }

/* Info box */
.sp-info {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 20px 24px;
}
.sp-info h3 { font-size: 1rem; font-weight: 700; margin: 0 0 10px; color: #0f172a; }
.sp-info p { font-size: .85rem; color: #475569; margin: 0 0 8px; }
.sp-info p:last-child { margin-bottom: 0; }
.sp-info code {
  display: block;
  background: #e2e8f0;
  border-radius: 6px;
  padding: 10px 14px;
  font-family: monospace;
  font-size: .83rem;
  color: #334155;
  margin: 10px 0;
}

/* Alert */
.sp-alert {
  border-radius: 10px;
  padding: 14px 18px;
  font-size: .85rem;
  font-weight: 500;
  margin-bottom: 16px;
}
.sp-alert-green { background: #f0fdf4; border: 1px solid #bbf7d0; color: #15803d; }
.sp-alert-red   { background: #fef2f2; border: 1px solid #fecaca; color: #b91c1c; }

/* Table */
.sp-table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.sp-table th {
  background: #f1f5f9;
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  color: #475569;
  border-bottom: 2px solid #e2e8f0;
}
.sp-table td {
  padding: 10px 14px;
  border-bottom: 1px solid #f1f5f9;
  color: #334155;
}
.sp-table tr:last-child td { border-bottom: none; }
.sp-table .sp-winner { background: #eff6ff; color: #1d4ed8; font-weight: 700; }
.sp-table .sp-winner-b { background: #f0fdf4; color: #15803d; font-weight: 700; }

/* Two-column comparison */
.sp-compare-wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
@media (max-width: 640px) { .sp-compare-wrap { grid-template-columns: 1fr; } }

.sp-offer-a .sp-result-primary { background: #2563eb; }
.sp-offer-b .sp-result-primary { background: #059669; }
.sp-offer-a .sp-card { border-top: 3px solid #2563eb; }
.sp-offer-b .sp-card { border-top: 3px solid #059669; }

/* Related links */
.sp-related {
  border-top: 1px solid #e2e8f0;
  margin-top: 32px;
  padding-top: 24px;
}
.sp-related h4 { font-size: .95rem; font-weight: 700; color: #0f172a; margin: 0 0 14px; }
.sp-related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 10px;
}
.sp-related-grid a {
  display: block;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: .83rem;
  font-weight: 600;
  color: #2563eb;
  text-decoration: none;
  transition: background .15s, border-color .15s;
}
.sp-related-grid a:hover { background: #eff6ff; border-color: #93c5fd; }
