/* FASA Forms shared authority */

:root {
  --crm-bg: #d7e3ef;
  --crm-bg-strong: #c4d4e6;
  --crm-surface: #eef4fa;
  --crm-card: #ffffff;
  --crm-border: #789abc;
  --crm-border-strong: #5f83a8;
  --crm-text: #0c2743;
  --crm-text-muted: #445f7a;
  --crm-primary: #1a5d96;
  --crm-primary-dark: #123f67;
  --crm-shadow: 0 10px 20px rgba(12, 33, 53, 0.08);
  --crm-shadow-lg: 0 18px 34px rgba(12, 33, 53, 0.12);
  --crm-radius-xl: 6px;
  --crm-radius-lg: 6px;
  --crm-radius-md: 6px;
  --crm-radius-sm: 6px;
  --crm-max-width: 825px;
  --crm-label-bg: #c8dbef;
  --crm-section-band: #bed2e8;
  --crm-section-surface: #dce9f5;
  --crm-section-surface-strong: #cedfef;
  --crm-section-header: #9fbdd9;
  --crm-font: Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body.crm-body,
.page {
  min-height: 100vh;
  padding: 18px 12px 28px;
  font-family: var(--crm-font);
  color: var(--crm-text);
  background:
    radial-gradient(circle at top, rgba(255, 255, 255, 0.58), transparent 34%),
    linear-gradient(180deg, #dde6ef 0%, #ccd7e3 28%, #c0ccd8 100%);
  background-repeat: no-repeat, no-repeat;
  background-attachment: fixed, fixed;
  background-size:
    100% 24rem,
    100% 100%;
}

body.fasa-shell {
  min-height: 100vh;
  font-family: var(--crm-font);
  color: var(--crm-text);
  background: #d9e6f2;
}

.main-content-wrap > .crm-shell,
.main-content-wrap > .crm-body,
.main-content-wrap > .page {
  margin-top: 14px;
}

body.crm-body a,
.page a,
.crm-shell a {
  color: var(--crm-primary);
  text-decoration: none;
}

body.crm-body a:hover,
.page a:hover,
.crm-shell a:hover {
  text-decoration: underline;
}

.crm-shell,
.page .shell {
  max-width: var(--crm-max-width);
  min-width: 0;
  margin: 0 auto;
  border: 1px solid rgba(24, 73, 116, 0.88);
  border-radius: var(--crm-radius-lg);
  background:
    linear-gradient(
      135deg,
      rgba(27, 82, 132, 0.14),
      rgba(255, 255, 255, 0) 42%
    ),
    linear-gradient(180deg, #ffffff 0%, #edf4fb 100%);
  box-shadow: 0 20px 36px rgba(12, 33, 53, 0.13);
  overflow: hidden;
}

.crm-header,
.page .header {
  padding: 18px 20px 0;
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.98) 0%,
    rgba(237, 244, 251, 0.96) 100%
  );
}

.crm-header__top,
.page .header-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px 18px;
  padding-bottom: 12px;
}

.crm-header__top > :first-child,
.page .header-top > :first-child {
  flex: 1 1 100%;
  width: 100%;
}

.crm-kicker,
.page .kicker {
  margin: 0 0 4px;
  color: var(--crm-text-muted);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-align: center;
}

.crm-header h1,
.page h1,
.crm-title {
  margin: 0 0 8px;
  color: var(--crm-text);
  font-size: clamp(1.7rem, 2.8vw, 2.35rem);
  line-height: 1.04;
  letter-spacing: -0.03em;
  text-align: center;
}

.crm-subtitle,
.page .subtitle,
.crm-title + .crm-note {
  max-width: 720px;
  margin: 0 auto;
  color: var(--crm-text-muted);
  font-size: 0.92rem;
  line-height: 1.45;
  text-align: center;
}

.crm-header__links,
.page .links,
.crm-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  align-items: center;
  padding-top: 4px;
}

.crm-header__links,
.page .links {
  width: 100%;
}

.crm-header__links a,
.page .links a,
.crm-links a,
.page .btn,
.crm-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 15px;
  border: 1px solid var(--crm-border-strong);
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, #ffffff 0%, #f5f8fc 100%);
  color: var(--crm-text);
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.crm-header__links a:hover,
.page .links a:hover,
.crm-links a:hover,
.page .btn:hover,
.crm-button:hover,
.crm-header__links a:focus-visible,
.page .links a:focus-visible,
.crm-links a:focus-visible,
.page .btn:focus-visible,
.crm-button:focus-visible {
  background: linear-gradient(180deg, #ffffff 0%, #edf4fb 100%);
  text-decoration: none;
}

.page .btn.primary,
.crm-button--primary {
  border-color: var(--crm-primary-dark);
  background: linear-gradient(
    180deg,
    var(--crm-primary),
    var(--crm-primary-dark)
  );
  color: #ffffff;
  box-shadow: 0 6px 14px rgba(26, 76, 122, 0.25);
}

.page .btn.primary:hover,
.crm-button--primary:hover {
  background: linear-gradient(180deg, #2269a7, #18486f);
}

.page .btn.primary:disabled,
.crm-button--primary:disabled,
.crm-submit--pending {
  background: #7b8794;
  border-color: #667381;
  box-shadow: none;
  color: #ffffff;
  cursor: wait;
  opacity: 0.78;
}

.page .btn.primary:disabled:hover,
.crm-button--primary:disabled:hover,
.crm-submit--pending:hover {
  background: #7b8794;
}

/* Visible focus ring for keyboard users on primary buttons */
.crm-button--primary:focus-visible {
  box-shadow: 0 0 0 3px rgba(27, 82, 132, 0.14);
  outline: none;
}

.crm-progress,
.page .progress {
  padding: 12px 14px 14px;
  border-top: 1px solid var(--crm-border);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.55),
    rgba(213, 224, 238, 0.55)
  );
}

.crm-progress__summary,
.page .progress-meta,
.actions-meta,
.crm-actions__meta {
  margin-bottom: 8px;
  color: var(--crm-text);
  font-size: 0.88rem;
  font-weight: 800;
  text-align: center;
}

.crm-progress__steps,
.page .progress-steps {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 12px;
  margin: 0 0 10px;
  padding: 0;
  list-style: none;
  color: var(--crm-text-muted);
  font-size: 0.86rem;
}

.crm-progress__steps li,
.page .progress-steps li {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}

.crm-progress__steps span,
.page .progress-steps span {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 1px solid var(--crm-border-strong);
  border-radius: 999px;
  background: #ffffff;
}

.crm-progress__steps .is-active,
.page .progress-steps .active {
  color: var(--crm-text);
}

.crm-progress__steps .is-active span,
.page .progress-steps .active span {
  border-color: var(--crm-primary);
  background: var(--crm-primary);
  color: #ffffff;
}

.crm-progress__bar,
.page .progressbar {
  width: 100%;
  height: 5px;
  border-radius: 999px;
  background: #dce7f2;
  overflow: hidden;
}

.crm-progress__fill,
.page .progressbar > i {
  display: block;
  height: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--crm-primary), #68a5e3);
}

.crm-form,
.page .form-wrap {
  padding: 18px 20px 0;
}

.crm-card,
.page .card {
  margin: 0 0 16px;
  border: 1px solid rgba(88, 117, 147, 0.74);
  border-radius: var(--crm-radius-lg);
  background: linear-gradient(180deg, #eaf2fb 0%, #dfeaf6 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.68),
    0 14px 24px rgba(12, 33, 53, 0.115);
  overflow: hidden;
}

.crm-card:last-child,
.page .card:last-child {
  margin-bottom: 10px;
}

.crm-card__header,
.page .card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 15px;
  border-bottom: 1px solid rgba(24, 73, 116, 0.34);
  background: linear-gradient(180deg, #a9c4de 0%, #96b6d3 100%);
}

.crm-card__header h2,
.page .card-head h2,
.page .subsection-title,
.crm-section-title {
  margin: 0;
  color: #133f66;
  font-size: 1.05rem;
  line-height: 1.2;
  letter-spacing: -0.015em;
  text-align: center;
}

.crm-card__toggle,
.page .card-toggle {
  border: 0;
  background: transparent;
  color: #6d88a3;
  font-size: 0.95rem;
  line-height: 1;
  cursor: pointer;
  display: none;
}

.crm-card__body,
.page .card-body {
  min-width: 0;
  padding: 15px 17px 17px;
  border-top: 1px solid rgba(255, 255, 255, 0.52);
  background: linear-gradient(
    180deg,
    #e4eef8 0%,
    #d8e6f3 100%
  );
}

.crm-form-card {
  padding: 18px 18px 18px;
  background: linear-gradient(180deg, #dde9f5 0%, #d1e0ef 100%);
}

.crm-form-card .crm-section-title {
  margin-bottom: 12px;
}

.home-group-list {
  max-width: 840px;
  margin: 0 auto;
  padding-left: 0;
  list-style: none;
}

.home-group-list li + li {
  margin-top: 8px;
}

.home-group-list__item-center {
  width: fit-content;
  max-width: 100%;
  height: auto;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.home-group-list--pairs li {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) auto;
  gap: 10px 14px;
  align-items: center;
  justify-items: center;
  padding: 10px 12px;
  border: 1px solid rgba(110, 144, 178, 0.46);
  border-radius: var(--crm-radius-md);
  background: linear-gradient(180deg, rgba(232, 241, 250, 0.98), #e3edf8);
  box-shadow: 0 10px 18px rgba(12, 33, 53, 0.09);
  transition: all 0.2s ease;
}
.home-group-list--pairs li:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 20px rgba(12, 33, 53, 0.08);
}

.home-group-list--pairs li + li {
  margin-top: 10px;
}

.home-group-list--pairs strong {
  font-size: 0.98rem;
  line-height: 1.2;
}

.home-group-list--pairs .crm-link-pair {
  justify-content: flex-end;
  margin-top: 0;
}

@media (max-width: 640px) {
  .home-group-list--pairs li {
    grid-template-columns: 1fr;
    align-items: start;
  }

  .home-group-list--pairs .crm-link-pair {
    justify-content: flex-start;
  }

  .crm-shell--index {
    padding: 8px;
    gap: 8px;
  }

  .crm-shell--index > .crm-card:first-child {
    padding: 13px 11px 11px;
  }

  .crm-shell--index .crm-form-card {
    padding: 10px;
  }

  .crm-shell--index .home-group-list--pairs li {
    grid-template-columns: 1fr;
    justify-items: stretch;
  }

  .crm-shell--index .home-group-list--pairs .crm-link-pair,
  .crm-shell--index .home-group-list__item-center .crm-link-pair {
    justify-content: stretch;
  }
}

.crm-grid,
.page .grid,
.page .inline-fields {
  display: grid;
  gap: 10px;
}

.crm-grid--2,
.page .grid-2,
.page .inline-2,
.crm-choice-grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.crm-grid--3,
.page .grid-3,
.page .inline-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.crm-grid-span-2 {
  grid-column: 1 / -1;
}

.crm-choice-grid {
  display: grid;
  gap: 10px;
}

.crm-choice-card,
.choice-row,
.page .choice-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-height: 36px;
  padding: 6px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  font-size: 0.9rem;
  font-weight: 700;
}

.crm-choice-card input,
.choice-row input,
.page .choice-row input,
.crm-checkbox input {
  width: 16px;
  height: 16px;
  margin-top: 2px;
  accent-color: var(--crm-primary);
}

.crm-fieldset,
.page fieldset {
  margin: 0;
  padding: 0;
  border: 0;
  min-width: 0;
}

.crm-field {
  display: grid;
  grid-template-columns: minmax(120px, 160px) minmax(0, 1fr);
  gap: 4px 10px;
  align-items: start;
}

.page .field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
  max-width: 100%;
}

.page
  .field
  input:not([type="file"]):not([type="radio"]):not([type="checkbox"]),
.page .field select,
.page .field textarea {
  min-height: 29px;
  height: 29px;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;
}

.crm-field label,
.crm-field legend,
.page label,
.page legend {
  margin: 0;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.3;
  color: #26435f;
}

.crm-field label,
.crm-field legend {
  padding: 2px 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.crm-inline-choices,
.crm-checkbox {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  min-height: 30px;
  padding: 0;
  font-size: 0.88rem;
}

.crm-inline-controls {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  min-width: 0;
}

.crm-inline-controls > input,
.crm-inline-controls > select,
.crm-inline-controls > textarea {
  flex: 1 1 auto;
  min-width: 0;
}

.crm-help--inline {
  grid-column: 2 / -1;
}

.crm-inline-choices label,
.crm-checkbox {
  font-weight: 600;
}

.crm-inline-choices label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="search"],
input[type="password"],
select,
textarea,
.page input[type="text"],
.page input[type="email"],
.page input[type="tel"],
.page input[type="number"],
.page input[type="date"],
.page input[type="search"],
.page input[type="password"],
.page select,
.page textarea {
  min-height: 34px;
  padding: 7px 11px;
  border: 1px solid var(--crm-border-strong);
  border-radius: var(--crm-radius-sm);
  background: #fcfdff;
  box-shadow:
    inset 0 1px 0 rgba(19, 63, 102, 0.08),
    0 1px 0 rgba(255, 255, 255, 0.55);
  color: var(--crm-text);
  font: inherit;
  font-size: 0.92rem;
  line-height: 1.4;
}

input:hover,
select:hover,
textarea:hover,
.page input:hover,
.page select:hover,
.page textarea:hover {
  border-color: #5f83a8;
}

textarea,
.page textarea {
  resize: vertical;
  min-height: 88px;
}

input[type="file"],
.page input[type="file"] {
  padding: 7px 9px;
}

select {
  appearance: auto;
}

input[readonly],
.page input[readonly] {
  background: #f6f9fc;
}

input:focus,
select:focus,
textarea:focus,
.page input:focus,
.page select:focus,
.page textarea:focus {
  outline: none;
  border-color: var(--crm-primary);
  box-shadow: 0 0 0 3px rgba(31, 95, 151, 0.16);
}


.crm-help,
.crm-note,
.page .note {
  margin: 0;
  color: var(--crm-text-muted);
  font-size: 0.84rem;
  line-height: 1.45;
}

.crm-prefix-availability {
  color: #2c5f3d;
  font-weight: 600;
}

.crm-prefix-availability--unavailable {
  color: #9b2c2c;
}


.crm-checkbox-label {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 0.5rem;
  text-align: left;
  white-space: normal;
}

.crm-checkbox-label input {
  flex: 0 0 auto;
}

.crm-address-grid {
  grid-template-columns: minmax(0, 1fr) !important;
}

.crm-prefix-choice-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

@media (max-width: 760px) {
  .crm-prefix-choice-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

.crm-note,
.page .note {
  padding: 12px 14px;
  border: 1px solid #a6c0da;
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, #e8f1fa 0%, #dde9f5 100%);
  overflow-wrap: anywhere;
}

.crm-label {
  display: block;
  margin-bottom: 6px;
  color: var(--crm-text-muted);
  font-size: 0.76rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.crm-payment-summary {
  display: grid;
  grid-template-columns: minmax(180px, 240px) 1fr;
  gap: 0.6rem;
  margin-bottom: 10px;
}

.crm-payment-summary,
.crm-payment-summary > * {
  min-width: 0;
}

.crm-payment-summary__amount {
  width: 100%;
  max-width: 100%;
  padding: 12px 14px;
  border: 1px solid #c4d7ea;
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, #fbfdff 0%, #eef4fb 100%);
  overflow-wrap: anywhere;
}

.crm-payment-summary__amount strong {
  display: block;
  font-size: 1.32rem;
  letter-spacing: -0.03em;
}

.crm-bank-grid {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 6px 8px;
  margin: 0;
  font-size: 0.86rem;
}

.crm-bank-grid dt {
  font-weight: 700;
  color: #36516d;
}

.crm-bank-grid dd {
  margin: 0;
}

.crm-payment-reference-text {
  color: #b42318;
  font-weight: 800;
}

.table-wrap {
  overflow-x: auto;
}

.challenges {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 0.84rem;
}

.challenges th,
.challenges td {
  padding: 6px;
  border: 1px solid #d4deea;
  vertical-align: top;
}

.challenges th {
  background: #f3f7fc;
  text-align: left;
}

.crm-actions,
.page .actions {
  position: sticky;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  padding: 12px 16px;
  border-top: 1px solid var(--crm-border);
  background: linear-gradient(
    180deg,
    rgba(255, 255, 255, 0.94) 0%,
    rgba(244, 248, 252, 0.98) 100%
  );
  box-shadow: 0 -8px 18px rgba(12, 33, 53, 0.055);
  backdrop-filter: blur(6px);
}

.crm-actions__buttons,
.page .buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

.fasa-honeypot,
.honeypot,
.sr-only {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

input.fasa-honeypot,
input.honeypot {
  position: absolute !important;
  left: -9999px !important;
  top: auto !important;
  width: 1px !important;
  min-width: 1px !important;
  max-width: 1px !important;
  height: 1px !important;
  min-height: 1px !important;
  padding: 0 !important;
  margin: 0 !important;
  opacity: 0 !important;
  pointer-events: none !important;
}

.hidden,
[hidden] {
  display: none !important;
}

.crm-gap-top {
  margin-top: 8px;
}

.crm-title {
  margin-bottom: 12px;
}

.crm-title + .crm-note {
  max-width: 700px;
  margin: 0 auto 14px;
}

.crm-links {
  margin-top: 4px;
}

.crm-shell > .crm-card:first-child {
  margin-top: 0;
  background:
    linear-gradient(135deg, rgba(31, 95, 151, 0.1), rgba(255, 255, 255, 0) 48%),
    linear-gradient(180deg, #ffffff 0%, #f7fbff 100%);
}

.crm-shell > .crm-card:first-child .crm-title,
.crm-shell > .crm-card:first-child .crm-section-title {
  text-align: center;
}

.crm-form-card .crm-note {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.home-group-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 46px;
  padding: 10px 12px;
  border: 1px solid #d3deea;
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, #ffffff 0%, #f5f8fc 100%);
  font-weight: 700;
  text-decoration: none;
}

.home-group-list a::after {
  content: "Open";
  flex: 0 0 auto;
  padding: 2px 7px;
  border: 1px solid #c2d4e6;
  border-radius: 999px;
  background: #eef5fd;
  color: #36516d;
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.home-group-list a:hover,
.home-group-list a:focus-visible {
  background: linear-gradient(180deg, #ffffff 0%, #edf4fb 100%);
  border-color: var(--crm-border-strong);
}

.crm-shell > .crm-card:first-child .crm-links {
  margin-top: 10px;
}

.crm-help--top14 {
  margin-top: 14px;
}

.field--mt16 {
  margin-top: 16px;
}

.crm-progress__fill--20,
.progress-fill-20 {
  width: 20%;
}

.crm-progress__fill--25,
.progress-fill-25 {
  width: 25%;
}

/* Mobile landscape/tablet form layout. */
@media (max-width: 780px) {
  body.crm-body,
  .page {
    padding: 8px 0 16px;
    margin-left: 0;
    margin-right: 0;
  }

  .crm-header,
  .page .header {
    padding: 10px 10px 0;
  }

  .crm-header__top,
  .page .header-top {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }

  .crm-progress,
  .page .progress {
    padding: 10px;
  }

  .crm-form,
  .page .form-wrap {
    padding: 10px 10px 0;
  }

  .crm-card,
  .page .card {
    margin-bottom: 10px;
    margin-left: 0;
    margin-right: 0;
  }

  .crm-card__header,
  .crm-card__body,
  .page .card-head,
  .page .card-body,
  .crm-form-card {
    padding: 10px 11px;
  }

  .crm-grid--2,
  .crm-grid--3,
  .page .grid-2,
  .page .grid-3,
  .page .inline-2,
  .page .inline-3,
  .crm-choice-grid--2,
  .crm-payment-summary,
  .crm-bank-grid {
    grid-template-columns: 1fr;
  }

  .crm-field {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .crm-help--inline {
    grid-column: 1 / -1;
  }

  .crm-field label,
  .crm-field legend {
    padding: 0;
    border: 0;
    background: transparent;
  }

  .crm-actions,
  .page .actions {
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
  }

  .main-content-wrap > .crm-shell,
  .main-content-wrap > .crm-body,
  .main-content-wrap > .page {
    margin-top: 10px;
    margin-left: 0;
    margin-right: 0;
  }

  .crm-actions__buttons,
  .page .buttons,
  .crm-links,
  .crm-header__links,
  .page .links {
    width: 100%;
  }

  .crm-header__links a,
  .page .links a,
  .crm-links a,
  .page .btn,
  .crm-button {
    flex: 1 1 auto;
  }

  .home-group-list a {
    align-items: flex-start;
    padding: 10px;
  }

  .crm-link-pair {
    flex-direction: column;
    align-items: stretch;
  }

  .crm-link-pair a {
    width: 100%;
  }

  .home-group-list a::after {
    font-size: 0.68rem;
  }

  .crm-header h1,
  .page h1,
  .crm-title {
    font-size: 1.65rem;
  }
}

@media (max-width: 425px) {
  body.crm-body,
  .page,
  .crm-shell,
  .page .shell,
  .crm-card,
  .page .card,
  .crm-form-card,
  .crm-header,
  .page .header,
  .crm-card__header,
  .crm-card__body,
  .page .card-head,
  .page .card-body,
  .crm-form,
  .page .form-wrap,
  .crm-progress,
  .page .progress,
  .crm-actions,
  .page .actions {
    margin-left: 0;
    margin-right: 0;
    padding-left: 0;
    padding-right: 0;
  }
}

.crm-declaration-grid {
  margin-top: 10px;
}

.crm-grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.crm-warning {
  background: #fff8ec;
  border-color: #ecd5a7;
}

.crm-summary {
  padding: 10px 12px;
  border: 1px solid #d9e5f1;
  border-radius: var(--crm-radius-sm);
  background: #f7fafc;
}

.crm-table-wrap {
  overflow-x: auto;
}

.crm-table {
  width: 100%;
  min-width: 470px;
  border-collapse: collapse;
  font-size: 0.82rem;
}

.crm-table th,
.crm-table td {
  padding: 5px;
  border: 1px solid var(--crm-border);
  vertical-align: top;
}

.crm-table th {
  background: #f3f7fc;
  text-align: left;
}

.crm-mini-table input,
.crm-mini-table select {
  padding: 4px 6px;
}

/* Litter Registration: give the active kitten rows a clear, compact working layout. */
.crm-litter-kitten-table {
  min-width: 0;
  table-layout: fixed;
}

.crm-litter-kitten-table th:first-child,
.crm-litter-kitten-table td:first-child {
  width: 4.25rem;
  text-align: center;
}

.crm-litter-kitten-table th:nth-child(2),
.crm-litter-kitten-table td:nth-child(2) {
  width: 10.5rem;
}

.crm-litter-kitten-table td:first-child {
  color: #0b5f9e;
  font-weight: 700;
  vertical-align: middle;
}

.crm-litter-kitten-table td:nth-child(2) {
  vertical-align: middle;
}

.crm-litter-kitten-table input,
.crm-litter-kitten-table select {
  box-sizing: border-box;
  min-width: 0;
  width: 100%;
}

.crm-litter-parent-grid {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.crm-litter-parent-section {
  border-top: 0;
  padding-top: 0;
}

.crm-litter-parent-section h3 {
  color: #0b5f9e;
  font-size: 0.95rem;
  margin: 0 0 0.35rem;
}

.crm-litter-parent-section .grid {
  gap: 0.5rem 0.65rem;
}

.crm-litter-date-grid {
  grid-column: 1 / -1;
}

@media (max-width: 34rem) {
  .crm-litter-parent-grid {
    grid-template-columns: 1fr;
  }

  .crm-litter-kitten-table th:nth-child(2),
  .crm-litter-kitten-table td:nth-child(2) {
    width: 8.5rem;
  }
}

.crm-subsection-title {
  margin: 10px 0 4px;
  color: #1a3f63;
  font-size: 0.92rem;
  line-height: 1.2;
  font-weight: 700;
}

.crm-subsection-title--first {
  margin-top: 12px;
  font-size: 0.97rem;
}

.crm-shell--compact {
  max-width: 825px;
}

.crm-shell--membership-wide {
  max-width: 825px;
}

.crm-address-inline-row {
  grid-template-columns: minmax(0, 1fr);
  gap: 10px;
  align-items: end;
}

.crm-address-inline-controls {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(7rem, 1fr) minmax(7rem, 1fr);
  gap: 8px;
  align-items: end;
  grid-column: 1;
}

.crm-address-inline-controls .crm-field {
  grid-template-columns: minmax(0, 1fr);
}

.crm-address-inline-controls .crm-field label {
  min-height: 0;
  padding: 0;
}

.crm-shell--compact .crm-header {
  padding: 10px 12px 0;
}

.crm-shell--compact .crm-header__top {
  gap: 8px;
  padding-bottom: 8px;
}

.crm-shell--compact .crm-kicker {
  font-size: 10px;
}

.crm-shell--compact .crm-header h1 {
  margin-bottom: 4px;
  font-size: clamp(1.48rem, 2.1vw, 2rem);
}

.crm-shell--compact .crm-subtitle {
  font-size: 0.84rem;
  line-height: 1.35;
}

.crm-shell--compact .crm-header__links {
  gap: 8px;
  font-size: 0.82rem;
}


.main-content-wrap > .crm-shell.crm-shell--index {
  margin-top: 14px;
}

.crm-shell--index > .crm-card {
  margin: 0;
}

.crm-shell--index > .crm-card:first-child {
  padding: 16px 18px 14px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.96) 0%, rgba(239, 245, 252, 0.94) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.78),
    0 18px 32px rgba(12, 33, 53, 0.14);
}

.crm-shell--index > .crm-card:first-child .crm-title {
  margin-bottom: 10px;
  font-size: clamp(1.85rem, 3.4vw, 2.45rem);
  letter-spacing: -0.04em;
}

.crm-shell--index > .crm-card:first-child .crm-note {
  max-width: 640px;
  padding: 10px 14px;
  background: linear-gradient(180deg, #edf5fd 0%, #dfeaf6 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
}

.crm-shell--index > .crm-card:first-child .crm-links {
  gap: 8px;
  margin-top: 10px;
}

.crm-shell--index > .crm-card:first-child .crm-links a {
  min-height: 34px;
  padding: 0 13px;
  font-size: 0.88rem;
}

.crm-shell--index .crm-form-card {
  padding: 11px 13px 13px;
  background:
    linear-gradient(180deg, rgba(235, 244, 252, 0.96) 0%, rgba(212, 227, 242, 0.98) 100%);
}

.crm-shell--index .crm-section-title {
  margin-bottom: 8px;
  font-size: 1rem;
  letter-spacing: -0.02em;
}

.crm-shell--index .crm-form-card > .crm-note {
  max-width: 560px;
  margin: 0 auto 10px;
  padding: 9px 12px;
  font-size: 0.8rem;
}

.crm-shell--index .home-group-list {
  max-width: none;
}

.crm-shell--index .home-group-list--pairs li {
  grid-template-columns: minmax(0, 1.25fr) auto;
  gap: 8px 12px;
  padding: 9px 11px;
  border-color: rgba(120, 150, 180, 0.48);
  background:
    linear-gradient(180deg, rgba(247, 250, 254, 0.98) 0%, rgba(228, 238, 249, 0.96) 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.84),
    0 10px 18px rgba(12, 33, 53, 0.08);
}

.crm-shell--index .home-group-list--pairs strong {
  display: block;
  color: #183653;
  font-size: 0.94rem;
}

.crm-shell--index .home-group-list--pairs .crm-link-pair {
  gap: 0.3rem;
}

.crm-shell--index .home-group-list__item-center {
  min-width: min(100%, 280px);
}

.crm-shell--index .home-group-list__item-center .crm-link-pair {
  justify-content: center;
}

.crm-shell--index .home-group-list:not(.home-group-list--pairs) {
  display: grid;
  gap: 6px;
}

.crm-shell--index .home-group-list:not(.home-group-list--pairs) li + li {
  margin-top: 0;
}

.crm-shell--index .home-group-list a {
  min-height: 40px;
  padding: 8px 11px;
  font-size: 0.88rem;
}

.crm-link-pair {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.65rem;
  align-items: center;
  margin-top: 0.2rem;
}

.crm-link-pair--center-fit {
  width: fit-content;
  max-width: 100%;
  height: auto;
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.crm-link-pair a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 0.18rem 0.7rem;
  border: 1px solid rgba(127, 159, 190, 0.72);
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, #ffffff 0%, #f4f8fc 100%);
  color: var(--crm-text);
  font-size: 0.82rem;
  font-weight: 700;
  text-decoration: none;
}

.crm-link-pair a:hover,
.crm-link-pair a:focus-visible {
  background: linear-gradient(180deg, #ffffff 0%, #edf4fb 100%);
  text-decoration: none;
}

.crm-shell--index .forms-hub-hero,
.crm-shell--index .forms-hub-section {
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.crm-shell--index .forms-hub-section__header .crm-section-title::before {
  content: "";
  display: inline-block;
  width: 0.28rem;
  height: 0.85rem;
  margin: 0 0.42rem 0 0;
  background: var(--crm-primary);
  vertical-align: -0.08rem;
}

.crm-shell--index .forms-hub-section__header p {
  margin: 0;
  color: var(--crm-text-muted);
  font-size: 0.78rem;
  line-height: 1.25;
}

.crm-shell--index .forms-hub-list,
.crm-shell--index .forms-hub-support-list {
  display: grid;
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
}

.crm-shell--index .forms-hub-row:first-child {
  border-top-color: rgba(28, 70, 109, 0.38);
}

.crm-shell--index .forms-hub-row__copy {
  min-width: 0;
}

.crm-shell--index .forms-hub-row__copy strong {
  display: block;
  color: var(--crm-text);
  font-size: 0.95rem;
  line-height: 1.15;
}

.crm-shell--index .forms-hub-row__copy span {
  display: block;
  margin-top: 0.08rem;
  color: var(--crm-text-muted);
  font-size: 0.75rem;
  line-height: 1.2;
}

.crm-shell--index .forms-hub-row:hover {
  border-top-color: rgba(28, 70, 109, 0.5);
  background: rgba(255, 255, 255, 0.62);
}

.crm-shell--index .forms-hub-row--portal {
  margin-top: 0.28rem;
  border: 1px solid rgba(28, 70, 109, 0.46);
  background: linear-gradient(90deg, rgba(214, 231, 246, 0.78), rgba(245, 249, 253, 0.8));
}

.crm-shell--index .forms-hub-row--portal:hover {
  background: linear-gradient(90deg, rgba(205, 225, 243, 0.94), rgba(255, 255, 255, 0.92));
}

.crm-shell--index .forms-hub-action,
.crm-shell--index .forms-hub-support-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  padding: 0.26rem 0.72rem;
  border: 1px solid rgba(92, 128, 164, 0.72);
  border-radius: 0;
  background: rgba(255, 255, 255, 0.72);
  color: var(--crm-text);
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.12;
  text-decoration: none;
  white-space: nowrap;
}

.crm-shell--index .forms-hub-action--primary {
  border-color: var(--crm-primary-dark);
  background: #ffffff;
  color: var(--crm-primary-dark);
}

.crm-shell--index .forms-hub-action--secondary {
  background: rgba(245, 249, 253, 0.78);
}

.crm-shell--index .forms-hub-action:hover,
.crm-shell--index .forms-hub-action:focus-visible,
.crm-shell--index .forms-hub-support-link:hover,
.crm-shell--index .forms-hub-support-link:focus-visible {
  border-color: var(--crm-primary);
  background: #ffffff;
  color: var(--crm-primary-dark);
  text-decoration: none;
}

.crm-shell--index .forms-hub-action:focus-visible,
.crm-shell--index .forms-hub-support-link:focus-visible {
  outline: 3px solid rgba(26, 93, 150, 0.22);
  outline-offset: 2px;
}


.crm-shell--index .forms-hub-section--support .forms-hub-section__header {
  grid-template-columns: 1fr;
  margin-bottom: 0.28rem;
}

.crm-shell--index .forms-hub-support-list {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.35rem;
  border-top: 1px solid rgba(108, 137, 166, 0.28);
  padding-top: 0.42rem;
}

.crm-shell--index .forms-hub-support-link {
  width: 100%;
  min-height: 1.9rem;
}

.crm-shell--index .home-group-list a::after {
  content: none;
  display: none;
}

/* Forms Index redesign: make the desktop page feel like a clear forms list while
   collapsing to the same clear reading order on smaller screens. */
.crm-shell--index {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(290px, 1fr);
  column-gap: 1rem;
  row-gap: 1rem;
  max-width: 1060px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  overflow: visible;
}

.crm-shell--index .forms-hub-hero,
.crm-shell--index .forms-hub-section--support {
  grid-column: 1 / -1;
}

.crm-shell--index .forms-hub-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas:
    "kicker actions"
    "title actions"
    "intro actions";
  gap: 0.25rem 1.5rem;
  align-items: center;
  padding: 1.35rem 1.55rem;
  border: 1px solid rgba(92, 128, 164, 0.38);
  background: linear-gradient(135deg, rgba(245, 249, 253, 0.96), rgba(226, 237, 248, 0.82));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.72);
  text-align: left;
}

.crm-shell--index .forms-hub-hero .crm-kicker,
.crm-shell--index .forms-hub-hero .crm-title,
.crm-shell--index .forms-hub-intro {
  grid-column: 1;
}

.crm-shell--index .forms-hub-hero .crm-kicker {
  grid-area: kicker;
  margin-bottom: 0.1rem;
}

.crm-shell--index .forms-hub-hero .crm-title {
  grid-area: title;
  margin: 0;
  font-size: clamp(1.72rem, 3vw, 2.2rem);
  letter-spacing: -0.035em;
}

.crm-shell--index .forms-hub-intro {
  grid-area: intro;
  margin: 0.1rem 0 0;
  max-width: 600px;
  color: var(--crm-text-muted);
  font-size: 0.9rem;
  line-height: 1.4;
}

.crm-shell--index .forms-hub-quick-links {
  grid-area: actions;
  display: grid;
  grid-template-columns: 1fr;
  flex-wrap: wrap;
  gap: 0.38rem;
  justify-content: center;
  min-width: 190px;
  margin: 0;
}

.crm-shell--index .forms-hub-section {
  padding: 0.85rem 0.7rem 0;
  border: 1px solid rgba(92, 128, 164, 0.38);
  background: rgba(235, 243, 250, 0.46);
}

.crm-shell--index .forms-hub-section__header {
  display: grid;
  grid-template-columns: minmax(10rem, auto) minmax(0, 1fr);
  gap: 0.75rem;
  align-items: baseline;
  margin-bottom: 0.62rem;
  padding: 0 0.1rem 0.58rem;
  border-bottom: 1px solid rgba(92, 128, 164, 0.42);
}

.crm-shell--index .forms-hub-section__header .crm-section-title {
  margin: 0;
  color: var(--crm-primary-dark);
  font-size: 1.08rem;
  line-height: 1.1;
  text-align: left;
}

.crm-shell--index .forms-hub-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(15rem, auto);
  gap: 0.7rem;
  align-items: center;
  min-height: 3.35rem;
  padding: 0.64rem 0.42rem;
  border-top: 1px solid rgba(108, 137, 166, 0.34);
  background: rgba(255, 255, 255, 0.54);
  transition: background-color 140ms ease, border-color 140ms ease;
}

.crm-shell--index .forms-hub-row__actions {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(6.4rem, auto);
  gap: 0.34rem;
  justify-content: end;
  align-items: center;
}

.crm-shell--index .forms-hub-section:nth-of-type(3) .forms-hub-row__copy strong {
  font-size: 0.86rem;
  line-height: 1.12;
}

.crm-shell--index .forms-hub-section--support {
  padding-bottom: 0.72rem;
}

@media (max-width: 760px) {
  .crm-shell--index {
    grid-template-columns: 1fr;
    gap: 0.7rem;
  }

  .crm-shell--index .forms-hub-section__header {
    grid-template-columns: 1fr;
    gap: 0.14rem;
  }

  .crm-shell--index .forms-hub-row {
    grid-template-columns: 1fr;
    gap: 0.36rem;
    min-height: 0;
    padding: 0.62rem 0.42rem;
  }

  .crm-shell--index .forms-hub-row__actions {
    grid-auto-flow: row;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-auto-columns: initial;
    justify-content: stretch;
  }

  .crm-shell--index .forms-hub-row--portal {
    margin-top: 0.35rem;
  }

  .crm-shell--index .forms-hub-row__actions .forms-hub-action:only-child {
    grid-column: 1 / -1;
  }

  .crm-shell--index .forms-hub-action,
  .crm-shell--index .forms-hub-support-link {
    width: 100%;
    min-height: 2.35rem;
    white-space: normal;
  }

  .crm-shell--index .forms-hub-support-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .crm-shell--index .forms-hub-hero,
  .crm-shell--index .forms-hub-section--support {
    grid-column: auto;
  }

  .crm-shell--index .forms-hub-hero {
    display: block;
    padding: 1rem 0.72rem 0.9rem;
    text-align: center;
  }

  .crm-shell--index .forms-hub-hero .crm-kicker {
    margin-bottom: 0.1rem;
  }

  .crm-shell--index .forms-hub-hero .crm-title {
    margin: 0;
  }

  .crm-shell--index .forms-hub-intro {
    margin: 0.35rem auto 0;
  }

  .crm-shell--index .forms-hub-quick-links {
    display: grid;
    min-width: 0;
    margin-top: 0.7rem;
  }

  .crm-shell--index .forms-hub-section {
    padding: 0.7rem 0.35rem 0;
  }
}

@media (max-width: 440px) {
  .crm-shell--index .forms-hub-row__actions,
  .crm-shell--index .forms-hub-support-list {
    grid-template-columns: 1fr;
  }

  .crm-shell--index .forms-hub-quick-links {
    display: grid;
    grid-template-columns: 1fr;
  }
}

.crm-shell--compact .crm-form {
  padding: 8px 10px 14px;
}

.crm-shell--compact .crm-card {
  margin-bottom: 8px;
}

.crm-shell--compact .crm-card__header,
.crm-shell--compact .crm-card__body {
  padding: 9px 11px;
}

.crm-shell--compact .crm-card__header h2 {
  font-size: 0.94rem;
}

.crm-card__header-actions {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.38rem;
  min-width: 0;
}

.crm-card__header-actions > input[type="file"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.crm-card__header-actions > input[type="file"]:focus + .crm-card__header-status,
.crm-card__header-actions > input[type="file"]:focus-visible + .crm-card__header-status {
  outline: 2px solid rgba(26, 93, 150, 0.5);
  outline-offset: 2px;
}

.crm-challenge-upload {
  min-height: 1.8rem;
  padding: 0.2rem 0.52rem;
  font-size: 0.76rem;
  white-space: nowrap;
}

.crm-card__header-status {
  color: #26435f;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1.1;
  text-align: right;
}

.crm-ai-certificate-notice {
  margin: 0.2rem 0 0.45rem;
  color: #4d5f72;
  font-size: 0.76rem;
  line-height: 1.3;
}

.crm-pedigree-reader {
  padding: 0.55rem 0.65rem;
  border: 1px solid #a7c7db;
  background: #f4f9fc;
}

.crm-pedigree-reader input[type="file"] {
  display: block;
  margin-top: 0.2rem;
}

.crm-litter-pedigree-reader {
  margin-bottom: 0.75rem;
}

.crm-litter-parent-fields {
  gap: 0.55rem 0.65rem;
}

.crm-litter-parent-fields .field--full {
  grid-column: 1 / -1;
}

.challenges td:first-child {
  white-space: nowrap;
}

.challenge-row-upload-input {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.challenge-row-upload {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  margin-left: 0.35rem;
  padding: 0 0.55rem;
  border: 1px solid #5f8fba;
  border-radius: 0.25rem;
  background: #1a5d96;
  color: #ffffff;
  cursor: pointer;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
  vertical-align: middle;
}

.challenge-row-upload::before {
  content: "\2191";
  margin-right: 0.3rem;
  font-size: 1rem;
}

.challenge-row-upload[data-file-selected="true"] {
  border-color: #237346;
  background: #237346;
  color: #ffffff;
}

.challenge-row-upload-input:focus + .challenge-row-upload,
.challenge-row-upload:hover {
  outline: 2px solid rgba(26, 93, 150, 0.28);
  outline-offset: 1px;
}

@media (max-width: 520px) {
  .challenge-row-upload {
    min-height: 2.5rem;
    min-width: 5.5rem;
    font-size: 0.82rem;
  }
}

.crm-shell--compact .crm-grid {
  gap: 6px;
}

.crm-shell--compact .crm-field {
  grid-template-columns: minmax(102px, 136px) minmax(0, 1fr);
  gap: 2px 6px;
  align-items: center;
}

.crm-shell--compact .crm-field label,
.crm-shell--compact .crm-field legend {
  padding: 0;
  border: 0;
  background: transparent;
  font-size: 0.78rem;
  line-height: 1.2;
}

.crm-shell--compact .crm-field input,
.crm-shell--compact .crm-field select,
.crm-shell--compact .crm-field textarea,
.crm-shell--compact .crm-field .crm-inline-choices,
.crm-shell--compact .crm-field .crm-choice-grid {
  grid-column: 2;
}

.crm-shell--compact .crm-field input,
.crm-shell--compact .crm-field select,
.crm-shell--compact .crm-field textarea {
  min-height: 28px;
  padding: 5px 7px;
  font-size: 0.82rem;
}

.crm-shell--compact .crm-field textarea {
  resize: vertical;
}

.crm-shell--compact .crm-inline-choices {
  gap: 6px 10px;
  min-height: 24px;
  font-size: 0.82rem;
}

.crm-shell--compact .crm-note {
  padding: 8px;
  font-size: 0.8rem;
  line-height: 1.32;
}

.crm-shell--compact .crm-payment-summary {
  gap: 6px;
  margin-bottom: 6px;
  grid-template-columns: minmax(150px, 210px) 1fr;
}

.crm-shell--compact .crm-label {
  font-size: 0.74rem;
}

.crm-shell--compact .crm-payment-summary__amount strong {
  font-size: 1.24rem;
}

.crm-shell--compact .crm-payment-summary__amount {
  align-self: stretch;
  min-height: 54px;
  padding: 8px 10px;
  border: 1px solid rgba(120, 150, 180, 0.48);
  border-radius: var(--crm-radius-sm);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.98) 0%, rgba(231, 240, 249, 0.96) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.crm-shell--compact .crm-bank-grid {
  grid-template-columns: 84px 1fr;
  font-size: 0.82rem;
}

.crm-shell--compact .challenges {
  font-size: 0.8rem;
}

.crm-shell--compact .challenges th,
.crm-shell--compact .challenges td {
  padding: 4px;
}

.crm-shell--compact .challenges td input,
.crm-shell--compact .challenges td select {
  min-height: 28px;
  padding: 3px 5px;
  font-size: 0.78rem;
}

.crm-shell--compact .crm-actions {
  gap: 8px;
  padding: 6px 8px;
}

.crm-shell--compact .crm-actions__meta {
  font-size: 0.78rem;
}

.crm-shell--compact .crm-actions__buttons {
  gap: 6px;
}

.crm-shell--compact .crm-button {
  min-height: 30px;
  padding: 0 10px;
  font-size: 0.8rem;
}

/* Compact-shell refinements at the shared mobile/tablet breakpoint. */
@media (max-width: 780px) {
  .crm-grid--4 {
    grid-template-columns: 1fr;
  }

  .crm-shell--compact .crm-header {
    padding: 6px 7px 0;
  }

  .crm-shell--compact .crm-header__top {
    flex-direction: column;
  }

  .crm-shell--compact .crm-form {
    padding: 6px 7px 16px;
  }

  .crm-shell--compact .crm-card__header,
  .crm-shell--compact .crm-card__body {
    padding: 6px 7px;
  }

  .crm-shell--compact .crm-grid--2,
  .crm-shell--compact .crm-grid--3,
  .crm-shell--compact .crm-payment-summary {
    grid-template-columns: 1fr;
  }

  .crm-shell--compact .crm-field {
    grid-template-columns: 1fr;
    gap: 3px;
  }

  .crm-shell--compact .crm-field input,
  .crm-shell--compact .crm-field select,
  .crm-shell--compact .crm-field textarea,
  .crm-shell--compact .crm-field .crm-inline-choices,
  .crm-shell--compact .crm-field .crm-choice-grid {
    grid-column: auto;
  }

  .crm-shell--compact .crm-actions {
    flex-direction: column;
    align-items: stretch;
    padding: 6px 7px;
  }

  .crm-shell--compact .crm-actions__buttons {
    width: 100%;
  }

.crm-shell--compact .crm-button {
  flex: 1 1 auto;
}

/* Shared public-form control treatment: field controls and actions use
   square corners across Membership, Honours, Individual, Litter and Prefix. */
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .crm-button),
.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .crm-button),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .btn) {
  border-radius: 0;
}

  .crm-address-inline-row {
    grid-template-columns: 1fr;
  }

  .crm-address-inline-controls {
    grid-template-columns: 1fr;
    grid-column: auto;
  }
}

/* Mobile density polish for long public forms. */
@media (max-width: 520px) {
  .crm-shell--compact .crm-header,
  .crm-shell--membership-wide .crm-header {
    padding: 0.45rem 0.65rem 0;
  }

  .crm-shell--compact .crm-header h1,
  .crm-shell--membership-wide .crm-header h1 {
    font-size: clamp(1.05rem, 7vw, 1.8rem);
    line-height: 1.04;
    letter-spacing: -0.04em;
  }

  .crm-shell--compact .crm-subtitle,
  .crm-shell--membership-wide .crm-subtitle {
    font-size: 0.76rem;
    line-height: 1.28;
  }

  .crm-shell--compact .crm-header__links,
  .crm-shell--membership-wide .crm-header__links {
    gap: 0.45rem;
  }

  .crm-shell--compact .crm-header__links a,
  .crm-shell--membership-wide .crm-header__links a,
  .crm-shell--compact .crm-button,
  .crm-shell--membership-wide .crm-button {
    min-height: 2.55rem;
    padding: 0.35rem 0.8rem;
    font-size: 0.8rem;
  }

  .crm-progress,
  .page .progress {
    padding: 0.75rem 0.8rem 0.8rem;
  }

  .crm-progress__summary,
  .crm-actions__meta {
    font-size: 0.9rem;
  }

  .crm-progress__steps,
  .page .progress-steps {
    gap: 0.5rem 0.65rem;
    font-size: 0.72rem;
  }

  .crm-progress__steps span,
  .page .progress-steps span {
    width: 1.95rem;
    height: 1.95rem;
    font-size: 0.92rem;
  }

  .crm-shell--compact .crm-form {
    padding: 0.45rem 0.65rem 1rem;
  }

  .crm-shell--membership-wide .crm-form {
    padding: 0.5rem 0.65rem 1rem;
  }

  .crm-shell--compact .crm-card {
    margin-bottom: 0.7rem;
  }

  .crm-shell--membership-wide .crm-card {
    margin-bottom: 0.72rem;
  }

  .crm-shell--compact .crm-card__header,
  .crm-shell--compact .crm-card__body {
    padding: 0.7rem 0.8rem;
  }

  .crm-shell--membership-wide .crm-card__header,
  .crm-shell--membership-wide .crm-card__body {
    padding: 0.72rem 0.8rem;
  }

  .crm-shell--compact .crm-card__header h2 {
    font-size: 0.88rem;
  }

  .crm-shell--membership-wide .crm-card__header h2 {
    font-size: 0.9rem;
  }

  .crm-shell--compact .crm-field {
    gap: 0.22rem;
  }

  .crm-shell--membership-wide .crm-grid,
  .crm-shell--membership-wide .crm-grid--2,
  .crm-shell--membership-wide .crm-grid--3,
  .crm-shell--membership-wide .crm-choice-grid--2,
  .crm-shell--membership-wide .crm-payment-summary,
  .crm-shell--membership-wide .crm-bank-grid,
  .crm-shell--membership-wide .crm-address-inline-row,
  .crm-shell--membership-wide .crm-address-inline-controls {
    grid-template-columns: 1fr;
  }

  .crm-shell--membership-wide .crm-field {
    grid-template-columns: 1fr;
    gap: 0.24rem;
  }

  .crm-shell--compact .crm-field label,
  .crm-shell--compact .crm-field legend {
    font-size: 0.73rem;
  }

  .crm-shell--membership-wide .crm-field label,
  .crm-shell--membership-wide .crm-field legend {
    font-size: 0.77rem;
    padding: 0;
    border: 0;
    background: transparent;
  }

  .crm-shell--compact .crm-field input,
  .crm-shell--compact .crm-field select,
  .crm-shell--compact .crm-field textarea {
    min-height: 2.55rem;
    padding: 0.45rem 0.62rem;
    font-size: 0.78rem;
  }

  .crm-shell--membership-wide .crm-field input,
  .crm-shell--membership-wide .crm-field select,
  .crm-shell--membership-wide .crm-field textarea,
  .crm-shell--membership-wide .crm-field .crm-inline-choices,
  .crm-shell--membership-wide .crm-field .crm-choice-grid {
    grid-column: auto;
  }

  .crm-shell--membership-wide .crm-field input,
  .crm-shell--membership-wide .crm-field select,
  .crm-shell--membership-wide .crm-field textarea {
    min-height: 2.55rem;
    padding: 0.45rem 0.62rem;
    font-size: 0.82rem;
  }

  .crm-shell--compact .crm-inline-choices,
  .crm-shell--compact .crm-choice-grid {
    gap: 0.45rem;
    font-size: 0.77rem;
  }

  .crm-shell--membership-wide .crm-inline-choices,
  .crm-shell--membership-wide .crm-choice-grid {
    gap: 0.5rem;
    font-size: 0.8rem;
  }

  

  .crm-shell--compact .crm-note {
    padding: 0.68rem 0.72rem;
    font-size: 0.76rem;
  }

  .crm-shell--membership-wide .crm-note {
    padding: 0.7rem 0.75rem;
    font-size: 0.8rem;
  }

  .crm-shell--compact .crm-payment-summary__amount {
    min-height: 0;
    padding: 0.7rem 0.78rem;
  }

  .crm-shell--membership-wide .crm-payment-summary__amount {
    min-height: 0;
    padding: 0.75rem 0.8rem;
  }

  .crm-shell--compact .crm-payment-summary__amount strong {
    font-size: 1.08rem;
  }

  .crm-shell--membership-wide .crm-payment-summary__amount strong {
    font-size: 1.12rem;
  }

  .crm-shell--compact .crm-bank-grid {
    gap: 0.22rem 0.55rem;
    font-size: 0.78rem;
  }

  .crm-shell--membership-wide .crm-bank-grid {
    gap: 0.24rem 0.55rem;
    font-size: 0.8rem;
  }

  .crm-shell--compact .crm-actions {
    gap: 0.7rem;
    padding: 0.8rem;
  }

  .crm-shell--membership-wide .crm-actions {
    gap: 0.72rem;
    padding: 0.8rem;
  }

  .crm-shell--compact .crm-actions__buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
  }

  .crm-shell--membership-wide .crm-actions__buttons {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.55rem;
    width: 100%;
  }

  .crm-shell--compact .crm-button {
    width: 100%;
  }

  .crm-shell--membership-wide .crm-button {
    width: 100%;
  }
}

/* Main-form sections use the index's silver surface; the outer shell remains plain. */
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-card,
body.fasa-shell .page .shell .card {
  border: 1px solid #8fb9d4 !important;
  box-shadow: none !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-card__body,
body.fasa-shell .page .shell .card-body {
  background: url("../../images/silver-card-soft-satin.png") center / cover no-repeat !important;
}

/* Litter parent details: scan paired identity and owner fields in two columns. */
body.fasa-shell .page .shell .crm-litter-parent-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0.65rem 0.9rem;
}

body.fasa-shell .page .shell .crm-litter-parent-fields .field {
  grid-column: auto !important;
}

body.fasa-shell .page .shell .crm-litter-parent-fields .field--full {
  grid-column: 1 / -1 !important;
}

body.fasa-shell .page .shell .crm-litter-owner-heading {
  margin-top: 0.2rem;
  padding-top: 0.55rem;
  border-top: 1px solid #b8cfdf;
}

body.fasa-shell .page .shell .crm-litter-owner-heading h3 {
  margin: 0;
  color: #0b5f9e;
  font-size: 0.9rem;
}

@media (max-width: 520px) {
  body.fasa-shell .page .shell .crm-litter-parent-fields {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* 2026-08-16 compact principal-form sections and scan-line fields. */

.crm-shell--membership-wide .crm-card__body,
.crm-shell--compact .crm-card__body,
.page .shell .card-body {
  padding: 0.45rem 0.55rem 0.52rem !important;
  border: 1px solid rgba(126, 154, 180, 0.28);
  background: #edf2f7 !important;
}

.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page .shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  min-height: 2.35rem;
  padding-top: 0.35rem;
  padding-bottom: 0.35rem;
}


.crm-shell--membership-wide .crm-choice-card,
.crm-shell--compact .crm-choice-card,
.page .shell .choice-row {
  min-height: 2rem;
  padding-top: 0.28rem;
  padding-bottom: 0.28rem;
}

.crm-shell--membership-wide .crm-note,
.crm-shell--compact .crm-note,
.page .shell .note {
  padding: 0.45rem 0.55rem;
}


.crm-field-group-heading {
  margin: 0.75rem 0 -0.1rem;
  padding: 0.65rem 0.35rem 0.18rem;
  border-top: 1px solid rgba(93, 128, 159, 0.24);
  border-top-color: #b8cad8;
  background: rgba(255, 255, 255, 0.42);
}

.crm-field-group-heading:first-child {
  border-top: 0;
}

.crm-field-group-heading .crm-subheading {
  margin: 0;
  color: #1c4f78;
  font-size: 0.82rem;
  letter-spacing: 0;
  text-transform: uppercase;
}

.crm-conditional-panel,
.crm-field--conditional,
.page .shell .field--conditional {
  border: 1px dashed rgba(93, 128, 159, 0.42);
  background: rgba(255, 255, 255, 0.55);
}

.crm-field--conditional,
.page .shell .field--conditional {
  padding: 0.28rem 0.35rem;
}

.crm-conditional-panel {
  padding: 0.35rem;
}

.crm-field--conditional > label,
.page .shell .field--conditional > label {
  color: #436681;
}

.crm-field--upload,
.page .shell .field--upload {
  align-items: center;
  background: rgba(255, 255, 255, 0.35);
}

.page .shell .field--full,
.page .shell .crm-address-grid,
.page .shell .crm-prefix-choice-grid {
  grid-column: 1 / -1;
}

.page .shell .grid-2 > .field--full {
  grid-column: 1 / -1;
}

.crm-shell--membership-wide .crm-grid--scan-groups,
.crm-shell--compact .crm-grid--scan-groups,
.page .shell .grid-2 {
  align-items: start;
}

.page .shell .grid-2 > .field {
  min-width: 0;
}

.crm-actions__secondary,
.page .shell .actions__secondary {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.crm-actions__primary,
.page .shell .actions__primary {
  display: flex;
  justify-content: flex-end;
}


@media (max-width: 760px) {
  .crm-actions__secondary,
  .crm-actions__primary,
  .page .shell .actions__secondary,
  .page .shell .actions__primary {
    justify-content: stretch;
  }

  .crm-actions__secondary > *,
  .crm-actions__primary > *,
  .page .shell .actions__secondary > *,
  .page .shell .actions__primary > * {
    width: 100%;
  }

  

  
}

@media (max-width: 420px) {
  

  

  

  .page .shell .grid-2,
  .page .shell .crm-address-grid,
  .page .shell .crm-prefix-choice-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .crm-field-group-heading {
    padding-left: 0;
    padding-right: 0;
    background: transparent;
  }
}

/* Keep the principal-form design pass authoritative after legacy blocks. */

.crm-shell--membership-wide .crm-grid,
.crm-shell--compact .crm-grid,
.page .shell .grid {
  grid-template-columns: minmax(0, 1fr);
  gap: 0.65rem 0.9rem;
}


.crm-shell--membership-wide :is(.crm-grid--2, .crm-grid--3, .crm-address-inline-row),
.crm-shell--compact :is(.crm-grid--2, .crm-grid--3),
.page .shell :is(.grid-2, .grid-3, .crm-address-grid, .crm-prefix-choice-grid, .crm-litter-parent-grid) {
  grid-template-columns: minmax(0, 1fr) !important;
}


@media (max-width: 760px) {
  

  
}

/* Principal forms: calm, legible shared completion experience. */

.crm-shell--membership-wide .crm-header,
.crm-shell--compact .crm-header,
.page .shell .header {
  margin-bottom: 0.75rem;
  padding: 1.25rem 1.5rem;
  border: 1px solid #8baac4;
  border-top: 4px solid #174f7b;
  background: #ffffff;
}


.crm-shell--membership-wide .crm-header h1,
.crm-shell--compact .crm-header h1,
.page .shell .header h1 {
  color: #0d3557;
  font-size: clamp(1.75rem, 3vw, 2.25rem);
  line-height: 1.15;
}

.crm-shell--membership-wide .crm-subtitle,
.crm-shell--compact .crm-subtitle,
.page .shell .subtitle {
  max-width: 46rem;
  color: #405c72;
  font-size: 1rem;
  line-height: 1.55;
}

.crm-form-stage-note {
  margin-bottom: 0.55rem !important;
  padding: 0.6rem 0.75rem !important;
  border-left: 4px solid #5b86aa !important;
  background: #eef5fa !important;
  color: #284b66;
}

.crm-shell--membership-wide .crm-card__header,
.crm-shell--compact .crm-card__header,
.page .shell .card-head {
  min-height: 2.75rem;
  padding: 0.65rem 0.85rem !important;
  border-bottom: 1px solid #a8bed0;
  background: #dce9f3;
}

.crm-shell--membership-wide .crm-card__header h2,
.crm-shell--compact .crm-card__header h2,
.page .shell .card-head h2 {
  color: #123f63;
  font-size: 1rem;
  line-height: 1.3;
}

.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  min-height: 2.7rem;
  padding: 0.55rem 0.65rem;
  border: 1px solid #789bb8 !important;
  border-radius: 4px !important;
  color: #17364f;
}

.crm-shell--membership-wide :is(input, select, textarea):focus,
.crm-shell--compact :is(input, select, textarea):focus,
.page :is(input, select, textarea):focus {
  outline: 2px solid #ffffff;
  outline-offset: 1px;
  border-color: #145b91 !important;
  box-shadow: 0 0 0 4px rgba(20, 91, 145, 0.24) !important;
}


.crm-choice-card,
.crm-fieldset,
.crm-conditional-panel,
.choice-row {
  border-color: #b5c8d8;
  background: #f7fafc;
}

.crm-shell--membership-wide .crm-note,
.crm-shell--compact .crm-note,
.page .shell .crm-note {
  border-color: #b0c5d6;
  border-radius: 4px;
  background: #f2f7fb !important;
}


.crm-shell--membership-wide .crm-button,
.crm-shell--compact .crm-button,
.page .shell .btn {
  min-height: 2.7rem;
  padding: 0.6rem 0.9rem;
  border-radius: 4px !important;
}

.crm-shell--membership-wide .crm-button--primary,
.crm-shell--compact .crm-button--primary,
.page .shell .btn.primary {
  min-width: 13rem;
  border-color: #0c456f;
  background: #0f5688;
  box-shadow: 0 3px 0 #082f4d;
}

@media (max-width: 760px) {
  

  .crm-shell--membership-wide .crm-header h1,
  .crm-shell--compact .crm-header h1,
  .page .shell .header h1 {
    font-size: 1.6rem;
  }

  .crm-shell--membership-wide .crm-button--primary,
  .crm-shell--compact .crm-button--primary,
  .page .shell .btn.primary {
    width: 100%;
    min-width: 0;
  }
}

@media (max-width: 760px) {
  .crm-shell--membership-wide .crm-grid--2,
  .crm-shell--membership-wide .crm-grid--3,
  .crm-shell--compact .crm-grid--2,
  .crm-shell--compact .crm-grid--3,
  .page .shell .grid-2,
  .page .shell .grid-3 {
    grid-template-columns: 1fr;
  }

  

  
}

@media (max-width: 420px) {
  .crm-shell--membership-wide .crm-form,
  .crm-shell--compact .crm-form,
  .page .shell .form-wrap {
    padding-right: 0.35rem;
    padding-left: 0.35rem;
  }

  .crm-shell--membership-wide .crm-field > label,
  .crm-shell--compact .crm-field > label,
  .page .shell .field > label {
    min-width: 0;
    text-align: center;
  }

  
}

/* 2026-08-16 all principal forms alignment cleanup, final cascade authority. */


@media (max-width: 760px) {
  

  

  
}

/* 2026-08-16 all principal forms alignment cleanup. */


@media (max-width: 760px) {
  

  

  
}

/* 2026-08-16 Membership alignment cleanup, final cascade authority. */


@media (max-width: 760px) {
  

  

  

  

  
}

/* 2026-08-16 Membership alignment cleanup. */


.crm-shell--membership-wide .crm-choice-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.35rem;
}

.crm-shell--membership-wide .crm-choice-card {
  min-height: 2.15rem;
  padding: 0.36rem 0.5rem;
}


.crm-shell--membership-wide .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.crm-shell--membership-wide .crm-field > .crm-help--inline {
  grid-column: 2;
  width: 100%;
  min-width: 0;
}

.crm-shell--membership-wide .crm-field--phone-standalone,
.crm-shell--membership-wide .crm-field:has(> label[for="breeds_owned"]) {
  grid-column: 1 / -1;
  grid-template-columns: 6.5rem minmax(0, 1fr) !important;
}

.crm-shell--membership-wide .crm-field--wrap-label > label,
.crm-shell--membership-wide .crm-field > label[for="breeds_owned"],
.crm-shell--membership-wide #breederFields .crm-field > label {
  justify-content: flex-start;
  max-width: none;
  min-height: 0;
  text-align: left;
  white-space: normal;
}

.crm-shell--membership-wide fieldset.crm-field {
  grid-template-columns: minmax(0, 1fr);
  padding: 0.45rem 0.55rem;
}

.crm-shell--membership-wide fieldset.crm-field > legend,
.crm-shell--membership-wide fieldset.crm-field > .crm-inline-choices,
.crm-shell--membership-wide fieldset.crm-field > .crm-help {
  grid-column: 1;
}

.crm-shell--membership-wide fieldset.crm-field > .crm-inline-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
}

@media (max-width: 760px) {
  .crm-shell--membership-wide .crm-card__body {
    padding: 0.65rem !important;
  }

  .crm-shell--membership-wide .crm-choice-grid,
  .crm-shell--membership-wide .crm-split-controls,
  .crm-shell--membership-wide .crm-address-inline-controls {
    grid-template-columns: minmax(0, 1fr);
  }

  .crm-shell--membership-wide .crm-field,
  .crm-shell--membership-wide .crm-field--phone-standalone,
  .crm-shell--membership-wide .crm-field:has(> label[for="breeds_owned"]),
  .crm-shell--membership-wide .crm-address-inline-row {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .crm-shell--membership-wide .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-help--inline),
  .crm-shell--membership-wide .crm-split-controls,
  .crm-shell--membership-wide .crm-address-inline-controls,
  .crm-shell--membership-wide .crm-field--phone-standalone > input,
  .crm-shell--membership-wide .crm-field > #breeds_owned {
    grid-column: 1 !important;
    width: 100% !important;
  }
}

/* 2026-08-16 open-tab forms layout authority. */

.crm-shell--membership-wide .crm-page-header,
.crm-shell--compact .crm-page-header,
.page .shell .page-header {
  padding: 1rem 1.15rem 0.85rem !important;
  border-bottom: 1px solid #aac1d7;
  background: #ffffff !important;
}


.crm-shell--membership-wide .crm-page-header :is(h1, p, .crm-kicker),
.crm-shell--compact .crm-page-header :is(h1, p, .crm-kicker),
.page .shell .page-header :is(h1, p, .kicker) {
  color: #173954 !important;
}

.crm-shell--membership-wide .crm-page-header h1,
.crm-shell--compact .crm-page-header h1,
.page .shell .page-header h1 {
  margin-bottom: 0.45rem;
  font-size: clamp(1.7rem, 2.5vw, 2.15rem);
  letter-spacing: 0;
}


.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .actions,
.page .shell .form-actions {
  margin-top: 0.8rem;
  padding: 0.9rem 1rem !important;
  border-top: 1px solid #aac1d7;
  border-radius: 6px !important;
  background: #ffffff;
}


@media (max-width: 760px) {
  

  

  .crm-shell--membership-wide .crm-page-header,
  .crm-shell--compact .crm-page-header,
  .page .shell .page-header {
    padding: 0.75rem 0.8rem !important;
  }

  

  

  

  .crm-shell--membership-wide .crm-actions,
  .crm-shell--compact .crm-actions,
  .page .shell .actions,
  .page .shell .form-actions {
    padding: 0.65rem !important;
  }
}

@media (max-width: 420px) {
  .crm-shell--membership-wide .crm-page-header h1,
  .crm-shell--compact .crm-page-header h1,
  .page .shell .page-header h1 {
    font-size: clamp(1.35rem, 7vw, 1.6rem);
  }

  
}

/* 2026-08-16 open-tab forms design revision. */
.main-content-wrap > .crm-body,
.main-content-wrap > .page {
  width: min(100%, 980px);
  margin: 1.35rem auto 0;
}

.crm-shell--membership-wide,
.crm-shell--compact,
.page .shell {
  width: min(100%, 980px);
  max-width: 980px;
  border: 1px solid #6f91ad;
  border-top: 5px solid #174f7b;
  background: #f8fbfe;
}

.crm-shell--membership-wide .crm-header,
.crm-shell--compact .crm-header,
.page .shell .header {
  padding: 1rem 1.15rem 0.85rem;
  border-bottom: 1px solid #aac1d7;
  background: #ffffff;
}

.crm-shell--membership-wide .crm-header__top,
.crm-shell--compact .crm-header__top,
.page .shell .header-top {
  gap: 0.7rem;
  padding-bottom: 0;
}

.crm-shell--membership-wide .crm-kicker,
.crm-shell--compact .crm-kicker,
.page .shell .kicker {
  margin-bottom: 0.25rem;
  color: #315b7c;
}

.crm-shell--membership-wide .crm-header h1,
.crm-shell--compact .crm-header h1,
.page .shell h1 {
  margin-bottom: 0.45rem;
  font-size: clamp(1.7rem, 2.5vw, 2.15rem);
  letter-spacing: 0;
}

.crm-shell--membership-wide .crm-subtitle,
.crm-shell--compact .crm-subtitle,
.page .shell .subtitle {
  max-width: 58rem;
  font-size: 0.96rem;
}

.crm-shell--membership-wide .crm-form,
.crm-shell--compact .crm-form,
.page .shell .form-wrap {
  padding: 0.9rem 1rem 0;
  background: #eef5fb;
}

.crm-shell--membership-wide .crm-note.crm-form-stage-note,
.crm-shell--compact .crm-note.crm-form-stage-note,
.page .shell .crm-form-stage-note {
  margin-bottom: 0.65rem;
  padding: 0.65rem 0.75rem;
  border-left: 4px solid #2f6f9f;
  background: #f8fbff;
}


.crm-shell--membership-wide .crm-card__header h2,
.crm-shell--compact .crm-card__header h2,
.page .shell .card-head h2 {
  color: #07375f;
  font-size: 1rem;
  text-align: left;
}


.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page .shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  min-height: 2.25rem;
  padding: 0.42rem 0.55rem !important;
  border-color: #7ca4c6 !important;
  background: #ffffff !important;
}

.crm-choice-card,
.choice-row label,
.page .choice-row label {
  min-height: 2.35rem;
  padding: 0.45rem 0.55rem;
  border: 1px solid #b7cadc;
  background: #f8fbff;
}

.crm-choice-card:hover,
.choice-row label:hover,
.page .choice-row label:hover {
  border-color: #7ca4c6;
  background: #f1f7fd;
}

.crm-conditional-panel,
.crm-shell--membership-wide :is(.crm-field--conditional, .crm-field--upload),
.crm-shell--compact :is(.crm-field--conditional, .crm-field--upload),
.page .shell :is(.field--conditional, .field--upload) {
  border-color: #c4d5e4;
  background: #f8fbff;
}

.crm-payment-summary__amount,
.crm-note {
  background: #f8fbff;
}

.crm-actions--final,
.page .shell .actions--final {
  display: grid;
  gap: 0.8rem;
  margin-top: 0.8rem;
  padding: 0.9rem 1rem !important;
  border-top: 1px solid #aac1d7;
  border-color: rgba(93, 128, 159, 0.42) !important;
  background: #f8fbfe !important;
}

.crm-final-review {
  display: grid;
  gap: 0.12rem;
  padding: 0.65rem 0.75rem;
  border: 1px solid #b0c5d6;
  border-left: 4px solid #174f7b;
  border-radius: 4px;
  background: #f2f7fb !important;
  color: #173f5f;
  font-size: 0.9rem;
  line-height: 1.35;
}

.crm-final-review strong {
  color: #0d3d63;
  font-size: 0.9rem;
  text-transform: uppercase;
}

.crm-actions__buttons--split,
.page .shell .buttons--split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid #c2d1dc;
}

.crm-actions__primary .crm-button--primary,
.page .shell .actions__primary .primary {
  min-width: 14rem;
}


.crm-shell--membership-wide .crm-field--phone-standalone > input,
.crm-shell--membership-wide .crm-field > #breeds_owned {
  width: min(100%, 23rem) !important;
}

@media (max-width: 760px) {
  .main-content-wrap > .crm-body,
  .main-content-wrap > .page {
    width: 100%;
    margin-top: 0.85rem;
  }

  .crm-shell--membership-wide,
  .crm-shell--compact,
  .page .shell {
    width: 100%;
    border-left: 0;
    border-right: 0;
  }

  .crm-shell--membership-wide .crm-header,
  .crm-shell--compact .crm-header,
  .page .shell .header {
    padding: 0.75rem 0.8rem;
  }

  .crm-shell--membership-wide .crm-form,
  .crm-shell--compact .crm-form,
  .page .shell .form-wrap {
    padding: 0.65rem 0.65rem 0;
  }

  

  .crm-shell--membership-wide .crm-card__header,
  .crm-shell--compact .crm-card__header,
  .page .shell .card-head {
    padding: 0.55rem 0.65rem !important;
  }

  .crm-actions__buttons--split,
  .page .shell .buttons--split {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.75rem;
  }

  .crm-actions--final,
  .page .shell .actions--final {
    padding: 0.65rem !important;
  }
}

@media (max-width: 420px) {
  .crm-shell--membership-wide .crm-header h1,
  .crm-shell--compact .crm-header h1,
  .page .shell h1 {
    font-size: clamp(1.35rem, 7vw, 1.6rem);
  }

  .crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
  .crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
  .page .shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
    min-height: 2.15rem;
  }

  .crm-actions__primary .crm-button--primary,
  .page .shell .actions__primary .primary {
    width: 100%;
    min-width: 0;
  }
}

/* Final principal-form authority after legacy refinements. */

.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .actions {
  margin-top: 1rem;
  padding: 0.9rem 1rem !important;
  border: 1px solid #8eaac1;
  border-top: 4px solid #174f7b;
  border-radius: 6px !important;
  background: #ffffff;
}


@media (max-width: 760px) {
  .crm-shell--membership-wide .crm-card__body,
  .crm-shell--compact .crm-card__body,
  .page .shell .card-body {
    padding: 0.8rem 0.75rem 0.9rem !important;
  }

  
}

/* Forms Index composition: keep the task groups full-width, use denser lists,
   and let this page exceed the standard 860px public-content wrapper. */
.main-content-wrap > .forms-hub-page {
  position: relative;
  left: 50%;
  width: min(1060px, calc(100vw - 2rem));
  transform: translateX(-50%);
}

.forms-hub-page .crm-shell--index {
  grid-template-columns: 1fr;
  width: 100%;
  max-width: 1060px;
  gap: 0.85rem;
}

.forms-hub-page .forms-hub-hero,
.forms-hub-page .forms-hub-section,
.forms-hub-page .forms-hub-section--support {
  grid-column: 1;
}


.forms-hub-page .forms-hub-list--online,
.forms-hub-page .forms-hub-list--pdfs {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.forms-hub-page .forms-hub-pdf-group + .forms-hub-pdf-group {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 2px solid rgba(28, 70, 109, 0.28);
}

.forms-hub-page .forms-hub-subsection-title {
  margin: 0 0 0.55rem;
  color: var(--crm-primary-dark);
  font-size: 0.92rem;
  line-height: 1.2;
  letter-spacing: 0.02em;
}

.forms-hub-page .forms-hub-pdf-group--honours .forms-hub-subsection-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.forms-hub-page .forms-hub-pdf-group--honours .forms-hub-subsection-title::before {
  content: "";
  width: 0.3rem;
  height: 1rem;
  background: var(--crm-primary);
}

.forms-hub-page .forms-hub-row:first-child {
  border-top-color: rgba(108, 137, 166, 0.42);
}

.forms-hub-page .forms-hub-row--portal {
  margin-top: 0;
  border-color: rgba(28, 70, 109, 0.5);
}

.forms-hub-page .forms-hub-row__copy span {
  margin-top: 0.18rem;
  font-size: 0.86rem;
  line-height: 1.35;
}

.forms-hub-page .forms-hub-row__actions {
  grid-auto-columns: minmax(7.25rem, auto);
}

.forms-hub-page .forms-hub-action,
.forms-hub-page .forms-hub-support-link {
  min-height: 2.75rem;
  padding: 0.5rem 0.85rem;
  font-size: 0.86rem;
  font-weight: 700;
}

.forms-hub-page .forms-hub-action--primary {
  border-color: var(--crm-primary-dark);
  background: var(--crm-primary-dark);
  color: #ffffff;
}

.forms-hub-page .forms-hub-action--primary:hover,
.forms-hub-page .forms-hub-action--primary:focus-visible {
  border-color: var(--crm-primary);
  background: var(--crm-primary);
  color: #ffffff;
}

.forms-hub-page .forms-hub-action--pdf {
  border-color: var(--crm-border-strong);
  background: #f7fbff;
  color: var(--crm-primary-dark);
}

.forms-hub-page .forms-hub-support-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

@media (max-width: 760px) {
  .main-content-wrap > .forms-hub-page {
    width: min(100%, calc(100vw - 0.9rem));
  }

  

  .forms-hub-page .forms-hub-list--online,
  .forms-hub-page .forms-hub-list--pdfs {
    grid-template-columns: 1fr;
    gap: 0.45rem;
  }

  .forms-hub-page .forms-hub-pdf-group + .forms-hub-pdf-group {
    margin-top: 0.85rem;
    padding-top: 0.85rem;
  }

  .forms-hub-page .forms-hub-row__actions {
    display: block;
  }

  .forms-hub-page .forms-hub-row__actions .forms-hub-action:only-child {
    width: auto;
    min-width: 7.25rem;
  }

  .forms-hub-page .forms-hub-support-list {
    grid-template-columns: 1fr;
    gap: 0.45rem;
  }
}

@media (max-width: 360px) {
  .forms-hub-page .forms-hub-row {
    grid-template-columns: 1fr;
  }

  .forms-hub-page .forms-hub-row__actions .forms-hub-action:only-child {
    width: 100%;
  }
}

/* Final shared override so later layout variants cannot reintroduce rounding. */
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .crm-button),
.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .crm-button),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea, button, .btn) {
  border-radius: 0 !important;
}

/* Honours challenge rows are entry fields, not recessed table cells. */
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  background: #ffffff;
  box-shadow: none;
}

.crm-shell--compact .challenges :is(input, select) {
  border: 1px solid var(--crm-border-strong);
  border-radius: 0;
  background: #ffffff;
  box-shadow: none;
}

/* Honours and Individual use the compact shell: keep their working surfaces
   flat, while retaining the blue section headers for navigation. */
.crm-shell--compact .crm-card__body,
.crm-shell--compact .crm-note,
.crm-shell--compact .crm-payment-summary__amount {
  border-radius: 0;
  background: #ffffff;
  box-shadow: none;
}

/* One quiet field outline across the public-form family. */
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  border: 1px solid #5f8fba !important;
  background: #ffffff !important;
}

/* Keep form cards quietly distinct from the pure-white entry fields. */
.crm-shell--compact .crm-card,
.crm-shell--compact .crm-card__body,
.crm-shell--membership-wide .crm-card,
.crm-shell--membership-wide .crm-card__body,
.page .shell .card,
.page .shell .card-body {
  background: #e8edf2;
  box-shadow: none;
}

@media (max-width: 520px) {
  .forms-hub-page .forms-hub-row__actions,
  .forms-hub-page .forms-hub-row__actions .forms-hub-action:only-child {
    width: 100%;
  }

  .main-content-wrap > .crm-shell.crm-shell--index {
    width: min(100% - 0.6rem, var(--crm-max-width));
    margin-left: auto;
    margin-right: auto;
  }

  .crm-shell--index .forms-hub-hero,
  .crm-shell--index .forms-hub-section {
    padding-left: 0.25rem;
    padding-right: 0.25rem;
  }
}

/* 2026-08-15 visual refresh: forms surfaces except online entries. */


.crm-body {
  color: #20384f;
}

.main-content-wrap > .crm-body.forms-hub-page,
.crm-shell--membership-wide,
.crm-shell--compact,
.page .shell {
  width: min(1140px, calc(100% - 1.5rem));
  margin-left: auto;
  margin-right: auto;
}

.forms-hub-page .forms-hub-hero,
.forms-hub-page .forms-hub-section,
.crm-shell--membership-wide .crm-card,
.crm-shell--compact .crm-card,
.page .shell .card {
  border-radius: 24px !important;
  border: 1px solid rgba(102, 137, 167, 0.18) !important;
  box-shadow: 0 22px 42px rgba(13, 44, 74, 0.08) !important;
}

.forms-hub-page .forms-hub-hero {
  position: relative;
  overflow: hidden;
  padding: clamp(1.45rem, 2.7vw, 2rem) !important;
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 30%),
    linear-gradient(135deg, rgba(13, 65, 107, 0.97), rgba(39, 107, 158, 0.9)) !important;
}

.forms-hub-page .forms-hub-hero .crm-kicker,
.forms-hub-page .forms-hub-hero .crm-title,
.forms-hub-page .forms-hub-hero .forms-hub-intro {
  position: relative;
  color: #f8fbff !important;
}

.forms-hub-page .forms-hub-section {
  padding: clamp(1rem, 2.5vw, 1.5rem) !important;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(241, 247, 252, 0.98)) !important;
}

.forms-hub-page .forms-hub-section__header {
  margin-bottom: 1rem;
}

.forms-hub-page .forms-hub-row {
  grid-template-columns: minmax(0, 1fr) auto;
  min-height: 4.35rem;
  padding: 0.72rem 0.78rem;
  border-radius: 18px;
  border: 1px solid rgba(112, 146, 175, 0.16);
  background: rgba(255, 255, 255, 0.98);
  box-shadow: 0 16px 30px rgba(13, 44, 74, 0.06);
}

.forms-hub-page .forms-hub-row__copy strong {
  color: #103e66;
  font-size: 1rem;
  line-height: 1.2;
}

.forms-hub-page .forms-hub-row__copy span,
.forms-hub-page .forms-hub-pdf-group p,
.forms-hub-page .forms-hub-support-list li {
  color: #425b71;
  line-height: 1.65;
}

.forms-hub-page .forms-hub-support-list li {
  border-radius: 16px;
  border: 1px solid rgba(112, 146, 175, 0.14);
  background: rgba(248, 251, 255, 0.92);
}

.crm-shell--membership-wide .crm-page-header,
.crm-shell--compact .crm-page-header,
.page .shell .page-header {
  padding: clamp(1.25rem, 2.5vw, 1.7rem);
  border-radius: 26px;
  border: 1px solid rgba(73, 115, 151, 0.2);
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.22), rgba(255, 255, 255, 0) 28%),
    linear-gradient(135deg, rgba(12, 61, 100, 0.98), rgba(33, 97, 147, 0.9));
  box-shadow: 0 26px 48px rgba(13, 44, 74, 0.14);
}

.crm-shell--membership-wide .crm-page-header :is(h1, p, .crm-kicker),
.crm-shell--compact .crm-page-header :is(h1, p, .crm-kicker),
.page .shell .page-header :is(h1, p, .crm-kicker) {
  color: #f8fbff;
}

.crm-shell--membership-wide .crm-progress,
.crm-shell--compact .crm-progress,
.page .shell .progress-indicator {
  padding: 0.9rem 1rem;
  border-radius: 20px;
  border: 1px solid rgba(116, 152, 183, 0.16);
  background: rgba(247, 250, 253, 0.94);
  box-shadow: 0 18px 34px rgba(13, 44, 74, 0.07);
}

.crm-shell--membership-wide .crm-card,
.crm-shell--compact .crm-card,
.page .shell .card,
.crm-shell--membership-wide .crm-note,
.crm-shell--compact .crm-note {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(241, 247, 252, 0.98)) !important;
}

.crm-shell--membership-wide .crm-card__header,
.crm-shell--compact .crm-card__header,
.page .shell .card-header {
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(116, 152, 183, 0.2);
}

.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  min-height: 2.85rem;
  border-color: #7eabc9 !important;
  background: #ffffff !important;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.9), 0 1px 2px rgba(13, 44, 74, 0.03);
}

.crm-shell--membership-wide :is(input, select, textarea):focus,
.crm-shell--compact :is(input, select, textarea):focus,
.page :is(input, select, textarea):focus {
  border-color: #2e76b0 !important;
  box-shadow: 0 0 0 3px rgba(46, 118, 176, 0.16) !important;
}

.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .form-actions {
  padding: 1rem 1.1rem;
  border-radius: 22px;
  border: 1px solid rgba(104, 142, 175, 0.18);
  background: rgba(248, 251, 254, 0.96);
  box-shadow: 0 18px 34px rgba(13, 44, 74, 0.08);
}

@media (max-width: 760px) {
  

  .forms-hub-page .forms-hub-hero,
  .forms-hub-page .forms-hub-section,
  .crm-shell--membership-wide .crm-card,
  .crm-shell--compact .crm-card,
  .page .shell .card,
  .crm-shell--membership-wide .crm-page-header,
  .crm-shell--compact .crm-page-header,
  .page .shell .page-header {
    border-radius: 18px !important;
  }
}

/* 2026-08-15 stripped-back correction. */

.forms-hub-page .forms-hub-hero,
.forms-hub-page .forms-hub-section,
.crm-shell--membership-wide .crm-card,
.crm-shell--compact .crm-card,
.page .shell .card,
.crm-shell--membership-wide .crm-page-header,
.crm-shell--compact .crm-page-header,
.page .shell .page-header,
.crm-shell--membership-wide .crm-progress,
.crm-shell--compact .crm-progress,
.page .shell .progress-indicator,
.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .form-actions,
.forms-hub-page .forms-hub-row,
.forms-hub-page .forms-hub-support-list li {
  border-radius: 0 !important;
  box-shadow: none !important;
}

.forms-hub-page .forms-hub-hero,
.crm-shell--membership-wide .crm-page-header,
.crm-shell--compact .crm-page-header,
.page .shell .page-header {
  padding: 0.9rem 1rem !important;
  background: #2f628f !important;
}

.forms-hub-page .forms-hub-hero .crm-title {
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  letter-spacing: -0.03em;
}

.forms-hub-page .forms-hub-hero .crm-kicker {
  margin-bottom: 0.2rem;
}

.forms-hub-page .forms-hub-quick-links .forms-hub-action--secondary,
.forms-hub-page .forms-hub-action--primary,
.forms-hub-page .forms-hub-action--secondary {
  border-radius: 0;
  font-weight: 700;
  box-shadow: none;
}

.forms-hub-page .forms-hub-section,
.crm-shell--membership-wide .crm-card,
.crm-shell--compact .crm-card,
.page .shell .card,
.crm-shell--membership-wide .crm-progress,
.crm-shell--compact .crm-progress,
.page .shell .progress-indicator,
.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .form-actions {
  padding: 0.75rem 0.9rem !important;
}

.forms-hub-page .forms-hub-row__copy span,
.forms-hub-page .forms-hub-pdf-group p,
.forms-hub-page .forms-hub-support-list li,
.crm-body,
.crm-shell--membership-wide :is(p, li, label),
.crm-shell--compact :is(p, li, label),
.page .shell :is(p, li, label) {
  line-height: 1.4;
}

.crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.crm-shell--compact :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea),
.page :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  min-height: 2.45rem;
  border-radius: 0 !important;
  box-shadow: none;
}

/* 2026-08-16 screenshot-led mobile density refinement. */
@media (max-width: 760px) {
  .main-content-wrap > .crm-body.forms-hub-page,
  .crm-shell--membership-wide,
  .crm-shell--compact,
  .page .shell {
    width: 100%;
  }

  .forms-hub-page .forms-hub-hero {
    padding: 0.7rem 0.8rem !important;
  }

  .forms-hub-page .forms-hub-hero .crm-title {
    font-size: clamp(1.5rem, 7vw, 1.85rem);
  }

  .forms-hub-page .forms-hub-quick-links {
    display: flex;
    justify-content: center;
  }

  .forms-hub-page .forms-hub-quick-links .forms-hub-action--secondary {
    width: auto !important;
    min-height: 2.2rem;
    padding: 0.35rem 0.65rem;
  }

  .forms-hub-page .forms-hub-section {
    padding: 0.65rem 0.7rem !important;
  }

  .forms-hub-page .forms-hub-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.55rem;
    min-height: 0;
    padding: 0.55rem 0.6rem;
  }

  .forms-hub-page .forms-hub-action {
    min-height: 2.2rem;
    padding: 0.35rem 0.6rem;
  }
}

@media (max-width: 520px) {
  .forms-hub-page .forms-hub-row {
    grid-template-columns: minmax(0, 1fr);
  }

  .crm-shell--membership-wide .crm-page-header,
  .crm-shell--compact .crm-page-header,
  .page .shell .page-header {
    padding: 0.65rem 0.75rem !important;
  }

  .crm-shell--membership-wide .crm-page-header h1,
  .crm-shell--compact .crm-page-header h1,
  .page .shell .page-header h1 {
    font-size: clamp(1.35rem, 7vw, 1.65rem);
    line-height: 1.15;
  }

  .crm-shell--membership-wide .crm-progress,
  .crm-shell--compact .crm-progress,
  .page .shell .progress-indicator {
    padding: 0.55rem 0.65rem !important;
  }

  .crm-progress__steps {
    gap: 0.35rem 0.5rem;
  }

  .crm-progress__steps span {
    width: 1.7rem;
    height: 1.7rem;
    font-size: 0.75rem;
  }

  .crm-shell--membership-wide .crm-card,
  .crm-shell--compact .crm-card,
  .page .shell .card {
    padding: 0.6rem 0.7rem !important;
  }

  .crm-choice-card {
    padding: 0.5rem 0.6rem;
  }

  .crm-shell--membership-wide .crm-actions,
  .crm-shell--compact .crm-actions,
  .page .shell .form-actions {
    padding: 0.55rem 0.65rem !important;
  }
}

/* Keep compact principal-form spacing authoritative after legacy refinements. */
.crm-shell--membership-wide .crm-card,
.crm-shell--compact .crm-card,
.page .shell .card {
  margin-bottom: 0.8rem;
  padding: 0 !important;
  border-color: #9fb7ca !important;
  border-radius: 6px !important;
  background: #ffffff !important;
}

.crm-shell--membership-wide .crm-card__header,
.crm-shell--compact .crm-card__header,
.page .shell .card-head {
  min-height: 2.75rem;
  padding: 0.65rem 0.85rem !important;
  background: #dce9f3;
}

.crm-shell--membership-wide .crm-card__body,
.crm-shell--compact .crm-card__body,
.page .shell .card-body {
  padding: 0.9rem 1rem 1rem !important;
  border: 0;
  background: #ffffff;
}

.crm-shell--membership-wide .crm-actions,
.crm-shell--compact .crm-actions,
.page .shell .actions {
  margin-top: 1rem;
  padding: 0.9rem 1rem !important;
  border-top: 4px solid #174f7b;
  border-radius: 6px !important;
  background: #ffffff;
}

.crm-shell--membership-wide .crm-grid,
.crm-shell--compact .crm-grid,
.page .shell .grid {
  gap: 0.65rem 0.9rem;
}

.crm-shell--membership-wide .crm-gap-top,
.crm-shell--compact .crm-gap-top {
  margin-top: 0.35rem;
}

.page .shell .field--mt16 {
  margin-top: 0.45rem;
}

.crm-shell--membership-wide .crm-field,
.crm-shell--compact .crm-field,
.page .shell .field {
  display: grid;
  grid-template-columns: fit-content(9rem) minmax(0, 1fr);
  align-items: center;
  gap: 0.3rem 0.75rem;
  min-width: 0;
}

.crm-shell--membership-wide .crm-field > label,
.crm-shell--compact .crm-field > label,
.page .shell .field > label {
  width: max-content;
  min-width: 0;
  max-width: 9rem;
  padding: 0;
  color: #203f58;
  font-size: 0.84rem;
  line-height: 1.3;
  text-align: left;
  white-space: normal;
}

.crm-shell--membership-wide :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload),
.crm-shell--compact :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload),
.page .shell :is(.field--conditional, .field--upload),
.crm-shell--compact .crm-field:has(> label:is(
  [for="registration_designation"],
  [for="cat_name"],
  [for="registration_no"],
  [for="breeder_phone"],
  [for="previous_owner"],
  [for="sire_registration_no"],
  [for="dam_registration_no"],
  [for="registration_pedigree_file"],
  [for="transfer_certificate_file"],
  [for="date_of_birth_approximate"],
  [for="challenges_sighted_by"]
)),
.page .shell .field:has(> label:is(
  [for="membership_no"],
  [for="daco_breeder_registration_number"],
  [for="daco_registration_number"],
  [for="queen_registration_no"],
  [for="queen_microchip"],
  [for="queen_council"],
  [for="queen_owner_address"],
  [for="queen_owner_email"],
  [for="queen_owner_phone"],
  [for="stud_registration_no"],
  [for="stud_microchip"],
  [for="stud_council"],
  [for="stud_owner_address"],
  [for="stud_owner_email"],
  [for="stud_owner_phone"],
  [for="kittens_count"],
  [for="sire_pedigree_file"],
  [for="dam_pedigree_file"],
  [for="existing_prefix_details"],
  [for="supporting_documents_file"],
  [for="payment_receipt"]
)) {
  grid-template-columns: minmax(0, 1fr) !important;
  align-items: start;
}

.crm-shell--membership-wide :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload) > label,
.crm-shell--compact :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload) > label,
.page .shell :is(.field--conditional, .field--upload) > label,
.crm-shell--compact .crm-field:has(> label:is(
  [for="registration_designation"],
  [for="cat_name"],
  [for="registration_no"],
  [for="breeder_phone"],
  [for="previous_owner"],
  [for="sire_registration_no"],
  [for="dam_registration_no"],
  [for="registration_pedigree_file"],
  [for="transfer_certificate_file"],
  [for="date_of_birth_approximate"],
  [for="challenges_sighted_by"]
)) > label,
.page .shell .field:has(> label:is(
  [for="membership_no"],
  [for="daco_breeder_registration_number"],
  [for="daco_registration_number"],
  [for="queen_registration_no"],
  [for="queen_microchip"],
  [for="queen_council"],
  [for="queen_owner_address"],
  [for="queen_owner_email"],
  [for="queen_owner_phone"],
  [for="stud_registration_no"],
  [for="stud_microchip"],
  [for="stud_council"],
  [for="stud_owner_address"],
  [for="stud_owner_email"],
  [for="stud_owner_phone"],
  [for="kittens_count"],
  [for="sire_pedigree_file"],
  [for="dam_pedigree_file"],
  [for="existing_prefix_details"],
  [for="supporting_documents_file"],
  [for="payment_receipt"]
)) > label {
  grid-column: 1;
  width: auto;
  max-width: none;
}

.crm-shell--membership-wide :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.crm-shell--compact :is(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.page .shell :is(.field--conditional, .field--upload) > :is(input, select, textarea),
.crm-shell--compact .crm-field:has(> label:is(
  [for="registration_designation"],
  [for="cat_name"],
  [for="registration_no"],
  [for="breeder_phone"],
  [for="previous_owner"],
  [for="sire_registration_no"],
  [for="dam_registration_no"],
  [for="registration_pedigree_file"],
  [for="transfer_certificate_file"],
  [for="date_of_birth_approximate"],
  [for="challenges_sighted_by"]
)) > :is(input, select, textarea),
.page .shell .field:has(> label:is(
  [for="membership_no"],
  [for="daco_breeder_registration_number"],
  [for="daco_registration_number"],
  [for="queen_registration_no"],
  [for="queen_microchip"],
  [for="queen_council"],
  [for="queen_owner_address"],
  [for="queen_owner_email"],
  [for="queen_owner_phone"],
  [for="stud_registration_no"],
  [for="stud_microchip"],
  [for="stud_council"],
  [for="stud_owner_address"],
  [for="stud_owner_email"],
  [for="stud_owner_phone"],
  [for="kittens_count"],
  [for="sire_pedigree_file"],
  [for="dam_pedigree_file"],
  [for="existing_prefix_details"],
  [for="supporting_documents_file"],
  [for="payment_receipt"]
)) > :is(input, select, textarea) {
  grid-column: 1 !important;
  width: 100%;
}

.crm-shell--membership-wide .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.crm-shell--compact .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.page .shell .field > :is(input, select, textarea) {
  grid-column: 2;
  width: 100%;
  min-width: 0;
  max-width: none;
}

.crm-shell--membership-wide .crm-field > .crm-help--inline,
.crm-shell--compact .crm-field > .crm-help--inline {
  grid-column: 2;
}

.crm-shell--membership-wide fieldset.crm-field > .crm-help {
  grid-column: 1 / -1;
  width: 100%;
  max-width: none;
  margin-top: 0.25rem;
  line-height: 1.35;
}

.crm-shell--membership-wide .crm-card {
  margin: 0;
}

.crm-shell--membership-wide .crm-card__body {
  padding: 2px !important;
}

.crm-shell--membership-wide .crm-grid {
  gap: 2px;
}

.crm-shell--membership-wide .crm-field {
  grid-template-columns: 6.5rem minmax(0, 1fr);
  gap: 2px;
  margin: 0;
}

.crm-shell--membership-wide .crm-field > label {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 6.5rem;
  min-height: 2.25rem;
  margin: 0;
  padding: 2px;
  text-align: center;
}

.crm-shell--membership-wide .crm-field:not(.crm-field--wrap-label, .crm-field--conditional, .crm-field--upload) > label {
  width: 100%;
  max-width: 6.5rem;
}

.crm-shell--membership-wide .crm-field > :is(input, select, textarea),
.crm-shell--membership-wide .crm-inline-controls > :is(input, select, textarea) {
  margin: 0;
  padding: 2px 6px !important;
}

.crm-shell--membership-wide .crm-address-inline-controls .crm-field {
  display: block;
  grid-template-columns: minmax(0, 1fr);
  min-width: 0;
}

.crm-shell--membership-wide .crm-address-inline-row {
  grid-template-columns: 6.5rem minmax(0, 1fr) !important;
  column-gap: 2px;
}

.crm-shell--membership-wide .crm-address-inline-controls {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(7rem, 1fr) minmax(7rem, 1fr);
  grid-column: 2;
  gap: 0.5rem;
  width: 100%;
  min-width: 0;
}

.crm-shell--membership-wide .crm-address-inline-controls .crm-field > :is(input, select) {
  grid-column: 1;
  width: 100%;
}

.crm-shell--membership-wide .crm-split-controls {
  display: grid;
  grid-column: 2;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
  width: 100%;
  min-width: 0;
}

.crm-shell--membership-wide .crm-split-controls > input {
  width: 100%;
  min-width: 0;
}

.crm-shell--membership-wide .crm-field--phone-standalone {
  grid-column: 1;
}

.crm-shell--membership-wide .crm-field--phone-standalone > input {
  grid-column: 2 !important;
  width: min(100%, 23rem) !important;
}

.crm-shell--membership-wide .crm-field:has(> label[for="breeds_owned"]) {
  grid-template-columns: 6.5rem minmax(0, 1fr) !important;
}

.crm-shell--membership-wide .crm-field > label[for="breeds_owned"] {
  grid-column: 1;
  width: 100%;
  max-width: 6.5rem;
  text-align: center;
}

.crm-shell--membership-wide .crm-field > #breeds_owned {
  grid-column: 2 !important;
  width: min(100%, 23rem) !important;
}

.crm-shell--membership-wide .crm-field--wrap-label > label,
.crm-shell--membership-wide #breederFields .crm-field > label {
  min-width: 0;
  text-align: left;
  white-space: normal;
  line-height: 1.2;
}

.crm-shell--membership-wide #breederFields .crm-field {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
}

.crm-shell--membership-wide #breederFields .crm-field > :is(input, select, textarea) {
  grid-column: 1;
}

@media (max-width: 760px) {
  .crm-shell--membership-wide .crm-address-inline-row {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .crm-shell--membership-wide .crm-address-inline-controls {
    grid-template-columns: minmax(0, 1fr);
    grid-column: 1;
  }

  .crm-shell--membership-wide .crm-field,
  .crm-shell--compact .crm-field,
  .page .shell .field {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.18rem;
  }

  .crm-shell--membership-wide .crm-field > label,
  .crm-shell--compact .crm-field > label,
  .page .shell .field > label {
    min-width: 0;
    font-size: 0.82rem;
    text-align: left;
  }

  .crm-shell--membership-wide .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-help--inline),
  .crm-shell--compact .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-help--inline),
  .page .shell .field > :is(input, select, textarea) {
    grid-column: 1;
  }

  .crm-shell--membership-wide .crm-split-controls {
    grid-column: 1;
    grid-template-columns: minmax(0, 1fr);
  }

  .crm-shell--membership-wide .crm-field--phone-standalone {
    grid-column: 1 / -1;
  }

  .crm-shell--membership-wide .crm-field--phone-standalone > input,
  .crm-shell--membership-wide .crm-field > #breeds_owned {
    width: 100% !important;
  }

  .crm-shell--membership-wide .crm-field:has(> label[for="breeds_owned"]) {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .crm-shell--membership-wide .crm-field > #breeds_owned {
    grid-column: 1 !important;
  }

  .crm-shell--membership-wide .crm-field > label,
  .crm-shell--membership-wide .crm-field > label[for="breeds_owned"] {
    justify-content: flex-start;
    width: auto;
    max-width: none;
    min-height: 0;
    text-align: left;
  }
}

@media (max-width: 420px) {
  .crm-shell--membership-wide .crm-field,
  .crm-shell--compact .crm-field,
  .page .shell .field {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.18rem;
  }

  .crm-shell--membership-wide .crm-field > label,
  .crm-shell--compact .crm-field > label,
  .page .shell .field > label {
    min-width: 0;
  }

  .crm-shell--membership-wide .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-help--inline),
  .crm-shell--compact .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-help--inline),
  .page .shell .field > :is(input, select, textarea) {
    grid-column: 1;
  }
}

/* 2026-08-16 all principal forms alignment cleanup, final cascade authority. */
.crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading),
.page .shell .field:not(.field--conditional, .field--upload, .field--full) {
  display: grid;
  grid-template-columns: 12.5rem minmax(0, 1fr) !important;
  align-items: center;
  gap: 0.32rem 0.65rem;
}

.crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > label,
.page .shell .field:not(.field--conditional, .field--upload, .field--full) > label {
  grid-column: 1;
  width: 100%;
  max-width: 12.5rem;
  min-height: 2.25rem;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  text-align: right;
  line-height: 1.2;
}

.crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
.page .shell .field:not(.field--conditional, .field--upload, .field--full) > :is(input, select, textarea) {
  grid-column: 2 !important;
  width: 100%;
  min-width: 0;
}

.crm-shell--compact .crm-inline-controls {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.crm-shell--compact .crm-inline-controls > :is(input, select, textarea) {
  flex: 1 1 auto;
  min-width: 0;
}

.crm-shell--compact .crm-inline-controls > .crm-button {
  flex: 0 0 auto;
}

.crm-shell--compact .crm-address-grid,
.page .shell .crm-address-grid,
.page .shell .crm-prefix-choice-grid,
.page .shell .crm-litter-parent-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 0.5rem;
}

.page .shell .crm-prefix-choice-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.crm-shell--compact .crm-address-grid > .crm-field,
.page .shell .crm-address-grid > .field,
.page .shell .crm-prefix-choice-grid > .field,
.page .shell .crm-litter-parent-grid > .field {
  display: block !important;
}

.crm-shell--compact .crm-address-grid > .crm-field > label,
.page .shell .crm-address-grid > .field > label,
.page .shell .crm-prefix-choice-grid > .field > label,
.page .shell .crm-litter-parent-grid > .field > label {
  width: auto;
  max-width: none;
  min-height: 0;
  display: block;
  text-align: left;
}

.crm-shell--compact .crm-address-grid > .crm-field > :is(input, select, textarea),
.page .shell .crm-address-grid > .field > :is(input, select, textarea),
.page .shell .crm-prefix-choice-grid > .field > :is(input, select, textarea),
.page .shell .crm-litter-parent-grid > .field > :is(input, select, textarea) {
  width: 100%;
}

@media (max-width: 760px) {
  .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading),
  .page .shell .field:not(.field--conditional, .field--upload, .field--full),
  .crm-shell--compact .crm-address-grid,
  .page .shell .crm-address-grid,
  .page .shell .crm-prefix-choice-grid,
  .page .shell .crm-litter-parent-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > label,
  .page .shell .field:not(.field--conditional, .field--upload, .field--full) > label {
    justify-content: flex-start;
    width: auto;
    max-width: none;
    min-height: 0;
    text-align: left;
  }

  .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
  .page .shell .field:not(.field--conditional, .field--upload, .field--full) > :is(input, select, textarea) {
    grid-column: 1 !important;
  }
}

body.fasa-shell .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading),
body.fasa-shell .page .shell .field:not(.field--conditional, .field--upload, .field--full) {
  grid-template-columns: 12.5rem minmax(0, 1fr) !important;
}

body.fasa-shell .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
body.fasa-shell .page .shell .field:not(.field--conditional, .field--upload, .field--full) > :is(input, select, textarea) {
  grid-column: 2 !important;
  width: 100% !important;
  min-width: 0;
}

body.fasa-shell .crm-shell--compact .crm-address-grid > .crm-field,
body.fasa-shell .page .shell .crm-address-grid > .field,
body.fasa-shell .page .shell .crm-prefix-choice-grid > .field,
body.fasa-shell .page .shell .crm-litter-parent-grid > .field {
  grid-template-columns: minmax(0, 1fr) !important;
}

body.fasa-shell .crm-shell--compact .crm-address-grid > .crm-field > :is(input, select, textarea),
body.fasa-shell .page .shell .crm-address-grid > .field > :is(input, select, textarea),
body.fasa-shell .page .shell .crm-prefix-choice-grid > .field > :is(input, select, textarea),
body.fasa-shell .page .shell .crm-litter-parent-grid > .field > :is(input, select, textarea) {
  grid-column: 1 !important;
  width: 100% !important;
}

@media (max-width: 760px) {
  body.fasa-shell .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading),
  body.fasa-shell .page .shell .field:not(.field--conditional, .field--upload, .field--full) {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.fasa-shell .crm-shell--compact .crm-field:not(.crm-field--conditional, .crm-field--upload, .crm-field--wrap-label, .crm-field-group-heading) > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid),
  body.fasa-shell .page .shell .field:not(.field--conditional, .field--upload, .field--full) > :is(input, select, textarea) {
    grid-column: 1 !important;
  }
}

/* Litter parent panels keep grouped columns, but inner parent fields stack cleanly. */
body.fasa-shell .page .shell .crm-litter-parent-grid {
  grid-template-columns: minmax(0, 1fr) !important;
  align-items: start;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .crm-litter-parent-section {
  min-width: 0;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .crm-litter-parent-section .grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0.55rem 0.65rem;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .field {
  display: block !important;
  min-width: 0;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .field > label {
  display: block;
  width: auto;
  max-width: none;
  min-height: 0;
  margin-bottom: 0.14rem;
  text-align: left;
  line-height: 1.2;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .field > :is(input, select, textarea) {
  grid-column: 1 !important;
  width: 100% !important;
  min-width: 0;
}

body.fasa-shell .page .shell .crm-litter-parent-grid .field:has(#queen_owner_address),
body.fasa-shell .page .shell .crm-litter-parent-grid .field:has(#stud_owner_address) {
  grid-column: 1 / -1;
}

@media (max-width: 960px) {
  body.fasa-shell .page .shell .crm-litter-parent-grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

@media (max-width: 520px) {
  body.fasa-shell .page .shell .crm-litter-parent-grid .crm-litter-parent-section .grid {
    grid-template-columns: minmax(0, 1fr) !important;
  }
}

/* Principal forms: top-label control alignment. */
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-field:not(.crm-field-group-heading),
body.fasa-shell .page .shell .field:not(.field--full) {
  display: block !important;
  min-width: 0;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-field > :is(label, legend),
body.fasa-shell .page .shell .field > :is(label, legend) {
  display: block !important;
  width: auto !important;
  max-width: none !important;
  min-height: 0 !important;
  margin: 0 0 0.16rem !important;
  text-align: left !important;
  line-height: 1.2;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-field > :is(input, select, textarea, .crm-inline-controls, .crm-inline-choices, .crm-choice-grid, .crm-name-grid, .crm-address-grid),
body.fasa-shell .page .shell .field > :is(input, select, textarea) {
  grid-column: 1 !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-field > :is(input[type="checkbox"], input[type="radio"]),
body.fasa-shell .page .shell .field > :is(input[type="checkbox"], input[type="radio"]) {
  width: auto !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-name-grid,
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-address-grid,
body.fasa-shell .page .shell .crm-address-grid {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 0.45rem;
}

body.fasa-shell .crm-shell--membership-wide .crm-name-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-name-grid > .crm-field,
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-address-grid > .crm-field,
body.fasa-shell .page .shell .crm-address-grid > .field,
body.fasa-shell .page .shell .crm-prefix-choice-grid > .field,
body.fasa-shell .page .shell .crm-litter-parent-grid .field {
  display: block !important;
}

body.fasa-shell .page .shell .crm-prefix-choice-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0.5rem;
}

body.fasa-shell .page .shell .crm-litter-date-grid {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 0.5rem;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid--2,
body.fasa-shell .page .shell .grid-2 {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid--3,
body.fasa-shell .page .shell .grid-3 {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid-span-2,
body.fasa-shell .page .shell .field--full {
  grid-column: 1 / -1 !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid:has(#payment_reference):has(#payment_receipt),
body.fasa-shell .page .shell .grid:has(#payment_reference):has(#payment_receipt) {
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid:has(#payment_reference):has(#payment_receipt) > .crm-field,
body.fasa-shell .page .shell .grid:has(#payment_reference):has(#payment_receipt) > .field {
  grid-column: auto !important;
}

body.fasa-shell .crm-shell--compact .crm-inline-controls {
  display: flex !important;
  align-items: stretch;
  gap: 0.45rem;
}

body.fasa-shell .crm-shell--compact .crm-inline-controls > :is(input, select, textarea) {
  flex: 1 1 auto;
  width: auto !important;
}

body.fasa-shell .crm-shell--compact .crm-inline-controls > .crm-button {
  flex: 0 0 auto;
}

@media (max-width: 760px) {
  body.fasa-shell .crm-shell--membership-wide .crm-name-grid,
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-address-grid,
  body.fasa-shell .page .shell .crm-address-grid,
  body.fasa-shell .page .shell .crm-prefix-choice-grid,
  body.fasa-shell .page .shell .crm-litter-date-grid,
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid--2,
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid--3,
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-grid:has(#payment_reference):has(#payment_receipt),
  body.fasa-shell .page .shell .grid:has(#payment_reference):has(#payment_receipt),
  body.fasa-shell .page .shell .grid-2,
  body.fasa-shell .page .shell .grid-3 {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.fasa-shell .crm-shell--compact .crm-inline-controls {
    flex-wrap: wrap;
  }

  body.fasa-shell .crm-shell--compact .crm-inline-controls > :is(input, select, textarea, .crm-button) {
    flex: 1 1 100%;
  }
}

/* Membership spacing now follows the same principal-form rhythm as the other forms. */
body.fasa-shell .crm-shell--membership-wide .crm-form {
  padding: 0.9rem 1rem 0 !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-card {
  margin-bottom: 0.8rem !important;
  padding: 0 !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-card__header {
  padding: 0.65rem 0.85rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-card__body {
  padding: 0.9rem 1rem 1rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-grid,
body.fasa-shell .crm-shell--membership-wide .crm-choice-grid,
body.fasa-shell .crm-shell--membership-wide .crm-payment-summary,
body.fasa-shell .crm-shell--membership-wide .crm-address-inline-controls {
  gap: 0.65rem 0.9rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-field,
body.fasa-shell .crm-shell--membership-wide fieldset.crm-field {
  gap: 0.3rem 0.75rem !important;
  margin: 0 !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-field > :is(label, legend) {
  margin: 0 0 0.16rem !important;
  padding: 0 !important;
}

body.fasa-shell .crm-shell--membership-wide :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  padding: 0.42rem 0.55rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-choice-card,
body.fasa-shell .crm-shell--membership-wide :is(.crm-note, .crm-field--conditional, .crm-field--upload),
body.fasa-shell .crm-shell--membership-wide fieldset.crm-field {
  padding: 0.65rem 0.75rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-gap-top,
body.fasa-shell .crm-shell--membership-wide .crm-form-stage-note {
  margin-top: 0.65rem !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-actions {
  margin-top: 1rem !important;
  padding: 0.9rem 1rem !important;
}

body.fasa-shell .crm-shell--membership-wide [hidden],
body.fasa-shell .crm-shell--compact [hidden],
body.fasa-shell .page .shell [hidden] {
  display: none !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-address-inline-row {
  display: block !important;
}

body.fasa-shell .crm-shell--membership-wide .crm-address-inline-controls {
  grid-column: 1 / -1 !important;
  grid-template-columns: minmax(0, 2fr) minmax(7rem, 1fr) minmax(7rem, 1fr) !important;
  width: 100% !important;
}

body.fasa-shell .crm-shell--membership-wide #breederFields > .crm-field > label {
  display: flex !important;
  min-height: 2.35em !important;
  align-items: flex-end;
}

/* 2026-08-17 canonical public-form surface system. Keep hierarchy in the
   section header; avoid stacked padded wrappers and competing border styles. */
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-card,
body.fasa-shell .page .shell .card,
body.fasa-shell .forms-hub-page :is(.forms-hub-hero, .forms-hub-section) {
  border: 1px solid var(--crm-border) !important;
  border-radius: var(--crm-radius-md) !important;
  box-shadow: none !important;
  overflow: hidden;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-card__body,
body.fasa-shell .page .shell .card-body {
  border: 0 !important;
  border-radius: 0 !important;
  background: #f7fafd !important;
  box-shadow: none !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) :is(.crm-note, .crm-payment-summary__amount),
body.fasa-shell .page .shell :is(.note, .payment-summary__amount) {
  border: 0 !important;
  border-left: 4px solid var(--crm-primary) !important;
  border-radius: 0 !important;
  background: #eef4fa !important;
  box-shadow: none !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) :is(.crm-conditional-panel, .crm-field--conditional, .crm-field--upload),
body.fasa-shell .page .shell :is(.field--conditional, .field--upload) {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) fieldset.crm-field,
body.fasa-shell .page .shell fieldset.field {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.fasa-shell .forms-hub-page :is(.forms-hub-row, .forms-hub-support-list li) {
  border: 0 !important;
  border-top: 1px solid #c2d1df !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

body.fasa-shell :is(.crm-card__toggle, .card-toggle) {
  display: inline-grid;
  width: 2.25rem;
  min-height: 2.25rem;
  place-items: center;
  border: 1px solid var(--crm-border-strong);
  border-radius: var(--crm-radius-sm) !important;
  background: #ffffff;
  color: var(--crm-primary-dark);
  cursor: pointer;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-actions,
body.fasa-shell .page .shell .form-actions {
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

/* Keep the standalone Prefix Application controls visually uniform. */
body.fasa-shell .page .shell #mainForm .field > :is(
  input:not([type="file"]):not([type="radio"]):not([type="checkbox"]),
  select,
  textarea
) {
  height: 2.7rem !important;
  min-height: 2.7rem !important;
  box-sizing: border-box;
}

body.fasa-shell .page .shell #mainForm .crm-prefix-applicant-grid > .field--full,
body.fasa-shell .page .shell #mainForm .crm-prefix-applicant-grid > .crm-address-grid {
  grid-column: 1 / -1;
}

/* The address row is a full-width field, so its control must use the full row too. */
body.fasa-shell .page .shell #mainForm .crm-prefix-applicant-grid > .field.field--full {
  display: block !important;
}

body.fasa-shell .page .shell #mainForm .crm-prefix-applicant-grid > .field.field--full > label,
body.fasa-shell .page .shell #mainForm .crm-prefix-applicant-grid > .field.field--full > :is(input, select, textarea) {
  display: block !important;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  grid-column: 1 / -1 !important;
}

@media (max-width: 760px) {
  body.fasa-shell .crm-shell--membership-wide .crm-form {
    padding: 0.65rem 0.65rem 0 !important;
  }

  body.fasa-shell .crm-shell--membership-wide .crm-card__header,
  body.fasa-shell .crm-shell--membership-wide .crm-actions {
    padding: 0.65rem !important;
  }

  body.fasa-shell .crm-shell--membership-wide .crm-grid,
  body.fasa-shell .crm-shell--membership-wide .crm-choice-grid,
  body.fasa-shell .crm-shell--membership-wide .crm-payment-summary,
  body.fasa-shell .crm-shell--membership-wide .crm-address-inline-controls {
    gap: 0.55rem !important;
  }

  body.fasa-shell .crm-shell--membership-wide .crm-address-inline-controls {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  body.fasa-shell .crm-shell--membership-wide #breederFields > .crm-field > label {
    min-height: 0 !important;
  }
}

/* Prefix Application compact rhythm. Preserve the existing single-page flow. */
@media (max-width: 725px) {
  body.fasa-shell .prefix-application-page .header {
    padding: 0.75rem 0.8rem !important;
  }

  body.fasa-shell .prefix-application-page .header-top,
  body.fasa-shell .prefix-application-page .links {
    gap: 0.45rem !important;
  }

  body.fasa-shell .prefix-application-page .subtitle {
    margin-block: 0.3rem 0 !important;
  }

  body.fasa-shell .prefix-application-page .form-wrap {
    padding: 0.55rem !important;
  }

  body.fasa-shell .prefix-application-page #mainForm > .crm-note {
    margin-bottom: 0.55rem !important;
    padding: 0.65rem 0.75rem !important;
  }

  body.fasa-shell .prefix-application-page #mainForm > .crm-note ul {
    margin: 0.4rem 0;
    padding-left: 1.2rem;
  }

  body.fasa-shell .prefix-application-page #mainForm > .crm-note li + li {
    margin-top: 0.2rem;
  }

  body.fasa-shell .prefix-application-page #mainForm .card {
    margin-bottom: 0.55rem;
  }

  body.fasa-shell .prefix-application-page #mainForm .card-head {
    min-height: 0;
    padding: 0.5rem 0.7rem !important;
  }

  body.fasa-shell .prefix-application-page #mainForm .card-body {
    padding: 0.65rem 0.7rem 0.7rem !important;
  }

  body.fasa-shell .prefix-application-page #mainForm :is(.grid, .crm-payment-summary) {
    gap: 0.5rem 0.65rem !important;
  }

  body.fasa-shell .prefix-application-page #mainForm .field {
    gap: 0.2rem 0.5rem;
  }

  body.fasa-shell .prefix-application-page .actions--final {
    margin-top: 0.55rem;
    padding: 0.65rem 0.7rem !important;
  }
}

@media (min-width: 560px) and (max-width: 725px) {
  body.fasa-shell .prefix-application-page #mainForm .crm-prefix-choice-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }
}

/* Shared authoritative payment and declaration states. */
.crm-declaration-date {
  display: block;
  width: min(100%, 27rem);
  min-height: 2.65rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--crm-border-strong);
  border-radius: 3px;
  background: #eef5fa;
  color: #173f60;
  font-weight: 700;
}

.crm-copy-reference {
  margin-left: 0.65rem;
  padding: 0.28rem 0.55rem;
  border: 1px solid #5d809f;
  background: #ffffff;
  color: #174f7b;
  font: inherit;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
}

.crm-copy-reference:focus-visible {
  outline: 3px solid #f0b429;
  outline-offset: 2px;
}

.crm-payment-summary[data-fee-error]::after {
  content: attr(data-fee-error);
  grid-column: 1 / -1;
  padding: 0.65rem 0.75rem;
  border-left: 4px solid #b42318;
  background: #fff2f0;
  color: #8a1c13;
  font-weight: 700;
}

/* Compact Help and Rules link groups shared by all public application forms. */
.crm-help-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 0.8rem;
  margin-bottom: 0.25rem;
}

.crm-help-links a {
  font-weight: 700;
}

.crm-help-qualification {
  margin-bottom: 0;
  font-style: italic;
}

@media (max-width: 559px) {
  .crm-help-links {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* Public-form guidance and horizontal data regions. */
.crm-form-stage-note > strong {
  display: block;
  margin-bottom: 0.25rem;
}

.crm-form-stage-note ul {
  margin: 0.25rem 0 0.4rem;
  padding-left: 1.2rem;
}

.crm-form-stage-note li {
  line-height: 1.35;
}

.crm-form-stage-note li + li {
  margin-top: 0.2rem;
}

.crm-table-scroll-hint {
  display: none;
}

@media (max-width: 700px) {
  .crm-table-scroll-hint {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin: 0.45rem 0 0.35rem;
    padding: 0.45rem 0.55rem;
    color: #284e6d;
    background: #e6eef6;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.3;
  }

  .crm-table-scroll-hint span {
    flex: 0 0 auto;
    color: #174f7b;
    font-size: 1.35rem;
    line-height: 1;
  }

  .table-wrap {
    overscroll-behavior-inline: contain;
    scrollbar-color: #5f8fba #e6eef6;
    scrollbar-width: auto;
  }

  .table-wrap:focus-visible {
    outline: 3px solid #174f7b;
    outline-offset: 3px;
  }
}

/* 2026-08-21 main form intro and action consistency pass. */
body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form-stage-note,
body.fasa-shell .page .shell .crm-form-stage-note {
  display: grid;
  gap: 0.55rem;
  margin-bottom: 0.75rem;
  padding: 0.85rem 0.95rem 0.9rem;
  border: 1px solid #9fbad2 !important;
  border-left: 4px solid var(--crm-primary) !important;
  background: #eef5fb !important;
}

body.fasa-shell .crm-form-stage-note > strong {
  margin: 0;
  color: #0b3c63;
  font-size: 0.96rem;
}

body.fasa-shell .crm-intro-copy {
  margin: 0;
  color: #254b68;
  font-size: 0.9rem;
  line-height: 1.42;
}

body.fasa-shell .crm-form-stage-note ul {
  margin: 0;
  padding-left: 1.15rem;
}

body.fasa-shell .crm-form-stage-note li {
  line-height: 1.42;
}

body.fasa-shell .crm-help-links {
  gap: 0.45rem;
  margin: 0;
}

body.fasa-shell .crm-help-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2rem;
  padding: 0.25rem 0.55rem;
  border: 1px solid #8dadc8;
  background: #ffffff;
  color: #0b4775;
  font-size: 0.84rem;
  font-weight: 700;
  line-height: 1.2;
}

body.fasa-shell .crm-help-qualification {
  margin: 0;
  color: #42617a;
  font-size: 0.84rem;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-actions--final,
body.fasa-shell .page .shell .actions--final {
  display: grid;
  gap: 0.85rem;
  margin-top: 1rem;
  padding: 0.9rem 1rem 1rem !important;
  border: 1px solid #8eaac1 !important;
  border-top: 4px solid #174f7b !important;
  border-radius: 6px !important;
  background: #f8fbfe !important;
}

body.fasa-shell :is(.crm-actions__buttons--split, .page .shell .buttons--split) {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.65rem;
  margin-top: 0;
  padding-top: 0.8rem;
  border-top: 1px solid #c2d1dc;
}

body.fasa-shell :is(.crm-actions__secondary, .page .shell .actions__secondary) {
  justify-self: start;
}

body.fasa-shell :is(.crm-actions__primary, .page .shell .actions__primary) {
  justify-self: end;
}

body.fasa-shell :is(.crm-actions__primary .crm-button--primary, .page .shell .actions__primary .primary) {
  min-width: 14rem;
}

#honours-challenge-certificates .crm-card__header {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.65rem 0.9rem;
}

#honours-challenge-certificates .crm-card__header-actions {
  display: grid;
  grid-template-columns: auto minmax(8rem, auto) 2.25rem;
  align-items: center;
  justify-content: end;
  gap: 0.45rem;
}

#honours-challenge-certificates .crm-card__header-status {
  color: #31536f;
  font-size: 0.82rem;
}

#honours-challenge-certificates .crm-challenge-upload {
  min-width: 9rem;
}

/* Keep the certificate action visible before the header becomes cramped. */
@media (max-width: 44rem) {
  #honours-challenge-certificates .crm-card__header {
    display: block;
  }

  #honours-challenge-certificates .crm-card__header h2 {
    margin-bottom: 0.5rem;
    text-align: left;
  }

  #honours-challenge-certificates .crm-card__header-actions {
    grid-template-columns: minmax(0, 1fr) 2.25rem;
    width: 100%;
  }

  #honours-challenge-certificates .crm-challenge-upload {
    grid-column: 1;
    grid-row: 1;
    justify-content: center;
  }

  #honours-challenge-certificates .crm-card__toggle {
    grid-column: 2;
    grid-row: 1;
  }

  #honours-challenge-certificates .crm-card__header-status {
    grid-column: 1 / -1;
    grid-row: 2;
    margin-top: 0.35rem;
    text-align: left;
  }
}

@media (min-width: 761px) {
  body.fasa-shell .crm-form-stage-note {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
  }

  body.fasa-shell .crm-form-stage-note > strong,
  body.fasa-shell .crm-form-stage-note .crm-intro-copy,
  body.fasa-shell .crm-form-stage-note ul,
  body.fasa-shell .crm-form-stage-note .crm-help-qualification {
    grid-column: 1;
  }

  body.fasa-shell .crm-form-stage-note .crm-help-links {
    grid-column: 2;
    grid-row: 1 / span 4;
    align-content: start;
    display: grid;
    min-width: 12rem;
  }
}

@media (max-width: 760px) {
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form,
  body.fasa-shell .page .shell .form-wrap {
    padding-bottom: 0.65rem !important;
  }

  body.fasa-shell .crm-help-links a {
    width: 100%;
  }

  body.fasa-shell :is(.crm-actions__buttons--split, .page .shell .buttons--split) {
    grid-template-columns: minmax(0, 1fr);
  }

  body.fasa-shell :is(.crm-actions__secondary, .crm-actions__primary, .page .shell .actions__secondary, .page .shell .actions__primary) {
    justify-self: stretch;
  }

  body.fasa-shell :is(.crm-actions__secondary > *, .crm-actions__primary > *, .page .shell .actions__secondary > *, .page .shell .actions__primary > *) {
    width: 100%;
  }
}

/* 2026-08-21 visual revision: warmer application dossier surface. */
body.fasa-shell {
  background:
    linear-gradient(180deg, rgba(247, 250, 253, 0.92), rgba(222, 233, 243, 0.86) 26%, rgba(213, 225, 236, 0.96)),
    repeating-linear-gradient(135deg, rgba(23, 79, 123, 0.05) 0 1px, transparent 1px 18px),
    #d9e6f2;
}

body.fasa-shell .main-content-wrap > :is(.crm-body, .crm-shell, .page) {
  margin-top: 1.55rem;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell) {
  position: relative;
  border-color: #6e94b5 !important;
  background:
    linear-gradient(180deg, #ffffff 0, #ffffff 5.35rem, #edf5fb 5.36rem, #f5f9fd 100%) !important;
  box-shadow: 0 1.25rem 2.25rem rgba(17, 50, 78, 0.16);
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell)::before {
  content: "";
  display: block;
  height: 0.42rem;
  background: linear-gradient(90deg, #11476f 0 28%, #b08d3c 28% 44%, #2f7d7a 44% 62%, #11476f 62% 100%);
}

body.fasa-shell :is(.crm-header, .page .shell .header) {
  padding: 1.2rem 1.25rem 1.05rem !important;
  border-bottom: 1px solid #bfd2e3;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(234, 243, 251, 0.96)),
    linear-gradient(90deg, rgba(176, 141, 60, 0.16), transparent 34%);
}

body.fasa-shell :is(.crm-header__top, .page .shell .header-top) {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr);
  justify-items: center;
  gap: 0.8rem;
  padding-bottom: 0 !important;
}

body.fasa-shell :is(.crm-kicker, .page .shell .kicker) {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 1.55rem;
  margin-bottom: 0.45rem;
  padding: 0.12rem 0.65rem;
  border: 1px solid rgba(176, 141, 60, 0.45);
  background: #fffaf0;
  color: #765c1c;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
}

body.fasa-shell :is(.crm-header h1, .page .shell h1, .crm-title) {
  margin-bottom: 0.55rem;
  color: #082f51;
  font-size: clamp(1.85rem, 3vw, 2.55rem);
  line-height: 1.02;
  letter-spacing: 0;
}

body.fasa-shell :is(.crm-subtitle, .page .shell .subtitle) {
  max-width: 46rem;
  color: #274d6c;
  font-size: 0.98rem;
}

body.fasa-shell :is(.crm-header__links, .page .shell .links) {
  gap: 0.55rem;
  padding-top: 0;
}

body.fasa-shell :is(.crm-header__links a, .page .shell .links a, .crm-button, .page .shell .btn) {
  min-height: 2.45rem;
  border-color: #6f91ae;
  background: #ffffff;
  color: #0d3c62;
}

body.fasa-shell :is(.crm-header__links a, .page .shell .links a):hover,
body.fasa-shell :is(.crm-header__links a, .page .shell .links a):focus-visible {
  border-color: #9f7c2f;
  background: #fff8e8;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form,
body.fasa-shell .page .shell .form-wrap {
  padding-top: 1rem !important;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form-stage-note,
body.fasa-shell .page .shell .crm-form-stage-note {
  position: relative;
  padding: 1rem 1rem 1rem 1.05rem;
  border: 1px solid #91b1cc !important;
  border-left: 0 !important;
  background:
    linear-gradient(90deg, #174f7b 0 0.42rem, transparent 0.42rem),
    linear-gradient(135deg, #f6fbff 0%, #edf6f8 58%, #fff8e9 100%) !important;
}

body.fasa-shell .crm-form-stage-note > strong {
  color: #07375f;
  font-size: 1.05rem;
}

body.fasa-shell .crm-form-stage-note > strong::after {
  content: "";
  display: block;
  width: 3.3rem;
  height: 0.18rem;
  margin-top: 0.35rem;
  background: #b08d3c;
}

body.fasa-shell .crm-help-links a {
  border-color: #86a8c5;
  background: rgba(255, 255, 255, 0.88);
}

body.fasa-shell .crm-help-links a:first-child {
  border-color: #9f7c2f;
  background: #fff8e8;
  color: #61490f;
}

body.fasa-shell :is(.crm-card, .page .shell .card) {
  border-color: #7fa2bf !important;
  background: #ffffff;
}

body.fasa-shell :is(.crm-card__header, .page .shell .card-head) {
  min-height: 3.1rem;
  border-bottom: 1px solid #a9c0d4;
  background:
    linear-gradient(90deg, rgba(176, 141, 60, 0.2), transparent 16rem),
    linear-gradient(180deg, #dceaf5, #ccdeed) !important;
}

body.fasa-shell :is(.crm-card__header h2, .page .shell .card-head h2) {
  color: #062d4d;
  font-size: 1.04rem;
}

body.fasa-shell :is(.crm-card__body, .page .shell .card-body) {
  background:
    linear-gradient(180deg, #fbfdff, #f4f8fc) !important;
}

body.fasa-shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea) {
  border-color: #83a8c6 !important;
  background: #ffffff !important;
}

body.fasa-shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea):focus,
body.fasa-shell :is(input:not([type="checkbox"]):not([type="radio"]), select, textarea):focus-visible {
  border-color: #9f7c2f !important;
  box-shadow: 0 0 0 3px rgba(176, 141, 60, 0.18);
  outline: none;
}

body.fasa-shell :is(.crm-choice-card, .choice-row label, .page .choice-row label) {
  border-color: #afc5d8;
  background: #ffffff;
}

body.fasa-shell :is(.crm-choice-card:has(input:checked), .choice-row label:has(input:checked), .page .choice-row label:has(input:checked)) {
  border-color: #9f7c2f;
  background: #fff8e8;
  box-shadow: inset 0.28rem 0 0 #b08d3c;
}

body.fasa-shell :is(.crm-payment-summary, .payment-summary) {
  gap: 0.75rem;
}

body.fasa-shell :is(.crm-payment-summary__amount, .payment-summary__amount),
body.fasa-shell :is(.crm-payment-summary__instructions, .payment-summary__instructions) {
  border-color: #b7ccdd !important;
  border-left: 4px solid #2f7d7a !important;
  background: #f4faf9 !important;
}

body.fasa-shell :is(.crm-actions--final, .page .shell .actions--final) {
  background:
    linear-gradient(90deg, rgba(176, 141, 60, 0.12), transparent 48%),
    #fbfdff !important;
}

body.fasa-shell .crm-final-review {
  border-color: #a8bfd2;
  border-left-color: #2f7d7a;
  background: #f6fbfa !important;
}

body.fasa-shell :is(.crm-button--primary, .page .shell .primary) {
  border-color: #0f4c72 !important;
  background: linear-gradient(180deg, #3c8ab0, #155d87) !important;
  color: #ffffff !important;
}

body.fasa-shell :is(.crm-button--primary, .page .shell .primary):hover,
body.fasa-shell :is(.crm-button--primary, .page .shell .primary):focus-visible {
  background: linear-gradient(180deg, #4499be, #174f7b) !important;
}

@media (min-width: 761px) {
  body.fasa-shell :is(.crm-header__links, .page .shell .links) {
    display: flex;
  }
}

@media (max-width: 760px) {
  body.fasa-shell {
    background:
      linear-gradient(180deg, #eaf2f9 0%, #d9e6f2 38%, #d0deeb 100%);
  }

  body.fasa-shell .main-content-wrap > :is(.crm-body, .crm-shell, .page) {
    margin-top: 0.9rem;
  }

  body.fasa-shell :is(.crm-header, .page .shell .header) {
    padding: 0.95rem 0.85rem 0.85rem !important;
  }

  body.fasa-shell :is(.crm-header h1, .page .shell h1, .crm-title) {
    font-size: clamp(1.55rem, 7vw, 1.9rem);
  }

  body.fasa-shell :is(.crm-card__header, .page .shell .card-head) {
    min-height: 2.85rem;
  }
}

/* 2026-08-21 Forms layout rebuild: style and rewritten-content support. */
body.fasa-shell {
  background-color: #d9e6f2;
  background-image:
    url("../../images/cat-shadows-blue-silver-bottom.png?v=20260821-background-light"),
    radial-gradient(circle at 12% 8%, rgba(176, 141, 60, 0.16), transparent 16rem),
    radial-gradient(circle at 88% 12%, rgba(47, 125, 122, 0.14), transparent 18rem),
    linear-gradient(180deg, #eef5fa 0%, #dbe8f2 38%, #cbdbe8 100%);
  background-position: center top, center top, center top, center top;
  background-repeat: no-repeat, no-repeat, no-repeat, no-repeat;
  background-attachment: fixed, fixed, fixed, fixed;
  background-size: cover, auto, auto, auto;
}

@media (max-width: 760px) {
  body.fasa-shell {
    background-attachment: scroll, scroll, scroll, scroll;
  }
}

body.fasa-shell .main-content-wrap {
  padding-bottom: 2.4rem;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell, .crm-shell--index) {
  overflow: hidden;
  border: 1px solid #557d9d !important;
  background:
    linear-gradient(180deg, #fbfdff 0, #fbfdff 4.7rem, #edf5fb 4.72rem, #f7fafc 100%) !important;
  box-shadow: none;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell, .crm-shell--index)::before {
  height: 0.55rem;
  background:
    linear-gradient(90deg, #0b3558 0 22%, #b08d3c 22% 36%, #2f7d7a 36% 54%, #d5e5f0 54% 56%, #0b3558 56% 100%);
}

body.fasa-shell :is(.crm-header, .page .shell .header) {
  background:
    linear-gradient(135deg, rgba(7, 42, 72, 0.96), rgba(19, 82, 124, 0.94) 60%, rgba(47, 125, 122, 0.92)),
    #0f4269 !important;
  color: #ffffff;
  text-align: left;
}

body.fasa-shell :is(.crm-header__top, .page .shell .header-top) {
  justify-items: stretch;
}

body.fasa-shell :is(.crm-kicker, .page .shell .kicker) {
  border-color: rgba(241, 209, 132, 0.72);
  background: rgba(255, 248, 232, 0.98);
  color: #5f470f;
}

body.fasa-shell :is(.crm-header h1, .page .shell h1) {
  max-width: 48rem;
  color: #ffffff;
  text-wrap: balance;
}

body.fasa-shell :is(.crm-subtitle, .page .shell .subtitle) {
  color: #e7f3fb;
  text-wrap: pretty;
}

body.fasa-shell :is(.crm-header__links a, .page .shell .links a) {
  border-color: rgba(255, 255, 255, 0.44);
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
}

body.fasa-shell :is(.crm-header__links a, .page .shell .links a):hover,
body.fasa-shell :is(.crm-header__links a, .page .shell .links a):focus-visible {
  border-color: #f1d184;
  background: #fff8e8;
  color: #0b3558;
}

body.fasa-shell :is(.crm-form-stage-note, .page .shell .crm-form-stage-note) {
  border: 0 !important;
  background:
    linear-gradient(180deg, #fff8e8 0%, #f5fbfb 100%) !important;
  box-shadow:
    inset 0.42rem 0 0 #b08d3c,
    0 0.65rem 1.2rem rgba(20, 70, 105, 0.11);
}

body.fasa-shell .crm-form-stage-note > strong {
  display: block;
  font-size: 1.18rem;
}

body.fasa-shell .crm-form-stage-note .crm-intro-copy {
  color: #173f61;
  font-size: 0.98rem;
}

body.fasa-shell .crm-form-stage-note li {
  margin-bottom: 0.45rem;
}

body.fasa-shell .crm-form-stage-note li::marker {
  color: #2f7d7a;
}

body.fasa-shell :is(.crm-card, .page .shell .card) {
  border: 0 !important;
  box-shadow:
    0 0.7rem 1.35rem rgba(18, 58, 88, 0.12),
    0 0 0 1px #8fb0ca;
}

body.fasa-shell :is(.crm-card__header, .page .shell .card-head) {
  border-bottom: 0;
  background:
    linear-gradient(90deg, #0f4269, #185f88 72%, #2f7d7a) !important;
}

body.fasa-shell :is(.crm-card__header h2, .page .shell .card-head h2) {
  color: #ffffff;
}

body.fasa-shell :is(.crm-card__toggle, .page .shell .card-toggle) {
  border-color: rgba(255, 255, 255, 0.52);
  color: #ffffff;
}

body.fasa-shell :is(.crm-card__body, .page .shell .card-body) {
  background:
    linear-gradient(180deg, #ffffff 0%, #f7fbfd 100%) !important;
}

body.fasa-shell :is(.crm-final-review) {
  border: 0;
  box-shadow:
    inset 0.42rem 0 0 #2f7d7a,
    0 0 0 1px #94b1c8;
}

body.fasa-shell .crm-final-review strong {
  color: #0b3558;
  font-size: 1.02rem;
  text-transform: uppercase;
}

body.fasa-shell :is(.crm-button--primary, .page .shell .primary) {
  background: linear-gradient(180deg, #2f7d7a, #124e73) !important;
}

body.fasa-shell :is(.crm-button--primary, .page .shell .primary):hover,
body.fasa-shell :is(.crm-button--primary, .page .shell .primary):focus-visible {
  background: linear-gradient(180deg, #36918d, #0f4269) !important;
}

body.fasa-shell .forms-hub-page .crm-shell--index {
  display: grid;
  grid-template-columns: minmax(23rem, 0.9fr) minmax(0, 1.5fr);
  gap: 1rem;
  max-width: 80rem;
  padding: 1rem;
}

body.fasa-shell .forms-hub-hero {
  position: sticky;
  display: block !important;
  top: 0.85rem;
  align-self: start;
  min-height: 32rem;
  padding: 1.35rem;
  border: 0;
  background:
    linear-gradient(160deg, #0b3558 0%, #174f7b 54%, #2f7d7a 100%);
  color: #ffffff;
}

body.fasa-shell .forms-hub-hero .crm-title {
  max-width: 100%;
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 3.35rem);
  line-height: 0.98;
}

body.fasa-shell .forms-hub-intro {
  max-width: 100%;
  color: #e7f3fb;
  font-size: 1rem;
}

body.fasa-shell .forms-hub-quick-links {
  position: static !important;
  inset: auto !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr);
  width: 100% !important;
  max-width: none;
  margin: 1rem 0 0;
}

body.fasa-shell .forms-hub-quick-links .forms-hub-action {
  width: 100% !important;
  max-width: none;
}

body.fasa-shell .forms-hub-summary-list {
  display: grid;
  gap: 0.65rem;
  width: 100%;
  max-width: none;
  margin: 1.15rem 0;
  padding: 0;
  list-style: none;
}

body.fasa-shell .forms-hub-summary-list li {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.7rem;
  align-items: center;
  padding: 0.68rem;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.1);
}

body.fasa-shell .forms-hub-summary-list strong {
  color: #f1d184;
  text-transform: uppercase;
}

body.fasa-shell .forms-hub-summary-list span {
  color: #ffffff;
}

body.fasa-shell .forms-hub-page .forms-hub-section {
  grid-column: 2;
  border: 0;
  box-shadow:
    0 0.7rem 1.45rem rgba(12, 48, 76, 0.12),
    0 0 0 1px #8fb0ca;
}

body.fasa-shell .forms-hub-list--online {
  grid-template-columns: minmax(0, 1fr);
}

body.fasa-shell .forms-hub-section__header {
  background:
    linear-gradient(90deg, rgba(176, 141, 60, 0.17), transparent 48%),
    #f8fbfd;
}

body.fasa-shell .forms-hub-row {
  gap: 1rem;
  background:
    linear-gradient(90deg, #ffffff, #f7fbfd);
}

body.fasa-shell .forms-hub-row__copy strong {
  color: #0b3558;
  font-size: 1.02rem;
}

body.fasa-shell .forms-hub-row__copy span {
  color: #31536f;
}

body.fasa-shell .forms-hub-action--primary {
  border-color: #0f4269;
  background: #0f4269;
}

body.fasa-shell .forms-hub-action--secondary {
  border-color: #7ea2bf;
}

body.fasa-shell :is(.crm-field, .field):has(input[type="file"]) {
  grid-column: 1 / -1;
  max-width: 100%;
}

body.fasa-shell :is(.crm-field, .field):has(input[type="file"]) input[type="file"] {
  width: 100%;
}

/* The Individual pedigree is part of Cat Identity, not a full-width document row. */
body.fasa-shell .crm-shell--compact #individual-registration-request .crm-field:has(#registration_pedigree_file) {
  grid-column: auto;
  max-width: none;
}

@media (min-width: 980px) {
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form,
  body.fasa-shell .page .shell #mainForm {
    display: block;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note {
    float: left;
    clear: left;
    width: min(21rem, 36%);
    margin: 0 1rem 0.95rem 0;
    position: sticky;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note {
    display: block;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note .crm-help-links,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note .crm-help-links {
    display: grid;
    min-width: 0;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note {
    top: 0.85rem;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > :is(.crm-card, .crm-actions--final),
  body.fasa-shell .page .shell #mainForm > .card {
    margin-left: calc(min(21rem, 36%) + 1rem);
  }

  body.fasa-shell .crm-shell--membership-wide .crm-form > .crm-form-stage-note {
    min-height: 19rem;
  }

  body.fasa-shell .page .shell .actions--final {
    margin-left: calc(min(21rem, 36%) + 1rem);
  }
}

@media (max-width: 979px) {
  body.fasa-shell .forms-hub-page .crm-shell--index {
    display: block;
    max-width: 58rem;
    padding: 0;
  }

  body.fasa-shell .forms-hub-hero {
    position: static;
    min-height: 0;
  }

  body.fasa-shell .forms-hub-page .forms-hub-section {
    grid-column: auto;
  }
}

@media (max-width: 760px) {
  body.fasa-shell :is(.crm-header, .page .shell .header) {
    text-align: center;
  }

  body.fasa-shell .forms-hub-summary-list li {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* User correction: keep Forms as plain stacked forms. */
body.fasa-shell .forms-hub-page .crm-shell--index {
  display: block;
  max-width: 64rem;
}

body.fasa-shell .forms-hub-hero {
  position: static;
  min-height: 0;
}

body.fasa-shell .forms-hub-page .forms-hub-section {
  grid-column: auto;
}

@media (min-width: 980px) {
  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form,
  body.fasa-shell .page .shell #mainForm {
    display: block;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note {
    float: none;
    clear: none;
    width: auto;
    margin: 0 0 0.95rem;
    position: static;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > :is(.crm-card, .crm-actions--final),
  body.fasa-shell .page .shell #mainForm > .card,
  body.fasa-shell .page .shell .actions--final {
    margin-left: 0;
  }

  body.fasa-shell .crm-shell--membership-wide .crm-form > .crm-form-stage-note {
    min-height: 0;
  }
}

/* User correction: compact buttons and merge the bottom form review area visually. */
body.fasa-shell .crm-help-links {
  display: flex !important;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
}

body.fasa-shell .crm-help-links a,
body.fasa-shell .forms-hub-quick-links .forms-hub-action,
body.fasa-shell :is(.crm-actions__secondary > *, .crm-actions__primary > *, .page .shell .actions__secondary > *, .page .shell .actions__primary > *) {
  width: auto !important;
  min-width: 9.5rem;
  max-width: 100%;
  justify-self: start;
}

body.fasa-shell .forms-hub-quick-links {
  display: flex !important;
  justify-content: flex-start;
}

body.fasa-shell .forms-hub-page .forms-hub-support-list {
  display: flex !important;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: flex-start;
}

body.fasa-shell .forms-hub-page .forms-hub-support-list li {
  flex: 0 0 auto !important;
  width: auto !important;
}

body.fasa-shell .forms-hub-page .forms-hub-support-link {
  width: auto !important;
  min-width: 9.5rem;
  padding: 0.48rem 0.8rem;
}

body.fasa-shell .crm-help-links a {
  min-height: 2rem;
  padding: 0.38rem 0.75rem;
}

body.fasa-shell :is(input[type="file"], .crm-field input[type="file"], .field input[type="file"]) {
  width: auto !important;
  max-width: 100%;
}

body.fasa-shell :is(
  #membership-fees-payment,
  #honours-fees-payment,
  #individual-fees-payment,
  #litter-fees-payment,
  #prefix-fees-payment
) {
  margin-bottom: 0;
}

body.fasa-shell :is(
  #membership-declaration,
  #honours-declaration,
  #individual-declaration,
  #litter-declaration,
  #prefix-declaration
) {
  margin-top: -0.12rem;
  border-top: 0 !important;
}

body.fasa-shell :is(
  #membership-declaration,
  #honours-declaration,
  #individual-declaration,
  #litter-declaration,
  #prefix-declaration
) :is(.crm-card__header, .card-head) {
  min-height: 2.45rem;
  background: linear-gradient(90deg, #0f4269, #185f88 72%, #2f7d7a) !important;
}

body.fasa-shell :is(
  #membership-declaration,
  #honours-declaration,
  #individual-declaration,
  #litter-declaration,
  #prefix-declaration
) :is(.crm-card__header h2, .card-head h2) {
  color: #ffffff;
  font-size: 0.98rem;
}

body.fasa-shell :is(
  #membership-fees-payment,
  #honours-fees-payment,
  #individual-fees-payment,
  #litter-fees-payment,
  #prefix-fees-payment,
  #membership-declaration,
  #honours-declaration,
  #individual-declaration,
  #litter-declaration,
  #prefix-declaration
) :is(.crm-card__body, .card-body) {
  padding: 0.85rem 1rem !important;
}

body.fasa-shell :is(
  #membership-declaration,
  #honours-declaration,
  #individual-declaration,
  #litter-declaration,
  #prefix-declaration
) :is(.crm-declaration-grid, .declaration-grid, .crm-field:has(#declaration_date_display), .field:has(#declaration_date_display)) {
  display: none !important;
}

body.fasa-shell :is(.crm-payment-summary, .payment-summary) {
  gap: 0.65rem;
}

body.fasa-shell :is(.crm-payment-summary__amount, .payment-summary__amount, .crm-payment-summary__instructions, .payment-summary__instructions) {
  padding: 0.62rem 0.75rem !important;
}

body.fasa-shell :is(.crm-payment-summary, .payment-summary) {
  align-items: stretch;
}

body.fasa-shell :is(.crm-payment-summary__amount, .payment-summary__amount) {
  display: grid;
  align-content: center;
  min-height: 0;
}

body.fasa-shell :is(.crm-payment-summary__amount, .payment-summary__amount) p:not(#form_fee_basis),
body.fasa-shell :is(.crm-payment-steps, .crm-payment-summary ol, .payment-summary ol),
body.fasa-shell :is(#autoReferenceRules, .crm-payment-summary + .crm-grid .crm-help, .payment-summary + .grid .help, .payment-summary + .field .help) {
  display: none !important;
}

body.fasa-shell :is(
  #membership-fees-payment,
  #honours-fees-payment,
  #individual-fees-payment,
  #litter-fees-payment,
  #prefix-fees-payment
) :is(.crm-help, .help):not(#form_fee_basis) {
  display: none !important;
}

body.fasa-shell :is(.crm-payment-summary, .payment-summary) > .crm-note,
body.fasa-shell :is(.crm-payment-summary, .payment-summary) > .note {
  margin: 0;
  padding: 0.62rem 0.75rem !important;
  border-left: 0;
  background: #eef5fb !important;
  box-shadow: inset 0.25rem 0 0 #2f7d7a;
}

body.fasa-shell :is(.crm-payment-summary, .payment-summary) > .crm-note > strong,
body.fasa-shell :is(.crm-payment-summary, .payment-summary) > .note > strong {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.82rem;
  line-height: 1.2;
}

body.fasa-shell :is(.crm-bank-grid, .bank-grid) {
  gap: 0.18rem 0.65rem;
  margin: 0;
}

body.fasa-shell :is(.crm-bank-grid, .bank-grid) dt,
body.fasa-shell :is(.crm-bank-grid, .bank-grid) dd {
  line-height: 1.25;
}

body.fasa-shell .crm-payment-reference-text {
  display: inline-block;
  padding: 0.08rem 0.28rem;
  border: 1px solid rgba(176, 141, 60, 0.45);
  background: #fffaf0;
}

body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-card__body, .card-body) {
  padding-bottom: 0.7rem !important;
}

body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-grid, .grid) {
  margin-top: 0.55rem;
}

body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-field, .field):has(input[type="file"]) {
  padding: 0.55rem 0.65rem;
  border: 1px solid #b8ccdc;
  background: #f8fbfe;
}

body.fasa-shell :is(.crm-actions__buttons--split, .page .shell .buttons--split) {
  align-items: center;
}

/* Keep declaration actions within the declaration card, not in a separate final panel. */
body.fasa-shell .crm-declaration-actions {
  margin-top: 0.9rem;
}

body.fasa-shell .crm-declaration-actions :is(.crm-actions__buttons--split, .buttons--split) {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

/* On desktop, keep the compact number and date columns fixed so Show,
   Affiliation, and Judge and Affiliate share all remaining certificate space. */
@media (min-width: 721px) {
  body.fasa-shell .challenges {
    table-layout: fixed;
  }

  body.fasa-shell .challenges :is(th, td):nth-child(1) {
    width: 6.75rem;
  }

  body.fasa-shell .challenges :is(th, td):nth-child(2) {
    width: 9rem;
  }
}

/* Payment receipt and optional transfer reference share one desktop row. */
@media (min-width: 641px) {
  body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-grid, .grid) {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-field, .field):has(#payment_receipt) {
    grid-column: auto !important;
  }

  body.fasa-shell :is(#membership-fees-payment, #honours-fees-payment, #individual-fees-payment, #litter-fees-payment, #prefix-fees-payment) :is(.crm-field, .field):has(#payment_reference_no) {
    padding: 0.55rem 0.65rem;
    border: 1px solid #b8ccdc;
    background: #f8fbfe;
  }
}

body.fasa-shell :is(.crm-actions__primary, .page .shell .actions__primary) {
  justify-self: end;
}

@media (max-width: 760px) {
  body.fasa-shell .crm-help-links,
  body.fasa-shell .forms-hub-quick-links,
  body.fasa-shell .forms-hub-page .forms-hub-support-list {
    justify-content: center;
  }

  body.fasa-shell .crm-help-links a,
  body.fasa-shell .forms-hub-quick-links .forms-hub-action,
  body.fasa-shell .forms-hub-page .forms-hub-support-link,
  body.fasa-shell :is(.crm-actions__secondary > *, .crm-actions__primary > *, .page .shell .actions__secondary > *, .page .shell .actions__primary > *) {
    min-width: 8.5rem;
  }
}

/* HTML help guides for active Forms. */
body.fasa-shell .forms-help-page .forms-help-shell {
  max-width: 62rem;
}

body.fasa-shell .forms-help-page .crm-header {
  margin-bottom: 0.9rem;
}

body.fasa-shell .forms-help-panel,
body.fasa-shell .forms-help-card {
  border: 1px solid #b9ccda;
  border-radius: 6px;
  background: #fbfdff;
  color: #07355b;
}

body.fasa-shell .forms-help-panel {
  padding: 1rem;
  margin-bottom: 0.85rem;
}

body.fasa-shell .forms-help-panel--lead {
  border-left: 5px solid #b08d3c;
  background: #fffaf0;
}

body.fasa-shell .forms-help-panel h2,
body.fasa-shell .forms-help-card h2 {
  margin: 0 0 0.45rem;
  font-size: 1.05rem;
  line-height: 1.25;
}

body.fasa-shell .forms-help-panel p,
body.fasa-shell .forms-help-card p,
body.fasa-shell .forms-help-panel li {
  font-size: 0.95rem;
  line-height: 1.45;
}

body.fasa-shell .forms-help-panel ul {
  margin: 0.5rem 0 0;
  padding-left: 1.15rem;
}

body.fasa-shell .forms-help-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
  margin-bottom: 0.85rem;
}

body.fasa-shell .forms-help-card {
  padding: 0.9rem;
}

body.fasa-shell .forms-help-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

body.fasa-shell .forms-help-actions a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.1rem;
  min-width: 9.5rem;
  padding: 0.42rem 0.8rem;
  border: 1px solid #7fa4c1;
  background: #f7fbff;
  color: #003b66;
  font-weight: 700;
  text-decoration: none;
}

body.fasa-shell .forms-help-actions a:first-child {
  background: #0f4a73;
  color: #fff;
}

body.fasa-shell .forms-help-note {
  margin: 0.75rem 0 0;
  font-style: italic;
}

/* Mobile header cleanup: keep the menu, lose the oversized form masthead. */
@media (max-width: 760px) {
  body.fasa-shell .fasa-nav {
    padding: 0.45rem 0.75rem;
  }

  body.fasa-shell .fasa-nav .navbar-toggler {
    min-height: 2.35rem;
    padding: 0.42rem 0.75rem;
    font-size: 0.95rem;
  }

  body.fasa-shell .main-content-wrap > :is(.crm-body, .crm-shell, .page) {
    margin-top: 0.35rem;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell, .crm-shell--index) {
    border-radius: 6px;
    background: #f8fbfd !important;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact, .page .shell, .crm-shell--index)::before {
    height: 0.24rem;
  }

  body.fasa-shell :is(.crm-header, .page .shell .header),
  body.fasa-shell .forms-hub-hero {
    padding: 0.42rem 0.6rem 0.46rem !important;
    text-align: left;
  }

  body.fasa-shell :is(.crm-header__top, .page .shell .header-top) {
    gap: 0.28rem;
  }

  body.fasa-shell :is(.crm-kicker, .page .shell .kicker),
  body.fasa-shell .forms-hub-hero .crm-kicker {
    min-height: 0;
    margin: 0 0 0.22rem;
    padding: 0;
    border: 0;
    background: transparent;
    color: #f1d184;
    font-size: 0.68rem;
    line-height: 1.1;
  }

  body.fasa-shell :is(.crm-header h1, .page .shell h1, .crm-title),
  body.fasa-shell .forms-hub-hero .crm-title {
    margin: 0;
    font-size: 1.16rem;
    line-height: 1.05;
  }

  body.fasa-shell :is(.crm-subtitle, .page .shell .subtitle),
  body.fasa-shell .forms-hub-intro {
    display: none;
  }

  body.fasa-shell :is(.crm-header__links, .page .shell .links),
  body.fasa-shell .forms-hub-quick-links {
    justify-content: flex-start;
    gap: 0.35rem;
  }

  body.fasa-shell :is(.crm-header__links a, .page .shell .links a),
  body.fasa-shell .forms-hub-quick-links .forms-hub-action {
    min-height: 1.55rem;
    min-width: 0;
    padding: 0.15rem 0.45rem;
    font-size: 0.72rem;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note {
    padding: 0.58rem 0.68rem !important;
  }

  body.fasa-shell .crm-form-stage-note > strong {
    font-size: 0.9rem;
  }

  body.fasa-shell .crm-form-stage-note .crm-intro-copy,
  body.fasa-shell .crm-form-stage-note li {
    font-size: 0.8rem;
    line-height: 1.22;
  }

  body.fasa-shell .crm-form-stage-note .crm-intro-copy {
    margin: 0.22rem 0;
  }

  body.fasa-shell .crm-form-stage-note ul {
    display: none;
  }

  body.fasa-shell .crm-form-stage-note .crm-help-links {
    display: flex !important;
    flex-wrap: nowrap;
    justify-content: flex-start;
    overflow-x: auto;
    gap: 0.3rem;
    padding-bottom: 0.1rem;
  }

  body.fasa-shell .crm-form-stage-note .crm-help-links a {
    flex: 0 0 auto;
    min-height: 1.75rem;
    min-width: 0;
    padding: 0.22rem 0.48rem;
    font-size: 0.76rem;
    white-space: nowrap;
  }

body.fasa-shell .crm-form-stage-note .crm-help-qualification {
  display: none;
}

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form {
    padding-top: 0.45rem;
  }

  body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form > .crm-form-stage-note,
  body.fasa-shell .page .shell #mainForm > .crm-form-stage-note {
    margin-bottom: 0.65rem;
  }

  body.fasa-shell .forms-help-page .forms-help-panel {
    padding: 0.78rem;
    margin-bottom: 0.65rem;
  }

  body.fasa-shell .forms-help-page .forms-help-card {
    padding: 0.75rem;
  }
}

@media (max-width: 760px) {
  body.fasa-shell .forms-help-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  body.fasa-shell .forms-help-actions {
    justify-content: center;
  }

  body.fasa-shell .forms-help-actions a,
  body.fasa-shell .forms-hub-page .forms-hub-row__actions .forms-hub-action,
  body.fasa-shell :is(.crm-actions__secondary > *, .crm-actions__primary > *, .page .shell .actions__secondary > *, .page .shell .actions__primary > *) {
    width: auto !important;
    min-width: 8.5rem;
  }

  body.fasa-shell .forms-hub-page .forms-hub-row__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    justify-content: center;
  }

  body.fasa-shell :is(.crm-actions__secondary, .crm-actions__primary, .page .shell .actions__secondary, .page .shell .actions__primary) {
    justify-self: center;
  }
}

/* Membership form: shallow South Australia and cats header. */
body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header {
  position: relative;
  min-height: 7rem;
  margin-bottom: 0.55rem;
  padding: 0.55rem 0.9rem 0.65rem !important;
  background:
    linear-gradient(90deg, rgba(3, 24, 55, 0.5), rgba(5, 34, 70, 0.68) 42%, rgba(5, 34, 70, 0.68) 58%, rgba(3, 24, 55, 0.5)),
    url("membership-sa-cats-header.png") center 52% / cover no-repeat !important;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header__top {
  gap: 0.3rem;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-kicker {
  position: absolute;
  top: 0.45rem;
  left: 0.7rem;
  min-height: 1.2rem;
  margin: 0;
  padding: 0.05rem 0.45rem;
  font-size: 0.62rem;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header h1 {
  margin-bottom: 0.2rem;
  font-size: clamp(1.4rem, 2.5vw, 1.9rem);
  line-height: 1;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-subtitle {
  max-width: 42rem;
  font-size: 0.78rem;
  line-height: 1.22;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header__links {
  gap: 0.4rem;
}

body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header__links a {
  min-height: 1.8rem;
  padding: 0.2rem 0.7rem;
  font-size: 0.76rem;
}

/* Principal-form header actions and concise start notes. */
body.fasa-shell :is(.crm-header__links, .page .shell .links) {
  max-width: 58rem;
}

body.fasa-shell :is(.crm-shell--membership-wide, .crm-shell--compact) .crm-form-stage-note--compact,
body.fasa-shell .page .shell .crm-form-stage-note--compact {
  gap: 0.2rem;
  margin-bottom: 0.55rem;
  padding: 0.55rem 0.7rem;
}

body.fasa-shell .crm-form-stage-note--compact > strong {
  font-size: 0.84rem;
  line-height: 1.1;
}

body.fasa-shell .crm-form-stage-note--compact > strong::after {
  width: 2.2rem;
  height: 0.12rem;
  margin-top: 0.18rem;
}

body.fasa-shell .crm-form-stage-note--compact .crm-intro-copy,
body.fasa-shell .crm-form-stage-note--compact li {
  font-size: 0.78rem;
  line-height: 1.2;
}

body.fasa-shell .crm-form-stage-note--compact .crm-intro-copy {
  margin: 0;
}

body.fasa-shell .crm-form-stage-note--compact ul {
  display: grid;
  gap: 0.08rem;
  margin: 0;
  padding-left: 1rem;
}

@media (max-width: 520px) {
  body.fasa-shell .crm-body .crm-shell--membership-wide .crm-header {
    min-height: 0;
    padding: 0.45rem 0.6rem 0.5rem !important;
    background-position: center;
  }
}

/* Compact Forms index: active online forms only. */
body.fasa-shell .forms-hub-page .forms-hub-summary-list,
body.fasa-shell .forms-hub-page .forms-hub-quick-links,
body.fasa-shell .forms-hub-page .forms-hub-row--portal,
body.fasa-shell .forms-hub-page .forms-hub-list--online .forms-hub-row__actions .forms-hub-action--secondary {
  display: none !important;
}

body.fasa-shell .forms-hub-page .forms-hub-hero {
  padding-bottom: 0.8rem;
}

body.fasa-shell .forms-hub-page .forms-hub-section--online {
  margin-top: 0;
}

/* Fillable PDFs are simple reference lines rather than application cards. */
body.fasa-shell .forms-hub-pdf-summary {
  display: grid;
  gap: 0.4rem;
  margin: 0.55rem 0 0;
  padding: 0;
  list-style: none;
}

body.fasa-shell .forms-hub-pdf-summary li,
body.fasa-shell .forms-hub-pdf-summary-line {
  margin: 0;
  color: #425b71;
  line-height: 1.45;
}

body.fasa-shell .forms-hub-pdf-summary a {
  color: #0f4c72;
  font-weight: 700;
}

body.fasa-shell .forms-hub-page .forms-hub-section__header {
  margin-bottom: 0.35rem;
}

body.fasa-shell .forms-hub-page .forms-hub-section__header > p {
  display: none;
}

/* Honours form: compact, unique awards-themed header. */
body.fasa-shell .crm-shell--compact .crm-header.crm-header--honours {
  position: relative;
  min-height: 7rem;
  margin-bottom: 0.55rem;
  padding: 0.55rem 0.9rem 0.65rem !important;
  background:
    linear-gradient(90deg, rgba(4, 20, 43, 0.46), rgba(4, 28, 59, 0.72) 42%, rgba(4, 28, 59, 0.72) 58%, rgba(4, 20, 43, 0.46)),
    url("honours-awards-cats-header.png") center 54% / cover no-repeat !important;
}

body.fasa-shell .crm-shell--compact .crm-header--honours .crm-header__top {
  gap: 0.3rem;
}

body.fasa-shell .crm-shell--compact .crm-header--honours .crm-kicker {
  position: absolute;
  top: 0.45rem;
  left: 0.7rem;
  min-height: 1.2rem;
  margin: 0;
  padding: 0.05rem 0.45rem;
  font-size: 0.62rem;
}

body.fasa-shell .crm-shell--compact .crm-header--honours h1 {
  margin-bottom: 0.2rem;
  font-size: clamp(1.4rem, 2.5vw, 1.9rem);
  line-height: 1;
}

body.fasa-shell .crm-shell--compact .crm-header--honours .crm-subtitle {
  max-width: 42rem;
  font-size: 0.78rem;
  line-height: 1.22;
}

body.fasa-shell .crm-shell--compact .crm-header--honours .crm-header__links {
  gap: 0.4rem;
}

body.fasa-shell .crm-shell--compact .crm-header--honours .crm-header__links a {
  min-height: 1.8rem;
  padding: 0.2rem 0.7rem;
  font-size: 0.76rem;
}

@media (max-width: 520px) {
  body.fasa-shell .crm-shell--compact .crm-header.crm-header--honours {
    min-height: 0;
    padding: 0.45rem 0.6rem 0.5rem !important;
    background-position: center;
  }
}

/* Individual, litter, and prefix forms: unique half-height themed headers. */
body.fasa-shell .crm-shell--compact .crm-header.crm-header--individual,
body.fasa-shell .page .shell .header.header--litter,
body.fasa-shell .page .shell .header.header--prefix {
  position: relative;
  min-height: 7rem;
  margin-bottom: 0.55rem;
  padding: 0.55rem 0.9rem 0.65rem !important;
}

body.fasa-shell .crm-shell--compact .crm-header.crm-header--individual {
  background:
    linear-gradient(90deg, rgba(3, 20, 44, 0.48), rgba(4, 27, 57, 0.74) 42%, rgba(4, 27, 57, 0.74) 58%, rgba(3, 20, 44, 0.48)),
    url("individual-registration-cats-header.png") center 52% / cover no-repeat !important;
}

body.fasa-shell .page .shell .header.header--litter {
  background:
    linear-gradient(90deg, rgba(3, 20, 44, 0.46), rgba(4, 27, 57, 0.72) 42%, rgba(4, 27, 57, 0.72) 58%, rgba(3, 20, 44, 0.46)),
    url("litter-registration-cats-header.png") center 48% / cover no-repeat !important;
}

body.fasa-shell .page .shell .header.header--prefix {
  background:
    linear-gradient(90deg, rgba(3, 20, 44, 0.44), rgba(4, 27, 57, 0.72) 42%, rgba(4, 27, 57, 0.72) 58%, rgba(3, 20, 44, 0.44)),
    url("prefix-application-cats-header.png") center 45% / cover no-repeat !important;
}

body.fasa-shell .crm-shell--compact .crm-header--individual .crm-header__top,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) .header-top {
  gap: 0.3rem;
}

body.fasa-shell .crm-shell--compact .crm-header--individual .crm-kicker,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) .kicker {
  position: absolute;
  top: 0.45rem;
  left: 0.7rem;
  min-height: 1.2rem;
  margin: 0;
  padding: 0.05rem 0.45rem;
  font-size: 0.62rem;
}

body.fasa-shell .crm-shell--compact .crm-header--individual h1,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) h1 {
  margin-bottom: 0.2rem;
  font-size: clamp(1.4rem, 2.5vw, 1.9rem);
  line-height: 1;
}

body.fasa-shell .crm-shell--compact .crm-header--individual .crm-subtitle,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) .subtitle {
  max-width: 42rem;
  font-size: 0.78rem;
  line-height: 1.22;
}

body.fasa-shell .crm-shell--compact .crm-header--individual .crm-header__links,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) .links {
  gap: 0.4rem;
}

body.fasa-shell .crm-shell--compact .crm-header--individual .crm-header__links a,
body.fasa-shell .page .shell :is(.header--litter, .header--prefix) .links a {
  min-height: 1.8rem;
  padding: 0.2rem 0.7rem;
  font-size: 0.76rem;
}

@media (max-width: 520px) {
  body.fasa-shell .crm-shell--compact .crm-header.crm-header--individual,
  body.fasa-shell .page .shell .header.header--litter,
  body.fasa-shell .page .shell .header.header--prefix {
    min-height: 0;
    padding: 0.45rem 0.6rem 0.5rem !important;
    background-position: center;
  }
}
