/* ==========================================
   BLOG PAGE

   CONTENTS
   01. Blog Hero
   02. Blog Articles

   BREAKPOINTS
   1100px / 900px / 800px / 700px / 600px / 480px / 400px
========================================== */


/* ==========================================
   01. BLOG HERO
========================================== */

.blog-hero__panel {
  display: grid;
  grid-template-columns:
    minmax(0, 0.96fr)
    minmax(0, 1.04fr);
  align-items: stretch;
  gap: 28px;

  padding: 16px;
}

.blog-hero__content {
  display: flex;
  flex-direction: column;
  justify-content: center;

  min-width: 0;
}

.blog-hero__title {
  max-width: 20ch;
}

.blog-hero__description {
  max-width: 610px;
  margin: 0 0 34px;

  font-size: 18px;
  line-height: 1.7;

  color: var(--color-text-soft);
}

.blog-hero__stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));

  overflow: hidden;

  border: 1px solid rgba(99, 119, 242, 0.16);
  border-radius: 20px;
}

.blog-hero-stat {
  min-width: 0;
  padding: 23px 24px;

  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.98),
      rgba(245, 247, 255, 0.9)
    );
}

.blog-hero-stat:nth-child(odd) {
  border-right: 1px solid rgba(99, 119, 242, 0.14);
}

.blog-hero-stat:nth-child(-n + 2) {
  border-bottom: 1px solid rgba(99, 119, 242, 0.14);
}

.blog-hero-stat__value {
  display: block;
  margin-bottom: 7px;

  font-family: var(--font-heading);
  font-size: 36px;
  font-weight: 400;
  line-height: 1;

  color: var(--color-accent);
}

.blog-hero-stat__label {
  display: block;

  font-size: 14px;
  font-weight: 700;
  line-height: 1.4;

  color: var(--color-text-soft);
}

.blog-hero__media {
  position: relative;
  overflow: hidden;

  width: 100%;
  height: 100%;
  min-height: 0;

  border-radius: 28px;
}

.blog-hero__media::after {
  position: absolute;
  inset: auto 0 0;
  z-index: 1;

  height: 28%;

  content: "";

  background:
    linear-gradient(
      to top,
      rgba(17, 19, 24, 0.24),
      transparent
    );

  pointer-events: none;
}

.blog-hero__media img {
  position: absolute;
  inset: 0;

  display: block;

  width: 100%;
  height: 100%;

  object-fit: cover;
  object-position: center;
}


/* BLOG HERO. RESPONSIVE - 1100px */

@media (max-width: 1100px) {
  .blog-hero__content {
    padding: 38px 20px 38px 32px;
  }

  .blog-hero__description {
    font-size: 17px;
  }

  .blog-hero-stat {
    padding: 20px;
  }
}


/* BLOG HERO. RESPONSIVE - 900px */

@media (max-width: 900px) {
  .blog-hero__panel {
    display: grid;
    grid-template-columns:
      minmax(0, 0.7fr)
      minmax(0, 1.3fr);
    grid-template-areas:
      "kicker kicker"
      "title title"
      "text text"
      "stats media";
    align-items: stretch;
    gap: 24px;

    padding: 34px;
  }

  .blog-hero__content {
    display: contents;
  }

  .blog-hero__content .section-kicker {
    grid-area: kicker;

    justify-self: start;
    margin-bottom: 0;
  }

  .blog-hero__title {
    grid-area: title;

    max-width: 20ch;
    margin-bottom: 0;

    font-size: 48px;
  }

  .blog-hero__description {
    grid-area: text;

    max-width: 760px;
    margin-bottom: 8px;
  }

  .blog-hero__stats {
    grid-area: stats;

    grid-template-columns: 1fr;

    width: 100%;
    max-width: none;
  }

  .blog-hero-stat:nth-child(odd) {
    border-right: 0;
  }

  .blog-hero-stat:not(:last-child) {
    border-bottom: 1px solid rgba(99, 119, 242, 0.14);
  }

  .blog-hero__media {
    grid-area: media;

    width: 100%;
    height: auto;
    min-height: 100%;
  }

  .blog-hero__media img {
    object-position: center 28%;
  }
}


/* BLOG HERO. RESPONSIVE - 800px */

@media (max-width: 800px) {
  .blog-hero__title {
    font-size: 44px;
  }

  .blog-hero__description {
    font-size: 16px;
  }
}


/* BLOG HERO. RESPONSIVE - 700px */

@media (max-width: 700px) {
  .blog-hero__media {
    height: 480px;
  }
}


/* BLOG HERO. RESPONSIVE - 600px */

@media (max-width: 600px) {
  .blog-hero__panel {
    grid-template-columns: 1fr;
    grid-template-areas:
      "kicker"
      "title"
      "text"
      "stats"
      "media";

    padding: 26px;
  }

  .blog-hero__title {
    font-size: 42px;
  }

  .blog-hero__description {
    margin-bottom: 28px;

    font-size: 15px;
  }

  .blog-hero__stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));

    border-radius: 18px;
  }

  .blog-hero-stat {
    padding: 18px 16px;
  }

  .blog-hero-stat:nth-child(odd) {
    border-right: 1px solid rgba(99, 119, 242, 0.14);
  }

  .blog-hero-stat:nth-child(-n + 2) {
    border-bottom: 1px solid rgba(99, 119, 242, 0.14);
  }

  .blog-hero-stat:nth-child(n + 3) {
    border-bottom: 0;
  }

  .blog-hero-stat__value {
    font-size: 31px;
  }

  .blog-hero-stat__label {
    font-size: 13px;
  }

  .blog-hero__media {
    height: 420px;
    min-height: 0;

    border-radius: 24px;
  }
}


/* BLOG HERO. RESPONSIVE - 480px */

@media (max-width: 480px) {
  .blog-hero__panel {
    padding: 20px;
  }

  .blog-hero__title {
    font-size: 38px;
  }

  .blog-hero__stats {
    grid-template-columns: 1fr;
  }

  .blog-hero-stat:nth-child(odd) {
    border-right: 0;
  }

  .blog-hero-stat:not(:last-child) {
    border-bottom: 1px solid rgba(99, 119, 242, 0.14);
  }

  .blog-hero__media {
    height: 360px;

    border-radius: 22px;
  }
}


/* BLOG HERO. RESPONSIVE - 400px */

@media (max-width: 400px) {
  .blog-hero__panel {
    padding: 16px;
  }

  .blog-hero__title {
    font-size: 34px;
  }

  .blog-hero__media {
    height: 330px;

    border-radius: 20px;
  }
}


/* ==========================================
   02. BLOG ARTICLES
========================================== */

.blog-articles__panel {
  padding-top: 82px;
  padding-bottom: 82px;

  background:
    radial-gradient(
      circle at 88% 8%,
      rgba(99, 119, 242, 0.12),
      transparent 26%
    ),
    linear-gradient(
      135deg,
      rgba(255, 255, 255, 0.99),
      rgba(246, 248, 255, 0.97)
    );
}

.blog-articles__heading {
  max-width: 900px;
  margin-bottom: 46px;
}

.blog-articles__heading .section-title {
  max-width: 820px;
  margin-inline: auto;
}

.blog-articles__heading .section-description {
  max-width: 720px;
}

.blog-articles__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.blog-card {
  display: flex;
  flex-direction: column;

  min-width: 0;
  height: 100%;
  overflow: hidden;

  background:
    linear-gradient(
      155deg,
      rgba(255, 255, 255, 1),
      rgba(247, 248, 255, 0.98)
    );

  border: 1px solid rgba(99, 119, 242, 0.16);
  border-radius: 24px;

  box-shadow:
    0 16px 36px rgba(42, 52, 101, 0.07),
    inset 0 1px 0 rgba(255, 255, 255, 1);

  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.blog-card:hover {
  transform: translateY(-6px);

  border-color: rgba(99, 119, 242, 0.3);

  box-shadow:
    0 24px 48px rgba(42, 52, 101, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 1);
}

.blog-card__media {
  position: relative;
  overflow: hidden;

  display: block;
  height: 225px;
  margin: 12px 12px 0;

  border-radius: 17px;
}

.blog-card__media::after {
  position: absolute;
  inset: auto 0 0;

  height: 34%;

  content: "";

  background:
    linear-gradient(
      to top,
      rgba(17, 19, 24, 0.25),
      transparent
    );

  pointer-events: none;
}

.blog-card__media img {
  width: 100%;
  height: 100%;

  object-fit: cover;
  object-position: center;

  transition: transform 500ms ease;
}

.blog-card:hover .blog-card__media img {
  transform: scale(1.035);
}

.blog-card__category {
  position: absolute;
  z-index: 2;
  bottom: 14px;
  left: 14px;

  padding: 7px 11px;

  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;

  color: #ffffff;
  background: var(--color-accent);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 999px;

  backdrop-filter: blur(10px);
}

.blog-card__content {
  display: flex;
  flex: 1;
  flex-direction: column;

  padding: 26px 26px 28px;
}

.blog-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;

  margin-bottom: 16px;

  font-size: 12px;
  font-weight: 700;

  color: var(--color-accent);
}

.blog-card__meta span + span {
  position: relative;
  padding-left: 14px;
}

.blog-card__meta span + span::before {
  position: absolute;
  top: 50%;
  left: 0;

  width: 4px;
  height: 4px;

  content: "";
  transform: translateY(-50%);

  background: rgba(99, 119, 242, 0.45);
  border-radius: 50%;
}

.blog-card__title {
  margin: 0 0 16px;

  font-size: 23px;
  font-weight: 800;
  line-height: 1.28;
  letter-spacing: -0.03em;

  color: var(--color-text);

  display: -webkit-box;
  overflow: hidden;

  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;

  text-overflow: ellipsis;
}

.blog-card__title a {
  color: inherit;
  text-decoration: none;
}

.blog-card__description {
  margin: 0 0 24px;

  font-size: 15px;
  line-height: 1.67;

  color: var(--color-text-soft);
}

.blog-card__link {
  display: inline-flex;
  align-items: center;
  gap: 10px;

  width: fit-content;
  margin-top: auto;

  font-size: 14px;
  font-weight: 800;

  color: var(--color-text);
  text-decoration: none;
}

.blog-card__link span {
  color: var(--color-accent);

  transition: transform var(--transition);
}

.blog-card__link:hover span {
  transform: translateX(4px);
}


/* BLOG ARTICLES. RESPONSIVE - 1100px */

@media (max-width: 1100px) {
  .blog-articles__grid {
    gap: 16px;
  }

  .blog-card__media {
    height: 205px;
  }

  .blog-card__content {
    padding: 24px;
  }

  .blog-card__title {
    font-size: 21px;
  }

  .blog-card__description {
    font-size: 14px;
  }
}


/* BLOG ARTICLES. RESPONSIVE - 900px */

@media (max-width: 900px) {
  .blog-articles__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .blog-card__media {
    height: 235px;
  }
}


/* BLOG ARTICLES. RESPONSIVE - 700px */

@media (max-width: 700px) {
  .blog-articles__grid {
    grid-template-columns: 1fr;
  }

  .blog-card {
    width: 100%;
    max-width: 560px;
    margin-inline: auto;
  }

  .blog-card__media {
    height: 300px;
  }
}


/* BLOG ARTICLES. RESPONSIVE - 600px */

@media (max-width: 600px) {
  .blog-articles__panel {
    padding-top: 62px;
    padding-bottom: 62px;
  }

  .blog-articles__heading {
    margin-bottom: 36px;
  }

  .blog-articles__grid {
    gap: 16px;
  }

  .blog-card__media {
    height: 260px;

    border-radius: 16px;
  }

  .blog-card__content {
    padding: 24px 22px 26px;
  }

  .blog-card__title {
    font-size: 21px;
  }
}


/* BLOG ARTICLES. RESPONSIVE - 480px */

@media (max-width: 480px) {
  .blog-card {
    border-radius: 21px;
  }

  .blog-card__media {
    height: 220px;
    margin: 10px 10px 0;
  }

  .blog-card__content {
    padding: 22px 20px 24px;
  }

  .blog-card__title {
    font-size: 20px;
  }

  .blog-card__description {
    font-size: 14px;
  }
}


/* BLOG ARTICLES. RESPONSIVE - 400px */

@media (max-width: 400px) {
  .blog-card__media {
    height: 195px;
  }

  .blog-card__content {
    padding-inline: 18px;
  }

  .blog-card__title {
    font-size: 19px;
  }
}