/* Blog 1000 em Mat — segue data-theme como o resto do site */

.blog-page {
  --b-bg: #070720;
  --b-surface: var(--theme-surface, #12122a);
  --b-input: #0d0d24;
  --b-text: var(--theme-text, #eef0f8);
  --b-muted: var(--theme-text-muted, rgba(238, 240, 248, 0.62));
  --b-purple: #7c3dff;
  --b-mint: #24ffab;
  --b-tag-bg: rgba(124, 61, 255, 0.16);
  --b-tag-fg: #cbb8ff;
  --b-border: rgba(255, 255, 255, 0.12);
  --b-link: #cbb8ff;
  background: var(--b-bg);
  color: var(--b-text);
}

html[data-theme="light"] .blog-page {
  --b-bg: #f7f7ff;
  --b-surface: #ffffff;
  --b-input: #ffffff;
  --b-text: #303c46;
  --b-muted: #6c757d;
  --b-purple: #5900ff;
  --b-mint: #0a7a52;
  --b-tag-bg: rgba(89, 0, 255, 0.1);
  --b-tag-fg: #4a1fd6;
  --b-border: #dee2e6;
  --b-link: #4a1fd6;
  background: #f7f7ff !important;
  color: #303c46 !important;
}

.blog-shell {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto 4rem;
  padding-top: 1.5rem;
}

.blog-kicker {
  margin: 0 0 0.5rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--b-mint);
}

.blog-hero {
  margin: 1rem 0 1.5rem;
}

.blog-hero__title {
  font-size: clamp(1.8rem, 4vw, 3rem);
  line-height: 1.15;
  margin: 0 0 0.6rem;
  letter-spacing: -0.03em;
}

.blog-hero__lead {
  color: var(--b-muted);
  max-width: 42rem;
}

.blog-search {
  display: flex;
  gap: 0.5rem;
  max-width: 520px;
  margin: 1.25rem 0 0.5rem;
}

.blog-search input {
  flex: 1;
  border: 1px solid var(--b-border);
  background: var(--b-input);
  color: var(--b-text);
  border-radius: 999px;
  padding: 0.8rem 1.1rem;
}

.blog-search button,
.blog-btn {
  border: 0;
  border-radius: 999px;
  padding: 0.8rem 1.2rem;
  font-weight: 700;
  background: linear-gradient(135deg, #6b3dff, #4a1fd6);
  color: #fff;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}

.blog-btn--ghost {
  background: transparent;
  border: 1px solid var(--b-border);
  color: var(--b-text);
}

.blog-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  margin: 1.25rem 0 2rem;
}

.blog-tag,
.blog-card__tags a,
.blog-card__tags span {
  display: inline-block;
  padding: 0.28rem 0.7rem;
  border-radius: 999px;
  background: var(--b-tag-bg);
  color: var(--b-tag-fg);
  text-decoration: none;
  font-size: 0.82rem;
}

.blog-tag.is-active,
a.blog-tag.is-active:hover,
a.blog-tag.is-active:focus-visible {
  background: var(--b-purple);
  color: #fff !important;
}

html[data-theme="light"] body.promocao.blog-page a.blog-tag.is-active,
html[data-theme="light"] body.promocao.blog-page a.blog-tag.is-active:hover,
html[data-theme="light"] body.promocao.blog-page a.blog-tag.is-active:focus-visible {
  color: #fff !important;
}

.blog-featured {
  display: grid;
  gap: 1.25rem;
  margin-bottom: 2rem;
  padding: 1rem;
  border-radius: 24px;
  background: var(--b-surface);
  border: 1px solid var(--b-border);
}

@media (min-width: 800px) {
  .blog-featured {
    grid-template-columns: 1.1fr 1fr;
    align-items: center;
  }
}

.blog-featured img,
.blog-featured__ph,
.blog-card img,
.blog-card__ph,
.blog-article__cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 18px;
}

.blog-featured__ph,
.blog-card__ph {
  min-height: 220px;
  background: linear-gradient(145deg, #2a1860, #12122a);
}

html[data-theme="light"] .blog-featured__ph,
html[data-theme="light"] .blog-card__ph {
  background: linear-gradient(145deg, #ede7ff, #e4e8ff);
}

.blog-featured__media,
.blog-card__media {
  display: block;
  min-height: 220px;
}

.blog-featured h2 a,
.blog-card h2 a,
.blog-card h3 a,
.blog-article h1 {
  color: var(--b-text);
  text-decoration: none;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.1rem;
}

.blog-card {
  background: var(--b-surface);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid var(--b-border);
}

.blog-card__body {
  padding: 1rem 1.1rem 1.2rem;
}

.blog-card h2 {
  font-size: 1.15rem;
  margin: 0.4rem 0 0.45rem;
}

.blog-meta,
.blog-empty,
.blog-share__hint,
.blog-hint {
  color: var(--b-muted);
  font-size: 0.9rem;
}

.blog-pager {
  display: flex;
  justify-content: center;
  gap: 1rem;
  align-items: center;
  margin: 2rem 0;
}

.blog-pager a,
.blog-crumb a,
.blog-prose a,
.blog-login-cta a,
.blog-editor-links a,
.blog-table a {
  color: var(--b-link);
}

.blog-article {
  max-width: 740px;
  margin: 0 auto;
}

.blog-crumb a {
  text-decoration: none;
}

.blog-article__head h1 {
  font-size: clamp(1.8rem, 4vw, 2.7rem);
  letter-spacing: -0.03em;
  margin: 0.4rem 0 0.7rem;
}

.blog-article__cover {
  margin: 1.25rem 0 1.5rem;
}

.blog-prose {
  font-size: 1.12rem;
  line-height: 1.75;
}

.blog-prose h2,
.blog-prose h3 {
  margin-top: 1.6rem;
}

.blog-prose a {
  color: var(--b-link);
}

.blog-prose img {
  max-width: 100%;
  border-radius: 12px;
}

.blog-share,
.blog-engage,
.blog-comments,
.blog-related {
  margin-top: 2.4rem;
  padding-top: 1.4rem;
  border-top: 1px solid var(--b-border);
}

.blog-share__row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.blog-share__btn,
.blog-like {
  border: 1px solid var(--b-border);
  background: var(--b-surface);
  color: var(--b-text);
  border-radius: 999px;
  padding: 0.45rem 0.85rem;
  text-decoration: none;
  font-size: 0.88rem;
  cursor: pointer;
}

.blog-share__btn {
  width: 2.6rem;
  height: 2.6rem;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}

.blog-share__btn:hover {
  transform: translateY(-1px);
  border-color: var(--b-purple);
  color: var(--b-purple);
}

.blog-share__btn.is-copied {
  border-color: var(--b-mint);
  color: var(--b-mint);
}

.blog-like.is-on {
  border-color: var(--b-mint);
  color: var(--b-mint);
}

.blog-comment {
  margin: 1rem 0;
  padding: 0.9rem 1rem;
  border-radius: 14px;
  background: var(--b-surface);
  position: relative;
}

.blog-comment__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.blog-comment__top form {
  margin: 0;
  flex-shrink: 0;
}

.blog-comment__del {
  width: 2.15rem;
  height: 2.15rem;
  padding: 0;
  border: 1px solid rgba(255, 107, 122, 0.35);
  border-radius: 10px;
  background: rgba(255, 107, 122, 0.1);
  color: #ff6b7a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 1rem;
  transition: background 0.15s ease, transform 0.15s ease;
}

.blog-comment__del:hover {
  background: rgba(255, 107, 122, 0.22);
  transform: scale(1.04);
}

html[data-theme="light"] .blog-comment__del {
  border-color: rgba(196, 40, 57, 0.28);
  background: rgba(196, 40, 57, 0.08);
  color: #c42839;
}

.blog-comment-form textarea,
.blog-editor__form input,
.blog-editor__form textarea,
.blog-editor__form select {
  width: 100%;
  border-radius: 12px;
  border: 1px solid var(--b-border);
  background: var(--b-input);
  color: var(--b-text);
  padding: 0.75rem 0.9rem;
}

.blog-login-cta a,
.blog-editor-links a {
  color: var(--b-link);
}

.blog-editor,
.blog-manage {
  max-width: 860px;
  margin: 0 auto;
}

.blog-editor__form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.blog-format {
  border: 1px solid var(--b-border);
  border-radius: 14px;
  padding: 0.8rem 1rem;
}

.blog-format__opt {
  margin-right: 1rem;
}

.blog-editor__row {
  display: flex;
  gap: 1.5rem;
  flex-wrap: wrap;
}

.blog-editor__actions {
  display: flex;
  gap: 0.6rem;
}

.blog-table {
  width: 100%;
  border-collapse: collapse;
}

.blog-table th,
.blog-table td {
  padding: 0.7rem 0.4rem;
  border-bottom: 1px solid var(--b-border);
  text-align: left;
}

.blog-table a {
  color: var(--b-link);
}

.blog-flash {
  text-align: center;
  padding: 0.65rem;
  background: rgba(36, 255, 171, 0.12);
}

.blog-draft-badge {
  display: inline-block;
  padding: 0.15rem 0.55rem;
  border-radius: 999px;
  background: #ffb020;
  color: #1a1200;
  font-weight: 700;
  font-size: 0.75rem;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.blog-seo {
  border: 1px solid var(--b-border);
  border-radius: 12px;
  padding: 0.7rem 1rem;
}

.EasyMDEContainer .CodeMirror {
  background: var(--b-input);
  color: var(--b-text);
  border-color: var(--b-border);
}

html[data-theme="light"] .EasyMDEContainer .editor-toolbar {
  background: #fff;
  border-color: var(--b-border);
}

html[data-theme="light"] .EasyMDEContainer .editor-toolbar button {
  color: #303c46;
}

/* Dark: toolbar + fullscreen (EasyMDE força fundo branco no fullscreen) */
html:not([data-theme="light"]) .EasyMDEContainer .editor-toolbar,
html:not([data-theme="light"]) .editor-toolbar.fullscreen,
html:not([data-theme="light"]) .EasyMDEContainer .CodeMirror,
html:not([data-theme="light"]) .CodeMirror-fullscreen,
html:not([data-theme="light"]) .editor-preview,
html:not([data-theme="light"]) .editor-preview-side,
html:not([data-theme="light"]) .editor-preview-full {
  background: #12122a !important;
  color: #eef0f8 !important;
  border-color: rgba(255, 255, 255, 0.14) !important;
}

html:not([data-theme="light"]) .EasyMDEContainer .editor-toolbar button,
html:not([data-theme="light"]) .editor-toolbar.fullscreen button,
html:not([data-theme="light"]) .EasyMDEContainer .editor-toolbar i,
html:not([data-theme="light"]) .editor-toolbar.fullscreen i {
  color: #eef0f8 !important;
}

html:not([data-theme="light"]) .EasyMDEContainer .editor-toolbar button:hover,
html:not([data-theme="light"]) .editor-toolbar.fullscreen button:hover,
html:not([data-theme="light"]) .EasyMDEContainer .editor-toolbar button.active,
html:not([data-theme="light"]) .editor-toolbar.fullscreen button.active {
  background: rgba(124, 61, 255, 0.28) !important;
  color: #fff !important;
}

html:not([data-theme="light"]) .CodeMirror-fullscreen .CodeMirror-lines,
html:not([data-theme="light"]) .CodeMirror-fullscreen .CodeMirror-line,
html:not([data-theme="light"]) .EasyMDEContainer .CodeMirror-line {
  color: #eef0f8 !important;
}

html:not([data-theme="light"]) .CodeMirror-cursor {
  border-left: 1px solid #eef0f8 !important;
}

html:not([data-theme="light"]) .cm-s-easymde .cm-header,
html:not([data-theme="light"]) .cm-s-easymde .cm-strong {
  color: #fff !important;
}

html:not([data-theme="light"]) .cm-s-easymde .cm-link,
html:not([data-theme="light"]) .cm-s-easymde .cm-url {
  color: #cbb8ff !important;
}

html:not([data-theme="light"]) .cm-s-easymde .cm-comment {
  color: #a8acc8 !important;
}

html:not([data-theme="light"]) .editor-statusbar {
  background: #12122a;
  color: #a8acc8;
  border-color: rgba(255, 255, 255, 0.14);
}
