:root {
  --color-text: #363636;
  --color-dark: #0f0f0f;
  --color-muted: #777;
  --color-gold: #e7b35a;
  --color-gold-dark: #c88f34;
  --color-bg: #fff;
  --color-soft: #f7f3ed;
  --container: 1140px;
  --header-height: 86px;
  --hero-min-height: 760px;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.16);
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: #888;
  background: var(--color-bg);
  font-family: Roboto, Helvetica, Arial, Verdana, sans-serif;
  font-size: 15px;
  line-height: 27px;
}

body.is-menu-open,
body.is-modal-open {
  overflow: hidden;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 1000;
  padding: 8px 14px;
  background: #fff;
  color: var(--color-dark);
  transform: translateY(-140%);
  transition: transform 0.2s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  width: min(var(--container), calc(100% - 40px));
  margin-inline: auto;
}

.site-header {
  position: absolute;
  top: calc(max(100vh, var(--hero-min-height)) - var(--header-height));
  left: 0;
  z-index: 50;
  width: 100%;
  height: var(--header-height);
  color: #fff;
  background: #111;
}

@supports (top: calc(max(100svh, 1px) - 1px)) {
  .site-header {
    top: calc(max(100svh, var(--hero-min-height)) - var(--header-height));
  }
}

.site-header.is-sticky {
  position: fixed;
  top: 0;
}

.site-header__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(980px, calc(100% - 40px));
  height: 100%;
  margin-inline: auto;
}

.site-header__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 126px;
}

.site-header__logo--mobile {
  display: none;
}

.site-header__logo-item {
  display: inline-flex;
}

.site-header__logo img {
  width: 126px;
}

.site-header__menu,
.site-header__mobile ul {
  padding: 0;
  margin: 0;
  list-style: none;
}

.site-header__menu {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: nowrap;
  gap: clamp(14px, 1.7vw, 26px);
  height: 100%;
}

.site-header__menu a,
.site-header__language a,
.site-header__language span {
  color: #fff;
  font-family: "Roboto Condensed", Helvetica, Arial, Verdana, sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 24px;
  letter-spacing: normal;
  white-space: nowrap;
  text-transform: none;
  transition: color 0.2s ease;
}

.site-header__menu a:hover,
.site-header__menu a:focus-visible,
.site-header__language a:hover,
.site-header__language a:focus-visible,
.site-header__language .is-active {
  color: var(--color-gold);
}

.site-header__language {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
}

.site-header__language-separator {
  opacity: 0.7;
}

.site-header__toggle {
  position: absolute;
  right: 0;
  display: none;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
}

.site-header__toggle span {
  display: block;
  width: 24px;
  height: 2px;
  margin: 5px auto;
  background: #fff;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-header__toggle[aria-expanded="true"] span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.site-header__toggle[aria-expanded="true"] span:nth-child(2) {
  opacity: 0;
}

.site-header__toggle[aria-expanded="true"] span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.site-header__mobile {
  display: none;
}

.section {
  position: relative;
  padding: 96px 0;
  scroll-margin-top: calc(var(--header-height) + 24px);
}

.section--about {
  padding: 86px 0 78px;
  background: #fff;
}

.section--churches {
  padding: 106px 0 116px;
  color: #fff;
  background:
    linear-gradient(rgba(0, 0, 0, 0.62), rgba(0, 0, 0, 0.62)),
    url("/assets/img/backgrounds/churches.webp") center / cover no-repeat;
}

.section--offers {
  background: #fff;
}

.section--services {
  background: #f7f7f7;
}

.section-title,
.section-heading h1,
.section-heading h2 {
  margin: 0;
  color: var(--color-dark);
  font-family: "Roboto Condensed", Roboto, sans-serif;
  font-size: clamp(32px, 4vw, 50px);
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
}

.section-title {
  max-width: 980px;
  margin-inline: auto;
  margin-bottom: 62px;
}

.section-kicker {
  margin: 0 0 18px;
  color: var(--color-gold);
  font-family: Raleway, Roboto, sans-serif;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.2em;
}

.about-grid {
  display: grid;
  grid-template-columns: 430px minmax(0, 1fr);
  gap: clamp(54px, 7vw, 86px);
  align-items: center;
  width: min(1030px, calc(100% - 40px));
}

.about-gallery {
  display: grid;
  grid-template-columns: 1fr 0.72fr;
  gap: 12px;
  align-items: start;
}

.about-gallery img {
  width: 100%;
  min-height: 0;
  object-fit: cover;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.1);
}

.about-gallery img:first-child {
  grid-column: 1;
  grid-row: 1;
  height: 250px;
}

.about-gallery img:nth-child(2) {
  grid-column: 1;
  grid-row: 2;
  height: 160px;
}

.about-gallery img:nth-child(3) {
  grid-column: 2;
  grid-row: 1 / span 2;
  height: 422px;
}

.about-content p:not(.section-kicker) {
  margin: 0 0 18px;
}

.about-content .section-kicker {
  margin: 0 0 22px;
  color: #888;
  font-family: Roboto, Helvetica, Arial, Verdana, sans-serif;
  font-size: 27px;
  font-weight: 700;
  letter-spacing: 0;
  line-height: 32px;
  text-align: center;
}

.section-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.about-content .section-actions {
  justify-content: center;
  gap: 20px;
  margin-top: 30px;
}

.button,
.text-button,
.section-heading__link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  border: 0;
  color: var(--color-gold);
  background: transparent;
  font-family: "Open Sans", Roboto, Helvetica, Arial, Verdana, sans-serif;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: normal;
  cursor: pointer;
  text-transform: none;
  transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}

.button {
  min-width: 120px;
  padding: 10px 18px;
  border: 2px solid var(--color-gold);
}

.about-content .button {
  min-width: 122px;
  min-height: 40px;
  padding: 10px 18px;
  border-color: var(--color-gold);
  color: #fff;
  background: var(--color-gold);
  font-size: 12px;
  line-height: 1;
}

.button:hover,
.button:focus-visible,
.button--gold {
  color: #fff;
  background: var(--color-gold);
}

.button--gold:hover,
.button--gold:focus-visible {
  background: var(--color-gold-dark);
  border-color: var(--color-gold-dark);
}

.text-button,
.section-heading__link {
  padding: 0;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.text-button:hover,
.text-button:focus-visible,
.section-heading__link:hover,
.section-heading__link:focus-visible {
  color: var(--color-gold-dark);
}

.church-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 34px;
  width: min(1040px, 100%);
  margin-inline: auto;
}

.church-card {
  overflow: hidden;
  padding: 26px 26px 32px;
  background: #fff;
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.1);
}

.church-card img {
  width: 100%;
  aspect-ratio: 1.22 / 1;
  object-fit: cover;
}

.church-card__body {
  padding: 20px 0 0;
  text-align: center;
}

.church-card h3,
.service-card h3 {
  margin: 0 0 10px;
  color: var(--color-dark);
  font-family: "Roboto Condensed", Roboto, sans-serif;
  font-size: 16px;
  font-weight: 700;
  line-height: 26px;
}

.church-card p {
  margin: 0 0 16px;
  color: var(--color-muted);
  font-size: 13px;
  line-height: 1.55;
}

.church-card .text-button {
  min-height: 30px;
  padding: 1px 13px;
  color: #fff;
  background: var(--color-gold);
  font-size: 12px;
  line-height: 30px;
  text-decoration: none;
}

.section-heading {
  display: grid;
  justify-items: center;
  margin-bottom: 70px;
}

.section-heading--light h1,
.section-heading--light h2 {
  max-width: 980px;
  color: #fff;
  text-shadow: 0 2px 20px rgba(0, 0, 0, 0.48);
}

.section-heading__link {
  margin-top: 8px;
}

.section-heading__divider {
  position: relative;
  display: block;
  width: 152px;
  height: 28px;
  margin-top: 22px;
}

.section-heading__divider::before,
.section-heading__divider::after {
  position: absolute;
  top: 12px;
  width: 50px;
  height: 4px;
  background: var(--color-gold);
  content: "";
}

.section-heading__divider::before {
  left: 0;
}

.section-heading__divider::after {
  right: 0;
}

.section-heading__divider {
  background:
    linear-gradient(var(--color-gold), var(--color-gold)) center 4px / 9px 18px no-repeat;
}

.section-heading__divider::before,
.section-heading__divider::after {
  border-radius: 2px;
}

.section-heading__divider {
  clip-path: none;
}

.service-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-template-rows: repeat(3, auto);
  grid-auto-flow: column;
  gap: 0 34px;
}

.service-card {
  display: grid;
  grid-template-columns: 86px 1fr;
  gap: 22px;
  align-items: center;
  padding: 22px 0;
  border-bottom: 1px dashed rgba(0, 0, 0, 0.2);
}

.service-card__image {
  display: block;
  width: 86px;
  height: 86px;
  padding: 0;
  overflow: hidden;
  border: 0;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
}

.service-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.service-card__content {
  min-width: 0;
}

.offers-carousel {
  position: relative;
  width: min(1050px, 100%);
  margin-inline: auto;
}

.offers-carousel__viewport {
  overflow: hidden;
}

.offers-list {
  display: flex;
  gap: 48px;
  transition: transform 0.35s ease;
}

.offer-card {
  flex: 0 0 calc((100% - 96px) / 3);
  text-align: center;
}

.offer-card img {
  width: min(250px, 100%);
  height: min(250px, 100vw);
  margin-inline: auto;
  border-radius: 50%;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.12);
  object-fit: cover;
}

.offer-card h3 {
  margin: 26px 0 4px;
  color: #8a8a8a;
  font-family: "Roboto Condensed", Roboto, sans-serif;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
}

.offer-card p {
  margin: 0;
  color: var(--color-gold);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.35;
}

.offers-carousel__arrow {
  position: absolute;
  top: 125px;
  z-index: 2;
  width: 32px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: var(--color-gold);
  color: transparent;
  cursor: pointer;
  transform: translateY(-50%);
}

.offers-carousel__arrow::before {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 9px;
  height: 9px;
  border-top: 2px solid #fff;
  border-right: 2px solid #fff;
  content: "";
}

.offers-carousel__arrow--previous {
  left: -24px;
}

.offers-carousel__arrow--previous::before {
  transform: translate(-35%, -50%) rotate(-135deg);
}

.offers-carousel__arrow--next {
  right: -24px;
}

.offers-carousel__arrow--next::before {
  transform: translate(-65%, -50%) rotate(45deg);
}

.anchor-target {
  display: block;
  scroll-margin-top: calc(var(--header-height) + 24px);
}

.section--contacts {
  padding: 74px 0 66px;
  color: rgba(255, 255, 255, 0.82);
  background: #111;
}

.contacts-layout {
  display: grid;
  grid-template-columns: 1fr;
  justify-items: center;
  gap: 28px;
  text-align: center;
}

.contacts-layout ul {
  padding: 0;
  margin: 0;
  list-style: none;
}

.footer-logo {
  display: inline-flex;
  width: 126px;
}

.footer-language {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #fff;
  font-family: "Roboto Condensed", Helvetica, Arial, Verdana, sans-serif;
  font-size: 15px;
  font-weight: 700;
  line-height: 20px;
  white-space: nowrap;
}

.footer-language a {
  color: inherit;
  transition: color 0.2s ease;
}

.footer-language a:hover,
.footer-language a:focus-visible,
.footer-language .is-active {
  color: var(--color-gold);
}

.footer-language__separator {
  opacity: 0.7;
}

.footer-addresses {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 56px;
  width: min(900px, 100%);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
}

.footer-dots {
  display: flex;
  gap: 7px;
}

.footer-dots span {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--color-gold);
}

.footer-copy {
  margin: -12px 0 0;
  color: rgba(255, 255, 255, 0.55);
  font-size: 12px;
}

.modal[hidden] {
  display: none;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  padding: 24px;
  overflow-y: auto;
  place-items: center;
}

.modal__backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
}

.modal--stacked {
  z-index: 130;
  padding: 0;
  overflow: hidden;
  place-items: start center;
}

.modal__dialog {
  position: relative;
  z-index: 1;
  width: min(900px, 100%);
  max-height: calc(100vh - 48px);
  padding: clamp(28px, 4vw, 46px);
  overflow-y: auto;
  background: #fff;
  box-shadow: var(--shadow);
}

.modal__dialog--donation {
  width: min(380px, calc(100vw - 32px));
  max-width: none;
  height: min(900px, calc(100vh - 32px));
  max-height: calc(100vh - 32px);
  padding: 0;
  overflow: hidden;
  background: transparent;
  box-shadow: none;
  outline: none;
}

.modal--stacked .modal__close,
.modal--stacked .modal__title {
  display: none;
}

.modal--stacked .modal__content {
  height: 100%;
}

.modal__close {
  position: sticky;
  top: 0;
  float: right;
  display: grid;
  width: 42px;
  height: 42px;
  margin-top: -18px;
  margin-right: -18px;
  border: 0;
  border-radius: 50%;
  background: var(--color-dark);
  color: #fff;
  cursor: pointer;
  font-size: 30px;
  line-height: 1;
  place-items: center;
}

.modal__title {
  margin: 0 48px 24px 0;
  color: var(--color-dark);
  font-family: "Roboto Condensed", Roboto, sans-serif;
  font-size: clamp(28px, 4vw, 44px);
  line-height: 1.2;
}

.modal__title[hidden] {
  display: none;
}

.modal__content h2,
.popup-article h2 {
  margin: 28px 0 14px;
  color: var(--color-dark);
  font-family: "Roboto Condensed", Roboto, sans-serif;
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.25;
}

.modal__content h2:first-child,
.popup-article h2:first-child {
  margin-top: 0;
}

.popup-article p,
.popup-article li {
  color: var(--color-text);
}

.popup-article ul,
.popup-article ol {
  padding-left: 22px;
}

.popup-article__actions {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

.map-frame,
.donation-frame {
  width: 100%;
  border: 0;
}

.map-frame {
  height: min(62vh, 540px);
}

.donation-frame {
  display: block;
  height: 100%;
  min-height: 0;
  background: transparent;
}

@media (max-width: 1080px) {
  .site-header__menu {
    gap: 12px;
  }

  .site-header__menu a,
  .site-header__language a,
  .site-header__language span {
    font-size: 18px;
    line-height: 22px;
  }

  .service-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .offers-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 900px) {
  :root {
    --header-height: 76px;
  }

  .site-header {
    position: absolute;
    background: #111;
  }

  .site-header.is-sticky {
    position: fixed;
    top: 0;
    background: rgba(17, 17, 17, 0.96);
  }

  .site-header__inner {
    min-height: var(--header-height);
  }

  .site-header__nav--desktop {
    display: none;
  }

  .site-header__logo--mobile {
    position: absolute;
    left: 50%;
    display: inline-flex;
    transform: translateX(-50%);
  }

  .site-header__toggle {
    display: block;
  }

  .site-header__mobile {
    display: block;
    max-height: 0;
    overflow: hidden;
    background: rgba(17, 17, 17, 0.96);
    transition: max-height 0.24s ease;
  }

  .site-header:not(.is-sticky) .site-header__mobile {
    position: absolute;
    right: 0;
    bottom: var(--header-height);
    left: 0;
  }

  .site-header__mobile.is-open {
    max-height: calc(100vh - var(--header-height));
    overflow-y: auto;
  }

  .site-header__mobile ul {
    display: grid;
    gap: 0;
    width: min(520px, calc(100% - 40px));
    padding: 12px 0 28px;
    margin-inline: auto;
  }

  .site-header__mobile li {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .site-header__mobile a {
    display: flex;
    padding: 14px 0;
  }

  .about-grid,
  .contacts-layout {
    grid-template-columns: 1fr;
  }

  .church-grid {
    grid-template-columns: 1fr;
  }

  .about-gallery {
    display: none;
  }

  .service-list {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    grid-auto-flow: row;
  }

  .service-card {
    justify-items: center;
    grid-template-columns: 1fr;
    gap: 14px;
    text-align: center;
  }

  .service-card__content {
    display: grid;
    justify-items: center;
    gap: 12px;
  }

  .service-card h3 {
    margin-bottom: 0;
  }

  .section--services .section-heading__link,
  .service-card .text-button {
    font-size: 16px;
    line-height: 20px;
  }

  .offer-card {
    flex-basis: calc((100% - 32px) / 2);
  }

  .offers-list {
    gap: 32px;
  }

  .footer-addresses {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

@media (max-width: 778px) {
  .site-header {
    top: calc(100vh - var(--header-height));
  }
}

@supports (top: calc(100svh - 1px)) {
  @media (max-width: 778px) {
    .site-header {
      top: calc(100svh - var(--header-height));
    }
  }
}

@media (max-width: 640px) {
  .container,
  .site-header__inner {
    width: min(100% - 24px, var(--container));
  }

  .section {
    padding: 72px 0;
  }

  .section--services .section-heading h1 {
    font-size: 50px;
  }

  .about-gallery {
    gap: 12px;
  }

  .about-gallery img,
  .about-gallery img:first-child {
    min-height: 180px;
  }

  .offer-card {
    flex-basis: 100%;
  }

  .offers-carousel__arrow--previous {
    left: 0;
  }

  .offers-carousel__arrow--next {
    right: 0;
  }

  .modal {
    padding: 12px;
  }

  .modal__dialog {
    max-height: calc(100vh - 24px);
  }
}
