/*!
 * Bootstrap Overrides for Rehab Guide
 * Fixes container widths, hero images, and layout constraints
 */

/* ===========================================================================
 * HERO BACKGROUND IMAGES - Homepage
 * =========================================================================== */

/* Mobile background (default) */
.page-template-home .slider-wrapper {
    background-image: url(/wp-content/uploads/2020/10/home-banner-mobile.jpg) !important;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Quote section background - mobile */
.quote-bg {
    background-image: url(/wp-content/uploads/2020/10/slide1-mobile.jpg) !important;
    background-size: cover !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* Desktop backgrounds (415px and up) */
@media (min-width: 415px) {
    .page-template-home .slider-wrapper {
        background-image: url(/wp-content/uploads/2020/10/home-banner.jpg) !important;
    }
    
    .quote-bg {
        background-image: url(/wp-content/uploads/2020/10/quote-desktop.jpg) !important;
    }
    
    .side-bar, 
    .mobile-element-ll {
        content-visibility: unset !important;
    }
}

/* ===========================================================================
 * CONTAINER WIDTH FIXES - Force 1200px max everywhere
 * =========================================================================== */

.container,
.container-fluid {
    max-width: 1200px !important;
    width: 100% !important;
    margin-left: auto !important;
    margin-right: auto !important;
    padding-left: 15px !important;
    padding-right: 15px !important;
}

/* ===========================================================================
 * HOMEPAGE SLIDER/HERO SECTION - Spacing Fixes
 * =========================================================================== */

/* Remove excessive margins/padding from slider area */
.slider-area {
    margin: 0 !important;
    padding: 0 !important;
}

.slider-wrapper {
    position: relative;
    min-height: 420px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    padding: 60px 0 !important;
}

.slider-wrapper.bg-opacity::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1;
}

.slider-wrapper .container {
    position: relative;
    z-index: 10;
    padding: 0 15px !important;
}

.slider-text {
    position: relative;
    z-index: 10;
    text-align: center;
    color: #ffffff;
    margin: 0 !important;
}

.slider-text-h1 {
    font-size: 48px !important;
    line-height: 1.25 !important;
    margin-bottom: 30px !important;
    color: #ffffff !important;
    font-weight: 400 !important;
    text-shadow: 0 3px 10px rgba(0, 0, 0, 0.5);
}

/* CTA Buttons spacing */
.slider-cta-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 25px !important;
    margin-bottom: 0 !important;
}

.slider-cta-buttons .btn-primary {
    padding: 18px 48px !important;
    font-size: 19px !important;
    background: #99E064 !important;
    color: #fff !important;
    border: 3px solid #99E064 !important;
    border-radius: 50px !important;
    text-transform: uppercase !important;
    font-weight: 700 !important;
    margin: 0 !important;
}

.slider-cta-buttons .btn-primary::before,
.slider-cta-buttons .btn-primary::after {
    display: none !important;
}

.slider-cta-buttons .btn-primary:hover {
    background: #7ac142 !important;
    border-color: #7ac142 !important;
    transform: translateY(-4px) !important;
    color: #fff !important;
}

/* Fix spacing between hero and next section */
.slider-area + * {
    margin-top: 0 !important;
    padding-top: 50px !important;
}

/* ===========================================================================
 * BREADCRUMB/HERO AREA - Category & Content Pages
 * =========================================================================== */

.breadcrumb-area {
    position: relative;
    width: 100%;
    min-height: 280px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 0 40px;
    overflow: hidden;
}

/* Background wrapper */
.breadcrumb-bg-wrapper {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

/* Picture element fills the wrapper */
.breadcrumb-picture {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: block;
}

/* Image covers the area */
.breadcrumb-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
}

/* Dark overlay - removed (set to 0) */
.breadcrumb-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0);
    z-index: 1;
}

/* Container above background */
.breadcrumb-area .container {
    position: relative;
    z-index: 10;
    max-width: 1200px !important;
}

/* Title styling */
.breadcrumb-text {
    color: #ffffff !important;
    text-align: center;
    margin-bottom: 15px;
    font-size: 42px;
    font-weight: 600;
    text-shadow: 0 3px 10px rgba(0, 0, 0, 0.5);
    line-height: 1.3;
}

/* Breadcrumb menu */
.breadcrumb-menu {
    margin-bottom: 30px;
}

.breadcrumb-menu-sub {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    background: transparent !important;
}

.breadcrumb-menu-sub li {
    color: #ffffff;
    font-size: 15px;
    display: flex;
    align-items: center;
}

.breadcrumb-menu-sub li:not(:last-child)::after {
    content: "›";
    margin-left: 10px;
    color: #99E064;
    font-size: 18px;
}

.breadcrumb-menu-sub a {
    color: #99E064 !important;
    text-decoration: none;
    transition: color 0.3s ease;
}

.breadcrumb-menu-sub a:hover {
    color: #7ac142 !important;
    text-decoration: underline;
}

/* Inquiry section */
.inquery {
    text-align: center;
    margin-top: 20px;
}

.breadcrumb-area-inquery-h2 {
    color: #ffffff;
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 12px;
    text-shadow: 0 2px 6px rgba(0, 0, 0, 0.5);
}

.inquery a,
.inquery .call_us {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    background: #99E064;
    color: #ffffff !important;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(153, 224, 100, 0.3);
}

.inquery a:hover,
.inquery .call_us:hover {
    background: #7ac142;
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(122, 193, 66, 0.4);
}

.inquery .icon-phone {
    font-size: 18px;
}

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

/* Homepage Hero */
@media (max-width: 991px) {
    .slider-wrapper {
        min-height: 380px;
        padding: 50px 0 !important;
    }
    
    .slider-text-h1 {
        font-size: 38px !important;
    }
}

@media (max-width: 768px) {
    .slider-wrapper {
        min-height: 360px;
        padding: 40px 0 !important;
    }
    
    .slider-text-h1 {
        font-size: 32px !important;
        margin-bottom: 25px !important;
    }
    
    .slider-cta-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    /* Breadcrumb responsive */
    .breadcrumb-area {
        min-height: 220px;
        padding: 40px 0 30px;
    }
    
    .breadcrumb-text {
        font-size: 30px;
        margin-bottom: 20px;
    }
    
    .breadcrumb-area-inquery-h2 {
        font-size: 18px;
    }
}

@media (max-width: 575px) {
    .slider-wrapper {
        min-height: 340px;
        padding: 35px 0 !important;
    }
    
    .slider-text-h1 {
        font-size: 28px !important;
    }
    
    .slider-cta-buttons .btn-primary {
        padding: 15px 40px !important;
        font-size: 17px !important;
    }
    
    /* Breadcrumb responsive */
    .breadcrumb-area {
        min-height: 200px;
        padding: 35px 0 25px;
    }
    
    .breadcrumb-text {
        font-size: 26px;
    }
    
    .inquery a,
    .inquery .call_us {
        padding: 12px 24px;
        font-size: 15px;
    }
}

/* ===========================================================================
 * HOMEPAGE LAYOUT IMPROVEMENTS
 * =========================================================================== */

/* Section spacing standardization */
.page-template-home section,
.page-template-home .content-section {
    padding: 60px 0 !important;
    margin: 0 !important;
}

/* Alternate section backgrounds for visual separation */
.page-template-home section:nth-of-type(even) {
    background: #f8f9fa;
}

.page-template-home section:nth-of-type(odd) {
    background: #ffffff;
}

/* Green sections keep their color */
.page-template-home .green-section,
.page-template-home [style*="background"] {
    background: inherit !important;
}

/* County selector section - green background */
.page-template-home .green-section {
    padding: 40px 0 !important;
    background: #99E064 !important;
}

/* Typography improvements */
.page-template-home h2 {
    font-size: 36px !important;
    line-height: 1.3 !important;
    margin-bottom: 25px !important;
    color: #2c3e50 !important;
    text-align: center !important;
}

.page-template-home h3 {
    font-size: 24px !important;
    line-height: 1.4 !important;
    margin-bottom: 20px !important;
    color: #34495e !important;
}

/* Content width constraints for readability */
.page-template-home .row {
    max-width: 1200px;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* Text blocks - improve readability */
.page-template-home p,
.page-template-home li {
    font-size: 16px !important;
    line-height: 1.7 !important;
    margin-bottom: 15px !important;
    color: #555 !important;
}

/* Column spacing in multi-column layouts */
.page-template-home .col-md-6,
.page-template-home .col-lg-6 {
    margin-bottom: 30px;
}

/* Green boxes styling (like the two boxes below hero) */
.page-template-home .green-box {
    background: #99E064 !important;
    padding: 30px !important;
    border-radius: 8px;
    margin-bottom: 20px;
    height: 100%;
}

.page-template-home .green-box h3,
.page-template-home .green-box h2 {
    color: #ffffff !important;
    margin-bottom: 15px !important;
}

.page-template-home .green-box ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.page-template-home .green-box li {
    color: #ffffff !important;
    padding-left: 25px;
    position: relative;
    margin-bottom: 10px !important;
}

.page-template-home .green-box li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: #ffffff;
    font-weight: bold;
}

/* "Drug & Alcohol Rehabs London & UK" heading section */
.page-template-home .main-content-intro {
    text-align: center;
    max-width: 900px;
    margin: 0 auto 40px;
}

/* Image sections */
.page-template-home img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    margin-bottom: 20px;
}

/* CTA sections (call-to-action) */
.page-template-home .cta-section {
    background: #99E064 !important;
    padding: 50px 30px !important;
    text-align: center;
    border-radius: 12px;
    margin: 40px 0;
}

.page-template-home .cta-section h2,
.page-template-home .cta-section h3 {
    color: #ffffff !important;
}

.page-template-home .cta-section .btn {
    background: #ffffff !important;
    color: #99E064 !important;
    border: none !important;
    padding: 15px 40px !important;
    font-size: 18px !important;
    font-weight: 700 !important;
    border-radius: 50px !important;
    margin-top: 20px;
}

.page-template-home .cta-section .btn:hover {
    background: #f0f0f0 !important;
    transform: translateY(-3px);
}

/* Cards/Boxes with equal heights */
.page-template-home .card,
.page-template-home .service-box {
    height: 100%;
    padding: 25px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    margin-bottom: 30px;
    transition: all 0.3s ease;
}

.page-template-home .card:hover,
.page-template-home .service-box:hover {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transform: translateY(-5px);
}

/* Bottom image cards section */
.page-template-home .image-card {
    text-align: center;
    margin-bottom: 30px;
}

.page-template-home .image-card img {
    margin-bottom: 15px;
}

.page-template-home .image-card h3 {
    font-size: 20px !important;
    color: #99E064 !important;
}

/* Helpline section styling */
.page-template-home .helpline-section {
    background: linear-gradient(135deg, #99E064 0%, #7ac142 100%);
    padding: 50px 30px !important;
    text-align: center;
    color: #ffffff;
    border-radius: 12px;
    margin: 40px 0;
}

.page-template-home .helpline-section h2 {
    color: #ffffff !important;
    font-size: 32px !important;
}

.page-template-home .helpline-section h3 {
    color: #ffffff !important;
    font-size: 26px !important;
}

/* ===========================================================================
 * RESPONSIVE - Homepage Layout
 * =========================================================================== */

@media (max-width: 991px) {
    .page-template-home section {
        padding: 50px 0 !important;
    }
    
    .page-template-home h2 {
        font-size: 32px !important;
    }
    
    .page-template-home h3 {
        font-size: 22px !important;
    }
}

@media (max-width: 768px) {
    .page-template-home section {
        padding: 40px 0 !important;
    }
    
    .page-template-home h2 {
        font-size: 28px !important;
    }
    
    .page-template-home h3 {
        font-size: 20px !important;
    }
    
    .page-template-home .green-box {
        margin-bottom: 20px;
    }
    
    .page-template-home .col-md-6,
    .page-template-home .col-lg-6 {
        margin-bottom: 20px;
    }
}

@media (max-width: 575px) {
    .page-template-home section {
        padding: 30px 0 !important;
    }
    
    .page-template-home h2 {
        font-size: 24px !important;
    }
    
    .page-template-home p,
    .page-template-home li {
        font-size: 15px !important;
    }
}

/* ===========================================================================
 * ACCORDIONS - Homepage
 * =========================================================================== */

.accordion-frontpage {
    margin-bottom: 12px;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
}

.accordion-frontpage:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.12);
}

/* Accordion Title/Header */
.accordion-frontpage .su-spoiler-title {
    background-color: #424442 !important;
    color: #fefefe !important;
    font-size: 17px !important;
    font-weight: 600 !important;
    padding: 18px 50px 18px 20px !important;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    border: none !important;
    display: block !important;
    margin: 0 !important;
}

.accordion-frontpage .su-spoiler-title:hover {
    background-color: #99e164 !important;
    color: #333 !important;
}

/* Open state */
.accordion-frontpage.su-spoiler-open .su-spoiler-title {
    background-color: #99e164 !important;
    color: #333 !important;
}

/* Content area */
.accordion-frontpage .su-spoiler-content {
    background: #ffffff !important;
    padding: 25px 20px !important;
    border: 1px solid #e0e0e0;
    border-top: none;
    display: block !important;
    margin: 0 !important;
}

/* HIDE content when closed */
.accordion-frontpage.su-spoiler-closed .su-spoiler-content {
    display: none !important;
    height: 0 !important;
    padding: 0 !important;
    border: none !important;
    overflow: hidden !important;
}

.accordion-frontpage .su-spoiler-content p {
    font-size: 16px !important;
    line-height: 1.7 !important;
    color: #555 !important;
    margin-bottom: 15px !important;
}

.accordion-frontpage .su-spoiler-content p:last-child {
    margin-bottom: 0 !important;
}

/* Icons - Plus/Minus - Properly positioned on the right */
.accordion-frontpage .su-spoiler-icon {
    position: absolute !important;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0 !important;
    font-weight: bold;
    line-height: 1;
    width: 24px;
    height: 24px;
    display: flex !important;
    align-items: center;
    justify-content: center;
}

/* CLOSED accordion - show PLUS sign */
.accordion-frontpage.su-spoiler-closed .su-spoiler-icon:before {
    content: '+' !important;
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 24px !important;
    font-weight: bold !important;
    line-height: 1 !important;
    display: block !important;
}

/* OPEN accordion - show MINUS sign (using hyphen instead of special character) */
.accordion-frontpage.su-spoiler-open .su-spoiler-icon:before {
    content: '\2212' !important; /* Unicode minus sign */
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 24px !important;
    font-weight: bold !important;
    line-height: 1 !important;
    display: block !important;
}

/* Fallback: if Unicode doesn't work, use regular hyphen */
@supports not (content: '\2212') {
    .accordion-frontpage.su-spoiler-open .su-spoiler-icon:before {
        content: '-' !important;
    }
}

/* Links inside accordion content */
.accordion-frontpage .su-spoiler-content a {
    color: #99e164 !important;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.accordion-frontpage .su-spoiler-content a:hover {
    color: #7ac142 !important;
}

/* Lists inside accordion */
.accordion-frontpage .su-spoiler-content ul,
.accordion-frontpage .su-spoiler-content ol {
    margin-left: 20px;
    margin-bottom: 15px;
}

.accordion-frontpage .su-spoiler-content li {
    margin-bottom: 8px;
    font-size: 16px !important;
    line-height: 1.7 !important;
    color: #555 !important;
}

/* Headings inside accordion content */
.accordion-frontpage .su-spoiler-content h2,
.accordion-frontpage .su-spoiler-content h3 {
    color: #5972A8 !important;
    margin-bottom: 15px !important;
    font-weight: 600 !important;
}

/* Container for accordion group */
.accordion-group {
    margin: 40px 0;
}

/* ===========================================================================
 * RESPONSIVE - Accordions
 * =========================================================================== */

@media (max-width: 768px) {
    .accordion-frontpage .su-spoiler-title {
        font-size: 16px !important;
        padding: 15px 45px 15px 15px !important;
    }
    
    .accordion-frontpage .su-spoiler-content {
        padding: 20px 15px !important;
    }
    
    .accordion-frontpage .su-spoiler-content p,
    .accordion-frontpage .su-spoiler-content li {
        font-size: 15px !important;
    }
    
    .accordion-frontpage .su-spoiler-icon {
        right: 15px;
    }
    
    .accordion-frontpage.su-spoiler-closed .su-spoiler-icon:before,
    .accordion-frontpage.su-spoiler-open .su-spoiler-icon:before {
        font-size: 22px !important;
    }
}

@media (max-width: 575px) {
    .accordion-frontpage .su-spoiler-title {
        font-size: 15px !important;
        padding: 14px 40px 14px 12px !important;
    }
    
    .accordion-frontpage .su-spoiler-content {
        padding: 18px 12px !important;
    }
    
    .accordion-frontpage .su-spoiler-content p,
    .accordion-frontpage .su-spoiler-content li {
        font-size: 14px !important;
    }
    
    .accordion-frontpage.su-spoiler-closed .su-spoiler-icon:before,
    .accordion-frontpage.su-spoiler-open .su-spoiler-icon:before {
        font-size: 20px !important;
    }
}

/* ===========================================================================
 * FOOTER STYLING - Target actual footer classes
 * =========================================================================== */

/* Main footer area */
footer.element-ll {
    background: #2c3e50 !important;
    color: #ffffff !important;
    padding: 0 !important;
}

/* Footer top area (main content) */
.footer-top-area {
    background: #2c3e50 !important;
    padding: 60px 0 40px !important;
}

.footer-top-area-cl {
    background: transparent !important;
}

/* Footer headings */
.footer-title,
footer h4.footer-title {
    color: #ffffff !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    margin-bottom: 25px !important;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Footer wrapper content */
.footer-wrapper {
    margin-bottom: 30px;
}

/* Footer text/paragraphs */
.footer-text p,
.footer-wrapper p,
footer p {
    color: #ffffff !important;
    font-size: 15px !important;
    line-height: 1.8 !important;
    margin-bottom: 15px !important;
}

/* Footer links list */
.footer-link,
.footer-menu,
footer ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

.footer-link li,
.footer-menu li,
footer ul li {
    color: #ffffff !important;
    font-size: 15px !important;
    line-height: 1.8 !important;
    margin-bottom: 15px !important;
    padding-left: 0 !important;
}

/* Footer links */
.footer-link a,
.footer-menu a,
footer a {
    color: #99e164 !important;
    text-decoration: none !important;
    transition: all 0.3s ease;
    font-weight: 500;
}

.footer-link a:hover,
.footer-menu a:hover,
footer a:hover {
    color: #b5f080 !important;
    text-decoration: underline !important;
}

/* Footer icons (location, circle bullets) */
.footer-link i,
.footer-menu i {
    color: #99e164 !important;
    margin-right: 10px;
    font-size: 14px;
}

/* Social media icons */
.footer-top-icon {
    margin-top: 20px;
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.footer-top-icon a {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
    border-radius: 50%;
    transition: all 0.3s ease;
    font-size: 16px;
}

.footer-top-icon a:hover {
    background: #99e164 !important;
    color: #2c3e50 !important;
    transform: translateY(-3px);
    text-decoration: none !important;
}

/* Footer bottom (copyright area) */
.footer2-bottom-area,
.black1-bg {
    background: #1a252f !important;
    padding: 20px 0 !important;
    border-top: 1px solid rgba(255, 255, 255, 0.1) !important;
}

.copyright1 p {
    color: #ffffff !important;
    font-size: 14px !important;
    margin: 0 !important;
    opacity: 0.9;
}

/* Newsletter section above footer */
.consulting-company-area.element-ll {
    background: #34495e !important;
    padding: 50px 0 !important;
}

.newsletter-embed {
    background: transparent !important;
}

/* ===========================================================================
 * RESPONSIVE - Footer
 * =========================================================================== */

@media (max-width: 991px) {
    .footer-top-area {
        padding: 50px 0 30px !important;
    }
    
    .footer-title {
        font-size: 18px !important;
    }
}

@media (max-width: 768px) {
    .footer-top-area {
        padding: 40px 0 25px !important;
    }
    
    .footer-wrapper {
        text-align: center;
        margin-bottom: 40px;
    }
    
    .footer-top-icon {
        justify-content: center;
    }
    
    .footer-title {
        font-size: 18px !important;
    }
    
    .footer-text p,
    .footer-link li {
        font-size: 14px !important;
    }
}

@media (max-width: 575px) {
    .footer-top-area {
        padding: 35px 0 20px !important;
    }
    
    .footer-title {
        font-size: 16px !important;
        margin-bottom: 15px !important;
    }
    
    .footer-text p,
    .footer-link li {
        font-size: 14px !important;
    }
    
    .footer-top-icon a {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}
/* Hide map marker icons in footer */
.footer-link li i.fa-map-marker-alt,
.footer-link i.fas.fa-map-marker-alt {
    display: none !important;
}

/* Adjust footer link spacing without icons */
.footer-link li {
    padding-left: 0 !important;
}