/* ===================================================================
   ConstructPro - Public Stylesheet
   Version: 2.0 (Refactored)
   =================================================================== */

/* --- 1. Global Settings & Variables --- */
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@400;600;700&family=Raleway:wght@400;500;600;700;800&display=swap');

:root {
    --cpro-primary-blue: #0d6efd; /* A strong, professional blue for actions */
    --cpro-primary-blue-darker: #0b5ed7;
    --cpro-primary-yellow: #ffc107; /* The brand's amber/yellow accent */
    --cpro-dark-text: #2c3e50;      /* Dark blue-gray for headings */
    --cpro-body-text: #343a40;      /* Standard dark gray for body */
    --cpro-light-gray: #f8f9fa;     /* Light background color */
    --cpro-footer-bg: #212529;      /* Dark footer background */
}

body {
    font-family: 'Open Sans', sans-serif;
    color: var(--cpro-body-text);
    line-height: 1.7;
    padding-top: 70px; /* Account for fixed navbar */
    background-color: #ffffff;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Raleway', sans-serif;
    font-weight: 700;
    color: var(--cpro-dark-text), var(--cpro-light-gray);
}

a {
    color: var(--cpro-primary-blue);
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}
a:hover {
    color: var(--cpro-primary-blue-darker);
    text-decoration: none; /* Often preferred over underline for modern look */
}

.btn-primary {
    background-color: var(--cpro-primary-blue);
    border-color: var(--cpro-primary-blue);
    font-weight: 600;
}
.btn-primary:hover {
    background-color: var(--cpro-primary-blue-darker);
    border-color: var(--cpro-primary-blue-darker);
}

.btn-accent {
    background-color: var(--cpro-primary-yellow);
    border-color: var(--cpro-primary-yellow);
    color: var(--cpro-dark-text);
    font-weight: 600;
}
.btn-accent:hover {
    background-color: #e0a800; /* Darker yellow */
    border-color: #d39e00;
    color: var(--cpro-dark-text);
}


/* --- 2. Layout: Navbar & Footer --- */
.navbar-brand i.fa-hard-hat {
    color: var(--cpro-primary-yellow);
}

.navbar.fixed-top.navbar-scrolled {
    background-color: rgba(33, 37, 41, 0.98) !important; /* Darker with slight transparency */
    box-shadow: 0 0.125rem 0.25rem rgba(0,0,0,.075);
    transition: background-color 0.3s ease-in-out;
}

.public-footer {
    background-color: var(--cpro-footer-bg);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}
.public-footer h5 {
    color: #fff;
    margin-bottom: 1rem;
    font-weight: 600;
}
/* This is the fix for the footer icon color */
.public-footer .navbar-brand i.fa-hard-hat {
    color: var(--cpro-primary-yellow);
}
.public-footer .footer-links a {
    color: rgba(255, 255, 255, 0.6);
    transition: color 0.2s ease;
}
.public-footer .footer-links a:hover {
    color: #fff;
}
.public-footer .copyright {
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255,255,255,0.1);
}

/* --- 3. Reusable Components & Sections --- */
.content-section {
    padding: 4.5rem 0;
}

.section-title {
    font-weight: 700;
    color: var(--cpro-dark-text);
    position: relative;
    padding-bottom: 0.75rem;
    margin-bottom: 3rem !important;
}
.section-title::after {
    content: '';
    position: absolute;
    display: block;
    width: 60px;
    height: 4px;
    background: var(--cpro-primary-yellow);
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
}

.hover-shadow {
    transition: box-shadow .3s ease-in-out, transform .3s ease-in-out;
}
.hover-shadow:hover {
    transform: translateY(-5px);
    box-shadow: 0 .5rem 1.5rem rgba(0,0,0,.1)!important;
}

.info-card {
    background-color: #fff;
    border: 1px solid #e9ecef;
    border-radius: .5rem;
    padding: 2rem;
}
.info-card i {
    font-size: 2.5rem;
    color: var(--cpro-primary-yellow);
    margin-bottom: 1rem;
    display: block;
}
.info-card h3 {
    font-size: 1.4rem;
}

/* --- 4. Page Specific: Homepage --- */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.55)), url('/images/construction-hero.jpg') no-repeat center center;
    background-size: cover;
    color: white;
    padding: 6rem 0;
}
.hero-section h1 {
    font-size: 3rem;
    font-weight: 800;
    color: white;
}
.hero-section .lead {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2rem;
}

/* --- 5. Page Specific: Blog & Single Post --- */

.blog-header {
    padding: 2.5rem 0;
    background-color: var(--cpro-light-gray);
    border-bottom: 1px solid #dee2e6;
}
.blog-header h1 {
    font-size: 3rem;
}
.blog-header .lead {
    font-size: 1.1rem;
    color: #6c757d;
}

.blog-post-card-item .card-title a {
    color: var(--cpro-dark-text);
    font-weight: 700;
}
.blog-post-card-item .card-title a:hover {
    color: var(--cpro-primary-blue);
}
.blog-post-card-item .card-text.text-muted {
    font-size: 0.85rem;
}

/* --- 6. *** FIX: Blog Sidebar Styles *** --- */
.public-aside-sidebar .card {
    border: 1px solid #e9ecef;
    margin-bottom: 1.5rem; /* Space between widgets */
}
.public-aside-sidebar .card-header {
    background-color: var(--cpro-light-gray);
    border-bottom: 1px solid #dee2e6;
    padding: 0.85rem 1.25rem;
}
.public-aside-sidebar .card-header h5 {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 0;
}
.public-aside-sidebar .card-header h5 i {
    color: var(--cpro-primary-blue);
    margin-right: 0.5rem;
    font-size: 0.9em;
}
.public-aside-sidebar .card-body {
    padding: 1.25rem;
}
/* Search Widget within Sidebar */
.public-aside-sidebar .input-group .form-control:focus {
    border-color: var(--cpro-primary-blue);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}
/* Recent Posts Widget */
.public-aside-sidebar .list-group-item {
    padding-left: 0;
    padding-right: 0;
    border-bottom: 1px solid #f0f0f0;
}
.public-aside-sidebar .list-group-item:last-child {
    border-bottom: none;
}
.public-aside-sidebar .list-group-item a {
    color: var(--cpro-body-text);
    font-weight: 600;
    display: block; /* Makes the whole item clickable */
}
.public-aside-sidebar .list-group-item small.text-muted {
    font-size: 0.8em;
    margin-top: 0.2rem;
}
/* Categories/Tags Widget */
.public-aside-sidebar .category-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem; /* Adds space between the tag buttons */
}
.public-aside-sidebar .category-tags .btn {
    font-size: 0.8rem;
    padding: 0.3rem 0.65rem;
}



.page-header, h1 {
    font-size: 3rem;
    font-weight: 800;
    color:aliceblue;
}
.header-title {
    font-size: 4rem;
    font-weight: 800;
}


.header-section {
    background: linear-gradient(rgba(0, 0, 0, 0.55), rgba(0, 0, 0, 0.55)), url('/images/showcase.jpg') no-repeat center center;
    background-size: cover;
    color: white;
    padding: 4rem 0;
}

/* --- Cookie Consent Banner Styles --- */
#cookieConsentBanner {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: var(--primary-dark-bg, #2c3e50); /* Assuming a dark primary background variable */
    color: var(--text-light, #f8f9fa); /* Light text color */
    padding: 18px 25px;
    text-align: center;
    box-shadow: 0 -3px 15px rgba(0, 0, 0, 0.25);
    z-index: 1050; /* Ensure it's above other elements, e.g., Bootstrap modals are 1050 */
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px; /* Space between text and button */
}

#cookieConsentBanner p {
    margin-bottom: 0; /* Remove default paragraph margin */
    font-size: 0.95rem;
    line-height: 1.6;
    max-width: 800px; /* Limit width for better readability on large screens */
}

#cookieConsentBanner a {
    color: var(--link-color-primary, #007bff); /* Primary link color */
    text-decoration: underline;
    transition: color 0.2s ease-in-out;
}

#cookieConsentBanner a:hover {
    color: var(--link-color-hover, #0056b3); /* Darker on hover */
}

#cookieConsentBanner button {
    background-color: var(--button-primary-bg, #007bff); /* Primary button background */
    color: var(--button-primary-text, white);
    border: none;
    padding: 10px 30px;
    border-radius: 0.375rem; /* Bootstrap's default border-radius */
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.3s ease, transform 0.1s ease;
    font-weight: 500;
}

#cookieConsentBanner button:hover {
    background-color: var(--button-primary-hover, #0056b3); /* Darker on hover */
    transform: translateY(-1px);
}

/* Responsive adjustments for smaller screens */
@media (max-width: 768px) {
    #cookieConsentBanner {
        padding: 15px 15px;
        flex-direction: column;
        text-align: center;
    }
    #cookieConsentBanner p {
        font-size: 0.9rem;
    }
    #cookieConsentBanner button {
        width: 100%;
        max-width: 250px;
    }
}