/* ==== CSS Variables - Color Palette & Theme ==== */
:root {
    /* Casal Palette Hex Codes */
    --casal-50: #effcfc;
    --casal-100: #d6f5f7;
    --casal-200: #b3ebee;
    --casal-300: #7edae2;
    --casal-400: #42c2ce;
    --casal-500: #26a5b4;
    --casal-600: #238697;
    --casal-700: #226c7c;
    --casal-800: #245966;
    --casal-900: #224b57;
    --casal-950: #11313b;

    /* RGB Component Variables (for use in rgba()) */
    --casal-50-rgb: 239, 252, 252;
    --casal-100-rgb: 214, 245, 247;
    --casal-500-rgb: 38, 165, 180;
    --casal-800-rgb: 36, 89, 102;
    --casal-900-rgb: 34, 75, 87;
    --primary-accent-rgb: 38, 165, 180; /* Added for .tab-search-input:focus */


    /* Theme Variables */
    --page-bg: var(--casal-50); /* Or transparent if you prefer */
    --primary-accent: var(--casal-500);
    --primary-accent-darker: var(--casal-600);
    --text-main: var(--casal-900);
    --text-subdued: var(--casal-700);
    --text-light: var(--casal-50);
    --card-bg: #ffffff;
    --border-color: var(--casal-200);

    /* PIP Category/Status Color Variables (Examples) */
    --limitedtime: #e74c3c;
    --pip-cat-abode-color: #3498db;
    --pip-cat-deepblue-color: #2980b9;
    --pip-cat-metapwr-color: #1abc9c;
    --pip-cat-onguard-color: #f39c12;
    --pip-cat-serenitysleep-color: #8e44ad;
    --pip-cat-productline-color: #7f8c8d;
}

/* ==== Basic Reset & Defaults ==== */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, system-ui, sans-serif, Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
    line-height: 1.6;
    background-color: transparent; /* Body background transparent for iframe */
    color: var(--text-main);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.container {
    width: 90%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 20px 0; /* Default container padding, can be overridden */
}

/* ==== Header Navigation (Main Site Navigation Bar) ==== */
.site-header {
    background-color: transparent;
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
    /* box-shadow: 0 2px 4px rgba(var(--casal-900-rgb),0.05); */ /* Optional subtle shadow */
}

.site-header .container { /* Ensure this container is full width or wide enough */
    display: flex;
    justify-content: center; /* Center nav if no logo, or space-between if logo exists */
    align-items: center;
    padding: 0 20px; /* Padding for the header container */
}

.main-nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap; /* Allow main nav items to wrap if necessary */
    justify-content: center; /* Center items if they wrap */
    gap: 10px 20px; /* Row gap, Column gap */
}

.main-nav a {
    text-decoration: none;
    color: var(--text-subdued);
    font-size: large;
    font-weight: 300;
    padding: 8px 10px; /* Padding on nav links */
    position: relative;
    transition: color 0.3s ease;
    display: inline-block; /* Ensure padding applies correctly */
}

.main-nav a:hover,
.main-nav a.active {
    color: var(--primary-accent);
}

.main-nav a.active::after {
    content: '';
    position: absolute;
    bottom: -1px; /* Align with the site-header border */
    left: 10px; /* Match padding */
    right: 10px; /* Match padding */
    height: 3px;
    background-color: var(--primary-accent);
    border-radius: 1.5px;
}

/* ==== Main Content Area ==== */
.main-content {
    flex-grow: 1;
    padding-top: 30px;
    padding-bottom: 50px;
}
.main-content.resources-page .container,
.main-content.faq-page .container,
.main-content.inspired-page .container { /* Specific container padding for these pages if needed */
    padding: 0; /* Reset if .tabs-container handles its own padding */
}


.page-title {
    text-align: center;
    font-size: 1.5rem;
    color: var(--text-main);
    margin-bottom: 15px;
    padding: 0 20px; /* Add some padding if container padding was removed */
}

.page-subtitle {
    text-align: center;
    font-size: 1.1rem;
    color: var(--text-subdued);
    margin-bottom: 0px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 10px;
}
ul {
  display: block;
  list-style-type: disc;
  /* margin-top: 1em;  User CSS was 1 em */
  /* margin-bottom: 1 em; User CSS was 1 em */
  margin-top: 1em;
  margin-bottom: 1em;
  margin-left: 0;
  margin-right: 0;
  padding-left: 40px;
}
/* ==== Video Section (Tutorial Page) ==== */
.universal-video-container {
    position: relative;
    overflow: hidden;
    width: 100%;
    max-width: 800px; /* Your original constraint */
    margin: 0 auto 20px auto; /* Your original margin */
    /* padding-top: 56.25%;  16:9 Aspect Ratio (9 / 16 * 100) */
    /* Your inline style was 56.31%, which is very close. Use 56.25% for perfect 16:9 */
    padding-top: 56.25%; /* Or 56.31% if you prefer the exact value you had */
    /* background-color: #000; Optional, can be removed if video loads reliably */
}

.universal-video-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: 0; /* Matches frameborder="0" */
}


/* Mobile Adjustments (Optional - above should be responsive) */
@media (max-width: 600px) {
    .universal-video-container {
        max-width: 100%; /* Allow full width on small screens */
    }
    h2 { /* This is a very general h2 style, might need more specificity */
        font-size: 1.2em;
    }
}

/* ==== Buttons (General) ==== */
.btn {
    display: inline-block;
    background-color: var(--primary-accent);
    color: #fff; /* Ensure good contrast with accent */
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    text-align: center;
    transition: background-color 0.3s ease, transform 0.2s ease;
    border: none;
    cursor: pointer;
    box-shadow: 0 2px 4px rgba(var(--casal-500-rgb), 0.2);
}
.btn:hover {
    background-color: var(--primary-accent-darker);
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(var(--casal-500-rgb), 0.3);
}
.btn-center {
    display: block;
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

/* ==== Footer ==== */
.site-footer {
    background-color: transparent;
    color: var(--text-subdued);
    text-align: center;
    padding: 30px 20px;
    font-size: 0.85rem;
    border-top: 1px solid var(--border-color);
}
.site-footer p {
    max-width: 800px;
    margin: 0 auto 10px auto;
    line-height: 1.5;
}
.site-footer p:last-child {
    margin-bottom: 0;
}

/* ==== Get Inspired Page Styles ==== */
.inspired-page .page-title { margin-bottom: 40px; }
.inspiration-section { margin-bottom: 60px; }
.inspiration-section .intro-text {
    max-width: 650px;
    margin: 0 auto 35px auto;
    text-align: center;
    color: var(--text-subdued);
    font-size: 1.1rem;
    line-height: 1.7;
}
.inspiration-section .intro-text p { margin-bottom: 15px; }
.prompt-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
.prompt-card {
    background-color: var(--card-bg);
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(var(--casal-900-rgb), 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-left: 5px solid var(--primary-accent);
}
.prompt-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(var(--casal-900-rgb), 0.12);
}
.prompt-card h3 {
    color: var(--primary-accent);
    font-size: 1.25rem;
    margin-bottom: 10px;
}
.prompt-card p {
    font-size: 0.95rem;
    line-height: 1.6;
    color: var(--text-subdued);
}
.wave-divider {
    margin: 30px 0 50px 0; /* Full width margin */
    line-height: 0;
    width: 100%;
}
.wave-divider svg { display: block; width: 100%; height: auto; max-height: 70px; }
.wave-divider svg path:nth-child(1) { fill: var(--casal-200); opacity: 0.7; }
.wave-divider svg path:nth-child(2) { fill: var(--casal-300); opacity: 0.5; }

/* ==== FAQ Page Styles ==== */
.faq-page .page-title { margin-bottom: 10px; }
.faq-page .page-subtitle { margin-bottom: 50px; }
.faq-list { max-width: 800px; margin: 0 auto; }
.faq-item {
    background-color: var(--card-bg);
    margin-bottom: 15px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 5px rgba(var(--casal-900-rgb), 0.05);
    transition: box-shadow 0.3s ease;
}
.faq-item[open] { box-shadow: 0 4px 12px rgba(var(--casal-900-rgb), 0.1); }
.faq-item[open] .faq-question { border-bottom: 1px solid var(--border-color); }
.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 20px;
    font-weight: 600;
    cursor: pointer;
    color: var(--text-main);
    list-style: none; /* Hides details marker in some browsers */
    transition: background-color 0.2s ease;
}
.faq-question::-webkit-details-marker, .faq-question::marker { display: none; } /* Standard way to hide marker */
.faq-question:hover { background-color: var(--casal-50); }
.faq-question::after { /* Using ::after for custom icon */
    content: '+';
    font-size: 1.5em;
    color: var(--primary-accent);
    font-weight: bold;
    transition: transform 0.3s ease;
    margin-left: 10px;
}
.faq-item[open] > .faq-question::after { content: '−'; /* Unicode minus U+2212 */ }
.faq-answer {
    padding: 20px;
    font-size: 0.95rem;
    line-height: 1.7;
    color: var(--text-subdued);
    border-top: 1px dashed var(--casal-100); /* Only show when open, can be inside [open] */
}
.faq-answer p { margin-bottom: 10px; }
.faq-answer p:last-child { margin-bottom: 0; }
.faq-answer a { color: var(--primary-accent); text-decoration: underline; }
.faq-answer a:hover { color: var(--primary-accent-darker); text-decoration: none; }

/* ==== Content Divider Styling ==== */
.content-divider {
    border: none;
    height: 1px;
    background-color: var(--border-color);
    margin: 40px 0; /* Increased margin */
}


/* ==== Resources Page - Tabs, Search, and Content (REVISED & CONSOLIDATED) ==== */
.resources-page .page-title {
    margin-bottom: 40px; /* More space above tabs */
}

.tabs-container {
    width: 100%;
    margin-bottom: 40px;
    background-color: #fff;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(var(--casal-800-rgb), 0.07);
    padding: 0;
}

.tab-navigation {
    display: flex;
    flex-wrap: wrap;
    padding: 6px 6px 0 6px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0;
}

.tab-button {
    padding: 6px 8px;
    cursor: pointer;
    background-color: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    outline: none;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-subdued);
    position: relative;
    transition: color 0.3s ease, border-bottom-color 0.3s ease;
    margin-right: 3px;
    margin-bottom: -1px; /* Overlap for seamless active border */
    text-decoration: none; /* For anchor tags */
    display: inline-block;
}
.tab-button:last-child {
    margin-right: 0;
}
.tab-button:hover {
    color: var(--primary-accent);
}
.tab-button.active {
    color: var(--primary-accent);
    border-bottom-color: var(--primary-accent);
    font-weight: 700;
}

/* Mobile: Horizontal scrollable tabs for better UX */
@media (max-width: 768px) {
    .tab-navigation {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch; /* Smooth scrolling on iOS */
        scrollbar-width: thin; /* Firefox */
        scrollbar-color: var(--casal-300) transparent; /* Firefox */
        padding-bottom: 6px;
        position: relative;
    }

    /* Fade gradient on right edge to indicate more content */
    .tab-navigation::after {
        content: '';
        position: absolute;
        right: 0;
        top: 0;
        bottom: 0;
        width: 30px;
        background: linear-gradient(to right, transparent, white);
        pointer-events: none;
    }

    /* Subtle scrollbar styling for Chrome, Safari and Opera */
    .tab-navigation::-webkit-scrollbar {
        height: 4px;
    }

    .tab-navigation::-webkit-scrollbar-track {
        background: transparent;
    }

    .tab-navigation::-webkit-scrollbar-thumb {
        background: var(--casal-300);
        border-radius: 2px;
    }

    .tab-navigation::-webkit-scrollbar-thumb:hover {
        background: var(--casal-400);
    }

    .tab-button {
        white-space: nowrap; /* Prevent text wrapping */
        flex-shrink: 0; /* Prevent buttons from shrinking */
        font-size: 0.9rem;
        padding: 8px 12px;
    }
}

.tab-content-panels {
    padding: 15px 10px;
}

.tab-panel {
    display: none; /* Controlled by JS and .active class */
    animation: fadeIn 0.5s ease-out;
}
.tab-panel.active {
    display: block;
}

.tab-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 15px;
}
.tab-header h2 {
    font-size: 1.5rem;
    color: var(--primary-accent);
    margin: 0;
    line-height: 1.2;
}
.tab-header > .btn.pip-external-link-btn { /* Button in PIP header */
    font-size: 0.9rem;
    padding: 10px 20px;
    margin-left: 20px;
    white-space: nowrap;
    flex-shrink: 0;
}

.tab-search-input {
    padding: 10px 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 0.95rem;
    min-width: 260px;
    max-width: 100%;
}
.tab-search-input:focus {
    outline: none;
    border-color: var(--primary-accent);
    box-shadow: 0 0 0 3px rgba(var(--primary-accent-rgb), 0.2);
}
.no-results-message {
    color: var(--text-subdued);
    font-style: italic;
    padding: 25px 0;
    text-align: center;
    display: none; /* Initially hidden, JS will show it */
}

/* Generic Resource Grid */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
}
/* Generic ebook Card Styling - Used by ebooks */
/* ====== Ebook Card with Image ====== */
.resource-card.ebook-card-with-image {
    display: flex;
    flex-direction: column; /* Title on top, body below */
    gap: 12px;
    padding: 15px;
    background-color: #fff;
    border-radius: 12px;
    border: 1px solid var(--casal-100);
    box-shadow: 0 4px 12px rgba(var(--casal-900-rgb), 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}

/* Hover effect */
.resource-card.ebook-card-with-image:hover {
    transform: translateY(-5px);
    box-shadow: 0 7px 22px rgba(var(--casal-900-rgb), 0.1);
}

/* ====== Title Styling ====== */
.resource-card.ebook-card-with-image .ebook-title {
    text-align: center;
    margin: 0;
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--casal-800);
}

/* ====== Body Wrapper (Image + Description) ====== */
.resource-card.ebook-card-with-image .ebook-card-body {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    gap: 16px;
}

/* ====== Image Styling ====== */
.resource-card.ebook-card-with-image .ebook-card-img {
    width: 110px !important;
    height: 140px !important;
    object-fit: cover;
    border-radius: 3px;
    flex-shrink: 0;
    display: block;
}

/* ====== Content Area ====== */
.resource-card.ebook-card-with-image .resource-card-content {
    padding: 0;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* ====== Description Text ====== */
.resource-card.ebook-card-with-image .resource-description {
    margin: 0 0 12px;
    font-size: 0.9rem;
    line-height: 1.5;
    color: var(--text-subdued);
}

/* ====== Full-Width Button ====== */
.resource-card.ebook-card-with-image .full-width-btn {
    display: block;
    width: 100%;
    text-align: center;
    margin-top: auto;
}

/* ====== Auto-Fix for Cards Without Images ====== */
.resource-card.ebook-card-with-image .ebook-card-body:not(:has(img)) {
    display: block; /* Make layout single-column if no image */
}

/* ====== Mobile Responsive ====== */
@media (max-width: 768px) {
    .resource-card.ebook-card-with-image .ebook-card-body {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .resource-card.ebook-card-with-image .ebook-card-img {
        width: 80% !important;
        height: auto !important;
        margin-bottom: 10px;
    }

    .resource-card.ebook-card-with-image .resource-card-content {
        align-items: center;
    }

    .resource-card.ebook-card-with-image .full-width-btn {
        width: 100%;
    }
}
/* ==== Magazine Grid & Card Styles ==== */

/* Magazine grid: 4 per row on desktop */
.magazine-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

/* Tablets: 2 per row */
@media (max-width: 1024px) {
  .magazine-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile: 1 per row */
@media (max-width: 600px) {
  .magazine-grid {
    grid-template-columns: 1fr;
  }

  /* Make covers larger on mobile */
  .magazine-card .magazine-cover {
    width: min(75%, 220px);
  }
}


/* Generic Resource Card Styling - Used by PIPs */
.resource-card {
    background-color: #fff;
    border-radius: 12px;
    border: 1px solid var(--casal-100);
    box-shadow: 0 4px 12px rgba(var(--casal-900-rgb), 0.06);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    display: flex; /* Useful for quick-link-anchor to fill height */
    flex-direction: column;
    overflow: hidden;
    position: relative;
    background-image: linear-gradient( to bottom, rgba(var(--casal-100-rgb), 0.3), rgba(var(--casal-50-rgb), 0.05) 30%, transparent 60% );
}
.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 7px 22px rgba(var(--casal-900-rgb), 0.1);
}
.resource-card img { /* For blog cards with images, not directly used by current PIP card structure */
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.resource-card-content { /* For blog cards with distinct content areas */
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.resource-card-content h3 {
    font-size: 1.15rem;
    color: var(--casal-800);
    font-weight: 600;
    margin-bottom: 10px;
    line-height: 1.3;
}
.resource-card-content .resource-description {
    font-size: 0.9rem;
    color: var(--text-subdued);
    line-height: 1.6;
    margin-bottom: 15px;
    flex-grow: 1;
}
.resource-card-content .resource-meta {
    font-size: 0.8rem;
    color: var(--text-subdued);
    margin-bottom: 8px;
    text-transform: uppercase;
}
.btn.resource-btn {
    margin-top: auto;
    align-self: flex-start;
    padding: 10px 20px;
}

/* Quick Links Card Styling - Used by PIPs */
.resource-card.quick-link-card {
    border-left: 5px solid var(--primary-accent);
}
a.quick-link-anchor { /* The <a> tag inside the quick-link-card */
    display: block;
    padding: 20px 25px;
    text-decoration: none !important;
    color: var(--text-main) !important;
    font-weight: 500;
    font-size: 1rem;
    line-height: 1.4;
    height: 100%; /* Make the anchor fill the card */
    box-sizing: border-box;
    transition: color 0.2s ease;
}


.resource-card.quick-link-card:hover a.quick-link-anchor {
    color: var(--primary-accent) !important;
}


/* Category Filter Bar Styling - Used by PIPs */
.category-filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 30px;
    padding-bottom: 15px;
}
.category-filter-btn { /* Used by PIP category filters */
    padding: 8px 18px;
    font-size: 0.9rem;
    background-color: transparent;
    color: var(--text-subdued);
    border: 1px solid var(--casal-200);
    border-radius: 20px; /* Pill shape */
    cursor: pointer;
    transition: background-color 0.3s ease, color 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}
.category-filter-btn:hover {
    background-color: var(--casal-100);
    border-color: var(--casal-300);
    color: var(--primary-accent);
}
.category-filter-btn.active {
    background-color: var(--primary-accent);
    color: #fff;
    border-color: var(--primary-accent);
    font-weight: 600;
    box-shadow: 0 2px 5px rgba(var(--primary-accent-rgb), 0.2);
}

/* PIP Status Label Styling (not currently used by PIPs, but here for completeness) */
.pip-status-label {
    display: inline-block;
    font-size: 0.75rem;
    padding: 3px 8px;
    border-radius: 4px;
    color: white;
    background-color: var(--pip-status-bg, var(--text-subdued)); /* Fallback color */
    margin-left: 10px;
    vertical-align: middle;
    font-weight: 500;
}

/* Class used by JS to hide items that don't match search/filter */
.searchable-item { /* This class is added by JS to PIP cards */
    /* display: block; or flex, grid etc. based on card type */
    /* transition: opacity 0.3s ease, transform 0.3s ease; Optional: for smoother hide/show */
}
.searchable-item[style*="display: none"] { /* Style for when JS hides it, more specific than .item-filtered-out if you had both */
    /* You could add transitions here if you were animating opacity/height instead of display:none */
}
/* .item-filtered-out { display: none !important; } /* Original class from user, JS now sets display directly */


/* Animation for tab panel fade in */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* PIPs Tab - Specific Content Styling (if any beyond resource-card) */
#pips .tab-header h2 { /* The h2 within the PIPs tab panel */
    /* width: auto; Already handled by flexbox */
    /* text-align: left; Default for h2 */
    /* border-bottom: none; No border on h2 by default */
    /* padding-bottom: 0; No padding on h2 by default */
}
.pip-explanation-content { /* For a different PIP page layout, not the link grid */
    display: flex;
    flex-wrap: wrap;
    gap: 35px;
    align-items: flex-start;
    margin-bottom: 40px;
}
.pip-text-section { flex: 2; min-width: 300px; }
.pip-text-section h3 {
    font-size: 1.45rem;
    color: var(--primary-accent);
    margin-top: 25px;
    margin-bottom: 12px;
}
.pip-text-section h3:first-of-type { margin-top: 0; }
.pip-text-section p { margin-bottom: 18px; line-height: 1.75; color: var(--text-subdued); }
.pip-text-section ul { list-style: disc; margin-left: 20px; padding-left: 10px; margin-bottom: 20px; color: var(--text-subdued); }
.pip-text-section ul li { margin-bottom: 10px; line-height: 1.75; }
.pip-text-section ul li strong { color: var(--text-main); font-weight: 600; }
.pip-image-section { flex: 1; min-width: 280px; text-align: center; margin-top: 10px; }
.pip-image-section img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 6px 18px rgba(var(--casal-800-rgb), 0.1);
}

.pip-cta-section {
    text-align: center;
    padding: 30px 20px;
    background-color: var(--casal-50);
    border-radius: 8px;
    margin-top: 30px;
    margin-bottom: 40px;
}
.pip-cta-section h3 {
    font-size: 1.5rem;
    color: var(--text-main);
    margin-bottom: 10px;
}
.pip-cta-section p {
    margin-bottom: 20px;
    color: var(--text-subdued);
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}
.pip-essential-chat-integration {
    margin-top: 40px;
    padding: 25px;
    background-color: var(--casal-50);
    border-radius: 10px;
    text-align: center;
}
.pip-essential-chat-integration h4 {
    font-size: 1.3rem;
    color: var(--primary-accent);
    margin-bottom: 12px;
}
.pip-essential-chat-integration p {
    color: var(--text-subdued);
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.7;
}

/* Responsive adjustments */
@media (max-width: 600px) {
    .prompt-grid, .resource-grid { /* Affects PIPs grid */
        grid-template-columns: 1fr; /* Stack cards on smaller screens */
    }
    .inspiration-section .intro-text,
    .pip-text-section { /* For PIPs page text sections, not the link grid */
        text-align: left;
    }
    .tab-header { /* Affects PIPs tab header */
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    .tab-header > .btn.pip-external-link-btn,
    .tab-header .tab-search-input { /* Affects PIPs tab search */
        margin-left: 0;
        width: 100%;
    }
    .pip-explanation-content {
        gap: 20px;
    }
}

/* ==== Get Inspired Page V2 Styles ==== */
.inspired-page-v2 .page-title { margin-bottom: 15px; }
.inspired-page-v2 .page-subtitle { margin-bottom: 50px; font-size: 1.15rem; max-width: 700px; }

/* Featured Prompts Carousel Section */
.featured-prompts-carousel-section { margin-bottom: 60px; text-align: center; }
.featured-prompts-carousel-section h2 { font-size: 1.8rem; color: var(--text-main); margin-bottom: 30px; }
.carousel-container {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    background-color: #fff;
    border-radius: 16px;
    padding: 30px 50px;
    box-shadow: 0 10px 30px rgba(var(--casal-800-rgb), 0.07);
    background-image: linear-gradient( to bottom, rgba(var(--casal-100-rgb), 0.4), rgba(var(--casal-50-rgb), 0.1) 10%, transparent 40% );
}
.carousel-slides { position: relative; overflow: hidden; height: 150px; display: flex; }
.carousel-slide {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.6s ease-in-out;
}
.carousel-slide.active { display: flex; opacity: 1; z-index: 1; }
/* .carousel-slide .slide-content { } */ /* Not used with current structure */
.carousel-slide h3 { font-size: 1.4rem; color: var(--primary-accent-darker); margin-bottom: 10px; }
.carousel-slide p { font-size: 1rem; color: var(--text-subdued); max-width: 80%; margin: 0 auto; }
.carousel-button {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(var(--casal-900-rgb), 0.3);
    color: white;
    border: none;
    padding: 10px;
    cursor: pointer;
    border-radius: 50%;
    z-index: 2;
    font-size: 1.5rem;
    line-height: 1;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.carousel-button:hover { background-color: rgba(var(--casal-900-rgb), 0.5); }
.carousel-button.prev { left: 10px; }
.carousel-button.next { right: 10px; }
.carousel-dots { text-align: center; margin-top: 20px; }
.carousel-dot {
    display: inline-block;
    width: 15px;
    height: 15px;
    background-color: var(--casal-200);
    border-radius: 50%;
    margin: 0 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, border-color 0.3s ease;
    border: 1px solid var(--casal-700);
}
.carousel-dot.active { background-color: var(--primary-accent); border-color: var(--primary-accent-darker); }

/* Unified Category Grid Section */
.category-grid-section { margin-bottom: 60px; text-align: center; }
.category-grid-section h2 { font-size: 1.8rem; color: var(--text-main); margin-bottom: 30px; }
.inspiration-category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    text-align: left;
    perspective: 1000px;
}

/* Flip Card Styles for Get Inspired Page V2 */
.flip-card-container {
    background-color: transparent;
    width: 100%;
    min-height: 180px;
    border-radius: 12px;
    cursor: pointer;
}
.flip-card-container:focus { outline: 2px solid var(--primary-accent); outline-offset: 2px; }
.flip-card-inner {
    position: relative;
    width: 100%;
    height: 100%;
    text-align: center;
    transition: transform 0.7s;
    transform-style: preserve-3d;
    box-shadow: 0 6px 18px rgba(var(--casal-900-rgb), 0.07);
    border-radius: 12px;
}
.flip-card-container.flipped .flip-card-inner { transform: rotateY(180deg); }
.flip-card-front, .flip-card-back {
    position: absolute;
    width: 100%;
    height: 100%;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    box-sizing: border-box;
}
.flip-card-front { background-color: var(--card-bg); color: var(--text-main); border: 1px solid var(--border-color); }
.flip-card-front h3 { font-size: 1.3rem; color: var(--primary-accent-darker); margin-bottom: 10px; }
.flip-card-front .front-tagline { font-size: 0.95rem; color: var(--text-subdued); line-height: 1.5; }
.flip-card-back {
    background-color: var(--primary-accent);
    color: var(--text-light);
    transform: rotateY(180deg);
    border: 1px solid var(--primary-accent-darker);
}
.flip-card-back h4 { font-size: 1.1rem; margin-bottom: 15px; border-bottom: 1px solid rgba(var(--casal-50-rgb), 0.5); padding-bottom: 8px; }
.flip-card-back ul { list-style: none; padding: 0; text-align: left; max-width: 90%; }
.flip-card-back ul li { font-size: 0.9rem; margin-bottom: 8px; line-height: 1.5; }
.flip-card-back ul li::before { content: "› "; margin-right: 5px; font-weight: bold; }

/* Ask Anything Section */
.ask-anything-section {
    text-align: center;
    padding: 40px 20px;
    background-color: var(--casal-100);
    border-radius: 12px;
    margin-top: 40px;
}
.ask-anything-section h2 { font-size: 1.8rem; color: var(--text-main); margin-bottom: 15px; }
.ask-anything-section p { font-size: 1.1rem; color: var(--text-subdued); max-width: 600px; margin: 0 auto 25px auto; }
.btn.btn-primary-cta { font-size: 1.1rem; padding: 12px 30px; }

/* ==== Chatbot Page Styles ==== */
.chatbot-page .page-title { margin-bottom: 10px; }
.chatbot-page .page-subtitle { margin-bottom: 30px; }
.chatbot-container { max-width: 100%; padding: 0 10px; }
.chatbot-iframe-wrapper {
    width: 100%;
    height: 700px; /* Or height: 70vh; min-height: 600px; max-height: 800px; */
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(var(--casal-800-rgb), 0.07);
    position: relative;
}
.chatbot-iframe-wrapper iframe { display: block; width: 100%; height: 100%; border: none; }

.webpage-embed-iframe {
    display: block; /* Ensures proper block-level behavior */
    width: 100%;    /* Fills the container's width */
    height: 80vh;   /* Sets height to 80% of the viewport's (screen's) height */
    min-height: 650px; /* Ensures it's not too short on smaller screens */
    border: none;   /* Removes the default iframe border */
    border-radius: 8px; /* Optional: adds rounded corners to match your site's aesthetic */
    background-color: #f8f8f8; /* A light background color while the content loads */
}

/* Add this to the end of your styles.css file */

/* ================================================== */
/* ==== My Oil Cabinet (MOC) Hero Section Styles ==== */
/* ================================================== */

.moc-hero-section {
    display: flex;
    align-items: center;
    gap: 50px; /* Space between text and image */
    padding: 40px 30px; /* Padding inside the hero box */
    background-color: #F9F8FC; /* Very light purple/gray background */
    border-radius: 16px; /* Match your other container styles */
    overflow: hidden;
}

.moc-text-content {
    flex: 1; /* Takes up half the space */
}

.moc-image-content {
    flex: 1; /* Takes up the other half */
    text-align: center; /* Center the image within its column */
    margin-top: 30px; /* Add spacing between buttons and image */
}

/* --- Text Styling --- */
.moc-text-content h1 {
    font-size: 3.2rem; /* Large, impactful headline */
    font-weight: 700;
    line-height: 1.2;
    color: #3d3d3d; /* A dark, soft black */
    margin-bottom: 20px;
}

.moc-gradient-text {
    /* The magic for the gradient text */
    background: linear-gradient(90deg, #226c7c, #034f60 120%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    --text-fill-color: transparent;
    font-weight: 800; /* Make it slightly bolder */
}

.moc-subtitle {
    font-size: 1.3rem;
    color: #034f60;
    margin-bottom: 10px;
    line-height: 1.5;
}

.moc-text-content p:not(.moc-subtitle) {
    font-size: 1rem;
    color: #666;
    margin-bottom: 35px;
    line-height: 1.6;
}

/* --- Button Styling --- */
.moc-cta-button {
    display: inline-block;
    text-decoration: none;
    background-color: #226c7c; /* Vibrant teal */
    color: #fff;
    padding: 15px 25px;
    border-radius: 50px; /* Pill shape */
    font-weight: 600;
    font-size: 1.1rem;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 15px rgba(50, 159, 165, 0.3);
}

.moc-cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(50, 159, 165, 0.4);
}

/* --- Image Styling --- */
.moc-image-content img {
    max-width: 100%;
    height: auto;
    border-radius: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

/* --- Responsive Adjustments for Mobile --- */
@media (max-width: 900px) {
    .moc-hero-section {
        flex-direction: column; /* Stack columns vertically */
        text-align: center; /* Center-align text */
        gap: 35px;
    }

    .moc-text-content h1 {
        font-size: 2.5rem; /* Slightly smaller headline on mobile */
    }

    .moc-cta-button {
        width: 80%;
        max-width: 300px; /* Ensure button isn't overly wide */
    }

    /* Put image on top on mobile for better flow */
    .moc-image-content {
        order: -1;
    }
}
    /* === eBook card: NO DESCRIPTION — stack, center, grow image === */
    .resource-card.ebook-card-with-image.no-description {
    flex-direction: column !important;
    align-items: center !important;
    text-align: center;
    }

    .resource-card.ebook-card-with-image.no-description .ebook-card-body {
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center;
    gap: 12px;
    }

    .resource-card.ebook-card-with-image.no-description .resource-card-content {
    display: none !important; /* hide the empty text column */
    }

    .resource-card.ebook-card-with-image.no-description .ebook-card-img {
    width: 180px !important;     /* override the 110px from the base rule */
    height: 240px !important;    /* keep ~3:4 aspect */
    object-fit: cover;
    display: block;
    margin: 0 auto;
    }

    /* Optional tweak for very small screens */
    @media (max-width: 600px) {
    .resource-card.ebook-card-with-image.no-description .ebook-card-img {
        width: min(70%, 220px) !important;
        height: auto !important;
  }
}