/* parimatchcl.cl — light, article/help-center theme. Blue accent. */

:root {
  --bg: #fafaf8;
  --bg-soft: #f2f1ec;
  --card: #ffffff;
  --card-hover: #f5f4ef;
  --text: #181712;
  --muted: #54524a;
  --muted-soft: #8a877a;
  --line: #e3e0d5;
  --brand: #f8ff13;
  --accent-blue: #2c5aa6;
  --danger-soft: #b3261e;
  --max: 1040px;
  --max-prose: 760px;
  --radius: 12px;
  --radius-sm: 8px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--muted);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

.container {
  width: min(100% - 24px, var(--max));
  margin-inline: auto;
}

a { color: var(--accent-blue); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------- 18+ top bar ---------- */
.topbar {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 13px;
}
.topbar .container {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0;
}
.badge-18 {
  flex: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 22px;
  padding: 0 6px;
  border: 2px solid var(--accent-blue);
  border-radius: 999px;
  color: var(--accent-blue);
  font-weight: 800;
  font-size: 12px;
  line-height: 1;
}
.topbar p { margin: 0; }

/* ---------- Header / nav ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(250, 250, 248, 0.96);
  backdrop-filter: saturate(1.1) blur(6px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
}
.brand-lockup { display: inline-flex; align-items: center; gap: 10px; }
.logo-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: var(--text);
  color: var(--brand);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: -0.02em;
  border: 2px solid var(--accent-blue);
}
.brand-name {
  font-weight: 700;
  color: var(--text);
  font-size: 16px;
  letter-spacing: -0.01em;
}
.brand-name span { color: var(--muted-soft); font-weight: 500; }

.nav-links {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  padding: 0;
  counter-reset: none;
}
.nav-links li { margin: 0; }
.nav-links a {
  display: inline-block;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
}
.nav-links a:hover { background: var(--bg-soft); color: var(--text); text-decoration: none; }
.nav-links a[aria-current="page"] { color: var(--accent-blue); }

/* ---------- Breadcrumb ---------- */
.breadcrumb {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  font-size: 13px;
}
.breadcrumb ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 10px 0;
  color: var(--muted-soft);
}
.breadcrumb li { display: inline-flex; gap: 8px; align-items: center; }
.breadcrumb li + li::before { content: "›"; color: var(--muted-soft); }
.breadcrumb a { color: var(--muted); }
.breadcrumb [aria-current="page"] { color: var(--text); }

/* ---------- Main / prose ---------- */
main { padding: 8px 0 48px; }

.hero { padding: 28px 0 8px; }
h1 {
  color: var(--text);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.12;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  max-width: var(--max);
}
.lead {
  color: var(--muted);
  font-size: clamp(16px, 1.4vw, 18px);
  max-width: var(--max-prose);
  margin: 0 0 14px;
}

.prose { max-width: var(--max-prose); }
.prose h2 {
  color: var(--text);
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.015em;
  line-height: 1.2;
  margin: 40px 0 12px;
  scroll-margin-top: 80px;
}
.prose h2::after {
  content: "";
  display: block;
  width: 54px;
  height: 3px;
  margin-top: 10px;
  background: var(--brand);
  border-radius: 2px;
}
.prose h3 {
  color: var(--text);
  font-size: 19px;
  font-weight: 700;
  margin: 26px 0 8px;
}
.prose p { margin: 0 0 14px; }
.prose a { font-weight: 600; }

section { scroll-margin-top: 80px; }
.section-band { background: var(--bg-soft); }
.section-pad { padding: 8px 0 4px; }

.long { content-visibility: auto; contain-intrinsic-size: auto 600px; }

/* ---------- Tables ---------- */
.table-wrap {
  max-width: var(--max);
  overflow-x: auto;
  margin: 18px 0 8px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  min-width: 480px;
}
caption {
  text-align: left;
  padding: 12px 16px 0;
  color: var(--muted-soft);
  font-size: 13px;
  font-weight: 600;
}
th, td {
  text-align: left;
  padding: 12px 16px;
  vertical-align: top;
}
thead th {
  color: var(--text);
  font-weight: 700;
  border-bottom: 2px solid var(--accent-blue);
  white-space: nowrap;
}
tbody tr { border-bottom: 1px solid var(--line); }
tbody tr:last-child { border-bottom: none; }
tbody td:first-child { color: var(--text); font-weight: 600; }

/* ---------- Chips ---------- */
.chip {
  display: inline-block;
  padding: 2px 9px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  border: 1px solid currentColor;
  line-height: 1.5;
}
.chip-common { color: var(--accent-blue); }
.chip-rare { color: var(--muted-soft); }
.chip-avoid { color: var(--danger-soft); }

/* ---------- Step markers ---------- */
.steps { list-style: none; margin: 18px 0 8px; padding: 0; }
.step {
  position: relative;
  display: grid;
  grid-template-columns: 36px 1fr;
  gap: 16px;
  padding: 0 0 22px 0;
}
.step:last-child { padding-bottom: 0; }
.step::before {
  content: "";
  position: absolute;
  left: 17px;
  top: 40px;
  bottom: 0;
  width: 2px;
  background: var(--line);
}
.step:last-child::before { display: none; }
.step-num {
  position: relative;
  z-index: 1;
  width: 36px;
  height: 36px;
  border: 2px solid var(--accent-blue);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-blue);
  font-weight: 800;
  background: var(--bg);
}
.step-body h3 { margin: 4px 0 6px; }
.step-body p { margin: 0; }

/* ---------- Cards (RG section) ---------- */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin: 18px 0 8px;
  max-width: var(--max);
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  transition: background 0.15s ease;
}
.card:hover { background: var(--card-hover); }
.card h3 { margin: 0 0 8px; color: var(--text); font-size: 17px; }
.card p { margin: 0; font-size: 15px; }

/* ---------- Notice ---------- */
.notice {
  background: var(--bg-soft);
  border: 1px solid var(--line);
  border-left: 3px solid var(--accent-blue);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  margin: 16px 0;
  max-width: var(--max-prose);
  font-size: 15px;
}
.notice p { margin: 0; }

/* ---------- FAQ ---------- */
.faq { max-width: var(--max-prose); margin-top: 8px; }
.faq details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 4px 16px;
}
.faq details + details { margin-top: 10px; }
.faq details[open] { background: var(--card-hover); }
.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 12px 24px 12px 0;
  position: relative;
  font-weight: 700;
  color: var(--text);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+";
  position: absolute;
  right: 0;
  top: 10px;
  color: var(--accent-blue);
  font-weight: 700;
  font-size: 20px;
}
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 0 0 12px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--bg-soft);
  border-top: 1px solid var(--line);
  padding: 36px 0 24px;
  font-size: 14px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 28px;
}
.site-footer h4 {
  color: var(--text);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin: 0 0 12px;
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin: 0 0 8px; }
.site-footer a { color: var(--muted); }
.site-footer .foot-desc { color: var(--muted); max-width: 34ch; margin: 10px 0 0; }

/* Footer payment block — M3: div > figure > img */
.footer-payments {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.footer-payments figure { margin: 0; }
.footer-payments img {
  height: 28px;
  width: auto;
  display: block;
}

.footer-legal {
  margin-top: 24px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  color: var(--muted-soft);
  font-size: 13px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  align-items: center;
}
.footer-legal .badge-18 { border-color: var(--muted-soft); color: var(--muted-soft); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .site-header .container { flex-wrap: wrap; }
  .nav-links { flex-wrap: wrap; gap: 4px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 640px) {
  .container { width: min(100% - 20px, var(--max)); }
  .step { grid-template-columns: 28px 1fr; gap: 12px; }
  .step-num { width: 28px; height: 28px; font-size: 13px; }
  .step::before { left: 13px; top: 32px; }
  .footer-grid { grid-template-columns: 1fr; }
}
@media (max-width: 420px) {
  table { font-size: 14px; }
  .chip { display: inline-block; margin-top: 2px; }
}

.logo-mark img { width: 36px; height: 36px; display: block; object-fit: cover; }

.legal-doc{padding:48px 0;max-width:820px}
.legal-doc h1{margin-bottom:8px}
.legal-doc h2{margin-top:34px}
.legal-doc .legal-updated{color:var(--muted,#888);font-size:14px}

.content-figure{margin:24px 0}
.content-figure img{width:100%;height:auto;border-radius:var(--radius,12px);display:block}

.action-link{display:inline-block;padding:12px 26px;border-radius:8px;background:var(--accent-blue);color:#fff;font-weight:600;text-decoration:none;transition:opacity .15s ease}
.action-link:hover{opacity:.88;color:#fff}

.nav-links a.nav-mark { color: var(--accent-blue); font-weight: 700; }
.action-link--alt { background: transparent; border: 2px solid var(--accent-blue); color: var(--accent-blue); padding: 10px 24px; }
.action-link--alt:hover { opacity: 1; background: var(--accent-blue); color: #fff; }
