/* ─── Front Page Content Shortcode Styles ──────────────────────────────────── */

/* ─── Banner Carousel ────────────────────────────────────────────────────── */
/* Height/position/padding/alignment now set in Bricks templates #5878 + #17911 */
/* Only CSS-only properties and dark mode overrides remain here */

/* Splide intermediates (not Bricks elements — need CSS for height propagation) */
.home #brxe-sklhyz .splide__track,
.home #brxe-sklhyz .splide__list,
.home #brxe-sklhyz .splide__slide {
  min-height: 500px;
}
/* Banner excerpt — frosted glass + flex fill (not available in Bricks) */
.home .brxe-tgjzxo.brxe-post-excerpt {
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  flex: 1;
  display: flex;
  align-items: center;
}
/* Banner excerpt — dark mode colors */
.dark-mode .home .brxe-tgjzxo.brxe-post-excerpt,
.home.dark-mode .brxe-tgjzxo.brxe-post-excerpt {
  background: rgba(0, 0, 0, 0.45) !important;
  color: #fff !important;
}

/* ─── Section Headings ───────────────────────────────────────────────────── */
.thx-section-heading {
  font-family: "Inter", sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.1;
  color: #001123;
  margin: 0 0 20px;
  text-transform: uppercase;
}
.dark-mode .thx-section-heading {
  color: #fff;
}

/* ─── Article Grids ──────────────────────────────────────────────────────── */
.thx-grid {
  display: grid;
  gap: 20px;
}
/* Reset .box margin inside grids — grid gap handles spacing */
.thx-grid > .box {
  margin-bottom: 0;
}
.thx-grid--2col { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.thx-grid--3col { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.thx-grid--4col { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ─── Hero Card (Large — matches #4769) ──────────────────────────────────── */
.thx-hero-card {
  display: flex;
  flex-direction: column;
}
.thx-hero-card__image {
  display: block;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 10px;
}
.thx-hero-card__image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  display: block;
  border-radius: 5px;
}
.thx-hero-card__title {
  text-decoration: none;
  color: inherit;
}
.thx-hero-card__title h2 {
  font-family: "Inter", sans-serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1.1em;
  color: #001123;
  margin: 0 0 10px;
}
.dark-mode .thx-hero-card__title h2 {
  color: #fff;
}
.thx-hero-card__excerpt {
  font-family: "Inter", sans-serif;
  font-size: 16px;
  line-height: 30px;
  color: #001123;
  margin: 0;
}
.dark-mode .thx-hero-card__excerpt {
  color: #fff;
}

/* ─── Full-Image Card (matches #5261) ─────────────────────────────────────── */
.thx-card-fi {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  aspect-ratio: 1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  position: relative;
  text-decoration: none;
  overflow: hidden;
  padding: 15px !important;
}
/* Dark overlay */
.thx-card-fi::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  border-radius: inherit;
  z-index: 0;
  pointer-events: none;
}
.thx-card-fi > * {
  position: relative;
  z-index: 1;
}
.thx-card-fi__title {
  font-family: "Inter", sans-serif;
  font-size: 18px;
  font-weight: 600;
  line-height: 1.1em;
  color: #fff;
  text-align: center;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
  margin: 0;
}
.thx-card-fi__meta {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
}
.thx-card-fi__date {
  font-family: "Inter", sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #eee;
  text-shadow: 0 0 4px rgba(0, 0, 0, 0.5);
}

/* ─── Medium Card (matches #5133) ────────────────────────────────────────── */
.thx-card-md {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 100%;
}
.thx-card-md__image {
  display: block;
  border-radius: 5px;
  overflow: hidden;
  margin-bottom: 10px;
}
.thx-card-md__image img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  display: block;
  border-radius: 5px;
}
.thx-card-md__title {
  font-family: "Inter", sans-serif;
  font-size: 24px;
  font-weight: 600;
  line-height: 1.1em;
  color: #001123;
  margin: 0 0 10px;
}
.dark-mode .thx-card-md__title {
  color: #fff;
}
.thx-card-md a {
  text-decoration: none;
  color: inherit;
}

/* ─── Small Card (matches #4773) ─────────────────────────────────────────── */
.thx-card-sm {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}
.thx-card-sm__title {
  font-family: "Inter", sans-serif;
  font-size: 22px;
  font-weight: 600;
  line-height: 1.1em;
  color: #001123;
  margin: 0 0 10px;
}
.dark-mode .thx-card-sm__title {
  color: #fff;
}
.thx-card-sm a {
  text-decoration: none;
  color: inherit;
}

/* ─── Card Meta Row (date + tags) ────────────────────────────────────────── */
.thx-card-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: auto;
  padding-top: 10px;
  width: 100%;
}
.thx-card-date {
  font-family: "Inter", sans-serif;
  font-size: 16px;
  font-weight: 400;
  color: #aaa;
  line-height: 30px;
  flex-shrink: 0;
}

/* ─── Category Tags ──────────────────────────────────────────────────────── */
.thx-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: flex-end;
}
.thx-tag {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 10px;
  font-family: "Inter", sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  line-height: 1;
  white-space: nowrap;
}
.thx-tag:hover {
  transform: scale(1.05);
  transition: transform 0.2s ease-in-out;
}

/* ─── Social Card ────────────────────────────────────────────────────────── */
.thx-social-card {
  padding: 13px 18px 18px;
  border-radius: 10px;
  border: 1px solid #001123;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.15);
}
.dark-mode .thx-social-card {
  background: #222;
  border: 1px solid transparent;
}
.thx-social-card__heading {
  font-family: "Inter", sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: #001123;
  margin: 0 0 10px;
}
.dark-mode .thx-social-card__heading {
  color: #fff;
}
.thx-social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.thx-social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 0 4px rgba(0, 0, 0, 0.15);
  color: #001123;
  font-size: 28px;
  text-decoration: none;
  transition: color 0.2s ease-in-out;
  cursor: pointer;
}
.thx-social-icon:hover {
  color: var(--hover-color, #0074ff);
}

/* ─── Patreon CTA ────────────────────────────────────────────────────────── */
.thx-patreon-cta {
  margin-top: 20px;
  padding: 15px;
  background: #f5f5f5;
  border-radius: 10px;
  text-align: center;
}
.dark-mode .thx-patreon-cta {
  background: #333;
}
.thx-patreon-btn {
  display: inline-block;
  padding: 10px 20px;
  background: #FF424D;
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 16px;
  transition: opacity 0.2s;
}
.thx-patreon-btn:hover {
  opacity: 0.85;
  color: #fff;
}

/* ─── Discover Button ────────────────────────────────────────────────────── */
.thx-discover-btn-wrap {
  text-align: center;
  margin-top: 20px;
}
.thx-discover-btn {
  display: inline-block;
  padding: 12px 30px;
  background: #001123;
  color: #fff;
  border-radius: 10px;
  text-decoration: none;
  font-family: "Inter", sans-serif;
  font-weight: 600;
  font-size: 16px;
  transition: background 0.2s;
}
.thx-discover-btn:hover {
  background: #002987;
  color: #fff;
}
.dark-mode .thx-discover-btn {
  background: #444;
}
.dark-mode .thx-discover-btn:hover {
  background: #555;
}

/* ─── Sort by Simulator (Bricks template #5205) ─────────────────────────── */
/* Disable card hover scale — this is a UI control, not an article card */
#brxe-sort,
#brxe-sort:hover {
  transform: none !important;
  box-shadow: 1px 1px 4px rgba(0, 17, 35, 0.1) !important;
}
/* Dark mode: card background + text color */
.dark-mode #brxe-sort,
.dark-mode .brxe-dropdown.frontpage.box.c-white {
  background: #333 !important;
  color: #fff;
  box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.3) !important;
}
.dark-mode #brxe-sort .brxe-dropdown-trigger {
  color: #fff;
}
.dark-mode #brxe-sort .brxe-dropdown-icon {
  color: #fff;
}

/* ─── Front Page Block Layout ────────────────────────────────────────────── */
.thx-fp-block {
  display: flex;
  gap: 20px;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 15px;
}
.thx-fp-block--reverse {
  flex-direction: row-reverse;
}
.thx-fp-block__content {
  flex: 0 0 70%;
  max-width: 70%;
  min-width: 0;
}
.thx-fp-block__sidebar {
  flex: 0 0 30%;
  max-width: 30%;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.thx-fp-block--half .thx-fp-block__content,
.thx-fp-block--half .thx-fp-block__sidebar {
  flex: 0 0 50%;
  max-width: 50%;
}

/* Separator sections — match content area width (1100px) */
#brxe-fp0002,
#brxe-fp0015,
#brxe-fp0030,
#brxe-fp0041,
#brxe-fp0053 {
  max-width: 1100px;
  margin: 20px auto;
  padding: 0 !important;
}

/* Content block sections + containers: padding, background, gaps now in Bricks #4908 */
/* Only dark mode background override remains (can't set conditional in Bricks) */
.dark-mode #brxe-fp0006,
.dark-mode #brxe-fp0019,
.dark-mode #brxe-fp0034,
.dark-mode #brxe-fp0045,
.dark-mode #brxe-fp0057 {
  background: #222;
}

/* ─── Responsive ─────────────────────────────────────────────────────────── */

/* Tablet */
@media (max-width: 1024px) {
  .thx-grid--4col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .thx-grid--3col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .thx-fp-block__content {
    flex: 0 0 65%;
    max-width: 65%;
  }
  .thx-fp-block__sidebar {
    flex: 0 0 35%;
    max-width: 35%;
  }
}

/* Mobile */
@media (max-width: 768px) {
  .thx-fp-block,
  .thx-fp-block--reverse {
    flex-direction: column;
  }
  .thx-fp-block__content,
  .thx-fp-block__sidebar {
    flex: none;
    max-width: 100%;
    width: 100%;
  }
  /* Force Bricks front page row containers to stack vertically */
  .home .brxe-section > .brxe-container {
    flex-direction: column !important;
  }
  /* Force Bricks front page columns to full width */
  .home .brxe-section > .brxe-container > .brxe-container {
    width: 100% !important;
    max-width: 100% !important;
  }
  .thx-grid--4col,
  .thx-grid--3col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .thx-grid--2col {
    grid-template-columns: 1fr;
  }
  .thx-hero-card__image img {
    height: 160px;
  }
  .thx-hero-card__title h2 {
    font-size: 22px;
  }
  .thx-card-md__title {
    font-size: 18px;
  }
  .thx-card-sm__title {
    font-size: 16px;
  }
  .thx-section-heading {
    font-size: 22px;
    line-height: 1.1;
  }
}

/* Small mobile */
@media (max-width: 480px) {
  .thx-grid--4col,
  .thx-grid--3col,
  .thx-grid--2col {
    grid-template-columns: 1fr;
  }
  .thx-card-fi {
    aspect-ratio: 16 / 9;
  }
}
