.lead {
  font-size: 1.32rem;
}

.secondary {
  font-size: 1.0666666667rem;
}

.third {
  font-size: 0.9561752988rem;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 45vh;
  overflow: hidden;
  will-change: transform;
  z-index: 1000;
  transition: transform 0.1s ease-out;
}
.header__container {
  max-width: 960px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}
.header__container h1 {
  font-size: 3.6rem;
  color: white;
  font-weight: bold;
  text-shadow: 2px 2px 4px rgba(28, 3, 1, 0.5);
}
.header__container h1 span {
  color: #E71F3F;
}
.header__container p {
  color: white;
  font-size: 2.04rem;
  line-height: 1.3;
  font-weight: 300;
  margin-bottom: 0.5rem;
  text-shadow: 2px 2px 4px rgba(28, 3, 1, 0.5);
}
.header__parallax {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
}
.header__parallax img {
  width: 100%;
  height: 45vh;
  -o-object-fit: cover;
     object-fit: cover;
  position: fixed;
  top: 0;
  left: 0;
  will-change: transform;
  -webkit-backface-visibility: hidden;
          backface-visibility: hidden;
  transform-style: preserve-3d;
}
.header::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(28, 3, 1, 0.5);
  z-index: 1;
}
@media only screen and (min-width: 600px) {
  .header {
    height: 40vh;
  }
  .header__container p {
    padding: 0 20px;
  }
}
@media screen and (min-width: 900px) {
  .header {
    height: 60vh;
  }
  .header__container h1 {
    font-size: 4.8rem;
  }
  .header__container p {
    padding: 0;
    font-size: 2.4rem;
  }
  .header__parallax img {
    height: 60vh;
  }
}
@media only screen and (min-width: 1300px) {
  .header__container h1 {
    font-size: 5.4rem;
  }
  .header__container p {
    font-size: 3rem;
  }
}

.home-wrap {
  margin-top: 400px;
}

.container {
  max-width: 1200px;
  margin: 2rem auto;
}
@media only screen and (min-width: 900px) {
  .container {
    padding: 0 2rem;
  }
}

.shadow-box {
  margin-bottom: 4rem;
  border: 1px dashed color-mix(in srgb, #999, white 60%);
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
  text-align: center;
}

.top-hero h1 {
  color: #E71F3F;
  line-height: 1.2;
}
.top-hero p {
  font-size: 1.3rem;
}
@media only screen and (min-width: 700px) {
  .top-hero p {
    font-size: 1.6rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
  }
}

.second-hero {
  text-align: center;
  margin-bottom: 3rem;
}
.second-hero h2 {
  color: #E71F3F;
  line-height: 1.4;
  font-size: 2rem;
}
@media only screen and (min-width: 700px) {
  .second-hero h2 {
    font-size: 2.6rem;
  }
}
.second-hero p {
  font-size: 1.3rem;
  margin-bottom: 3rem;
}
@media only screen and (min-width: 700px) {
  .second-hero p {
    font-size: 1.5rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
  }
}

.third-hero {
  padding-top: 2rem;
}
.third-hero h2 {
  color: #E71F3F;
  font-size: 2rem;
  text-align: center;
  line-height: 1.4;
}
@media only screen and (min-width: 700px) {
  .third-hero h2 {
    font-size: 2.6rem;
  }
}

.hero-container {
  display: grid;
  gap: 3rem;
  padding-top: 1rem;
}

.hero-card {
  padding: 2rem 2rem 0 2rem;
  border: 1px dashed color-mix(in srgb, #999, white 60%);
  border-radius: 0.75rem;
  box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out;
  text-align: center;
}
.hero-card h2 {
  font-size: 2rem;
  margin-bottom: 1rem;
  font-weight: 200;
}
.hero-card h3 {
  font-size: 1.9rem;
  color: #E71F3F;
}
.hero-card p {
  font-size: 1.3rem;
}
@media only screen and (min-width: 700px) {
  .hero-card p {
    font-size: 1.4rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
  }
}

.feature-icon {
  margin-bottom: 0.8rem;
}
.feature-icon img {
  height: 50px;
}

.hero-card-link {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  margin-bottom: 2rem;
  transition: background-color 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.hero-card-link:hover {
  transform: translateY(-2px);
}

.cta {
  margin-top: 6rem;
  text-align: center;
}
.cta h2 {
  color: #E71F3F;
  line-height: 1.4;
}
@media only screen and (min-width: 700px) {
  .cta h2 {
    font-size: 2.6rem;
  }
}
.cta p {
  font-size: 1.4rem;
}
@media only screen and (min-width: 700px) {
  .cta p {
    font-size: 1.6rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
  }
}
.cta .button-wrap {
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  margin-bottom: 2rem;
}
.cta .button-wrap div {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: center;
  margin-bottom: 2rem;
  row-gap: 20px;
}
.cta .button-wrap div img {
  width: 60px;
}
@media only screen and (min-width: 600px) {
  .cta .button-wrap {
    flex-direction: row;
    align-items: flex-end;
  }
  .cta .button-wrap div {
    margin-bottom: 0;
  }
}

@media (min-width: 768px) {
  .hero-container {
    grid-template-columns: repeat(2, 1fr);
  }
}
@media only screen and (min-width: 900px) {
  .home-wrap {
    margin-top: 580px;
  }
}
.cheat-section {
  margin-bottom: 6rem;
  margin-top: 6rem;
}
.cheat-section h2 {
  color: #E71F3F;
  line-height: 1.4;
}
@media only screen and (min-width: 700px) {
  .cheat-section h2 {
    font-size: 2.6rem;
  }
}

.related-posts-gallery h2 {
  text-align: center;
  color: #E71F3F;
  margin-bottom: 52px;
  font-size: 2.5rem;
  font-weight: 200;
}
@media only screen and (min-width: 700px) {
  .related-posts-gallery h2 {
    font-size: 3rem;
    margin-bottom: 52px;
  }
}

.filter-controls {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-bottom: 62px;
}
@media only screen and (min-width: 700px) {
  .filter-controls {
    margin-bottom: 78px;
    gap: 16px;
  }
}

.filter-btn {
  padding: 10px 20px;
  font-size: 0.875rem;
  position: relative;
  overflow: hidden;
}
@media only screen and (min-width: 700px) {
  .filter-btn {
    padding: 12px 24px;
    font-size: 0.95rem;
  }
}
.filter-btn:hover, .filter-btn.selected {
  color: #fff;
  background-color: color-mix(in srgb, #E71F3F, white 20%);
  transform: translateY(-2px);
  box-shadow: 0 8px 15px -3px rgba(37, 99, 235, 0.3);
}
.filter-btn.selected {
  cursor: not-allowed;
}

.posts-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 50px;
  margin-bottom: 48px;
}
@media only screen and (min-width: 700px) {
  .posts-grid {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    row-gap: 40px;
  }
}

.gallery-card {
  background: #fff;
  border: 1px dashed color-mix(in srgb, #999, white 60%);
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  cursor: pointer;
  position: relative;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  opacity: 1;
  transform: translateY(0) scale(1);
}
.gallery-card.hidden {
  display: none;
}
.gallery-card.filtering-out {
  opacity: 0;
  transform: translateY(20px) scale(0.95);
  pointer-events: none;
}
.gallery-card.filtering-in {
  animation: fadeInScale 0.6s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}
.gallery-card:hover {
  transform: translateY(-8px) scale(1.02);
  box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}
.gallery-card:hover .gallery-card__img {
  transform: scale(1.1);
}
.gallery-card__image {
  height: 200px;
  position: relative;
  overflow: hidden;
}
.gallery-card__img {
  width: 100%;
  height: 100%;
  -o-object-fit: cover;
     object-fit: cover;
  -o-object-position: center;
     object-position: center;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}
.gallery-card__content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.gallery-card__meta {
  margin-bottom: 16px;
}
.gallery-card__category {
  font-size: 0.65rem;
  font-weight: 400;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 6px 12px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, #2563eb, #7c3aed);
}
.gallery-card__title {
  font-size: 1.7rem;
  font-weight: 200;
  line-height: 1.2;
  color: #0f172a;
  margin-bottom: 12px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.gallery-card:hover .gallery-card__title {
  color: #E71F3F;
}
.gallery-card__excerpt {
  font-size: 1.2rem;
  line-height: 1.6;
  color: #475569;
  flex-grow: 1;
  margin-bottom: 20px;
}

.gallery-card__category.utilities {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
}

.gallery-card__category.code {
  background: linear-gradient(135deg, #10b981, #059669);
}

.load-more-container {
  display: flex;
  justify-content: center;
  margin-top: 32px;
  margin-bottom: 4rem;
}

.load-more-btn {
  border-radius: 50px;
  padding: 16px 32px;
  font-size: 1rem;
  font-weight: 400;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 15px -3px rgba(37, 99, 235, 0.4);
  position: relative;
  overflow: hidden;
}
.load-more-btn:before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
}
.load-more-btn:hover {
  color: #fff;
  background-color: color-mix(in srgb, #E71F3F, white 20%);
  transform: translateY(-2px);
  box-shadow: 0 8px 25px -5px rgba(37, 99, 235, 0.5);
}
.load-more-btn:hover:before {
  left: 0;
}
.load-more-btn.hidden {
  display: none;
}
.load-more-btn .load-more-icon {
  width: 20px;
  height: 20px;
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.load-more-btn:hover .load-more-icon {
  transform: translateY(2px);
}

/* Loading Animation */
.load-more-btn.loading .load-more-icon {
  animation: bounce 1s infinite;
}

/* Card Animations */
@keyframes fadeInScale {
  0% {
    opacity: 0;
    transform: translateY(30px) scale(0.9);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
@keyframes bounce {
  0%, 20%, 50%, 80%, 100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-5px);
  }
  60% {
    transform: translateY(-3px);
  }
}
@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* Filter Animation Classes */
.gallery-card.fade-in {
  animation: slideUp 0.6s ease-out forwards;
}

/* Staggered Animation Delays */
.gallery-card:nth-child(1) {
  transition-delay: 0.1s;
}

.gallery-card:nth-child(2) {
  transition-delay: 0.2s;
}

.gallery-card:nth-child(3) {
  transition-delay: 0.3s;
}

.gallery-card:nth-child(4) {
  transition-delay: 0.4s;
}

.gallery-card:nth-child(5) {
  transition-delay: 0.5s;
}

.gallery-card:nth-child(6) {
  transition-delay: 0.6s;
}

.gallery-card:nth-child(7) {
  transition-delay: 0.7s;
}

.gallery-card:nth-child(8) {
  transition-delay: 0.8s;
}

.index-footer,
.index-footer .footer-inner-post {
  max-width: 1180px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

@media only screen and (min-width: 700px) {
  .index-footer,
  .index-footer .footer-inner-post {
    padding-left: 0;
    padding-right: 0;
  }
}
