/* YouTube Consent Blocker — placeholder styles */

.ytcb-placeholder {
  position: relative;
  display: block;
  overflow: hidden;
  background: #0d0d0d;
  /* Maintain 16:9 aspect ratio via padding trick */
  aspect-ratio: 16 / 9;
  max-width: 100%;
}

/* Fallback for browsers without aspect-ratio support */
@supports not (aspect-ratio: 16/9) {
  .ytcb-placeholder::before {
    content: '';
    display: block;
    padding-top: 56.25%; /* 9/16 */
  }
}

.ytcb-thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  filter: blur(2px) brightness(0.45);
  transform: scale(1.04); /* hide blur edges */
}

.ytcb-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.25rem;
  text-align: center;
  box-sizing: border-box;
}

/* No thumbnail — plain dark background overlay */
.ytcb-placeholder:not(:has(.ytcb-thumb)) .ytcb-overlay {
  background: rgba(0, 0, 0, 0.82);
}

.ytcb-title {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
}

.ytcb-msg {
  margin: 0 0 1.1rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.85);
  max-width: 30rem;
  line-height: 1.5;
}

/*
 * Buttons — hard reset first so browser defaults and wp-element-button don't
 * bleed in. All visual styling (colour, border, radius, padding, font) is
 * intentionally left to the theme classes set in Settings › YouTube Consent.
 */
.ytcb-btn {
  /* Reset browser <button> defaults */
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  font: inherit;
  color: inherit;
  line-height: inherit;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: none;

  /* Reset wp-element-button border override */
  outline: none;

  /* Layout only — gap is handled by .ytcb-btn-wrap */
  display: inline-block;
  cursor: pointer;
  white-space: nowrap;

  /* Theme classes take over from here */
}

/* Button row — flex so gap drives the spacing between buttons */
.ytcb-btn-wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: var(--ytcb-btn-gap, 8px);
}

/* Responsive: stack buttons on small screens */
@media (max-width: 400px) {
  .ytcb-title {
    font-size: 0.95rem;
  }

  .ytcb-msg {
    font-size: 0.8rem;
  }

  .ytcb-btn-wrap {
    flex-direction: column;
    align-items: stretch;
  }

  .ytcb-btn {
    display: block;
    width: 100%;
    text-align: center;
  }
}
