/* ==========================================================================
   cookie.css — уведомление об использовании cookie и настройки согласия
   ========================================================================== */

.cookie-notification {
  position: fixed;
  right: 0;
  bottom: -110%;
  left: 0;
  z-index: 100001;
  max-height: calc(100vh - 24px);
  max-height: calc(100dvh - 24px);
  padding: 22px 24px;
  overflow-y: auto;
  overscroll-behavior: contain;
  color: #333;
  background: linear-gradient(180deg, #ffffff 0%, #f7f7f7 100%);
  border-radius: 14px 14px 0 0;
  box-shadow: 0 -6px 34px rgba(0, 0, 0, 0.14);
  box-sizing: border-box;
  font-family: "Roboto", "Open Sans", Helvetica, Arial, sans-serif;
  opacity: 0;
  transition: bottom 0.55s cubic-bezier(0.25, 0.1, 0.25, 1), opacity 0.3s ease;
}

.cookie-notification[hidden] {
  display: none !important;
}

.cookie-notification.show {
  bottom: 0;
  opacity: 1;
}

.cookie-content {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 34px;
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
}

.cookie-text {
  flex: 1 1 auto;
  min-width: 0;
  margin: 0;
  color: #333;
  font-size: 14px;
  line-height: 1.55;
}

.cookie-text p {
  margin: 0;
}

.cookie-text a {
  color: #b22222;
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(178, 34, 34, 0.3);
  transition: color 0.2s ease, border-color 0.2s ease;
}

.cookie-text a:hover {
  color: #8b0000;
  border-bottom-color: #8b0000;
}

.cookie-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 12px;
}

.cookie-btn {
  min-width: 142px;
  padding: 13px 24px;
  color: #ffffff;
  background: #b22222;
  border: 2px solid #b22222;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(178, 34, 34, 0.22);
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.cookie-btn:hover {
  background: #8b0000;
  border-color: #8b0000;
  box-shadow: 0 6px 16px rgba(139, 0, 0, 0.28);
  transform: translateY(-2px);
}

.cookie-btn:active {
  transform: translateY(0);
}

.cookie-btn_secondary {
  color: #444;
  background: #ffffff;
  border-color: #cfcfcf;
  box-shadow: none;
}

.cookie-btn_secondary:hover {
  color: #8b0000;
  background: #fff5f5;
  border-color: #b22222;
  box-shadow: 0 6px 16px rgba(178, 34, 34, 0.12);
}

.cookie-btn:focus-visible {
  outline: 2px solid #b22222;
  outline-offset: 3px;
}

/* Ссылка/кнопка «Настройки cookie» в подвале */
.tcs-cookie-settings {
  display: inline;
  padding: 0;
  color: inherit;
  background: none;
  border: 0;
  font: inherit;
  line-height: inherit;
  text-align: inherit;
  text-decoration: none;
  cursor: pointer;
}

.tcs-cookie-settings:focus-visible {
  outline: 2px solid currentColor;
  outline-offset: 2px;
}

@media (max-width: 992px) {
  .cookie-notification {
    padding: 20px;
  }

  .cookie-content {
    align-items: stretch;
    flex-direction: column;
    gap: 16px;
  }

  .cookie-text {
    font-size: 13.5px;
  }

  .cookie-actions {
    width: 100%;
  }

  .cookie-btn {
    flex: 1 1 0;
    min-width: 0;
  }
}

@media (max-width: 520px) {
  .cookie-notification {
    max-height: calc(100vh - 12px);
    max-height: calc(100dvh - 12px);
    padding: 16px 14px 18px;
    border-radius: 12px 12px 0 0;
  }

  .cookie-text {
    font-size: 12.5px;
    line-height: 1.5;
  }

  .cookie-actions {
    flex-direction: column;
    gap: 9px;
  }

  .cookie-btn {
    width: 100%;
    min-height: 46px;
    padding: 12px 16px;
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .cookie-notification,
  .cookie-btn {
    transition: none;
  }
}

@media print {
  .cookie-notification {
    display: none !important;
  }
}
