/* ----- */
/* Fonts */
/* ----- */

/* Georgia */
@font-face {
  font-family: Georgia;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: local(Georgia),
    url(../../assets/fonts/Georgia.ttf) format('truetype'),
    url(../../assets/fonts/Georgia.woff) format('woff'),
    url(../../assets/fonts/Georgia.woff2) format('woff2');
}

@font-face {
  font-family: Georgia;
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: local(Georgia),
    url(../../assets/fonts/Georgia-Bold.ttf) format('truetype'),
    url(../../assets/fonts/Georgia-Bold.woff) format('woff'),
    url(../../assets/fonts/Georgia-Bold.woff2) format('woff2');
}

@font-face {
  font-family: Georgia;
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: local(Georgia),
    url(../../assets/fonts/Georgia-Italic.ttf) format('truetype'),
    url(../../assets/fonts/Georgia-Italic.woff) format('woff'),
    url(../../assets/fonts/Georgia-Italic.woff2) format('woff2');
}

/* Arial */
@font-face {
  font-family: Arial;
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: local(Arial),
    url(../../assets/fonts/ArialMT.ttf) format('truetype'),
    url(../../assets/fonts/ArialMT.woff) format('woff'),
    url(../../assets/fonts/ArialMT.woff2) format('woff2');
}

@font-face {
  font-family: Arial;
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: local(Arial),
    url(../../assets/fonts/Arial-ItalicMT.woff) format('truetype'),
    url(../../assets/fonts/Arial-ItalicMT.woff) format('woff'),
    url(../../assets/fonts/Arial-ItalicMT.woff2) format('woff2');
}

/* -------------- */
/* General styles */
/* -------------- */

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

html {
  scroll-behavior: smooth;
}

body {
  max-width: 100vw;

  font-family: Georgia, serif;
}

.container {
  max-width: 1220px;
  min-width: 320px;
  margin: 0 auto;
  padding: 0 10px;

  display: flex;
  justify-content: space-between;
  align-items: center;
}

.list {
  display: flex;
  flex-wrap: wrap;

  list-style: none;
}

.link {
  display: block;

  color: #f1cdb3;
  text-decoration: none;
  transition: 0.3s;
}

.link.active {
  color: #292929;
  border-bottom: 3px solid #f1cdb3;
  cursor: default;
}

.section {
  padding-top: 80px;
  padding-bottom: 100px;
}

.section-title {
  font-family: Georgia, serif;
  font-style: normal;
  font-weight: 400;
  font-size: 35px;
  line-height: 1.3;
  letter-spacing: 0.06em;
  text-align: left;

  color: #545454;
}

.btn {
  padding: 15px 45px;

  font-family: 'Georgia';
  font-style: normal;
  font-weight: 400;
  font-size: 17px;
  line-height: 1.3;
  letter-spacing: 0.06em;

  color: rgba(41, 41, 41, 1);
  border: none;
  outline: none;
  border-radius: 100px;

  transition: all 0.3s linear;
}

.btn-filled {
  background-color: #f1cdb3;
}

.btn-filled:hover {
  background-color: #fddcc4;
}

.btn-ghost {
  background-color: transparent;
  border: 2px solid #f1cdb3;
}

.btn-ghost:hover:not(.btn-current):not(.disabled) {
  background-color: #fddcc4;
  border-color: #fddcc4;
}

/* Header */
.header {
  padding: 60px 0 30px;

  position: fixed;
  left: 0;
  right: 0;

  background-color: #ffffff;
}

.header-container {
  display: flex;
  flex-wrap: wrap;
}

.logo-link {
  display: flex;
  flex-direction: column;
  align-items: end;
}

.logo-title {
  padding-bottom: 9px;

  font-weight: 400;
  font-size: 32px;
  line-height: 1.1;
  letter-spacing: 0.06em;

  color: #545454;
}

.logo:hover .logo-title{
  color: #292929;
}

.logo-text {
  font-family: "Arial";
  font-weight: 400;
  font-size: 13px;
  line-height: 1.2;
  letter-spacing: 0.105em;

  color: #292929;
}

.logo:hover .logo-text{
  color: #545454;
}

.nav-list {
  column-gap: 36px;
}

.nav-link {
  font-family: "Arial";
  font-style: normal;
  font-weight: 400;
  font-size: 15px;
  line-height: 1.6;

  color: #545454;
  transition: all 0.3s linear;
}

.nav-link:hover {
  color: #292929;
}

/* Burger-menu */
.burger-menu {
  display: none;
  width: 30px;
  height: 30px;
  margin-right: 43px;
  position: relative;
  cursor: pointer;
  transition: all 0.3s linear;
}

.burger-line {
  width: 30px;
  height: 2px;
  position: absolute;
  background-color: #000000;
  transition: all 0.3s linear;
}

.burger-menu:hover .burger-line{
  background-color: #292929;
}

.burger-line_first {
  top: 3px;
}

.burger-line_second {
  top: 13px;
}

.burger-line_third {
  bottom: 5px;
}

/* Friends section */
.friends {
  padding-top: 230px;

  background-color: #f6f6f6;
}
.friends-container {
  flex-direction: column;  
}

.friends-title {
  padding-bottom: 60px;

  text-align: center;
}

.cards {
  width: 100%;
  padding-bottom: 60px;

  display: flex;
  justify-content: space-between;
  align-items: center;
  column-gap: 40px;
  row-gap: 30px;
}

.cards-list {
  justify-content: space-between;
  column-gap: 40px;
  row-gap: 30px;
}

.card {
  padding-bottom: 30px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  row-gap: 30px;

  background-color: #fafafa;
  border-radius: 9px;

  transition: all 0.3s linear;
}

.card:hover {
  background-color: #ffffff;
  box-shadow: 0px 2px 35px 14px rgba(13, 13, 13, 0.04);
}

.card:hover .btn-card {
  background-color: #fddcc4;
  border-color: #fddcc4;
}

.card-title,
.item-title {
  font-family: 'Georgia';
  font-style: normal;
  font-weight: 400;
  font-size: 20px;
  line-height: 1.15;
  letter-spacing: 0.06em;

  color: #545454;
}

.btn-card {
  padding: 12px 43px 14px;
}

.slider-controls {
  display: flex;
  column-gap: 20px;
}

.btn-start,
.btn-prev,
.btn-current,
.btn-next,
.btn-finish {
  width: 52px;
  height: 52px;
  padding: 17px;

  display: flex;
  justify-content: center;
  align-items: center;
  
  cursor: pointer;
}

.btn.active {
  background-color: #f1cdb3;
  cursor: default;
}

.btn.disabled {
  color: #cdcdcd;
  fill: #cdcdcd;
  stroke: #cdcdcd;
  background-color: transparent;
  border-color: #cdcdcd;
  cursor: default;
}

.icon {
  height: 23px;
  flex-shrink: 0;
}

/* Footer */
.footer {
  padding-top: 18px;

  background: url(../../assets/images/noise_transparent.png),
    radial-gradient(100% 215.42% at 0% 0%, #5B483A 0%, #262425 100%);
}

.footer-container {
  flex-wrap: wrap;
  column-gap: 120px;
}

.footer-section {
  width: 302px;
  min-height: 253px;
  padding: 0;

  display: flex;
  flex-direction: column;
  row-gap: 39px;
}

.footer-section:last-of-type {
  width: 322px;
  row-gap: 32px;
}

.footer-title {
  color: #ffffff;
}

.footer-link {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  column-gap: 20px;
}

.email-link,
.phone-link,
.address-link {
  font-family: 'Georgia';
  font-style: normal;
  font-weight: 400;
  font-size: 20px;
  line-height: 1.15;
  letter-spacing: 0.06em;

  fill: #f1cdb3;
  transition: all 0.3s linear;
}

.footer-link:hover {
  color: #fddcc4;
  fill: #fddcc4;
}

.footer-link:hover .footer-icon {
  fill: #fddcc4;
}

.marker-icon:first-of-type {
  flex-shrink: 0;
}

.footer-img {
  min-height: 332px;
  padding-top: 22px;
}

/* ------------- */
/* Media queries */
/* ------------- */

/* 768 <= width < 1280 */
@media (max-width: 1279px) {
  
  /* header */
  .header {
    padding-top: 30px;
  }

  .container {
    max-width: 708px;
    padding: 0;
  }

  /* friends */
  .friends {
    padding-top: 200px;
    padding-bottom: 76px;
  }

  .friends-title {
    padding-bottom: 30px;
  }

  .cards {
    padding-bottom: 41px;
    justify-content: center;
  }

  .cards-list {
    max-width: 580px;
    row-gap: 29px;
  }

  .cards-item:last-child,
  .cards-item:nth-last-child(2) {
    display: none;
  }
  
  /* footer */
  .footer {
    padding-top: 31px;
  }

  .footer-container {
    column-gap: 60px;
    justify-content: center;
    row-gap: 23px;
  }

  .footer-section {
    width: 280px;
  }

  .footer-section:last-of-type {
    width: 300px;
  }  

}

/* 320 <= width <= 768 */
@media (max-width: 767px) {

  /* general */
  .section {
    padding-top: 42px;
    padding-bottom: 43px;
  }

  .section-title {
    font-size: 25px;
    text-align: center;
  }

  /* header */
  .container {
    max-width: 300px;
    padding: 0 10px;
  }

  .logo {
    z-index: 3;
  }

  .burger-menu {
    display: block;
    z-index: 2;
    transition: all 0.3s linear;
  }

  .burger-menu.active {
    transform: rotate(90deg);
  }

  .burger-menu.active .burger-line {
    background-color: #fafafa;
  }

  .nav {
    max-width: 320px;
    position: fixed;
    top: 0;
    bottom: 0;
    right: 0;
    transform: translateX(320px);

    background-color: #292929;
    z-index: 2;
    transition: all 0.3s linear;
  }

  .nav.active {
    transform: translateX(0);
  }

  .overlay.active {
    display: block;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(41, 41, 41, 0.6);
    /* z-index: 1; */
  }

  .nav-list {
    padding-top: 248px;
    row-gap: 40px;
    justify-content: center;
  }

  .nav-link {
    font-size: 32px;
    line-height: 1.6;

    color: #cdcdcd;
  }

  .nav-link.active {
    color: #fafafa;
  }

  .nav-link:hover {
    color: #fafafa;
  }

  body.stop-scrolling {
      height: 100%;
      overflow: hidden;    
  }

  /* friends */
  .friends {
    padding-top: 160px;
    padding-bottom: 42px;
  }

  .friends-container {
    row-gap: 12px;
  }

  .cards {
    max-width: 270px;
    padding-bottom: 11px;
    flex-wrap: wrap;
    justify-content: space-around;
  }

  .cards-list {
    width: 270px;
    row-gap: 11px;
  }

  .cards-item:nth-child(n+4) {
    display: none;
  }

  .card {
    margin-bottom: 19px;
    row-gap: 0;
  }

  .card-title {
    padding: 30px 0;
  }

  .slider-controls {
    column-gap: 10px;
  }

  /* footer */
  .footer {
    padding-top: 29px;
  }

  .footer-container {
    row-gap: 12px;
  }

  .footer-section {
    min-height: 235px;
    padding-top: 0;
    padding-bottom: 0;
  }

  .footer-section:last-of-type {
    row-gap: 40px;
  }

  .footer-link {
    justify-content: center;
  }

  .phone-link {
    justify-content: center;
  }

  .address-link {
    justify-content: flex-start;
  }

  .footer-img {
    width: 260px;
    min-height: 286px;
    max-height: 269px;
    padding-top: 16px;    
  }
  
}
