/* ============================================================
   TEKEL HEALTH FOUNDATION — cpd.css
   CPD Programs page: accreditation panel, focus-area cards,
   note callouts, and the registration form.
   ============================================================ */

/* ── ACCREDITATION BADGE PANEL ── */
.cpd-badge-panel {
  background: linear-gradient(165deg, var(--c-mist) 0%, #DCEAEE 100%);
  border: 1px solid rgba(27,122,110,0.10);
  border-radius: var(--radius-lg);
  padding: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  box-shadow: var(--shadow-md);
}

.cpd-badge {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--c-border);
}

.cpd-badge svg {
  flex-shrink: 0;
  padding: 0.6rem;
  box-sizing: content-box;
  background: var(--c-white);
  border-radius: 14px;
  box-shadow: var(--shadow-sm);
}

.cpd-badge-label {
  font-family: var(--ff-display);
  font-weight: 700;
  color: var(--c-deep);
  line-height: 1.3;
}

.cpd-badge-facts {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.cpd-badge-facts li {
  font-size: 0.92rem;
  color: var(--c-slate);
}

.cpd-badge-facts strong {
  color: var(--c-teal);
  font-family: var(--ff-mono);
}

/* ── FOCUS AREA CARD GRID ── */
.cpd-focus-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.cpd-focus-card h3 {
  font-size: 1.05rem;
  margin-bottom: 0.6rem;
}

.cpd-focus-card p {
  font-size: 0.92rem;
}

.cpd-card-link {
  display: inline-flex;
  align-items: center;
  margin-top: 1.1rem;
  font-family: var(--ff-mono);
  font-size: 0.72rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--c-teal);
  transition: color 0.2s, transform 0.3s var(--ease-out);
}
.cpd-card-link:hover { color: var(--c-teal-light); transform: translateX(3px); }

/* ── DELIVERY / FEE NOTE BOXES ── */
.cpd-note-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.cpd-note-box {
  background: var(--c-white);
  border-radius: var(--radius-lg);
  border: 1px solid var(--c-border);
  border-left: 3px solid var(--c-teal);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

.cpd-note-box:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.cpd-note-box--gold { border-left-color: var(--c-gold); }

.cpd-note-box h4 {
  font-family: var(--ff-display);
  font-size: 1rem;
  color: var(--c-deep);
  margin-bottom: 0.5rem;
}

.cpd-note-box p {
  font-size: 0.88rem;
  line-height: 1.6;
}

/* ── FORM CARD ── */
.cpd-form-card {
  background: var(--c-white);
  border-radius: var(--radius-xl);
  padding: clamp(1.5rem, 4vw, 3rem);
  max-width: 880px;
  margin: 0 auto;
  box-shadow: 0 30px 70px rgba(0,0,0,0.32);
  position: relative;
  overflow: hidden;
}

.cpd-form-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--c-teal) 0%, var(--c-gold) 100%);
}

.cpd-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.65rem;
  background: #FDF0F0;
  border: 1px solid #EFC3C3;
  color: #8A2A2A;
  border-radius: var(--radius);
  padding: 0.9rem 1.2rem;
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 1.75rem;
  box-shadow: var(--shadow-sm);
}

.cpd-alert::before {
  content: '!';
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: #C24545;
  color: var(--c-white);
  font-family: var(--ff-mono);
  font-weight: 700;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 0.1rem;
}

/* Honeypot — hidden from real visitors, present for bots */
.cpd-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* ── FIELDSETS ── */
.cpd-fieldset {
  border: none;
  padding: 0;
  margin: 0 0 2.25rem;
}

.cpd-fieldset legend {
  font-family: var(--ff-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--c-teal);
  margin-bottom: 1.25rem;
  padding: 0;
}

.cpd-fieldset-hint {
  font-size: 0.85rem;
  color: var(--c-slate);
  margin: -0.75rem 0 1rem;
}

.cpd-fieldset--consent {
  padding-top: 1.5rem;
  border-top: 1px solid var(--c-border);
}

/* ── FORM ROWS / FIELDS ── */
.cpd-form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
  margin-bottom: 1.25rem;
}

.cpd-form-row--single { grid-template-columns: 1fr; }

.cpd-field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--c-ink);
  margin-bottom: 0.45rem;
}

.req { color: var(--c-gold); }

.cpd-field input[type="text"],
.cpd-field input[type="tel"],
.cpd-field input[type="email"],
.cpd-field select,
.cpd-field textarea {
  width: 100%;
  padding: 0.8rem 0.95rem;
  font-family: var(--ff-body);
  font-size: 0.95rem;
  color: var(--c-ink);
  background: var(--c-cream);
  border: 1.5px solid var(--c-border);
  border-radius: var(--radius);
  box-shadow: inset 0 1px 2px rgba(11,31,46,0.04);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.cpd-field input::placeholder,
.cpd-field textarea::placeholder { color: rgba(74,96,112,0.55); }

.cpd-field input:hover,
.cpd-field select:hover,
.cpd-field textarea:hover { border-color: rgba(27,122,110,0.35); }

.cpd-field input:focus,
.cpd-field select:focus,
.cpd-field textarea:focus {
  outline: none;
  background: var(--c-white);
  border-color: var(--c-teal);
  box-shadow: 0 0 0 4px rgba(27,122,110,0.14);
}

.cpd-field select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%234A6070' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 0.9rem center;
  background-size: 16px;
  padding-right: 2.5rem;
}

.cpd-field textarea { resize: vertical; min-height: 90px; }

/* ── CHECKBOX / RADIO GROUPS — custom-styled controls ── */
.cpd-checkbox-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem 1rem;
}

.cpd-checkbox,
.cpd-radio {
  display: flex;
  align-items: flex-start;
  gap: 0.7rem;
  font-size: 0.9rem;
  color: var(--c-ink);
  line-height: 1.5;
  cursor: pointer;
  padding: 0.55rem 0.65rem;
  border-radius: var(--radius);
  transition: background 0.2s ease;
}

.cpd-checkbox-grid .cpd-checkbox:hover,
.cpd-radio-row .cpd-radio:hover { background: var(--c-mist); }

.cpd-checkbox input[type="checkbox"],
.cpd-radio input[type="radio"] {
  appearance: none;
  -webkit-appearance: none;
  margin-top: 0.15rem;
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  cursor: pointer;
  border: 1.5px solid var(--c-border);
  background: var(--c-white);
  transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}

.cpd-checkbox input[type="checkbox"] { border-radius: 5px; }
.cpd-radio input[type="radio"] { border-radius: 50%; }

.cpd-checkbox input[type="checkbox"]:checked,
.cpd-radio input[type="radio"]:checked {
  border-color: var(--c-teal);
  background: linear-gradient(155deg, var(--c-teal-light) 0%, var(--c-teal) 70%);
  box-shadow: var(--shadow-teal);
}

.cpd-checkbox input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 9px;
  border: solid var(--c-white);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.cpd-radio input[type="radio"]:checked::after {
  content: '';
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--c-white);
}

.cpd-checkbox input:focus-visible,
.cpd-radio input:focus-visible {
  outline: 2px solid var(--c-teal);
  outline-offset: 2px;
}

.cpd-fieldset--consent .cpd-checkbox {
  font-size: 0.88rem;
  color: var(--c-slate);
}
.cpd-fieldset--consent .cpd-checkbox:hover { background: var(--c-mist); }

.cpd-radio-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.5rem;
  margin-top: 0.5rem;
}

.cpd-field-error {
  color: #B03A3A;
  font-size: 0.82rem;
  margin-top: 0.75rem;
}

.cpd-submit {
  width: 100%;
  justify-content: center;
  margin-top: 0.5rem;
}

/* ── RESPONSIVE ── */
@media (max-width: 860px) {
  .cpd-note-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
  .cpd-form-row,
  .cpd-checkbox-grid { grid-template-columns: 1fr; }
  .cpd-badge-panel { margin-top: 2rem; }
}
