/* ==========================================================================
   BRICKSPERU — GUÍAS (AEO, oct-2026)
   Layout for the guide pages (/precio-m2-san-isidro-2026/, /comparador-lima-vs-marbella/,
   /que-es-una-inmobiliaria-ai-native/). Loaded after style.css, which provides the tokens,
   the fonts and the site header.
   ========================================================================== */

.guide-main {
  max-width: 46rem;
  margin: 0 auto;
  padding: 2rem 1rem 4rem;
}

@media (min-width: 640px) {
  .guide-main { padding: 3rem 1.5rem 5rem; }
}

.guide-crumbs {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  margin-bottom: 1.5rem;
}

.guide-main .guide-crumbs a { color: var(--color-brand-teal); text-decoration: none; }
.guide-crumbs a:hover { text-decoration: underline; }

.guide-main h1 {
  font-family: var(--font-headline);
  font-weight: 800;
  font-size: 1.9rem;
  line-height: 1.15;
  color: var(--color-text-primary);
  letter-spacing: -0.01em;
  margin-bottom: 0.75rem;
}

@media (min-width: 640px) {
  .guide-main h1 { font-size: 2.5rem; }
}

.guide-main .guide-meta {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--color-text-muted);
  margin-bottom: 1.75rem;
}

.guide-answer {
  background: var(--color-surface-card);
  border: 1px solid rgba(80, 193, 183, 0.25);
  border-left: 3px solid var(--color-brand-teal);
  border-radius: 1rem;
  padding: 1.25rem 1.25rem;
  margin-bottom: 2.5rem;
}

.guide-answer-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-brand-teal);
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.guide-main .guide-answer p {
  font-size: 1.05rem;
  line-height: 1.65;
  color: var(--color-text-primary);
}

.guide-main h2 {
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.35rem;
  line-height: 1.25;
  color: var(--color-text-primary);
  margin: 2.5rem 0 0.85rem;
}

.guide-main h3 {
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 1.05rem;
  color: var(--color-text-primary);
  margin: 1.5rem 0 0.4rem;
}

.guide-main p,
.guide-main li {
  color: var(--color-text-secondary);
  font-size: 0.98rem;
  line-height: 1.7;
}

.guide-main p + p { margin-top: 0.85rem; }

.guide-main ul,
.guide-main ol {
  padding-left: 1.25rem;
  margin: 0.6rem 0 0.9rem;
}

.guide-main li + li { margin-top: 0.35rem; }

.guide-main a { color: var(--color-brand-amber); }
.guide-main a:hover { color: var(--color-brand-amber-light); }

.guide-main strong { color: var(--color-text-primary); font-weight: 600; }

/* Tables scroll inside their own box on phones: the page never scrolls sideways. */
.guide-table-wrap {
  overflow-x: auto;
  margin: 1rem 0 0.5rem;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.85rem;
}

.guide-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}

/* Three-column tables keep a readable width and scroll inside their box. */
.guide-table.guide-table-wide { min-width: 34rem; }

.guide-table th,
.guide-table td {
  text-align: left;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  vertical-align: top;
  color: var(--color-text-secondary);
}

.guide-table th {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-text-muted);
  background: var(--color-surface-dark);
  font-weight: 600;
}

.guide-table tr:last-child td { border-bottom: 0; }

.guide-table td.num {
  font-family: var(--font-mono);
  color: var(--color-text-primary);
  white-space: nowrap;
}

.guide-source {
  font-size: 0.78rem !important;
  color: var(--color-text-muted) !important;
  margin-top: 0.4rem;
}

.guide-note {
  background: rgba(245, 166, 35, 0.07);
  border: 1px solid rgba(245, 166, 35, 0.25);
  border-radius: 0.85rem;
  padding: 1rem 1.1rem;
  margin: 1.25rem 0;
}

.guide-note p { color: var(--color-text-secondary); }

.guide-faq details {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.9rem 0;
}

.guide-faq summary {
  cursor: pointer;
  font-family: var(--font-headline);
  font-weight: 600;
  font-size: 1rem;
  color: var(--color-text-primary);
  list-style: none;
}

.guide-faq summary::-webkit-details-marker { display: none; }
.guide-faq summary::before { content: "+ "; color: var(--color-brand-teal); }
.guide-faq details[open] summary::before { content: "– "; }
.guide-faq details p { margin-top: 0.5rem; }

.guide-cta {
  margin-top: 2.75rem;
  padding: 1.5rem 1.25rem;
  border-radius: 1.1rem;
  background: var(--color-surface-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.guide-cta h2 { margin-top: 0; }

.guide-cta-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1rem;
}

.guide-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.2rem;
  border-radius: 9999px;
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 0.85rem;
  text-decoration: none;
  min-height: 44px;
}

.guide-main a.guide-btn-primary {
  background: linear-gradient(135deg, #F5A623 0%, #FFBA42 100%);
  color: var(--color-obsidian);
}

.guide-main a.guide-btn-secondary {
  background: rgba(255, 255, 255, 0.05);
  color: var(--color-text-primary);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.guide-disclaimer {
  font-size: 0.8rem !important;
  color: var(--color-text-muted) !important;
  margin-top: 1rem;
}

.guide-related {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.guide-related ul { list-style: none; padding-left: 0; }

.guide-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.5rem 1rem 2rem;
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.7;
  color: var(--color-text-muted);
}

.guide-footer a { color: var(--color-text-secondary); }

/* Header action on the guide pages */
.guide-header-link {
  font-family: var(--font-headline);
  font-weight: 700;
  font-size: 0.8rem;
  color: var(--color-text-primary);
  text-decoration: none;
  padding: 0.55rem 0.95rem;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.15);
  background: rgba(255, 255, 255, 0.04);
  white-space: nowrap;
}

.guide-header-link:hover { border-color: var(--color-brand-teal); }

/* Home: links to the guides */
.home-guides {
  max-width: 80rem;
  margin: 0 auto;
  padding: 2.5rem 1rem 3rem;
}

.home-guides-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-top: 1rem;
}

@media (min-width: 768px) {
  .home-guides { padding: 3rem 2rem; }
  .home-guides-grid { grid-template-columns: repeat(3, 1fr); }
}

.home-guide-card {
  display: block;
  padding: 1.1rem 1.2rem;
  border-radius: 1rem;
  background: var(--color-surface-card);
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-decoration: none;
  transition: border-color 0.2s ease;
}

.home-guide-card:hover { border-color: rgba(80, 193, 183, 0.45); }

.home-guide-card strong {
  display: block;
  font-family: var(--font-headline);
  font-size: 1rem;
  color: var(--color-text-primary);
  margin-bottom: 0.3rem;
}

.home-guide-card span {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.55;
}
