/* ============================================================
   An Alphabet Of Hull — shared stylesheet
   Mid-brightness green theme: lighter green boxes for every
   link, a dark green outline, an arty italic display face,
   and everything centred.
   ============================================================ */

:root {
  --ink: #16281a;
  --bg-green: #5da860;
  --topbar-green: #22391f;
  --topbar-line: #a9d79f;

  --tile-fill: #d9f0d1;
  --tile-border: #234420;
  --tile-hover: #c3e6b9;

  --panel: #f4faf1;
  --panel-border: #bfe0b8;

  --cream: #fbfff6;

  --font-display: "Trebuchet MS", "Lucida Grande", Verdana, sans-serif;
  --font-body: "Trebuchet MS", "Lucida Grande", Verdana, Arial, sans-serif;

  --bar-height: 64px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg-green);
  color: var(--ink);
  font-family: var(--font-body);
  line-height: 1.6;
  padding-top: var(--bar-height);
  text-align: center;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
}

/* ---------------- Top bar ---------------- */

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--bar-height);
  background: var(--topbar-green);
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 1.5rem;
  z-index: 100;
  border-bottom: 3px solid var(--topbar-line);
  gap: 2rem;
}

.topbar-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-decoration: none;
  color: var(--cream);
  white-space: nowrap;
}

.nav-select {
  font-family: var(--font-body);
  font-size: 0.95rem;
  background: var(--topbar-green);
  color: var(--cream);
  border: 2px solid var(--topbar-line);
  border-radius: 8px;
  padding: 0.45rem 0.8rem;
  cursor: pointer;
}

.nav-select:focus-visible,
a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
}

/* ---------------- Layout shell ---------------- */

.wrap {
  max-width: 1000px;
  margin: 0 auto;
  padding: 3rem 1.5rem 5rem;
  text-align: center;
}

/* ---------------- Home hero ---------------- */

.hero {
  text-align: center;
  padding-bottom: 1.5rem;
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.6rem, 6vw, 4.6rem);
  margin: 0 0 0.5rem;
  font-weight: 600;
}

.hero h1 span {
  -webkit-text-stroke: 2px #ffffff;
  paint-order: stroke fill;
  text-shadow: 3px 3px 0 rgba(0, 0, 0, 0.2);
}

.hero .subtitle {
  font-size: 1.1rem;
  color: var(--cream);
  opacity: 0.9;
  margin: 0;
}

/* ---------------- Editable text block ---------------- */

.intro-text {
  max-width: 60ch;
  margin: 2.5rem auto;
  font-size: 1.08rem;
  color: var(--ink);
  text-align: center;
  background: var(--panel);
  border: 2px solid var(--panel-border);
  border-radius: 14px;
  padding: 1.75rem 2rem;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.08);
}

.intro-text p {
  margin: 0 0 1rem;
}

.intro-text p:last-child {
  margin-bottom: 0;
}

/* ---------------- Image slot ---------------- */

.image-slot {
  max-width: 680px;
  margin: 2.5rem auto;
  border: 2px solid var(--panel-border);
  border-radius: 14px;
  background: var(--panel);
  padding: 0.6rem;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.image-slot img {
  width: 100%;
  height: auto;
  border-radius: 8px;
}

.image-fallback {
  display: none;
  align-items: center;
  justify-content: center;
  height: 260px;
  border-radius: 8px;
  background: repeating-linear-gradient(
    135deg,
    #e3f2df,
    #e3f2df 10px,
    #d5e9cf 10px,
    #d5e9cf 20px
  );
  color: var(--tile-border);
  font-family: var(--font-body);
  font-size: 0.95rem;
  text-align: center;
  padding: 1rem;
}

/* ---------------- Map window ---------------- */

.map-slot {
  max-width: 860px;
  margin: 2.5rem auto;
  border: 2px solid var(--panel-border);
  border-radius: 14px;
  background: var(--panel);
  padding: 0.6rem;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.08);
  overflow: hidden;
}

.map-slot iframe {
  display: block;
  width: 100%;
  height: clamp(320px, 55vh, 480px);
  border: 0;
  border-radius: 8px;
}

/* ---------------- Divider ---------------- */

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  margin: 3rem auto;
  max-width: 300px;
}

.divider span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--tile-border);
}

.divider::before,
.divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--panel-border);
}

/* ---------------- Letter grid (boxed links) ---------------- */

.letter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 1.1rem;
  justify-content: center;
}

.letter-tile,
.letter-tile.v1,
.letter-tile.v2,
.letter-tile.v3 {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1 / 1;
  text-decoration: none;
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 2.75rem);
  font-weight: 600;
  background: var(--tile-fill);
  border: 4px solid var(--tile-border);
  border-radius: 16px;
  box-shadow: 0 4px 0 var(--tile-border);
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
  -webkit-text-stroke: 1.5px #ffffff;
  paint-order: stroke fill;
  text-shadow: 2px 2px 0 rgba(0, 0, 0, 0.15);
}

.letter-tile:hover,
.letter-tile:focus-visible {
  background: var(--tile-hover);
  transform: translateY(-3px);
  box-shadow: 0 7px 0 var(--tile-border);
}

.letter-tile:active {
  transform: translateY(0);
  box-shadow: 0 2px 0 var(--tile-border);
}

/* ---------------- Letter page ---------------- */

.letter-hero {
  text-align: center;
  padding-bottom: 1rem;
}

.letter-hero .big-letter {
  font-family: var(--font-display);
  font-size: clamp(5rem, 18vw, 9rem);
  line-height: 1;
  margin: 0;
  color: var(--letter-color, hsl(var(--hue, 0), 78%, 36%));
  font-weight: 600;
  -webkit-text-stroke: 3px #ffffff;
  paint-order: stroke fill;
  text-shadow: 4px 4px 0 rgba(0, 0, 0, 0.18);
}

.letter-hero .is-for {
  font-size: 1.2rem;
  color: hsl(var(--hue, 0), 60%, 30%);
  margin: 0.75rem 0 0;
  text-shadow: 0 0 6px rgba(255, 255, 255, 0.55);
}

.letter-hero .is-for .fill {
  border-bottom: 2px dashed hsl(var(--hue, 0), 60%, 30%);
}

.letter-pager {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 1rem;
  max-width: 720px;
  margin: 3rem auto 0;
  padding-top: 1.75rem;
  border-top: 2px solid var(--panel-border);
  font-size: 0.95rem;
  text-align: center;
}

.letter-pager > div,
.letter-pager > a {
  margin: 0;
}

.letter-pager a {
  text-decoration: none;
  color: var(--ink);
  background: var(--tile-fill);
  border: 2px solid var(--tile-border);
  border-radius: 10px;
  padding: 0.6rem 1.2rem;
  display: inline-block;
  transition: background 0.12s ease, transform 0.12s ease;
}

.letter-pager a:hover {
  background: var(--tile-hover);
  transform: translateY(-2px);
}

.letter-pager .home-link {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.05rem;
}

/* ---------------- Responsive ---------------- */

@media (max-width: 760px) {
  .letter-grid {
    grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  }
}

@media (max-width: 480px) {
  .topbar {
    padding: 0 1rem;
    gap: 1rem;
  }
  .topbar-title {
    font-size: 1.05rem;
  }
  .letter-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 0.7rem;
  }
  .letter-pager {
    flex-direction: column;
    gap: 0.75rem;
  }
}

/* ---------------- Where to find it ---------------- */

.where {
  max-width: 60ch;
  margin: 2.5rem auto;
  background: var(--panel);
  border: 2px solid var(--panel-border);
  border-radius: 14px;
  padding: 1.5rem 2rem;
  box-shadow: 0 4px 0 rgba(0, 0, 0, 0.08);
  text-align: center;
}

.where h2 {
  font-size: 1.2rem;
  margin: 0 0 1rem;
}

.where .venue + .venue {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 2px solid var(--panel-border);
}

.where .label {
  margin: 0 0 .25rem;
  font-size: .9rem;
  color: var(--tile-border);
  font-weight: 600;
}

.where .place {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 600;
}

.where address {
  font-style: normal;
  margin: .5rem 0;
}

.where .hours {
  margin: .5rem 0;
  font-size: .95rem;
}

.where .soon {
  margin: 0;
}

.where .links {
  margin: .75rem 0 0;
}

.where .links a {
  display: inline-block;
  margin: .3rem;
  padding: .5rem 1rem;
  background: var(--tile-fill);
  border: 2px solid var(--tile-border);
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
  transition: background .12s ease, transform .12s ease;
}

.where .links a:hover {
  background: var(--tile-hover);
  transform: translateY(-2px);
}

/* ---------------- Credits and long stories ---------------- */

.letter-hero .made-by {
  margin: .6rem 0 0;
  font-size: 1.05rem;
  color: var(--cream);
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.story h3 {
  font-size: 1.05rem;
  margin: 1.5rem 0 .5rem;
}

.story ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.story li {
  margin: .5rem 0;
  font-size: .95rem;
}

/* ---------------- Photos and story links ---------------- */

.image-slot img {
  width: auto;
  max-width: 100%;
  max-height: 85vh;
  margin: 0 auto;
}

.story h3:first-child {
  margin-top: 0;
}

.story a {
  color: var(--ink);
  text-decoration: underline;
}

/* ---------------- About page and link ---------------- */

.about-row {
  margin: 2rem 0 0;
}

.about-link {
  display: inline-block;
  padding: .75rem 1.6rem;
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--ink);
  text-decoration: none;
  background: var(--tile-fill);
  border: 3px solid var(--tile-border);
  border-radius: 12px;
  box-shadow: 0 4px 0 var(--tile-border);
  transition: transform .12s ease, box-shadow .12s ease, background .12s ease;
}

.about-link:hover,
.about-link:focus-visible {
  background: var(--tile-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 0 var(--tile-border);
}

.story .thanks li {
  font-size: 1rem;
}
