/*-- -------------------------- -->
<---        Cookie Banner        -->
<--- -------------------------- -*/

/* Fixed bar pinned to the bottom of the viewport, same cream/navy/sage
   palette as the rest of the site. Hidden by default -- js/cookie-banner.js
   reveals it (.cs-cookie-visible) after checking localStorage for a
   prior choice, and hides it again once Accept/Necessary Only is
   clicked. */
@media only screen and (min-width: 0rem) {
  #cs-cookie-banner {
    width: 100%;
    position: fixed;
    left: 0;
    bottom: 0;
    z-index: 200;
    background-color: var(--secondaryDark);
    padding: 1.25rem 1.5rem;
    transform: translateY(100%);
    opacity: 0;
    transition: transform 0.4s ease, opacity 0.4s ease;
  }
  #cs-cookie-banner.cs-cookie-visible {
    transform: translateY(0);
    opacity: 1;
  }
  #cs-cookie-banner .cs-cookie-inner {
    width: 100%;
    max-width: 72rem;
    margin: auto;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }
  #cs-cookie-banner .cs-cookie-text {
    font-family: var(--bodyFont);
    font-size: 0.875rem;
    line-height: 1.6em;
    color: var(--cream);
    opacity: 0.9;
    margin: 0;
    max-width: 48rem;
  }
  #cs-cookie-banner .cs-cookie-text a {
    color: var(--cream);
    text-decoration: underline;
    text-underline-offset: 0.2rem;
    opacity: 1;
  }
  #cs-cookie-banner .cs-cookie-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
  }
  #cs-cookie-banner .cs-cookie-btn {
    font-family: var(--bodyFont);
    font-size: 0.8125rem;
    font-weight: 500;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 2.75rem;
    padding: 0 1.5rem;
    border-radius: 999px;
    cursor: pointer;
    white-space: nowrap;
  }
  #cs-cookie-banner .cs-cookie-accept {
    background-color: var(--primary);
    color: #fff;
    border: 1px solid var(--primary);
    transition: background-color 0.3s;
  }
  #cs-cookie-banner .cs-cookie-accept:hover {
    background-color: var(--primaryDark);
  }
  #cs-cookie-banner .cs-cookie-decline {
    background-color: transparent;
    color: var(--cream);
    border: 1px solid rgba(253, 252, 250, 0.4);
    transition: border-color 0.3s;
  }
  #cs-cookie-banner .cs-cookie-decline:hover {
    border-color: var(--cream);
  }
}

/* Desktop - 48rem: text and buttons share one row */
@media only screen and (min-width: 48rem) {
  #cs-cookie-banner .cs-cookie-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
  }
}
