@font-face {
  font-family: "Atkinson Hyperlegible Local";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/atkinson-hyperlegible-400.woff2") format("woff2");
}

@font-face {
  font-family: "Atkinson Hyperlegible Local";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/assets/fonts/atkinson-hyperlegible-700.woff2") format("woff2");
}

:root {
  --sscs-ink: #171a17;
  --sscs-white: #fff;
  --sscs-gold: #e1a32c;
  --sscs-forest: #103c2b;
  --sscs-z-launcher: 70;
  --sscs-z-status: 71;
  --sscs-z-drawer: 2147483646;
}

.sscs-launcher {
  box-sizing: border-box;
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: var(--sscs-z-launcher);
  min-height: 52px;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  padding: 8px 18px 8px 9px;
  border: 1px solid #2e6652;
  border-radius: 4px;
  color: var(--sscs-white);
  background: var(--sscs-forest);
  box-shadow: 0 12px 34px rgba(6, 28, 20, 0.28);
  font-family: "Atkinson Hyperlegible Local", system-ui, sans-serif;
  font-size: 0.9rem;
  font-weight: 700;
  line-height: 1.2;
  cursor: pointer;
  transition:
    background 160ms ease-out,
    box-shadow 160ms ease-out,
    transform 160ms ease-out;
}

.sscs-launcher:hover {
  background: #164f39;
  box-shadow: 0 16px 38px rgba(6, 28, 20, 0.34);
  transform: translateY(-1px);
}

.sscs-launcher:focus-visible {
  outline: 3px solid var(--sscs-gold);
  outline-offset: 3px;
}

.sscs-launcher-mark {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--sscs-ink);
  background: var(--sscs-gold);
}

.sscs-launcher-mark::before {
  width: 13px;
  height: 13px;
  display: block;
  border: 2px solid currentColor;
  border-radius: 50% 50% 50% 18%;
  content: "";
  transform: rotate(-12deg);
}

.sscs-status {
  box-sizing: border-box;
  position: fixed;
  right: 24px;
  bottom: 88px;
  z-index: var(--sscs-z-status);
  max-width: min(340px, calc(100vw - 32px));
  margin: 0;
  padding: 11px 13px;
  border: 1px solid #d5a84f;
  border-radius: 3px;
  color: #342100;
  background: #fff4d8;
  box-shadow: 0 12px 32px rgba(6, 28, 20, 0.22);
  font-family: "Atkinson Hyperlegible Local", system-ui, sans-serif;
  font-size: 0.84rem;
  line-height: 1.45;
}

html[data-chatwoot-panel="open"] .sscs-launcher,
html[data-chatwoot-shell="open"] .sscs-launcher {
  visibility: hidden;
}

.sscs-loading-drawer {
  box-sizing: border-box;
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: var(--sscs-z-drawer);
  width: min(400px, calc(100vw - 32px));
  height: min(640px, calc(100vh - 48px));
  overflow: hidden;
  border: 1px solid #d9ded9;
  border-radius: 8px;
  color: var(--sscs-ink);
  background: var(--sscs-white);
  box-shadow: 0 20px 60px rgba(6, 28, 20, 0.28);
  font-family: "Atkinson Hyperlegible Local", system-ui, sans-serif;
}

.sscs-loading-drawer[hidden] {
  display: none;
}

.sscs-loading-header {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px 14px 20px;
  border-bottom: 1px solid #e3e7e3;
  background: #f6f7f3;
}

.sscs-loading-header img {
  width: 150px;
  height: auto;
  display: block;
}

.sscs-loading-close {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  color: #36423a;
  background: transparent;
  font: 400 1.8rem/1 system-ui, sans-serif;
  cursor: pointer;
}

.sscs-loading-close:hover {
  background: #e7ebe7;
}

.sscs-loading-close:focus-visible {
  outline: 3px solid var(--sscs-gold);
  outline-offset: 2px;
}

.sscs-loading-body {
  min-height: calc(100% - 76px);
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 12px;
  padding: 32px;
  text-align: center;
}

.sscs-loading-body strong {
  font-size: 1.15rem;
}

.sscs-loading-body > span:last-child {
  max-width: 260px;
  color: #575e58;
  font-size: 0.9rem;
  line-height: 1.45;
}

.sscs-loading-spinner {
  width: 34px;
  height: 34px;
  border: 4px solid #dfe6e1;
  border-top-color: var(--sscs-forest);
  border-radius: 50%;
  animation: sscs-spin 700ms linear infinite;
}

@keyframes sscs-spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 1040px) {
  .site-header .sscs-launcher {
    order: 2;
    margin-left: auto;
  }

  .site-header .mobile-menu {
    order: 3;
  }

  .sscs-launcher {
    position: relative;
    right: auto;
    bottom: auto;
    width: 46px;
    height: 46px;
    min-height: 46px;
    flex: 0 0 46px;
    justify-content: center;
    overflow: hidden;
    gap: 0;
    padding: 7px;
    border-radius: 50%;
    box-shadow: none;
  }

  .sscs-launcher > span:last-child {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    clip-path: inset(50%);
    white-space: nowrap;
  }

  .sscs-status {
    right: 14px;
    top: 78px;
    bottom: auto;
  }
}

@media (max-width: 680px) {
  .sscs-loading-drawer {
    right: 0;
    bottom: 0;
    width: 100vw;
    height: 100dvh;
    max-height: none;
    border: 0;
    border-radius: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .sscs-launcher {
    transition: none;
  }

  .sscs-launcher:hover {
    transform: none;
  }

  .sscs-loading-spinner {
    animation: none;
    border-top-color: #dfe6e1;
    background: var(--sscs-forest);
  }
}
