/* Mako blog — matches www.mako-app.com for brand consistency */
@import url('https://fonts.googleapis.com/css2?family=Rubik:ital,wght@0,400;0,500;0,700;0,900;1,400;1,500&display=swap');

:root {
  --black: #0d0d0d;
  --purple: #5A31F5;
  --green: linear-gradient(135deg, #1EADF0 0%, #0AFB60 100%);
  --grey: #272727;
  --light-grey: #737373;
  --white: #FFFFFF;
  --agent-glow: rgba(30, 173, 240, 0.15);
  --content-max-width: 1200px;
  --content-padding: 2rem;
}

* {
  box-sizing: border-box;
}

body {
  background-color: var(--black);
  color: var(--white);
  font-family: "Rubik", sans-serif;
  font-optical-sizing: auto;
  margin: 0;
  font-weight: 500;
  font-style: normal;
  line-height: 1.5;
}

h1, h2, h3, h4 {
  font-family: "Rubik", sans-serif;
  font-optical-sizing: auto;
  font-weight: 900;
  margin: 30px 0;
  font-style: normal;
}

h1 { font-size: 2.5rem; margin-top: 0; }
h2 { font-size: 1.75rem; }
h3 { font-size: 1.35rem; }

.big-text   { font-size: 40px; }
.medium-text { font-size: 25px; }
.small-text { font-size: 18px; line-height: 24px; }
.tiny-text  { font-size: 16px; line-height: 21px; }

.highlight-green {
  background: var(--green);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* Layout — header and main share same width */
.blog-header {
  background: var(--black);
  border-bottom: 1px solid var(--grey);
}
.blog-header-inner {
  align-items: center;
  display: flex;
  flex-direction: row;
  justify-content: space-between;
  width: 95%;
  margin: 20px auto;
}
.blog-logo {
  font-weight: 900;
  font-size: 1.25rem;
}
.blog-logo a {
  color: var(--white);
  text-decoration: none;
}
.blog-nav a {
  text-decoration: none;
  margin-left: 1.5rem;
  font-size: 16px;
}
.blog-nav a:hover {
  color: var(--white);
}

main {
  max-width: var(--content-max-width);
  margin: 0 auto;
  padding: 2rem var(--content-padding) 4rem;
}

main:has(.home-layout) {
  max-width: var(--content-max-width);
  padding: 2rem var(--content-padding) 4rem;
}

/* ——— Home: two-column — left static, right scrollable ——— */
.home-layout {
  display: flex;
  gap: 3rem;
  align-items: flex-start;
  padding: 0;
  min-height: calc(100vh - 180px);
}

.home-static {
  flex: 0 0 320px;
  position: sticky;
  top: 2rem;
  text-align: left;
}
.home-static-title {
  font-size: clamp(2rem, 4vw, 3rem);
  margin: 0 0 2rem;
  text-align: center;
  letter-spacing: -0.02em;
}
.home-static-tagline {
  color: var(--light-grey);
  margin: 0 0 1.5rem;
  line-height: 1.5;
}

.home-posts-scroll {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  max-height: calc(100vh - 180px);
  padding-right: 0.5rem;
  margin-bottom: 2rem;
}
.home-posts-scroll::-webkit-scrollbar {
  width: 6px;
}
.home-posts-scroll::-webkit-scrollbar-track {
  background: var(--grey);
  border-radius: 3px;
}
.home-posts-scroll::-webkit-scrollbar-thumb {
  background: var(--light-grey);
  border-radius: 3px;
}

/* ——— Home: post grid (cards) in scroll container ——— */
.post-grid {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 1.25rem;
}
.post-card {
  display: block;
  background: var(--grey);
  border: 1px solid transparent;
  border-radius: 12px;
  padding: 1.5rem 1.75rem;
  text-decoration: none;
  color: var(--white);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.post-card:hover {
  border-color: rgba(30, 173, 240, 0.35);
  background: rgba(39, 39, 39, 0.9);
}
.post-card-title {
  font-weight: 700;
  font-size: 1.2rem;
  display: block;
  margin-bottom: 0.35rem;
}
.post-card:hover .post-card-title {
  background: var(--green);
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.post-card-meta {
  color: var(--light-grey);
  font-size: 0.875rem;
  display: block;
  margin-bottom: 0.5rem;
}
.post-card-desc {
  color: var(--light-grey);
  margin: 0 0 0.75rem;
  line-height: 1.45;
}
.post-card-link {
  font-size: 0.9rem;
  font-weight: 600;
  color: #1EADF0;
  transition: color 0.2s ease;
}
.post-card:hover .post-card-link {
  color: #0AFB60;
}
.post-card--empty {
  background: var(--grey);
  border-radius: 12px;
  padding: 2rem;
  border: 1px dashed var(--light-grey);
}
.post-card--empty code {
  background: var(--black);
  padding: 0.2em 0.5em;
  border-radius: 4px;
  font-size: 0.9em;
}

/* Index: legacy post list (e.g. if used elsewhere) */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.post-list li {
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--grey);
}
.post-list li:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}
.post-list a {
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.25rem;
  display: block;
  margin-bottom: 0.5rem;
}
.post-list a:hover {
  color: #1EADF0;
}
.post-meta {
  color: var(--light-grey);
  font-size: 0.9rem;
  margin-top: 0.25rem;
}

/* Single post */
.post-header {
  margin-bottom: 2rem;
}
.post-title {
  font-size: 2.25rem;
  margin: 0 0 0.5rem;
  line-height: 1.2;
}
.post-date {
  color: var(--light-grey);
  font-size: 0.95rem;
}

/* Markdown content */
.post-body h1,
.post-body h2,
.post-body h3 {
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}
.post-body h2 { font-size: 1.5rem; }
.post-body p {
  margin: 0 0 1rem;
  font-size: 1.05rem;
  line-height: 1.65;
}
.post-body a {
  color: #1EADF0;
  text-decoration: none;
}
.post-body a:hover {
  text-decoration: underline;
}
.post-body ul, .post-body ol {
  margin: 0 0 1rem;
  padding-left: 1.5rem;
}
.post-body code {
  background: var(--grey);
  padding: 0.15em 0.4em;
  border-radius: 4px;
  font-size: 0.9em;
}
.post-body pre {
  background: var(--grey);
  padding: 1rem;
  border-radius: 8px;
  overflow-x: auto;
  margin: 1rem 0;
}
.post-body pre code {
  background: none;
  padding: 0;
}
.post-body blockquote {
  border-left: 4px solid var(--purple);
  margin: 1.5rem 0;
  padding-left: 1rem;
  color: var(--light-grey);
}

/* CTA blocks — edit in templates for conversion */
.cta-block {
  background: var(--grey);
  border: 1px solid rgba(30, 173, 240, 0.12);
  border-radius: 12px;
  padding: 1.5rem;
  margin: 2.5rem auto;
  width: max-content;
  max-width: 60%;
  text-align: center;
}

.cta-block h3 {
  margin-top: 0;
  margin-bottom: 0rem;
  font-size: 1.35rem;
}
.cta-block p {
  color: var(--light-grey);
  margin-bottom: 1.25rem;
  font-size: 1rem;
}
.cta-block > .cta-button {
  margin-top: 1.25rem;
  display: block;
  margin: auto;
  width: max-content;
}

.cta-block--inline {
  margin: 0;
  padding: 1.5rem;
  width: -webkit-fill-available;
  text-align: left;
  max-width: none;
}

.cta-block--inline .cta-button {
  width: 100%;
  text-align: center;
}
.cta-block--inline h3 {
  margin-bottom: 0.35rem;
}
.cta-block--inline p {
  margin-bottom: 1rem;
}
.cta-button {
  -webkit-appearance: none;
  appearance: none;
  background: var(--purple);
  border: none;
  border-radius: 10px;
  box-shadow: 0 6px 8px #00000059;
  color: var(--white);
  cursor: pointer;
  font-size: 16px;
  font-weight: 600;
  gap: 10px;
  justify-content: center;
  padding: 12px 14px;
  text-decoration: none;
  transition: transform .08s ease,opacity .12s ease,background .12s ease,border-color .12s ease;
  -webkit-user-select: none;
  user-select: none;
}

/* Footer */
.blog-footer {
  border-top: 1px solid var(--grey);
  padding: 2rem;
  text-align: center;
  color: var(--light-grey);
  font-size: 0.9rem;
}
.blog-footer a {
  color: #1EADF0;
  text-decoration: none;
}
.blog-footer a:hover {
  text-decoration: underline;
}

@media screen and (max-width: 800px) {
  .big-text   { font-size: 30px; }
  .medium-text { font-size: 22px; }
  .small-text { font-size: 14px; line-height: 18px; }
  .tiny-text  { font-size: 12px; }
  .blog-header { padding-left: 1rem; padding-right: 1rem; }
  .blog-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }
  .blog-nav a{
    display: none;
  }
  .cta-block{
    max-width: 100%;
  }
  .blog-logo img {
    width: 156px;
    height: auto;
  }
  .post-title { font-size: 1.75rem; }
  main { padding: 1.5rem 1rem 3rem; }
  main:has(.home-layout) { padding: 2rem 1rem 3rem; }
  .home-layout {
    flex-direction: column;
    min-height: 0;
    gap: 2rem;
  }
  .home-static {
    position: static;
    flex: none;
    width: 100%;
  }
  .home-static-title { font-size: 2rem; }
  .home-posts-scroll {
    max-height: none;
    overflow: visible;
    padding-right: 0;
  }
  .post-card { padding: 1.25rem 1.5rem; }
  .post-card-title { font-size: 1.1rem; }
}
