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

:root {
  --forum-page: #dda092;
  --forum-panel: #f5e7e2;
  --forum-card: #fffaf8;
  --forum-card-muted: #f9efeb;
  --forum-field: #fffdfc;
  --forum-primary: #8e0e00;
  --forum-primary-deep: #6f0b02;
  --forum-ink: #3e2119;
  --forum-muted: #806159;
  --forum-border: #d9beb7;
  --forum-border-strong: #cfa69c;
  --forum-line: #e3c0b8;
  --forum-success: #695f24;
  --forum-white: #ffffff;
  --forum-shadow: 0 10px 24px rgba(62, 33, 25, 0.1);
}

.prema-forum-route,
.prema-forum-route body {
  background: var(--forum-page) !important;
}

.prema-forum-route body,
.prema-forum-route button,
.prema-forum-route input,
.prema-forum-route select,
.prema-forum-route textarea,
.prema-forum-route [contenteditable="true"] {
  font-family: "DM Sans", Helvetica, Arial, sans-serif !important;
}

.prema-forum-route #main-content {
  background: var(--forum-page) !important;
}

.prema-forum-route .premaforum,
.prema-forum-route .premaforum * {
  box-sizing: border-box;
}

.prema-forum-route .premaforum > .et_pb_section_0 {
  width: 100%;
  height: auto;
  min-height: 0;
  margin: 0 !important;
  padding: 0 !important;
  overflow: visible;
}

.prema-forum-route .premaforum > .et_pb_section_0 .et_pb_fullwidth_image,
.prema-forum-route .premaforum > .et_pb_section_0 .et_pb_image_wrap,
.prema-forum-route .premaforum > .et_pb_section_0 picture,
.prema-forum-route .premaforum > .et_pb_section_0 img {
  display: block;
  width: 100%;
  height: auto;
}

.prema-forum-route .premaforum > .et_pb_section_0 img {
  object-fit: contain;
  object-position: center top;
}

.premaforum-community {
  position: relative;
  z-index: 1;
  width: 100%;
  padding: clamp(32px, 5vw, 84px) clamp(18px, 4vw, 68px) clamp(54px, 7vw, 110px);
  background: var(--forum-page);
}

.premaforum-panel {
  width: min(100%, 1780px);
  margin: 0 auto;
  padding: clamp(22px, 3.5vw, 54px);
  color: var(--forum-ink);
  background: var(--forum-panel);
  border: 1px solid rgba(142, 14, 0, 0.17);
  border-radius: 24px;
  box-shadow: var(--forum-shadow);
  font-family: "DM Sans", Helvetica, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.55;
}

.premaforum-panel button,
.premaforum-panel input,
.premaforum-panel select,
.premaforum-panel textarea {
  font: inherit;
}

.premaforum-panel button {
  margin: 0;
}

.premaforum-topic-form-card h2 {
  margin: 0;
  padding: 0;
  color: var(--forum-ink);
  font-family: "DM Sans", Helvetica, Arial, sans-serif !important;
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.05;
}

.premaforum-status,
.premaforum-empty,
.premaforum-signin-prompt {
  color: var(--forum-muted);
}

.premaforum-status {
  margin: 20px 0;
  padding: 0;
  text-align: center;
}

.premaforum-pending {
  margin: 0 0 34px;
}

.premaforum-pending__label {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0 0 13px;
  color: var(--forum-primary);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.premaforum-pending__label > span:first-child,
.premaforum-signin-prompt > span:first-child {
  display: inline-flex;
}

.premaforum-icon,
.premaforum-pending__label svg,
.premaforum-signin-prompt svg {
  display: block;
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
}

.premaforum-topic-list {
  display: grid;
  gap: 18px;
}

.premaforum-published-divider {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 17px;
  margin: 35px 0 5px;
  color: var(--forum-muted);
  font-size: 13px;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.premaforum-published-divider span {
  height: 1px;
  background: var(--forum-border);
}

.premaforum-topic {
  position: relative;
  overflow: hidden;
  color: var(--forum-ink);
  background: var(--forum-card);
  border: 1px solid var(--forum-border);
  border-radius: 18px;
  box-shadow: 0 4px 14px rgba(62, 33, 25, 0.045);
}

.premaforum-accent {
  position: absolute;
  inset: 0 0 auto;
  z-index: 2;
  height: 4px;
  background: var(--forum-primary);
}

.premaforum-topic__header {
  display: flex;
  align-items: stretch;
  min-height: 92px;
  padding-right: 21px;
  transition: background-color 150ms ease;
}

.premaforum-topic__header:hover,
.premaforum-topic__header:focus-within {
  background: rgba(221, 160, 146, 0.1);
}

.premaforum-topic__toggle {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 16px;
  width: 100%;
  min-width: 0;
  padding: 25px 25px 22px;
  color: var(--forum-ink);
  background: transparent;
  border: 0;
  cursor: pointer;
  text-align: left;
}

.premaforum-topic__toggle:focus-visible,
.premaforum-topic__edit-icon:focus-visible,
.premaforum-control:focus-visible,
.premaforum-reaction:focus-visible,
.premaforum-comment-form__send:focus-visible,
.premaforum-editor__tool:focus-visible,
.premaforum-editor__reference:focus-visible,
.premaforum-add-reference:focus-visible,
.premaforum-reference-field__delete:focus-visible,
.premaforum-submit:focus-visible,
.premaforum-cancel-edit:focus-visible {
  outline: 3px solid rgba(142, 14, 0, 0.3);
  outline-offset: 2px;
}

.premaforum-topic__toggle > svg:last-child {
  color: var(--forum-primary);
}

.premaforum-topic__image {
  display: grid;
  place-items: center;
  width: 64px;
  height: 64px;
  overflow: hidden;
  background: var(--forum-card-muted);
  border: 2px solid transparent;
  border-radius: 50%;
  box-shadow: 0 0 0 4px rgba(221, 160, 146, 0.22);
}

.premaforum-topic__image-media {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  transform: scale(1.09);
}

.premaforum-topic__image--large {
  width: 76px;
  height: 76px;
  flex: 0 0 76px;
}

.premaforum-topic__heading {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.premaforum-pending-topic__heading {
  display: grid;
  min-width: 0;
  gap: 5px;
}

.premaforum-topic__title,
.premaforum-pending-topic__title {
  display: block;
  margin: 0;
  padding: 0;
  color: var(--forum-ink);
  font-family: "DM Sans", Helvetica, Arial, sans-serif !important;
  font-weight: 600;
  letter-spacing: -0.025em;
  line-height: 1.22;
}

.premaforum-topic__title {
  font-size: clamp(20px, 2.1vw, 29px);
}

.premaforum-topic__subtitle,
.premaforum-pending-topic__subtitle {
  display: block;
  margin: 0;
  padding: 0;
  color: var(--forum-muted);
  font-family: "DM Sans", Helvetica, Arial, sans-serif !important;
  font-size: clamp(16px, 1.45vw, 20px);
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.35;
}

.premaforum-topic__edit-icon {
  align-self: center;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin: 0 0 0 4px;
  padding: 0;
  color: var(--forum-primary);
  background: var(--forum-card);
  border: 1px solid var(--forum-border-strong);
  border-radius: 50%;
  cursor: pointer;
  flex: 0 0 auto;
}

.premaforum-topic__edit-icon:hover {
  color: var(--forum-white);
  background: var(--forum-primary);
  border-color: var(--forum-primary);
}

.premaforum-topic__edit-icon svg {
  width: 19px;
  height: 19px;
}

.premaforum-topic__panel {
  border-top: 0;
}

.premaforum-topic__content {
  min-width: 0;
  max-width: 100%;
  margin: 0;
  padding: 28px clamp(26px, 4vw, 62px);
  color: var(--forum-ink);
  font-size: clamp(15px, 1.08vw, 17px);
  line-height: 1.62;
  overflow-wrap: anywhere;
}

.premaforum-topic__content p {
  margin: 0 0 1em;
  padding: 0;
}

.premaforum-topic__content p:last-child {
  margin-bottom: 0;
}

.premaforum-topic__content ul,
.premaforum-topic__content ol {
  margin: 0 0 1em 1.5em;
  padding: 0;
}

.premaforum-topic__content ul { list-style: disc; }
.premaforum-topic__content ol { list-style: decimal; }

.premaforum-topic__content a,
.premaforum-reference a,
.premaforum-signin-prompt a,
.premaforum-comment-gate a {
  color: var(--forum-primary);
  font-weight: 650;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.premaforum-topic__content a:has(> sup),
.premaforum-editor__input a:has(> sup) {
  text-decoration: none;
}

/* Keep inline reference markers visually superscript without enlarging the line box. */
.premaforum-topic__content a > sup,
.premaforum-editor__input a > sup {
  position: relative;
  bottom: 0.5em;
  height: auto;
  font-size: 0.72em;
  line-height: 0;
  vertical-align: baseline;
}

.premaforum-topic__content img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 22px auto;
  border-radius: 12px;
}

.premaforum-topic__body-image {
  width: min(100%, 840px);
  aspect-ratio: 16 / 9;
  margin: 1.15em auto 1.65em;
  overflow: hidden;
  background: var(--forum-card-muted);
  border-radius: 14px;
}

.premaforum-topic__content .premaforum-topic__body-image-media {
  display: block;
  width: 100%;
  max-width: none;
  height: 100%;
  margin: 0;
  object-fit: cover;
  object-position: center;
  border-radius: 0;
}

.premaforum-poll-option {
  display: inline-flex;
  position: relative;
  align-items: flex-start;
  gap: 0;
  max-width: 100%;
  margin-right: 0.2em;
  color: inherit;
  line-height: normal;
  vertical-align: baseline;
}

.premaforum-poll-option__text,
.premaforum-editor__input [data-poll-id] {
  display: inline-block;
  max-width: 100%;
  padding: 0.1em 0.26em 0.2em;
  color: inherit;
  background: rgba(221, 160, 146, 0.42);
  border: 0;
  border-radius: 0.3em;
  box-shadow: none;
  line-height: 1.35;
  overflow: visible;
  vertical-align: middle;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
}

.premaforum-poll-option__text {
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}

.premaforum-poll-option[role="button"] {
  cursor: pointer;
  transition: color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.premaforum-poll-option[role="button"]:hover .premaforum-poll-option__text,
.premaforum-poll-option[role="button"]:focus-visible .premaforum-poll-option__text,
.premaforum-poll-option.is-selected .premaforum-poll-option__text {
  color: var(--forum-primary-deep);
  background: rgba(221, 160, 146, 0.64);
  border: 0;
  box-shadow: none;
}

.premaforum-poll-option[role="button"]:focus-visible {
  outline: 0;
}

.premaforum-poll-option[role="button"]:focus-visible .premaforum-poll-option__text {
  outline: 2px solid rgba(142, 14, 0, 0.42);
  outline-offset: 2px;
}

.premaforum-poll-option.is-busy { opacity: 0.62; }

.premaforum-poll-option__count {
  display: inline-flex;
  position: relative;
  top: -0.58em;
  z-index: 1;
  align-items: center;
  justify-content: center;
  width: auto;
  min-width: 1.55em;
  height: 1.55em;
  flex: 0 0 auto;
  margin-left: -0.12em;
  padding: 0 0.28em;
  color: #fff;
  background: #171412;
  border: 1px solid #171412;
  border-radius: 0.3em;
  box-shadow: 0 0 0 2px var(--forum-field);
  box-sizing: border-box;
  font-size: 0.62em;
  font-weight: 750;
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}

.premaforum-poll-option[role="button"]:hover .premaforum-poll-option__count,
.premaforum-poll-option[role="button"]:focus-visible .premaforum-poll-option__count,
.premaforum-poll-option.is-selected .premaforum-poll-option__count {
  color: #fff;
  background: #171412;
  border-color: #171412;
  box-shadow: 0 0 0 2px var(--forum-field), 0 1px 2px rgba(73, 34, 26, 0.15);
}

.premaforum-topic__content table,
.premaforum-editor__input table {
  width: 100%;
  margin: 18px 0;
  border-collapse: collapse;
}

.premaforum-topic__content {
  overflow-x: visible;
}

.premaforum-editor__input {
  overflow-x: auto;
}

.premaforum-topic__content table[data-table-size-locked="true"] {
  width: 100% !important;
  max-width: 100%;
  table-layout: fixed;
}

.premaforum-editor__input table[data-table-size-locked="true"] {
  max-width: none;
  table-layout: fixed;
}

.premaforum-topic__content [data-fixed-cell="true"] {
  height: auto !important;
  overflow: visible !important;
  overflow-wrap: anywhere;
  word-break: normal;
}

.premaforum-editor__input [data-fixed-cell="true"] {
  overflow: auto;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.premaforum-topic__content [data-fixed-cell="true"]:has(.premaforum-poll-option) {
  min-height: 32px;
  height: auto !important;
  overflow: visible !important;
}

.premaforum-topic__content .premaforum-table-row--poll,
.premaforum-topic__content .premaforum-table-cell--poll {
  height: auto !important;
}

.premaforum-topic__content .premaforum-table-cell--poll {
  overflow: visible !important;
  vertical-align: middle;
}

.premaforum-topic__content .premaforum-fixed-cell--poll {
  min-height: 46px !important;
  height: auto !important;
  padding-block: 4px;
  overflow: visible !important;
}

.premaforum-topic__content td,
.premaforum-topic__content th {
  min-width: 0;
  overflow: visible;
  overflow-wrap: anywhere;
  word-break: normal;
}

.premaforum-topic__content td,
.premaforum-topic__content th,
.premaforum-editor__input td,
.premaforum-editor__input th {
  padding: 10px 12px;
  border: 1px solid var(--forum-border-strong);
  text-align: left;
}

.premaforum-editor__input table[data-editor-table-selected="true"] {
  outline: 3px solid var(--forum-primary);
  outline-offset: 4px;
}

.premaforum-table-selector,
.premaforum-table-resizer {
  position: absolute;
  z-index: 7;
}

.premaforum-table-selector[hidden],
.premaforum-table-resizer[hidden] {
  display: none !important;
}

.premaforum-table-selector {
  display: grid;
  place-items: center;
  width: 28px;
  height: 28px;
  padding: 0;
  color: var(--forum-white);
  background: var(--forum-primary);
  border: 2px solid var(--forum-field);
  border-radius: 7px;
  box-shadow: 0 2px 8px rgba(62, 33, 25, 0.2);
  cursor: pointer;
  transform: translate(-50%, -50%);
}

.premaforum-table-selector:hover,
.premaforum-table-selector:focus-visible {
  background: var(--forum-primary-deep);
  outline: 2px solid rgba(142, 14, 0, 0.28);
  outline-offset: 2px;
}

.premaforum-table-selector svg {
  width: 16px;
  height: 16px;
}

.premaforum-table-resizer {
  display: block;
  padding: 0;
  background: transparent;
  touch-action: none;
}

.premaforum-table-resizer::after {
  position: absolute;
  content: "";
  background: var(--forum-primary);
  opacity: 0.46;
  transition: opacity 120ms ease, box-shadow 120ms ease;
}

.premaforum-table-resizer:hover::after,
.premaforum-is-table-resizing .premaforum-table-resizer::after {
  opacity: 1;
  box-shadow: 0 0 0 2px rgba(142, 14, 0, 0.12);
}

.premaforum-table-resizer--column {
  width: 12px;
  cursor: col-resize;
}

.premaforum-table-resizer--column::after {
  inset: 0 auto 0 5px;
  width: 2px;
}

.premaforum-table-resizer--row {
  height: 12px;
  cursor: row-resize;
}

.premaforum-table-resizer--row::after {
  inset: 5px 0 auto;
  height: 2px;
}

body.premaforum-is-table-resizing {
  user-select: none;
}

body.premaforum-is-table-resizing--column,
body.premaforum-is-table-resizing--column * {
  cursor: col-resize !important;
}

body.premaforum-is-table-resizing--row,
body.premaforum-is-table-resizing--row * {
  cursor: row-resize !important;
}

.premaforum-references {
  margin: 0 clamp(26px, 4vw, 62px);
  padding: 25px 0 23px;
  color: var(--forum-muted);
  border-top: 1px solid var(--forum-border);
  font-size: 14px;
}

.premaforum-references__heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 13px;
  padding: 0;
  color: var(--forum-ink);
}

.premaforum-references__heading svg {
  width: 17px;
  height: 17px;
  color: var(--forum-primary);
}

.premaforum-reference {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 9px;
  margin: 7px 0;
  scroll-margin-top: 120px;
  overflow-wrap: anywhere;
}

.premaforum-reference strong { color: var(--forum-primary); }

.premaforum-topic__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin: 0 clamp(26px, 4vw, 62px);
  padding: 19px 0 22px;
  border-top: 1px solid var(--forum-border);
}

.premaforum-identity {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 8px 15px;
  color: var(--forum-muted);
  font-size: 14px;
}

.premaforum-identity strong {
  color: var(--forum-ink);
  font-weight: 700;
}

.premaforum-topic__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.premaforum-reactions {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.premaforum-reaction {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  color: var(--forum-ink);
  background: var(--forum-field);
  border: 1px solid var(--forum-border-strong);
  border-radius: 999px;
  cursor: pointer;
  line-height: 1;
  transition: transform 150ms ease, border-color 150ms ease, background 150ms ease;
}

.premaforum-reaction:not(:disabled):hover { transform: scale(1.06); }

.premaforum-reaction.is-selected {
  background: rgba(142, 14, 0, 0.08);
  border-color: var(--forum-primary);
}

.premaforum-reaction:disabled {
  cursor: default;
  opacity: 0.58;
}

.premaforum-reaction__emoji { font-size: 15px; }

.premaforum-reaction__count {
  color: var(--forum-muted);
  font-size: 11px;
  font-weight: 700;
}

.premaforum-control {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 38px;
  padding: 7px 14px;
  color: var(--forum-ink);
  background: transparent;
  border: 1px solid var(--forum-border-strong);
  border-radius: 999px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.premaforum-control:hover {
  color: var(--forum-white);
  background: var(--forum-ink);
  border-color: var(--forum-ink);
}

.premaforum-control svg { width: 16px; height: 16px; }

.premaforum-control--danger {
  color: var(--forum-primary);
  border-color: var(--forum-primary);
}

.premaforum-control--danger:hover {
  background: var(--forum-primary);
  border-color: var(--forum-primary);
}

.premaforum-control--approve {
  color: var(--forum-success);
  border-color: rgba(105, 95, 36, 0.55);
}

.premaforum-control--approve:hover {
  background: var(--forum-success);
  border-color: var(--forum-success);
}

.premaforum-control--comments {
  min-width: 52px;
  padding-inline: 12px;
  background: rgba(221, 160, 146, 0.2);
}

.premaforum-new-comment {
  position: absolute;
  top: 3px;
  right: 4px;
  width: 7px;
  height: 7px;
  background: var(--forum-primary);
  border: 1px solid var(--forum-card);
  border-radius: 50%;
}

.premaforum-comments {
  background: var(--forum-card);
  border-top: 1px solid var(--forum-border);
}

.premaforum-comments__list {
  display: grid;
  gap: 10px;
  padding: 18px clamp(26px, 4vw, 62px) 0;
}

.premaforum-comment {
  display: grid;
  grid-template-columns: 42px minmax(0, 1fr);
  gap: 13px;
  padding: 14px;
  background: var(--forum-card-muted);
  border: 1px solid rgba(207, 166, 156, 0.55);
  border-radius: 13px;
}

.premaforum-comment--reply {
  margin-left: min(calc(var(--comment-depth, 1) * 30px), 90px);
  border-left: 3px solid rgba(160, 29, 17, 0.42);
}

.premaforum-comment__content { min-width: 0; }

.premaforum-comment__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.premaforum-comment__actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 6px;
}

.premaforum-comment__reply-context {
  margin: 5px 0 0;
  color: var(--forum-primary);
  font-size: 12px;
  font-weight: 700;
}

.premaforum-comment__body {
  margin: 7px 0 0;
  padding: 0;
  color: var(--forum-ink);
  font-size: 15px;
  line-height: 1.58;
  overflow-wrap: anywhere;
}

.premaforum-avatar {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  object-fit: cover;
  color: var(--forum-primary);
  background: rgba(221, 160, 146, 0.3);
  border: 0;
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  font-style: normal;
}

.premaforum-avatar--large {
  width: 52px;
  height: 52px;
  flex-basis: 52px;
  font-size: 15px;
}

.premaforum-comments__empty,
.premaforum-comment-gate {
  margin: 0;
  color: var(--forum-muted);
  font-size: 14px;
}

.premaforum-comments__empty {
  padding: 4px 0;
  font-style: italic;
  text-align: left;
}

.premaforum-comment-gate {
  padding: 18px clamp(26px, 4vw, 62px) 22px;
  text-align: center;
}

.premaforum-comment-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 48px;
  align-items: end;
  gap: 12px;
  padding: 16px clamp(26px, 4vw, 62px) 24px;
}

.premaforum-comment-form__replying {
  display: flex;
  grid-column: 1 / -1;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
  padding: 9px 13px;
  color: var(--forum-ink);
  background: rgba(221, 160, 146, 0.2);
  border-left: 3px solid var(--forum-primary);
  border-radius: 9px;
  font-size: 13px;
  font-weight: 700;
}

.premaforum-comment-form__cancel-reply {
  flex: 0 0 auto;
  padding: 3px 0;
  color: var(--forum-primary);
  background: transparent;
  border: 0;
  font: inherit;
  cursor: pointer;
}

.premaforum-comment-form__cancel-reply:hover,
.premaforum-comment-form__cancel-reply:focus-visible {
  text-decoration: underline;
}

.premaforum-comment-form__field {
  display: block;
  min-width: 0;
  padding: 12px 16px;
  background: var(--forum-field);
  border: 1px solid var(--forum-border-strong);
  border-radius: 20px;
}

.premaforum-comment-form textarea {
  display: block;
  width: 100%;
  min-height: 72px;
  max-height: 130px;
  padding: 0;
  resize: vertical;
  color: var(--forum-ink);
  background: transparent;
  border: 0;
  outline: 0;
  line-height: 1.45;
}

.premaforum-comment-form textarea::placeholder,
.premaforum-field input::placeholder,
.premaforum-reference-field input::placeholder {
  color: #a0857e;
  opacity: 1;
}

.premaforum-comment-form__send {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  padding: 0;
  color: var(--forum-white);
  background: var(--forum-primary);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}

.premaforum-comment-form__send svg { width: 19px; height: 19px; }

.premaforum-control--comment-reply,
.premaforum-control--comment-delete {
  min-height: 28px;
  padding: 5px 9px;
  color: var(--forum-muted);
  background: transparent;
  font-size: 11px;
}

.premaforum-control--comment-reply {
  color: var(--forum-primary);
}

.premaforum-control--comment-reply.is-selected {
  color: var(--forum-white);
  background: var(--forum-primary);
  border-color: var(--forum-primary);
}

.premaforum-control--comment-reply svg,
.premaforum-control--comment-delete svg {
  width: 13px;
  height: 13px;
}

.premaforum-comment-form__send:disabled,
.premaforum-submit:disabled {
  cursor: not-allowed;
  opacity: 0.4;
}

.premaforum-topic--pending { border-color: var(--forum-border-strong); }

.premaforum-pending-topic__content {
  padding: 28px clamp(26px, 4vw, 62px) 0;
}

.premaforum-pending-topic__header {
  display: flex;
  align-items: center;
  gap: 20px;
}

.premaforum-pending-topic__title { font-size: clamp(22px, 2.2vw, 31px); }

.premaforum-pending-topic__content > .premaforum-topic__content { padding: 24px 0; }

.premaforum-pending-topic__content > .premaforum-references,
.premaforum-pending-topic__content > .premaforum-topic__footer { margin-inline: 0; }

.premaforum-empty {
  display: grid;
  place-items: center;
  gap: 12px;
  padding: 45px 20px;
  text-align: center;
}

.premaforum-empty__icon {
  width: 36px;
  height: 36px;
  color: var(--forum-primary);
}

.premaforum-empty p { margin: 0; padding: 0; }

.premaforum-topic-form-card {
  position: relative;
  overflow: hidden;
  margin: 36px 0 0;
  padding: clamp(27px, 4vw, 52px);
  background: var(--forum-card);
  border: 1px solid var(--forum-border);
  border-radius: 18px;
  box-shadow: 0 4px 14px rgba(62, 33, 25, 0.045);
}

.premaforum-topic--editing {
  overflow: visible;
  scroll-margin-top: 110px;
}

.premaforum-topic-form-heading {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.premaforum-topic-form-card > .premaforum-topic-form-heading {
  margin-bottom: 26px;
}

.premaforum-topic--editing > .premaforum-topic-form-heading {
  padding: 28px clamp(26px, 4vw, 62px) 22px;
  border-bottom: 1px solid var(--forum-border);
}

.premaforum-topic-form-heading__copy { min-width: 0; }

.premaforum-topic-form-heading h2,
.premaforum-topic-form-card__hint {
  margin: 0;
  padding: 0;
  font-family: "DM Sans", Helvetica, Arial, sans-serif !important;
}

.premaforum-topic-form-heading h2 {
  color: var(--forum-ink);
  font-size: clamp(29px, 3.2vw, 45px);
  font-weight: 700;
  letter-spacing: -0.035em;
}

.premaforum-topic-form-card__hint {
  margin-top: 4px;
  color: var(--forum-muted);
  font-size: 14px;
}

.premaforum-topic--editing > .premaforum-topic-form {
  padding: 24px clamp(26px, 4vw, 62px) 28px;
}

.premaforum-signin-prompt {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
  padding: 20px 22px;
  background: var(--forum-card-muted);
  border: 1px solid var(--forum-border);
  border-radius: 13px;
}

.premaforum-signin-prompt p { margin: 0; padding: 0; }

.premaforum-topic-form {
  display: grid;
  gap: 16px;
}

.premaforum-field {
  display: grid;
  gap: 8px;
  min-width: 0;
  color: var(--forum-ink);
  font-size: 14px;
  font-weight: 700;
}

.premaforum-field__label-with-icon {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.premaforum-content-label {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.premaforum-content-label small {
  color: var(--forum-primary);
  font-size: 12px;
  font-weight: 600;
}

.premaforum-topic-image-control { flex: 0 0 auto; }

.premaforum-topic-image-picker {
  position: relative;
  display: grid;
  place-items: center;
  width: 72px;
  height: 72px;
  flex: 0 0 72px;
  padding: 0;
  overflow: hidden;
  color: var(--forum-primary);
  background: rgba(221, 160, 146, 0.2);
  border: 2px dashed var(--forum-primary);
  border-radius: 50%;
  cursor: pointer;
}

.premaforum-topic-image-picker.has-image {
  border-color: transparent;
  border-style: solid;
  box-shadow: 0 0 0 4px rgba(221, 160, 146, 0.2);
}

.premaforum-topic-image-picker:disabled {
  cursor: default;
  opacity: 0.78;
}

.premaforum-topic-image-picker:focus-visible {
  outline: 3px solid rgba(142, 14, 0, 0.3);
  outline-offset: 2px;
}

.premaforum-topic-image-placeholder {
  font-size: 29px;
  font-weight: 500;
  line-height: 1;
}

.premaforum-topic-image-preview {
  display: block;
  width: 100%;
  height: 100%;
  max-width: none;
  object-fit: cover;
  object-position: center;
  transform: scale(1.09);
}

.premaforum-topic-image-preview.is-default-logo,
.premaforum-topic__image-media.is-default-logo {
  padding: 0;
  background: #8c605a;
  object-fit: contain;
  transform: translateY(3px) scale(1.35);
}

.premaforum-topic-image-edit {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  color: var(--forum-white);
  background: rgba(62, 33, 25, 0.56);
  opacity: 0;
  pointer-events: none;
  transition: opacity 160ms ease;
}

.premaforum-topic-image-edit .premaforum-editor__icon {
  width: 27px;
  height: 27px;
}

.premaforum-topic-image-picker.has-image:not(:disabled):hover .premaforum-topic-image-edit,
.premaforum-topic-image-picker.has-image:not(:disabled):focus-visible .premaforum-topic-image-edit {
  opacity: 1;
}

.premaforum-field__label-with-icon i {
  display: inline-flex;
  font-style: normal;
}

.premaforum-field__label-with-icon svg {
  width: 17px;
  height: 17px;
  color: var(--forum-primary);
}

.premaforum-field input,
.premaforum-field select,
.premaforum-reference-field input {
  width: 100%;
  min-height: 50px;
  padding: 12px 15px;
  color: var(--forum-ink);
  background: var(--forum-field);
  border: 1px solid var(--forum-border-strong);
  border-radius: 11px;
  outline: 0;
  font-size: 15px;
  font-weight: 500;
}

.premaforum-field input:focus,
.premaforum-field select:focus,
.premaforum-reference-field input:focus,
.premaforum-editor:focus-within {
  border-color: var(--forum-primary);
  box-shadow: 0 0 0 3px rgba(142, 14, 0, 0.1);
}

.premaforum-editor {
  position: relative;
  overflow: visible;
  background: var(--forum-field);
  border: 1px solid var(--forum-border-strong);
  border-radius: 12px;
}

.premaforum-editor__toolbar {
  position: relative;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  padding: 7px;
  background: var(--forum-card-muted);
  border-bottom: 1px solid var(--forum-border);
  border-radius: 11px 11px 0 0;
}

.premaforum-editor__tool,
.premaforum-editor__reference {
  display: inline-grid;
  place-items: center;
  width: 34px;
  min-width: 34px;
  height: 34px;
  padding: 0;
  color: var(--forum-ink);
  background: transparent;
  border: 0;
  border-radius: 50%;
  cursor: pointer;
}

.premaforum-editor__icon {
  display: block;
  width: 18px;
  height: 18px;
  pointer-events: none;
}

.premaforum-editor__tool:hover,
.premaforum-editor__reference:hover {
  color: var(--forum-white);
  background: var(--forum-primary);
}

.premaforum-editor__tool:disabled,
.premaforum-editor__tool:disabled:hover {
  color: var(--forum-muted);
  background: transparent;
  cursor: not-allowed;
  opacity: 0.38;
}

.premaforum-editor__tool.is-active {
  color: var(--forum-white);
  background: var(--forum-primary);
}

.premaforum-editor__reference {
  margin-left: auto;
}

.premaforum-editor__reference svg { width: 18px; height: 18px; }

.premaforum-editor__table-menu {
  order: 20;
  display: flex;
  flex: 1 0 100%;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  margin-top: 3px;
  padding: 8px 2px 1px;
  border-top: 1px solid var(--forum-border);
}

.premaforum-editor__table-menu[hidden] {
  display: none;
}

.premaforum-editor__table-tool {
  color: var(--forum-primary);
}

.premaforum-editor__body { position: relative; }

.premaforum-editor__input {
  position: relative;
  z-index: 1;
  min-height: 190px;
  padding: 17px;
  color: var(--forum-ink);
  outline: 0;
  font-size: 15px;
  font-weight: 400;
  line-height: 1.62;
}

.premaforum-editor__input p { margin: 0 0 0.8em; padding: 0; }

.premaforum-editor__input ul,
.premaforum-editor__input ol {
  margin: 0 0 0.8em 1.55em;
  padding: 0;
}

.premaforum-editor__input ul { list-style: disc outside; }
.premaforum-editor__input ol { list-style: decimal outside; }
.premaforum-editor__input li { margin: 0.18em 0; padding-left: 0.15em; }

.premaforum-editor__input [data-poll-id] {
  cursor: text;
}

.premaforum-editor__placeholder {
  position: absolute;
  top: 17px;
  left: 17px;
  z-index: 0;
  max-width: calc(100% - 34px);
  color: #a0857e;
  font-size: 15px;
  font-weight: 400;
  pointer-events: none;
}

.premaforum-editor__reference-menu {
  position: absolute;
  top: calc(100% - 4px);
  right: 7px;
  z-index: 20;
  width: min(300px, calc(100vw - 72px));
  max-height: 250px;
  overflow: auto;
  padding: 6px;
  background: var(--forum-card);
  border: 1px solid var(--forum-border-strong);
  border-radius: 10px;
  box-shadow: 0 12px 30px rgba(62, 33, 25, 0.18);
}

.premaforum-editor__emoji-menu {
  position: absolute;
  top: calc(100% - 4px);
  right: 50px;
  z-index: 21;
  display: grid;
  grid-template-columns: repeat(6, 38px);
  gap: 4px;
  width: max-content;
  max-width: calc(100vw - 72px);
  padding: 8px;
  background: var(--forum-card);
  border: 1px solid var(--forum-border-strong);
  border-radius: 12px;
  box-shadow: 0 12px 30px rgba(62, 33, 25, 0.18);
}

.premaforum-editor__emoji-menu[hidden] { display: none; }

.premaforum-editor__emoji-option {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: 9px;
  cursor: pointer;
  font-size: 21px;
  line-height: 1;
}

.premaforum-editor__emoji-option:hover,
.premaforum-editor__emoji-option:focus-visible {
  background: rgba(221, 160, 146, 0.24);
  outline: none;
}

@media (max-width: 480px) {
  .premaforum-editor__emoji-menu {
    right: 7px;
    grid-template-columns: repeat(4, 38px);
  }
}

.premaforum-reference-menu__item {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  min-height: 40px;
  padding: 7px 9px;
  color: var(--forum-ink);
  background: transparent;
  border: 0;
  border-radius: 7px;
  cursor: pointer;
  text-align: left;
  font-size: 13px;
}

.premaforum-reference-menu__item:hover { background: rgba(221, 160, 146, 0.2); }

.premaforum-reference-menu__item svg,
.premaforum-reference-menu__number {
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
}

.premaforum-reference-menu__number {
  display: grid;
  place-items: center;
  color: var(--forum-white);
  background: var(--forum-primary);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 700;
}

.premaforum-reference-menu__name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.premaforum-reference-list {
  display: grid;
  gap: 12px;
}

.premaforum-reference-section > .premaforum-field__label-with-icon {
  font-size: 16px;
}

.premaforum-reference-empty {
  margin: 0;
  padding: 16px 20px;
  color: var(--forum-muted);
  background: var(--forum-field);
  border: 1px dashed var(--forum-border-strong);
  border-radius: 1.4rem;
  font-size: 14px;
  font-weight: 400;
}

.premaforum-reference-field {
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) minmax(0, 1fr) 40px;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: var(--forum-field);
  border: 1px solid var(--forum-border-strong);
  border-radius: 1.4rem;
}

.premaforum-reference-field__number {
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  color: var(--forum-primary);
  background: rgba(142, 14, 0, 0.12);
  border-radius: 50%;
  font-size: 14px;
  font-weight: 700;
}

.premaforum-reference-field input {
  min-height: 40px;
  height: 40px;
  padding: 0 16px;
  background: transparent;
  border-radius: 999px;
  font-size: 14px;
}

.premaforum-reference-field__delete {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  padding: 0;
  color: var(--forum-primary);
  background: transparent;
  border: 1px solid var(--forum-border-strong);
  border-radius: 50%;
  cursor: pointer;
}

.premaforum-reference-field__delete:hover {
  color: var(--forum-white);
  background: var(--forum-primary);
  border-color: var(--forum-primary);
}

.premaforum-reference-field__delete svg { width: 16px; height: 16px; }

.premaforum-add-reference {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: max-content;
  margin-top: 12px !important;
  padding: 8px 16px;
  color: var(--forum-primary);
  background: rgba(142, 14, 0, 0.12);
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 700;
}

.premaforum-add-reference:hover {
  background: rgba(142, 14, 0, 0.18);
}

.premaforum-add-reference span { display: inline-flex; }
.premaforum-add-reference svg { width: 17px; height: 17px; }

.premaforum-posting-as {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 58px;
  padding: 12px 20px;
  color: var(--forum-ink);
  background: var(--forum-card-muted);
  border: 0;
  border-radius: 1.4rem;
  font-size: 14px;
}

.premaforum-posting-as__label {
  margin-right: 2px;
  color: var(--forum-muted);
}

.premaforum-posting-as .premaforum-avatar {
  width: 34px;
  height: 34px;
  flex-basis: 34px;
  font-size: 0.85rem;
}

.premaforum-posting-as > strong {
  font-size: 16px;
  font-weight: 600;
}

.premaforum-admin-badge {
  padding: 3px 8px;
  color: var(--forum-primary);
  background: rgba(221, 160, 146, 0.22);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
}

.premaforum-form-message {
  margin: 0;
  padding: 12px 15px;
  color: var(--forum-primary);
  background: rgba(142, 14, 0, 0.07);
  border-radius: 9px;
  font-size: 13px;
  font-weight: 600;
}

.premaforum-submit {
  width: 100%;
  height: 48px;
  min-height: 48px;
  padding: 0 22px;
  color: var(--forum-white);
  background: var(--forum-primary);
  border: 0;
  border-radius: 1.4rem;
  box-shadow: 0 1px 2px rgba(62, 33, 25, 0.12);
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.025em;
}

.premaforum-form-actions {
  display: grid;
  gap: 8px;
}

.premaforum-topic--editing .premaforum-form-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 9px;
}

.premaforum-inline-community {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
}

.premaforum-topic--editing .premaforum-submit {
  width: auto;
  min-height: 40px;
  padding: 8px 16px;
  font-size: 13px;
}

.premaforum-topic--editing .premaforum-cancel-edit {
  justify-self: auto;
  min-height: 40px;
  padding: 8px 16px;
  color: var(--forum-ink);
  border: 1px solid var(--forum-border-strong);
  border-radius: 999px;
  text-decoration: none;
}

.premaforum-submit:not(:disabled):hover {
  background: var(--forum-primary-deep);
  border-color: var(--forum-primary-deep);
}

.premaforum-cancel-edit {
  justify-self: center;
  padding: 7px 12px;
  color: var(--forum-primary);
  background: transparent;
  border: 0;
  cursor: pointer;
  font-size: 13px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.premaforum-toast {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 100003;
  max-width: min(390px, calc(100vw - 32px));
  padding: 13px 18px;
  color: var(--forum-white);
  background: var(--forum-ink);
  border-radius: 10px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 180ms ease, transform 180ms ease;
  font-family: "DM Sans", Helvetica, Arial, sans-serif;
  font-size: 14px;
}

.premaforum-toast.is-error { background: var(--forum-primary); }

.premaforum-toast.is-visible {
  opacity: 1;
  transform: translateY(0);
}

[hidden] { display: none !important; }

@media (max-width: 780px) {
  .premaforum-community { padding: 22px 10px 48px; }

  .premaforum-panel {
    padding: 16px 10px 22px;
    border-radius: 18px;
  }

  .premaforum-topic-list { gap: 13px; }

  .premaforum-topic,
  .premaforum-topic-form-card { border-radius: 15px; }

  .premaforum-topic__header {
    min-height: 84px;
    padding-right: 16px;
  }

  .premaforum-topic__toggle {
    grid-template-columns: 52px minmax(0, 1fr) 18px;
    gap: 10px;
    padding: 20px 13px 18px;
  }

  .premaforum-topic__image {
    width: 52px;
    height: 52px;
  }

  .premaforum-topic__image--large {
    width: 60px;
    height: 60px;
    flex-basis: 60px;
  }

  .premaforum-pending-topic__header { gap: 13px; }

  .premaforum-topic__edit-icon {
    width: 38px;
    height: 38px;
  }

  .premaforum-topic__title { font-size: 18px; }
  .premaforum-topic__content,
  .premaforum-comment-form,
  .premaforum-pending-topic__content {
    padding-left: 17px;
    padding-right: 17px;
  }

  .premaforum-topic__content { font-size: 15px; }

  .premaforum-references,
  .premaforum-topic__footer {
    margin-left: 17px;
    margin-right: 17px;
  }

  .premaforum-topic__footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .premaforum-topic__actions {
    width: 100%;
    justify-content: flex-start;
  }

  .premaforum-comment {
    grid-template-columns: 36px minmax(0, 1fr);
    gap: 11px;
  }

  .premaforum-comment--reply {
    margin-left: min(calc(var(--comment-depth, 1) * 14px), 42px);
  }

  .premaforum-comment__header {
    align-items: flex-start;
    flex-direction: column;
  }

  .premaforum-avatar {
    width: 36px;
    height: 36px;
    flex-basis: 36px;
  }

  .premaforum-comment-form {
    grid-template-columns: minmax(0, 1fr) 40px;
    gap: 9px;
  }

  .premaforum-comment-form__field {
    padding: 11px 13px;
  }

  .premaforum-comment-form__send { width: 40px; height: 40px; }

  .premaforum-comments__list {
    padding-left: 17px;
    padding-right: 17px;
  }

  .premaforum-topic--editing > .premaforum-topic-form-heading {
    gap: 13px;
    padding: 22px 17px 18px;
  }

  .premaforum-topic--editing > .premaforum-topic-form {
    padding: 20px 17px 23px;
  }

  .premaforum-topic--editing .premaforum-form-actions {
    justify-content: flex-start;
  }

  .premaforum-inline-community {
    width: 100%;
  }

  .premaforum-topic-form-card {
    margin-top: 23px;
    padding: 27px 15px 22px;
  }

  .premaforum-topic-image-picker {
    width: 62px;
    height: 62px;
    flex-basis: 62px;
  }

  .premaforum-reference-field {
    grid-template-columns: 36px minmax(0, 1fr) 40px;
    gap: 9px;
  }

  .premaforum-reference-field input:nth-of-type(2) { grid-column: 2 / 3; }

  .premaforum-reference-field__delete {
    grid-column: 3;
    grid-row: 1 / 3;
  }

  .premaforum-reference-field__number { grid-row: 1 / 3; }

  .premaforum-reference-empty { padding: 14px 16px; }

  .premaforum-posting-as {
    gap: 10px;
    padding: 11px 16px;
  }

  .premaforum-editor__tool,
  .premaforum-editor__reference {
    width: 32px;
    min-width: 32px;
    height: 32px;
    padding: 0;
  }

  .premaforum-editor__input { min-height: 160px; }
}

@media (prefers-reduced-motion: reduce) {
  .premaforum-toast { transition: none; }
}
