:root {
  --home-text: #294b49;
  --home-muted: #63777e;
  --home-brand: #287060;
  --home-focus: #bfe2d8;
  --home-surface: rgb(255 255 255 / 84%);
  --home-border: rgb(151 173 171 / 48%);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
}

body.public-home-page {
  min-height: 100vh;
  overflow-x: hidden;
  background: #f1f5f4;
  color: var(--home-text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Microsoft YaHei", sans-serif;
}

.public-home {
  position: relative;
  min-height: 100vh;
  isolation: isolate;
  overflow: hidden;
}

.public-home__still,
.public-home__intro {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
}

.public-home__still {
  z-index: 0;
}

.public-home__intro {
  z-index: 1;
  opacity: 1;
  transition: opacity 280ms ease;
}

.public-home.is-intro-complete .public-home__intro,
.public-home.is-intro-skipped .public-home__intro,
.public-home.is-intro-failed .public-home__intro {
  opacity: 0;
  pointer-events: none;
}

.public-home__about-entry {
  position: absolute;
  top: clamp(22px, 4.8vh, 52px);
  right: clamp(22px, 5vw, 72px);
  z-index: 3;
  padding: 7px 2px;
  border: 0;
  border-bottom: 1px solid transparent;
  border-radius: 0;
  background: transparent;
  color: var(--home-brand);
  font: inherit;
  font-size: 0.96rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  cursor: pointer;
}

.public-home__about-entry:hover {
  border-bottom-color: currentColor;
}

.public-home__about-entry:focus-visible,
.public-home__about-close:focus-visible,
.public-home__entry:focus-visible {
  outline: 3px solid var(--home-focus);
  outline-offset: 3px;
}

.public-home__content {
  position: relative;
  z-index: 2;
  width: min(420px, calc(100vw - 48px));
  min-height: 100vh;
  margin-left: clamp(24px, 9vw, 172px);
  padding: 8vh 0 22vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  opacity: 0;
  transform: translateY(8px);
  text-shadow: 0 1px 2px rgb(255 255 255 / 42%);
  transition: opacity 520ms ease, transform 520ms ease;
}

.public-home.is-content-visible .public-home__content,
.public-home.is-intro-skipped .public-home__content,
.public-home.is-intro-failed .public-home__content {
  opacity: 1;
  transform: translateY(0);
}

.public-home__eyebrow {
  margin: 0 0 8px;
  color: var(--home-brand);
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.03em;
}

.public-home h1 {
  margin: 0 0 10px;
  color: var(--home-text);
  font-size: clamp(2.45rem, 5.5vw, 4.8rem);
  line-height: 1.04;
  font-weight: 650;
  letter-spacing: 0.02em;
}

.public-home__subtitle {
  margin: 0 0 28px;
  color: var(--home-muted);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
  line-height: 1.7;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.public-home__entry {
  width: max-content;
  min-width: 112px;
  padding: 11px 18px;
  border: 0;
  border-radius: 8px;
  color: #fff;
  background: var(--home-brand);
  text-decoration: none;
  font: inherit;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-shadow: none;
  cursor: pointer;
  transition: background 180ms ease, transform 180ms ease;
}

.public-home__entry:hover {
  background: #245f52;
  transform: translateY(-1px);
}

.public-home__about-backdrop {
  position: fixed;
  inset: 0;
  z-index: 4;
  background: rgb(241 245 244 / 18%);
}

.public-home__about-dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  z-index: 5;
  width: min(620px, calc(100vw - 40px));
  max-height: min(78vh, 680px);
  overflow: auto;
  padding: clamp(26px, 4vw, 42px);
  border: 1px solid var(--home-border);
  border-radius: 18px;
  background: var(--home-surface);
  box-shadow: 0 20px 60px rgb(49 78 80 / 14%);
  color: var(--home-text);
  transform: translate(-50%, -50%);
}

.public-home__about-dialog h2 {
  margin: 0 0 18px;
  font-size: clamp(1.45rem, 2.4vw, 1.9rem);
  line-height: 1.25;
  font-weight: 700;
}

.public-home__about-dialog p {
  margin: 0 0 16px;
  color: #3e5d5b;
  font-size: 1rem;
  line-height: 1.85;
}

.public-home__about-dialog p:last-child {
  margin-bottom: 0;
}

.public-home__about-final {
  color: var(--home-brand) !important;
  font-weight: 700;
}

.public-home__about-close {
  position: absolute;
  top: 14px;
  right: 16px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--home-muted);
  font: inherit;
  font-size: 1.55rem;
  line-height: 1;
  cursor: pointer;
}

.public-home__about-close:hover {
  color: var(--home-brand);
  background: rgb(226 240 236 / 72%);
}

@media (max-width: 720px) {
  .public-home__about-entry {
    top: 18px;
    right: 18px;
  }

  .public-home__content {
    width: min(420px, calc(100vw - 36px));
    margin: 0 auto;
    padding-top: 18vh;
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  .public-home__intro {
    display: none;
  }

  .public-home__content,
  .public-home__entry,
  .public-home__intro {
    transition: none;
  }
}
