/* AMOON SJC v1.10.19 — light-theme contrast contract.
 * A light surface always owns dark foreground colours. This intentionally
 * outranks global theme rules that otherwise leave white text on pale cards. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-shell {
  --sjc-light-surface: #fffaf0;
  --sjc-light-surface-2: #f3eadb;
  --sjc-light-ink: #171b22;
  --sjc-light-copy: #45505b;
  --sjc-light-accent: #74162e;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-section,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-disclaimer {
  background: linear-gradient(145deg, var(--sjc-light-surface), var(--sjc-light-surface-2)) !important;
  border-color: rgba(113, 80, 17, .24) !important;
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-section :is(h1, h2, h3, h4, strong, b),
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-disclaimer :is(h1, h2, h3, h4, strong, b) {
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-section :is(p, small, figcaption),
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-disclaimer :is(p, small, figcaption) {
  color: var(--sjc-light-copy) !important;
  -webkit-text-fill-color: var(--sjc-light-copy) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-section-head > span {
  color: var(--sjc-light-accent) !important;
  -webkit-text-fill-color: var(--sjc-light-accent) !important;
}

/* Court-location cards shown in the screenshot. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a {
  background: linear-gradient(145deg, #fffdf8, #eee5d5) !important;
  border-color: rgba(113, 80, 17, .27) !important;
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
  box-shadow: 0 10px 24px rgba(65, 43, 8, .08) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a strong,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a strong {
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a span,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a span {
  color: var(--sjc-light-accent) !important;
  -webkit-text-fill-color: var(--sjc-light-accent) !important;
  text-shadow: none !important;
}

/* Impact cards. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-cards article {
  background: linear-gradient(145deg, #fffdf8, #eee5d5) !important;
  border-color: rgba(113, 80, 17, .27) !important;
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
  box-shadow: 0 10px 24px rgba(65, 43, 8, .08) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-cards article :is(b, h3) {
  color: var(--sjc-light-accent) !important;
  -webkit-text-fill-color: var(--sjc-light-accent) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-cards article p {
  color: var(--sjc-light-copy) !important;
  -webkit-text-fill-color: var(--sjc-light-copy) !important;
}

/* Project cards and media captions. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card {
  background: #fffaf0 !important;
  border-color: rgba(113, 80, 17, .28) !important;
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card :is(h3, strong) {
  color: var(--sjc-light-ink) !important;
  -webkit-text-fill-color: var(--sjc-light-ink) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card p {
  color: var(--sjc-light-copy) !important;
  -webkit-text-fill-color: var(--sjc-light-copy) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card :is(.sjc-court-label, a) {
  color: var(--sjc-light-accent) !important;
  -webkit-text-fill-color: var(--sjc-light-accent) !important;
  text-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-media {
  background: #fffdf8 !important;
  border-color: rgba(113, 80, 17, .25) !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-media figcaption {
  background: #fffdf8 !important;
  color: var(--sjc-light-copy) !important;
  -webkit-text-fill-color: var(--sjc-light-copy) !important;
}

/* Pale and gold actions always use dark text. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-btn:not(.primary),
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-inline-actions .primary,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-inline-pencil:is(:hover, :focus-visible) {
  color: #171106 !important;
  -webkit-text-fill-color: #171106 !important;
  text-shadow: none !important;
}

/* v1.10.20 — the SJC case study is an intentionally dark project canvas.
 * Light Theme may change the global shell, but it must never bleach individual
 * SJC controls or cards inside this dark canvas. */
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-approved-copy .sjc-btn:not(.primary) {
  background: #0b1019 !important;
  background-image: none !important;
  border-color: rgba(226, 189, 90, .42) !important;
  color: #f2cf69 !important;
  -webkit-text-fill-color: #f2cf69 !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a {
  background: linear-gradient(145deg, #101622, #090d14) !important;
  border-color: rgba(226, 189, 90, .26) !important;
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
  box-shadow: none !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a strong,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a strong {
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-location-edit-wrap > a span,
html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-court-grid > a span {
  color: #e2bd5a !important;
  -webkit-text-fill-color: #e2bd5a !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card {
  background: #090d15 !important;
  background-image: none !important;
  border-color: rgba(226, 189, 90, .30) !important;
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card :is(h3, strong) {
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card p {
  color: #b8c1ce !important;
  -webkit-text-fill-color: #b8c1ce !important;
}

html[data-amoon-theme="light"] body.amoon-sjc-case-route .sjc-feature-card :is(.sjc-court-label, a) {
  color: #e2bd5a !important;
  -webkit-text-fill-color: #e2bd5a !important;
}

.sjc-add-module-button {
  appearance: none !important;
  cursor: pointer !important;
  font-family: inherit !important;
}

.sjc-inline-actions .sjc-inline-delete {
  margin-right: auto !important;
  border-color: rgba(223, 69, 96, .62) !important;
  background: rgba(116, 18, 42, .24) !important;
  color: #ff9aaa !important;
  -webkit-text-fill-color: #ff9aaa !important;
}

.sjc-inline-actions .sjc-inline-delete:hover,
.sjc-inline-actions .sjc-inline-delete:focus-visible {
  background: #8b1635 !important;
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
}

/* v1.10.21 — unconditional SJC canvas isolation. The live screenshots show
 * that another late stylesheet can bleach these controls even when the HTML
 * theme flag is not "light", so this rule intentionally does not depend on it. */
html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-approved-copy .sjc-btn:not(.primary) {
  background: #0b1019 !important;
  background-image: none !important;
  border-color: rgba(226, 189, 90, .42) !important;
  color: #f2cf69 !important;
  -webkit-text-fill-color: #f2cf69 !important;
  text-shadow: none !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-location-edit-wrap > a,
html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-court-grid > a {
  background: #0b111a !important;
  background-image: linear-gradient(145deg, #111824, #080c13) !important;
  border-color: rgba(226, 189, 90, .28) !important;
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
  box-shadow: none !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-location-edit-wrap > a strong,
html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-court-grid > a strong {
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
  text-shadow: none !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-location-edit-wrap > a span,
html body.amoon-sjc-public-route.amoon-sjc-case-route main.sjc-shell .sjc-court-grid > a span {
  color: #e2bd5a !important;
  -webkit-text-fill-color: #e2bd5a !important;
  text-shadow: none !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog {
  width: min(590px, calc(100vw - 32px)) !important;
  max-width: calc(100vw - 32px) !important;
  overflow-x: hidden !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog form,
html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog label,
html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog input,
html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog textarea,
html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog select {
  min-width: 0 !important;
  max-width: 100% !important;
}

html body.amoon-sjc-public-route.amoon-sjc-case-route .sjc-inline-dialog input[name="title"] {
  appearance: none !important;
  -webkit-appearance: none !important;
  background-color: #07111a !important;
  background-image: none !important;
  padding-right: 11px !important;
}

.sjc-add-court-card {
  min-height: 320px !important;
  appearance: none !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 9px !important;
  padding: 22px !important;
  border: 1px dashed rgba(226, 189, 90, .48) !important;
  border-radius: 16px !important;
  background: linear-gradient(145deg, #0d131d, #070b12) !important;
  color: #f2cf69 !important;
  -webkit-text-fill-color: #f2cf69 !important;
  font-family: inherit !important;
  cursor: pointer !important;
}

.sjc-add-court-card i {
  color: #e2bd5a !important;
  -webkit-text-fill-color: #e2bd5a !important;
  font-size: 30px !important;
  font-style: normal !important;
}

.sjc-add-court-card strong {
  color: #f7f8fb !important;
  -webkit-text-fill-color: #f7f8fb !important;
  font-size: 15px !important;
}

.sjc-add-court-card small {
  color: #9fa9b7 !important;
  -webkit-text-fill-color: #9fa9b7 !important;
  font-size: 10px !important;
}
