/*
 Theme Name:   Divi Child — Green Stocks Research
 Theme URI:    https://greenstocksresearch.com
 Description:  Child theme for the Divi parent theme. Safe storage for all custom CSS.
 Author:       Green Stocks Research
 Author URI:   https://greenstocksresearch.com
 Template:     Divi
 Version:      1.0.0
 Text Domain:  divi-child-gsr
*/

/* =============================================================================
   SECTION 1 — LAYOUT: SIDEBAR & FULL-WIDTH CONTENT
   (Hides Divi sidebar, expands content area to full width on desktop)
   Remove this section once the Divi Theme Builder header/footer is live
   and all old Divi Builder posts have been replaced with Gutenberg HTML.
============================================================================= */

/*** Remove divider line between content and sidebar ***/
#main-content .container:before { background: none; }

/*** Hide Sidebar ***/
#sidebar { display: none; }

/*** Expand the content area to full width on desktop ***/
@media (min-width: 981px) {
    #left-area {
        width: 100%;
        padding: 23px 0px 0px !important;
        float: none !important;
    }
}

/* =============================================================================
   SECTION 2 — SINGLE POST TITLE & SPACING
   Hides the duplicate WordPress block title on posts that use custom HTML,
   and removes the top padding gap above the post content area.
============================================================================= */

/*** Hide WordPress default title on single posts with custom HTML ***/
.single-post .entry-title,
.single-post .wp-block-post-title {
    display: none;
}

/*** Remove top spacing above post content on single posts ***/
body.single-post #main-content .container {
    padding-top: 0px !important;
}

/* =============================================================================
   SECTION 3 — MOBILE LOGO SIZING
   Constrains the Divi header logo to 150px on small screens.
   NOTE: Once the custom Theme Builder header is activated, this rule will be
   superseded by the header's own responsive CSS and can be removed.
============================================================================= */

@media (max-width: 980px) {
    #logo,
    img.df-site-logo {
        width: 150px !important;
        height: auto !important;
    }
}

/* =============================================================================
   SECTION 4 — MAILPOET NEWSLETTER SIGNUP FORM
   Styles the MailPoet form embedded in the site footer and post sidebars.
   Keep this section permanently — it is independent of Divi Builder.
============================================================================= */

/* Wrapper block */
.gsr-mp-block {
    font-family: 'Open Sans', sans-serif;
    padding: 0 0 20px 0;
}

/* Eyebrow label */
.gsr-mp-eyebrow {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.2px;
    color: #2E7D32;
    margin-bottom: 10px;
}

/* Heading */
.gsr-mp-block h3 {
    font-family: 'Merriweather', serif;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.3;
    color: #1a1a1a;
    margin-bottom: 10px;
    letter-spacing: -0.3px;
}

/* Description text */
.gsr-mp-desc {
    font-size: 14px;
    color: #444;
    line-height: 1.65;
    margin: 0 0 6px;
}

/* Bullet list */
.gsr-mp-bullets {
    list-style: none;
    margin: 12px 0 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.gsr-mp-bullets li {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    color: #555;
}

.gsr-mp-bullets li::before {
    content: '';
    width: 5px;
    height: 5px;
    background: #2E7D32;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 6px;
}

/* Divider */
.gsr-mp-divider {
    border: none;
    border-top: 1px solid #d4e8d4;
    margin: 20px 0 0;
}

/* MailPoet form container */
.mailpoet_form {
    max-width: 680px !important;
    margin: 12px auto 0 !important;
}

/* Email input field */
.mailpoet_form input[type="email"],
.mailpoet_form input.mailpoet_text,
.mailpoet_form input.mailpoet_email {
    width: 100% !important;
    padding: 11px 14px !important;
    border: 1.5px solid #c8d8c8 !important;
    border-radius: 4px !important;
    font-size: 14px !important;
    font-family: 'Open Sans', sans-serif !important;
    color: #1a1a1a !important;
    background: #fff !important;
    box-sizing: border-box !important;
    outline: none !important;
}

.mailpoet_form input[type="email"]:focus,
.mailpoet_form input.mailpoet_text:focus,
.mailpoet_form input.mailpoet_email:focus {
    border-color: #2E7D32 !important;
}

/* Submit button */
.mailpoet_form input[type="submit"],
.mailpoet_form button[type="submit"],
.mailpoet_form .mailpoet_submit {
    width: 100% !important;
    background: #2E7D32 !important;
    color: #fff !important;
    font-family: 'Open Sans', sans-serif !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    border: none !important;
    border-radius: 4px !important;
    padding: 12px 20px !important;
    cursor: pointer !important;
    transition: background .2s !important;
    margin-top: 10px !important;
    box-sizing: border-box !important;
}

.mailpoet_form input[type="submit"]:hover,
.mailpoet_form button[type="submit"]:hover,
.mailpoet_form .mailpoet_submit:hover {
    background: #1b5e20 !important;
}

/* =============================================================================
   SECTION 5 — SUPPRESS DIVI DEFAULT HEADER & FOOTER
   Activate this section AFTER you have published a Global Header and Global
   Footer in Divi → Theme Builder. These rules ensure the old default Divi
   header/footer cannot bleed through alongside the custom ones.

   NOTE: Divi Theme Builder replaces the default header/footer automatically
   when a Global layout is published. These rules are a safety net only.
   Comment them out again if you ever disable the Theme Builder templates.
============================================================================= */

/*** Hide Divi default header (Theme Builder header is now live) ***/
#main-header { display: none !important; }
#et-main-area { margin-top: 0 !important; }

/*** Hide Divi default footer (Theme Builder footer is now live) ***/
#main-footer { display: none !important; }

/* =============================================================================
   SECTION 6 — THEME BUILDER HEADER/FOOTER GLOBAL CSS
   Once the Divi Theme Builder header/footer is live, you can add any tweaks
   here (e.g., active-page link highlighting, sticky behaviour adjustments).
   The component-level CSS lives inside each Theme Builder Code module.
============================================================================= */

/* Placeholder — add any global header/footer overrides here */
