/* Meezab Student Registration Form. Every rule is scoped to .mfc-reg so the
   form looks the same inside any WordPress theme. */

.mfc-reg {
  --mfc-primary: #0d3b66;
  --mfc-border: #cbd5e1;
  --mfc-bg-light: #f8fafc;
  --mfc-text: #1f2937;
  color: var(--mfc-text);
  padding: 24px 0;
}

.mfc-reg,
.mfc-reg * {
  box-sizing: border-box;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, sans-serif;
}

.mfc-reg .mfc-reg__card {
  max-width: 820px;
  margin: 0 auto;
  background: #ffffff;
  padding: 36px 40px;
  border-radius: 8px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  border-top: 6px solid var(--mfc-primary);
}

.mfc-reg .mfc-reg__header {
  text-align: center;
  margin-bottom: 24px;
  border-bottom: 2px solid #e2e8f0;
  padding-bottom: 16px;
}

.mfc-reg .mfc-reg__title {
  margin: 0;
  padding: 0;
  font-size: 22px;
  line-height: 1.3;
  letter-spacing: 1px;
  color: var(--mfc-primary);
  text-transform: uppercase;
}

.mfc-reg .mfc-reg__subtitle {
  margin: 6px 0 0;
  font-size: 15px;
  font-weight: 600;
  color: #64748b;
  letter-spacing: 0.5px;
}

.mfc-reg .mfc-reg__section {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  background: var(--mfc-bg-light);
  padding: 8px 12px;
  border-left: 4px solid var(--mfc-primary);
  margin: 24px 0 14px;
  letter-spacing: 0.5px;
}

/* Every item sits on a six-column grid: full = 6, half = 3, third = 2. */
.mfc-reg .mfc-reg__grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  column-gap: 16px;
}

.mfc-reg .mfc-reg__item--full {
  grid-column: span 6;
}

.mfc-reg .mfc-reg__item--half {
  grid-column: span 3;
}

.mfc-reg .mfc-reg__item--third {
  grid-column: span 2;
}

.mfc-reg .mfc-reg__block {
  margin-bottom: 14px;
}

@media (max-width: 650px) {
  .mfc-reg .mfc-reg__item--half,
  .mfc-reg .mfc-reg__item--third {
    grid-column: span 6;
  }
  .mfc-reg .mfc-reg__card {
    padding: 20px 16px;
  }
}

.mfc-reg .mfc-reg__group {
  display: flex;
  flex-direction: column;
  margin-bottom: 12px;
  min-width: 0;
}

.mfc-reg .mfc-reg__group > label,
.mfc-reg .mfc-reg__label {
  font-size: 13px;
  font-weight: 600;
  margin: 0 0 6px;
  color: #374151;
}

.mfc-reg .mfc-reg__group input[type="text"],
.mfc-reg .mfc-reg__group input[type="tel"],
.mfc-reg .mfc-reg__group input[type="email"],
.mfc-reg .mfc-reg__group input[type="date"],
.mfc-reg .mfc-reg__group input[type="number"],
.mfc-reg .mfc-reg__group select,
.mfc-reg .mfc-reg__group textarea {
  width: 100%;
  max-width: 100%;
  margin: 0;
  padding: 9px 12px;
  border: 1px solid var(--mfc-border);
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.4;
  color: var(--mfc-text);
  background-color: #fff;
  box-shadow: none;
  height: auto;
}

.mfc-reg .mfc-reg__group input:focus,
.mfc-reg .mfc-reg__group select:focus,
.mfc-reg .mfc-reg__group textarea:focus {
  outline: none;
  border-color: var(--mfc-primary);
  box-shadow: 0 0 0 2px rgba(13, 59, 102, 0.15);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--mfc-primary) 15%, transparent);
}

.mfc-reg .mfc-reg__group .mfc-reg__invalid {
  border-color: #ef4444;
}

.mfc-reg .mfc-reg__radios {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  margin-top: 6px;
}

.mfc-reg .mfc-reg__radios label {
  font-weight: normal;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  margin: 0;
}

.mfc-reg .mfc-reg__radios input {
  margin: 0;
}

.mfc-reg .mfc-reg__table-title {
  display: block;
  font-size: 13px;
}

.mfc-reg .mfc-reg__charges {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  margin: 6px 0 0;
}

.mfc-reg .mfc-reg__charges th,
.mfc-reg .mfc-reg__charges td {
  border: 1px solid #e2e8f0;
  padding: 6px 10px;
  text-align: left;
}

.mfc-reg .mfc-reg__charges th {
  background-color: #f1f5f9;
  font-weight: 600;
}

.mfc-reg .mfc-reg__terms {
  background: var(--mfc-bg-light);
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 12px 16px;
  max-height: 160px;
  overflow-y: auto;
  font-size: 12px;
  line-height: 1.5;
}

.mfc-reg .mfc-reg__list {
  margin-top: 6px;
  font-size: 13px;
  line-height: 1.5;
}

.mfc-reg .mfc-reg__list.mfc-reg__terms {
  margin-top: 0;
  font-size: 12px;
}

.mfc-reg .mfc-reg__list ol,
.mfc-reg .mfc-reg__list ul {
  margin: 0;
  padding-left: 18px;
}

.mfc-reg .mfc-reg__declaration {
  font-size: 13px;
  line-height: 1.5;
  margin: 0 0 12px;
}

.mfc-reg .mfc-reg__declaration p {
  margin: 0 0 8px;
  font-size: inherit;
  line-height: inherit;
}

.mfc-reg .mfc-reg__declaration p:last-child {
  margin-bottom: 0;
}

.mfc-reg .mfc-reg__sig {
  border: 1px dashed #94a3b8;
  background: #ffffff;
  border-radius: 4px;
  text-align: center;
  position: relative;
}

.mfc-reg .mfc-reg__sig.mfc-reg__invalid {
  border-color: #ef4444;
}

.mfc-reg .mfc-reg__canvas {
  width: 100%;
  height: 150px;
  cursor: crosshair;
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
  display: block;
}

/* More room for a finger signature on phones. */
@media (max-width: 650px) {
  .mfc-reg .mfc-reg__canvas {
    height: 210px;
  }
}

.mfc-reg .mfc-reg__sig-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 10px;
  border-top: 1px solid #e2e8f0;
  background: #f8fafc;
  font-size: 11px;
  color: #64748b;
}

.mfc-reg .mfc-reg__clear {
  background: none;
  border: none;
  color: #ef4444;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  padding: 2px 6px;
  box-shadow: none;
}

.mfc-reg .mfc-reg__hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.mfc-reg .mfc-reg__message {
  margin-top: 20px;
  padding: 12px 16px;
  border-radius: 4px;
  font-size: 14px;
  line-height: 1.5;
}

.mfc-reg .mfc-reg__message.is-success {
  background: #ecfdf5;
  border: 1px solid #10b981;
  color: #065f46;
}

.mfc-reg .mfc-reg__message.is-error {
  background: #fef2f2;
  border: 1px solid #ef4444;
  color: #991b1b;
}

.mfc-reg .mfc-reg__captcha {
  margin-top: 16px;
}

.mfc-reg .mfc-reg__pdf-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-top: 12px;
}

.mfc-reg .mfc-reg__pdf {
  display: inline-block;
  padding: 9px 18px;
  border-radius: 4px;
  background-color: var(--mfc-primary);
  color: #ffffff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.mfc-reg .mfc-reg__pdf:hover,
.mfc-reg .mfc-reg__pdf:focus {
  color: #ffffff;
  text-decoration: none;
  opacity: 0.9;
}

.mfc-reg .mfc-reg__pdf-note {
  font-size: 12px;
}

.mfc-reg .mfc-reg__actions {
  display: flex;
  gap: 12px;
  margin-top: 24px;
}

.mfc-reg .mfc-reg__submit {
  flex: 1;
  padding: 12px 20px;
  background-color: var(--mfc-primary);
  color: #ffffff;
  border: none;
  border-radius: 4px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s ease;
}

.mfc-reg .mfc-reg__submit:hover {
  background-color: #08233d;
  background-color: color-mix(in srgb, var(--mfc-primary) 75%, #000);
}

.mfc-reg .mfc-reg__submit:disabled {
  opacity: 0.7;
  cursor: wait;
}

@media print {
  .mfc-reg .mfc-reg__card {
    box-shadow: none;
    border-top: none;
    padding: 0;
    max-width: 100%;
  }
  .mfc-reg .mfc-reg__actions,
  .mfc-reg .mfc-reg__clear,
  .mfc-reg .mfc-reg__sig-controls span {
    display: none !important;
  }
  .mfc-reg .mfc-reg__item--half,
  .mfc-reg .mfc-reg__item--third {
    grid-column: span 3;
  }
  .mfc-reg .mfc-reg__terms {
    max-height: none;
    overflow: visible;
  }
}
