/**
 *  Shared CSS for tombstone pages (cassini, feed, landfill, etc.) created in 2026.
 *  Also styles .btn-back to create a back button in the upper left corner if present:
 *    <button class="btn-back" onclick="history.back()">&#8249;</button>
 */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background-color: #f6f5f3;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100dvh;
  font-family: "Open Sans", "Arial", sans-serif;
  position: relative;
  overflow-y: auto;
}

.btn-back {
  position: fixed;
  top: 1rem;
  left: 1rem;
  width: 2.0rem;
  height: 2.0rem;
  border-radius: 50%;
  background: rgb(33, 33, 33, .3);
  border: 1px solid #666;
  color: #555;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: baseline;
  justify-content: center;
  z-index: 999;
  padding: 0;
  /* To fix Chrome Iphone issue where the canvas was pushed down below the button 
  instead of positioned in upper left full-viewport: buttons have user-agent stylesheet 
  margins that need to be explicitly overridden */
  margin: 0;
  /* Explicit margin override for buttons */
  -webkit-appearance: none;
  /* Remove iOS button styling */
  appearance: none;
}

.btn-back:hover {
  background: #999;
  color: #222;
}


.stage :focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 2px;
}

/* ---------- Stage (centered images) ---------- */
.stage {
  width: 100%;
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}

.content {
  width: min(100%, 720px, calc(82vh * 1244 / 700));
  margin: auto;
}

.content h1,
.content h2,
.content h3 {
  text-align: center;
}

.content h3 {
  margin-bottom: 30px;
}

.intro {
  margin: 0 0 24px;
  line-height: 1.6;
}

.main-image {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  line-height: 0;
}

.main-image a {
  display: block;
}

.main-image img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid #9c9c9c;
  border-radius: 2px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* ---------- Mobile / tablet ---------- */
@media (max-width: 768px) {
  .stage {
    /* clear the fixed back button at the top */
    padding: 4rem 18px 32px;
  }

  .content {
    width: min(100%, 720px);
  }

  .main-image {
    grid-template-columns: 1fr;
  }

  .main-image img {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
  }
}