/* share.css — styling for the share button and fallback popup
   Matches the dark/gold journal aesthetic of rexjacob.com */

/* === Share button (sits in .morenav alongside the back link) === */
.share-btn {
  font-family: "Montserrat", sans-serif;
  font-size: 0.6rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold, #c9a84c);
  background: transparent;
  border: 1px solid var(--gold-border, rgba(201, 168, 76, 0.22));
  padding: 13px 26px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}
.share-btn:hover,
.share-btn:focus {
  background: var(--gold-dim, rgba(201, 168, 76, 0.08));
  border-color: var(--gold, #c9a84c);
  outline: none;
}

/* Two-button layout in .morenav (back + share) */
.morenav {
  gap: 14px;
  flex-wrap: wrap;
}
@media (max-width: 480px) {
  .morenav { flex-direction: column; align-items: center; }
  .morenav a, .share-btn { width: 100%; max-width: 280px; text-align: center; }
}

/* === Desktop fallback popup === */
.share-popup {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-family: "Montserrat", sans-serif;
}
.share-popup.open { display: flex; animation: share-fade 0.18s ease both; }
@keyframes share-fade { from { opacity: 0; } to { opacity: 1; } }

.share-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 4, 2, 0.78);
  backdrop-filter: blur(3px);
  -webkit-backdrop-filter: blur(3px);
}

.share-popup-card {
  position: relative;
  background: linear-gradient(180deg, #1a1408 0%, #0e0c07 100%);
  border: 1px solid rgba(201, 168, 76, 0.28);
  padding: 32px 28px;
  width: 100%;
  max-width: 360px;
  box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
  animation: share-rise 0.22s ease both;
}
@keyframes share-rise {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.share-popup-title {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.45rem;
  font-weight: 400;
  color: #f5efe0;
  text-align: center;
  letter-spacing: 0.01em;
  margin-bottom: 4px;
}

.share-popup-rule {
  width: 60px;
  height: 1px;
  background: linear-gradient(to right, transparent, #c9a84c, transparent);
  margin: 16px auto;
}

.share-option {
  display: block;
  width: 100%;
  font-family: "Montserrat", sans-serif;
  font-size: 0.62rem;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: rgba(245, 239, 224, 0.78);
  background: transparent;
  border: 1px solid rgba(201, 168, 76, 0.18);
  padding: 13px 18px;
  margin: 8px 0;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: all 0.2s ease;
  -webkit-font-smoothing: antialiased;
}
.share-option:hover,
.share-option:focus {
  background: rgba(201, 168, 76, 0.08);
  border-color: #c9a84c;
  color: #f0d080;
  outline: none;
}
.share-option.share-copied {
  background: rgba(201, 168, 76, 0.14);
  color: #f0d080;
  border-color: #c9a84c;
}

.share-close {
  display: block;
  width: 100%;
  font-family: "Montserrat", sans-serif;
  font-size: 0.55rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(245, 239, 224, 0.5);
  background: transparent;
  border: none;
  padding: 10px;
  cursor: pointer;
  margin-top: 4px;
  transition: color 0.2s ease;
}
.share-close:hover { color: #c9a84c; }
