/* devinmind.com.br — Igor Wendt
   Paleta: papel cinza-sálvia, tinta verde-escura, acento "ledger green", sinal âmbar para uma única marca. */
:root {
  --paper: #eef1ec;
  --paper-2: #e3e8e1;
  --ink: #17211d;
  --ink-2: #4a5852;
  --rule: #c9d2cb;
  --ledger: #1d6b57;
  --signal: #b9821e;
  --code-bg: #e2e7e0;
  --sans: "Schibsted Grotesk", system-ui, sans-serif;
  --serif: "Newsreader", Georgia, serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --measure: 40rem;
  --rail: 11rem;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #121a17;
    --paper-2: #18221e;
    --ink: #e6ece7;
    --ink-2: #a3b1aa;
    --rule: #2c3833;
    --ledger: #5fbf9f;
    --signal: #e0ad4d;
    --code-bg: #1c2723;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--sans);
  font-feature-settings: "ss01", "tnum" 0;
}
a { color: inherit; text-decoration-color: var(--ledger); text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
a:hover { color: var(--ledger); }
:focus-visible { outline: 2px solid var(--ledger); outline-offset: 3px; border-radius: 2px; }

.wrap { max-width: calc(var(--rail) + var(--measure) + 4rem); margin: 0 auto; padding: 0 1.25rem; }

/* Cabeçalho */
.top { display: flex; justify-content: space-between; align-items: baseline; padding: 1.5rem 0 0; }
.mark { font-weight: 700; letter-spacing: -0.02em; text-decoration: none; font-size: 1.05rem; }
.mark b { color: var(--ledger); font-weight: 700; }
.top nav { display: flex; gap: 1.25rem; font-size: 0.95rem; }
.top nav a { text-decoration: none; color: var(--ink-2); }
.top nav a:hover, .top nav a[aria-current] { color: var(--ink); }

/* Hero: a frase é o elemento que fica na memória */
.hero { padding: 5.5rem 0 4.5rem; }
.hero .name { font-size: 1rem; color: var(--ink-2); margin: 0 0 1.25rem; }
.hero h1 {
  font-size: clamp(2.6rem, 7.2vw, 5.4rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 650;
  margin: 0;
  max-width: 13ch;
  text-wrap: balance;
}
.hero .lede { max-width: 34rem; margin: 2rem 0 0; font-size: 1.15rem; color: var(--ink-2); }
.hero .lede strong { color: var(--ink); font-weight: 600; }
.links { display: flex; flex-wrap: wrap; gap: 0.75rem 1.5rem; margin: 2rem 0 0; padding: 0; list-style: none; font-weight: 500; }

/* Seções com rótulo na margem */
.sec { display: grid; grid-template-columns: var(--rail) minmax(0, var(--measure)); gap: 0 2.5rem; padding: 3rem 0; border-top: 1px solid var(--rule); }
.sec > h2 { font-size: 0.95rem; font-weight: 600; margin: 0.2rem 0 1rem; color: var(--ink-2); letter-spacing: 0; }
.sec p { margin: 0 0 1rem; }

.areas { margin: 0; }
.areas div { padding: 0 0 1.25rem; }
.areas dt { font-weight: 600; letter-spacing: -0.01em; }
.areas dd { margin: 0.15rem 0 0; color: var(--ink-2); }

.posts { list-style: none; margin: 0; padding: 0; }
.posts li { padding: 0 0 1.5rem; }
.posts a { font-size: 1.35rem; font-weight: 600; letter-spacing: -0.02em; line-height: 1.25; text-decoration: none; }
.posts a:hover { text-decoration: underline; }
.posts p { color: var(--ink-2); margin: 0.35rem 0 0; }
.posts time { display: block; font-size: 0.875rem; color: var(--ink-2); margin-top: 0.35rem; }

.foot { padding: 2.5rem 0 3rem; border-top: 1px solid var(--rule); color: var(--ink-2); font-size: 0.875rem; }

/* Artigo */
.article { max-width: 42rem; margin: 0 auto; padding: 3.5rem 0 2rem; }
.article header h1 { font-size: clamp(2.1rem, 5vw, 3.3rem); line-height: 1.04; letter-spacing: -0.04em; font-weight: 650; margin: 0; text-wrap: balance; }
.article header .dek { font-family: var(--serif); font-size: 1.3rem; line-height: 1.45; color: var(--ink-2); margin: 1.25rem 0 0; }
.article header .meta { font-size: 0.9rem; color: var(--ink-2); margin: 1.5rem 0 0; }
.prose { font-family: var(--serif); font-size: 1.2rem; line-height: 1.68; margin-top: 2.5rem; }
.prose h2 { font-family: var(--sans); font-size: 1.45rem; letter-spacing: -0.025em; line-height: 1.2; margin: 3rem 0 0.75rem; }
.prose h3 { font-family: var(--sans); font-size: 1.1rem; letter-spacing: -0.01em; margin: 2rem 0 0.5rem; }
.prose p, .prose ul, .prose ol { margin: 0 0 1.15rem; }
.prose li { margin: 0 0 0.45rem; }
.prose code { font-family: var(--mono); font-size: 0.82em; background: var(--code-bg); padding: 0.08em 0.35em; border-radius: 3px; }
.prose pre { font-family: var(--mono); font-size: 0.85rem; line-height: 1.55; background: var(--code-bg); padding: 1rem 1.15rem; border-radius: 4px; overflow-x: auto; margin: 0 0 1.4rem; }
.prose pre code { background: none; padding: 0; font-size: inherit; }
.prose blockquote { margin: 1.5rem 0; padding: 0 0 0 1.1rem; border-left: 3px solid var(--signal); color: var(--ink-2); }

/* A ordem da virada é uma sequência de verdade: numeração com sentido */
.steps { counter-reset: s; list-style: none; padding: 0; font-family: var(--sans); font-size: 1.02rem; line-height: 1.5; border-left: 2px solid var(--rule); margin: 1.5rem 0 1.8rem; }
.steps li { counter-increment: s; position: relative; padding: 0 0 1.1rem 2.4rem; }
.steps li::before { content: counter(s); position: absolute; left: -0.8rem; top: 0; width: 1.6rem; height: 1.6rem; border-radius: 50%; background: var(--paper); border: 2px solid var(--ledger); color: var(--ledger); font-weight: 700; font-size: 0.85rem; display: grid; place-items: center; }
.steps li b { display: block; font-weight: 600; }
.steps li span { color: var(--ink-2); }

.tbl { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 0.95rem; margin: 0 0 1.5rem; }
.tbl th, .tbl td { text-align: left; padding: 0.55rem 0.75rem 0.55rem 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.tbl th { font-weight: 600; color: var(--ink-2); }
.back { display: inline-block; margin: 2.5rem 0 0; font-family: var(--sans); }

@media (max-width: 760px) {
  .sec { grid-template-columns: 1fr; padding: 2.25rem 0; }
  .hero { padding: 3.5rem 0 3rem; }
  .prose { font-size: 1.1rem; }
  .top nav { gap: 1rem; }
}
@media (prefers-reduced-motion: no-preference) {
  .hero h1, .hero .lede, .links { animation: rise 0.7s cubic-bezier(.2,.7,.2,1) both; }
  .hero .lede { animation-delay: 0.12s; }
  .links { animation-delay: 0.22s; }
  @keyframes rise { from { opacity: 0; transform: translateY(10px); } }
}
