/*
 * Shared primitives of the "New Version" main page design.
 * Every wgt-home-* block loads this file before its own stylesheet.
 */

:root {
  --home-purple: #8b6fff;
  --home-purple-strong: #7e4de6;
  --home-title: #1d1d1d;
  --home-subtitle: #667085;
  --home-surface: #f8f8f8;
  --home-surface-border: #ececec;
  --home-card-border: #f6f4ff;
  --home-tag-bg: #faf8ff;
  --home-text-gradient: linear-gradient(160deg, #8b6fff 107.63%, #d8cbfd 115.05%);
  --home-card-shadow: 0 4px 26px rgba(45, 44, 52, 0.05);
  --home-section-padding: 120px;
  --home-content-width: 1200px;
}

[class*="wgt-home"] {
  --home-gap: 42px;

  box-sizing: border-box;
  padding: 0 var(--home-section-padding);
}

[class*="wgt-home"] *,
[class*="wgt-home"] *::before,
[class*="wgt-home"] *::after {
  box-sizing: border-box;
}

[class*="wgt-home"] .home-inner {
  width: 100%;
  max-width: var(--home-content-width);
  margin: 0 auto;
}

/* ===== Section header ===== */

[class*="wgt-home"] .home-section-head {
  display: flex;
  flex-direction: column;
  gap: 32px;
  align-items: flex-start;
}

[class*="wgt-home"] .home-section-head.center {
  align-items: center;
  text-align: center;
}

[class*="wgt-home"] .home-tag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px 10px;
  border: 1px solid var(--home-purple);
  border-radius: 50px;
  background: var(--home-tag-bg);
  box-shadow: inset 4px 4px 4px rgba(255, 255, 255, 0.25), 0 0 0.5px rgba(0, 0, 0, 0.08);
}

[class*="wgt-home"] .home-tag img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

[class*="wgt-home"] .home-tag span {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.42;
  white-space: nowrap;
  background: var(--home-text-gradient);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

[class*="wgt-home"] .home-section-text {
  display: flex;
  flex-direction: column;
  gap: 12px;
  width: 100%;
}

[class*="wgt-home"] .home-section-title,
[class*="wgt-home"] .home-section-title :is(h1, h2, h3, h4, h5, h6, p) {
  margin: 0;
  color: var(--home-title);
  font-size: 38px;
  font-weight: 400;
  line-height: 1.2;
}

[class*="wgt-home"] .home-section-description,
[class*="wgt-home"] .home-section-description p {
  margin: 0;
  color: var(--home-subtitle);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.4;
}

/* ===== Buttons ===== */

[class*="wgt-home"] .home-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 250px;
  padding: 14px 32px;
  border: 1px solid transparent;
  border-radius: 100px;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
  text-decoration: none;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

[class*="wgt-home"] .home-btn-primary {
  background: var(--home-purple-strong);
  color: #fff;
}

[class*="wgt-home"] .home-btn-primary:hover {
  background: var(--primary-color-0);
  color: #fff;
}

[class*="wgt-home"] .home-btn-secondary {
  background: #fff;
  border-color: #f5f3ff;
  color: var(--home-title);
}

[class*="wgt-home"] .home-btn-secondary:hover {
  border-color: var(--home-purple);
  color: var(--home-title);
}

/* ===== Link with arrow ===== */

[class*="wgt-home"] .home-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--primary-color-1);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
  text-decoration: none;
}

[class*="wgt-home"] .home-link::after {
  content: "↗";
  font-size: 13px;
}

[class*="wgt-home"] .home-link:hover {
  text-decoration: underline;
}

/* ===== Cards ===== */

[class*="wgt-home"] .home-card {
  background: var(--home-surface);
  border: 1px solid var(--home-surface-border);
  border-radius: 10px;
}

[class*="wgt-home"] .home-card-white {
  background: #fff;
  border: 1px solid var(--home-card-border);
  border-radius: 10px;
  box-shadow: var(--home-card-shadow);
}

/* ===== Decorative grid background ===== */

[class*="wgt-home"] .home-grid-bg {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image: linear-gradient(to right, rgba(99, 52, 200, 0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(99, 52, 200, 0.05) 1px, transparent 1px);
  background-size: 80px 80px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, #000 20%, transparent 75%);
}

@media (max-width: 1280px) {
  [class*="wgt-home"] {
    --home-section-padding: 64px;
  }
}

@media (max-width: 992px) {
  [class*="wgt-home"] {
    --home-section-padding: 32px;
    --home-gap: 32px;
  }

  [class*="wgt-home"] .home-section-head {
    gap: 24px;
  }

  [class*="wgt-home"] .home-section-title,
  [class*="wgt-home"] .home-section-title :is(h1, h2, h3, h4, h5, h6, p) {
    font-size: 30px;
  }
}

@media (max-width: 768px) {
  [class*="wgt-home"] {
    --home-section-padding: 16px;
  }

  [class*="wgt-home"] .home-section-title,
  [class*="wgt-home"] .home-section-title :is(h1, h2, h3, h4, h5, h6, p) {
    font-size: 26px;
  }

  [class*="wgt-home"] .home-btn {
    width: 100%;
    min-width: 0;
  }
}
