.account-form {
  max-width: 420px;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}
.account-form label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--heading);
}
.account-form input,
.account-form select,
.account-form textarea {
  width: 100%;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
  color: var(--text);
  font: inherit;
}
.account-form textarea {
  min-height: 7rem;
  resize: vertical;
}
.product-editor {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: 2rem;
  align-items: start;
}
.product-list {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}
.product-pick {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  width: 100%;
  padding: 0.65rem 0.75rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: inherit;
  text-align: left;
  cursor: pointer;
  font: inherit;
}
.product-pick.active {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 25%, transparent);
}
.product-pick img {
  width: 52px;
  height: 52px;
  object-fit: cover;
  border-radius: 8px;
  background: #e8eef5;
}
.product-pick strong {
  display: block;
  font-size: 0.92rem;
}
.product-pick span {
  color: var(--muted);
  font-size: 0.8rem;
}
.gallery-admin {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}
.gallery-admin-item {
  width: 88px;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  align-items: center;
}
.gallery-admin-item img {
  width: 88px;
  height: 88px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: #e8eef5;
}
.gallery-admin-item span,
.gallery-admin-item button { font-size: 0.75rem; }
.product-preview {
  width: 100%;
  max-height: 240px;
  object-fit: cover;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #e8eef5;
}
@media (max-width: 800px) {
  .product-editor { grid-template-columns: 1fr; }
}
.account-error { color: #c2410c; font-size: 0.9rem; }
.account-ok { color: var(--accent); font-size: 0.9rem; }
.account-meta { color: var(--muted); margin-bottom: 1.5rem; }
.balance-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 1.4rem 1.5rem;
  margin-bottom: 2rem;
}
.balance-card strong {
  display: block;
  font-size: 2rem;
  color: var(--heading);
  letter-spacing: -0.03em;
}
.account-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0 2rem;
}
.account-table th,
.account-table td {
  text-align: left;
  padding: 0.7rem 0.4rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.92rem;
}
.account-table th { color: var(--muted); font-weight: 600; }
.admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.15rem;
  margin: 1.5rem 0 2rem;
}
.admin-card {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding: 1.25rem 1.3rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  color: inherit;
  text-decoration: none;
}
.admin-card:hover { border-color: var(--accent); }
.admin-card h2 {
  font-size: 1.15rem;
  color: var(--heading);
  margin: 0;
}
.admin-card p {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
  margin: 0;
}
.admin-card-meta {
  margin-top: auto;
  padding-top: 0.7rem;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--heading);
}
.account-switch { margin-top: 1rem; color: var(--muted); }

.account-form.blog-form { max-width: none; }
.blog-editor { align-items: stretch; }
.blog-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.45rem;
  border: 1px solid var(--border);
  border-bottom: 0;
  border-radius: 10px 10px 0 0;
  background: #f4f7fb;
}
.blog-toolbar button {
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.35rem 0.55rem;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--heading);
  cursor: pointer;
}
.blog-toolbar button.is-active {
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, #fff);
  color: var(--accent);
}
.blog-toolbar .spacer { flex: 1; min-width: 0.5rem; }
.tiptap-shell {
  border: 1px solid var(--border);
  border-radius: 0 0 10px 10px;
  background: var(--surface);
  min-height: 22rem;
}
.tiptap-shell .ProseMirror {
  min-height: 22rem;
  padding: 1rem 1.1rem;
  outline: none;
  color: var(--text);
}
.tiptap-shell .ProseMirror p.is-editor-empty:first-child::before {
  content: attr(data-placeholder);
  color: var(--muted);
  float: left;
  height: 0;
  pointer-events: none;
}
#html-source {
  min-height: 22rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.85rem;
  line-height: 1.5;
  border-radius: 0 0 10px 10px;
}
