/* guide.css — visual guides (public/guide/). Builds on the tokens in css/camplist.css. */

.guide-body {
  max-width: 1120px;
}
.guide-header .brand {
  display: flex;
  align-items: center;
  text-decoration: none;
  color: var(--logo-color);
  font-family: var(--font-header-wide);
  font-size: clamp(1.5rem, 4vw, 3rem);
  line-height: 1.1;
}
.guide-header .logo {
  height: clamp(40px, 8vw, 64px);
  width: auto;
  margin-inline-end: 0.75rem;
}

.guide-main {
  margin: 0 auto;
}
.guide-hero {
  text-align: center;
  padding: 0.5rem 0 1.5rem;
}
.guide-hero h1 {
  margin-bottom: 0.25rem;
}
.lead {
  color: var(--muted);
  font-size: 1.1rem;
  margin: 0 auto 1rem;
  max-width: 48ch;
}

/* Pictograms */
.ico {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  vertical-align: -0.25em;
}
.ico.inline {
  width: 1em;
  height: 1em;
  vertical-align: -0.15em;
}
.ico.big {
  width: 2.5rem;
  height: 2.5rem;
  color: var(--accent);
}
.ico.hero {
  width: 3.5rem;
  height: 3.5rem;
  color: var(--accent);
}
.ico.mark {
  width: 1.15em;
  height: 1.15em;
  color: var(--accent);
}
.ico.permit {
  color: #b7410e;
}

/* The three-tile summary and the section chips */
.quick {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin: 1rem auto 1.25rem;
  max-width: 720px;
}
.quick-tile {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem 0.5rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}
.quick-no,
.step-no,
.num {
  display: inline-grid;
  place-items: center;
  width: 1.7em;
  height: 1.7em;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  font-weight: 700;
  font-family: var(--font);
  font-size: 0.95rem;
  line-height: 1;
  flex: none;
}
.toc {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}
.toc a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}
.toc a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

/* Step groups */
.group {
  margin: 1.5rem 0 2rem;
}
.group > h2,
.catalogue-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-header);
  font-size: clamp(1.25rem, 3vw, 1.6rem);
  border-bottom: 1px solid var(--border);
  padding-bottom: 0.4rem;
  margin-bottom: 1rem;
  color: var(--logo-color);
}
.count {
  font-family: var(--font);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--muted);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.1rem 0.55rem;
  margin-inline-start: 0.25rem;
}
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
.step {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  min-width: 0;
}
.step h3 {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0 0 0.75rem;
  font-family: var(--font-header);
  font-size: 1.2rem;
}
/* Dialog- and panel-sized pictures: picture on one side, numbered notes on the other */
.step.narrow {
  display: grid;
  grid-template-columns: minmax(0, 460px) 1fr;
  grid-auto-rows: max-content;
  column-gap: 1.25rem;
  align-items: start;
}
.step.narrow h3 {
  grid-column: 1 / -1;
}
.step.narrow .shot {
  grid-column: 1;
  grid-row: 2 / span 4;
}
.step.narrow .legend,
.step.narrow .hint,
.step.narrow .step-link {
  grid-column: 2;
}
.step.narrow .legend {
  grid-template-columns: 1fr;
  margin-top: 0;
}

/* Picture with numbered boxes */
.shot {
  position: relative;
  margin: 0;
}
.shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: #fff;
}
.shot .hl {
  position: absolute;
  border: 2px solid var(--accent);
  border-radius: 6px;
  box-shadow:
    0 0 0 2px rgba(255, 255, 255, 0.85),
    0 0 0 4px rgba(47, 133, 90, 0.25);
  pointer-events: none;
}
.shot .num {
  position: absolute;
  transform: translate(-55%, -55%);
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.35);
  font-size: clamp(0.75rem, 1.6vw, 1rem);
}
.legend {
  list-style: none;
  margin: 0.75rem 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 0.4rem 0.75rem;
}
.legend li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.95rem;
}
.hint {
  margin: 0.6rem 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}
.step-link {
  margin: 0.6rem 0 0;
  font-weight: 600;
}
.to-top {
  text-align: center;
  margin: 1rem 0 2rem;
}

/* Fact tiles */
.facts {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 0.5rem;
  margin: 0.75rem 0;
}
.fact {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0.5rem 0.4rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  text-align: center;
}
.fact .ico {
  color: var(--accent);
  width: 1.4rem;
  height: 1.4rem;
}
.fact-label {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
}
.fact-value {
  font-weight: 700;
}

/* Template catalogue */
.tcards {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1rem;
}
.tcard {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  display: flex;
  flex-direction: column;
}
.tcard-main {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  color: inherit;
  text-decoration: none;
}
.tcard-title {
  font-family: var(--font-header);
  font-size: 1.15rem;
  color: var(--logo-color);
}
.tcard-main:hover .tcard-title {
  color: var(--accent);
}
.tcard-tagline {
  color: var(--muted);
  font-size: 0.95rem;
}
.tcard .facts {
  grid-template-columns: repeat(2, 1fr);
  margin-top: auto;
}
.tcard-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin: 0.5rem 0 0;
}

/* One template */
.crumbs {
  margin: 0 0 0.5rem;
}
.crumbs a {
  color: var(--accent);
}
.template-hero .facts {
  max-width: 760px;
  margin: 0.75rem auto;
}
.template-hero .description {
  max-width: 70ch;
  margin: 1rem auto 0;
  text-align: start;
}
.cta {
  display: flex;
  justify-content: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 1rem 0 0;
}
.considerations {
  margin-inline-start: 1.2rem;
  display: grid;
  gap: 0.35rem;
}
.legend-keys {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin: 0 0 0.75rem;
  color: var(--muted);
}
.tsections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1rem;
  align-items: start;
}
.tsection {
  padding: 0.9rem 1rem;
  margin: 0;
}
.tsection h3 {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-header);
  font-size: 1.1rem;
  margin: 0 0 0.5rem;
  color: var(--logo-color);
}
.titems {
  list-style: none;
  display: grid;
  gap: 0.35rem;
}
.titems li {
  display: flex;
  gap: 0.5rem;
  align-items: flex-start;
  line-height: 1.35;
}
.titems .ico.mark {
  margin-top: 0.15em;
}
.item-optional .item-text {
  color: var(--muted);
}
.item-note {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
}
.sources ul {
  margin-inline-start: 1.2rem;
  display: grid;
  gap: 0.3rem;
}

/* The two labelled placements (same rules as the app: labelled, no pop-ups, no sticky units) */
.guide-main .ad-slot-inline {
  margin: 1.5rem auto;
  max-width: 970px;
}
.guide-main .ad-slot-inline .sponsor-card {
  margin-top: 0;
}

.guide-footer {
  text-align: center;
  color: var(--muted);
  margin: 2rem 0 1rem;
}

@media (max-width: 600px) {
  .guide-header .header-actions {
    flex-basis: 100%;
  }
  .guide-header .header-actions .button-link {
    flex: 1 1 auto;
    justify-content: center;
    padding-inline: 0.5rem;
  }
  .quick {
    grid-template-columns: 1fr;
  }
  .quick-tile {
    flex-direction: row;
    justify-content: flex-start;
    padding: 0.6rem 0.9rem;
  }
  .tsections {
    grid-template-columns: 1fr;
  }
  .legend {
    grid-template-columns: 1fr;
  }
  .step.narrow {
    grid-template-columns: 1fr;
  }
  .step.narrow .shot {
    grid-row: auto;
  }
  .step.narrow .legend,
  .step.narrow .hint,
  .step.narrow .step-link {
    grid-column: 1;
  }
  .step.narrow .legend {
    margin-top: 0.75rem;
  }
}

@media print {
  .guide-header .header-actions,
  .toc,
  .to-top,
  .cta,
  .tcard-actions {
    display: none;
  }
  .step,
  .tcard,
  .tsection {
    break-inside: avoid;
  }
}
