/* Cookie consent banner */
#cuki-notice {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  height: 150px;
  background: rgba(255, 255, 255, 0.91);
  border-top: 1px solid #007BFF;
  display: none;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px 10px 20px;
  z-index: 1000;
  opacity: 0;
  animation: bannerAppear 0.4s ease 3s forwards;
}

#cuki-notice.immediate {
  animation: none !important;
  opacity: 1 !important;
}

@keyframes bannerAppear {
  0%   { opacity: 0; }
  100% { opacity: 1; }
}

.cuki-text-block {
  padding-left: 35px;
}
.cuki-text-block p {
  margin: 4px 0;
  color: black;
  font-size: 15px;
}
.cuki-more-details {
  color: #007BFF;
  text-decoration: none;
  font-size: 15px;
}
.cuki-more-details:hover { text-decoration: underline; }

.cuki-buttons-block {
  display: flex;
  align-items: center;
  position: relative;
}
.cuki-language-button {
  margin-left: 43px;
  color: black;
  text-decoration: none;
  font-size: 16px;
  position: relative;
}
.cuki-language-button:hover { text-decoration: underline; }

.cuki-language-dropdown {
  position: absolute;
  bottom: 100%;
  left: 0;
  background: white;
  border: 1px solid #ccc;
  width: 60px;
  display: none;
  z-index: 1001;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
  border-radius: 6px;
}
.cuki-language-dropdown a {
  display: block;
  padding: 8px 10px;
  text-align: center;
  color: black;
  text-decoration: none;
  font-size: 16px;
}
.cuki-language-dropdown a:hover {
  background: #f5f5f5;
}

.cuki-action-buttons {
  flex: 1;
  text-align: center;
}
.cuki-action-button {
  margin: 0 12px;
  color: #007BFF;
  text-decoration: none;
  font-size: 15px;
}
.cuki-action-button:hover { text-decoration: underline; }

/* Modal window */
#cuki-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1001;
  opacity: 0;
  transition: opacity 0.3s ease;
}
#cuki-modal-overlay.visible { opacity: 1; }

#cuki-modal {
  background: rgba(255, 255, 255, 0.95);
  width: 600px;
  max-width: 90%;
  height: 450px;
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.2);
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.cuki-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 25px 15px;
  color: black;
  border-bottom: 1px solid #eee;
}

.cuki-close {
  cursor: pointer;
  font-size: 24px;
  font-weight: bold;
  color: #667;
}

.cuki-modal-content {
  flex: 1;
  padding: 0 25px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #ccc transparent;
    scrollbar-gutter: stable;
}

.cuki-modal-content::-webkit-scrollbar {
  width: 6px;
}

.cuki-modal-content::-webkit-scrollbar-track {
  background: transparent;
}

.cuki-modal-content::-webkit-scrollbar-thumb {
  background: #ccc;
  border-radius: 3px;
}

.cuki-section {
  margin: 15px 0;
  color: black;
}

.cuki-section.necessary {
  background-color: #f9f9f9;
  border-radius: 8px;
}

.cuki-section.analytics p,
.cuki-section.marketing p {
  padding-left: 15px;
}

.cuki-section-inner {
  padding: 15px;
}

.cuki-section h4 {
  margin: 0 0 8px 0;
  font-size: 16px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 15px 25px 0 15px; /* отступы внутри секции, но не влияют на позицию стрелки */
  position: relative;
}

.cuki-always-active {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #667;
  white-space: nowrap;
  margin-left: auto;
}

.cuki-checkbox-square {
  width: 16px;
  height: 16px;
  border: 2px solid #ccc;
  position: relative;
  border-radius: 3px;
  background: white;
}

.cuki-checkbox-square.necessary {
  background: #f0f0f0;
  border-color: #ccc;
  cursor: default;
}

.cuki-checkbox-square.necessary.active::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 12px;
  font-weight: bold;
  color: #333;
}



/* Стили для  чекбоксов  Analytics Marketing */
.cuki-checkbox-label {
  display: flex;
  align-items: center;
  margin-left: auto;
  margin-right: 8px;
  cursor: pointer;
}

.cuki-checkbox-label input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.cuki-custom-checkbox {
  width: 16px;
  height: 16px;
  border: 2px solid #ccc;
  border-radius: 3px;
  background: white;
  display: inline-block;
  position: relative;
  transition: all 0.2s ease;
}

.cuki-checkbox-label input:disabled + .cuki-custom-checkbox {
  opacity: 0.5;
  cursor: not-allowed;
}

.cuki-checkbox-label input:checked + .cuki-custom-checkbox {
  background: #007BFF;
  border-color: #007BFF;
}

.cuki-checkbox-label input:checked + .cuki-custom-checkbox::after {
  content: '✓';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: white;
  font-size: 12px;
  font-weight: bold;
}



/* Стрелка — только кнопка реагирует на hover */
.cuki-arrow-btn {
  appearance: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
}

.cuki-arrow-icon {
  display: inline-block;
  width: 12px;
  height: 12px;
  font-size: 0;
  line-height: 0;
}

.cuki-arrow-icon::after {
  content: '\003E'; /* символ > */
  font-size: 18px;
  font-weight: 300;
  color: #007BFF;
  display: block;
  transition: transform 0.3s ease;
}

.cuki-arrow-btn[aria-expanded="true"] .cuki-arrow-icon::after {
  transform: rotate(90deg);
}

.cuki-section p {
  margin: 0 0 10px 0;
  font-size: 14px;
  color: #667;
}

.cuki-cookie-list {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  margin-top: 5px;
  padding-left: 5px;
  border-left: 1px solid #eee;
}

.cuki-cookie-list.expanded {
  max-height: 300px;
}

.cuki-cookie-item {
  font-size: 13px;
  margin: 6px 0;
  color: #667;
  padding: 4px 0;
  border-bottom: 1px solid #f0f0f0;
}

.cuki-modal-footer {
  padding: 15px 25px;
  border-top: 1px solid #eee;
  background: rgba(255, 255, 255, 0.95);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.cuki-privacy-link,
.cuki-cookie-link,
.cuki-save-button {
  color: #007BFF;
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
}

.cuki-privacy-link:hover,
.cuki-cookie-link:hover,
.cuki-save-button:hover {
  text-decoration: underline;
}

@media (max-width: 768px) {
   
  .cuki-text-block {
    padding-left: 20px;
  }
  .cuki-language-button {
    margin-left: 20px;
  }
  .cuki-action-button {
    margin: 0 8px;
    font-size: 14px;
  }
  #cuki-modal {
    width: calc(100% - 40px);
  }
}

@media (max-width:767px) and (orientation:portrait) {
    #cuki-notice {
    height: 200px;
  }
   .cuki-modal-footer {
    height: 90px;
      /*  padding: 15px 5px; */
  }
   .cuki-modal-footer a {
    /* font-size: 12px; */
       text-align: center;
  }
 }

/* === ИСПРАВЛЕНИЕ МОДАЛЬНОГО ОКНА ДЛЯ ЛАНДШАФТНЫХ ТЕЛЕФОНОВ === */
@media (max-width: 767px) and (orientation: landscape) {
  #cuki-modal {
    width: 95vw;
    max-height: 85vh;
    margin: 0 auto;
  }

  .cuki-modal-content {
    padding: 0 15px;
    max-height: calc(85vh - 120px); /* оставляет место для header + footer */
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  .cuki-modal-header h3 {
    font-size: 18px;
  }

  .cuki-section h4 {
    font-size: 15px;
  }

  .cuki-section p {
    font-size: 13px;
  }

  .cuki-cookie-item {
    font-size: 12px;
  }

  .cuki-modal-footer {
    padding: 10px 15px;
   
    gap: 10px;
    align-items: stretch;
  }

  .cuki-modal-footer a,
  .cuki-modal-footer .cuki-save-button {
    text-align: center;
  }
}
    