.news-feed-list {
  display: grid;
  gap: 14px;
}

.news-feed-card {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}

.news-feed-post-shell {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--news-source-primary, var(--site-primary)) 26%, white 74%);
}

.news-feed-title-bar {
  display: block;
  padding: 8px 10px;
  background: var(--news-source-news-header, var(--news-header, var(--news-source-nav-current, var(--nav-current, var(--site-accent, var(--site-primary))))));
  border-bottom: 1px solid color-mix(in srgb, var(--news-source-news-header, var(--news-header, var(--news-source-nav-current, var(--nav-current, var(--site-accent, var(--site-primary)))))) 74%, white 26%);
  color: var(--news-source-news-header-text, var(--news-header-text, var(--site-text)));
  font-size: 1.25rem;
  line-height: 1.22;
  font-weight: 700;
}

.news-feed-title-bar a {
  color: inherit;
  text-decoration: none;
}

.news-feed-meta-bubble {
  display: grid;
  justify-items: center;
  align-content: start;
  gap: 2px;
  margin: 0 0 8px;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  background: color-mix(in srgb, var(--site-bg) 84%, white 16%);
  width: max-content;
  max-width: 100%;
}

.news-feed-summary-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 0;
  padding: 0 10px 12px;
  background: var(--news-source-news-content, var(--news-content, color-mix(in srgb, var(--site-bg) 96%, white 4%)));
  grid-column: 1 / -1;
}

.news-feed-meta-site,
.news-feed-meta-date {
  display: block;
  margin: 0;
  font-size: 0.82rem;
  line-height: 1.1;
  font-weight: 700;
  color: color-mix(in srgb, var(--site-text) 78%, black 22%);
  text-decoration: none;
}

.news-feed-summary-footer-link .news-feed-link-full {
  font-size: 0.9rem;
  font-weight: 700;
}

.news-feed-date-corner {
  display: inline-flex;
  align-items: center;
  padding: 4px 9px;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  background: color-mix(in srgb, var(--site-bg) 84%, white 16%);
  font-size: 0.82rem;
  line-height: 1.1;
  font-weight: 700;
  color: color-mix(in srgb, var(--site-text) 78%, black 22%);
  white-space: nowrap;
}

/* Desktop/tablet footer alignment:
   keep date at far right, but align Full Article with summary text column start. */
@media (min-width: 641px) and (max-width: 960px) {
  .news-feed-summary-footer-link {
    margin-left: calc(125px + 12px);
  }
}

@media (min-width: 961px) {
  .news-feed-summary-footer-link {
    margin-left: calc(140px + 12px);
  }
}

.news-feed-post-header {
  display: none;
}

.news-feed-post-body {
  display: grid;
  grid-template-columns: 140px minmax(0, 1fr) 240px;
  gap: 10px 12px;
  align-items: start;
  padding: 12px 10px;
  background: var(--news-source-news-content, var(--news-content, color-mix(in srgb, var(--site-bg) 96%, white 4%)));
  color: var(--news-source-news-content-text, var(--news-content-text, var(--site-text)));
}

.news-feed-date-cell {
  display: flex;
  justify-content: center;
  align-items: center;
}

.news-feed-headline-cell {
  min-width: 0;
}

.news-feed-author-cell {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.news-feed-summary-cell {
  min-width: 0;
}

.news-feed-image-cell {
  min-width: 0;
}

.news-feed-date {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 4px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--site-bg) 84%, white 16%);
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  font-size: 0.82rem;
  line-height: 1.1;
  font-weight: 700;
  color: color-mix(in srgb, var(--site-text) 78%, black 22%);
}

.news-feed-context-line {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 4px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--news-source-bg, var(--site-bg)) 82%, white 18%);
  border: 1px solid color-mix(in srgb, var(--news-source-primary, var(--site-primary)) 36%, white 64%);
  font-size: 0.82rem;
  line-height: 1.1;
  font-weight: 700;
  color: color-mix(in srgb, var(--news-source-text, var(--site-text)) 80%, black 20%);
  text-decoration: none;
}

a.news-feed-context-line:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.news-feed-title {
  margin: 0;
  padding-bottom: 6px;
  margin-bottom: 6px;
  border-bottom: 1px solid color-mix(in srgb, var(--site-text) 16%, white 84%);
  font-size: 1.1rem;
  line-height: 1.28;
}

.news-feed-summary-cell > .news-feed-title {
  display: none;
}

.news-feed-title a {
  color: var(--site-primary);
  text-decoration: none;
  border-bottom: 1px solid transparent;
}

.news-feed-title-main {
  font-size: 1em;
  font-weight: 700;
}

.news-feed-title-note {
  font-size: 0.64em;
  font-weight: 600;
  opacity: 0.86;
}

.news-feed-title a:hover {
  border-bottom-color: color-mix(in srgb, var(--site-primary) 48%, transparent 52%);
}

.news-feed-author-identity {
  margin: 0 0 10px;
  display: grid;
  place-items: center;
}

.news-feed-author-name,
.news-feed-author-mail {
  display: inline-block;
  font-size: 0.84rem;
  line-height: 1.25;
  font-weight: 700;
  color: color-mix(in srgb, var(--site-text) 90%, black 10%);
  text-decoration: none;
  word-break: break-word;
  padding: 4px 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--site-bg) 74%, white 26%);
  border: 1px solid color-mix(in srgb, var(--site-text) 12%, white 88%);
}

.news-feed-author-image-wrap {
  display: grid;
  place-items: center;
}

.news-feed-author-avatar {
  width: 74px;
  height: 74px;
  border-radius: 999px;
  object-fit: cover;
  border: 1px solid color-mix(in srgb, var(--site-text) 20%, white 80%);
  background: #f4f8fb;
}

.news-feed-author-avatar-fallback {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, color-mix(in srgb, var(--site-primary) 16%, white 84%), color-mix(in srgb, var(--site-accent) 16%, white 84%));
  color: color-mix(in srgb, var(--site-text) 85%, black 15%);
  font-size: 0.74rem;
  font-weight: 800;
  text-transform: uppercase;
}

.news-feed-summary {
  margin: 0 0 8px;
  color: color-mix(in srgb, var(--site-text) 90%, black 10%);
}

.news-feed-summary-rich a {
  color: var(--site-accent);
  text-decoration: underline;
  font-weight: 700;
}

.news-feed-links {
  margin: 2px 0 0;
  font-size: 0.9rem;
  font-weight: 700;
}

.news-feed-summary-cell > .news-feed-links {
  display: none;
}

.news-feed-owner-actions {
  position: absolute;
  top: 8px;
  right: 10px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.news-feed-owner-status {
  display: inline-flex;
  align-items: center;
  margin: 0;
  padding: 4px 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--site-bg) 84%, white 16%);
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  font-size: 0.8rem;
  line-height: 1.1;
  font-weight: 700;
  color: color-mix(in srgb, var(--site-text) 78%, black 22%);
  white-space: nowrap;
}

.news-feed-owner-status.is-unpublished {
  background: color-mix(in srgb, #f59e0b 14%, white 86%);
  border-color: color-mix(in srgb, #f59e0b 40%, white 60%);
  color: color-mix(in srgb, #b45309 82%, black 18%);
}

.news-feed-owner-status.is-published {
  background: color-mix(in srgb, var(--success, #37d38a) 12%, white 88%);
  border-color: color-mix(in srgb, var(--success, #37d38a) 34%, white 66%);
  color: color-mix(in srgb, var(--site-text) 78%, black 22%);
}

.news-feed-owner-actions > .news-feed-owner-btn {
  width: 28px;
  height: 28px;
  border-radius: 999px;
  border: 2px solid var(--action-icon-edit-ring);
  background: var(--action-icon-bg);
  display: inline-grid;
  place-items: center;
  padding: 0;
  color: var(--action-icon-edit-fg);
  font-size: 0;
  line-height: 1;
  cursor: pointer;
}

.news-feed-owner-actions > .news-feed-owner-btn.is-danger {
  border-color: var(--action-icon-delete-ring);
  color: var(--action-icon-delete-fg);
}

.news-feed-owner-actions > .news-feed-owner-btn::before {
  content: "";
  width: 14px;
  height: 14px;
  display: block;
  background-color: currentColor;
  mask-repeat: no-repeat;
  -webkit-mask-repeat: no-repeat;
  mask-position: center;
  -webkit-mask-position: center;
  mask-size: contain;
  -webkit-mask-size: contain;
  mask-image: url("../icons/ri-pencil-line.svg");
  -webkit-mask-image: url("../icons/ri-pencil-line.svg");
}

.news-feed-owner-actions > .news-feed-owner-btn.is-danger::before {
  width: 15px;
  height: 15px;
  mask-image: url("../icons/ri-delete-bin-line.svg");
  -webkit-mask-image: url("../icons/ri-delete-bin-line.svg");
}

.news-feed-owner-actions > .news-feed-owner-btn.is-warn {
  border-color: var(--action-icon-warn-ring);
  color: var(--action-icon-warn-fg);
}

.layout-block-surface-quick-links > .layout-block-content {
  display: block;
}

.layout-quick-links-grid {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  justify-content: center;
  align-items: center;
  gap: 8px;
}

.layout-block-surface-quick-links.is-left-column .layout-quick-links-grid {
  width: 100%;
  justify-content: center;
}

.layout-block-surface-quick-links.is-right-column .layout-quick-links-grid {
  width: 100%;
  justify-content: center;
}

.layout-block-surface-quick-links {
  --quick-links-accent: var(--calendar-month-control-accent, var(--nav-bg, var(--site-primary, #6f7f0f)));
  --quick-links-text: var(--calendar-month-control-text, var(--calendar-source-event-text, var(--calendar-source-nav-text, var(--nav-text, #ffffff))));
  --quick-links-surface: var(--site-bg, #f7faf7);
  --quick-links-button-height: clamp(30px, 3vw, 38px);
  --quick-links-icon-size: clamp(18px, 2vw, 24px);
  --quick-links-icon-glyph-size: clamp(12px, 1.2vw, 16px);
  --quick-links-label-size: clamp(0.95rem, 1.02vw, 1.08rem);
}

.layout-quick-links-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: var(--quick-links-button-height);
  width: max-content;
  min-width: 0;
  max-width: 100%;
  box-sizing: border-box;
  padding: clamp(2px, 0.45vw, 5px) clamp(6px, 1vw, 10px);
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--quick-links-accent) 32%, white 68%);
  background:
    linear-gradient(
      180deg,
      color-mix(in srgb, var(--quick-links-accent) 18%, white 82%) 0%,
      color-mix(in srgb, var(--quick-links-accent) 48%, #1f2937 52%) 100%
    );
  color: color-mix(in srgb, var(--quick-links-text) 92%, black 8%);
  text-decoration: none;
  font-weight: 800;
  white-space: nowrap;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.45),
    0 3px 0 color-mix(in srgb, var(--quick-links-accent) 34%, #0f172a 66%),
    0 6px 10px -3px rgba(15, 23, 42, 0.18);
  line-height: 1.2;
  transition: background-color .16s ease, border-color .16s ease, box-shadow .16s ease, transform .16s ease;
}

.layout-block-surface-quick-links.is-right-column .layout-quick-links-button {
  flex-direction: row-reverse;
}

.layout-block-surface-quick-links.is-left-column .layout-quick-links-button,
.layout-block-surface-quick-links.is-right-column .layout-quick-links-button {
  width: 100%;
  min-width: 0;
  justify-content: center;
}

.layout-quick-links-button:hover {
  text-decoration: none;
  border-color: color-mix(in srgb, var(--quick-links-accent) 40%, white 60%);
  background:
    linear-gradient(
      180deg,
      color-mix(in srgb, var(--quick-links-accent) 24%, white 76%) 0%,
      color-mix(in srgb, var(--quick-links-accent) 56%, #1f2937 44%) 100%
    );
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.5),
    0 2px 0 color-mix(in srgb, var(--quick-links-accent) 34%, #0f172a 66%),
    0 4px 8px -3px rgba(15, 23, 42, 0.16);
  transform: translateY(1px);
}

.layout-quick-links-button:focus-visible {
  outline: none;
  border-color: color-mix(in srgb, var(--quick-links-accent) 56%, white 44%);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.44),
    0 0 0 3px color-mix(in srgb, var(--quick-links-accent) 18%, transparent 82%),
    0 2px 0 color-mix(in srgb, var(--quick-links-accent) 35%, #0f172a 65%);
}

.layout-quick-links-icon {
  display: inline-grid;
  place-items: center;
  width: var(--quick-links-icon-size);
  height: var(--quick-links-icon-size);
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--quick-links-text) 18%, transparent 82%);
  background: color-mix(in srgb, var(--quick-links-surface) 70%, white 30%);
  color: color-mix(in srgb, var(--quick-links-accent) 54%, #0f172a 46%);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  flex: 0 0 auto;
}

.layout-quick-links-icon i {
  font-size: var(--quick-links-icon-glyph-size);
  line-height: 1;
}

.layout-quick-links-label {
  display: block;
  min-width: 0;
  font-size: var(--quick-links-label-size);
  line-height: 1.15;
  overflow-wrap: anywhere;
  white-space: nowrap;
  text-align: center;
}

.layout-block-surface-quick-links.is-left-column .layout-quick-links-label,
.layout-block-surface-quick-links.is-right-column .layout-quick-links-label {
  text-align: center;
}

.layout-block-surface-quick-links.is-full-row .layout-quick-links-grid {
  justify-content: center;
  align-items: center;
}

.layout-block-surface-quick-links.is-full-row .layout-quick-links-button {
  width: max-content;
  min-width: 0;
  max-width: 100%;
  justify-content: center;
}

.layout-block-surface-quick-links.is-full-row .layout-quick-links-label {
  text-align: center;
}

.news-feed-owner-actions > .news-feed-owner-btn.is-warn::before {
  width: 15px;
  height: 15px;
  mask-image: url("../icons/ri-eye-off-line.svg");
  -webkit-mask-image: url("../icons/ri-eye-off-line.svg");
}

.news-feed-owner-actions > .news-feed-owner-btn.is-warn.is-published::before {
  mask-image: url("../icons/ri-eye-line.svg");
  -webkit-mask-image: url("../icons/ri-eye-line.svg");
}

.news-feed-owner-edit-form {
  border: 1px solid color-mix(in srgb, var(--site-primary) 24%, white 76%);
  border-radius: 12px;
  margin: 10px;
  overflow: hidden;
  background: color-mix(in srgb, var(--site-bg) 96%, white 4%);
  display: grid;
  gap: 0;
}

.news-feed-owner-edit-form[hidden] {
  display: none !important;
}

.news-feed-owner-edit-header {
  padding: 8px 10px;
  background: color-mix(in srgb, var(--nav-bg, var(--site-primary)) 88%, black 12%);
  border-bottom: 1px solid color-mix(in srgb, var(--site-primary) 30%, white 70%);
  color: color-mix(in srgb, var(--nav-text, #ffffff) 88%, white 12%);
  font-weight: 800;
}

.news-feed-owner-edit-body {
  padding: 10px;
  display: grid;
  gap: 10px;
}

.news-feed-owner-edit-form input[type="text"] {
  width: 100%;
  box-sizing: border-box;
}

.news-feed-summary-editor-wrap {
  display: grid;
  gap: 6px;
}

.news-feed-summary-toolbar,
.news-public-summary-toolbar {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.news-feed-summary-toolbar button,
.news-public-summary-toolbar button {
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  border-radius: 6px;
  background: #fff;
  color: color-mix(in srgb, var(--site-text) 85%, black 15%);
  font-size: 0.86rem;
  line-height: 1;
  padding: 4px 8px;
  cursor: pointer;
}

.news-feed-summary-editor,
.news-public-summary-editor {
  width: 100%;
  min-height: 78px;
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  border-radius: 2px;
  background: #fff;
  padding: 8px 10px;
  box-sizing: border-box;
  overflow-wrap: anywhere;
}

.news-feed-summary-editor:empty::before,
.news-public-summary-editor:empty::before {
  content: attr(data-placeholder);
  color: #666;
}

.news-feed-owner-edit-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.news-feed-owner-edit-actions .news-feed-owner-btn {
  width: auto;
  height: auto;
  border-radius: 8px;
  padding: 4px 10px;
  font-size: 0.95rem;
}

.news-feed-owner-detail-toggle {
  font-size: 0.86rem;
  margin-right: auto;
}

.news-feed-post-shell.is-editing .news-feed-post-body {
  display: none;
}

.news-feed-link-source,
.news-feed-link-full {
  color: var(--site-accent);
  text-decoration: underline;
  font-weight: 700;
}

.news-feed-link-sep {
  opacity: 0.62;
}

.news-feed-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border-radius: 10px;
  object-fit: cover;
  border: 1px solid color-mix(in srgb, var(--site-text) 14%, white 86%);
  background: color-mix(in srgb, var(--site-bg) 86%, white 14%);
}

.news-feed-image-fallback {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, color-mix(in srgb, var(--site-primary) 18%, white 82%), color-mix(in srgb, var(--site-accent) 18%, white 82%));
}

.news-feed-image-fallback-label {
  font-size: 0.88rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: color-mix(in srgb, var(--site-text) 82%, black 18%);
}

.news-public-composer {
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
  margin-bottom: 12px;
}

.news-quick-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 10px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(18, 54, 94, 0.16);
  background: rgba(255, 255, 255, 0.8);
}

.news-quick-actions.is-editing {
  display: none;
}

.news-quick-add-btn {
  appearance: none;
  border: 1px solid rgba(18, 54, 94, 0.3);
  background: rgba(18, 54, 94, 0.06);
  color: #12365e;
  font-weight: 700;
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
}

.news-quick-status {
  font-size: 0.86rem;
  color: #12365e;
  margin: 0;
}

.news-public-form {
  display: none;
  gap: 8px;
}

.news-public-form.is-open {
  display: grid;
}

.news-public-bubble {
  border-radius: 12px;
  overflow: hidden;
  background: var(--news-content, color-mix(in srgb, var(--site-bg) 96%, white 4%));
  color: var(--news-content-text, var(--site-text));
  border: 1px solid color-mix(in srgb, var(--site-primary) 24%, white 76%);
  display: grid;
}

.news-public-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: var(--news-header, var(--nav-current, var(--site-accent, var(--site-primary))));
  border-bottom: 1px solid color-mix(in srgb, var(--news-header, var(--nav-current, var(--site-accent, var(--site-primary)))) 74%, white 26%);
}

.news-public-header-label {
  font-size: 1rem;
  font-weight: 800;
  color: var(--news-header-text, color-mix(in srgb, var(--nav-text, #ffffff) 90%, white 10%));
  white-space: nowrap;
}

.news-public-header input[type="text"] {
  flex: 1;
  min-width: 180px;
  border-radius: 2px;
  border: 1px solid color-mix(in srgb, var(--site-text) 18%, white 82%);
  background: #fff;
}

.news-public-body {
  padding: 10px;
  display: grid;
  gap: 10px;
}

.news-public-form input[type="text"] {
  width: 100%;
  box-sizing: border-box;
}

.news-public-summary-wrap {
  display: grid;
  gap: 6px;
}

.news-public-options-row {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding-top: 2px;
}

.news-public-upload-inline {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 0.92rem;
  font-weight: 600;
  color: color-mix(in srgb, var(--site-text) 82%, black 18%);
}

.news-public-upload-inline input[type="file"] {
  max-width: 290px;
}

.news-public-detail-toggle-inline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.95rem;
}

.news-public-crop-anchor select {
  min-width: 130px;
}

.news-public-actions-inline {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.news-public-cancel-btn {
  appearance: none;
  border: 1px solid rgba(18, 54, 94, 0.25);
  background: rgba(18, 54, 94, 0.06);
  color: #12365e;
  border-radius: 8px;
  padding: 7px 12px;
  font-weight: 700;
  cursor: pointer;
}

@media (max-width: 960px) {
  .news-feed-post-header {
    grid-template-columns: 125px minmax(0, 1fr);
  }

  .news-feed-post-body {
    grid-template-columns: 125px minmax(0, 1fr);
  }

  .news-feed-image-cell {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .news-feed-card {
    padding: 12px;
  }

  .news-feed-post-header {
    grid-template-columns: 1fr;
    justify-items: start;
  }

  .news-feed-post-body {
    grid-template-columns: 1fr;
  }

  .news-feed-owner-actions {
    top: 6px;
    right: 8px;
  }

  .news-feed-author-cell {
    text-align: center;
  }

  .news-public-header {
    flex-direction: column;
    align-items: stretch;
  }

  .news-public-options-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .news-public-actions-inline {
    margin-left: 0;
  }

  .news-quick-actions {
    flex-direction: column;
    align-items: flex-start;
  }
}
