.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 20px;
}



#image {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  height: auto;
}

.dziv {
  width: 100%;
  height: auto;
  background-color: var(--r-color);
  position: relative;
}

.image {
  width: 100%;
  height: 100%;
}

.click {
  max-height: 1000px !important;
  -webkit-transition: max-height 0.25s ease-in;
  transition: max-height 0.25s ease-in;
}

@media only screen and (max-width: 768px) {
  .hidden-content {
    max-height: 100px;
    /* Show only part of the text on mobile */
    overflow: hidden;
    position: relative;
    transition: max-height 0.5s ease-in-out;
  }

  .hidden-content.click {
    max-height: 1000px;
    /* Expand to show full content */
  }

  .hidden-content::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 50px;
    /* Height of the gradient fade */
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgb(121, 140, 112));
    transition: opacity 0.5s ease;
  }


  /* Gradient for section 1 */
  .gradient-section-1 .hidden-content::after {
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgb(49 120 159));
  }

  /* Gradient for section 2 */
  .gradient-section-2 .hidden-content::after {
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgb(233 231 225));

  }

  /* Gradient for section 2 */
  .gradient-section-3 .hidden-content::after {
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0), rgb(121 140 112));

  }

  .hidden-content.click::after {
    opacity: 0;
    /* Remove the gradient when fully expanded */
  }

  .showM {
    margin: 10px 0;
    /* Center the text */
    text-align: center;
  }

  .showP {
    font-size: 16px;
    font-weight: bold;
    color: #E9E7E1;
    cursor: pointer;
    transition: color 0.3s ease;
    text-align: center !important;
  }

  .showP:hover {
    color: #ccc;
    /* Add a subtle hover effect to make it interactive */
  }
}

/* On larger screens (non-mobile), the text is fully visible and "Lasīt Vairāk" is hidden */
@media only screen and (min-width: 769px) {
  .showP {
    display: none;
    /* Hide "Lasīt Vairāk" text on larger screens */
  }

  .hidden-content {
    max-height: none;
    /* Ensure full content is visible on larger screens */
  }

  .hidden-content::after {
    display: none;
    /* Remove the fade effect on larger screens */
  }
}


/* On larger screens (non-mobile), the text is fully visible and the button is hidden */
@media only screen and (min-width: 769px) {
  .read-more-btn {
    display: none;
    /* Hide the button on larger screens */
  }

  .hidden-content {
    max-height: none;
    /* Ensure full content is visible on larger screens */
  }

  .hidden-content::after {
    display: none;
    /* Remove the fade effect on larger screens */
  }
}


.info {
  height: auto;
  background-color: var(--r-color);
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-pack: distribute;
  justify-content: space-around;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
}

.blu {
  background-color: var(--g-color) !important;
}

.bal {
  color: var(--r-color);
}

.telp {
  color: #ebe7df;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
  -webkit-box-align: center;
  -ms-flex-align: center;
  align-items: center;
  padding: 0 0.5rem;
}

.numb {
  font-size: 34px;
  font-weight: 800;
}

.h-all {
  font-size: 60px;
}


@media (max-width: 1400px) {


  .h-all {
    font-size: 45px;
  }
}

@media (max-width: 1100px) {


  .adition {
    display: flex;
    flex-direction: column-reverse;
  }
}


@media (max-width: 1000px) {
  .numb {
    font-size: 28px;
  }

  .h-all {
    font-size: 40px;
  }

  .telp {
    padding: 0 3px;
  }


}

@media (max-width: 530px) {
  .numb {
    font-size: 25px;
  }

  .sfs {
    font-size: 15px;
    font-weight: 300;
  }

  .h-all {
    font-size: 30px;
  }

  .info {
    height: 5rem;
  }


}

@media (max-width: 410px) {
  .numb {
    font-size: 22px;
  }

  .sfs {
    font-size: 13px;
    font-weight: 300;
  }

  .h-all {
    font-size: 28px;
  }

  .info {
    height: 4rem;
  }

  .p-all {
    font-size: 11px;
  }
}

button.rounded {
  background: #E9E7E1;
  border: none;
  color: #E9E7E1;
  font-size: 16px;
  border-radius: 30px;
  padding: 10px 30px;
  line-height: 1.5;
  cursor: pointer;
}

.background {
  background-color: #E9E7E1;
}

p.large-paragraph {
  font-size: 1.25rem;
  font-weight: 300;
}

#header-hero-container {
  height: calc(100vh);
  position: relative;
  display: flex;
  justify-content: center;
}

.full {
  width: 100%;
  height: 100%;
}

.hamburger-menu {
  background-color: transparent;
  border: 1px solid #E9E7E1;
  padding: 3px 5px;
  width: 30px;
  cursor: pointer;
  margin-top: 10px;
  display: none;
}

.hamburger-menu .strip {
  display: block;
  height: 1px;
  background-color: #E9E7E1;
  margin: 4px 0;
}

header ul {
  list-style-type: none;
  -webkit-padding-start: 0px;
  padding-inline-start: 0px;
}

header ul li {
  display: inline-block;
  margin: 0 15px;
}

#close-flyout {
  display: none;
}

header ul li a {
  color: whitesmoke;
  font-size: 22px;
  text-decoration: none;
}

header ul.is-sticky li a {
  color: #31789F;
}

header ul li a:hover,
header ul li a.active {
  color: #E9E7E1;
}

header ul.is-sticky li a:hover,
header ul.is-sticky li a.active {
  color: #E9E7E1;
  text-shadow: 0 0 0 white;
}

.borders {
  border-bottom-left-radius: 300px 120px;
  border-bottom-right-radius: 300px 120px;
}

#hero {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  height: 100%;
  width: 100%;
}

#hero .fade {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  background: rgba(52, 58, 64, 0.3);
  z-index: 1;
}

#hero .hero-text {
  position: absolute;
  top: 50%;
  margin: -75px auto 0;
  left: 0;
  right: 0;
  z-index: 2;
  color: #E9E7E1;
  width: 500px;
  text-align: center;
}

#hero .hero-text p {
  line-height: 20px;
  font-weight: 300;
  font-size: 10px;
}

/* Positioning the hero section */
#hero {
  position: relative;
  /* height: 100vh; */
  /* Adjust as needed */
  overflow: hidden;
}

/* Styling the background images */
.bg-image {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  height: 100%;
  width: 100%;
  background-size: cover !important;
  background-repeat: no-repeat !important;
  background-position: center !important;
  opacity: 0;
}

/* Ensuring the first background is visible initially */
#bg1 {
  opacity: 1;
}

.header-text-cont {
  position: relative;
  z-index: 2;
  /* Ensure this is higher than the bg-image z-index */
}

#projektu {
  padding: 4rem 0;
  text-align: center;
  background-color: var(--g-color);
}

@media (max-width: 800px) {
  #projektu {
    padding: 60px 0;
  }
}

#projektu h2 {
  margin: 15px 0;
  font-size: 70px;
}

.flex {
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
}

.how-p {
  width: 60%;
  font-weight: 500;
}

@media (max-width: 1400px) {
  #projektu h2 {
    font-size: 60px;
  }
}

@media (max-width: 1000px) {
  #projektu h2 {
    font-size: 45px;
    line-height: 40px;
  }

  .how-p {
    width: 90%;
  }
}

#projektu .flex>div {
  width: 30%;
}

#projektu h4 {
  color: #343a40;
  margin-top: 1rem;
}

#projektu span.fas {
  color: #E9E7E1;
  font-size: 35px;
}

@media (max-width: 2500px) {
  #image {
    display: block;
    width: 100%;
    height: 100%;
  }

  .dziv {
    width: 100%;
    height: auto;
    border-bottom: 0;
  }

  .info {
    height: 7rem;
    width: 100%;
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-direction: row;
    flex-direction: row;
    -ms-flex-pack: distribute;
    justify-content: space-around;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
  }
}

@media (max-width: 1240px) {
  .info {
    height: 6rem;
  }

  /* #logo {
    top: 1px;
  } */

  #nav-toggle {
    display: block;
  }

  nav ul {
    position: fixed;
    background: #E9E7E1;
    right: -100%;
    top: 0;
    margin: 0;
    padding: 2rem;
    height: 100%;
    width: 300px;
    -webkit-box-sizing: border-box;
    box-sizing: border-box;
    -webkit-box-shadow: 5px 0 10px 3px #798C70;
    box-shadow: 5px 0 10px 3px #798C70;
  }

  #close-flyout {
    position: absolute;
    right: 2rem;
    top: 1.5rem;
    font-size: 30px;
    color: #798C70;
    cursor: pointer;
    display: block;
    line-height: 1;
    margin: 0;
  }

  nav ul li {
    display: block;
    margin: 20px 0;
  }

  nav ul li:first-child {
    margin-top: 50px;
  }

  nav ul li a {
    font-size: 20px;
    color: #798C70;
  }

  nav ul li a.active,
  nav ul li a:hover {
    color: #E9E7E1;
    text-shadow: 0 0 0 white;
  }
}

@media (max-width: 767px) {
  #header-hero-container {
    height: calc(90vh);
  }

  h1 {
    font-size: 2rem;
  }

  h2 {
    font-size: 1.8rem;
  }

  h3 {
    font-size: 1.2rem;
  }

  .large-paragraph {
    font-size: 1rem;
  }

  .container {
    max-width: 540px;
    display: flex;
    flex-direction: column-reverse;
  }

  .conter0 {
    flex-direction: column !important;
  }

  #hero .hero-text {
    width: 400px;
  }

  #agents .card {
    width: 49%;
  }

  #the-best .flex>img {
    display: none;
  }

  #the-best .flex>div {
    width: 100%;
  }

  #testimonials-slider p {
    font-size: 1.2rem;
  }

  #properties .container:before {
    top: 2px;
    font-size: 0.85rem;
  }

  #properties-slider a.slick-arrow {
    font-size: 0.85rem;
  }

  #properties button.rounded {
    width: 300px;
  }

  #services .flex>div {
    width: 48%;
  }

  #contact .flex {
    -ms-flex-wrap: wrap;
    flex-wrap: wrap;
  }

  #form-container {
    width: 100%;
    padding: 2rem;
  }

  #address-container {
    width: 100%;
    margin-top: 2rem;
  }
}

@media (max-width: 650px) {
  #header-hero-container {
    height: calc(85vh);
  }
}

@media (max-width: 530px) {
  .numb {
    font-size: 25px;
    font-weight: 700;
  }

  .sfs {
    font-size: 13px;
    font-weight: 300;
  }

  .info {
    height: 80px;
  }
}

@media (max-width: 500px) {
  #hero .hero-text {
    width: 330px;
  }

  #agents {
    margin: 4rem 0 3rem;
    padding: 0 0 3rem;
  }

  #agents .card {
    width: 100%;
  }

  #agents p.large-paragraph {
    width: 100%;
  }

  #projektu .flex>div {
    width: 100%;
    margin-top: 2rem;
  }

  #properties button.rounded {
    width: 250px;
  }

  #services {
    padding: 4rem 0 3rem;
    margin: 4rem 0;
  }

  #services .flex>div {
    width: 100%;
  }

  #testimonials {
    margin-bottom: 4rem;
  }

  #testimonials-slider p {
    font-size: 1rem;
  }

  #testimonials-slider .slick-arrow {
    display: none !important;
  }
}

@media (max-width: 410px) {
  .numb {
    font-size: 22px;
    font-weight: 700;
  }

  .sfs {
    font-size: 13px;
    font-weight: 300;
  }

  .info {
    height: 4rem;
  }
}

.formap {
  margin-top: 97px;
}

.atr {
  padding: 5rem 0 0 0;
}

.block {
  -webkit-transition: ease-in 1s;
  transition: ease-in 1s;
  position: absolute;
  top: -7%;
  left: -5%;
  opacity: 0;
  z-index: 2;
  width: 33%;
  pointer-events: none;
}

@media (max-width: 1300px) {
  .block {
    width: 45%;
  }
}

.block-m {
  background-color: var(--g-color);
  width: 35%;
  height: 100%;
}

.block-l {
  border-radius: 50% 0 0 50%;
}

.block-r {
  border-radius: 0 50% 50% 0;
}

.block-c {
  background-color: var(--g-color);
  padding: 0;
  width: 45%;
  height: auto;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -webkit-box-pack: center;
  -ms-flex-pack: center;
  justify-content: center;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -ms-flex-direction: column;
  flex-direction: column;
}

.block h3 {
  color: var(--r-color);
  text-align: center;
  font-size: 3rem;
  font-weight: 800;
}

.block p {
  color: var(--r-color);
  text-align: justify;
  font-size: 20px;
  z-index: 2;
  margin: 0 -60%;
  line-height: 20px;
}

.b-sca {
  width: 100%;
}

.b-ver {
  width: 100%;
}

.display {
  -webkit-transition: ease-in 1s;
  transition: ease-in 1s;
  opacity: 0.95;
}

@media (max-width: 1000px) {
  .display {
    display: none !important;
  }
}

.come-in {
  -webkit-transform: translateY(-40px);
  transform: translateY(-40px);
  -webkit-animation: come-in 0.8s ease forwards;
  animation: come-in 0.8s ease forwards;
  opacity: 0.2;
}

.come-in:nth-child(odd) {
  -webkit-animation-duration: 0.6s;
  animation-duration: 0.6s;
}

@-webkit-keyframes come-in {
  to {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes come-in {
  to {
    -webkit-transform: translateY(0);
    transform: translateY(0);
    opacity: 1;
  }
}

#overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: #31789F;
  /* filter: brightness(50%); */
  -moz-opacity: 0.7;
  -khtml-opacity: 0.7;
  opacity: 0.7;
  z-index: 100;
  display: none;
}

.cnt223 a {
  text-decoration: none;
}

.popup {
  width: 100%;
  margin: 0 auto;
  display: none;
  position: fixed;
  z-index: 101;
  background-color: #31789F;
}

.cnt223 {
  min-width: 600px;
  width: 600px;
  min-height: 150px;
  margin: 40vh auto;
  background: #E9E7E1;
  position: relative;
  z-index: 103;
  padding: 15px 35px;
  border-radius: 5px;
  box-shadow: 0 2px 5px #31789F;
}

.cnt223 p {
  clear: both;
  color: #798C70;
  /* text-align: justify; */
  font-size: 20px;
}

.cnt223 p a {
  color: #A0412D;
  font-weight: bold;
}

.cnt223 .x {
  float: right;
  height: 35px;
  left: 22px;
  position: relative;
  top: -25px;
  width: 34px;
}

.cnt223 .x:hover {
  cursor: pointer;
}

@media (max-width: 530px) {
  .cnt223 {
    min-width: 280px;
    width: 273px;
    min-height: 150px;
    margin: 40vh auto;
    background: #E9E7E1;
    position: relative;
    z-index: 103;
    padding: 15px 35px;
    border-radius: 5px;
    box-shadow: 0 2px 5px #798C70;
  }

  .cnt223 h1 {
    font-size: 20px;
  }

  .cnt223 p {
    font-size: 15px;
  }
}

@media (max-width: 530px) {
  .cnt223 {
    min-width: 240px;
    width: 230px;
    min-height: 150px;
    margin: 40vh auto;
    background: #E9E7E1;
    position: relative;
    z-index: 103;
    padding: 15px 35px;
    border-radius: 5px;
    box-shadow: 0 2px 5px #31789F;
  }

  .cnt223 h1 {
    font-size: 17px;
  }

  .cnt223 p {
    font-size: 13px;
  }
}