:root {
  --xestui-form-success: #dff3e7;
  --xestui-form-error: #fde8e4;
}

body.admin-bar .site-header {
  top: 32px;
}

@media (max-width: 782px) {
  body.admin-bar .site-header {
    top: 46px;
  }
}

.xestui-form-status {
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  border-radius: 0.75rem;
  background: var(--xestui-form-success);
  color: #112a1c;
  font-weight: 700;
}

.xestui-form-status.is-error {
  background: var(--xestui-form-error);
  color: #7a241c;
}

.xestui-field-error {
  margin: 0.4rem 0 0;
  color: #8c2f27;
  font-size: 0.9rem;
}

[aria-invalid="true"] {
  outline: 2px solid #b74637;
  outline-offset: 2px;
}

.xestui-resource-modal[hidden] {
  display: none !important;
}

.xestui-resource-modal {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: grid;
  place-items: center;
  padding: clamp(0.75rem, 2vw, 1.75rem);
  background: rgba(5, 18, 11, 0.86);
  backdrop-filter: blur(10px);
}

.xestui-resource-dialog {
  position: relative;
  width: min(1180px, 100%);
  max-height: calc(100vh - 2rem);
  overflow: hidden;
  border-radius: 1.25rem;
  background: #f8faf8;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.42);
}

.xestui-resource-dialog header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem 1rem;
  background: #112a1c;
  color: #fff;
}

.xestui-resource-dialog h2 {
  margin: 0;
  color: inherit;
  font-size: clamp(1rem, 2vw, 1.35rem);
}

.xestui-resource-close {
  display: inline-grid;
  width: 2.75rem;
  height: 2.75rem;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 50%;
  background: transparent;
  color: #fff;
  cursor: pointer;
}

.xestui-resource-content {
  display: grid;
  max-height: calc(100vh - 7rem);
  place-items: center;
  overflow: auto;
  background: #eef3ef;
}

.xestui-resource-content iframe {
  width: 100%;
  min-height: min(760px, calc(100vh - 7rem));
  border: 0;
  background: #fff;
}

.xestui-resource-content img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: auto;
}

.xestui-resource-content figure {
  margin: 0;
  padding: 1rem;
}

.xestui-resource-content figcaption {
  margin-top: 0.75rem;
  text-align: center;
}

.xestui-resource-modal [data-modal-sentinel] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.xestui-v34-fallback {
  width: min(920px, calc(100% - 2rem));
  margin: 10rem auto 5rem;
}

.xestui-v34-fallback a {
  color: #12633a;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
  }

  [data-reveal] {
    transition: none !important;
  }
}
