@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;500;600;700&family=Source+Sans+3:wght@400;500;600;700&display=swap');

body.create-community-page {
  min-height: 100vh;
  background:
    radial-gradient(1000px 420px at 8% -10%, rgba(232, 93, 42, 0.18), transparent 55%),
    radial-gradient(800px 360px at 92% 0%, rgba(45, 212, 191, 0.08), transparent 50%),
    var(--bg-primary, #0e1116);
  color: var(--text-primary, #e8eaed);
  font-family: 'Source Sans 3', system-ui, sans-serif;
}

.create-community-main {
  width: min(1040px, calc(100% - 2rem));
  margin: 1.5rem auto 3rem;
  display: grid;
  gap: 1.25rem;
}

@media (min-width: 900px) {
  .create-community-main {
    grid-template-columns: minmax(0, 1.4fr) minmax(260px, 0.8fr);
    align-items: start;
    margin-top: 2rem;
  }
}

.create-community-panel,
.preview-card {
  background: var(--bg-secondary, #161b22);
  border: 1px solid var(--border-color, #2a3340);
  border-radius: 16px;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
}

.create-community-panel {
  padding: 1.5rem 1.35rem 1.4rem;
}

@media (min-width: 640px) {
  .create-community-panel {
    padding: 2rem;
  }
}

.create-community-hero .eyebrow,
.preview-card .eyebrow {
  margin: 0 0 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #f0a060;
  font-family: Outfit, system-ui, sans-serif;
}

.create-community-hero h1 {
  margin: 0;
  font-family: Outfit, system-ui, sans-serif;
  font-size: clamp(1.75rem, 3vw, 2.35rem);
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.create-community-hero .lede {
  margin: 0.65rem 0 0;
  color: var(--text-secondary, #9aa3af);
  font-size: 1rem;
  line-height: 1.5;
  max-width: 36rem;
}

.create-community-form {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.field label,
.visibility-field legend {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.86rem;
  font-weight: 650;
  color: #d1d5db;
  font-family: Outfit, system-ui, sans-serif;
}

.field .optional {
  color: #6b7280;
  font-weight: 500;
}

.field input,
.field textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--border-color, #2a3340);
  background: var(--bg-tertiary, #1f2630);
  color: inherit;
  font: inherit;
  padding: 0.85rem 1rem;
  outline: none;
}

.field textarea {
  resize: vertical;
  min-height: 110px;
}

.field input:focus,
.field textarea:focus {
  border-color: rgba(232, 93, 42, 0.75);
  box-shadow: 0 0 0 3px rgba(232, 93, 42, 0.16);
}

.slug-row {
  display: flex;
  align-items: stretch;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--border-color, #2a3340);
  background: var(--bg-tertiary, #1f2630);
}

.slug-prefix {
  display: inline-flex;
  align-items: center;
  padding: 0 0.85rem;
  background: rgba(255, 255, 255, 0.04);
  color: #9aa3af;
  font-weight: 650;
  border-right: 1px solid var(--border-color, #2a3340);
}

.slug-row input {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.slug-row:focus-within {
  border-color: rgba(232, 93, 42, 0.75);
  box-shadow: 0 0 0 3px rgba(232, 93, 42, 0.16);
}

.hint {
  margin: 0.4rem 0 0;
  font-size: 0.8rem;
  color: #6b7280;
}

.visibility-field {
  margin: 0;
  padding: 0;
  border: 0;
  display: grid;
  gap: 0.65rem;
}

@media (min-width: 640px) {
  .visibility-field {
    grid-template-columns: 1fr 1fr;
  }
}

.radio-card {
  display: flex;
  gap: 0.7rem;
  align-items: flex-start;
  padding: 0.9rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border-color, #2a3340);
  background: var(--bg-tertiary, #1f2630);
  cursor: pointer;
}

.radio-card:has(input:checked) {
  border-color: rgba(232, 93, 42, 0.7);
  background: rgba(232, 93, 42, 0.1);
}

.radio-card strong {
  display: block;
  font-family: Outfit, system-ui, sans-serif;
}

.radio-card small {
  display: block;
  margin-top: 0.15rem;
  color: #9aa3af;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.7rem;
  margin-top: 0.35rem;
}

.btn-primary,
.btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0 1.15rem;
  border-radius: 999px;
  font-family: Outfit, system-ui, sans-serif;
  font-weight: 650;
  font-size: 0.95rem;
  text-decoration: none;
  border: 0;
  cursor: pointer;
}

.btn-primary {
  background: #e85d2a;
  color: #fff;
}

.btn-primary:hover:not(:disabled) {
  background: #f06d3d;
}

.btn-primary:disabled {
  opacity: 0.65;
  cursor: not-allowed;
}

.btn-secondary {
  background: transparent;
  color: #d1d5db;
  border: 1px solid var(--border-color, #2a3340);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.04);
}

.create-community-aside {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.preview-card {
  padding: 1.25rem;
}

.preview-row {
  display: flex;
  gap: 0.85rem;
  align-items: center;
  margin-top: 0.75rem;
}

.preview-row img {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: #1f2630;
}

.preview-row strong {
  display: block;
  font-family: Outfit, system-ui, sans-serif;
  font-size: 1.05rem;
}

.preview-row span {
  color: #2dd4bf;
  font-size: 0.9rem;
  font-weight: 650;
}

.preview-desc {
  margin: 0.9rem 0 0;
  color: #9aa3af;
  line-height: 1.45;
  font-size: 0.92rem;
}

.tips {
  margin: 0;
  padding: 0 0.25rem 0 1.2rem;
  color: #9aa3af;
  font-size: 0.9rem;
  line-height: 1.55;
}

.create-alert {
  margin-top: 1.1rem;
  border-radius: 12px;
  padding: 0.8rem 0.95rem;
  font-size: 0.9rem;
}

.create-alert.hidden {
  display: none;
}

.create-alert-error {
  background: rgba(248, 113, 113, 0.12);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: #fecaca;
}

.create-alert-ok {
  background: rgba(52, 211, 153, 0.12);
  border: 1px solid rgba(52, 211, 153, 0.35);
  color: #a7f3d0;
}
