/* ===== Design tokens ===== */
:root {
  --bg: #fdf8f3;
  --bg-card: #ffffff;
  --ink: #241f1c;
  --ink-soft: #6b6259;
  --accent: #e8542f;       /* laranja-avermelhado principal */
  --accent-ink: #ffffff;
  --accent-soft: #ffe4d9;
  --accent-2: #2d6a63;     /* verde-petróleo secundário */
  --border: #ece3d8;
  --radius: 16px;
  --shadow: 0 2px 10px rgba(36, 31, 28, 0.06);
  --max-width: 720px;
  font-size: 16px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Georgia", "Iowan Old Style", serif;
  line-height: 1.65;
}

body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; display: block; }

.icon {
  width: 1.05em;
  height: 1.05em;
  vertical-align: -0.18em;
  stroke: currentColor;
  fill: none;
}

/* ===== Header ===== */
.site-header {
  border-bottom: 3px solid var(--ink);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header__inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 22px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.site-title {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.site-title span { color: var(--accent); }

.site-nav a {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
  margin-left: 18px;
}
.site-nav a:hover { color: var(--accent); text-decoration: none; }

/* ===== Layout ===== */
main {
  flex: 1;
  max-width: var(--max-width);
  width: 100%;
  margin: 0 auto;
  padding: 36px 20px 64px;
}

/* ===== Busca ===== */
.search-box {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-card);
  border: 2px solid var(--ink);
  border-radius: 999px;
  padding: 10px 18px;
  margin-bottom: 34px;
}
.search-box .icon { color: var(--ink-soft); flex-shrink: 0; }
.search-box input {
  border: none;
  outline: none;
  background: transparent;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.95rem;
  width: 100%;
  color: var(--ink);
}
.search-empty {
  display: none;
  color: var(--ink-soft);
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9rem;
  padding: 8px 4px 24px;
}

/* ===== Lista de posts ===== */
.post-list { display: flex; flex-direction: column; gap: 22px; }

.post-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px 26px;
  box-shadow: var(--shadow);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.post-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(36,31,28,0.1); }

.post-card__date {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--accent-2);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.post-card__title {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 1.35rem;
  font-weight: 800;
  margin: 0 0 8px;
  letter-spacing: -0.01em;
}
.post-card__title a { color: var(--ink); }
.post-card__title a:hover { color: var(--accent); text-decoration: none; }

.post-card__excerpt { color: var(--ink-soft); margin: 0; }

/* ===== Post individual ===== */
.post-header { margin-bottom: 28px; }
.post-header .post-card__date { margin-bottom: 14px; }

.post-title {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 2.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 10px;
}

.post-content { font-size: 1.08rem; }
.post-content p { margin: 0 0 1.2em; }
.post-content h2, .post-content h3 {
  font-family: "Helvetica Neue", Arial, sans-serif;
  margin-top: 1.6em;
}
.post-content blockquote {
  border-left: 4px solid var(--accent);
  margin: 1.4em 0;
  padding: 4px 0 4px 18px;
  color: var(--ink-soft);
  font-style: italic;
}
.post-content code {
  background: var(--accent-soft);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 0.9em;
}

.back-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ink);
  margin-bottom: 24px;
}
.back-link:hover { color: var(--accent); text-decoration: none; }

/* ===== Barra de ações (curtir / compartilhar) ===== */
.action-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 30px 0;
  padding: 14px 0;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.88rem;
  font-weight: 700;
  border: 2px solid var(--ink);
  background: var(--bg-card);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 16px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.btn:hover { background: var(--ink); color: var(--bg); }
.btn:active { transform: scale(0.96); }

.btn-like.is-liked {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--accent-ink);
}
.btn-like.is-liked .icon { fill: currentColor; }

.btn-share.is-copied { background: var(--accent-2); border-color: var(--accent-2); color: #fff; }

/* ===== Comentários ===== */
.comments-section { margin-top: 40px; }

.comments-title {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 800;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

.comment-form {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  margin-bottom: 26px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.comment-form input,
.comment-form textarea {
  font-family: inherit;
  font-size: 0.95rem;
  border: 1.5px solid var(--border);
  border-radius: 10px;
  padding: 10px 12px;
  outline: none;
  background: var(--bg);
  color: var(--ink);
  resize: vertical;
}
.comment-form input:focus,
.comment-form textarea:focus { border-color: var(--accent); }
.comment-form textarea { min-height: 80px; }

.comment-form__submit {
  align-self: flex-end;
  background: var(--accent);
  color: #fff;
  border: none;
  border-radius: 999px;
  padding: 9px 20px;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  cursor: pointer;
}
.comment-form__submit:hover { background: #cf4523; }
.comment-form__submit:disabled { opacity: 0.6; cursor: default; }

.comment-status {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

.comment-list { display: flex; flex-direction: column; gap: 14px; }

.comment {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 14px 18px;
  background: var(--bg-card);
}
.comment__head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 4px;
}
.comment__name {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--accent-2);
}
.comment__date {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.75rem;
  color: var(--ink-soft);
}
.comment__body { margin: 0 0 10px; font-size: 0.96rem; }
.comment__actions { display: flex; gap: 8px; }
.comment__actions .btn { padding: 5px 12px; font-size: 0.78rem; }

.empty-state {
  color: var(--ink-soft);
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.9rem;
  padding: 10px 0;
}

/* ===== Footer ===== */
.site-footer {
  border-top: 3px solid var(--ink);
  padding: 24px 20px;
  text-align: center;
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 0.82rem;
  color: var(--ink-soft);
}

@media (max-width: 480px) {
  .post-title { font-size: 1.6rem; }
  .site-title { font-size: 1.25rem; }
  .action-bar { flex-wrap: wrap; }
}
