/* =========================================================
  Cookie Consent Banner (Full)
  - Scoped under #cookie-consent to avoid collisions
  - Common design across all WP installs
  - Responsive (stack on mobile)
========================================================= */

#cookie-consent {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 99999;
  padding: 0;
  pointer-events: none; /* allow clicks only on inner */
}

/* Outer width container */
#cookie-consent .cc__inner {
  pointer-events: auto;
  margin: 0 auto;

  background: #E8EEF1;
  color: #333;

  padding: 25px 30px;

  display: flex;
  gap: 30px;
  align-items: center;
  justify-content: space-between;
}

/* Make sure weird global CSS doesn't mess too much */
#cookie-consent,
#cookie-consent * {
  box-sizing: border-box;
}

/* Text area */
#cookie-consent .cc__text {
  min-width: 0; /* for ellipsis/wrap */
}

#cookie-consent .cc__title {
  margin: 0 0 6px 0;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.3;
  letter-spacing: 0.02em;
}

#cookie-consent .cc__desc {
  margin: 0;
  font-size: 13px;
  line-height: 1.7;
  opacity: 0.92;
  word-break: break-word;
}

/* Links row */
#cookie-consent .cc__links {
  margin: 10px 0 0 0;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* Link style */
#cookie-consent .cc__link {
  color: #fff;
  font-size: 13px;
  line-height: 1.4;
  opacity: 0.9;
  text-decoration: underline;
  text-underline-offset: 2px;
}

#cookie-consent .cc__link:hover,
#cookie-consent .cc__link:focus-visible {
  opacity: 1;
}

/* "設定を変更" as button-link */
#cookie-consent .cc__linkbtn {
  appearance: none;
  -webkit-appearance: none;

  border: none;
  background: transparent;
  padding: 0;
  margin: 0;

  color: #fff;
  font-size: 13px;
  line-height: 1.4;
  opacity: 0.9;

  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 2px;
}

#cookie-consent .cc__linkbtn:hover,
#cookie-consent .cc__linkbtn:focus-visible {
  opacity: 1;
}

/* Actions */
#cookie-consent .cc__actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  flex-shrink: 0;
  align-items: center;
  justify-content: flex-end;
}

/* Base button reset-ish */
#cookie-consent .cc__btn {
  appearance: none;
  -webkit-appearance: none;

  border: 1px solid rgba(255, 255, 255, 0.35);
  background: transparent;
  color: #fff;

  padding: 15px 60px;

  cursor: pointer;
  font-weight: 700;
  font-size: 13px;
  line-height: 1;

  transition: transform 0.05s ease, opacity 0.15s ease, background 0.15s ease, border-color 0.15s ease;
}

/* Avoid global button font overrides */
#cookie-consent .cc__btn,
#cookie-consent .cc__linkbtn {
  /* font: inherit; */
}

/* Hover / focus */
#cookie-consent .cc__btn:hover {
  opacity: 0.95;
}

#cookie-consent .cc__btn:active {
  transform: translateY(1px);
}

#cookie-consent .cc__btn:focus-visible,
#cookie-consent .cc__link:focus-visible,
#cookie-consent .cc__linkbtn:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.75);
  outline-offset: 3px;
}

/* Deny */
#cookie-consent .cc__btn--deny {
  background: #fff;
  color: #111;
  border-color: #333;
}

/* Accept */
#cookie-consent .cc__btn--accept {
  background: #414547;
  border-color: #414547;
}

/* Accept hover tweak */
#cookie-consent .cc__btn--accept:hover {
  opacity: 0.98;
}

/* Optional: small text sizing on very large fonts */
#cookie-consent .cc__desc small {
  font-size: 12px;
  opacity: 0.9;
}

/* Responsive */
@media (max-width: 767px) {

  #cookie-consent .cc__inner {
    padding: 14px 14px;
    flex-direction: column;
    align-items: stretch;
    gap: 12px;
  }

  #cookie-consent .cc__actions {
    justify-content: flex-end;
  }

  #cookie-consent .cc__btn {
    width: 100%;
    justify-content: center;
    padding: 12px 14px;
  }

  #cookie-consent .cc__actions {
    flex-direction: row-reverse; /* accept on top? change if desired */
    gap: 10px;
  }

  #cookie-consent .cc__links {
    margin-top: 8px;
  }
}

/* Extra small */
@media (max-width: 360px) {
  #cookie-consent .cc__title {
    font-size: 14px;
  }
  #cookie-consent .cc__desc,
  #cookie-consent .cc__link,
  #cookie-consent .cc__linkbtn {
    font-size: 12px;
  }
}

/* Print: hide */
@media print {
  #cookie-consent {
    display: none !important;
  }
}
