/* Offset for sections to avoid header overlap */
section {
    scroll-margin-top: 10vh; /* Adjust based on header height */
}

/* Match navbar height to home page */
nav {
    grid-template-rows: auto 0px;
}

#video-play {
    width: 50vw !important;
    max-width: 750px;
    height: auto;
}


.blog-container li {
    margin-bottom: 1vh;
}

.blog-container p {
    margin-bottom:1vh;
}

.blog-container h2 {
    text-align: center;
    margin-bottom: 4vh;
    margin-top: 2vh;
}

.blog-container h3 {
    margin-bottom: 1vh;
    margin-top: 2vh;
}

.blog-container ul {
    margin-top: 2vh;
}

/* Blog Title */
.blog-title {
    font-size: 2.5rem;
    color: #288DC7; /* Main brand color */
    text-align: center;
    margin: 0rem 0;
    padding-top: 0vh; /* Ensures the title is visible without overlap */
    max-width:800px;
    margin: 2rem auto;
    padding: 1.5rem;
    margin-top: 0;

}

/* Main Container */
.blog-container {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch; /* ensures children match tallest height */
    gap: 2vw;
    width: 100vw;
    max-width: 90vw;
    margin: 0 auto;
    padding-top: 12vh; /* Aligns with the title */
    padding-left: 4vw;
}

/* Individual blog card */
.blog-card {
    flex: 1 1 22%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

@media (max-width: 1024px) {
    .blog-card {
        flex: 1 1 45%;
    }
}

@media (max-width: 600px) {
    .blog-card {
        flex: 1 1 100%;
    }
}

/* Sidebar Styling */
/* Sidebar Styling */
.sidebar {
    width: 15vw;
    max-width: 15vw;
    padding: 1rem;
    background-color: #f9f9fb; /* Sidebar background color */
    box-shadow: 2px 0 5px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 50%;
    transform: translateY(-50%);
    margin-right: 2vw; /* Adds spacing from the main content */
    height: auto; /* Adjusts height to content */
    z-index: 10;
}

/* Main Content Styling */
.main-content {
    display: flex;
    flex-grow: 1;
    max-width: 100%;
    box-sizing: border-box;
    padding-top:0rem;
    padding-right: 2rem; /* Adds right padding for balanced spacing */
    margin-top:0;
    align-items: flex-start;
}

/* Content Section */
.content {
    margin-top: 0; /* Remove margin on top */
    padding-top: 0; /* Remove any extra padding on top */
}

/* Sections Styling */
.intro-section,
.key-takeaways,
.market-cap-section,
.market-cap-usage,
.beta-section,
.beta-usage,
.history-background,
.core-concepts,
.applications-section,
.risks-section,
.portfolio-strategies,
.vyfin-section,
.conclusion-section {
    max-width: 800px;
    margin: 2rem auto;
    padding: 1.5rem;
    background-color: #f9f9fb;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05); /* Subtle shadow */
}

.formula {
    font-family: 'Courier New', monospace;
    background-color: #f1f1f1;
    padding: 0.5rem;
    border-radius: 4px;
    display: block;
    color: #333;
    margin-bottom: 1vh;
    overflow-wrap: break-word;
    white-space: pre-wrap;
    max-width: 100%;
    box-sizing: border-box;
}

/* Specific Section Colors */
.intro-section {
    font-size: 1.1rem;
    line-height: 1.6;
    color: rgb(104, 106, 158); /* Smokey white text */
}

.key-takeaways {
    background-color: #e6f4ff; /* Light blue background for emphasis */
    border-left: 5px solid #288DC7; /* Blue accent line */
}

.core-concepts {
    background-color: #e6f4ff; /* Light blue background */
    border-left: 5px solid #288DC7; /* Blue accent line */
}

.key-takeaways h2 {
    font-size: 1.75rem;
    color: #288DC7;
}

.market-cap-section h2,
.beta-section h2 {
    font-size: 2rem;
    color: #721bde;
    margin-bottom: 1rem;
}

.portfolio-strategies h2 {
    font-size: 2rem;
    color: #49ad4d;
}

.vyfin-section {
    background-color: #e7e0ff; /* Light purple background */
    border-left: 5px solid #721bde;
}

.conclusion-section h2 {
    font-size: 2rem;
    color: #288DC7;
    text-align: center;
    margin-bottom: 1rem;
}

/* Link Styling */
a {
    color: #49ad4d; /* Green link color */
    text-decoration: none;
    font-weight: bold;
}

a:hover {
    color: #288DC7;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 1600px) {
    .blog-title {
        font-size: 2rem;
        margin: 1.5rem 0;
        padding-top: 10vh;
    }

    .blog-container {
        flex-direction: column;
        align-items: center;
        padding-left: 0;
    }

    .sidebar {
        position: relative;
        width: 100%;
        max-width: 100%;
        margin-bottom: 1rem;
        top: 0;
        transform: none;
        align-self: flex-start;
    }

    .main-content {
        flex-direction: column;
        padding-right: 0;
    }
}

