
@import url('https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,100..1000;1,9..40,100..1000&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');
@font-face {
    font-family: 'Open Runde';
    src: url('path/to/open-runde-regular.woff2') format('woff2');
    font-weight: 400;
    font-display: swap;
}

/* All px values converted to rem (1rem = 16px) */
/* Reset and base styles */
html {
  scroll-behavior: smooth;
  font-size: 80%;  /* 16px × 0.8 = 12.8px */
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    /* DM Sans: font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; */
    /* font-family: 'Open Runde', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;  */
    line-height: 1.5;
    letter-spacing: 0.03em;
    color: rgba(98, 108, 113, 1);
    background-color: #ffffff;
    width: 100%;
    min-height: 100vh;
    overflow-x: hidden;
}


/* Navigation */
.navbar {
    background: #ffffff;
    box-shadow: 0 0.25rem 0.375rem -0.0625rem rgba(0,0,0,0.04), 0 0.125rem 0.25rem -0.0625rem rgba(0,0,0,0.02);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.nav-container {
    width: 100rem;
    margin: auto;
    display: flex;
    justify-content: space-between;
    padding: 1rem 0 0 0;
    align-items: flex-end;
}

.nav-brand {
  display: start;
}

.brand-icon {
  height: 4.375rem;
  width: auto;
  margin-bottom: 0.625rem;
  margin-top: 0.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    margin-bottom: 0.625rem;
}

.nav-link {
    font-size: 1.5rem;
    font-weight: 400;
    text-decoration: none;
    color: #120450;
    transition: color 0.25s cubic-bezier(0.16,1,0.3,1);
}
.nav-link:hover {
    color: #9E0E25;
}

/* Hero section */
.hero-section {
	margin: auto;
	max-width: 100rem;
	color: #f7f7f7;
}


.hero-inner {
    display: grid;
    grid-template-columns: auto auto;
    gap: 0;
    align-items: stretch;
}

.hero-photo {
    display: block;
    max-width: 25rem;
    height: auto;
    object-fit: cover;
}

.hero-title {
  display: flex;
  flex-direction: column;
  align-self: stretch;
  padding-bottom: 2rem;
}

.hero-title h1 {
    color: #120450;
    font-size: 3.5rem;
    font-weight: 500;
    line-height: 1;
    margin-left: 2rem;
    padding-top: 2rem;
    padding-bottom: 2rem;
}

.hero-title p {
    font-size: 2rem;
    font-weight: 350;
    line-height: 1.7;
    color: #120450;
    padding-bottom: 1rem;
    margin-left: 2rem;
    margin-right: 3rem;
}

/* Buttons row */
.hero-buttons {
    background: #ffffff;
}
.buttons-row {
  background: #ffffff;
  display: flex;
  gap: 0;
  width: 100rem;
  margin: auto;
}
.btn {
    flex: 1;
    padding: 0.75rem 1.5rem;
    font-size: 1.625rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    color: #120450;
    background: #ffffff;
    /* box-shadow: 0 0 0.2rem rgba(0,0,0,0.1); */
    transition: background-color 0.25s ease, transform ease;
    position: relative;
  }
.btn:first-child { border-left: none; }
.btn:last-child  { border-right: none; }

.btn::after {
    content: "";
    position: absolute;
    right: 0;
    top: 30%;
    height: 40%;
    width: 0.5px;
    background: rgba(0,0,0,0.1);
}

.btn:first-child::before {
    content: "";
    position: absolute;
    left: 0;
    top: 30%;
    height: 40%;
    width: 0.5px;
    background: rgba(0,0,0,0.1);
}

.btn:hover,
.btn:focus {
  background: #f7f7f7;
  color:#9E0E25;
}

/* Latest news */
.content-container {
    background: #f7f7f7;
}

.content-section {
    max-width: 100rem;
    margin: auto;
    padding: 2.5rem 0;
    column-count: 2;
    column-gap: 2rem;
}

.content-title {
  font-size: 3rem;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.05em;
  color: #120450;
  text-align: left;
  max-width: 100rem;
  margin: auto;
  padding-top: 3rem;
  padding-bottom: 0.5rem;
}


.content-card {
  background: #ffffff;
  border-top: 0.3rem solid #9E0E25;
  margin-bottom: 2rem;
  transition: box-shadow 0.3s ease, transform 0.3s ease;
  break-inside: avoid;
}

.content-card:hover {
  transform: translateY(-0.25rem);
  box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.1);
}

.card-inner {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}


.card-text {
  padding-top: 2rem;
  padding-bottom: 0rem;
  padding-left: 2rem;
  padding-right: 2rem;
  color: #120450;
  flex: 1;
}

.card-text h4{
  padding-bottom: 0.75rem;
  color: #120450;
  opacity: 0.7;
  font-size: 1.8rem;
  font-weight: 400;
  letter-spacing: 0.2rem;
}

.card-text h3{
  font-size: 2rem;
  font-weight: 500;
  padding-bottom: 0.75rem;
}

.card-text p{
  font-size: 1.8rem;
  font-weight: 400;
  line-height: 3rem;
}

/* Single image layout - centered with equal space */
.single-image {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 100%;
  height: auto;
  align-self: stretch;
  margin-top: auto;
  margin-bottom: auto;
  margin-right: 0;
  margin-left: 0;
  object-fit: contain;
}

.card-gallery {
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 40rem;
  align-self: stretch;
  margin-right: 0;
  margin-left: 0;
  margin-bottom: auto;
  margin-top: auto;
}


.gallery-main {
  background: white;
  display: block;
  overflow: hidden;
  object-fit: contain;
  height: 35rem;
  width: auto;
}

.gallery-main-image {
  display: block;
  max-width: 100%;
  max-height: 35rem;
  object-fit: cover;
  margin: auto;
}

.gallery-controls {
  /* border: 0.1rem solid #9E0E25; */
  background: white; /* rgb(240, 240, 240); */
  display: flex;
  align-items: center;
  gap: 1rem;
  justify-content: center;
  width: 100%;
  margin: auto;
  height: 8rem;
  padding-top: 1rem;
  padding-bottom: 1rem;
  overflow: hidden;
}

.gallery-arrow {
  background: #9E0E25;
  border: none;
  color: #ffffff;
  font-size: 2rem;
  padding-bottom: 1rem;
  cursor: pointer;
  transition: background 0.3s ease;
  flex-shrink: 0;
  min-width: 3rem;
  height: 3rem;
  z-index: 10;
}

.gallery-arrow:hover {
  background: #120450;
}

.gallery-thumbnails {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-start;
  align-items: center;
  overflow-x: auto;
  flex: 0 0 auto;
}

.gallery-thumbnail {
  flex-shrink: 0;
  width: 6rem;
  height: 6rem;
  object-fit: cover;
  cursor: pointer;
  border: 3px solid transparent;
  transition: border-color 0.3s ease, opacity 0.3s ease;
  opacity: 0.6;
}

.gallery-thumbnail:hover {
  opacity: 1;
}

.gallery-thumbnail.active {
  border-color: #9E0E25;
  opacity: 1;
}

/* ================================
   Mobile layout (<= 700px)
   ================================ */
@media (max-width: 700px) {

    html {
        font-size: 70%; /* чутка меньше текст */
    }

    /* Navbar */
    .nav-container {
        width: 100%;
        padding: 1rem;
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .nav-menu {
        flex-wrap: wrap;
        gap: 1rem;
    }

    /* Hero */
    .hero-inner {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .hero-title h1 {
        margin-left: 0;
        text-align: left;
        padding: 1rem;
    }

    .hero-title p {
        margin-left: 0;
        margin-right: 0;
        text-align: left;
        padding: 1rem;
    }

    .hero-photo {
        max-width: 100%;
        margin: 0;
    }

    /* Buttons */
    .buttons-row {
        flex-direction: column;
        width: 100%;
        gap: 1rem;
        padding: 1rem;
    }

    .btn {
        width: 100%;
        font-size: 1.5rem;
    }

    /* News: one column */
    .content-title {
        padding-left: 1rem;
        padding-right: 1rem;
        text-align: left;
    }

    .content-section {
        column-count: 1;
        padding-left: 1rem;
        padding-right: 1rem;
    }

    .content-card {
        width: 100%;
        break-inside: avoid;
        padding-bottom: 1rem;
    }

    .card-text {
        padding-left: 1rem;
        padding-right: 1rem;
    }

    /* Gallery */
    .card-gallery {
        height: auto;
    }

    .gallery-main {
        height: auto;
    }

    .gallery-main-image {
        width: 100%;
        height: auto;
        object-fit: contain;
    }

    .gallery-controls {
        height: auto;
        padding: 1rem;
    }

    .gallery-thumbnail {
        width: 4rem;
        height: 4rem;
    }
}