/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */

/* Document
   ========================================================================== */

/**
 * 1. Correct the line height in all browsers.
 * 2. Prevent adjustments of font size after orientation changes in iOS.
 */

html {
  line-height: 1.15; /* 1 */
  -webkit-text-size-adjust: 100%; /* 2 */
}

/* Sections
   ========================================================================== */

/**
 * Remove the margin in all browsers.
 */

body {
  margin: 0;
}

/**
 * Render the `main` element consistently in IE.
 */

main {
  display: block;
}

/**
 * Correct the font size and margin on `h1` elements within `section` and
 * `article` contexts in Chrome, Firefox, and Safari.
 */

h1 {
  font-size: 2em;
  margin: 0.67em 0;
}

/* Grouping content
   ========================================================================== */

/**
 * 1. Add the correct box sizing in Firefox.
 * 2. Show the overflow in Edge and IE.
 */

hr {
  box-sizing: content-box; /* 1 */
  height: 0; /* 1 */
  overflow: visible; /* 2 */
}

/**
 * 1. Correct the inheritance and scaling of font size in all browsers.
 * 2. Correct the odd `em` font sizing in all browsers.
 */

pre {
  font-family: monospace, monospace; /* 1 */
  font-size: 1em; /* 2 */
}

/* Text-level semantics
   ========================================================================== */

/**
 * Remove the gray background on active links in IE 10.
 */

a {
  background-color: transparent;
}

/**
 * 1. Remove the bottom border in Chrome 57-
 * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.
 */

abbr[title] {
  border-bottom: none; /* 1 */
  text-decoration: underline; /* 2 */
  text-decoration: underline dotted; /* 2 */
}

/**
 * Add the correct font weight in Chrome, Edge, and Safari.
 */

b,
strong {
  font-weight: bolder;
}

/**
 * 1. Correct the inheritance and scaling of font size in all browsers.
 * 2. Correct the odd `em` font sizing in all browsers.
 */

code,
kbd,
samp {
  font-family: monospace, monospace; /* 1 */
  font-size: 1em; /* 2 */
}

/**
 * Add the correct font size in all browsers.
 */

small {
  font-size: 80%;
}

/**
 * Prevent `sub` and `sup` elements from affecting the line height in
 * all browsers.
 */

sub,
sup {
  font-size: 75%;
  line-height: 0;
  position: relative;
  vertical-align: baseline;
}

sub {
  bottom: -0.25em;
}

sup {
  top: -0.5em;
}

/* Embedded content
   ========================================================================== */

/**
 * Remove the border on images inside links in IE 10.
 */

img {
  border-style: none;
}

/* Forms
   ========================================================================== */

/**
 * 1. Change the font styles in all browsers.
 * 2. Remove the margin in Firefox and Safari.
 */

button,
input,
optgroup,
select,
textarea {
  font-family: inherit; /* 1 */
  font-size: 100%; /* 1 */
  line-height: 1.15; /* 1 */
  margin: 0; /* 2 */
}

/**
 * Show the overflow in IE.
 * 1. Show the overflow in Edge.
 */

button,
input { /* 1 */
  overflow: visible;
}

/**
 * Remove the inheritance of text transform in Edge, Firefox, and IE.
 * 1. Remove the inheritance of text transform in Firefox.
 */

button,
select { /* 1 */
  text-transform: none;
}

/**
 * Correct the inability to style clickable types in iOS and Safari.
 */

button,
[type="button"],
[type="reset"],
[type="submit"] {
  -webkit-appearance: button;
}

/**
 * Remove the inner border and padding in Firefox.
 */

button::-moz-focus-inner,
[type="button"]::-moz-focus-inner,
[type="reset"]::-moz-focus-inner,
[type="submit"]::-moz-focus-inner {
  border-style: none;
  padding: 0;
}

/**
 * Restore the focus styles unset by the previous rule.
 */

button:-moz-focusring,
[type="button"]:-moz-focusring,
[type="reset"]:-moz-focusring,
[type="submit"]:-moz-focusring {
  outline: 1px dotted ButtonText;
}

/**
 * Correct the padding in Firefox.
 */

fieldset {
  padding: 0.35em 0.75em 0.625em;
}

/**
 * 1. Correct the text wrapping in Edge and IE.
 * 2. Correct the color inheritance from `fieldset` elements in IE.
 * 3. Remove the padding so developers are not caught out when they zero out
 *    `fieldset` elements in all browsers.
 */

legend {
  box-sizing: border-box; /* 1 */
  color: inherit; /* 2 */
  display: table; /* 1 */
  max-width: 100%; /* 1 */
  padding: 0; /* 3 */
  white-space: normal; /* 1 */
}

/**
 * Add the correct vertical alignment in Chrome, Firefox, and Opera.
 */

progress {
  vertical-align: baseline;
}

/**
 * Remove the default vertical scrollbar in IE 10+.
 */

textarea {
  overflow: auto;
}

/**
 * 1. Add the correct box sizing in IE 10.
 * 2. Remove the padding in IE 10.
 */

[type="checkbox"],
[type="radio"] {
  box-sizing: border-box; /* 1 */
  padding: 0; /* 2 */
}

/**
 * Correct the cursor style of increment and decrement buttons in Chrome.
 */

[type="number"]::-webkit-inner-spin-button,
[type="number"]::-webkit-outer-spin-button {
  height: auto;
}

/**
 * 1. Correct the odd appearance in Chrome and Safari.
 * 2. Correct the outline style in Safari.
 */

[type="search"] {
  -webkit-appearance: textfield; /* 1 */
  outline-offset: -2px; /* 2 */
}

/**
 * Remove the inner padding in Chrome and Safari on macOS.
 */

[type="search"]::-webkit-search-decoration {
  -webkit-appearance: none;
}

/**
 * 1. Correct the inability to style clickable types in iOS and Safari.
 * 2. Change font properties to `inherit` in Safari.
 */

::-webkit-file-upload-button {
  -webkit-appearance: button; /* 1 */
  font: inherit; /* 2 */
}

/* Interactive
   ========================================================================== */

/*
 * Add the correct display in Edge, IE 10+, and Firefox.
 */

details {
  display: block;
}

/*
 * Add the correct display in all browsers.
 */

summary {
  display: list-item;
}

/* Misc
   ========================================================================== */

/**
 * Add the correct display in IE 10+.
 */

template {
  display: none;
}

/**
 * Add the correct display in IE 10.
 */

[hidden] {
  display: none;
}

@font-face {
  font-family: 'Inter';
  font-style:  normal;
  font-weight: 400;
  src: url(dcba3388310e6ae77440.woff2) format("woff2");
}

@font-face {
  font-family: 'Inter';
  font-style:  normal;
  font-weight: 500;
  src: url(e481ef8133a3c71636e5.woff2) format("woff2");
}

@font-face {
  font-family: 'Inter';
  font-style:  normal;
  font-weight: 900;
  src: url(8d07d4e4ea9833df9373.woff2) format("woff2");
}

.page__content {
  background-color: black;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  display: flex;
  flex-direction: column;
}

.page__section {
  width: 100%;
  max-width: 882px;
  -webkit-box-sizing: border-box;
  -moz-box-sizing: border-box;
  box-sizing: border-box;
  position: relative;
  margin: 0 auto;
}

@media screen and (max-width: 1140px) {
  .page__section {
    width: calc(100% - 40px);
  }
}

.page {
  background: #000;
}

.header__logo {
  width: 142px;
  height: 33px;
  object-fit: contain;
}

@media screen and (max-width: 480px) {
  .header__logo {
    width: 104px;
    height: 24px;
    margin: 0 0 0 7px;
  }
}

.header {
  min-height: 120px;
  font-family: 'Inter', Arial, sans-serif;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.header::before {
  content: '';
  width: 100%;
  height: 1px;
  opacity: 0.7;
  background: #545454;
  position: absolute;
  left: 50%;
  -webkit-transform: translateX(-50%);
  -moz-transform: translateX(-50%);
  -ms-transform: translateX(-50%);
  -o-transform: translateX(-50%);
  transform: translateX(-50%);
  bottom: 0;
}

@media screen and (max-width: 480px) {
  .header {
    min-height: 85px;
  }
  .header::before {
    width: calc(100% + 40px);
  }
}

.content {
  flex-shrink: 0;
  flex-grow: 1;
}

.footer__copyright {
  font-size: 18px;
  line-height: 22px;
  color: #545454;
  margin: 0;
}

@media screen and (max-width: 568px) {
  .footer__copyright {
    font-size: 14px;
    line-height: 17px;
  }
}

.footer {
  font-family: 'Inter', Arial, sans-serif;
  flex-shrink: 0;
  padding: 30px 0 60px;
}

@media screen and (max-width: 568px) {
  .footer {
    padding: 30px 0 36px;
  }
}

.profile__description {
  font-size: 18px;
  line-height: 22px;
  grid-area: description;
  margin: 0;
}

@media screen and (max-width: 568px) {
  .profile__description {
    font-size: 14px;
    line-height: 17px;
  }
}

@media screen and (max-width: 480px) {
  .profile__description {
    width: 100%;
    margin: 7px 0 0 0;
  }
}

.profile__add-button {
  width: 150px;
  height: 50px;
  background: transparent url(bed8c136e13907f5eefb.svg) center no-repeat;
  background-size: 22px;
  -webkit-border-radius: 2px;
  -moz-border-radius: 2px;
  border-radius: 2px;
  border: 2px solid #fff;
  -webkit-transition: 0.3s;
  -moz-transition: 0.3s;
  -ms-transition: 0.3s;
  -o-transition: 0.3s;
  transition: 0.3s;
  cursor: pointer;
  margin-left: auto;
}

.profile__add-button:hover {
  opacity: 0.6;
}

@media screen and (max-width: 740px) {
  .profile__add-button {
    width: 50px;
    height: 50px;
  }
}

@media screen and (max-width: 480px) {
  .profile__add-button {
    width: 100%;
  }
}

.profile__edit-button {
  width: 24px;
  height: 24px;
  background: transparent url(6c7bf05444b9793fdf6e.svg) center no-repeat;
  background-size: 10px 10px;
  border: 1px solid #fff;
  grid-area: button;
  align-self: center;
  cursor: pointer;
  -webkit-transition: 0.3s;
  -moz-transition: 0.3s;
  -ms-transition: 0.3s;
  -o-transition: 0.3s;
  transition: 0.3s;
  padding: 0;
  margin: 0;
}

.profile__edit-button:hover {
  opacity: 0.6;
}

@media screen and (max-width: 480px) {
  .profile__edit-button {
    width: 18px;
    height: 18px;
    background-size: 8px 8px;
  }
}

.profile__info {
  display: grid;
  grid-template-areas: "title button"
  "description description";
  grid-template-columns: minmax(auto, 295px) auto;
  grid-gap: 9px 17px;
}

@media screen and (max-width: 740px) {
  .profile__info {
    grid-template-columns: minmax(auto, 228px) auto;
    grid-gap: 9px 5px;
  }
}

@media screen and (max-width: 568px) {
  .profile__info {
    grid-template-columns: minmax(auto, 195px) auto;
  }
}

@media screen and (max-width: 480px) {
  .profile__info {
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin: 26px 0 33px 0;
  }
}

.profile__title {
  font-size: 42px;
  line-height: 48px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  grid-area: title;
  margin: 0;
}

@media screen and (max-width: 740px) {
  .profile__title {
    font-size: 32px;
    line-height: 38px;
  }
}

@media screen and (max-width: 568px) {
  .profile__title {
    font-size: 27px;
    line-height: 33px;
  }
}

@media screen and (max-width: 480px) {
  .profile__title {
    min-width: 201px;
  }
}

.profile__image {
  width: 120px;
  height: 120px;
  -webkit-border-radius: 50%;
  -moz-border-radius: 50%;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  margin: 0 29px 0 0;
  position: relative;
}

.profile__image::after {
  content: '';
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.5);
  background-image: url(a086f758840ae814ecde.svg);
  background-repeat: no-repeat;
  background-position: center;
  opacity: 0;
  z-index: 1;
}

.profile__image:hover::after {
  opacity: 1;
  cursor: pointer;
}


@media screen and (max-width: 740px) {
  .profile__image {
    margin: 0 10px 0 0;
  }
}

@media screen and (max-width: 480px) {
  .profile__image {
    margin-right: 0;
  }
}

.profile {
  font-family: 'Inter', Arial, sans-serif;
  color: #fff;
  display: flex;
  align-items: center;
  padding: 36px 0;
}

@media screen and (max-width: 480px) {
  .profile {
    padding: 43px 0;
    flex-direction: column;
    text-align: center;
  }
}

.places__list {
  display: grid;
  grid-template-columns: repeat(auto-fit, 282px);
  justify-content: center;
  grid-gap: 20px 18px;
  list-style-type: none;
  margin: 0;
  padding: 0;
}

.places__item {

}

.places {
  font-family: 'Inter', Arial, sans-serif;
  padding: 15px 0 36px;
}

@media screen and (max-width: 568px) {
  .places {
    padding: 15px 0 18px;
  }
}

.card__description {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #fff;
  padding: 25px 20px;
}

.card__image {
  height: 282px;
  object-fit: cover;
  width: 100%;
}

.card__image:hover {
  cursor: pointer;
}

.card__like-button {
  width: 21px;
  height: 18px;
  background: transparent url(df0c965524717a3fd8e9.svg) no-repeat;
  
  background-size: 21px 18px;
  border: none;
  cursor: pointer;
  padding: 0;
  margin: 0;
  -webkit-transition: 0.3s;
  -moz-transition: 0.3s;
  -ms-transition: 0.3s;
  -o-transition: 0.3s;
  transition: 0.3s;
}

.card__like-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card__like-counter {
  font-size: 13px;
  font-family: 'Inter', Arial, sans-serif;
  margin-top: 3px;
  line-height: 100%;
}

.card__like-button:hover {
  opacity: 0.6;
}

.card__like-button_is-active {
  background: transparent url(a7ffe37dcb927ba0c46c.svg) no-repeat;
}

.card__delete-button {
  width: 18px;
  height: 18px;
  background: transparent url(2af49b82d305a6ea3442.svg) center no-repeat;
  /*Потом это будет из модификатора*/
  background-size: 18px 18px;
  border: none;
  cursor: pointer;
  position: absolute;
  top: 18px;
  right: 15px;
  padding: 0;
  margin: 0;
  -webkit-transition: 0.3s;
  -moz-transition: 0.3s;
  -ms-transition: 0.3s;
  -o-transition: 0.3s;
  transition: 0.3s;
}

.card__delete-button:hover {
  opacity: 0.6;
}

.card__title {
  max-width: 220px;
  font-size: 24px;
  line-height: 29px;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  /*Либо с точками из макета, либо этот набор свойств для эллипсиса текста в можно лучше*/
  margin: 0;
}

.card {
  font-family: 'Inter', Arial, sans-serif;
  -webkit-border-radius: 10px;
  -moz-border-radius: 10px;
  border-radius: 10px;
  position: relative;
  overflow: hidden;
}

.popup__content {
  max-width: 430px;
  width: 100%;
  min-height: 330px;
  background-color: #fff;
  border-radius: 10px;
  position: relative;
  box-sizing: border-box;
  padding: 34px 36px;
}

@media screen and (max-width: 568px) {
  .popup__content {
    width: 100%;
    max-width: calc(100% - 80px);
    margin-top: 40px;
    padding: 30px 20px;
  }
}

.popup__content_content_image {
  max-width: 75vw;
  max-height: 75vh;
  height: auto;
  width: auto;
  display: flex;
  background: transparent;
  -webkit-background-size: cover;
  background-size: cover;
  -webkit-border-radius: 0;
  -moz-border-radius: 0;
  border-radius: 0;
  padding: 0;
}

.popup__close {
  width: 35px;
  height: 35px;
  background: transparent url(8a65f75d3d836c291cc9.svg) center no-repeat;
  background-size: 35px 35px;
  border: none;
  position: absolute;
  top: -36px;
  right: -34px;
  -webkit-transform: rotate(90deg);
  -moz-transform: rotate(90deg);
  -ms-transform: rotate(90deg);
  -o-transform: rotate(90deg);
  transform: rotate(90deg);
  transition: visibility 0s, opacity 0.3s;
  padding: 0;
  margin: 0;
  cursor: pointer;
}

.popup__close:hover {
  opacity: 0.6;
}

.popup__title {
  margin: 0;
  font-size: 24px;
  line-height: 30px;
}

@media screen and (max-width: 568px) {
  .popup__title {
    font-size: 18px;
    line-height: 22px;
  }
}

.popup__form {
  margin-top: 27px;
}

.popup__input {
  width: 100%;
  height: 47px;
  border: 0;
  border-bottom: 1px solid rgba(0, 0, 0, .2);
  font-size: 14px;
  line-height: 18px;
  box-sizing: border-box;
  padding: 10px 0 0;
  margin-bottom: 10px;
}

.popup__input:last-of-type {
  margin-bottom: 0;
}

@media screen and (max-width: 568px) {
  .popup__title {
    font-size: 12px;
    line-height: 15px;
  }
}

.popup__button {
  width: 100%;
  height: 50px;
  font-size: 18px;
  line-height: 22px;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
  border-radius: 2px;
  border: none;
  transition: visibility 0s, background 0.3s;
  margin-top: 48px;
}

.popup__button:hover {
  background: rgba(0, 0, 0, 0.8);
  cursor: pointer;
}

@media screen and (max-width: 568px) {
  .popup__button {
    font-size: 14px;
    line-height: 17px;
  }
}

.popup__caption {
  font-size: 12px;
  line-height: 15px;
  color: #fff;
  position: absolute;
  left: 0;
  top: calc(100% + 10px);
  margin: 0;
}

.popup__image {
  max-height: 100%;
  max-width: 100%;
  object-fit: cover;
  display: block;
}

.popup {
  font-family: 'Inter', Arial, sans-serif;
  display: none;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, .5);
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  z-index: 10;
}

.popup_is-animated {
    display: flex;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
    user-select: none;
    transition: visibility 0s 0.6s, opacity 0.6s;
}
.popup_is-opened {
  display: flex;
  visibility: visible;
  opacity: 1;
  pointer-events: all;
  transition: visibility 0s, opacity 0.6s;
}

.form__input-error {
  font-size: 12px;
  color: red;
  min-height: 16px;
  display: block;
}

.form__input_type_error {
  border-bottom: 1px solid rgb(255, 0, 0);
}

.form__input-error_active {
  visibility: visible;
}

.button_inactive {
  background: white;
  border: solid 1px black;
  color: #000000;
  opacity: .5;
}

.button_inactive:hover {
  cursor: not-allowed;
  background: transparent;
}


