/* Blog: archive + single, portfolio look */
body.mt-blog .site-header, body.mt-blog .site-footer, body.mt-blog #site-header, body.mt-blog #site-footer { display: none !important; }
body.mt-blog { background: var(--mtx-bg); color: var(--mtx-ink); font-family: "IBM Plex Sans", system-ui, sans-serif; margin: 0; }
body.mt-blog a { color: inherit; }
.mtb-wrap { max-width: 1240px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 56px); }

.mtb-header { position: sticky; top: 0; z-index: 80; background: color-mix(in srgb, var(--mtx-bg) 86%, transparent); -webkit-backdrop-filter: saturate(1.4) blur(10px); backdrop-filter: saturate(1.4) blur(10px); border-bottom: 1px solid var(--mtx-rule); }
body.admin-bar .mtb-header { top: 32px; }
.mtb-header-in { max-width: 1360px; margin: 0 auto; padding: 0 clamp(16px, 4vw, 56px); height: 64px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.mtb-brand { font-family: "Satoshi", system-ui, sans-serif; font-weight: 700; font-size: 18px; letter-spacing: -0.02em; text-decoration: none; }
.mtb-nav ul { display: flex; gap: clamp(14px, 2.2vw, 30px); list-style: none; margin: 0; padding: 0; align-items: center; }
.mtb-nav a { font-family: "IBM Plex Mono", monospace; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; color: var(--mtx-muted); }
.mtb-nav a:hover, .mtb-nav a[aria-current] { color: var(--mtx-ink); }
.mtb-nav a[aria-current] { box-shadow: 0 2px 0 var(--mtx-accent); padding-bottom: 4px; }

.mtb-hero { padding-top: clamp(56px, 10vh, 120px); padding-bottom: clamp(32px, 5vh, 56px); }
.mtb-label { font-family: "IBM Plex Mono", monospace; font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase; color: var(--mtx-accent); margin: 0 0 18px; }
.mtb-title { font-family: "Satoshi", system-ui, sans-serif; font-weight: 500; font-size: clamp(2.6rem, 6vw, 5.6rem); line-height: 1; letter-spacing: -0.045em; margin: 0; max-width: 16ch; }
.mtb-title em, .mtb-single-title em { font-family: "Fraunces", Georgia, serif; font-style: italic; font-weight: 400; color: var(--mtx-accent); letter-spacing: -0.02em; }
.mtb-lede { font-size: clamp(17px, 1.4vw, 20px); line-height: 1.55; color: var(--mtx-muted); max-width: 60ch; margin: 22px 0 0; }
.mtb-tools { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 40px; }
.mtb-cats { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 0; padding: 0; }
.mtb-cats a { display: inline-block; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--mtx-rule); text-decoration: none; font-size: 14px; transition: background-color .25s, border-color .25s; }
.mtb-cats a:hover { border-color: var(--mtx-ink); }
.mtb-cats a.is-on { background: #00282C; border-color: #00282C; color: #fff; }
html[data-theme="dark"] .mtb-cats a.is-on { background: #9AEDF7; border-color: #9AEDF7; color: #001819; }
.mtb-search input { font: inherit; font-size: 15px; padding: 10px 18px; border-radius: 999px; border: 1px solid var(--mtx-rule); background: var(--mtx-mist); color: var(--mtx-ink); min-width: 240px; }
.mtb-search input:focus { outline: 2px solid var(--mtx-accent); outline-offset: 2px; }

.mtb-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(20px, 2.4vw, 32px); padding-bottom: 24px; }
.mtb-card { display: flex; flex-direction: column; background: var(--mtx-card); border: 1px solid var(--mtx-rule); border-radius: 24px; overflow: hidden; transition: transform .45s cubic-bezier(.22,.61,.36,1), box-shadow .45s; }
.mtb-card:hover { transform: translateY(-4px); box-shadow: 0 28px 60px -36px rgba(0,40,44,.5); }
.mtb-thumb { display: block; aspect-ratio: 16 / 10; overflow: hidden; background: #00282C; }
.mtb-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .8s cubic-bezier(.22,.61,.36,1); }
.mtb-card:hover .mtb-thumb img { transform: scale(1.04); }
.mtb-thumb-ph { width: 100%; height: 100%; display: flex; align-items: flex-end; padding: 22px; box-sizing: border-box; background: radial-gradient(120% 120% at 90% 0%, #9AEDF7 0%, #0A4A50 45%, #00282C 100%); }
.mtb-thumb-ph span { font-family: "Fraunces", Georgia, serif; font-style: italic; font-size: 28px; color: #EBFBFC; }
.mtb-card-body { padding: 22px 24px 26px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.mtb-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: 0; font-family: "IBM Plex Mono", monospace; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--mtx-muted); }
.mtb-pill { padding: 4px 10px; border-radius: 999px; background: var(--mtx-mist); color: var(--mtx-accent) !important; text-decoration: none; }
.mtb-card-title { font-family: "Satoshi", system-ui, sans-serif; font-weight: 500; font-size: clamp(1.25rem, 1.6vw, 1.5rem); line-height: 1.2; letter-spacing: -0.025em; margin: 0; }
.mtb-card-title a { text-decoration: none; }
.mtb-card-title a:hover { color: var(--mtx-accent); }
.mtb-excerpt { margin: 0; color: var(--mtx-muted); line-height: 1.55; font-size: 15.5px; }
.mtb-more { margin-top: auto; font-family: "IBM Plex Mono", monospace; font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; color: var(--mtx-ink); }
.mtb-more span { display: inline-block; transition: transform .3s; }
.mtb-card:hover .mtb-more span { transform: translateX(5px); }
.mtb-card--feat { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.mtb-card--feat .mtb-thumb { aspect-ratio: auto; min-height: 380px; }
.mtb-card--feat .mtb-card-body { padding: clamp(28px, 3.4vw, 48px); justify-content: center; }
.mtb-card--feat .mtb-card-title { font-size: clamp(1.8rem, 3vw, 2.8rem); line-height: 1.08; }
.mtb-pages { display: flex; gap: 8px; justify-content: center; padding: 32px 0 80px; }
.mtb-pages .page-numbers { min-width: 44px; height: 44px; display: grid; place-items: center; border-radius: 999px; border: 1px solid var(--mtx-rule); text-decoration: none; }
.mtb-pages .current { background: #00282C; color: #fff; border-color: #00282C; }
.mtb-empty { border: 1px dashed var(--mtx-rule); border-radius: 24px; padding: 64px 32px; text-align: center; margin-bottom: 96px; color: var(--mtx-muted); }

/* Single */
.mtb-single-head { max-width: 860px; padding-top: clamp(40px, 8vh, 96px); }
.mtb-back { display: inline-block; margin-bottom: 32px; font-family: "IBM Plex Mono", monospace; font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase; text-decoration: none; color: var(--mtx-muted); }
.mtb-back:hover { color: var(--mtx-ink); }
.mtb-single-title { font-family: "Satoshi", system-ui, sans-serif; font-weight: 500; font-size: clamp(2.2rem, 5vw, 4.4rem); line-height: 1.04; letter-spacing: -0.04em; margin: 20px 0 0; }
.mtb-hero-img { max-width: 1240px; margin: 48px auto 0; padding: 0 clamp(16px, 4vw, 56px); }
.mtb-hero-img img { width: 100%; height: auto; max-height: 640px; object-fit: cover; border-radius: 28px; display: block; }
.mtb-share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 28px; }
.mtb-share-label { font-family: "IBM Plex Mono", monospace; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mtx-muted); margin-right: 6px; }
.mtb-share-btn { font: inherit; font-size: 14px; cursor: pointer; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--mtx-rule); background: transparent; color: var(--mtx-ink); text-decoration: none; transition: background-color .25s, border-color .25s; }
.mtb-share-btn:hover { background: #9AEDF7; border-color: #9AEDF7; color: #001819; }
.mtb-copy.is-done { background: #00282C; color: #fff; border-color: #00282C; }
.mtb-prose { max-width: 720px; margin: 0 auto; padding: clamp(40px, 6vh, 72px) clamp(16px, 4vw, 32px) 0; font-size: 19px; line-height: 1.75; }
.mtb-prose > * + * { margin-top: 1.1em; }
.mtb-prose h2, .mtb-prose h3, .mtb-prose h4 { font-family: "Satoshi", system-ui, sans-serif; font-weight: 500; letter-spacing: -0.03em; line-height: 1.15; margin-top: 2em; }
.mtb-prose h2 { font-size: 2rem; } .mtb-prose h3 { font-size: 1.5rem; }
.mtb-prose a { color: var(--mtx-accent); text-underline-offset: 3px; }
.mtb-prose img, .mtb-prose figure img { border-radius: 18px; max-width: 100%; height: auto; }
.mtb-prose figure { margin: 2em 0; } .mtb-prose figcaption { font-size: 14px; color: var(--mtx-muted); margin-top: 10px; text-align: center; }
.mtb-prose blockquote { margin: 2em 0; padding: 4px 0 4px 24px; border-left: 3px solid #9AEDF7; font-family: "Fraunces", Georgia, serif; font-style: italic; font-size: 1.35em; line-height: 1.45; }
.mtb-prose pre { background: #00282C; color: #EBFBFC; padding: 20px; border-radius: 16px; overflow: auto; font-size: 15px; }
.mtb-prose code { font-family: "IBM Plex Mono", monospace; font-size: .88em; background: var(--mtx-mist); padding: 2px 6px; border-radius: 6px; }
.mtb-prose pre code { background: none; padding: 0; }
.mtb-prose ul, .mtb-prose ol { padding-left: 1.3em; }
.mtb-prose hr { border: 0; border-top: 1px solid var(--mtx-rule); margin: 3em 0; }
.mtb-single-foot { max-width: 720px; padding-top: 48px; padding-bottom: 40px; }
.mtb-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.mtb-tags a { padding: 6px 14px; border-radius: 999px; background: var(--mtx-mist); text-decoration: none; font-size: 14px; }
.mtb-adjacent { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 40px; border-top: 1px solid var(--mtx-rule); padding-top: 24px; }
.mtb-adjacent a { text-decoration: none; font-family: "Satoshi", system-ui, sans-serif; font-size: 18px; line-height: 1.3; }
.mtb-adjacent a:hover { color: var(--mtx-accent); }
.mtb-adjacent small { display: block; font-family: "IBM Plex Mono", monospace; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: var(--mtx-muted); margin-bottom: 6px; }
.mtb-adjacent .is-next { text-align: right; }
.mtb-related { padding-top: 40px; padding-bottom: 64px; }
.mtb-h2 { font-family: "Satoshi", system-ui, sans-serif; font-weight: 500; font-size: clamp(1.8rem, 3vw, 2.6rem); letter-spacing: -0.035em; margin: 0 0 28px; }

.mtb-footer { border-top: 1px solid var(--mtx-rule); padding: 32px 0 48px; }
.mtb-footer .mtb-wrap { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }
.mtb-footer p { margin: 0; font-size: 14px; color: var(--mtx-muted); }

@media (max-width: 1023px) { .mtb-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .mtb-card--feat { grid-template-columns: 1fr; } .mtb-card--feat .mtb-thumb { min-height: 0; aspect-ratio: 16 / 9; } }
@media (max-width: 767px) {
  .mtb-grid { grid-template-columns: 1fr; }
  .mtb-nav li:nth-child(2), .mtb-nav li:nth-child(3), .mtb-nav li:nth-child(4) { display: none; }
  .mtb-search input { min-width: 0; width: 100%; } .mtb-search { width: 100%; }
  .mtb-prose { font-size: 17.5px; }
  body.admin-bar .mtb-header { top: 0; }
}
body.mt-blog .mtb-cats a.is-on, body.mt-blog .mtb-pages .current, body.mt-blog .mtb-copy.is-done { color: #fff; }
html[data-theme="dark"] body.mt-blog .mtb-cats a.is-on { color: #001819; }
body.mt-blog .mtb-share-btn:hover { color: #001819; }
.mtb-admin { display: flex; gap: 10px; margin: 0 0 20px; }
body.mt-blog .mtb-admin a { padding: 10px 18px; border-radius: 999px; background: #9AEDF7; color: #001819; text-decoration: none; font-size: 14px; font-weight: 500; }
body.mt-blog .mtb-admin a + a { background: transparent; border: 1px solid var(--mtx-rule); color: var(--mtx-ink); }
