/* General styles */

:root {
  --main-color: #303030;
  --second-color: #555555;
  --accent-color: #ff6c00;
  --pre-title-case: uppercase;
  --title-first-color: #ffffff;
  --title-second-color: #303030;
  --button-first-color: #ffffff;
  --button-second-color: #303030;
  --specific-ident: 20px;
}

h1,
h2,
p {
  margin: 0;
}

.page-body {
  font-family: "Open Sans", sans-serif;
}

.container {
  width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  border: 0;
  padding: 0;
  white-space: nowrap;
  clip-path: inset(100%);
  clip: rect(0 0 0 0);
  overflow: hidden;
}

.link {
  text-decoration: none;
}

.list {
  list-style: none;
  padding-left: 0;
  margin: 0;
}

.button {
  font-weight: 600;
  font-size: 12px;
  line-height: calc(16 / 12);
  letter-spacing: 0.09em;
  text-transform: uppercase;
  cursor: pointer;
  font-family: inherit;
  padding: 12px 20px;
  min-width: 160px;
  background: transparent;
  border: 1px solid var(--accent-color);
  border-radius: 50px;
}

.second-button:hover,
.second-button:focus {
  color: var(--button-first-color);
}

.title {
  font-family: "Railway", sans-serif;
}

.second-title {
  font-size: 42px;
  line-height: calc(49 / 42);
  letter-spacing: 0.05em;
}

.pre-title {
  font-weight: 600;
  font-size: 11px;
  line-height: calc(15 / 11);
  text-transform: var(--pre-title-case);
}

.pre-title::before {
  content: " ";
  display: inline-block;
  height: 1px;
  width: 60px;
  background-color: var(--main-color);
  margin-right: 20px;
  vertical-align: middle;
}

/* Header styles */

.page-header {
  padding: 32px 0;
  position: absolute;
  width: 100%;
}

.page-header .container {
  display: flex;
  align-items: center;
}

.header-logo {
  margin-right: 120px;
}

.header-list {
  display: flex;
}

.header-list .item:not(:first-child) {
  margin-left: 25px;
}

.header-contacts {
  margin-left: auto;
}

.header-link {
  font-weight: 600;
  font-size: 12px;
  line-height: calc(16 / 12);
  letter-spacing: 0.1em;
  color: #ffffff;
  transition: color 500ms linear;
}

.header-link:hover,
.header-link:focus {
  color: var(--accent-color);
}

.header-button {
  color: var(--button-first-color);
  margin-left: 35px;
}

/* Hero styles */

.hero .container {
  display: flex;
}

.hero .social-wrapper {
  width: 100px;
  display: flex;
  align-items: flex-end;
  padding-left: 25px;
  padding-bottom: 40px;
}

.hero-list {
  transform: rotate(-90deg) translate(19px);
  display: flex;
  align-items: center;
  transform-origin: top left;
  position: relative;
}

.hero-list::before {
  content: " ";
  position: absolute;
  width: 40px;
  height: 1px;
  background-color: var(--main-color);
  left: -40px;
  top: 9px;
}

.hero-list .item {
  margin-left: 40px;
}

.hero .list-link {
  font-weight: 600;
  font-size: 11px;
  line-height: calc(15 / 11);
  letter-spacing: 0.2em;
  color: var(--main-color);
}

.hero .list-link:hover,
.hero .list-link:focus {
  color: var(--accent-color);
}

.hero-description {
  padding-top: 176px;
  padding-left: 200px;
  padding-right: 50px;
  padding-bottom: 210px;
  background-color: #2d2c2c;
  background-image: linear-gradient(
      rgba(25, 28, 38, 0.2),
      rgba(25, 28, 38, 0.2)
    ),
    url(../img/hero-description-bg.jpg);
  background-repeat: no-repeat;
  background-size: cover;
  flex-grow: 1;
}

.hero .pre-title {
  color: rgba(157, 164, 189, 0.6);
  margin-bottom: var(--specific-ident);
}

.hero .pre-title::before {
  background-color: rgba(157, 164, 189, 0.6);
}

.hero .title {
  font-size: 72px;
  line-height: calc(85 / 72);
  letter-spacing: 0.05em;
  color: var(--title-first-color);
  margin-bottom: var(--specific-ident);
}

.hero-text {
  font-size: 18px;
  line-height: calc(30 / 18);
  letter-spacing: 0.02em;
  color: #9da4bd;
  max-width: 360px;
}

/* About styles */

.about {
  padding: 120px 0;
}

.about .container {
  display: flex;
  align-items: flex-start;
}

.about .pre-title {
  color: var(--main-color);
  margin-bottom: var(--specific-ident);
}

.about .title {
  color: var(--title-second-color);
  margin-bottom: var(--specific-ident);
}

.about .after-title {
  font-size: 18px;
  line-height: calc(30 / 18);
  letter-spacing: 0.02em;
  color: var(--second-color);
  margin-bottom: var(--specific-ident);
}

.about-img {
  margin-right: 30px;
}

.about-text {
  font-size: 14px;
  line-height: calc(26 / 14);
  letter-spacing: 0.02em;
  color: var(--second-color);
  margin-bottom: 42px;
}

.about-button {
  color: var(--button-second-color);
}

/* Services styles */

.services {
  background-color: rgb(17, 19, 25);
  background-image: url(../img/services-bg.png);
  background-position: right top;
  background-repeat: no-repeat;
  background-size: cover;
  padding: 120px 0;
}

.services .pre-title {
  color: rgba(157, 164, 189, 0.6);
  margin-bottom: var(--specific-ident);
}

.services .title {
  color: var(--title-first-color);
  margin-bottom: 44px;
}

.services .our-price {
  display: flex;
  margin-right: -30px;
}

.services-list {
  padding: 30px 20px;
  width: calc((100% - 60px) / 2);
  margin-right: 30px;
  margin-bottom: 44px;
}

.services-first {
  background: linear-gradient(180deg, #171a24 0%, rgba(23, 26, 36, 0.2) 100%);
}

.services-second {
  background: linear-gradient(180deg, #090b13 0%, rgba(9, 11, 19, 0.2) 100%);
}

.services-list .item:not(:last-child) {
  margin-bottom: 20px;
}

.services-list .item {
  display: flex;
  justify-content: space-between;
}

.services .text {
  font-size: 18px;
  line-height: calc(30 / 18);
  letter-spacing: 0.02em;
  color: #9da4bd;
}

.services-button {
  color: var(--button-first-color);
  display: block;
  margin: auto;
}

/* Benefits styles */
.benefits-container {
  display: flex;
  padding-top: 130px;
  padding-bottom: 120px;
}

.benefits-list {
  width: 370px;
  display: flex;
  flex-wrap: wrap;
  margin-right: 130px;
}

.benefits-description {
  max-width: 550px;
}

.benefits-list .item {
  background-color: #f7f7f7;
  width: 170px;
  height: 133px;
  text-align: center;
  padding: 20px 24px;
}

.benefits-list .item:nth-child(odd) {
  margin-right: 30px;
}

.benefits-list .item:nth-child(even) {
  margin-top: 30px;
}

.benefits-list .number {
  font-weight: 700;
  font-size: 42px;
  line-height: calc(57 / 42);
  letter-spacing: 0.05em;
  color: var(--main-color);
}

.benefits-list .sign {
  font-weight: 600;
  font-size: 16px;
  line-height: calc(22 / 16);
  color: var(--accent-color);
}

.benefits-list .text {
  font-weight: 600;
  font-size: 11px;
  line-height: calc(15 / 11);
  color: var(--main-color);
}

.benefits .pre-title {
  color: var(--main-color);
}

.benefits .title {
  color: var(--title-second-color);
}

.benefits .after-title {
  font-size: 18px;
  line-height: calc(30 / 18);
  letter-spacing: 0.02em;
  color: var(--second-color);
}

/* Barbers styles */

.barbers {
  padding: 120px 0;
  background-color: #f7f7f7;
}

.barbers .pre-title {
  color: var(--main-color);
}

.barbers .title {
  color: var(--title-second-color);
}

.barber-list {
  display: flex;
  margin-left: -30px;
}

.barber-list img {
  display: block;
}

.barber-list .item {
  flex-basis: calc((100% - 90px) / 3);
  margin-left: 30px;
  cursor: pointer;
}

.barber-list .img-wrapper {
  position: relative;
  overflow: hidden;
}

.barber-description {
  background-color: rgba(255, 166, 0, 0.427);
  position: absolute;
  bottom: 0;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  font-size: 20px;
  padding: 20px;
  transform: translateY(100%);
  transition: transform 500ms linear;
}

.barber-list .item:hover .barber-description {
  transform: translateY(0);
}

/* .barber-list .item:hover .barber-description {
  opacity: 1;
} */

.barber-list .social-icons {
  display: flex;
  justify-content: center;
  margin-top: 30px;
}

.barber-list .social-item {
  width: 44px;
  height: 44px;
  margin-right: 10px;
}

.barber-list .social-item:last-child {
  margin-right: 0;
}

.barber-list .social-link {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background-color: #ffffff;
  color: var(--main-color);
}

.barber-list .social-icon {
  fill: currentColor;
}

.barber-list .social-link:hover,
.barber-list .social-link:focus {
  color: var(--accent-color);
}

.barber-name {
  font-size: 18px;
  line-height: calc(25 / 18);
  text-align: center;
  letter-spacing: 0.02em;
  color: var(--main-color);
}

.barber-position {
  font-size: 14px;
  line-height: calc(19 / 14);
  text-align: center;
  letter-spacing: 0.02em;
  color: var(--accent-color);
}

/* Gallery styles */

.gallery {
  padding: 120px 0;
}

.gallery .pre-title {
  color: var(--main-color);
  margin-bottom: 44px;
}

.gallery-images {
  display: flex;
  margin-right: -30px;
}

.gallery-images .img {
  flex-basis: calc((100% - 120px) / 4);
  margin-right: 30px;
}

/* Booking Contacts */

.booking-contacts {
  background-color: #191c26;
  display: flex;
  justify-content: space-between;
  height: 634px;
  background-repeat: no-repeat;
  background-position: right;
}

.booking-contacts .booking {
  padding-top: 130px;
  padding-left: 216px;
  padding-right: 30px;
}

.booking-contacts .contacts {
  width: 50%;
  background-image: url(../img/contacts-bg.png);
}

.booking-form {
  display: flex;
  flex-wrap: wrap;
  width: 570px;
}

.booking-form input {
  padding-bottom: 8px;
}

.booking-form input,
.booking-form textarea {
  background-color: transparent;
  border: none;
  border-bottom: 1px solid rgba(157, 164, 189, 0.4);
  color: rgba(157, 164, 189, 0.4);
}

.booking-form input:focus,
.booking-form textarea:focus {
  border-bottom: 1px solid #fff;
  outline: transparent;
  color: #fff;
}

.booking-form input::placeholder,
.booking-form textarea::placeholder {
  text-transform: uppercase;
  font-weight: 600;
  font-size: 11px;
}

.booking-form input:focus::placeholder,
.booking-form textarea:focus::placeholder {
  color: #fff;
}

.booking-form input {
  width: 270px;
  height: 24px;
  margin-bottom: 44px;
}

.booking-form .textarea-wrapper {
  width: 100%;
  margin-bottom: 44px;
}

.booking-form textarea {
  width: 570px;
  height: 76px;
  resize: none;
  display: block;
}

.booking-form .button {
  display: inline-block;
  color: var(--button-first-color);
}

.booking-form .name-input + input {
  margin-left: 30px;
}

.contacts {
  padding-top: 130px;
  padding-bottom: 120px;
  padding-left: 100px;
}

.contacts .title,
.booking .title {
  color: var(--title-first-color);
  margin-bottom: 40px;
}

.contacts .contact-address {
  font-style: normal;
}

.contacts .address-item {
  margin-bottom: 20px;
}

.contacts .address-link {
  display: flex;
  align-items: center;
  color: #9da4bd;
}

.contacts .address-link:hover {
  color: var(--accent-color);
}

.contacts .icon {
  margin-right: 16px;
  fill: none;
  stroke: currentColor;
}

.contacts .address-link:hover,
.contacts .address-link:focus {
  color: var(--accent-color);
}

.modal-backdrop {
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  right: 0;
  background-color: rgba(0, 0, 0, 0.8);
  transition: opacity 500ms, visibility 500ms;
}

.modal-backdrop.is-hidden .modal {
  transform: rotate(-180deg);
}

.modal {
  width: 500px;
  height: 600px;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(0);
  transition: transform 1000ms linear;
  background-color: #ffffff;
  border-radius: 20px;
}

.modal .close-sign {
  position: absolute;
  display: flex;
  justify-content: center;
  cursor: pointer;
  align-items: center;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 30px;
  border: 1px solid #000000;
  border-radius: 50%;
}

.is-hidden {
  visibility: hidden;
  opacity: 0;
  pointer-events: none;
}

.modal-form {
  padding: 50px;
}

.modal-input {
  width: 100%;
  height: 40px;
  margin-bottom: 10px;
  border-radius: 10px;
  border: 1px solid #303030;
  padding: 10px;
  padding-left: 25px;
  font-size: 12px;
  color: #ff6c00;
  font-weight: bold;
}

.modal-textarea {
  width: 100%;
  height: 60px;
  border-radius: 10px;
  border: 1px solid #303030;
  resize: none;
  padding: 10px;
  font-size: 12px;
  color: #ff6c00;
  font-weight: bold;
}

.modal-input::placeholder,
.modal-textarea::placeholder {
  font-size: 14px;
  font-weight: normal;
  color: blue;
}

.modal-label,
.label-span {
  display: inline-block;
  width: 100%;
  margin-bottom: 10px;
  font-size: 14px;
  color: #555555;
}

.sizes {
  margin: 20px 0;
}

.select-cities {
  width: 100%;
  margin: 10px 0;
  border-radius: 10px;
}

.input-wrapper {
  position: relative;
  margin-bottom: 10px;
}

.input-wrapper input {
  margin-bottom: 0;
}

.input-icon {
  position: absolute;
  left: 5px;
  top: 50%;
  transform: translateY(-50%);
  fill: #212121;
}

.modal-input:focus + .input-icon,
.modal-input:hover + .input-icon {
  fill: orange;
}

.check-line {
  margin: 10px 0;
}

.checkbox-agree {
  display: flex;
  align-items: center;
}

.checkbox-agree .icon-wrapper {
  width: 16px;
  height: 15px;
  border: 2px solid #000000;
  border-radius: 2px;
  margin-right: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.checkbox-agree .agree-icon {
  fill: transparent;
}

.check-line input:checked + .checkbox-agree .icon-wrapper {
  background-color: orange;
  border: none;
}

.check-line input:checked + .checkbox-agree .agree-icon {
  fill: #ffffff;
}
/* .checkbox-agree::before {
  content: " ";
  margin-right: 8px;
  display: flex;
  width: 16px;
  height: 15px;
  border: 2px solid #000000;
  border-radius: 2px;
}

.check-line input:checked + .checkbox-agree::before {
  background-color: orange;
  border: none;
  background-image: url(../img/check-mark.svg);
  background-repeat: no-repeat;
  background-position: center;
} */
