/* ============================================================
   Акции и спецпредложения — изолированные стили
   Префикс: slp- (всё под .slp-root)
   ============================================================ */

.slp-root {
  --slp-accent: #FE5D26;
  --slp-accent-hover: #D95427;
  --slp-black: #312D2B;
  --slp-text: #272F3D;
  --slp-bg: #F6F6F6;
  --slp-white: #FFFFFF;
  --slp-border: rgba(49, 45, 43, 0.1);
  --slp-card-shadow: 0 1px 4px 0 rgba(49, 45, 43, 0.08);
  --slp-transition: .25s ease;
  --slp-radius-sm: 10px;
  --slp-radius-md: 12px;
  --slp-radius-lg: 24px;

  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--slp-text);
  background-color: var(--slp-bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.slp-root *,
.slp-root *::before,
.slp-root *::after {
  box-sizing: border-box;
}

/* Бьём inline font-family, который HTML-редактор может вставить в Body */
.slp-rich,
.slp-rich *,
.slp-modal *,
.slp-card *,
.slp-featured-body * {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
}

.slp-root a {
  text-decoration: none;
  color: inherit;
}

.slp-root img {
  max-width: 100%;
  height: auto;
  display: block;
}

.slp-root button {
  font-family: inherit;
}

.slp-root h1,
.slp-root h2,
.slp-root h3,
.slp-root p,
.slp-root ul,
.slp-root ol {
  margin: 0;
  padding: 0;
}

.slp-root ul,
.slp-root ol {
  list-style: none;
}

.slp-container {
  max-width: 1297px;
  margin: 0 auto;
  padding: 0 15px;
}

/* --- Hero --- */
.slp-hero {
  padding: 32px 0 8px;
}

.slp-hero-title {
  font-size: 32px;
  font-weight: 500;
  line-height: 40px;
  color: var(--slp-black);
}

.slp-hero-subtitle {
  margin-top: 8px;
  font-size: 16px;
  color: var(--slp-text);
  opacity: 0.6;
}

/* --- Featured promo --- */
.slp-featured {
  padding: 32px 0;
}

.slp-featured-card {
  display: flex;
  background: var(--slp-white);
  border-radius: var(--slp-radius-lg);
  box-shadow: var(--slp-card-shadow);
  overflow: hidden;
  transition: box-shadow var(--slp-transition);
  cursor: pointer;
}

.slp-featured-card:hover {
  box-shadow: 0 8px 32px rgba(49, 45, 43, 0.12);
}

.slp-featured-img {
  position: relative;
  flex-shrink: 0;
  width: 480px;
}

.slp-featured-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slp-featured-body {
  display: flex;
  flex-direction: column;
  padding: 36px 40px;
  flex: 1;
}

.slp-featured-title {
  font-size: 28px;
  font-weight: 700;
  line-height: 36px;
  color: var(--slp-black);
  margin-bottom: 16px;
}

/* --- Badge --- */
.slp-badge {
  position: absolute;
  top: 16px;
  left: 16px;
  padding: 5px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
  z-index: 1;
}

.slp-badge--discount {
  background: var(--slp-accent);
  color: var(--slp-white);
}

.slp-badge--hot {
  background: #E53E3E;
  color: var(--slp-white);
}

.slp-badge--bonus {
  background: #16A34A;
  color: var(--slp-white);
}

/* --- Rich text --- */
.slp-rich {
  font-size: 14px;
  line-height: 22px;
  color: var(--slp-text);
}

.slp-rich p {
  margin-bottom: 8px;
}

.slp-rich p:last-child {
  margin-bottom: 0;
}

.slp-rich strong {
  font-weight: 600;
  color: var(--slp-black);
}

.slp-rich em {
  font-style: italic;
}

.slp-rich u {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.slp-accent {
  color: var(--slp-accent);
  font-weight: 600;
}

.slp-rich ul,
.slp-rich ol {
  margin: 8px 0;
  padding-left: 0;
  list-style: none;
}

.slp-rich ul li,
.slp-rich ol li {
  position: relative;
  padding-left: 18px;
  margin-bottom: 4px;
}

.slp-rich ul li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 9px;
  width: 6px;
  height: 6px;
  background: var(--slp-accent);
  border-radius: 50%;
}

.slp-rich ol {
  counter-reset: slpCounter;
}

.slp-rich ol li {
  counter-increment: slpCounter;
}

.slp-rich ol li::before {
  content: counter(slpCounter) ".";
  position: absolute;
  left: 0;
  top: 0;
  font-weight: 600;
  color: var(--slp-accent);
  font-size: 13px;
}

.slp-bubble {
  display: inline-block;
  padding: 4px 12px;
  background: var(--slp-bg);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  color: var(--slp-text);
  opacity: 0.75;
  line-height: 1.5;
}

.slp-featured-body .slp-rich {
  font-size: 15px;
  line-height: 24px;
}

.slp-featured-body .slp-bubble {
  font-size: 13px;
  padding: 5px 14px;
}

/* --- Listing --- */
.slp-listing {
  padding: 24px 0 48px;
}

.slp-root .slp-listing-title {
  font-size: 28px;
  font-weight: 700;
  line-height: 36px;
  color: var(--slp-black);
  margin-bottom: 20px;
}

.slp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

/* --- Card --- */
.slp-card {
  display: flex;
  flex-direction: column;
  background: var(--slp-white);
  border-radius: var(--slp-radius-lg);
  box-shadow: var(--slp-card-shadow);
  overflow: hidden;
  transition: transform var(--slp-transition), box-shadow var(--slp-transition);
  cursor: pointer;
}

.slp-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 32px rgba(49, 45, 43, 0.12);
}

.slp-card-img {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.slp-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.slp-card-body {
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 20px 22px 18px;
  gap: 12px;
}

.slp-card-title {
  font-size: 19px;
  font-weight: 700;
  line-height: 26px;
  color: var(--slp-black);
}

.slp-card-footer {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  padding-top: 14px;
  border-top: 1px solid var(--slp-border);
}

.slp-card-highlight {
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  color: #6b6b6b;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.slp-card-link {
  font-size: 13px;
  font-weight: 600;
  line-height: 18px;
  color: var(--slp-accent);
  white-space: nowrap;
  transition: color var(--slp-transition);
}

.slp-card:hover .slp-card-link {
  color: var(--slp-accent-hover);
}

/* --- CTA --- */
.slp-cta {
  padding: 0 0 60px;
}

.slp-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 40px 48px;
  background: linear-gradient(135deg, var(--slp-accent) 0%, #7B2FF2 100%);
  border-radius: var(--slp-radius-lg);
}

.slp-cta-title {
  font-size: 24px;
  font-weight: 700;
  line-height: 32px;
  color: var(--slp-white);
}

.slp-cta-text {
  margin-top: 6px;
  font-size: 15px;
  line-height: 22px;
  color: var(--slp-white);
  opacity: 0.85;
}

.slp-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  background: var(--slp-accent);
  color: var(--slp-white);
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--slp-radius-sm);
  border: none;
  cursor: pointer;
  transition: background var(--slp-transition), transform var(--slp-transition);
  text-decoration: none;
  white-space: nowrap;
}

.slp-btn:hover {
  background: var(--slp-accent-hover);
  transform: translateY(-1px);
}

.slp-btn--white {
  background: var(--slp-white);
  color: var(--slp-accent);
}

.slp-btn--white:hover {
  background: var(--slp-accent);
  color: var(--slp-white);
}

/* --- Modal --- */
.slp-modal {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.slp-modal.is-open {
  opacity: 1;
  visibility: visible;
}

.slp-modal-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
}

.slp-modal-dialog {
  position: relative;
  display: flex;
  flex-direction: column;
  max-width: 520px;
  max-height: 90vh;
  width: 90%;
  background: var(--slp-white);
  border-radius: var(--slp-radius-lg);
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.2);
  transform: translateY(20px) scale(0.97);
  transition: transform 0.3s ease;
}

.slp-modal.is-open .slp-modal-dialog {
  transform: translateY(0) scale(1);
}

.slp-modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  transition: background var(--slp-transition);
}

.slp-modal-close:hover {
  background: var(--slp-bg);
}

.slp-modal-body {
  display: flex;
  flex-direction: column;
  padding: 36px 32px;
  overflow-y: auto;
  flex: 1;
}

.slp-modal-badge {
  margin-bottom: 12px;
}

.slp-modal-badge .slp-badge {
  position: static;
}

.slp-modal-title {
  font-size: 24px;
  font-weight: 700;
  line-height: 32px;
  color: var(--slp-black);
  margin-bottom: 16px;
}

.slp-modal-content {
  font-size: 15px;
  line-height: 24px;
}

.slp-modal-actions {
  margin-top: 24px;
}

.slp-modal-actions .slp-btn {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif !important;
  color: #fff !important;
}

/* ============================================================
   Tablet (<=991px)
   ============================================================ */
@media (max-width: 991px) {
  .slp-featured-img {
    width: 380px;
  }

  .slp-featured-body {
    padding: 28px 32px;
  }

  .slp-featured-title {
    font-size: 24px;
    line-height: 32px;
  }

  .slp-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .slp-cta-inner {
    padding: 32px 36px;
  }

  .slp-modal-dialog {
    max-width: 480px;
  }
}

/* ============================================================
   Mobile (<=768px)
   ============================================================ */
@media (max-width: 768px) {
  .slp-root section {
    margin-bottom: 0;
  }

  .slp-hero-title {
    font-size: 24px;
    line-height: 32px;
  }

  .slp-featured-card {
    flex-direction: column;
  }

  .slp-featured-img {
    width: 100%;
    aspect-ratio: 16 / 9;
  }

  .slp-featured-body {
    padding: 24px;
  }

  .slp-featured-title {
    font-size: 22px;
    line-height: 30px;
    margin-top: 12px;
  }

  .slp-grid {
    grid-template-columns: 1fr;
  }

  .slp-listing-title {
    font-size: 24px;
    line-height: 32px;
  }

  .slp-cta-inner {
    flex-direction: column;
    text-align: center;
    padding: 32px 24px;
  }

  .slp-cta-title {
    font-size: 20px;
    line-height: 28px;
  }

  .slp-modal-body {
    padding: 24px 20px;
  }

  .slp-modal-title {
    font-size: 20px;
    line-height: 28px;
  }
}

/* ============================================================
   Small mobile (<=480px)
   ============================================================ */
@media (max-width: 480px) {
  .slp-hero {
    padding: 64px 0 4px;
  }

  .slp-hero-title {
    font-size: 24px;
    line-height: 32px;
  }

  .slp-hero-subtitle {
    font-size: 14px;
  }

  .slp-featured {
    padding: 24px 0;
  }

  .slp-featured-body {
    padding: 20px;
  }

  .slp-featured-title {
    font-size: 20px;
    line-height: 26px;
  }

  .slp-featured-body .slp-rich {
    font-size: 14px;
    line-height: 21px;
  }

  .slp-listing {
    padding: 16px 0 36px;
  }

  .slp-listing-title {
    font-size: 22px;
    line-height: 28px;
    margin-bottom: 20px;
  }

  .slp-card-body {
    padding: 16px 18px 18px;
  }

  .slp-card-title {
    font-size: 16px;
    line-height: 22px;
  }

  .slp-card-footer {
    padding-top: 10px;
  }

  .slp-card-highlight {
    font-size: 11px;
    line-height: 15px;
  }

  .slp-card-link {
    font-size: 12px;
  }

  .slp-cta {
    padding: 0 0 40px;
  }

  .slp-cta-inner {
    padding: 28px 20px;
  }

  .slp-cta-title {
    font-size: 18px;
    line-height: 24px;
  }

  .slp-cta-text {
    font-size: 13px;
  }

  .slp-modal-body {
    padding: 20px 16px;
  }

  .slp-modal-title {
    font-size: 18px;
    line-height: 24px;
  }

  .slp-btn {
    padding: 10px 22px;
    font-size: 13px;
  }
}
