* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: system-ui, -apple-system, Arial, sans-serif;
  background: #07111f;
  color: #e6edf3;
  min-height: 100vh;
}

button,
input,
textarea,
select {
  font: inherit;
}

.fi-wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px;
}

.page {
  width: 100%;
}

.post-card {
  background: #101827;
  border: 1px solid #223047;
  border-radius: 18px;
  padding: 16px;
  margin-bottom: 14px;
  box-shadow: 0 14px 35px rgba(0, 0, 0, 0.18);
}

.section-title {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 7px;
}

.section-text {
  font-size: 13px;
  color: #9fb0c3;
  line-height: 1.6;
}

.fi-form-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.fi-form-group {
  margin-top: 4px;
}

.fi-form-label {
  font-size: 13px;
  color: #b8c7d9;
  margin-bottom: 8px;
  font-weight: 700;
}

.fi-dark-input,
.fi-dark-textarea {
  width: 100%;
  background: #07111f;
  border: 1px solid #27364e;
  border-radius: 12px;
  padding: 12px;
  color: #e6edf3;
  font-size: 15px;
  outline: none;
}

.fi-dark-input:focus,
.fi-dark-textarea:focus {
  border-color: #3b82f6;
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.18);
}

.fi-dark-input::placeholder,
.fi-dark-textarea::placeholder {
  color: #6e7f91;
}

.fi-dark-textarea {
  min-height: 150px;
  resize: vertical;
  line-height: 1.7;
}

.top-btn {
  background: #2563eb;
  color: #fff;
  border: none;
  padding: 12px 14px;
  border-radius: 12px;
  cursor: pointer;
  font-size: 15px;
  font-weight: 800;
  width: 100%;
}

.top-btn:hover {
  background: #1d4ed8;
}

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

.fi-models-chooser {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.fi-model-item,
.fi-models-chooser label {
  background: #07111f;
  border: 1px solid #27364e;
  padding: 8px 11px;
  border-radius: 999px;
  font-size: 13px;
  cursor: pointer;
  user-select: none;
}

.fi-model-item:hover,
.fi-models-chooser label:hover {
  border-color: #3b82f6;
}

.fi-model-item input,
.fi-models-chooser input {
  margin-left: 6px;
}

#mediaPreviewBox {
  margin-top: 8px;
  display: grid;
  gap: 10px;
}

#mediaPreviewBox img,
#mediaPreviewBox video {
  width: 100%;
  border-radius: 14px;
  max-height: 360px;
  object-fit: contain;
  background: #020617;
}

.fi-media-preview-item {
  border: 1px solid #223047;
  border-radius: 14px;
  padding: 8px;
  background: #0b1424;
}

.fi-arms-login-page {
  max-width: 460px;
  margin: 60px auto;
  padding: 14px;
}

.fi-arms-login-card {
  padding: 20px;
}

.fi-arms-head-card {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
}

.fi-arms-head-card .top-btn {
  width: auto;
  min-width: 100px;
  margin-top: 0;
}

.fi-arms-publish-page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 14px;
}

.fi-arms-publish-card {
  width: 100%;
}

.fi-muted {
  font-size: 12px;
  color: #6e7f91;
}

.fi-toast {
  box-shadow: 0 14px 40px rgba(0, 0, 0, 0.3);
}

@media (min-width: 900px) {
  .fi-arms-publish-page {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr);
    gap: 16px;
    align-items: start;
  }

  .fi-arms-head-card {
    position: sticky;
    top: 16px;
    display: block;
  }

  .fi-arms-head-card .top-btn {
    width: 100%;
    margin-top: 14px;
  }

  .fi-arms-publish-card {
    padding: 22px;
  }

  .fi-dark-textarea {
    min-height: 220px;
  }
}

@media (max-width: 520px) {
  .fi-wrap,
  .fi-arms-publish-page {
    padding: 10px;
  }

  .post-card {
    border-radius: 16px;
    padding: 14px;
  }

  .section-title {
    font-size: 15px;
  }

  .top-btn {
    font-size: 14px;
  }
}
