@import url("./fonts.css");
@import url("./tokens.css");

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--color-page);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--color-page);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
}

a {
  color: inherit;
}

.site-shell {
  display: flex;
  flex-direction: column;
  gap: var(--shell-gap);
  width: 100%;
  height: 100vh;
  height: 100svh;
  padding: var(--shell-padding);
  overflow: hidden;
  background: var(--color-page);
}

.hero {
  position: relative;
  display: flex;
  flex: 1 1 0;
  min-height: 0;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border-radius: var(--radius-hero);
  isolation: isolate;
}

.hero__background {
  --photo-shift-x: 0px;
  --photo-shift-y: 0px;

  position: absolute;
  z-index: -1;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 36% 50%;
  transform: translate3d(var(--photo-shift-x), var(--photo-shift-y), 0) scale(1.025);
  transform-origin: center;
  user-select: none;
  will-change: transform;
}

.hero__content {
  position: relative;
  z-index: 1;
  display: flex;
  width: min(var(--content-width), calc(100% - 64px));
  flex-direction: column;
  align-items: center;
  gap: 48px;
  text-align: center;
}

.hero__title {
  margin: 0;
  color: var(--color-heading);
  font-family: var(--font-display);
  font-size: 62px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -1.24px;
  text-shadow: var(--shadow-copy);
}

.hero__title span {
  display: block;
}

.hero__description {
  margin: 0;
  color: var(--color-copy);
  font-size: 18px;
  font-weight: 400;
  line-height: 1.5;
  text-shadow: var(--shadow-copy);
}

.facebook-button {
  position: relative;
  display: inline-flex;
  min-height: 56px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 33px 14px 29px;
  overflow: hidden;
  border: 1px solid var(--color-facebook-border);
  border-radius: var(--radius-button);
  background: linear-gradient(
    180deg,
    var(--color-facebook-start) 0%,
    var(--color-facebook-end) 100%
  );
  box-shadow: var(--shadow-button), var(--shadow-button-inset);
  color: var(--color-white);
  font-size: 18px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  transition: filter 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.facebook-button img {
  width: 1em;
  height: 1em;
  object-fit: contain;
}

.facebook-button:hover {
  filter: brightness(1.08);
  transform: translateY(-1px);
}

.facebook-button:active {
  transform: translateY(1px);
}

.facebook-button:focus-visible,
.contact-item:focus-visible {
  outline: 3px solid var(--color-focus);
  outline-offset: 4px;
}

.contact-bar {
  flex: 0 0 auto;
  width: 100%;
  padding: 0 16px;
  overflow: hidden;
}

.contact-list {
  display: flex;
  width: 100%;
  align-items: center;
  gap: 32px;
  margin: 0;
  font-style: normal;
}

.contact-item {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: var(--color-contact);
  font-size: 18px;
  font-weight: 400;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  transition: color 160ms ease;
}

.contact-item:hover {
  color: var(--color-white);
}

.contact-item img {
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
}

.contact-item--address {
  margin-left: auto;
}

@media (max-width: 860px) {
  :root {
    --radius-hero: 16px;
    --shell-padding: 8px 8px 16px;
  }

  .hero {
    align-items: flex-start;
    justify-content: center;
    padding: 48px 32px 64px;
  }

  .hero__background {
    object-position: 63.5% 50%;
  }

  .hero__content {
    width: 100%;
    gap: 28px;
  }

  .hero__title {
    width: min(257px, 100%);
    font-size: 32px;
  }

  .hero__description {
    font-size: 15px;
  }

  .facebook-button {
    font-size: 18px;
  }

  .contact-item {
    font-size: 16px;
  }

  .contact-item img {
    width: 16px;
    height: 16px;
    flex-basis: 16px;
  }

  .contact-bar {
    padding-inline: 16px;
  }

  .contact-list {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
  }

  .contact-item--address {
    margin-left: 0;
  }
}

@media (min-width: 600px) and (max-width: 860px) {
  .hero {
    align-items: center;
    padding: 48px;
  }

  .hero__background {
    object-position: 45% 50%;
  }

  .hero__content {
    width: min(var(--content-width), 100%);
    gap: 36px;
  }

  .hero__title {
    font-size: 52px;
  }

  .hero__description {
    font-size: 18px;
  }
}

@media (max-width: 360px) {
  .hero {
    padding-inline: 22px;
  }

  .contact-item {
    font-size: 16px;
  }
}

@media (min-width: 861px) and (max-height: 620px) {
  .hero__content {
    gap: 24px;
  }

  .hero__title {
    font-size: 46px;
  }

  .hero__description {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .facebook-button,
  .contact-item {
    transition: none;
  }
}
