/* My12 onboarding presentation only.
 * Keep this canonical file identical to both app public copies.
 * These DOM scopes also match the currently published JavaScript. They stop
 * matching after account creation, so organisation setup remains unchanged.
 */

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) {
  --color-primary: #0f2f85;
  --color-primary-light: #2563eb;
  --color-background: #f6f9ff;
  --color-surface: #ffffff;
  --color-border: #dbe4f0;
  --color-text-primary: #132344;
  --color-text-secondary: #526482;
  font-family: "DM Sans", sans-serif;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.55;
  color: #132344;
  letter-spacing: normal;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where(h1, h2, h3, h4, h5, h6) {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.25;
  text-wrap: balance;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where([class~="uppercase"]) {
  text-transform: none;
  letter-spacing: normal;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where([class~="font-black"], [class~="font-bold"], [class~="font-semibold"]) {
  font-weight: 600;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where([class~="text-[9px]"], [class~="text-[10px]"], [class~="text-[11px]"]) {
  font-size: 13px;
  font-weight: 500;
  line-height: 1.5;
  text-transform: none;
  letter-spacing: normal;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where([class~="text-xs"]) {
  font-size: 14px;
  line-height: 1.5;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where(p[class~="text-sm"], p[class~="text-base"], p[class~="text-lg"]) {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.65;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where([class~="text-slate-400"]) {
  color: #61718b;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where(button, a[class*="inline-flex"]),
:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where(button, a[class*="inline-flex"]):hover {
  min-height: 44px;
  border-radius: 12px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: normal;
  text-transform: none;
  transform: none;
  translate: none;
  scale: none;
  transition-property: background-color, border-color, color, box-shadow;
  transition-duration: 160ms;
  box-shadow: none;
}

:is(
  #root > div:has(input[aria-label="Locations"]),
  #root > div:has(input[placeholder="admin@church.org"])
) :where(button, a, input):focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 3px;
}

/* Calculator: keep every bundle, quote, add-on and trial rule in the DOM. */
#root > div:has(input[aria-label="Locations"]) {
  background-color: #f6f9ff;
}

#root > div:has(input[aria-label="Locations"]) > header {
  background-color: #ffffff;
  border-bottom-color: #dbe4f0;
  box-shadow: 0 1px 0 rgb(15 47 133 / 3%);
}

#root > div:has(input[aria-label="Locations"]) > header > div {
  padding-top: 14px;
  padding-bottom: 14px;
}

#root > div:has(input[aria-label="Locations"]) > header a:first-child :where(img, [role="img"]) {
  width: 132px;
  height: 44px;
}

#root > div:has(input[aria-label="Locations"]) > main {
  padding-top: clamp(28px, 4vw, 48px);
  padding-bottom: 64px;
}

#root > div:has(input[aria-label="Locations"]) h1 {
  max-width: 760px;
  font-size: clamp(32px, 4.2vw, 48px);
  font-weight: 600;
  line-height: 1.15;
  color: #0f2f85;
}

#root > div:has(input[aria-label="Locations"]) h2 {
  font-size: 24px;
  font-weight: 600;
  line-height: 1.3;
}

#root > div:has(input[aria-label="Locations"]) :where([class~="rounded-[24px]"], [class~="rounded-[28px]"]) {
  border-radius: 18px;
}

#root > div:has(input[aria-label="Locations"]) :where([class~="shadow-sm"], [class~="shadow-xl"], [class~="shadow-2xl"]) {
  box-shadow: 0 6px 24px rgb(15 47 133 / 5%);
}

#root > div:has(input[aria-label="Locations"]) :where(input[type="number"]) {
  min-height: 44px;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.4;
  color: #0f2f85;
}

#root > div:has(input[aria-label="Locations"]) :where(input[type="range"]) {
  min-height: 32px;
  accent-color: #0f2f85;
  cursor: pointer;
}

#root > div:has(input[aria-label="Locations"]) :where(button[aria-label^="Increase"], button[aria-label^="Decrease"]) {
  width: 44px;
  min-width: 44px;
  height: 44px;
}

#root > div:has(input[aria-label="Locations"]) :where(button[aria-pressed]) {
  min-width: 0;
  border-radius: 18px;
  padding: 20px;
  box-shadow: 0 3px 14px rgb(15 47 133 / 4%);
}

#root > div:has(input[aria-label="Locations"]) :where(button[aria-pressed="true"]) {
  color: #ffffff;
  background-color: #0f2f85;
  border-color: #0f2f85;
  box-shadow: 0 0 0 2px rgb(15 47 133 / 14%);
}

#root > div:has(input[aria-label="Locations"]) :where(button[aria-pressed] > div:first-child p:first-child) {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.35;
}

#root > div:has(input[aria-label="Locations"]) :where(button[aria-pressed] p[class~="text-3xl"]) {
  font-size: 28px;
  font-weight: 600;
  line-height: 1.2;
}

#root > div:has(input[aria-label="Locations"]) :where(aside > div) {
  border-radius: 18px;
  color: #ffffff;
  background-color: #0f2f85;
  box-shadow: 0 12px 36px rgb(15 47 133 / 12%);
}

#root > div:has(input[aria-label="Locations"]) :where(aside p[class~="text-4xl"]) {
  font-size: 30px;
  font-weight: 600;
  line-height: 1.2;
}

#root > div:has(input[aria-label="Locations"]) :where(aside p[class~="text-5xl"]) {
  font-size: 44px;
  font-weight: 600;
  line-height: 1.15;
}

#root > div:has(input[aria-label="Locations"]) :where(aside [class*="text-white/"], button[aria-pressed="true"] [class*="text-white/"]) {
  color: #e2eafe;
}

#root > div:has(input[aria-label="Locations"]) :where(aside [class*="text-primary/"]) {
  color: #526482;
}

/* Authentication only: exact root overrides its existing inline gradient. */
#root > div:has(input[placeholder="admin@church.org"]) {
  min-height: 100dvh;
  padding: clamp(24px, 4vw, 48px) 20px;
  background: #f6f9ff !important;
  color: #132344;
}

#root > div:has(input[placeholder="admin@church.org"]) > div.absolute {
  display: none;
}

#root > div:has(input[placeholder="admin@church.org"]) > div.relative {
  width: 100%;
  max-width: 480px;
}

#root > div:has(input[placeholder="admin@church.org"]) > div.relative > div.text-center {
  margin-bottom: 28px;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(div[class~="w-28"][class~="h-28"]) {
  width: 64px;
  height: 64px;
  margin-bottom: 16px;
  background-color: #ffffff;
  border: 1px solid #dbe4f0;
  border-radius: 16px;
  box-shadow: 0 4px 16px rgb(15 47 133 / 5%);
  transform: none;
  rotate: none;
  backdrop-filter: none;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(div[class~="w-28"][class~="h-28"] img) {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  filter: none;
}

#root > div:has(input[placeholder="admin@church.org"]) h1 {
  font-size: clamp(28px, 4vw, 34px);
  font-weight: 600;
  line-height: 1.2;
  color: #0f2f85;
}

#root > div:has(input[placeholder="admin@church.org"]) :where([class~="text-blue-200"], [class*="text-white/"]) {
  color: #526482;
}

#root > div:has(input[placeholder="admin@church.org"]) > div.relative > div.bg-white {
  border: 1px solid #dbe4f0;
  border-radius: 20px;
  padding: clamp(24px, 4vw, 36px);
  background-color: #ffffff;
  color: #132344;
  box-shadow: 0 10px 40px rgb(15 47 133 / 7%);
}

#root > div:has(input[placeholder="admin@church.org"]) h2 {
  font-size: clamp(22px, 3vw, 25px);
  font-weight: 600;
  line-height: 1.3;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(h2 + p, .text-center > p[class~="text-sm"]) {
  font-size: 16px;
  font-weight: 400;
  line-height: 1.6;
  color: #526482;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(label) {
  font-size: 13px;
  font-weight: 600;
  line-height: 1.5;
  color: #334155;
  letter-spacing: normal;
  text-transform: none;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(input) {
  min-height: 48px;
  border: 1px solid #ccd8e8;
  border-radius: 12px;
  padding-top: 12px;
  padding-bottom: 12px;
  background-color: #fbfdff;
  font-size: 16px;
  font-weight: 400;
  line-height: 1.5;
  color: #132344;
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(input)::placeholder {
  color: #75839a;
  opacity: 1;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(input):focus {
  border-color: #2563eb;
  background-color: #ffffff;
  box-shadow: 0 0 0 3px rgb(37 99 235 / 12%);
}

#root > div:has(input[placeholder="admin@church.org"]) :where(form button:not([type="button"])) {
  min-height: 48px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  background-color: #0f2f85;
  color: #ffffff;
}

#root > div:has(input[placeholder="admin@church.org"]) :where(form button:not([type="button"]) span) {
  font-size: 16px;
  font-weight: 600;
  letter-spacing: normal;
  text-transform: none;
}

#root > div:has(input[placeholder="admin@church.org"]) > div.relative > p:last-child {
  margin-top: 24px;
  font-size: 12px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: normal;
  text-transform: none;
  color: #61718b;
}

@media (max-width: 479px) {
  #root > div:has(input[aria-label="Locations"]) > header > div,
  #root > div:has(input[aria-label="Locations"]) > main {
    padding-left: 16px;
    padding-right: 16px;
  }

  #root > div:has(input[aria-label="Locations"]) > header a:last-child {
    padding-left: 12px;
    padding-right: 12px;
    font-size: 13px;
  }

  #root > div:has(input[aria-label="Locations"]) > header a:first-child :where(img, [role="img"]) {
    width: 112px;
    height: 40px;
  }

  #root > div:has(input[placeholder="admin@church.org"]) {
    padding: 24px 16px;
  }

  #root > div:has(input[placeholder="admin@church.org"]) > div.relative > div.bg-white {
    padding: 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  :is(
    #root > div:has(input[aria-label="Locations"]),
    #root > div:has(input[placeholder="admin@church.org"])
  ),
  :is(
    #root > div:has(input[aria-label="Locations"]),
    #root > div:has(input[placeholder="admin@church.org"])
  ) * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Keep larger labels readable inside the calculator's narrower left column. */
#root > div:has(input[aria-label="Locations"]) main section > div > div:has(> button[aria-pressed]) {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (min-width: 1024px) and (max-width: 1279px) {
  #root > div:has(input[aria-label="Locations"]) main section > div > div:has(input[aria-label="Locations"]) {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 479px) {
  #root > div:has(input[aria-label="Locations"]) main section > div > div:has(> button[aria-pressed]) {
    grid-template-columns: 1fr;
  }
}
