/* Share row — Facebook, Instagram, email, link.
   Layered on top of the compiled Astro bundle; uses the site's own tokens only.
   Two shapes: .share (quiet strip, sits in the footer) and .share--panel
   (a bordered call to action for the end of a page). */

.share {
  display: grid;
  gap: 0.9rem;
  justify-items: start;
}

.share__title {
  font-family: var(--label);
  text-transform: uppercase;
  letter-spacing: 0.2em;
  font-size: 0.78rem;
  color: var(--muted);
  margin: 0;
}

/* the native-share button ships hidden; display would otherwise beat [hidden] */
.share__btn[hidden] { display: none; }

/* a full-width band to sit the panel in at the foot of a page */
.share-band {
  padding-block: clamp(2.5rem, 6vw, 4rem) clamp(3rem, 7vw, 5rem);
}

.share__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.share__btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  font-family: var(--label);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.8rem;
  font-weight: 500;
  line-height: 1;
  padding: 0.68rem 1.15rem;
  border: 1px solid var(--ink-line);
  border-radius: 999px;
  color: var(--bone-dim);
  background: transparent;
  text-decoration: none;
  cursor: pointer;
  transition:
    color 0.3s var(--ease),
    border-color 0.3s var(--ease),
    background-color 0.3s var(--ease),
    transform 0.3s var(--ease);
}

.share__btn svg {
  width: 1.05em;
  height: 1.05em;
  fill: currentColor;
  flex: none;
}

.share__btn:hover {
  color: var(--brass-hi);
  border-color: var(--brass-lo);
  background: rgba(200, 162, 74, 0.08);
}

.share__btn:focus-visible {
  outline: 2px solid var(--brass-hi);
  outline-offset: 3px;
}

.share__btn:active { transform: translateY(1px); }

/* a hint of each network's own colour on hover, kept low so the page stays warm */
.share__btn--fb:hover {
  color: #9dc0f5;
  border-color: rgba(24, 119, 242, 0.55);
  background: rgba(24, 119, 242, 0.12);
}

.share__btn--ig:hover {
  color: #f0aac5;
  border-color: rgba(221, 42, 123, 0.5);
  background: rgba(221, 42, 123, 0.12);
}

/* status line for "link copied" — reserves its own height so nothing jumps */
.share__note {
  margin: 0;
  min-height: 1.2em;
  font-size: 0.82rem;
  color: var(--muted);
  opacity: 0;
  transition: opacity 0.3s var(--ease);
}

.share__note[data-shown="true"] {
  opacity: 1;
  color: var(--brass);
}

/* ---- panel variant: the prominent version, for the foot of a page ---- */

.share--panel {
  width: 100%;
  max-width: 54rem;
  margin-inline: auto;
  justify-items: center;
  text-align: center;
  gap: 1.1rem;
  padding: clamp(2rem, 5vw, 3.25rem) clamp(1.25rem, 4vw, 3rem);
  border: 1px solid var(--ink-line);
  background:
    radial-gradient(ellipse 70% 100% at 50% 0%, rgba(200, 162, 74, 0.07), transparent 70%),
    var(--ink-raise);
  position: relative;
}

/* brass hairline across the top, matching the site's rules */
.share--panel::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 1px;
  background: var(--rule);
}

.share--panel .share__title {
  font-family: var(--display);
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  line-height: 1.25;
  letter-spacing: 0.01em;
  text-transform: none;
  color: var(--bone);
}

.share--panel .share__lede {
  margin: -0.3rem 0 0.3rem;
  max-width: 46ch;
  color: var(--bone-dim);
  font-size: 1.02rem;
  line-height: 1.6;
}

.share--panel /* the native-share button ships hidden; display would otherwise beat [hidden] */
.share__btn[hidden] { display: none; }

/* a full-width band to sit the panel in at the foot of a page */
.share-band {
  padding-block: clamp(2.5rem, 6vw, 4rem) clamp(3rem, 7vw, 5rem);
}

.share__row { justify-content: center; }

.share--panel .share__btn {
  border-color: var(--brass-lo);
  color: var(--brass-hi);
  padding: 0.8rem 1.35rem;
}

/* ---- footer placement ---- */

.footer__share {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  padding-top: 1.75rem;
  border-top: 1px solid var(--ink-line);
}

/* the footer base already draws its own top border; avoid doubling up */
.footer__share + .footer__base {
  margin-top: 1.75rem;
  padding-top: 1.75rem;
}

@media (max-width: 40rem) {
  .share__btn {
    padding: 0.66rem 1rem;
    font-size: 0.76rem;
  }
}
