/* Define your custom color palette using CSS variables */
:root {
    --light-cream: #f1f2eb; /* Very light, almost white */
    --dark-charcoal: #4a4a48; /* Dark gray for text and strong elements */

    /* Main accent color and its generated shades */
    --soft-teal: #d0e2e1;
    --soft-teal-100: #f0f6f5; /* Lighter shade for gradients */
    --soft-teal-200: #e1edec;
    --soft-teal-300: #d2e4e2;
    --soft-teal-400: #c3dbd8;
    --soft-teal-500: #b4d2cf;
    --soft-teal-600: #a5c9c6;
    --soft-teal-700: #96c0bd;
    --soft-teal-800: #87b7b4;
    --soft-teal-900: #78aeab; /* Darker shade for hover */
    
    /* New color variables for light rose powder, used for buttons and content boxes */
    --light-rose-powder: #f9e6e6; /* A soft, muted pink/rose */
    --light-rose-powder-900: #e0cccc; /* A darker shade for hover */
}

/* Basic styling for the body and overall layout */
body {
    font-family: 'Inter', sans-serif;
    background-color: var(--light-cream); /* Fallback or subtle base color */
    transition: background-color 0.5s ease;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex; /* Use flexbox to center content */
    flex-direction: column; /* Stack items vertically */
    align-items: center; /* Center horizontally */
    justify-content: center; /* Center vertically */
}

/* New: Main container to correctly stack content vertically */
.main-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 2rem 1rem; /* Add padding top and bottom, and horizontal padding */
    width: 100%; /* Ensure it takes up full width for centering */
    max-width: 650px; /* Optional: Set a max-width for large screens */
    margin: 0 auto; /* This also helps with centering, but flex on body is more robust */
}

/* Styling for the full-page background image */
.affirmation-background-image {
    position: fixed; /* Fixed to viewport, stays in place on scroll */
    top: 0;
    left: 0;
    width: 100vw; /* Cover full viewport width */
    height: 100vh; /* Cover full viewport height */
    object-fit: cover; /* Covers the entire area without distortion */
    z-index: -1; /* Place far behind all other content */
    opacity: 0.8; /* Set to 0.8 to make text more readable */
    transition: opacity 0.5s ease-in-out; /* Smooth fade for image */
}

/* Styling for the main affirmation card/box */
.affirmation-card {
    max-width: 600px; /* Use a max-width for better responsiveness */
    width: 100%;
    background-color: #FFFFFF; /* Explicitly white background for the box */
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    text-align: center;
    z-index: 1; /* Ensure card content is above the background image */
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-bottom: 2rem; /* Space below the card to the next element */
}

/* Ensure text and logo are visible above the image */
.logo-container, .card-title, #affirmation-text, .new-affirmation-btn, .card-footer {
    position: relative; /* Ensure these elements are above the card's own background (if any) */
    z-index: 2; /* Higher than the card's background and the page background image */
}

/* Styling for the main title */
.card-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--dark-charcoal); /* Dark text for strong contrast */
    margin-bottom: 1.5rem;
}
/* Responsive font size for title */
@media (min-width: 640px) {
    .card-title {
        font-size: 2.25rem;
    }
}

/* Styling for the affirmation text */
#affirmation-text {
    font-size: 1.25rem;
    font-style: italic;
    color: var(--dark-charcoal); /* Dark text for good readability */
    margin-bottom: 2rem;
    min-height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    transition: opacity 0.5s ease-in-out;
}
/* Responsive font size for affirmation text */
@media (min-width: 640px) {
    #affirmation-text {
        font-size: 1.5rem;
    }
}

/* Styling for the button */
.new-affirmation-btn {
    background-color: var(--soft-teal); /* Main button color */
    color: var(--dark-charcoal); /* Dark text for contrast on button */
    font-weight: 600;
    padding: 0.75rem 1.5rem;
    border-radius: 9999px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease-in-out;
    border: none;
    cursor: pointer;
}
.new-affirmation-btn:hover {
    background-color: var(--soft-teal-900); /* Darker shade on hover */
    color: var(--light-cream); /* Light text on darker hover */
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
    transform: scale(1.05);
}

/* Styling for the footer */
.card-footer {
    margin-top: 2rem;
    color: var(--dark-charcoal); /* Dark text for footer */
    font-size: 0.875rem;
}

/* Logo specific styling for the image */
.logo-container {
    margin-bottom: 1.5rem; /* Space below the logo */
    display: flex;
    justify-content: center;
}

.logo-image {
    max-width: 120px; /* Adjust max width as needed */
    height: auto; /* Maintain aspect ratio */
    border-radius: 50%; /* If your logo is circular and you want this CSS effect */
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); /* Subtle shadow for depth */
}

/* NEW: Container for the icon buttons to arrange them horizontally */
.action-buttons-container {
    display: flex;
    justify-content: center;
    gap: 1rem; /* Space between buttons */
    margin-top: 1rem; /* Space from the New Affirmation button */
}

/* NEW: Base styling for icon buttons */
.icon-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    padding: 0;
    font-size: 1.2rem;
    border-radius: 9999px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease-in-out;
    border: none;
    cursor: pointer;
    text-decoration: none;
}
.icon-btn:hover {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
    transform: scale(1.05);
}

/* NEW: Styling for the single combined count text */
#combined-interaction-count {
    font-size: 0.7rem;
    color: var(--dark-charcoal);
    margin-top: 0.5rem;
    font-weight: 500;
    text-align: center;
    width: 100%;
}

/* NEW: Specific styling for the Download Image button */
.download-btn {
    background-color: var(--light-rose-powder);
    color: var(--dark-charcoal);
}
.download-btn:hover {
    background-color: var(--light-rose-powder-900);
    color: var(--dark-charcoal);
}

/* NEW: Specific styling for the Share to Social Media button */
.share-btn {
    background-color: var(--soft-teal);
    color: var(--dark-charcoal);
}
.share-btn:hover {
    background-color: var(--soft-teal-900);
    color: var(--light-cream);
}

/* NEW: Hidden canvas for image generation */
#share-canvas {
    display: none;
}

/* NEW: CSS to disable text selection */
.no-select {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* NEW: SEO static content section */
.static-content-for-seo {
    margin-top: 0; /* No need for a top margin, the parent container handles it */
    padding: 2rem;
    background-color: #FFFFFF; /* Changed to a white background for better visual separation */
    border-radius: 1rem;
    text-align: left;
    max-width: 600px; /* Keep it consistent with the card */
    margin-bottom: 2rem; /* Add space at the bottom */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08); /* Consistent box shadow */
}

.static-content-for-seo h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-charcoal);
    margin-bottom: 1rem;
}

.static-content-for-seo p {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--dark-charcoal);
}
.footer {
    margin-top: 0; /* No need for a top margin, the parent container handles it */
    padding: 2rem;
    text-align: left;
    max-width: 600px; /* Keep it consistent with the card */
    margin-bottom: 2rem; /* Add space at the bottom */
    color: var(--light-rose-powder);
}

/* Adjust the main body layout for blog posts to allow for vertical scrolling */
body.blog-page {
    justify-content: flex-start; /* Align content to the top instead of centering */
}

/* General container for the blog page content */
.blog-main-container {
    padding: 2rem 1rem;
    width: 100%;
    max-width: 900px; /* Wider container for the blog layout */
    margin: 0 auto;
}

/* Blog header styling, similar to the card title */
.blog-header {
    text-align: center;
    padding-bottom: 2rem;
    padding-top: 1rem;
}

.blog-header-title {
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--dark-charcoal);
    margin-bottom: 0.5rem;
}

.blog-header-subtitle {
    font-size: 1.25rem;
    color: var(--dark-charcoal);
}

/* Container for the grid of blog post cards */
.blog-posts-container {
    display: grid;
    grid-template-columns: 1fr; /* Single column on mobile */
    gap: 2rem;
}

/* Responsive grid for larger screens */
@media (min-width: 768px) {
    .blog-posts-container {
        grid-template-columns: repeat(2, 1fr); /* Two columns on desktop */
    }
}

/* Styling for each individual blog post card */
.blog-post-card {
    background-color: var(--light-rose-powder);
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: transform 0.3s ease-in-out;
    text-decoration: none; /* Remove underline from the link */
    color: inherit; /* Inherit text color */
}

.blog-post-card:hover {
    transform: translateY(-5px); /* Subtle lift on hover */
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.blog-post-card-image {
    width: 100%;
    height: 250px; /* Fixed height for consistent card size */
    object-fit: cover;
    display: block;
}

.blog-post-card-content {
    padding: 1.5rem;
}

.blog-post-card-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--dark-charcoal);
    margin-bottom: 0.5rem;
}

.blog-post-card-meta {
    font-size: 0.875rem;
    color: var(--dark-charcoal);
    opacity: 0.7;
    margin-bottom: 1rem;
}

.blog-post-card-excerpt {
    font-size: 1rem;
    color: var(--dark-charcoal);
    line-height: 1.6;
}

/* Styling for the single blog post page */
.single-post-container {
    width: 100%;
    max-width: 800px;
    background-color: #FFFFFF;
    border-radius: 0.75rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    padding: 2rem;
    margin-top: 2rem;
    margin-bottom: 2rem;
}

.back-link {
    display: inline-block;
    color: var(--soft-teal-900);
    font-weight: 600;
    margin-bottom: 2rem;
    text-decoration: none;
    transition: color 0.3s ease;
}

.back-link:hover {
    color: var(--soft-teal);
}

.single-post-image {
    width: 100%;
    height: auto;
    border-radius: 0.75rem;
    margin-bottom: 2rem;
}

.single-post-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark-charcoal);
    margin-bottom: 0.5rem;
}

.single-post-meta {
    font-size: 1rem;
    color: var(--dark-charcoal);
    opacity: 0.7;
    margin-bottom: 2rem;
}

.single-post-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--dark-charcoal);
}

.single-post-content p {
    margin-bottom: 1.5rem;
}