/*  insights-010.css
    Purpose        Styles for Insights article #010
                   “Tax-Loss Harvesting for UK Investors”.
                   Provides bespoke two-column layouts, responsive
                   tax-table, legal-wrapper, case-study blocks and
                   other helpers that sit **on top** of the global
                   styles-insights.css.

                   Key sections
                     ▸ §1 Hero two-column intro (image + text)
                     ▸ §3 Capital-gains tax table + data-source
                     ▸ §4 Investment horizon graphic (image left/right)
                     ▸ §5 Legal-considerations wrapper & highlight
                     ▸ §6 Case-study scenarios (wrapper → scenario blocks)
                     ▸ §7/8 Ordered & unordered lists   

    Load order     After styles-insights.css, e.g.

       <link rel="stylesheet" href="css/styles-insights.css">
       <link rel="stylesheet" href="css/insights-10.css">

  
    Last updated   31 Jul 2025
*/


/* Default styles (apply to all screen sizes) */

.image-column {
    flex: 0 0 auto;
    align-self: flex-start;
}

.image-column img {
    width: 400px;
    height: auto;
    background: transparent;
}

/* Apply two-column layout only for screens wider than 768px */
@media (min-width: 769px) {
    .two-column-layout-page {
        display: flex;
        align-items: center;
        gap: 20px;
    }

    .text-column {
        display: flex;
        flex-direction: column;
    }
}

/* Responsive adjustments for screens 768px and below */
@media (max-width: 768px) {

    h1 {
        line-height: 1.1;
        margin-bottom: 10px;
    }

    .two-column-layout-page {
        flex-direction: column;
        gap: 15px;
    }
    
    .image-column {
        align-self: center;
        display: flex;
        justify-content: center; /* Center the image horizontally */
        width: 100%;
    }
    
    .image-column img {
        width: 100%;
        max-width: 275px;
    }
}



/*Section 3*/

/* Tax Table Styles */
.tax-table-container {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch; /* Enables momentum scrolling on iOS */
}

.tax-table {
    width: 100%;
    min-width: 600px; /* Force a minimum width for the table */
    max-width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background-color: #252525;
    color: #FAF9F6;
    text-align: center;
    font-size: 16px;
    border-radius: 8px;
    overflow: hidden;
    table-layout: fixed;
}

.tax-table th {
    background-color: #4EA1D3;
    color: white;
    padding: 12px;
    font-weight: bold;
    word-wrap: break-word;
    word-break: break-word;
}

.tax-table td {
    padding: 12px;
    border-bottom: 1px solid #4EA1D3;
    word-wrap: break-word;
    word-break: break-word;
}

.tax-table tr:nth-child(even) {
    background-color: #2c3e50;
}

.tax-table tr:last-child td {
    font-weight: bold;
    background-color: #1a1a1a;
    color: #ffffff;
}

.data-source {
    margin-top: 10px;
    font-size: 0.8em;
    text-align: left;
    color: #bbb;
}

.data-source a {
    color: #4EA1D3;
    text-decoration: none;
}

.data-source a:hover {
    text-decoration: underline;
}

/* Responsive styles for portrait mobile (max-width: 768px) */
@media (max-width: 768px) {
    .tax-table {
        font-size: 14px; /* Reduce font size for smaller screens */
    }
    
    .tax-table th,
    .tax-table td {
        padding: 8px; /* Reduce padding for a more compact table */
    }
}


/* Default styles (apply to all screen sizes) */

/* Unique styling for Section 4 image column */
.section4-image-column {
    flex: 0 0 auto; /* Auto width based on defined image size */
    align-self: flex-start;
}

/* Adjust image size for Section 4 */
.section4-image-column img {
    width: 400px;
    height: auto;
    background: transparent;
}

/* Reverse layout for Section 4 (image left, text right) */
.section4-two-column-layout-page.reverse-layout .section4-image-column {
    order: 1;
}

.section4-two-column-layout-page.reverse-layout .section4-text-column {
    order: 2;
}

/* Apply two-column layout only for screens wider than 768px */
@media (min-width: 769px) {
    .section4-two-column-layout-page {
        display: flex;
        align-items: center;
        gap: 20px;
    }

    .section4-text-column {
        display: flex;
        flex-direction: column;
    }
}

/* Responsive adjustments for Section 4 on screens 768px and below */
@media (max-width: 768px) {
    .section4-two-column-layout-page {
        flex-direction: column;
        gap: 15px;
    }
    
    .section4-image-column {
        align-self: center;
        display: flex;
        justify-content: center; /* Center the image horizontally */
        width: 100%;
    }
    
    .section4-image-column img {
        width: 100%;
        max-width: 275px; /* Do not exceed original width */
    }
}



/* Section 5: Legal Considerations Example Container */

/* Container for the legal considerations example */
.legal-wrapper {
    display: block;
    width: 100%;
    border: 2px solid #ccc;
    background-color: #2c2c2c;
    padding: 30px;
    border-radius: 10px;
    margin-top: 40px;
    margin-bottom: 40px;
}

/* Section Title for the Example */
.legal-chart-title {
    text-align: center;
    font-size: 1.17em;
    font-weight: bold;
    width: 100%;
    margin-bottom: 20px !important;
    color: white;
    margin-top: -10px;
}

/* Container for the chart, matching the example text container's width */
.legal-chart-container {
    width: 100%;
    margin-bottom: 20px;
}

/* Chart Image Styling: image fills container width and maintains aspect ratio,
   with a maximum height to avoid being too tall */
.legal-chart-container img {
    width: 100%;
    height: auto;
    max-height: 4250px; /* Adjust this value if you need the chart shorter or taller */
    object-fit: contain;
    border-radius: 10px;
}

/* Full-Width Example Text Box */
.legal-example-text {
    width: 100%;
    color: white;
    font-size: 1em;
    line-height: 1.6;
}

/* Highlight Box inside the example text */
.legal-highlight-box {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 5px 20px; /* 5px vertical, 20px horizontal padding */
    border-radius: 8px;
/*    font-weight: bold;*/
}

/* Responsive Design for Mobile Portrait (max-width: 768px) */
@media (max-width: 768px) {
    .legal-wrapper {
        padding: 20px;
    }
    
    .legal-chart-title {
        font-size: 1.3em;
    }
    
    .legal-chart-container {
        width: 100%;
    }
    
    .legal-example-text {
        font-size: 1em;
    }
}


/*Section 6*/

/* Outer Container for Each Case Study */
.case-study {
  margin-bottom: 40px;
  padding: 20px;
  border: 2px solid #ccc;  /* Changed to contrasting color */
  border-radius: 8px;
  background-color: #2c2c2c;
  color: #fff;
}

/* Case Study Heading */
.case-study h3 {
  font-size: 1.3em;
  margin-bottom: 15px;
}

/* Scenario Wrapper for Each Set of Scenarios (No Border) */
.scenario-wrapper {
  background-color: rgba(255, 255, 255, 0.1);
  padding: 20px;
  border-radius: 10px;
  margin: 20px 0;
}

/* Scenario Heading */
.scenario-heading {
  text-align: center;
  font-size: 1.1em;
  font-weight: bold;
  margin-bottom: -15px;
  color: white;
}

/* Scenario Content */
.scenario-content {
  font-size: 0.95em;
  line-height: 1.6;
  color: white;
  padding: 10px;
}

/* Responsive Design for Mobile */
@media (max-width: 768px) {
  .case-study h3 {
    font-size: 1.2em;
  }
  .scenario-wrapper {
    padding: 15px;
  }
  .scenario-heading {
    font-size: 1.05em;
  }
  .scenario-content {
    font-size: 0.9em;
  }
}


/*Section 7/8*/
ul li {
  margin-bottom: 12px; /* Adjust the spacing as needed */
}




