/* style/blog-tt888-code-guide.css */

/* Base styles for the page content, applying dark background and light text */
.page-blog-tt888-code-guide {
  background-color: #08160F; /* Custom Background */
  color: #F2FFF6; /* Custom Text Main */
  font-family: Arial, sans-serif;
  line-height: 1.6;
}

/* Sections */
.page-blog-tt888-code-guide__section {
  padding: 60px 0;
  position: relative;
  z-index: 1;
}

.page-blog-tt888-code-guide__container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

/* Hero Section */
.page-blog-tt888-code-guide__hero-section {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding-top: 10px; /* Small top padding, body handles --header-offset */
  padding-bottom: 60px;
  position: relative;
  overflow: hidden;
}

.page-blog-tt888-code-guide__hero-image-wrapper {
  width: 100%;
  max-height: 675px; /* Limit height for hero image */
  overflow: hidden;
  margin-bottom: 30px;
}

.page-blog-tt888-code-guide__hero-image {
  width: 100%;
  height: auto;
  display: block;
  object-fit: cover;
  filter: none; /* Ensure no CSS filter is applied */
}

.page-blog-tt888-code-guide__hero-content {
  max-width: 900px;
  margin-top: -100px; /* Adjust to slightly overlap the image for visual flow */
  position: relative;
  z-index: 2;
  background: linear-gradient(180deg, rgba(8, 22, 15, 0.8) 0%, #08160F 100%); /* Gradient to blend with background */
  padding: 40px;
  border-radius: 10px;
}

.page-blog-tt888-code-guide__main-title {
  font-size: clamp(2em, 4vw, 3.5em); /* Responsive font size */
  color: #F2FFF6; /* Custom Text Main */
  font-weight: bold;
  line-height: 1.2;
  margin-bottom: 20px;
  letter-spacing: 1px;
}

.page-blog-tt888-code-guide__hero-description {
  font-size: 1.2em;
  color: #A7D9B8; /* Custom Text Secondary */
  margin-bottom: 30px;
}

/* Section Titles */
.page-blog-tt888-code-guide__section-title {
  font-size: clamp(1.8em, 3.5vw, 2.8em); /* Responsive font size */
  color: #F2FFF6; /* Custom Text Main */
  text-align: center;
  margin-bottom: 40px;
  font-weight: bold;
}

/* Text Blocks */
.page-blog-tt888-code-guide__text-block {
  font-size: 1.1em;
  color: #A7D9B8; /* Custom Text Secondary */
  margin-bottom: 20px;
  text-align: justify;
}

/* Buttons */
.page-blog-tt888-code-guide__btn-primary,
.page-blog-tt888-code-guide__btn-secondary {
  display: inline-block;
  padding: 15px 30px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: bold;
  font-size: 1.1em;
  transition: all 0.3s ease;
  box-sizing: border-box;
  text-align: center;
  white-space: normal; /* Allow text wrapping */
  word-wrap: break-word; /* Allow long words to break */
}

.page-blog-tt888-code-guide__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%); /* Custom Button */
  color: #F2FFF6; /* Custom Text Main */
  border: none;
  box-shadow: 0 5px 15px rgba(34, 199, 104, 0.4);
}

.page-blog-tt888-code-guide__btn-primary:hover {
  background: linear-gradient(180deg, #13994A 0%, #2AD16F 100%);
  transform: translateY(-3px);
  box-shadow: 0 8px 20px rgba(34, 199, 104, 0.6);
}

.page-blog-tt888-code-guide__btn-secondary {
  background: transparent;
  color: #57E38D; /* Custom Glow */
  border: 2px solid #2E7A4E; /* Custom Border */
}

.page-blog-tt888-code-guide__btn-secondary:hover {
  background-color: #1E3A2A; /* Custom Divider for hover */
  color: #F2FFF6; /* Custom Text Main */
  border-color: #57E38D;
  transform: translateY(-3px);
}

.page-blog-tt888-code-guide__btn-center {
  display: block;
  margin: 30px auto 0 auto;
  max-width: 300px; /* Limit button width for better appearance */
}

/* What is Code Section */
.page-blog-tt888-code-guide__what-is-code {
  background-color: #0A4B2C; /* Custom Deep Green */
  padding-top: 80px;
  padding-bottom: 80px;
}

/* How to Get Section */
.page-blog-tt888-code-guide__how-to-get {
  background-color: #08160F;
}

.page-blog-tt888-code-guide__steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-blog-tt888-code-guide__step-card {
  background-color: #11271B; /* Custom Card BG */
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-blog-tt888-code-guide__step-image {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 25px;
  filter: none; /* Ensure no CSS filter is applied */
}

.page-blog-tt888-code-guide__step-title {
  font-size: 1.5em;
  color: #F2FFF6; /* Custom Text Main */
  margin-bottom: 15px;
  font-weight: bold;
}

/* Benefits Section */
.page-blog-tt888-code-guide__benefits {
  background-color: #11271B; /* Custom Card BG */
}

.page-blog-tt888-code-guide__benefits-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  margin-top: 40px;
}

.page-blog-tt888-code-guide__benefit-card {
  background-color: #08160F; /* Custom Background */
  border-radius: 10px;
  padding: 30px;
  text-align: center;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.page-blog-tt888-code-guide__benefit-image {
  width: 100%;
  height: 250px; /* Fixed height for consistency */
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 25px;
  filter: none; /* Ensure no CSS filter is applied */
}

.page-blog-tt888-code-guide__benefit-title {
  font-size: 1.5em;
  color: #F2FFF6; /* Custom Text Main */
  margin-bottom: 15px;
  font-weight: bold;
}

/* FAQ Section */
.page-blog-tt888-code-guide__faq {
  background-color: #08160F;
}

.page-blog-tt888-code-guide__faq-list {
  margin-top: 40px;
}

.page-blog-tt888-code-guide__faq-item {
  background-color: #11271B; /* Custom Card BG */
  border: 1px solid #2E7A4E; /* Custom Border */
  border-radius: 8px;
  margin-bottom: 15px;
  overflow: hidden;
  color: #F2FFF6; /* Custom Text Main */
}

.page-blog-tt888-code-guide__faq-question {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px;
  font-size: 1.2em;
  font-weight: bold;
  cursor: pointer;
  background-color: #11271B;
  color: #F2FFF6;
  list-style: none; /* For details/summary */
}

.page-blog-tt888-code-guide__faq-question::-webkit-details-marker {
  display: none;
}

.page-blog-tt888-code-guide__faq-toggle {
  font-size: 1.5em;
  line-height: 1;
  transition: transform 0.3s ease;
}

.page-blog-tt888-code-guide__faq-item[open] .page-blog-tt888-code-guide__faq-toggle {
  transform: rotate(45deg);
}

.page-blog-tt888-code-guide__faq-answer {
  padding: 0 20px 20px 20px;
  font-size: 1em;
  color: #A7D9B8; /* Custom Text Secondary */
}

/* CTA Section */
.page-blog-tt888-code-guide__cta-section {
  background: linear-gradient(90deg, #0A4B2C 0%, #11A84E 100%); /* Blend with brand colors */
  text-align: center;
  padding: 80px 0;
}

.page-blog-tt888-code-guide__cta-title {
  color: #F2FFF6;
  margin-bottom: 20px;
}

.page-blog-tt888-code-guide__cta-description {
  max-width: 800px;
  margin: 0 auto 40px auto;
  color: #A7D9B8;
}

.page-blog-tt888-code-guide__cta-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px; /* Spacing between buttons */
}

/* Responsive Styles */
@media (max-width: 1024px) {
  .page-blog-tt888-code-guide__hero-content {
    margin-top: -50px;
    padding: 30px;
  }

  .page-blog-tt888-code-guide__main-title {
    font-size: clamp(2em, 5vw, 3em);
  }

  .page-blog-tt888-code-guide__section-title {
    font-size: clamp(1.8em, 4.5vw, 2.5em);
  }
}

@media (max-width: 768px) {
  .page-blog-tt888-code-guide {
    font-size: 16px;
    line-height: 1.6;
  }

  .page-blog-tt888-code-guide__hero-image-wrapper {
    max-height: 400px;
  }

  .page-blog-tt888-code-guide__hero-content {
    margin-top: -30px;
    padding: 20px;
  }

  .page-blog-tt888-code-guide__main-title {
    font-size: clamp(1.8em, 6vw, 2.5em);
  }

  .page-blog-tt888-code-guide__hero-description {
    font-size: 1em;
  }

  .page-blog-tt888-code-guide__section {
    padding: 40px 0;
  }

  .page-blog-tt888-code-guide__section-title {
    font-size: clamp(1.6em, 5.5vw, 2.2em);
    margin-bottom: 30px;
  }

  .page-blog-tt888-code-guide__text-block {
    font-size: 0.95em;
  }

  /* Mobile image responsiveness */
  .page-blog-tt888-code-guide img {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    object-fit: cover !important;
  }

  /* Mobile video responsiveness (if any) */
  .page-blog-tt888-code-guide video,
  .page-blog-tt888-code-guide__video {
    max-width: 100% !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
  }
  
  .page-blog-tt888-code-guide__video-section,
  .page-blog-tt888-code-guide__video-container,
  .page-blog-tt888-code-guide__video-wrapper {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    overflow: hidden !important;
  }

  .page-blog-tt888-code-guide__video-section {
    padding-top: 10px !important; /* body handles --header-offset */
  }

  /* Mobile button responsiveness */
  .page-blog-tt888-code-guide__btn-primary,
  .page-blog-tt888-code-guide__btn-secondary,
  .page-blog-tt888-code-guide a[class*="button"],
  .page-blog-tt888-code-guide a[class*="btn"] {
    max-width: 100% !important;
    width: 100% !important; /* Ensure full width on mobile */
    box-sizing: border-box !important;
    white-space: normal !important;
    word-wrap: break-word !important;
    padding-left: 15px;
    padding-right: 15px;
  }

  .page-blog-tt888-code-guide__cta-buttons,
  .page-blog-tt888-code-guide__button-group,
  .page-blog-tt888-code-guide__btn-container,
  .page-blog-tt888-code-guide__cta-content {
    max-width: 100% !important;
    width: 100% !important;
    box-sizing: border-box !important;
    padding-left: 15px;
    padding-right: 15px;
    flex-wrap: wrap !important;
    gap: 15px;
  }
  
  .page-blog-tt888-code-guide__steps-grid, 
  .page-blog-tt888-code-guide__benefits-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .page-blog-tt888-code-guide__step-card, 
  .page-blog-tt888-code-guide__benefit-card {
    padding: 20px;
  }

  .page-blog-tt888-code-guide__step-image, 
  .page-blog-tt888-code-guide__benefit-image {
    height: 200px; /* Adjust height for mobile */
  }

  .page-blog-tt888-code-guide__faq-question {
    font-size: 1.1em;
    padding: 15px;
  }

  .page-blog-tt888-code-guide__faq-answer {
    padding: 0 15px 15px 15px;
  }

  .page-blog-tt888-code-guide__cta-section {
    padding: 50px 0;
  }

  .page-blog-tt888-code-guide__cta-title {
    font-size: 1.8em;
  }

  .page-blog-tt888-code-guide__cta-description {
    font-size: 1em;
  }

  /* Content area images must not be smaller than 200px */
  .page-blog-tt888-code-guide__container img,
  .page-blog-tt888-code-guide__step-card img,
  .page-blog-tt888-code-guide__benefit-card img {
    min-width: 200px !important;
    min-height: 200px !important;
  }
}

/* Ensure images in content areas are not smaller than 200x200px on desktop */
.page-blog-tt888-code-guide__step-image,
.page-blog-tt888-code-guide__benefit-image {
  min-width: 200px;
  min-height: 200px;
}

/* Color Contrast Fixes (if needed, applying based on dark background) */
.page-blog-tt888-code-guide__dark-bg {
  color: #ffffff; /* Deep Green/Dark background with light text */
  background: #11A84E; /* Example brand color */
}

.page-blog-tt888-code-guide__light-bg {
  color: #333333; /* Light background with dark text */
  background: #ffffff;
}

.page-blog-tt888-code-guide__medium-bg {
  color: #000000; /* Medium background with dark text */
  background: #22C768;
}

.page-blog-tt888-code-guide__content-area,
.page-blog-tt888-code-guide__text-block {
  color: #A7D9B8; /* Secondary text color on dark backgrounds */
}

.page-blog-tt888-code-guide p,
.page-blog-tt888-code-guide li {
  color: #A7D9B8; /* Secondary text color on dark backgrounds */
}

.page-blog-tt888-code-guide__card {
  background: #11271B; /* Card BG on dark page background */
  color: #F2FFF6;
  border: 1px solid #2E7A4E; /* Custom Border */
}

.page-blog-tt888-code-guide__dark-section {
  background: #0A4B2C;
  color: #F2FFF6; /* Forced light text */
}

.page-blog-tt888-code-guide__btn-primary {
  background: linear-gradient(180deg, #2AD16F 0%, #13994A 100%);
  color: #F2FFF6; /* Button text always light */
}

.page-blog-tt888-code-guide__btn-secondary {
  background: transparent;
  color: #57E38D; /* Custom Glow for text */
  border: 2px solid #2E7A4E;
}

.page-blog-tt888-code-guide__text-contrast-fix {
  color: #F2FFF6 !important;
  text-shadow: none !important;
}