/* ============================================
   Xterium — Shared scaffold-style для content-only pages
   (about, legal: rules/agreement/privacy/terms, community)
   All classes prefixed: xp-
   Принципы из scaffold-страниц: xg-hero, xg-article-card, xg-cta.
   @since 2026-05-17 (Phase N — scaffold principles propagation)
   ============================================ */

/* ===== HERO ===== */
.xp-hero {
  position: relative;
  z-index: 1;
  padding: 40px 0 56px;
  overflow: hidden;
}
.xp-hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.xp-hero-bg picture, .xp-hero-bg img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .35;
}
.xp-hero-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(6,10,20,.6) 0%, rgba(6,10,20,.88) 55%, var(--xh-bg-deep, #060a14) 100%);
}
.xp-hero-inner {
  position: relative;
  z-index: 1;
  max-width: var(--xh-max-w, 1200px);
  margin: 0 auto;
  padding: 0 var(--xh-container-pad, 32px);
}
.xp-hero-inner .xh-breadcrumbs { margin-bottom: 14px; }
.xp-hero-eyebrow {
  display: inline-block;
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--xh-orange, #e88420);
  margin-bottom: 10px;
}
.xp-hero-title {
  font-family: var(--xh-font-display, 'Archivo Black'), sans-serif;
  font-size: clamp(28px, 4.5vw, 48px);
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #fff;
  line-height: 1.05;
  margin: 0 0 14px;
}
.xp-hero-accent { color: var(--xh-orange, #e88420); }
.xp-hero-desc {
  font-size: 15.5px;
  color: var(--xh-text-secondary, #a4b3c8);
  max-width: 640px;
  margin: 0 0 20px;
  line-height: 1.6;
}
/* Wave J Phase H+ 2026-05-21: hero meta-items как chip'ы с background — было plain text без визуальной структуры. */
.xp-hero-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.xp-meta-item {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  font-size: 12.5px;
  color: var(--xh-text-secondary, #a4b3c8);
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-weight: 600;
  letter-spacing: .02em;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.xp-meta-item svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
  color: var(--xh-yellow, #FFCC00);
}

/* ===== STATS row (для about/contacts) ===== */
.xp-stats {
  position: relative;
  z-index: 1;
  max-width: var(--xh-max-w, 1200px);
  margin: -20px auto 0;
  padding: 0 var(--xh-container-pad, 32px);
}
.xp-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
}
.xp-stat {
  padding: 20px 18px;
  background: var(--xh-bg-card, #0c1322);
  border: 1px solid var(--xh-border-light, #1e2d4a);
  border-radius: var(--xh-radius-lg, 10px);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: transform var(--xh-transition, .3s ease);
}
.xp-stat:hover { transform: translateY(-2px); }
.xp-stat__value {
  font-family: var(--xh-font-display, 'Archivo Black'), sans-serif;
  font-size: 30px;
  line-height: 1;
  color: var(--xh-orange, #e88420);
}
.xp-stat__value sup { font-size: 0.55em; vertical-align: super; opacity: .8; }
.xp-stat__label {
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .6px;
  color: var(--xh-text-secondary, #a4b3c8);
}

/* ===== CONTENT LAYOUT (article-card pattern из xg-) ===== */
.xp-layout {
  position: relative;
  z-index: 1;
  padding: 40px 0 56px;
}
.xp-layout-inner {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 var(--xh-container-pad, 32px);
}
.xp-layout-inner--wide {
  max-width: var(--xh-max-w, 1200px);
}
.xp-article {
  background: var(--xh-bg-card, #0c1322);
  border: 1px solid var(--xh-border, #162035);
  border-radius: var(--xh-radius-lg, 10px);
  padding: 36px 40px;
}
.xp-article.xh-prose { color: var(--xh-text-secondary, #a4b3c8); }

/* ===== CARDS GRID (для contacts, community: 2-3 cards с icons) ===== */
.xp-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 18px;
  margin: 0 0 28px;
}
.xp-card {
  padding: 24px;
  background: var(--xh-bg-card, #0c1322);
  border: 1px solid var(--xh-border, #162035);
  border-radius: var(--xh-radius-lg, 10px);
  transition: all var(--xh-transition, .3s ease);
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  color: inherit;
}
.xp-card:hover {
  border-color: var(--xh-border-light, #1e2d4a);
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(0,0,0,.3);
}
.xp-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(232,132,30,.08);
  border: 1px solid rgba(232,132,30,.25);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.xp-card__icon svg {
  width: 20px;
  height: 20px;
  color: var(--xh-orange, #e88420);
}
.xp-card__icon--blue   { background: rgba(42,125,225,.08);  border-color: rgba(42,125,225,.25); }
.xp-card__icon--blue svg { color: var(--xh-blue-light, #4a9df5); }
.xp-card__icon--teal   { background: rgba(32,176,184,.08);  border-color: rgba(32,176,184,.25); }
.xp-card__icon--teal svg { color: var(--xh-teal, #20b0b8); }
.xp-card__icon--green  { background: rgba(32,168,104,.08);  border-color: rgba(32,168,104,.25); }
.xp-card__icon--green svg { color: var(--xh-green, #20a868); }
.xp-card__icon--purple { background: rgba(106,64,184,.08);  border-color: rgba(106,64,184,.25); }
.xp-card__icon--purple svg { color: var(--xh-purple, #6a40b8); }
.xp-card h3 {
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-size: 17px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--xh-text, #e8ecf2);
  margin: 0;
}
.xp-card p {
  margin: 0;
  font-size: 14px;
  color: var(--xh-text-secondary, #a4b3c8);
  line-height: 1.55;
}
.xp-card__cta {
  margin-top: auto;
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--xh-orange, #e88420);
  display: flex;
  align-items: center;
  gap: 6px;
}
.xp-card__cta svg { width: 14px; height: 14px; }

/* ===== Section title (между блоками внутри страницы) ===== */
.xp-section-title {
  font-family: var(--xh-font-heading, 'Rajdhani'), sans-serif;
  font-size: 22px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #fff;
  margin: 32px 0 20px;
  display: flex;
  align-items: center;
  gap: 16px;
}
.xp-section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--xh-border-light, #1e2d4a);
}

/* ===== CTA banner (общий xp-cta) ===== */
.xp-cta {
  position: relative;
  z-index: 1;
  padding: 0 0 56px;
}
.xp-cta-wrap {
  max-width: var(--xh-max-w, 1200px);
  margin: 0 auto;
  padding: 0 var(--xh-container-pad, 32px);
}
.xp-cta-inner {
  padding: 44px 48px;
  border-radius: var(--xh-radius-lg, 10px);
  border: 1px solid var(--xh-border-light, #1e2d4a);
  position: relative;
  overflow: hidden;
  text-align: center;
}
.xp-cta-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.xp-cta-bg picture, .xp-cta-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.xp-cta-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(8,12,22,.92) 0%, rgba(8,12,22,.78) 50%, rgba(8,12,22,.62) 100%);
}
.xp-cta-content {
  position: relative;
  z-index: 1;
}
.xp-cta-content h2 {
  font-family: var(--xh-font-display, 'Archivo Black'), sans-serif;
  font-size: clamp(22px, 3vw, 30px);
  text-transform: uppercase;
  letter-spacing: 2px;
  color: #fff;
  margin: 0 0 12px;
}
.xp-cta-content p {
  font-size: 15px;
  color: var(--xh-text-secondary, #a4b3c8);
  margin: 0 auto 22px;
  max-width: 480px;
}
.xp-cta-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
  .xp-hero { padding: 32px 0 40px; }
  .xp-article { padding: 24px 22px; }
  .xp-cta-inner { padding: 32px 24px; }
  .xp-section-title { font-size: 18px; letter-spacing: 1.5px; }
}
@media (max-width: 480px) {
  .xp-stat__value { font-size: 24px; }
}

@media (prefers-reduced-motion: reduce) {
  .xp-stat, .xp-card { transition: none; }
}
