/* ==========================================================================
   Funny's Snack — Profil Sayfası
   ========================================================================== */

.profile {
  padding-top: 40px;
  padding-bottom: 120px;
}

.profile__title {
  margin-bottom: 28px;
}

.profile__layout {
  display: grid;
  grid-template-columns: 300px minmax(0, 1fr);
  align-items: start;
  gap: 28px;
}

.profile__forms {
  display: grid;
  gap: 28px;
}

/* Satın almadan gelindiyse gösterilen bilgi çubuğu */
.notice-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 14px 24px;
  margin-bottom: 28px;
  padding: 16px 16px 16px 24px;
  border: 2px solid var(--c-red);
  border-radius: var(--radius-md);
  background: var(--c-white);
  font-size: 14px;
  font-weight: 400;
}

.notice-bar .btn {
  min-height: 44px;
  padding-inline: 26px;
  font-size: 15px;
}

/* Summary
   ========================================================================== */

.profile-summary {
  position: sticky;
  top: 24px;
  padding: 32px 24px 24px;
  border-radius: var(--radius-lg);
  background: var(--c-red);
  color: var(--c-white);
  text-align: center;
}

.profile-summary__avatar {
  display: grid;
  place-items: center;
  width: 84px;
  height: 84px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: var(--c-white);
  color: var(--c-red);
  font-family: var(--font-display);
  font-stretch: 115%;
  font-weight: 900;
  font-size: 30px;
}

.profile-summary__name {
  font-family: var(--font-display);
  font-stretch: 115%;
  font-weight: 900;
  font-size: 18px;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.profile-summary__email {
  margin-top: 4px;
  font-size: 13px;
  opacity: .85;
  overflow-wrap: anywhere;
}

.profile-summary__stats {
  margin: 22px 0 0;
  padding: 6px 16px;
  border-radius: var(--radius-md);
  background: var(--c-white);
  color: var(--c-text);
  text-align: left;
}

.profile-summary__stats > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  font-size: 14px;
}

.profile-summary__stats > div + div {
  border-top: 1px solid var(--c-bg);
}

.profile-summary__stats dd {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0;
  font-family: var(--font-display);
  font-stretch: 110%;
  font-weight: 900;
  color: #000;
}

.profile-summary__stats .coin {
  width: 20px;
  height: 20px;
}

/* Form cards
   ========================================================================== */

.profile-card {
  padding: 32px;
  border-radius: var(--radius-lg);
  background: var(--c-white);
}

.profile-card__title {
  margin-bottom: 20px;
  font-family: var(--font-display);
  font-stretch: 120%;
  font-weight: 900;
  font-size: 18px;
  text-transform: uppercase;
  color: #000;
}

.profile-card__title--spaced {
  margin-top: 16px;
  padding-top: 24px;
  border-top: 1px solid var(--c-bg);
  scroll-margin-top: 24px;
}

.profile-card__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 18px;
}

.profile-card__full {
  grid-column: 1 / -1;
}

.profile-card__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
  margin-top: 8px;
}

.profile-card__message {
  font-size: 14px;
  font-weight: 500;
  color: var(--c-navy);
}

/* Fields (açık zemin) */

.field {
  margin-bottom: 18px;
  min-width: 0;
}

.field__label {
  display: block;
  margin-bottom: 6px;
  font-family: var(--font-display);
  font-stretch: 115%;
  font-weight: 900;
  font-size: 12px;
  text-transform: uppercase;
  color: var(--c-text);
}

.field__input {
  display: block;
  width: 100%;
  min-height: 46px;
  padding: 10px 18px;
  border: 2px solid var(--c-bg);
  border-radius: 14px;
  background: var(--c-bg);
  color: #000;
  font-family: var(--font-body);
  font-weight: 400;
  font-size: 15px;
  outline: none;
  transition: border-color .2s ease, background .2s ease;
}

textarea.field__input {
  resize: vertical;
  line-height: 1.5;
}

select.field__input {
  appearance: none;
  padding-right: 44px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23EA4752' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  background-size: 18px;
  cursor: pointer;
}

.field__input:focus {
  border-color: var(--c-card);
  background-color: var(--c-white);
}

.field__input::placeholder {
  color: #B0A3A5;
}

.field__error {
  display: none;
  margin-top: 5px;
  font-size: 12px;
  font-weight: 400;
  color: var(--c-red);
}

.field.is-invalid .field__input {
  border-color: var(--c-red);
}

.field.is-invalid .field__error {
  display: block;
}

/* Responsive
   ========================================================================== */

@media (max-width: 900px) {
  .profile__layout {
    grid-template-columns: 1fr;
  }

  .profile-summary {
    position: static;
  }
}

@media (max-width: 767px) {
  .profile {
    padding-top: 24px;
    padding-bottom: 72px;
  }

  .profile-card {
    padding: 24px 18px;
  }

  .profile-card__grid {
    grid-template-columns: 1fr;
  }

  .profile-card__actions .btn,
  .notice-bar .btn {
    width: 100%;
  }
}
