/* Скоро Пицца LMS v5.47.0 — единая визуальная система платформы */
:root {
  --sp-brand-red: #e31937;
  --sp-brand-red-dark: #a60f24;
  --sp-brand-yellow: #ffca28;
  --sp-text: #34373d;
  --sp-muted: #737b87;
  --sp-line: #e3e6eb;
  --sp-page: #f3f4f6;
  --sp-surface: #ffffff;
  --sp-radius-hero: 28px;
  --sp-radius-panel: 22px;
  --sp-radius-control: 14px;
  --sp-shadow-panel: 0 10px 30px rgba(31, 38, 49, .07);
  --sp-shadow-hero: 0 18px 48px rgba(165, 15, 36, .18);
}

html, body {
  color: var(--sp-text);
  background: var(--sp-page);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

body { line-height: 1.45; }

/* Верхняя панель: крупнее подписи, устойчивые сетки без наложений. */
.topbar {
  column-gap: clamp(18px, 1.8vw, 30px);
  min-height: 76px;
  padding-inline: clamp(22px, 3vw, 54px);
}

.main-nav {
  min-width: 0;
  gap: clamp(18px, 1.45vw, 27px);
}

.nav-link {
  min-height: 48px;
  font-size: 15px;
  font-weight: 750;
  line-height: 1.2;
  white-space: nowrap;
}

.brand strong { font-size: 16px; }
.brand small { font-size: 11px; }
.account__copy strong { font-size: 13px; }
.account__copy small { font-size: 11px; }

/* Единые шапки разделов. */
.sp-infographic-hero,
.analytics-screen .analytics-hero,
.assessment-hero,
.course-detail-hero,
.course-editor-hero,
.quiz-hero,
.profile-hero {
  box-sizing: border-box;
  min-height: 220px;
  overflow: hidden;
  padding: 38px 42px;
  border-radius: var(--sp-radius-hero);
  box-shadow: var(--sp-shadow-hero);
}

.sp-infographic-hero,
.analytics-screen .analytics-hero,
.assessment-hero { min-height: 220px; }

.sp-infographic-hero h1,
.sp-team__hero.sp-infographic-hero h1,
.analytics-screen .analytics-hero h1,
.assessment-hero h1,
.course-detail-hero h1,
.course-editor-hero h1,
.quiz-hero h1,
.profile-hero h1 {
  margin-block: 0;
  color: #fff;
  font-size: clamp(38px, 4vw, 58px);
  font-weight: 850;
  line-height: 1.02;
  letter-spacing: -.04em;
}

.sp-infographic-hero .eyebrow,
.sp-team__hero.sp-infographic-hero .sp-team__eyebrow,
.analytics-screen .analytics-eyebrow,
.assessment-hero .eyebrow,
.course-detail-hero .eyebrow,
.course-editor-hero .eyebrow,
.quiz-hero .eyebrow,
.profile-hero .eyebrow {
  margin: 0 0 10px;
  color: var(--sp-brand-yellow);
  font-size: 12px;
  font-weight: 900;
  line-height: 1.25;
  letter-spacing: .15em;
  text-transform: uppercase;
}

.sp-infographic-hero > div:first-child > p:last-child,
.sp-team__hero.sp-infographic-hero .sp-team__brand p,
.analytics-screen .analytics-hero-subtitle,
.assessment-hero p:not(.eyebrow),
.course-detail-hero__copy > p:not(.eyebrow),
.course-editor-hero > div:first-child > p:last-child,
.quiz-hero p:last-child,
.profile-hero p:last-child {
  max-width: 740px;
  margin: 15px 0 0;
  color: rgba(255, 255, 255, .86);
  font-size: 16px;
  line-height: 1.5;
}

.assessment-hero {
  grid-template-columns: minmax(0, 1fr) 270px;
  background: linear-gradient(125deg, #8e0921 0%, #d70d31 62%, #f0445e 100%);
}

.assessment-hero__visual svg { width: 230px; }
.assessment-hero__actions { margin-top: 24px; }
.sp-team__hero.sp-infographic-hero { margin-top: 0; }

/* Главный баннер сохраняет рекламный формат, но использует ту же геометрию. */
.home-carousel {
  border-radius: var(--sp-radius-hero);
  box-shadow: var(--sp-shadow-hero);
}

.home-carousel__slide { padding: 38px 48px; }
.home-carousel-link,
.home-carousel__action { border-radius: var(--sp-radius-control); }

/* Единые панели и карточки. */
.panel,
.course-row,
.catalog-card,
.banner-admin-card,
.banner-admin-footer,
.empty-state,
.course-outline,
.course-progress-card,
.profile-identity,
.profile-learning,
.profile-assignments,
.home-news-card,
.news-admin-row,
.news-detail__content,
.analytics-panel,
.analytics-card,
.analytics-kpi,
.team-ranking,
.assessment-panel,
.assessment-summary article,
.assessment-template-card,
.assessment-question,
.sp-team__panel,
.sp-card,
.sp-structure,
.editor-guide,
.editor-row,
.edit-chapter-card,
.course-template-card,
.course-workflow-card,
.assignment-history-row,
.profile-course-row,
.team-ranking__row,
.analytics-attention-item,
.analytics-list-item,
.sp-modal,
.editor-dialog,
.profile-edit-dialog,
.assignment-resubmit-dialog,
.course-copy-dialog,
.course-workflow-dialog {
  border-color: var(--sp-line);
  border-radius: var(--sp-radius-panel);
  background-color: var(--sp-surface);
  box-shadow: var(--sp-shadow-panel);
}

.panel,
.analytics-panel,
.assessment-panel,
.profile-learning,
.profile-assignments { overflow: hidden; }

.panel__head,
.assessment-panel__head,
.analytics-card-head {
  gap: 20px;
  padding-bottom: 18px;
  border-bottom-color: var(--sp-line);
}

.panel__head h2,
.assessment-panel__head h2,
.analytics-card-head h2,
.team-ranking__section-head h2 {
  margin: 0;
  color: var(--sp-text);
  font-size: 24px;
  font-weight: 820;
  line-height: 1.2;
  letter-spacing: -.02em;
}

.panel__head p,
.assessment-panel__head p,
.analytics-card-copy,
.team-ranking__section-head p {
  color: var(--sp-muted);
  font-size: 13px;
  line-height: 1.5;
}

.course-row,
.catalog-card,
.news-admin-row,
.home-news-card,
.assessment-template-card { transition: transform .18s ease, box-shadow .18s ease; }

.course-row:hover,
.catalog-card:hover,
.news-admin-row:hover,
.home-news-card:hover,
.assessment-template-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(31, 38, 49, .10);
}

.catalog-card__image,
.course-row__image { overflow: hidden; }

/* Единые кнопки. Малые круглые иконки остаются компактными. */
.button,
.sp-button,
.assessment-dialog__footer .button,
.assessment-template-card > button,
.assessment-hero .button {
  min-height: 46px;
  padding-inline: 20px;
  border-radius: var(--sp-radius-control);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.2;
}

.button--primary,
.sp-button--primary {
  color: #fff;
  background: var(--sp-brand-red);
}

.button--primary:hover,
.sp-button--primary:hover { background: var(--sp-brand-red-dark); }

.button--secondary,
.sp-button--secondary {
  color: var(--sp-text);
  border: 1px solid var(--sp-line);
  background: #fff;
}

.button--secondary:hover,
.sp-button--secondary:hover {
  border-color: #cfd3d9;
  background: #f7f8f9;
}

.button--soft { min-height: 42px; }

.message-compose button,
.notification-center-mark-all,
.assessment-answer-buttons button {
  min-height: 42px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 800;
}

.icon-action,
.dialog-close,
.sp-modal__close,
.assessment-dialog__close,
.notification-center-trigger,
.message-center-trigger,
.notification-center-close,
.message-center-close,
.assessment-open { border-radius: 13px; }

/* Единые поля, поиски и вкладки. */
.form-control input,
.form-control select,
.form-control textarea,
.rich-editable,
.sp-field input,
.sp-field select,
.sp-field textarea,
.assessment-field input,
.assessment-field select,
.assessment-field textarea,
.message-center-search,
.message-compose textarea,
.search {
  border-color: #d7dbe1;
  border-radius: var(--sp-radius-control);
  background: #fff;
  font-size: 14px;
}

.form-control input,
.form-control select,
.sp-field input,
.sp-field select,
.assessment-field input,
.assessment-field select,
.search { min-height: 46px; }

.form-control > span,
.sp-field > span,
.assessment-field > span {
  color: #515863;
  font-size: 13px;
  font-weight: 800;
}

.tabs { gap: 8px; }
.tab,
.analytics-tab,
.assessment-filter button {
  min-height: 42px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 800;
}

.toolbar { gap: 20px; padding-block: 18px; }

/* Диалоги и боковые центры используют одну типографику и радиусы. */
.editor-dialog,
.profile-edit-dialog,
.assignment-resubmit-dialog,
.course-copy-dialog,
.course-workflow-dialog,
.assessment-dialog,
.message-center-dialog,
.notification-center-dialog {
  border-radius: 24px;
  box-shadow: 0 28px 80px rgba(25, 31, 42, .28);
}

.editor-dialog__head,
.assessment-dialog__head,
.message-center-head,
.notification-center-head { padding: 24px 28px; }

.editor-dialog__head h2,
.assessment-dialog__head h2,
.message-center-head h2,
.notification-center-head h2 {
  margin: 0;
  color: var(--sp-text);
  font-size: 28px;
  font-weight: 840;
  line-height: 1.18;
  letter-spacing: -.025em;
}

/* Детали контента. */
.section-header:not(.sp-infographic-hero) h1,
.news-editor-header h1 {
  font-size: clamp(34px, 4vw, 46px);
  line-height: 1.08;
  letter-spacing: -.035em;
}

.news-detail { max-width: 960px; }
.news-detail__hero { margin: 28px auto 24px; }
.news-detail__hero h1 { max-width: 900px; }
.news-detail__media { border-radius: var(--sp-radius-panel); }
.news-detail__content {
  padding: clamp(24px, 4vw, 42px);
  font-size: 18px;
  line-height: 1.7;
}
.news-detail__content > :first-child { margin-top: 0; }
.news-detail__content > :last-child { margin-bottom: 0; }
.news-detail__actions .button { min-width: 180px; }

.assessment-summary { gap: 14px; }
.assessment-summary article { padding: 20px 22px; }
.assessment-panel__head { padding: 24px 26px; }
.assessment-filter { border-radius: 14px; }

@media (min-width: 1901px) {
  .topbar { grid-template-columns: minmax(210px, 1fr) auto minmax(250px, 1fr); }
  .main-nav { justify-content: center; }
}

@media (min-width: 721px) and (max-width: 1900px) {
  .topbar {
    grid-template-columns: auto minmax(0, 1fr);
    grid-template-rows: 62px 52px;
    min-height: 116px;
    padding-block: 0;
    row-gap: 0;
  }

  .topbar .brand { grid-column: 1; grid-row: 1; }
  .topbar .account { grid-column: 2; grid-row: 1; justify-self: end; }
  .topbar .main-nav {
    grid-column: 1 / -1;
    grid-row: 2;
    min-height: 52px;
    align-self: stretch;
    justify-content: center;
    gap: clamp(18px, 2.3vw, 30px);
    overflow-x: auto;
    border-top: 1px solid var(--sp-line);
    scrollbar-width: none;
  }

  .topbar .main-nav::-webkit-scrollbar { display: none; }
  .topbar .main-nav .nav-link { flex: 0 0 auto; min-height: 52px; font-size: 14px; }
}

@media (max-width: 880px) {
  .sp-infographic-hero,
  .analytics-screen .analytics-hero,
  .assessment-hero,
  .course-detail-hero,
  .course-editor-hero,
  .quiz-hero,
  .profile-hero {
    min-height: 210px;
    padding: 32px 28px;
    border-radius: 24px;
  }

  .assessment-hero { grid-template-columns: minmax(0, 1fr) 210px; }
  .assessment-hero__visual svg { width: 190px; }
}

@media (max-width: 720px) {
  .topbar {
    min-height: 68px;
    padding-inline: 14px;
  }

  .brand strong { font-size: 15px; }
  .brand small { font-size: 10px; }
  .mobile-nav a { min-width: 82px; font-size: 12px; font-weight: 750; }

  .sp-infographic-hero,
  .analytics-screen .analytics-hero,
  .sp-team__hero.sp-infographic-hero,
  .assessment-hero,
  .course-detail-hero,
  .course-editor-hero,
  .quiz-hero,
  .profile-hero {
    min-height: 0;
    padding: 28px 22px;
    border-radius: 22px;
  }

  .sp-infographic-hero,
  .analytics-screen .analytics-hero,
  .sp-team__hero.sp-infographic-hero { min-height: 300px; }

  .sp-infographic-hero h1,
  .sp-team__hero.sp-infographic-hero h1,
  .analytics-screen .analytics-hero h1,
  .assessment-hero h1,
  .course-detail-hero h1,
  .course-editor-hero h1,
  .quiz-hero h1,
  .profile-hero h1 { font-size: 36px; }

  .sp-infographic-hero > div:first-child > p:last-child,
  .sp-team__hero.sp-infographic-hero .sp-team__brand p,
  .analytics-screen .analytics-hero-subtitle,
  .assessment-hero p:not(.eyebrow),
  .course-detail-hero__copy > p:not(.eyebrow),
  .course-editor-hero > div:first-child > p:last-child,
  .quiz-hero p:last-child,
  .profile-hero p:last-child { font-size: 15px; }

  .assessment-hero { display: block; }
  .assessment-hero__visual { display: none; }
  .assessment-hero__actions { display: grid; }

  .panel,
  .analytics-panel,
  .assessment-panel,
  .profile-learning,
  .profile-assignments { border-radius: 18px; }

  .panel__head h2,
  .assessment-panel__head h2,
  .analytics-card-head h2,
  .team-ranking__section-head h2 { font-size: 21px; }

  .button,
  .sp-button,
  .assessment-dialog__footer .button,
  .assessment-template-card > button,
  .assessment-hero .button { min-height: 46px; font-size: 14px; }

  .editor-dialog,
  .profile-edit-dialog,
  .assignment-resubmit-dialog,
  .course-copy-dialog,
  .course-workflow-dialog,
  .assessment-dialog { border-radius: 0; }

  .news-detail__content { padding: 22px 18px; font-size: 16px; }
  .news-detail__actions { display: grid; }
  .news-detail__actions .button { width: 100%; }
}

@media (max-width: 420px) {
  .sp-infographic-hero h1,
  .sp-team__hero.sp-infographic-hero h1,
  .analytics-screen .analytics-hero h1,
  .assessment-hero h1,
  .course-detail-hero h1,
  .course-editor-hero h1,
  .quiz-hero h1,
  .profile-hero h1 { font-size: 32px; }

  .home-carousel { border-radius: 20px; }
  .home-carousel__slide { padding-inline: 24px; }
}
