/* Blog Content Typography - Dark Theme (aiden) */

@layer utilities {
  .aiden-blog {
    font-family:
      "PingFang SC",
      "PingFang TC",
      -apple-system,
      BlinkMacSystemFont,
      sans-serif;
  }
  .aiden-blog [id] {
    scroll-margin-top: calc(var(--height-header) + 20px);
  }
}

.markdown > *:first-child {
  margin-top: 0;
}

.markdown h1,
.markdown h2,
.markdown h3,
.markdown h4,
.markdown h5,
.markdown h6 {
  margin-top: 16px;
  margin-bottom: 16px;
  font-weight: 500;
  line-height: 1.25;
  color: #ffffff;
}

.markdown h1 {
  font-size: 2em;
  font-weight: 700;
  padding-bottom: 0.3em;
}

.markdown h2 {
  font-size: 1.7em;
  padding-bottom: 0.3em;
  margin-top: 50px;
  font-weight: 700;
}

.markdown h3 {
  font-size: 1.4em;
  padding-bottom: 0.2em;
  font-weight: 400;
}

.markdown h4 {
  font-size: 1.25em;
}

.markdown h5 {
  font-size: 0.875em;
}

.markdown h6 {
  font-size: 0.85em;
  color: #9ca3af;
}

.markdown p {
  margin-bottom: 16px;
  line-height: 1.6;
  color: #d1d5db;
  font-size: 1em;
}

.markdown ul,
.markdown ol {
  margin-bottom: 16px;
  padding-left: 2em;
  line-height: 1.6;
  color: #d1d5db;
}

.markdown ul {
  list-style-type: disc;
}

.markdown ol {
  list-style-type: decimal;
}

.markdown li {
  margin-bottom: 0.25em;
}

.markdown li > p {
  margin-bottom: 0.5em;
}

.markdown li a {
  word-break: break-word;
  overflow-wrap: break-word;
}

.markdown a {
  color: #ff5a00;
  text-decoration: none;
}

.markdown a:hover {
  color: #ff5a00;
  text-decoration: underline;
}

.markdown strong {
  font-weight: 600;
  color: #ffffff;
}

.markdown em {
  font-style: italic;
}

.markdown code {
  background-color: #374151;
  color: #fca5a5;
  padding: 0.2em 0.4em;
  margin: 0;
  font-size: 85%;
  border-radius: 6px;
  font-family:
    ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, "Liberation Mono",
    monospace;
}

.markdown pre {
  margin-bottom: 16px;
  padding: 16px;
  overflow: auto;
  font-size: 85%;
  line-height: 1.45;
  background-color: #1f2937;
  border-radius: 6px;
  border: 1px solid #374151;
}

.markdown pre code {
  background-color: transparent;
  color: #e5e7eb;
  padding: 0;
  margin: 0;
  font-size: 100%;
  border-radius: 0;
}

.markdown blockquote {
  margin-bottom: 16px;
  padding: 0 1em;
  color: #9ca3af;
  border-left: 0.25em solid #ffffff;
  background-color: rgba(255, 255, 255, 0.03);
}

.markdown blockquote > :first-child {
  margin-top: 0;
}

.markdown blockquote > :last-child {
  margin-bottom: 0;
}

.markdown hr {
  height: 1px;
  padding: 0;
  margin: 16px 0;
  background-color: #374151;
  border: 0;
}

.markdown table {
  display: block;
  margin-bottom: 16px;
  border-spacing: 0;
  border-collapse: collapse;
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.markdown table th {
  font-weight: 600;
  padding: 6px 13px;
  border: 1px solid #4b5563;
  background-color: #1f2937;
  color: #ffffff;
}

.markdown table td {
  padding: 6px 13px;
  border: 1px solid #4b5563;
  color: #d1d5db;
}

.markdown table tr {
  background-color: #111827;
  border-top: 1px solid #4b5563;
}

.markdown table tr:nth-child(2n) {
  background-color: #1f2937;
}

.markdown img {
  max-width: 100%;
  width: 100%;
  height: auto;
  max-height: 600px;
  object-fit: contain;
  margin-top: 21px;
  margin-bottom: 16px;
  border: 1px solid #374151;
  border-radius: 8px;
}

.markdown dl {
  margin-bottom: 16px;
  padding: 0;
}

.markdown dt {
  padding: 0;
  margin-top: 21px;
  font-size: 1em;
  font-style: italic;
  font-weight: 600;
  color: #ffffff;
}

.markdown dd {
  padding: 0 16px;
  margin-bottom: 16px;
  color: #d1d5db;
}

.markdown .highlight {
  margin-bottom: 16px;
}

.markdown .task-list-item {
  list-style-type: none;
}

.markdown .task-list-item input[type="checkbox"] {
  margin: 0 0.2em 0.25em -1.6em;
  vertical-align: middle;
}

.markdown .anchor {
  float: left;
  padding-right: 4px;
  margin-left: -20px;
  line-height: 1;
}

.markdown .mermaid {
  margin-bottom: 16px;
  background-color: #1f2937;
  border: 1px solid #374151;
  padding: 16px;
  border-radius: 6px;
}

.markdown h1:hover .anchor,
.markdown h2:hover .anchor,
.markdown h3:hover .anchor,
.markdown h4:hover .anchor,
.markdown h5:hover .anchor,
.markdown h6:hover .anchor {
  text-decoration: none;
}

.markdown .hash-link {
  opacity: 0;
  padding-left: 8px;
  transition: opacity 0.2s;
  color: #6b7280;
}

.markdown h1:hover .hash-link,
.markdown h2:hover .hash-link,
.markdown h3:hover .hash-link,
.markdown h4:hover .hash-link,
.markdown h5:hover .hash-link,
.markdown h6:hover .hash-link {
  opacity: 1;
}

/* TOC active link */
#toc .active,
[data-toc] .active {
  color: #ffffff;
}

/* Dedicated blog post */

.blog-post {
  min-height: 100vh;
  overflow: visible;
  background: #000;
  color: #f5f5f7;
  font-family: Geist, "PingFang SC", system-ui, sans-serif;
}

.blog-post__article {
  width: 100%;
  max-width: 1500px;
  margin: 98px auto 0;
  padding: 36px 40px 150px;
  border-top: 1px solid rgba(255, 255, 255, 0.095);
}

.blog-post__header {
  display: flex;
  align-items: center;
  flex-direction: column;
}

.blog-post__back {
  position: relative;
  display: inline-flex;
  height: 36px;
  align-items: center;
  justify-content: center;
  gap: 11px;
  padding: 0 17px 0 13px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  background:
    radial-gradient(90% 160% at 8% -70%, rgba(255, 255, 255, 0.13), transparent 68%),
    #1d1d1d;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.055);
  color: rgba(255, 255, 255, 0.66);
  font-size: 14px;
  line-height: 1;
  text-decoration: none;
  transition:
    border-color 220ms ease,
    color 220ms ease,
    background 220ms ease,
    transform 180ms ease;
}

.blog-post__back > span:first-child {
  color: #ff5a00;
  font-size: 25px;
  line-height: 0;
  transform: translateY(-1px);
}

.blog-post__back:hover,
.blog-post__back:focus-visible {
  border-color: rgba(255, 255, 255, 0.25);
  background-color: #262626;
  color: #fff;
  outline: none;
}

.blog-post__back:active {
  transform: scale(0.97);
}

.blog-post__header h1 {
  max-width: 820px;
  margin: 46px auto 0;
  color: #f4f4f5;
  font-size: clamp(42px, 3.15vw, 54px);
  line-height: 1.12;
  font-weight: 300;
  letter-spacing: -0.038em;
  text-align: center;
  text-wrap: balance;
}

.blog-post__layout {
  display: grid;
  grid-template-columns: 210px minmax(0, 760px) 230px;
  justify-content: center;
  gap: clamp(44px, 4.4vw, 78px);
  margin-top: 62px;
}

.blog-post__toc,
.blog-post__author {
  position: sticky;
  top: 120px;
  align-self: start;
}

.blog-post__toc[hidden] {
  display: none;
}

.blog-post__toc > p {
  margin: 0 0 22px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 16px;
  line-height: 1.25;
  font-weight: 400;
}

.blog-post__toc nav {
  display: flex;
  align-items: flex-start;
  flex-direction: column;
  gap: 22px;
}

.blog-post__toc nav a {
  display: block;
  color: rgba(255, 255, 255, 0.43);
  font-size: 13px;
  line-height: 1.6;
  font-weight: 300;
  text-decoration: none;
  transition: color 200ms ease;
}

.blog-post__toc nav a:hover,
.blog-post__toc nav a:focus-visible,
.blog-post__toc nav a.active {
  color: rgba(255, 255, 255, 0.88);
  outline: none;
}

.blog-post__main {
  min-width: 0;
}

.blog-post__hero {
  position: relative;
  aspect-ratio: 16 / 9;
  margin: 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.085);
  border-radius: 10px;
  background: #080808;
}

.blog-post__hero::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.025), transparent 24%);
}

.blog-post__hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-post__content {
  margin-top: 44px;
  color: rgba(255, 255, 255, 0.62);
  font-size: clamp(17px, 1.12vw, 21px);
  font-weight: 300;
  letter-spacing: -0.018em;
}

.blog-post__main--no-hero .blog-post__content {
  margin-top: 0;
}

.blog-post__content p {
  margin-bottom: 22px;
  color: rgba(255, 255, 255, 0.61);
  font-size: 1em;
  line-height: 1.72;
}

.blog-post__content h1,
.blog-post__content h2,
.blog-post__content h3,
.blog-post__content h4,
.blog-post__content h5,
.blog-post__content h6 {
  color: #f2f2f3;
  font-weight: 400;
  letter-spacing: -0.035em;
}

.blog-post__content h2 {
  margin-top: 58px;
  margin-bottom: 22px;
  padding: 0;
  font-size: clamp(31px, 2.15vw, 40px);
  line-height: 1.18;
}

.blog-post__content h3 {
  margin-top: 42px;
  font-size: clamp(24px, 1.7vw, 30px);
}

.blog-post__content h1 {
  margin-top: 58px;
  margin-bottom: 22px;
  font-size: clamp(34px, 2.4vw, 44px);
  line-height: 1.14;
}

.blog-post__content h4 {
  margin-top: 34px;
  font-size: clamp(20px, 1.4vw, 24px);
}

.blog-post__content h5,
.blog-post__content h6 {
  margin-top: 28px;
  font-size: clamp(17px, 1.15vw, 20px);
}

.blog-post__content ul,
.blog-post__content ol {
  color: rgba(255, 255, 255, 0.61);
  line-height: 1.72;
}

.blog-post__content img {
  border-color: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

.blog-post__author {
  min-width: 0;
}

.blog-post__author-heading {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 12px;
}

.blog-post__avatar {
  display: block;
  width: 50px;
  height: 50px;
  flex: 0 0 50px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  background: #161616;
}

.blog-post__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.blog-post__author-name {
  min-width: 0;
  color: rgba(255, 255, 255, 0.8);
  font-size: 15px;
  line-height: 1.35;
  font-weight: 400;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: color 200ms ease;
}

.blog-post__author-name:hover,
.blog-post__author-name:focus-visible {
  color: #fff;
  outline: none;
}

.blog-post__author-bio {
  margin: 19px 0 0;
  color: rgba(255, 255, 255, 0.43);
  font-size: 13px;
  line-height: 1.65;
  font-weight: 300;
  overflow-wrap: anywhere;
}

.blog-post__author time {
  display: block;
  margin-top: 22px;
  color: rgba(255, 255, 255, 0.38);
  font-size: 13px;
  line-height: 1;
  font-weight: 300;
}

.blog-post__share {
  display: flex;
  align-items: center;
  flex-direction: column;
  gap: 24px;
  margin-top: 112px;
}

.blog-post__share > p {
  margin: 0;
  color: rgba(255, 255, 255, 0.53);
  font-size: 14px;
  line-height: 1;
  font-weight: 300;
}

.blog-post__share ul {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 34px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.blog-post__share a {
  display: flex;
  height: 28px;
  align-items: center;
  justify-content: center;
  color: #fff;
  opacity: 0.68;
  transition:
    opacity 180ms ease,
    transform 200ms ease;
}

.blog-post__share a:hover,
.blog-post__share a:focus-visible {
  opacity: 1;
  outline: none;
  transform: translateY(-2px);
}

.blog-post__share a > svg {
  width: 24px;
  height: 24px;
  fill: currentcolor;
}

.blog-post__share .blog-post__medium-icon {
  width: 32px;
  height: 20px;
}

.blog-post__share .blog-post__linkedin-icon {
  width: 78px;
  height: auto;
}

.blog-post__share .blog-post__linkedin-icon path {
  fill: #fff;
}

.blog-post__related {
  max-width: calc(1200px + clamp(44px, 4.4vw, 78px) + clamp(44px, 4.4vw, 78px));
  margin: 112px auto 0;
  padding-top: 52px;
  border-top: 1px solid rgba(255, 255, 255, 0.09);
}

.blog-post__related > h2 {
  margin: 0 0 34px;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(24px, 2vw, 32px);
  line-height: 1.15;
  font-weight: 300;
  letter-spacing: -0.025em;
}

.blog-post__related .blog-post__related-grid {
  padding-top: 0;
}

@media (max-width: 1100px) {
  .blog-post__article {
    max-width: 840px;
  }

  .blog-post__layout {
    grid-template-columns: minmax(0, 760px);
    gap: 32px;
  }

  .blog-post__toc {
    display: none;
  }

  .blog-post__author {
    position: static;
    top: auto;
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 30px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.09);
    text-align: center;
  }

  .blog-post__author-heading {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 10px;
  }

  .blog-post__avatar {
    width: 52px;
    height: 52px;
    flex-basis: 52px;
  }

  .blog-post__author-name {
    align-self: center;
  }

  .blog-post__author-bio {
    width: 100%;
    max-width: 560px;
    margin: 0;
  }

  .blog-post__author time {
    align-self: center;
    margin-top: 0;
    line-height: 1.35;
  }
}

@media (max-width: 700px) {
  .blog-post__article {
    margin-top: 58px;
    padding: 28px 24px 100px;
  }

  .blog-post__back {
    height: 34px;
    font-size: 13px;
  }

  .blog-post__header h1 {
    margin-top: 36px;
    font-size: clamp(32px, 8.5vw, 34px);
    line-height: 1.14;
  }

  .blog-post__layout {
    margin-top: 44px;
  }

  .blog-post__author {
    padding-bottom: 24px;
  }

  .blog-post__hero {
    border-radius: 8px;
  }

  .blog-post__content {
    margin-top: 34px;
    font-size: 17px;
  }

  .blog-post__content p {
    margin-bottom: 18px;
    line-height: 1.68;
  }

  .blog-post__content h2 {
    margin-top: 46px;
    font-size: 30px;
  }

  .blog-post__share {
    margin-top: 82px;
  }

  .blog-post__share ul {
    gap: 28px;
  }

  .blog-post__share a {
    height: 24px;
  }

  .blog-post__share a > svg {
    width: 20px;
    height: 20px;
  }

  .blog-post__share .blog-post__medium-icon {
    width: 27px;
    height: 17px;
  }

  .blog-post__share .blog-post__linkedin-icon {
    width: 66px;
  }

  .blog-post__related {
    margin-top: 82px;
    padding-top: 38px;
  }

  .blog-post__related > h2 {
    margin-bottom: 24px;
  }
}

/* Blog archive */

.blog-archive {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  background: #000;
  color: #f5f5f7;
  font-family: Geist, "PingFang SC", system-ui, sans-serif;
}

.blog-archive__container {
  position: relative;
  z-index: 1;
  padding-top: clamp(52px, 5vw, 88px);
  padding-bottom: 320px;
}

.blog-archive__content {
  width: 100%;
  max-width: 1692px;
  margin: 0 auto;
}

.blog-archive__header {
  padding: 0 4px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.blog-archive__eyebrow {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  line-height: 1;
  font-weight: 400;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.blog-archive__eyebrow > span:first-child {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  background: #ff5a00;
}

.blog-archive__header h1 {
  margin: 19px 0 0;
  color: #f5f5f7;
  font-size: clamp(42px, 3.2vw, 60px);
  line-height: 0.94;
  font-weight: 300;
  letter-spacing: -0.045em;
  text-transform: uppercase;
}

.blog-archive__toolbar {
  display: flex;
  min-height: 82px;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 18px 2px;
}

.blog-tabs {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: clamp(8px, 1.25vw, 18px);
}

.blog-tab {
  position: relative;
  isolation: isolate;
  display: inline-flex;
  min-width: 72px;
  height: 36px;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: 0 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: rgba(255, 255, 255, 0.5);
  box-shadow: none;
  font: inherit;
  font-size: 15px;
  line-height: 1;
  font-weight: 400;
  text-decoration: none;
  cursor: pointer;
  transition:
    color 240ms ease,
    border-color 360ms ease,
    background 360ms ease,
    box-shadow 360ms ease,
    transform 180ms ease;
}

.blog-tab > span {
  position: relative;
  z-index: 2;
}

.blog-tab:hover,
.blog-tab:focus-visible {
  border-color: rgba(255, 255, 255, 0.18);
  color: #fff;
  outline: none;
}

.blog-tab:active {
  transform: scale(0.97);
}

.blog-tab.is-active {
  border-color: rgba(255, 255, 255, 0.2);
  background:
    radial-gradient(90% 170% at 10% -70%, rgba(255, 255, 255, 0.22), transparent 68%),
    linear-gradient(125deg, #353535 0%, #252525 58%, #303030 100%);
  color: #fff;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.17),
    inset 0 -1px 0 rgba(255, 255, 255, 0.055),
    0 6px 16px rgba(0, 0, 0, 0.22);
}

.blog-border-glow {
  position: absolute;
  z-index: 3;
  left: 50%;
  width: 88%;
  height: 1px;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(
    90deg,
    rgba(221, 222, 227, 0) 0%,
    #dddee3 40%,
    #dddee3 60%,
    rgba(221, 222, 227, 0) 100%
  );
  transform: translateX(-50%) scaleX(0);
  will-change: opacity, transform;
}

.blog-border-glow--top {
  top: 0;
}

.blog-border-glow--bottom {
  bottom: 0;
}

.blog-tab:hover .blog-border-glow--top,
.blog-tab:focus-visible .blog-border-glow--top,
.blog-post__back:hover .blog-border-glow--top,
.blog-post__back:focus-visible .blog-border-glow--top,
.blog-search:hover .blog-border-glow--top,
.blog-search:focus-within .blog-border-glow--top {
  animation: blog-border-glow 4s linear infinite;
}

.blog-tab:hover .blog-border-glow--bottom,
.blog-tab:focus-visible .blog-border-glow--bottom,
.blog-post__back:hover .blog-border-glow--bottom,
.blog-post__back:focus-visible .blog-border-glow--bottom,
.blog-search:hover .blog-border-glow--bottom,
.blog-search:focus-within .blog-border-glow--bottom {
  animation: blog-border-glow-reverse 4s linear infinite;
}

.blog-search {
  position: relative;
  isolation: isolate;
  display: flex;
  width: clamp(180px, 14vw, 232px);
  height: 34px;
  flex: 0 0 auto;
  align-items: center;
  gap: 9px;
  padding: 0 14px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 999px;
  background:
    radial-gradient(90% 160% at 8% -75%, rgba(255, 255, 255, 0.12), transparent 66%),
    rgba(31, 31, 31, 0.78);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.055);
  color: rgba(255, 255, 255, 0.35);
  transition:
    border-color 240ms ease,
    background 240ms ease,
    box-shadow 240ms ease;
}

.blog-search:hover,
.blog-search:focus-within {
  border-color: rgba(255, 255, 255, 0.32);
  background-color: rgba(39, 39, 39, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 0 0 3px rgba(255, 255, 255, 0.035);
}

.blog-search svg {
  width: 14px;
  height: 14px;
  flex: 0 0 14px;
  fill: none;
  stroke: currentcolor;
  stroke-width: 1.6;
  stroke-linecap: round;
}

.blog-search input {
  width: 100%;
  min-width: 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: rgba(255, 255, 255, 0.88);
  font: inherit;
  font-size: 12px;
  line-height: 1;
}

.blog-search input::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.blog-search input::-webkit-search-cancel-button {
  cursor: pointer;
  filter: invert(1);
  opacity: 0.45;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 532px));
  justify-content: center;
  column-gap: clamp(28px, 2.5vw, 48px);
  row-gap: 40px;
  padding-top: 12px;
}

.home-blog__viewport {
  width: 100vw;
  margin-top: 40px;
  margin-left: calc(50% - 50vw);
  overflow-x: auto;
  overflow-y: hidden;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  touch-action: pan-x pan-y;
}

.home-blog__viewport::-webkit-scrollbar {
  display: none;
}

.home-blog__grid {
  --home-blog-gap: clamp(28px, 2.5vw, 48px);
  --home-blog-card-count: 7;
  --home-blog-card-width: min(
    532px,
    calc(
      (
          100vw
          - var(--ad-container-left, 40px)
          - var(--ad-container-left, 40px)
          - var(--home-blog-gap)
          - var(--home-blog-gap)
        ) / 3
    )
  );

  display: grid;
  grid-template-columns: repeat(
    var(--home-blog-card-count),
    var(--home-blog-card-width)
  );
  width: max-content;
  column-gap: var(--home-blog-gap);
  row-gap: 40px;
  padding-top: 12px;
}

@media (max-width: 1100px) {
  .home-blog__grid {
    --home-blog-gap: 28px;
    --home-blog-card-width: min(
      532px,
      calc(
        (
            100vw
            - var(--ad-container-left, 40px)
            - var(--ad-container-left, 40px)
            - var(--home-blog-gap)
          ) / 2
      )
    );
  }
}

@media (max-width: 760px) {
  .home-blog__grid {
    --home-blog-gap: 16px;
    --home-blog-card-width: min(
      532px,
      calc(100vw - var(--ad-container-left, 24px) * 2)
    );
    padding-top: 14px;
  }
}

.blog-card {
  --blog-glow-x: 50%;
  --blog-glow-y: 50%;
  --blog-glow-opacity: 0;

  position: relative;
  isolation: isolate;
  display: flex;
  min-width: 0;
  min-height: 510px;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 14px;
  background: rgba(23, 23, 23, 0.85);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.025);
  transition:
    background-color 360ms ease,
    box-shadow 420ms ease;
}

.blog-card:hover,
.blog-card:focus-within {
  background-color: rgba(25, 25, 25, 0.92);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.045),
    0 14px 38px rgba(0, 0, 0, 0.26);
}

.blog-card__hover-surface {
  position: absolute;
  z-index: 2;
  inset: 0;
  padding: 1px;
  border-radius: inherit;
  opacity: var(--blog-glow-opacity);
  pointer-events: none;
  background: radial-gradient(
    490px circle at var(--blog-glow-x) var(--blog-glow-y),
    rgba(255, 255, 255, 0.3),
    rgba(255, 255, 255, 0.12) 28%,
    transparent 62%
  );
  transition: opacity 240ms ease;
  will-change: opacity;
  -webkit-mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#000 0 0) content-box,
    linear-gradient(#000 0 0);
  mask-composite: exclude;
}

.blog-card.is-pointer-active,
.blog-card:focus-within {
  --blog-glow-opacity: 1;
}

.blog-card__media {
  position: relative;
  z-index: 1;
  aspect-ratio: 16 / 8.4;
  margin: 14px 14px 0;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  background: #050505;
}

.blog-card__media::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.035), transparent 28%);
}

.blog-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition:
    transform 600ms cubic-bezier(0.16, 1, 0.3, 1),
    filter 420ms ease;
  will-change: transform;
}

.blog-card:hover .blog-card__media img,
.blog-card:focus-within .blog-card__media img {
  filter: brightness(1.07);
  transform: scale(1.1);
}

.blog-card__content {
  position: relative;
  z-index: 1;
  display: flex;
  min-height: 224px;
  flex: 1;
  flex-direction: column;
  padding: 30px 30px 28px;
}

.blog-card__title {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: #f2f2f3;
  font-size: clamp(19px, 1.35vw, 24px);
  line-height: 1.28;
  font-weight: 400;
  letter-spacing: -0.025em;
  transition: color 240ms ease;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.blog-card:hover .blog-card__title,
.blog-card:focus-within .blog-card__title {
  color: #fff;
}

.blog-card__content p {
  display: -webkit-box;
  margin: 15px 0 0;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.45);
  font-size: clamp(13px, 0.88vw, 16px);
  line-height: 1.45;
  font-weight: 300;
  letter-spacing: -0.012em;
  transition: color 240ms ease;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.blog-card:hover .blog-card__content p,
.blog-card:focus-within .blog-card__content p {
  color: rgba(255, 255, 255, 0.62);
}

.blog-card__content time {
  margin-top: auto;
  padding-top: 28px;
  color: rgba(255, 255, 255, 0.43);
  font-size: 14px;
  line-height: 1;
  font-weight: 300;
  letter-spacing: 0.005em;
}

.blog-card__link {
  position: absolute;
  z-index: 5;
  inset: 0;
  border-radius: inherit;
}

.blog-card__link:focus-visible {
  outline: 1px solid rgba(255, 255, 255, 0.8);
  outline-offset: -4px;
}

.blog-grid__empty {
  margin: 0;
  padding: 100px 20px;
  text-align: center;
  color: rgba(255, 255, 255, 0.45);
  font-size: 16px;
}

.blog-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 54px;
  font-size: 13px;
}

.blog-pagination a,
.blog-pagination .current {
  display: flex;
  min-width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.58);
  transition:
    color 200ms ease,
    border-color 200ms ease,
    background 200ms ease;
}

.blog-pagination a:hover,
.blog-pagination a:focus-visible,
.blog-pagination .current {
  border-color: rgba(255, 255, 255, 0.24);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  outline: none;
}

.blog-archive .blog-bottom-mask {
  position: absolute;
  right: -180px;
  bottom: 0;
  left: -180px;
}

@keyframes blog-border-glow {
  0% {
    opacity: 0;
    transform: translateX(-50%) scaleX(0);
    transform-origin: left center;
  }
  3% {
    opacity: 1;
  }
  45%,
  54.99% {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
    transform-origin: left center;
  }
  55% {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
    transform-origin: right center;
  }
  97% {
    opacity: 1;
    transform: translateX(-50%) scaleX(0);
    transform-origin: right center;
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) scaleX(0);
    transform-origin: right center;
  }
}

@keyframes blog-border-glow-reverse {
  0% {
    opacity: 0;
    transform: translateX(-50%) scaleX(0);
    transform-origin: right center;
  }
  3% {
    opacity: 1;
  }
  45%,
  54.99% {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
    transform-origin: right center;
  }
  55% {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
    transform-origin: left center;
  }
  97% {
    opacity: 1;
    transform: translateX(-50%) scaleX(0);
    transform-origin: left center;
  }
  100% {
    opacity: 0;
    transform: translateX(-50%) scaleX(0);
    transform-origin: left center;
  }
}

@media (max-width: 1100px) {
  .blog-grid {
    grid-template-columns: repeat(2, minmax(0, 532px));
  }

  .blog-card__title {
    font-size: 22px;
  }

  .blog-card__content p {
    font-size: 15px;
  }
}

@media (max-width: 760px) {
  .blog-archive__container {
    padding-top: 54px;
    padding-bottom: 220px;
  }

  .blog-archive__header {
    padding-right: 0;
    padding-bottom: 18px;
    padding-left: 0;
  }

  .blog-archive__eyebrow {
    font-size: 11px;
  }

  .blog-archive__eyebrow > span:first-child {
    width: 12px;
    height: 12px;
    flex-basis: 12px;
  }

  .blog-archive__header h1 {
    margin-top: 16px;
    font-size: 42px;
  }

  .blog-archive__toolbar {
    align-items: stretch;
    flex-direction: column;
    gap: 15px;
    padding: 15px 0 17px;
  }

  .blog-tabs {
    width: calc(100% + 24px);
    margin-right: -24px;
    padding-right: 24px;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .blog-tabs::-webkit-scrollbar {
    display: none;
  }

  .blog-tab {
    min-width: 66px;
    height: 34px;
    padding: 0 15px;
    font-size: 14px;
  }

  .blog-search {
    width: 100%;
    height: 38px;
  }

  .blog-search input {
    font-size: 16px;
  }

  .blog-grid {
    grid-template-columns: minmax(0, 532px);
    row-gap: 16px;
    padding-top: 14px;
  }

  .blog-card {
    min-height: 0;
    border-radius: 13px;
  }

  .blog-card__media {
    margin: 11px 11px 0;
    border-radius: 9px;
  }

  .blog-card__content {
    min-height: 220px;
    padding: 25px 22px 24px;
  }

  .blog-card__title {
    font-size: 21px;
  }

  .blog-card__content p {
    margin-top: 12px;
    font-size: 14px;
  }

  .blog-card__content time {
    padding-top: 24px;
    font-size: 13px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .blog-border-glow {
    animation: none !important;
  }

  .blog-tab,
  .blog-card,
  .blog-card__hover-surface,
  .blog-card__media img {
    transition-duration: 1ms;
  }

  .blog-tab:hover .blog-border-glow,
  .blog-tab:focus-visible .blog-border-glow,
  .blog-post__back:hover .blog-border-glow,
  .blog-post__back:focus-visible .blog-border-glow,
  .blog-search:hover .blog-border-glow,
  .blog-search:focus-within .blog-border-glow {
    opacity: 1;
    transform: translateX(-50%) scaleX(1);
  }
}
