/* Golden Volunteer — styles for favorites + hours-log entry points.
   Kept separate from the built stylesheet so site updates stay clean. */

:root {
  --gv-green: #1d3b2a;
  --gv-gold: #c9a227;
  --gv-cream: #faf6ec;
}

/* Bookmark button on each listing card */
.opportunity-card .card-top {
  position: relative;
}
.gv-fav-btn {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: 1.5px solid rgba(29, 59, 42, 0.25);
  background: rgba(255, 255, 255, 0.75);
  color: var(--gv-green);
  cursor: pointer;
  padding: 0;
  flex: none;
}
.gv-fav-btn:hover {
  border-color: var(--gv-gold);
  color: #8a6d1c;
}
.gv-fav-btn.is-saved {
  background: var(--gv-gold);
  border-color: var(--gv-gold);
  color: #fff;
}
.gv-fav-btn:focus-visible {
  outline: 2px solid var(--gv-gold);
  outline-offset: 2px;
}

/* Favorites filter toggle next to the search bar */
.gv-fav-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  padding: 9px 16px;
  border-radius: 999px;
  border: 1.5px solid rgba(29, 59, 42, 0.3);
  background: #fff;
  color: var(--gv-green);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
}
.gv-fav-toggle:hover {
  border-color: var(--gv-gold);
}
.gv-fav-toggle.is-active {
  background: var(--gv-green);
  border-color: var(--gv-green);
  color: #fff;
}
.gv-fav-toggle:focus-visible {
  outline: 2px solid var(--gv-gold);
  outline-offset: 2px;
}

.gv-fav-empty {
  text-align: center;
  padding: 28px 18px;
  margin: 18px auto;
  max-width: 560px;
  border: 1.5px dashed rgba(29, 59, 42, 0.35);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.6);
  color: var(--gv-green);
}
.gv-fav-empty p {
  margin: 6px 0;
}

/* ---- Morphing hamburger -> X (mobile nav) ---- */
.gv-burger { display: none; }
@media (width<=900px) {
  .icon-button.gv-replaced { display: none !important; }
  .gv-burger {
    display: grid; place-items: center;
    width: 42px; height: 42px; border-radius: 50%;
    background: var(--sage-100, #eef3e9); color: var(--pine-950, #18251b);
    border: 0; cursor: pointer; padding: 0; flex: none; position: relative;
  }
  .gv-burger span {
    position: absolute; left: 12px; right: 12px; height: 2px;
    background: currentColor; border-radius: 2px;
    transition: transform .32s cubic-bezier(.4,0,.2,1), opacity .22s ease;
  }
  .gv-burger span:nth-child(1) { transform: translateY(-6px); }
  .gv-burger span:nth-child(2) { transform: translateY(0); }
  .gv-burger span:nth-child(3) { transform: translateY(6px); }
  .gv-burger.is-open span:nth-child(1) { transform: translateY(0) rotate(45deg); }
  .gv-burger.is-open span:nth-child(2) { opacity: 0; }
  .gv-burger.is-open span:nth-child(3) { transform: translateY(0) rotate(-45deg); }
  .gv-burger:focus-visible { outline: 2px solid var(--gv-gold); outline-offset: 2px; }
}
/* "Log Hours" button in the site nav — intentionally stands out */
#site-nav .gv-log-hours-btn {
  display: inline-block;
  padding: 9px 20px;
  border-radius: 999px;
  background: var(--gv-gold);
  color: #1d2b22;
  font-weight: 700;
  text-decoration: none;
  border: none;
  white-space: nowrap;
}
#site-nav .gv-log-hours-btn:hover {
  background: #b8941f;
  color: #10160f;
}
@media (max-width: 760px) {
  #site-nav .gv-log-hours-btn {
    margin-top: 6px;
  }
}

/* ---- Smooth mobile menu unfold ---- */
@media (width<=900px) {
  .nav-links {
    display: flex !important;
    flex-direction: column; align-items: stretch; gap: .15rem;
    position: absolute; top: calc(100% + 10px); left: 0; right: 0;
    background: #fffaf0; border: 1px solid #ffffffa6; border-radius: 22px;
    box-shadow: var(--shadow, 0 8px 30px rgba(20,42,30,.15));
    max-height: 0; opacity: 0; overflow: hidden;
    padding-top: 0; padding-bottom: 0;
    transform: translateY(-10px);
    transition: max-height .38s cubic-bezier(.4,0,.2,1), opacity .3s ease,
                transform .38s cubic-bezier(.4,0,.2,1), padding-top .38s ease, padding-bottom .38s ease;
    pointer-events: none;
  }
  .nav-links.is-open {
    max-height: 560px;
    opacity: 1;
    transform: translateY(0);
    padding-top: .45rem; padding-bottom: .45rem;
    pointer-events: auto;
  }
}
