* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f8f4ff 0%, #e8d0ff 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
}

/* Base Typography */
body {
  font-family: 'Roboto', sans-serif;
}

/* ===== H2 Styling ===== */
h2 {
  font-size: clamp(22px, 3vw, 28px);
  font-weight: 900;
  margin: 22px 0 14px;
  line-height: 1.3;
  letter-spacing: -0.3px;

  /* Rich Black → Blue Gradient */
  background: linear-gradient(90deg, #9c27b0, #790c73, #c40aba);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;

  animation: h2Gradient 5s ease infinite;
  position: relative;
}

/* Animated underline accent */
h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 110px;
  height: 3px;
  border-radius: 6px;
  background: linear-gradient(90deg, #9705aa, #da0e7e);
  transition: width 0.4s ease, box-shadow 0.4s ease;
}

h2:hover::after {
  width: 210px;
  box-shadow: 0 0 8px rgba(37, 99, 235, 0.6);
}

/* Smooth gradient animation */
@keyframes h2Gradient {
  0% { background-position: 0% center; }
  50% { background-position: 100% center; }
  100% { background-position: 0% center; }
}


/* ===== H3 Styling ===== */
h3 {
  font-size: clamp(18px, 2.3vw, 24px);
  font-weight: 700;
  color: #5c1036;
  margin: 18px 0 10px;
  line-height: 1.4;

  position: relative;
  padding-left: 14px;
  transition: all 0.3s ease;
}

/* Modern left accent bar */
h3::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 4px;
  height: 70%;
  border-radius: 4px;
  background: linear-gradient(180deg, #500a4a, #530c4d);
  transition: height 0.3s ease, box-shadow 0.3s ease;
}

h3:hover {
  color: #430b43;
  transform: translateX(4px);
}

h3:hover::before {
  height: 100%;
  box-shadow: 0 0 6px rgba(37, 99, 235, 0.5);
}

/* Page padding */
main {
    width: 100%;
    max-width: 1320px;
    /* Changed from 1280px to match "will show 1200px width" */
    margin: 0 auto;
    /* Centers the container */
    padding: 60px 20px 30px;
    /* Updated to: 80px top, 20px sides, 40px bottom */
    box-sizing: border-box;
    /* Critical for proper width calculation */
}

/*
main {
  padding-top: 80px;
  padding: 60px 20px 30px; /*80px 20px 40px*/
width: 100%;
max-width: 1280px;
/*will show 1200px width*/
margin: 0 auto;
flex: 1;
}

*/

/* Custom Pic */
.custompic {
    display: flex;
    /* always flex */
    opacity: 0;
    /* hidden by default */
    pointer-events: none;
    /* not clickable when hidden */
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    padding: 0;
    /*4px 4px*/
    background-color: white;
    border-radius: 1px;
    /*12px*/
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 0;
    /*20px*/
}

/* When pic is visible */
.custompic.active {
    opacity: 1;
    pointer-events: auto;
}

.custompic img {
    display: block;
    margin: 0 auto;
    padding: 0;
    width: 100%;
    max-width: 1320px;
    height: auto;
    max-height: 130px;
    box-sizing: border-box;
    margin-bottom: 0;
    /*20px*/
}

/*Webpage for bodystart ads (bsa) section*/
.web-content-bsa {
    margin: 0 auto;
    width: 100%;
    max-width: 1320px;
    /*real content length: 1032px*/
    padding: 0;
    /*20px*/
    /* Added breathing room */
    background: linear-gradient(135deg, #f8f4ff 100%, #e8d0ff 100%);
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for bodyfooter ads (bfa) section*/
.web-content-bfa {
    margin: 0 auto;
    width: 100%;
    max-width: 1320px;
    /*real content length: 1032px*/
    padding: 0;
    /*20px*/
    /* Added breathing room */
    background: linear-gradient(135deg, #f8f4ff 100%, #e8d0ff 100%);
    border-radius: 12px;
    margin-bottom: 10px;
    /*ex: 20px*/
    /*keep under every segmentation*/
}

/* =========================
   Hero Section (Responsive)
========================= */

.hero {
    text-align: center;
    width: 100%;
    max-width: 1320px;
    margin: 0 auto 10px;

    padding: clamp(10px, 2vw, 15px); /* responsive padding */

    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.06);

    box-sizing: border-box;
}

/* ===== H1 Post Title ===== */
.hero h1 {
    font-size: clamp(26px, 5vw, 38px); /* auto scales mobile → desktop */
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 15px;

    color: #5e35b1;
}

/* ===== Subtitle / Description ===== */
.hero p {
    font-size: clamp(15px, 2.5vw, 20px);
    line-height: 1.6;
    color: #555;

    max-width: 1000px;
    margin: 0 auto 25px;
}

/*Webpage tool content max-width: 1200px; for web application*/
.tool-content {
    margin: 0 auto;
    width: 100%;
    max-width: 1320px;
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage tool content max-width: 1200px; for web application*/
.feat-image {
    margin: 0 auto 20px;
    width: 100%;
    max-width: 1200px;
    padding: clamp(10px, 3vw, 20px);
    /* responsive padding */
    background: #ffffff;
    border-radius: 12px;
    box-sizing: border-box;
    margin-bottom: 20px;
    /*keep under every segmentation*/
    overflow: hidden;
    /* prevents overflow issues */
}

/* Responsive Image */
.feat-image img {
    width: 100%;
    height: auto !important;
    /* keeps aspect ratio */
    max-width: 100%;
    max-height: 100%;
    display: block;
    border-radius: 10px;
}

/*Webpage blog and article content max-width: 1032px, start*/
.web-content-i {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for table of content (toc) section*/
.web-content-toc {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for table of content (toc) section*/
.web-content-vdo {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for body (b) section*/
.web-content-b {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for email collection form (ecf) or ads section*/
.web-content-esf-or-ads {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /*20px*/
    /* Added breathing room */
    background: linear-gradient(135deg, #f8f4ff 100%, #e8d0ff 100%);
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for bodyend ads (bea) section*/
.web-content-bea {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 0;
    /*20px*/
    /* Added breathing room */
    background: linear-gradient(135deg, #f8f4ff 100%, #e8d0ff 100%);
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for conclusion (c) section*/
.web-content-c {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage for frequently asked question (faq) section*/
.web-content-faq {
    margin: 0 auto;
    width: 100%;
    max-width: 1072px;
    /*real content length: 1032px*/
    padding: 20px;
    /* Added breathing room */
    background: white;
    border-radius: 12px;
    margin-bottom: 20px;
    /*keep under every segmentation*/
}

/*Webpage blog and article content max-width: 1032px, end*/

/* Main TOC container, start */
.it-toc {
    padding: 20px;
    color: #000;
    max-width: 600px;
    margin: 0 auto;
    font-family: Arial, sans-serif;
}

/* Style A, B, C markers */
.it-toc {
    list-style-type: upper-alpha;
}

.it-toc>li {
    font-weight: 700;
    margin-bottom: 15px;
    position: relative;
    padding-left: 8px;
}

/* Letter styling effect */
.it-toc>li::marker {
    color: #000;
    font-weight: bold;
    font-size: 18px;
}

/* Main topic text */
.it-mt {
    color: #000;
    font-size: 18px;
}

/* Nested numbering */
.it-toc ol {
    list-style-type: decimal;
    margin-top: 10px;
    padding-left: 25px;
}

.it-toc ol li {
    font-weight: 400;
    margin-bottom: 6px;
    color: #000;
}

/* Hover effect */
.it-toc li:hover {
    color: #111;
    transform: translateX(3px);
    transition: 0.2s ease;
}

/* Main TOC container, end */

/* Webpage Related Content Section Styling max-width: 1032px, start */
.related-content {
    margin: 40px auto;
    width: 100%;
    max-width: 1072px;
    padding: 30px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.08);
    margin-bottom: 40px;
    position: relative;
    overflow: hidden;
}

/* Related Posts Heading Styling */
.related-heading {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 35px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
    position: relative;
}

.related-heading::before {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 180px;
    height: 2px;
    background: linear-gradient(90deg, #FF6228, #FFDD7E, #2196F3, #FFA6B5);
    border-radius: 2px;
}

.related-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 70px;
    height: 70px;
    border-radius: 18px;
    background: linear-gradient(135deg, #FF6228 0%, #FFDD7E 100%);
    color: white;
    font-size: 32px;
    box-shadow: 0 8px 20px rgba(255, 98, 40, 0.25);
    position: relative;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    z-index: 1;
}

.related-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #2196F3 0%, #3DFFCC 100%);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.related-icon:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 12px 25px rgba(33, 150, 243, 0.3);
}

.related-icon:hover::before {
    opacity: 1;
}

.related-icon:hover i {
    transform: rotate(10deg) scale(1.1);
}

.related-icon i {
    transition: transform 0.4s ease;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.1));
}

.related-heading-text {
    flex: 1;
}

.related-heading-text h2 {
    font-size: 2.0rem;
    color: #2c3e50;
    font-weight: 800;
    margin-bottom: 8px;
    background: linear-gradient(90deg, #5e35b1, #9c27b0);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.5px;
}

.related-heading-text p {
    font-size: 1.1rem;
    color: #7f8c8d;
    font-weight: 500;
    line-height: 1.5;
    max-width: 600px;
}

.related-heading-text p span {
    color: #FF6228;
    font-weight: 600;
}

/* Content Grid - Fixed for small screens */
.content-grid {
    margin: 0 auto;
    width: 100%;
    max-width: 1032px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 24px;
    padding: 0;
}

/* Fix for small screens - ensure all cards are equal width */
@media (max-width: 768px) {
    .content-grid {
        grid-template-columns: repeat(2, 1fr);
    } 
}

@media (max-width: 600px) {
    .content-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

.card {
    background: white;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s, box-shadow 0.3s;
    border: 1px solid #f0f0f0;
    display: flex;
    flex-direction: column;
    height: 100%;
    /* Make all cards equal height */
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
}

.card-image-container {
    width: 100%;
    height: 200px;
    overflow: hidden;
}

.card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.card:hover img {
    transform: scale(1.05);
}

.card-content {
    padding: 24px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.card h3 {
    margin-bottom: 12px;
    color: #5e35b1;
    font-size: 1.4rem;
    font-weight: 600;
    line-height: 1.4;
    transition: color 0.3s;
    flex-grow: 1;
}

.imghdghover:hover {
    color: #FF6228;
}

.card p {
    color: #666;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-top: auto;
}

.tdn {
    text-decoration: none;
    color: inherit;
    display: block;
}

/* Responsive adjustments for heading - UPDATED */
@media (max-width: 768px) {
    .related-heading {
        /* Removed flex-direction: column to keep icon and text side by side */
        align-items: center;
        gap: 15px;
        /* Slightly reduce gap on smaller screens */
    }

    .related-heading-text h2 {
        font-size: 1.7rem;
        font-weight: 700;
    }

    .related-icon {
        width: 60px;
        height: 60px;
        font-size: 28px;
        border-radius: 15px;
        flex-shrink: 0;
        /* Prevent icon from shrinking */
    }

    /* Optional: Adjust the gradient line width for smaller screens */
    .related-heading::before {
        width: 140px;
    }
}

@media (max-width: 480px) {
    .related-content {
        padding: 20px;
    }

    .related-heading {
        /* Ensure icon and text stay in one row even on very small screens */
        flex-wrap: nowrap;
        gap: 12px;
    }

    .related-heading-text h2 {
        font-size: 1.5rem;
        font-weight: 600;
        word-wrap: break-word;
        /* Prevent text overflow */
    }

    .related-icon {
        width: 50px;
        height: 50px;
        font-size: 24px;
        border-radius: 12px;
    }

    .related-heading::before {
        width: 100px;
    }
}

/* For very small screens, ensure text doesn't overflow */
@media (max-width: 360px) {
    .related-heading {
        gap: 10px;
    }

    .related-heading-text h2 {
        font-size: 1.3rem;
        font-weight: 500;
    }

    .related-icon {
        width: 45px;
        height: 45px;
        font-size: 22px;
    }
}

/* Decorative elements */
.related-content::after {
    content: '';
    position: absolute;
    top: -50px;
    right: -50px;
    width: 150px;
    height: 150px;
    background: linear-gradient(135deg, rgba(255, 98, 40, 0.05) 0%, rgba(33, 150, 243, 0.05) 100%);
    border-radius: 50%;
    z-index: 0;
}

.related-content::before {
    content: '';
    position: absolute;
    bottom: -30px;
    left: -30px;
    width: 100px;
    height: 100px;
    background: linear-gradient(135deg, rgba(255, 221, 126, 0.05) 0%, rgba(61, 255, 204, 0.05) 100%);
    border-radius: 50%;
    z-index: 0;
}

/* Ensure content stays above decorative elements */
.related-heading,
.content-grid {
    position: relative;
    z-index: 1;
}

/* Webpage Related Content Section Styling max-width: 1032px, end */