/*
Theme Name: Low Energy Services 2026
Description: Modern Bootstrap 5.3 Build - High Contrast Edition
Author:Lundie Media
*/

/* Standard browsers (Chrome, Edge, Opera, Safari) */
::selection {
    background-color: #b7cd00 !important;
    color: #000000 !important;
}

/* Firefox specific */
::-moz-selection {
    background-color: #b7cd00 !important;
    color: #000000 !important;
}

:root {
    --bs-primary: #b7cd00;
    --bs-primary-rgb: 183, 205, 0;
    --dark-bg: #121212;
    --bg-dark: black;
    --glass: rgba(255, 255, 255, 0.05);
}

body { font-family: 'Cabin', sans-serif; background-color: #fff; color: #1a1a1a; overflow-x: hidden; }

/* Sticky Header with Blur Effect */
.main-header { 
    position: sticky; 
    top: 0; 
    z-index: 1050; 
    background: rgba(18, 18, 18, 0.95); 
    backdrop-filter: blur(10px);
    border-bottom: 3px solid var(--bs-primary); 
}

/* Hero Slider Logic */
.hero-slider { height: 80vh; position: relative; background: #000; overflow: hidden; display: flex; align-items: center; }
.hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: 0; animation: fade 24s infinite; }
.hero-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(0,0,0,0.7), rgba(0,0,0,0.3)); }

@keyframes fade { 0%, 20% { opacity: 1; } 25%, 100% { opacity: 0; } }
.bg1 { background-image: url('https://lowenergyservices.co.uk/wp-content/uploads/2024/03/a-commercial-solar-install-_1_.webp'); animation-delay: 0s; }
.bg2 { background-image: url('https://lowenergyservices.co.uk/wp-content/uploads/2025/03/ground-mounted-solar-installers.jpg'); animation-delay: 6s; }
.bg3 { background-image: url('https://lowenergyservices.co.uk/wp-content/uploads/2024/03/top-golf-solar-installation-_1__1.webp'); animation-delay: 12s; }
.bg4 { background-image: url('https://lowenergyservices.co.uk/wp-content/uploads/2024/03/business-solar-installer-in-glasgow-scotland-_1__1.webp'); animation-delay: 18s; }

/* Infinite Ticker (Smooth Scroll) */
.logo-ticker { background: #fff; padding: 60px 0; overflow: hidden; position: relative; }
.ticker-track { display: flex; width: calc(250px * 28); animation: scroll 60s linear infinite; }
.ticker-track:hover { animation-play-state: paused; }
.ticker-track img { width: 180px; margin: 0 40px; filter: grayscale(1); opacity: 0.5; transition: 0.3s; }
.ticker-track img:hover { filter: grayscale(0); opacity: 1; transform: scale(1.1); }
@keyframes scroll { 0% { transform: translateX(0); } 100% { transform: translateX(calc(-250px * 14)); } }

/* Reveal Framework */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s cubic-bezier(0.2, 1, 0.3, 1); }
.reveal.active { opacity: 1; transform: translateY(0); }

/* Front Action Tabs */
.action-card { border: none; transition: 0.4s; padding: 50px 20px; text-decoration: none !important; }
.bg-green { background-color: var(--bs-primary); color: #000; }
.bg-dark-grey { background-color: #222; color: #fff; }
.bg-med-grey { background-color: #333; color: #fff; }
.action-card:hover { transform: translateY(-10px); background-color: #000; color: var(--bs-primary); }

/* MEGA MENU OVERRIDES */
@media (min-width: 1200px) {
    .dropdown-full-width { position: static !important; }
    
    .dropdown-full-width .dropdown-menu {
        width: 100vw;
        left: 0;
        right: 0;
        margin-top: 0;
        background: #121212; /* Deep Black */
        border-top: 4px solid #b7cd00; /* Branding Green */
        border-bottom: 1px solid #333;
        border-radius: 0;
        padding: 0;
        transition: all 0.2s ease-in-out;
    }

    /* Column Headers */
    .megamenu h6 {
        font-size: 0.75rem;
        letter-spacing: 1.5px;
        color: #b7cd00 !important;
        text-transform: uppercase;
        border-bottom: 1px solid #333;
        padding-bottom: 10px;
    }

    /* Links inside Mega Menu */
    .megamenu .dropdown-item {
        color: #e0e0e0 !important;
        padding: 8px 0 !important;
        font-weight: 400;
        font-size: 1rem;
        background: transparent !important;
    }

    .megamenu .dropdown-item:hover {
        color: #b7cd00 !important;
        transform: translateX(5px);
        transition: 0.2s;
    }
}

/* MOBILE MENU ADJUSTMENTS */
@media (max-width: 1199px) {
    .navbar-collapse {
        background: #121212;
        padding: 20px;
        margin-top: 10px;
    }
    .megamenu h6 {
        margin-top: 20px;
        color: #b7cd00;
    }
}

/* Fix Blue Links in Content */
.entry-content a, 
section p a {
    color: var(--bs-primary) !important;
    text-decoration: underline;
    font-weight: 700;
}

.entry-content a:hover, 
section p a:hover {
    color: #000 !important;
    background-color: var(--bs-primary);
    text-decoration: none;
}

/* Action Card Icon Styling */
.action-icon {
    height: 80px;
    width: auto;
    margin-bottom: 20px;
    transition: transform 0.4s ease;
}

.action-card:hover .action-icon {
    transform: scale(1.1) rotate(-5deg);
    filter: brightness(0) invert(1); /* Turns icons white on hover */
}

/* Logo Ticker Styles */
.logo-ticker {
    overflow: hidden;
    padding: 40px 0;
    background: #fff;
    white-space: nowrap;
    position: relative;
}

/* The track that moves */
.ticker-track {
    display: inline-flex;
    align-items: center;
    animation: marquee 90s linear infinite;
   
}

.ticker-track img {
    height: 60px; /* Adjust logo size */
    width: auto;
    display: block;
    filter: grayscale(100%); /* Optional: makes logos look professional */
    opacity: 0.7;
    transition: 0.3s;
}

.ticker-track img:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* The Animation Loop */
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); } /* We loop halfway because we duplicate the content */
}

/* Optional: Pause on hover */
.logo-ticker:hover .ticker-track {
    animation-play-state: paused;
}

/* --- Overriding Bootstrap btn-primary for Solar Brand --- */
.btn-primary {
    position: relative;
    display: inline-block;
    padding: 11px 15px !important;
    background-color: #1a1a1a !important; /* Start Dark */
    color: #ffffff !important;
    font-weight: 700 !important;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: none !important;
    border-radius: 0 !important; /* Force Sharp Corners */
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.215, 0.61, 0.355, 1) !important;
    z-index: 1;
    cursor: pointer;
}

/* The Swipe Layer */
.btn-primary::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background-color: #b7cd00; /* Brand Green */
    transition: all 0.4s cubic-bezier(0.215, 0.61, 0.355, 1);
    z-index: -1;
}

/* Hover States */
.btn-primary:hover {
    background-color: #1a1a1a !important; /* Keep base dark so swipe shows over it */
    color: #000000 !important; /* Text turns black on green */
    transform: translateY(-3px); /* Subtle Lift */
    box-shadow: 0 10px 20px rgba(0,0,0,0.2) !important;
}

/* Trigger the Swipe */
.btn-primary:hover::before {
    width: 100%;
}


/* Fix for potential text jitter during animation */
.btn-primary {
    -webkit-font-smoothing: antialiased;
    transform: translateZ(0);
}

/* --- Header Phone Button Custom Class --- */
.btn-nav-phone {
    position: relative;
    display: inline-flex;
    align-items: center;
    padding: 12px 25px !important;
    background-color: #b7cd00 !important; /* Start with Brand Green */
    color: #000000 !important; /* Black text on Green */
    font-weight: 700 !important;
    border: none !important;
    border-radius: 0 !important; /* Sharp corners */
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.215, 0.61, 0.355, 1) !important;
    z-index: 1;
}

/* The Swipe Layer (Dark Background on Hover) */
.btn-nav-phone::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background-color: #ffffff; /* Swipes to White for high contrast in header */
    transition: all 0.4s cubic-bezier(0.215, 0.61, 0.355, 1);
    z-index: -1;
}

/* Hover States */
.btn-nav-phone:hover {
    color: #000000 !important;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(183, 205, 0, 0.3) !important;
}

/* Trigger the Swipe */
.btn-nav-phone:hover::before {
    width: 100%;
}

/* Ensure Icon stays aligned */
.btn-nav-phone i {
    font-size: 0.9rem;
    position: relative;
    z-index: 2;
}

/* Grid System Styling */
.text-green { color: #b7cd00 !important; }
.border-green { border-color: #b7cd00 !important; }

.service-box {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 1px solid #eee;
}

.service-box:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.1) !important;
}

.header-line {
    width: 60px;
    height: 4px;
    background: #b7cd00;
    margin: 15px auto;
}

/* List Icon Styling */
.fa-check-circle {
    font-size: 1.2rem;
}

/* Path Energy Style Cards */
.sector-card {
  
   
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    height: 100%;
    border: 1px solid #eee;
}

.sector-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(183, 205, 0, 0.15);
}

.sector-img {
    height: 180px;
    background-size: cover;
    background-position: center;
}

.sector-body {
    padding: 25px;
}

/* Step Process Styling */
.step-item {
    position: relative;
    padding-top: 20px;
}

.step-number {
    font-size: 3rem;
    font-weight: 800;
    color: rgba(183, 205, 0, 0.15); /* Light green overlay */
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1;
}

.step-item h4 {
    position: relative;
    z-index: 2;
    margin-top: 20px;
    color: #333;
}

.text-green { color: #b7cd00; }

.funding-card {
    background: #1a1a1a;
    border: 1px solid #333;
  
    height: 100%;
    transition: all 0.3s ease;
    overflow: hidden;
}

.funding-card:hover {
    border-color: #b7cd00;
    background: #222;
}

/* Chart Styles */
.chart-container {
    height: 120px;
    background: #111;
    display: flex;
    align-items: flex-end;
    padding: 20px;
}

.bar-grid {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    height: 100%;
    width: 100%;
}

.bar {
    flex: 1;
    border-radius: 2px 2px 0 0;
    transform: scaleY(0.1);
    transform-origin: bottom;
    transition: transform 0.5s ease;
    transition-delay: var(--delay);
}

.funding-card:hover .bar {
    transform: scaleY(1);
}

.gray-bar { background-color: #555; }
.teal-bar { background-color: #b7cd00; } /* Matches your green */

.text-green { color: #b7cd00; }

/* 1. The Brand Green Filter (#b7cd00) */
.action-icon {
    /* This complex filter approximate #b7cd00 from a black source icon */
    filter: brightness(0) invert(1);
    transition: filter 0.3s ease, transform 0.3s ease;
}

/* 2. The White Filter on Hover */
.action-card:hover .action-icon {
    /* This turns the icon pure white */
    filter: brightness(0) invert(1);
    transform: translateY(-5px); /* Optional: slight lift effect */
}

/* Base styling for the cards to ensure smooth transitions */
.action-card {
    min-height: 250px;
    transition: background-color 0.3s ease;
}

/* --- FAQ Accordion Custom Styling --- */

/* Remove the default blue glow/outline */
.accordion-button:focus {
    box-shadow: none;
    border-color: rgba(0,0,0,.125);
}

/* Style for the active (open) question */
.accordion-button:not(.collapsed) {
    background-color: #b7cd00 !important; /* Brand Green */
    color: #000000 !important; /* Black text for readability on green */
}

/* Style for the little arrow icon when open */
.accordion-button:not(.collapsed)::after {
    filter: brightness(0); /* Makes the arrow black when background is green */
}

/* General Accordion Item Hover */
.accordion-button:hover {
    background-color: #f8f9fa;
}

/* Ensure images or links inside FAQ answers match brand */
.accordion-body a {
    color: #b7cd00;
    font-weight: bold;
    text-decoration: none;
}

.accordion-body a:hover {
    text-decoration: underline;
}

/* Project Card Styling */
.project-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-radius: 0; /* Keep it sharp as per your preference */
}

/* Image Zoom Effect */
.project-thumb {
    transition: transform 0.5s ease;
    object-fit: cover;
    height: 100px; /* Forces consistent height */
    width: 100%;
}

.project-card:hover .project-thumb {
    transform: scale(1.1);
}

.project-card:hover {
    transform: translateX(5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1) !important;
}

/* News List Hover */
.news-list-item {
    transition: all 0.3s ease;
}

.news-list-item:hover {
    border-left-color: #b7cd00 !important;
    background-color: #fafafa !important;
}

/* Arrow Animation on Hover */
.project-card span i {
    transition: transform 0.3s ease;
}

.project-card:hover span i {
    transform: translateX(5px);
}

/* Zoom effect for the Areas image */
.hover-zoom {
    transition: transform 0.8s ease;
}

.hover-zoom:hover {
    transform: scale(1.05);
}

/* Ensure the image fills the height on desktop */
@media (min-width: 992px) {
    .object-fit-cover {
        object-fit: cover;
        min-height: 400px;
    }
}

/* Custom list item hover */
.list-unstyled li {
    transition: transform 0.2s ease;
}

.list-unstyled li:hover {
    transform: translateX(5px);
}

@media (max-width: 1199.98px) {
    /* 1. Make the menu scrollable if too long */
    .navbar-collapse {
        max-height: 80vh; /* Limits height to 80% of screen */
        overflow-y: auto; /* Adds scrollbar only if needed */
        -webkit-overflow-scrolling: touch; /* Smooth scrolling for iPhone */
        padding-bottom: 30px; /* Space for the bottom phone button */
    }

    /* 2. Fix the Megamenu for mobile (stops it being full-width/fixed) */
    .dropdown-full-width .megamenu {
        position: static !important;
        width: 100% !important;
        box-shadow: none !important;
        padding: 0 !important;
    }

    /* 3. Make sure columns stack inside the mobile dropdown */
    .megamenu .row {
        display: block;
        padding: 0 15px !important;
    }

    .megamenu .col-lg-3, 
    .megamenu .col-lg-4 {
        width: 100% !important;
        padding: 15px 0 !important;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }

    /* 4. Ensure the green phone button is always visible at the bottom of the stack */
    .btn-nav-phone {
        margin-top: 15px;
        width: 100%;
        justify-content: center;
    }
}

/* --- Animated Hamburger Settings --- */

/* Remove default Bootstrap border and glow */
.navbar-toggler {
    border: none !important;
    box-shadow: none !important;
    padding: 10px 5px;
}

.hamburger-icon {
    width: 30px;
    height: 20px;
    position: relative;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* Style for the three bars */
.hamburger-icon span {
    display: block;
    width: 100%;
    height: 3px;
    background-color: #b7cd00; /* Your brand green */
    border-radius: 3px;
    transition: all 0.3s cubic-bezier(0.645, 0.045, 0.355, 1);
}

/* --- The Animation States --- */

/* Top Bar: Rotate 45deg down */
.navbar-toggler:not(.collapsed) .hamburger-icon span:nth-child(1) {
    transform: translateY(8.5px) rotate(45deg);
    background-color: #ffffff; /* Turns white when open for contrast */
}

/* Middle Bar: Fade Out */
.navbar-toggler:not(.collapsed) .hamburger-icon span:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

/* Bottom Bar: Rotate 45deg up */
.navbar-toggler:not(.collapsed) .hamburger-icon span:nth-child(3) {
    transform: translateY(-8.5px) rotate(-45deg);
    background-color: #ffffff;
}

@media (max-width: 1199.98px) {
    .navbar-collapse.show {
        max-height: 85vh; /* Prevents menu going off-screen */
        overflow-y: auto; 
        background-color: #1a1a1a; /* Dark background so text is readable */
        padding: 20px;
    }
}

/* --- Ultra-Smooth Crossfade Hero --- */
.hero-slider {
    position: relative;
    height: 80vh;
    min-height: 500px;
    overflow: hidden;
    background-color: #000; 
}

.hero-bg {
    position: absolute; /* Stack them all on top of each other */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    
    /* Hide them by default */
    opacity: 0; 
    z-index: 1;
    
    /* Increase duration to 2s for a "soft" feel */
    transition: opacity 2s ease-in-out; 
    
    /* Prevent flicker */
    backface-visibility: hidden;
    transform: translateZ(0);
}

/* The image being shown */
.hero-bg.active {
    opacity: 1;
    z-index: 3; /* Highest priority */
}

/* The image that just finished being shown (to prevent the jump) */
.hero-bg.last-active {
    opacity: 0;
    z-index: 2; /* Sits behind the new one while fading out */
}

.hero-slider .container {
    position: relative;
    z-index: 10; /* Keeps text above everything */
}