.group-creation-page {
  --group-creation-accent: var(--color-primary);
  --group-creation-accent-soft: rgba(var(--color-primary-rgb), 0.12);
  --group-creation-accent-shadow: rgba(var(--color-primary-rgb), 0.22);
  --group-creation-accent-contrast: #ffffff;
  padding-bottom: 28px;
}

.group-creation-page .group-creation-layout {
  align-items: flex-start;
}

.group-creation-page .group-creation-wizard-card {
  background: #fff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 24px;
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.08);
  padding: 24px;
}

.group-creation-page .group-creation-wizard-header {
  display: flex;
  flex-direction: column;
  gap: 54px;
  margin-bottom: 64px;
}

.group-creation-page .group-creation-wizard-title {
  margin: 0;
  font-size: 30px;
  font-weight: 800;
  line-height: 1.15;
  color: #0f172a;
  text-align: center;
}

.group-creation-page .group-creation-progress {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 0;
  width: 100%;
  max-width: 820px;
  margin: 0 auto;
}

.group-creation-page .group-creation-progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  flex: 1 1 0;
  gap: 0;
}

.group-creation-page .group-creation-progress-step-top {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  position: relative;
}

.group-creation-page .group-creation-progress-index {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 999px;
  background: #ffffff;
  border: 4px solid #e5e7eb;
  color: #94a3b8;
  font-size: 17px;
  font-weight: 700;
  position: relative;
  z-index: 2;
  transition:
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.group-creation-page .group-creation-progress-label {
  display: none;
}

.group-creation-page .group-creation-progress-bar {
  position: absolute;
  top: 24px;
  left: 50%;
  width: 100%;
  height: 8px;
  border-radius: 999px;
  background: #e5e7eb;
  overflow: hidden;
  z-index: 1;
}

.group-creation-page .group-creation-progress-bar::after {
  content: "";
  display: block;
  width: 0;
  height: 100%;
  background: var(--group-creation-accent);
  transition: width 0.2s ease;
}

.group-creation-page .group-creation-progress-step:last-child .group-creation-progress-bar {
  display: none;
}

.group-creation-page .group-creation-progress-step.is-active .group-creation-progress-index,
.group-creation-page .group-creation-progress-step.is-complete .group-creation-progress-index {
  border-color: var(--group-creation-accent);
  color: var(--group-creation-accent-contrast);
  box-shadow: 0 0 0 6px var(--group-creation-accent-soft);
}

.group-creation-page .group-creation-progress-step.is-active .group-creation-progress-index {
  background: var(--group-creation-accent);
}

.group-creation-page .group-creation-progress-step.is-complete .group-creation-progress-index {
  background: #ffffff;
  color: var(--group-creation-accent);
}

.group-creation-page .group-creation-progress-step.is-active .group-creation-progress-label,
.group-creation-page .group-creation-progress-step.is-complete .group-creation-progress-label {
  color: #0f172a;
}

.group-creation-page .group-creation-progress-step.is-complete .group-creation-progress-bar::after {
  width: 100%;
}

.group-creation-page .group-creation-step {
  display: none;
}

.group-creation-page .group-creation-step.is-active {
  display: block;
}

.group-creation-page .group-creation-step-title {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
}

.group-creation-page .group-creation-section-title {
  font-size: 24px !important;
  font-weight: 800;
  color: #0f172a;
  text-align: center;
}

.group-creation-page .group-creation-step-title--center {
  text-align: center;
  margin-bottom: 26px;
}

.group-creation-page .group-creation-step-note {
  margin: 0 0 18px;
  color: #64748b;
}

.group-creation-page .group-creation-step--intro {
  max-width: 760px;
  margin: 0 auto;
}

.group-creation-page .group-creation-step--intro .group-creation-grid {
  gap: 46px;
}

.group-creation-page .group-creation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.group-creation-page .group-creation-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.group-creation-page .group-creation-field--full {
  grid-column: 1 / -1;
}

.group-creation-page .group-creation-field label,
.group-creation-page .group-creation-group-label {
  font-size: 18px;
  font-weight: 800;
  color: #1e293b;
  text-align: center;
  margin-bottom: 14px;
}

.group-creation-page .group-creation-field--compact input[type="text"] {
  max-width: 360px;
  margin: 0 auto;
  text-align: left;
}

.group-creation-page .group-creation-field--motto input[type="text"] {
  width: 100%;
  max-width: none;
}

.group-creation-page .group-creation-field--motto {
  width: 35%;
}

.group-creation-page .group-creation-field--compact input[type="number"],
.group-creation-page .group-creation-field--compact select {
  max-width: 220px;
  margin: 0 auto;
}

.group-creation-page .group-creation-field input[type="text"],
.group-creation-page .group-creation-field input[type="number"],
.group-creation-page .group-creation-field select {
  width: 100%;
  min-height: 46px;
  border: 1px solid #cbd5e1;
  border-radius: 14px;
  padding: 10px 14px;
  font-size: 15px;
  color: #0f172a;
  background: #fff;
}

.group-creation-page .group-creation-field input:focus,
.group-creation-page .group-creation-field select:focus {
  outline: none;
  border-color: var(--group-creation-accent);
  box-shadow: 0 0 0 4px var(--group-creation-accent-soft);
}

.group-creation-page .group-creation-radio-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 auto 18px;
}

.group-creation-page .group-creation-radio-grid--stack-left {
  justify-content: center;
  margin: 0 0 8px;
}

.group-creation-page .group-creation-radio {
  position: relative;
}

.group-creation-page .group-creation-radio input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.group-creation-page .group-creation-radio span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 120px;
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: #fff;
  font-size: 16px;
  font-weight: 700;
  color: #334155;
  cursor: pointer;
  transition:
    border-color 0.2s ease,
    background 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease;
}

.group-creation-page .group-creation-radio input:checked + span {
  border-color: var(--group-creation-accent);
  background: var(--group-creation-accent);
  color: #fff;
  box-shadow: 0 8px 18px var(--group-creation-accent-shadow);
}

.group-creation-page .group-creation-type-list,
.group-creation-page .group-creation-avatar-list {
  display: grid;
  gap: 14px;
}

.group-creation-page .group-creation-type-list {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.group-creation-page .group-creation-type-card {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 18px;
  border: 1px solid #dbe4f0;
  border-radius: 20px;
  background: #fff;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    box-shadow 0.18s ease;
}

.group-creation-page .group-creation-type-card:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.28);
  box-shadow: 0 12px 32px rgba(15, 23, 42, 0.08);
}

.group-creation-page .group-creation-type-card.is-selected {
  border-color: var(--group-creation-accent);
  background: var(--group-creation-accent);
  box-shadow: 0 0 0 4px var(--group-creation-accent-soft);
}

.group-creation-page .group-creation-type-card.is-disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: #f8fafc;
}

.group-creation-page .group-creation-type-card img {
  width: 74px;
  height: 74px;
  object-fit: contain;
  flex: 0 0 auto;
}

.group-creation-page .group-creation-type-card-body {
  min-width: 0;
  align-self: flex-start;
}

.group-creation-page .group-creation-type-card-title {
  margin: 0 0 6px;
  font-size: 18px;
  font-weight: 800;
  color: #0f172a;
}

.group-creation-page .group-creation-type-card-description {
  margin: 0;
  color: #64748b;
  font-size: 14px;
  line-height: 1.45;
  white-space: normal;
}

.group-creation-page .group-creation-type-card.is-selected .group-creation-type-card-title,
.group-creation-page .group-creation-type-card.is-selected .group-creation-type-card-description {
  color: #fff;
}

.group-creation-page .group-creation-type-card.is-selected .group-creation-type-card-badge {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.group-creation-page .group-creation-type-card-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 24px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(100, 116, 139, 0.12);
  color: #475569;
  font-size: 11px;
  font-weight: 700;
}

.group-creation-page .group-creation-avatar-section {
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(180px, 0.45fr);
  gap: 16px;
  align-items: flex-start;
}

.group-creation-page .group-creation-step3-layout {
  display: flex;
  flex-direction: column;
  gap: 30px;
}

.group-creation-page .group-creation-step3-heading {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
}

.group-creation-page .group-creation-step3-title {
  margin: 0;
  font-size: 24px;
  font-weight: 800;
  color: #0f172a;
  text-align: center;
}

.group-creation-page .group-creation-step3-subtitle {
  margin: 0 0 4px;
  color: #64748b;
  font-size: 13px;
  line-height: 1.1;
  text-align: center;
}

.group-creation-page .group-creation-avatar-list {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

.group-creation-page .group-creation-avatar-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  border-radius: 0;
  background: transparent;
  cursor: pointer;
  transition:
    opacity 0.18s ease,
    transform 0.18s ease;
}

.group-creation-page .group-creation-avatar-card:hover {
  opacity: 0.92;
  transform: translateY(-2px);
}

.group-creation-page .group-creation-avatar-card.is-selected {
  box-shadow: none;
}

.group-creation-page .group-creation-avatar-card img {
  width: 100px;
  height: 100px;
  border-radius: 18px;
  object-fit: cover;
  background: #f1f5f9;
  transition:
    box-shadow 0.18s ease,
    transform 0.18s ease;
}

.group-creation-page .group-creation-avatar-card.is-selected img {
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.16);
  transform: translateY(-1px) scale(1.12);
}

.group-creation-page .group-creation-avatar-sidebar {
  display: flex;
  flex-direction: column;
  gap: 14px;
  align-items: center;
}

.group-creation-page .group-creation-avatar-preview {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 16px;
  border: 1px dashed #cbd5e1;
  border-radius: 22px;
  background: #f8fafc;
  width: 100%;
  max-width: 180px;
}

.group-creation-page .group-creation-avatar-preview img,
.group-creation-page .group-creation-avatar-preview-placeholder {
  width: 96px;
  height: 96px;
  border-radius: 22px;
  object-fit: cover;
  background: #e2e8f0;
}

.group-creation-page .group-creation-avatar-preview-placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #64748b;
  font-weight: 700;
  text-align: center;
  padding: 12px;
}

.group-creation-page .group-creation-avatar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  width: 100%;
}

.group-creation-page .group-creation-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 10px 16px;
  border-radius: 14px;
  border: 1px solid transparent;
  font-weight: 700;
  cursor: pointer;
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    opacity 0.18s ease;
}

.group-creation-page .group-creation-btn:hover {
  transform: translateY(-1px);
}

.group-creation-page .group-creation-btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.group-creation-page .group-creation-btn--primary {
  background: var(--group-creation-accent);
  color: #fff;
  box-shadow: 0 10px 24px var(--group-creation-accent-shadow);
}

.group-creation-page .group-creation-btn--secondary {
  border-color: #cbd5e1;
  background: #fff;
  color: #334155;
}

.group-creation-page .group-creation-btn--ghost {
  background: rgba(15, 23, 42, 0.04);
  color: #334155;
}

.group-creation-page .group-creation-btn--primary:disabled {
  background: #cbd5e1;
  color: #ffffff;
  box-shadow: none;
  opacity: 1;
}

.group-creation-page .group-creation-step4-panels {
  display: grid;
  gap: 18px;
}

.group-creation-page .group-creation-step4-panel {
  display: none;
  padding: 20px;
  border-radius: 22px;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
}

.group-creation-page .group-creation-step4-panel.is-active {
  display: block;
}

.group-creation-page .group-creation-step4-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(240px, 1fr));
  gap: 28px 42px;
  max-width: 760px;
  margin: 0 auto;
}

.group-creation-page .group-creation-step4-column {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

.group-creation-page .group-creation-step4-column .group-creation-field {
  align-items: center;
}

.group-creation-page .group-creation-step4-column .group-creation-group-label {
  width: 100%;
}

.group-creation-page .group-creation-step4-footer-note {
  max-width: 760px;
  margin: 20px auto 0;
}

.group-creation-page .group-creation-inline-help {
  margin: 0;
  color: #64748b;
  font-size: 13px;
  line-height: 1.45;
}

.group-creation-page .group-creation-inline-help--center {
  text-align: center;
}

.group-creation-page .group-creation-inline-help--tight {
  margin-top: 0;
}

.group-creation-page .group-creation-inline-help--left {
  text-align: left;
  width: 100%;
}

.group-creation-page .group-creation-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 58px;
  padding-top: 40px;
  border-top: 1px solid #e2e8f0;
}

.group-creation-page .group-creation-actions-left,
.group-creation-page .group-creation-actions-right {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.group-creation-page .group-creation-error {
  display: none;
  margin-bottom: 18px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.18);
  color: #b91c1c;
  font-weight: 600;
}

.group-creation-page .group-creation-error.is-visible {
  display: block;
}

.group-creation-page .group-creation-step1-heading {
  margin-bottom: 22px;
}

.group-creation-page .group-creation-hidden {
  display: none !important;
}

.group-creation-page .avatar-crop-container {
  width: 100%;
  min-height: 380px;
  background: #f1f5f9;
  border-radius: 16px;
  overflow: hidden;
}

.group-creation-page .avatar-crop-container img {
  display: block;
  max-width: 100%;
}

.group-creation-ads-hidden {
  width: 0;
  height: 0;
  display: none;
  opacity: 0;
  position: absolute;
  top: -300000px;
  left: -300000px;
}

@media (max-width: 1199.98px) {
  .group-creation-page .group-creation-avatar-section {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 991.98px) {
  .group-creation-page .group-creation-progress {
    flex-wrap: wrap;
    row-gap: 18px;
  }

  .group-creation-page .group-creation-progress-step {
    flex: 0 0 50%;
  }

  .group-creation-page .group-creation-grid,
  .group-creation-page .group-creation-type-list {
    grid-template-columns: minmax(0, 1fr);
  }

  .group-creation-page .group-creation-step4-layout {
    grid-template-columns: minmax(0, 1fr);
    max-width: 420px;
  }

  .group-creation-page .group-creation-avatar-list {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

@media (max-width: 575.98px) {
  .group-creation-page .group-creation-wizard-card {
    padding: 18px;
    border-radius: 20px;
  }

  .group-creation-page .group-creation-progress {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    max-width: 320px;
  }

  .group-creation-page .group-creation-progress-step {
    flex: 1 1 auto;
  }

  .group-creation-page .group-creation-progress-step .group-creation-progress-bar {
    display: none;
  }

  .group-creation-page .group-creation-radio-grid,
  .group-creation-page .group-creation-avatar-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .group-creation-page .group-creation-actions {
    flex-direction: column-reverse;
    align-items: stretch;
  }

  .group-creation-page .group-creation-actions-left,
  .group-creation-page .group-creation-actions-right {
    width: 100%;
    justify-content: stretch;
  }

  .group-creation-page .group-creation-btn {
    width: 100%;
  }
}
