
.cedar-staff-list {
  display: grid;
  gap: 1.5rem;
}

.cedar-staff-card {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: minmax(0, 140px) minmax(0, 1fr);
  align-items: start;
}

.cedar-staff-card__photo img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 0.75rem;
}

.cedar-staff-card__name {
  margin: 0 0 0.35rem;
}

.cedar-staff-card__title,
.cedar-staff-card__email {
  margin: 0 0 0.75rem;
}

.cedar-staff-card__bio > :first-child {
  margin-top: 0;
}

.cedar-staff-card__bio > :last-child {
  margin-bottom: 0;
}

.cedar-staff-card__actions {
  margin-top: 1rem;
}


.cedar-staff-message-block {
  display: inline-block;
}

.cedar-staff-message-block .cedar-staff-message {
  display: inline-block;
}

.cedar-staff-message-block {
  display: inline-block;
}

.cedar-staff-message__trigger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  min-height: 0;
  cursor: pointer;
  appearance: none;
  text-decoration: none;
  transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease, opacity 0.25s ease;
}

.cedar-staff-message__trigger:hover {
  opacity: 0.92;
}

.cedar-staff-message__trigger:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

.cedar-staff-message-block.is-style-text .cedar-staff-message__trigger:hover {
  text-decoration: underline;
}


.cedar-staff-message__result {
  margin-top: 1rem;
}

.cedar-staff-message__modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 9998;
  padding: 20px;
}

.cedar-staff-message__modal.is-visible {
  display: flex;
  align-items: center;
  justify-content: center;
}

.cedar-staff-message__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
}

.cedar-staff-message__dialog {
  position: relative;
  z-index: 1;
  width: min(100%, 560px);
  max-height: calc(100vh - 40px);
  overflow: auto;
  background: #fff;
  border-radius: 10px;
  padding: 28px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.cedar-staff-message__close {
  position: absolute;
  top: 12px;
  right: 14px;
  border: none;
  background: transparent;
  font-size: 28px;
  line-height: 1;
  cursor: pointer;
}

.cedar-staff-message__intro {
  margin-top: -0.25rem;
  margin-bottom: 1rem;
}

.cedar-staff-form {
  max-width: 500px;
  padding: 20px;
  background: rgba(50, 50, 50, 0.05);
  border-radius: 8px;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(235, 235, 235, 0.3);
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

.cedar-staff-form label {
  font-weight: 600;
  margin-bottom: 4px;
  display: inline-block;
  color: var(--wp--preset--color--primary);
}

.cedar-staff-form input[type="text"],
.cedar-staff-form input[type="email"],
.cedar-staff-form textarea {
  width: 100%;
  padding: 10px 12px;
  margin-top: 4px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.4);
  border: none;
  font-size: 15px;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
}

.cedar-staff-form input:focus,
.cedar-staff-form textarea:focus {
  border-color: var(--wp--preset--color--primary);
  outline: none;
}

.cedar-staff-form textarea {
  min-height: 120px;
  resize: vertical;
}

.cedar-staff-form button,
.scf-send-final,
.scf-cancel {
  padding: 12px 18px;
  font-size: 16px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  transition: background 0.25s ease, opacity 0.25s ease;
}

.cedar-staff-form button,
.scf-send-final {
  background: var(--wp--preset--color--primary);
  color: #fff;
}

.cedar-staff-form button:hover,
.scf-send-final:hover {
  background: var(--wp--preset--color--primary);
}

.cedar-staff-form button:disabled,
.scf-send-final:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.scf-cancel {
  background: #ddd;
  color: #222;
}

.scf-submit-row {
  margin-top: 10px;
}

.scf-notice {
  display: none;
  padding: 12px;
  margin-bottom: 16px;
  border-radius: 6px;
}

.scf-notice:not(:empty) {
  display: block;
}

.scf-notice-success {
  background: var(--wp--preset--color--accent);
  border: 1px solid var(--wp--preset--color--gray);
  color: white;
}

.scf-notice-error {
  background: #fdeaea;
  border: 1px solid #e29a9a;
  color: #8a1f1f;
}

.scf-hp {
  position: absolute !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.scf-confirmation {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9999;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.scf-confirmation.is-visible {
  display: flex;
}

.scf-confirmation-box {
  max-width: 480px;
  width: 100%;
  background: #fff;
  border-radius: 10px;
  padding: 28px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.scf-confirmation-box p {
  overflow-wrap: anywhere;
}

.scf-send-final {
  margin-right: 10px;
}

@media (max-width: 640px) {
  .cedar-staff-card {
    grid-template-columns: 1fr;
  }

  .cedar-staff-card__photo {
    max-width: 220px;
  }

  .cedar-staff-message__dialog {
    padding: 22px 18px;
  }

  .cedar-staff-form {
    padding: 16px;
  }
}


.wp-block-cedar-companion-staff-field,
.wp-block-cedar-companion-staff-message,
.wp-block-cedar-companion-staff-link {
  max-width: 100%;
}

.cedar-staff-field__image,
.wp-block-cedar-companion-staff-field img {
  display: block;
  max-width: 100%;
  height: auto;
}

.cedar-staff-field__text {
  margin: 0;
}

.cedar-staff-field__link {
  color: inherit;
  text-decoration: none;
}

.cedar-staff-field__link:hover,
.cedar-staff-field__email-link:hover {
  text-decoration: underline;
}

.wp-block-cedar-companion-staff-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
}

.wp-block-cedar-companion-staff-link:not(.has-background) {
  padding: 0;
}

.wp-block-cedar-companion-staff-link.has-background {
  padding: 0.75rem 1rem;
}


.wp-block-group.is-style-cedar-staff-card-portrait {
  border: 1px solid var(--wp--preset--color--contrast-3, rgba(0, 0, 0, 0.08));
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.08);
}

.wp-block-group.is-style-cedar-staff-card-portrait .wp-block-columns {
  align-items: center;
}

.wp-block-group.is-style-cedar-staff-card-compact {
  border: 1px solid var(--wp--preset--color--contrast-3, rgba(0, 0, 0, 0.08));
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}

.wp-block-group.is-style-cedar-staff-card-compact .wp-block-columns {
  gap: var(--wp--preset--spacing--30, 1rem);
}

.wp-block-group.is-style-cedar-staff-card-compact .wp-block-column:first-child {
  flex-basis: 24% !important;
}

.wp-block-group.is-style-cedar-staff-card-minimal {
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  padding-right: 0 !important;
  padding-left: 0 !important;
}

.wp-block-group.is-style-cedar-staff-card-minimal .wp-block-columns {
  gap: var(--wp--preset--spacing--30, 1rem);
}

.wp-block-group.is-style-cedar-staff-card-minimal .wp-block-column:first-child {
  flex-basis: 20% !important;
}

@media (max-width: 781px) {
  .wp-block-group.is-style-cedar-staff-card-compact .wp-block-column:first-child,
  .wp-block-group.is-style-cedar-staff-card-minimal .wp-block-column:first-child {
    flex-basis: 100% !important;
  }
}


html.cedar-staff-modal-open,
body.cedar-staff-modal-open {
  overflow: hidden;
}

body.cedar-staff-modal-open {
  touch-action: none;
}

.cedar-staff-message__modal[hidden] {
  display: none !important;
}

.cedar-staff-message__modal {
  isolation: isolate;
}

.cedar-staff-message__dialog {
  margin: auto;
}


.cedar-staff-toast-region {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 10002;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  width: min(calc(100vw - 2rem), 420px);
  pointer-events: none;
}

.cedar-staff-toast {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1rem 1rem 1rem;
  border-radius: 12px;
  background: #fff;
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.18);
  border: 1px solid rgba(0, 0, 0, 0.08);
  pointer-events: auto;
}

.cedar-staff-toast--success {
  border-left: 4px solid var(--wp--preset--color--accent, #2e7d32);
}

.cedar-staff-toast__message {
  flex: 1 1 auto;
  overflow-wrap: anywhere;
}

.cedar-staff-toast__close {
  flex: 0 0 auto;
  border: 0;
  background: transparent;
  color: currentColor;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  padding: 0;
}

.cedar-staff-message__dialog:focus,
.scf-confirmation-box:focus {
  outline: none;
}

@media (max-width: 640px) {
  .cedar-staff-toast-region {
    top: auto;
    right: 1rem;
    bottom: 1rem;
    left: 1rem;
    width: auto;
  }
}


@media (prefers-reduced-motion: reduce) {
  .cedar-staff-message__trigger,
  .cedar-staff-form input[type="submit"],
  .cedar-staff-form button,
  .scf-send-final,
  .scf-cancel,
  .cedar-staff-toast,
  .cedar-staff-message__modal,
  .cedar-staff-message__dialog,
  .scf-confirmation,
  .scf-confirmation-box {
    animation: none !important;
    transition: none !important;
    scroll-behavior: auto !important;
  }
}


.wp-block-cedar-companion-staff-message {
  display: inline-block;
  vertical-align: top;
}

.wp-block-cedar-companion-staff-message .cedar-staff-message__trigger {
  width: auto;
  max-width: 100%;
}


.cedar-staff-message__trigger.is-style-outline {
    background: transparent;
    border-style: solid;
    border-width: 2px;
    border-color: currentColor;
}

.cedar-staff-message__trigger.is-style-text {
    background: transparent;
    border: 0;
    padding: 0;
}
