/**
Theme Name: Astra Child
Author: Brainstorm Force
Author URI: http://wpastra.com/about/
Description: Astra is the fastest, fully customizable & beautiful theme suitable for blogs, personal portfolios and business websites. It is very lightweight (less than 50KB on frontend) and offers unparalleled speed. Built with SEO in mind, Astra comes with schema.org code integrated so search engines will love your site. Astra offers plenty of sidebar options and widget areas giving you a full control for customizations. Furthermore, we have included special features and templates so feel free to choose any of your favorite page builder plugin to create pages flexibly. Some of the other features: # WooCommerce Ready # Responsive # Compatible with major plugins # Translation Ready # Extendible with premium addons # Regularly updated # Designed, Developed, Maintained & Supported by Brainstorm Force. Looking for a perfect base theme? Look no further. Astra is fast, fully customizable and beautiful theme!
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: astra-child
Template: astra
*/
// Rollup Engagement Prompt Block Template
function render_rollup_prompt_block( $block, $content = '', $is_preview = false ) {
    // Get the field data
    $show_prompt = get_field('show_rollup_prompt');
    
    if ( ! $show_prompt ) {
        return;
    }
    
    $prompt = get_field('rollup_custom_prompt');
    
    if ( ! $prompt ) {
        return;
    }
    ?>
    
    <div class="rollup-engagement-prompt">
        <div class="rollup-icon"><?php echo esc_html( $prompt['icon'] ?: '?' ); ?></div>
        <h3 class="rollup-title"><?php echo esc_html( $prompt['title'] ?: 'What Do You Think?' ); ?></h3>
        <p class="rollup-question"><?php echo esc_html( $prompt['question'] ); ?></p>
        <a href="#comments" class="rollup-button"><?php echo esc_html( $prompt['button_text'] ?: 'Leave A Comment Below' ); ?></a>
    </div>
    
    <?php
}
/* ========================================
   CSS GRID LAYOUT - SCUBA INSIDER PRO
   Article Layout System
   ======================================== */

/* GRID CONTAINER - Three Columns */
.article-grid-wrapper {
    display: grid;
    grid-template-columns: 
        minmax(20px, 1fr)           /* Left margin */
        minmax(300px, 800px)        /* Content column */
        minmax(20px, 1fr);          /* Right margin */
    gap: 2rem;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* FULL-WIDTH ELEMENTS - Span All Columns */
.article-grid-wrapper .featured-image-full,
.article-grid-wrapper .entry-header,
.article-grid-wrapper .entry-footer {
    grid-column: 1 / 4;
}

/* MAIN CONTENT - Center Column Only */
.article-grid-wrapper .entry-content {
    grid-column: 2;
}

/* ARTICLE SUMMARY BLOCK - Full Width */
.article-summary-block {
    grid-column: 1 / 4;
    max-width: 85%;
    margin: 0 auto 2.5rem auto;
}

/* ========================================
   VISUAL PITSTOP CALLOUT BOXES
   ======================================== */

/* Base Styles */
.visual-pitstop {
    padding: 1.5rem;
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    margin-bottom: 2rem;
}

/* Right Margin Callout */
.visual-pitstop-right {
    grid-column: 3;
    align-self: start;
    max-width: 350px;
    justify-self: start;
}

/* Left Margin Callout */
.visual-pitstop-left {
    grid-column: 1;
    align-self: start;
    max-width: 350px;
    justify-self: end;
}

/* Full-Width Breakout */
.visual-pitstop-full {
    grid-column: 1 / 4;
    max-width: 100%;
}

/* Callout Type Colors */
.visual-pitstop-species {
    border-top: 4px solid #0099cc;
}

.visual-pitstop-geographic {
    border-top: 4px solid #d946a6;
}

.visual-pitstop-threats {
    border-top: 4px solid #ff6b35;
}

.visual-pitstop-environmental {
    border-top: 4px solid #4ade80;
}

/* Callout Typography */
.visual-pitstop .pitstop-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
    margin-bottom: 0.75rem;
    font-family: 'Oswald', sans-serif;
    color: #666;
}

.visual-pitstop h4 {
    margin: 0.5rem 0;
    font-size: 1.1rem;
    font-family: 'Bitter', Georgia, serif;
}

.visual-pitstop p {
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0.5rem 0;
}

.visual-pitstop img {
    width: 100%;
    height: auto;
    border-radius: 4px;
    margin-bottom: 1rem;
}

/* ========================================
   BREAKOUT IMAGES
   ======================================== */

/* Full-Width Breakout Image */
.breakout-image-full {
    grid-column: 1 / 4;
    width: 100%;
    margin: 3rem 0;
}

.breakout-image-full img {
    width: 100%;
    height: auto;
    display: block;
}

/* Content + Right Margin */
.breakout-image-right {
    grid-column: 2 / 4;
    width: 100%;
    margin: 2.5rem 0;
}

.breakout-image-right img {
    width: 100%;
    height: auto;
    display: block;
}

/* Left Margin + Content */
.breakout-image-left {
    grid-column: 1 / 3;
    width: 100%;
    margin: 2.5rem 0;
}

.breakout-image-left img {
    width: 100%;
    height: auto;
    display: block;
}

/* Image Captions */
.breakout-image-full figcaption,
.breakout-image-right figcaption,
.breakout-image-left figcaption {
    font-size: 0.9rem;
    font-style: italic;
    color: #666;
    padding: 0.75rem 1rem;
    text-align: center;
    font-family: 'Merriweather', Georgia, serif;
}

/* ========================================
   RESPONSIVE LAYOUT
   ======================================== */

/* Desktop Medium */
@media (max-width: 1399px) {
    .article-grid-wrapper {
        grid-template-columns: minmax(20px, 1fr) minmax(300px, 750px) minmax(20px, 1fr);
    }
}

/* Tablet Landscape */
@media (max-width: 1199px) {
    .article-grid-wrapper {
        grid-template-columns: minmax(20px, 1fr) minmax(300px, 700px) minmax(20px, 1fr);
    }
    
    .visual-pitstop-right,
    .visual-pitstop-left {
        max-width: 300px;
    }
}

/* Tablet Portrait & Mobile - SINGLE COLUMN */
@media (max-width: 991px) {
    .article-grid-wrapper {
        grid-template-columns: 1fr;
        padding: 0 15px;
    }
    
    /* Everything becomes full-width and stacks */
    .article-grid-wrapper .entry-content,
    .visual-pitstop-right,
    .visual-pitstop-left,
    .visual-pitstop-full,
    .breakout-image-right,
    .breakout-image-left,
    .breakout-image-full {
        grid-column: 1;
        max-width: 100%;
    }
    
    .visual-pitstop {
        padding: 1.25rem;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .article-grid-wrapper {
        gap: 1rem;
        padding: 0 10px;
    }
    
    .visual-pitstop {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
}