/* Estilos propios de la guía de jugador. Reutiliza las variables de
   style.css (cargado antes que este archivo). */

body {
  max-width: 860px;
  margin: 0 auto;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 18px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 13px;
  transition: color 0.15s ease;
}

.back-link:hover {
  color: var(--amber);
}

.guide-toc {
  position: sticky;
  top: 12px;
  z-index: 5;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 18px 0 32px;
  padding: 10px;
  background: rgba(26, 43, 32, 0.92);
  backdrop-filter: blur(6px);
  border: 1px solid var(--panel-border);
  border-radius: 999px;
}

.guide-toc a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 12.5px;
  font-weight: 600;
  padding: 6px 13px;
  border-radius: 999px;
  transition: color 0.15s ease, background-color 0.15s ease;
  white-space: nowrap;
}

.guide-toc a:hover {
  color: var(--text);
  background: var(--panel-bg-elevated);
}

.guide-section {
  max-width: 760px;
  margin: 0 0 52px;
  scroll-margin-top: 70px;
}

.guide-section h2 {
  font-family: var(--font-display);
  font-size: 23px;
  font-weight: 600;
  padding-bottom: 10px;
  margin: 0 0 18px;
  position: relative;
}

.guide-section h2::after {
  content: "";
  display: block;
  width: 56px;
  height: 3px;
  background: var(--amber);
  border-radius: 2px;
  margin-top: 10px;
}

.guide-section h3 {
  font-family: var(--font-display);
  font-size: 16px;
  color: var(--amber);
  margin: 26px 0 10px;
}

.guide-section h4 {
  margin: 0 0 4px;
  font-size: 14.5px;
}

.guide-section p {
  color: var(--text);
  margin: 0 0 12px;
}

.guide-section p.muted {
  color: var(--text-muted);
  font-size: 13.5px;
}

.guide-section ul,
.guide-section ol {
  margin: 0 0 12px;
  padding-left: 22px;
}

.guide-section li {
  margin-bottom: 6px;
}

/* ---- Edificios: rejilla de tarjetas -------------------------------------- */

.building-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 12px;
  margin: 0 0 16px;
}

.building-card {
  background: var(--panel-bg);
  border: 1px solid var(--panel-border-soft);
  border-radius: var(--radius);
  padding: 14px;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.building-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}

.building-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
}

.building-icon {
  font-size: 22px;
}

.building-cost {
  font-size: 12px;
  font-weight: 700;
  color: var(--bg);
  background: var(--amber);
  border-radius: 999px;
  padding: 2px 9px;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.building-card h4 {
  font-family: var(--font-display);
  font-weight: 600;
}

.building-card p {
  margin: 0;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ---- Estados: chips -------------------------------------------------------- */

.state-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 6px 10px;
  margin: 0 0 16px;
}

.state-grid-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  padding: 5px 10px;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border-soft);
  border-radius: 7px;
}

.state-grid-item .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 5px currentColor;
}

/* ---- Recuadros destacados --------------------------------------------------- */

.callout {
  position: relative;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  padding: 12px 16px 12px 42px;
  margin: 0 0 16px;
  font-size: 13.5px;
}

.callout::before {
  content: "💡";
  position: absolute;
  left: 12px;
  top: 12px;
  font-size: 15px;
}

.callout.warn {
  border-left-color: var(--rust);
}

.callout.warn::before {
  content: "⚠️";
}

/* ---- FAQ: <details> nativos -------------------------------------------------- */

.faq-item {
  margin-bottom: 10px;
  background: var(--panel-bg);
  border: 1px solid var(--panel-border-soft);
  border-radius: var(--radius-sm);
  padding: 4px 16px;
}

.faq-item[open] {
  border-color: var(--panel-border);
}

.faq-item .question {
  cursor: pointer;
  list-style: none;
  font-weight: 600;
  padding: 12px 0;
  display: flex;
  align-items: center;
  gap: 10px;
}

.faq-item .question::-webkit-details-marker {
  display: none;
}

.faq-item .question::before {
  content: "+";
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  color: var(--amber);
  border: 1px solid var(--panel-border);
  border-radius: 50%;
  transition: transform 0.15s ease, background-color 0.15s ease;
}

.faq-item[open] .question::before {
  content: "–";
  background: var(--amber-dim);
}

.faq-item .answer {
  color: var(--text-muted);
  font-size: 13.5px;
  margin: 0 0 14px 28px;
}
