/* ===================================================================
   isomass-global.css
   Merged site-wide styles (loaded on every page):
   base + nav + top-bar + footer + mobile-nav + logos
   Universal reset kept once (from base).
=================================================================== */

/* ---------- base ---------- */
/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* ---------- nav ---------- */
body {
 font-family: 'Mona Sans', sans-serif;
 line-height: 1.6;
 color: #333;
}

.container {
 max-width: 1200px;
 margin: 0 auto;
 padding: 0 20px;
}

/* ========================================
NAVIGATION BAR BASE STYLES
======================================== */

/* Nav scrolls away with the page on desktop and tablet; it sticks on phones (see 768px rule below) */
.navbar {
 background-color: white;
 box-shadow: 0 2px 10px rgba(0,0,0,0.1);
 position: relative;
 z-index: 1000;
}

@media (max-width: 768px) {
 .navbar {
  position: sticky;
  top: 0;
 }
}

.nav-content {
 display: flex;
 justify-content: space-between;
 align-items: center;
 padding: 15px 0;
 min-height: 80px;
}

.logo {
 display: flex;
 align-items: center;
}

.logo img {
 height: 65px;
 width: auto;
}

/* ██████████████████████████████████████████████████████████
DESKTOP & TABLET NAVIGATION STYLES (769px and above)
██████████████████████████████████████████████████████████ */

.desktop-nav {
 display: flex;
 align-items: center;
 gap: 35px;
 justify-content: flex-end;
 flex: 1;
 margin-left: 80px;
}

.nav-item {
 position: relative;
}

.nav-link {
 text-decoration: none;
 color: #333;
 font-weight: 600;
 font-size: 16px;
 padding: 10px 0;
 display: flex;
 align-items: center;
 gap: 5px;
 transition: color 0.3s ease;
}

.nav-link:hover {
 color: #d21e2b;
}

.nav-link.contact-btn {
 background-color: #d21e2b;
 color: white;
 padding: 12px 25px;
 border-radius: 5px;
 transition: background-color 0.3s ease;
}

.nav-link.contact-btn:hover {
 background-color: #b01a24;
 color: white;
}

.search-btn {
 background: none;
 border: 2px solid #d21e2b;
 color: #d21e2b;
 padding: 10px;
 border-radius: 5px;
 cursor: pointer;
 transition: all 0.3s ease;
}

.search-btn:hover,
.search-btn.active {
 background-color: #d21e2b;
 color: white;
}

/* Nav search panel - drops down under the navbar from the magnifying glass */
.nav-search-panel {
 position: absolute;
 top: 100%;
 left: 0;
 right: 0;
 z-index: 999;
 background-color: #1a1a1a;
 border-top: 3px solid #d21e2b;
 padding: 25px 0;
 box-shadow: 0 12px 30px rgba(0, 0, 0, 0.25);
}

.nav-search-panel[hidden] {
 display: none;
}

.nav-search-form {
 display: flex;
 align-items: center;
 gap: 10px;
 max-width: 820px;
 margin: 0 auto;
 background-color: #ffffff;
 border-radius: 10px;
 padding: 6px;
}

.nav-search-form:focus-within {
 box-shadow: 0 0 0 3px rgba(210, 30, 43, 0.6);
}

.nav-search-form input {
 flex: 1;
 min-width: 0;
 border: none;
 background: transparent;
 padding: 12px 14px;
 font-family: 'Mona Sans', sans-serif;
 font-size: 1rem;
 color: #222;
}

.nav-search-form input:focus {
 outline: none;
}

.nav-search-form input::-webkit-search-cancel-button,
.mobile-overlay-search input::-webkit-search-cancel-button {
 -webkit-appearance: none;
}

.nav-search-submit {
 display: inline-flex;
 align-items: center;
 gap: 8px;
 background-color: #d21e2b;
 color: #ffffff;
 border: none;
 border-radius: 7px;
 padding: 12px 22px;
 font-family: 'Mona Sans', sans-serif;
 font-size: 0.95rem;
 font-weight: 700;
 cursor: pointer;
 transition: background-color 0.3s ease;
}

.nav-search-submit:hover {
 background-color: #b01a24;
}

.nav-search-close {
 background: none;
 border: none;
 color: #d21e2b;
 font-size: 1.2rem;
 padding: 10px 12px;
 cursor: pointer;
}

.nav-search-close:hover {
 color: #9a1620;
}

.nav-search-suggestions {
 display: flex;
 flex-wrap: wrap;
 justify-content: center;
 align-items: center;
 gap: 8px 10px;
 max-width: 820px;
 margin: 15px auto 0;
 font-size: 0.88rem;
}

.nav-search-suggestions span {
 color: rgba(255, 255, 255, 0.7);
 font-weight: 600;
}

.nav-search-suggestions a {
 color: #ffffff;
 background-color: rgba(255, 255, 255, 0.08);
 border: 1px solid rgba(255, 255, 255, 0.15);
 border-radius: 50px;
 padding: 5px 12px;
 text-decoration: none;
 transition: all 0.3s ease;
}

.nav-search-suggestions a:hover {
 background-color: #d21e2b;
 border-color: #d21e2b;
}

@media (max-width: 768px) {
 .nav-search-panel {
  display: none;
 }
}

/* Screen reader only text - used by search labels */
.isomass-sr-only {
 position: absolute;
 width: 1px;
 height: 1px;
 padding: 0;
 margin: -1px;
 overflow: hidden;
 clip: rect(0, 0, 0, 0);
 white-space: nowrap;
 border: 0;
}

/* Dropdown Menu */

.dropdown-menu {
 position: absolute;
 top: 100%;
 left: 0;
 background-color: white;
 box-shadow: 0 5px 20px rgba(0,0,0,0.1);
 border-radius: 5px;
 padding: 10px 0;
 min-width: 180px;
 opacity: 0;
 visibility: hidden;
 transform: translateY(-10px);
 transition: all 0.3s ease;
 transition-delay: 0.5s;
}

.dropdown:hover .dropdown-menu,
.dropdown:focus-within .dropdown-menu {
 opacity: 1;
 visibility: visible;
 transform: translateY(0);
 transition-delay: 0s;
}

.dropdown-item {
 display: block;
 padding: 10px 20px;
 color: #333;
 text-decoration: none;
 transition: background-color 0.3s ease;
}

.dropdown-item:hover {
 background-color: #f8f9fa;
 color: #d21e2b;
}

/* Mega Menu */
/* Positioned against the nav bar (not the Products link) and aligned to its right edge,
   so it can never run off the screen and cause a sideways scroll */
.nav-content {
 position: relative;
}

.nav-item.mega-dropdown {
 position: static;
}

.mega-menu {
 position: absolute;
 top: 100%;
 left: auto;
 right: 0;
 max-width: 100%;
 background-color: white;
 box-shadow: 0 5px 30px rgba(0,0,0,0.15);
 border-radius: 8px;
 padding: 30px;
 width: 900px;
 opacity: 0;
 visibility: hidden;
 transform: translateY(-10px);
 transition: all 0.3s ease;
 transition-delay: 0.5s;
}

.mega-dropdown:hover .mega-menu,
.mega-dropdown:focus-within .mega-menu {
 opacity: 1;
 visibility: visible;
 transform: translateY(0);
 transition-delay: 0s;
}

/* Moving between About and Products: the one you've left fades out straight away
   (no 0.5s linger) and sits underneath the one you're opening, so they never overlap.
   The 0.5s linger still applies when the pointer leaves the nav altogether. */
.nav-menu:hover .nav-item:not(:hover) > .dropdown-menu,
.nav-menu:hover .nav-item:not(:hover) > .mega-menu {
 opacity: 0;
 visibility: hidden;
 transform: translateY(-10px);
 transition-delay: 0s;
 z-index: 1;
}

.nav-item:hover > .dropdown-menu,
.nav-item:hover > .mega-menu {
 z-index: 2;
}

.mega-menu-content {
 display: grid;
 grid-template-columns: repeat(3, 1fr);
 gap: 25px;
}

.mega-column a {
 text-decoration: none;
}

.mega-column h4 {
 color: #d21e2b;
 font-size: 16px;
 margin-bottom: 6px;
 font-weight: 700;
 line-height: 1.3;
}

.mega-column p {
 color: #666;
 font-size: 13px;
 line-height: 1.4;
}

/* Tablet Adjustments */

@media (max-width: 1024px) {
 .desktop-nav {
     gap: 28px;
     margin-left: 60px;
 }
 
 .mega-menu {
     width: 800px;
 }
 
 .mega-menu-content {
     grid-template-columns: repeat(2, 1fr);
     gap: 20px;
 }
 
 .mega-column h4 {
     font-size: 15px;
 }
 
 .mega-column p {
     font-size: 12px;
 }
}

/* ---------- top-bar ---------- */
/* ========================================
  TOP BAR STYLES
======================================== */

.top-bar {
   background-color: #d21e2b;
   color: white;
   padding: 10px 0;
   font-size: 14px;
}

.top-bar-content {
   display: flex;
   justify-content: space-between;
   align-items: center;
}

.cta-text {
   font-weight: 600;
}

.contact-info {
   display: flex;
   gap: 30px;
}

.contact-item {
   color: white;
   text-decoration: none;
   display: flex;
   align-items: center;
   gap: 8px;
   transition: opacity 0.3s ease;
}

.contact-item:hover {
   opacity: 0.8;
}

.contact-item i {
   font-size: 12px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
   .top-bar {
       display: none;
   }
}

/* ---------- footer ---------- */
/* ========================================
  FOOTER STYLES
======================================== */

.footer {
   background-color: #111;
   color: white;
   padding: 60px 0 20px 0;
}

.footer-content {
   display: grid;
   grid-template-columns: 2fr 1fr 1fr 1fr;
   gap: 40px;
   margin-bottom: 40px;
}

.footer-column h4 {
   color: white;
   font-size: 18px;
   font-weight: 700;
   margin-bottom: 8px;
   padding-bottom: 8px;
   border-bottom: 2px solid #d21e2b;
   display: inline-block;
}

/* About Section */
.footer-about p {
   color: #ccc;
   line-height: 1.6;
   margin-bottom: 20px;
   font-size: 15px;
}

.footer-social {
   display: flex;
   gap: 15px;
}

.social-link {
   display: flex;
   align-items: center;
   justify-content: center;
   width: 40px;
   height: 40px;
   background-color: #d21e2b;
   color: white;
   border-radius: 50%;
   text-decoration: none;
   transition: all 0.3s ease;
}

.social-link:hover {
   background-color: #b01a24;
   transform: translateY(-2px);
}

.social-link i {
   font-size: 18px;
}

/* Footer Links */
.footer-links {
   list-style: none;
   padding: 0;
   margin: 0;
}

.footer-links li {
   margin-bottom: 8px;
}

.footer-links a {
   color: #ccc;
   text-decoration: none;
   font-size: 14px;
   transition: color 0.3s ease;
}

.footer-links a:hover {
   color: #d21e2b;
}

/* Footer Bottom */
.footer-bottom {
   border-top: 1px solid #333;
   padding-top: 20px;
   text-align: center;
}

.footer-bottom p {
   color: #999;
   font-size: 14px;
   margin: 0;
}

/* ========================================
  FOOTER RESPONSIVE DESIGN
======================================== */

/* Tablet Styles */
@media (max-width: 1024px) {
   .footer-content {
       grid-template-columns: 1fr 1fr;
       gap: 30px;
   }
   
   .footer-about {
       grid-column: 1 / -1;
       margin-bottom: 20px;
   }
}

/* Mobile Styles */
@media (max-width: 768px) {
   .footer {
       padding: 40px 0 20px 0;
   }
   
   .footer-content {
       grid-template-columns: 1fr;
       gap: 30px;
   }
   
   .footer-about {
       grid-column: 1;
       margin-bottom: 0;
   }
   
   .footer-column h4 {
       font-size: 16px;
   }
}

/* Small Mobile Styles */
@media (max-width: 480px) {
   .footer {
       padding: 30px 0 15px 0;
   }
   
   .footer-content {
       gap: 25px;
       margin-bottom: 30px;
   }
   
   .footer-about p {
       font-size: 14px;
   }
   
   .footer-links a {
       font-size: 13px;
   }
   
   .footer-bottom p {
       font-size: 13px;
   }
}

/* Past Projects Section */
.footer-projects {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.project-item {
    display: flex;
    gap: 12px;
    align-items: flex-start;
    text-decoration: none;
    color: inherit;
    transition: opacity 0.3s ease;
}

.project-item:hover {
    opacity: 0.8;
}

.project-item img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 4px;
}

.project-content {
    flex: 1;
}

.project-date {
    color: #d21e2b;
    font-size: 12px;
    font-weight: 500;
    display: block;
    margin-bottom: 4px;
}

.project-item h5 {
    color: #ccc;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.3;
    margin: 0;
}

/* Mobile adjustments for projects */
@media (max-width: 768px) {
    .project-item img {
        width: 50px;
        height: 50px;
    }
    
    .project-item h5 {
        font-size: 12px;
    }
    
    .project-date {
        font-size: 11px;
    }
}

/* ---------- mobile-nav ---------- */
/* ████████████████████████████████████████████████████████████████
   MOBILE ONLY NAVIGATION STYLES (768px and below)
   ████████████████████████████████████████████████████████████████ */

/* Hamburger button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    padding: 8px;
    margin-right: -8px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: #1a1a1a;
    transition: all 0.3s ease;
    border-radius: 2px;
}

/* Red middle bar */
.mobile-menu-toggle span:nth-child(2) {
    background-color: #d21e2b;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Overlay - phones only */
.mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ffffff;
    z-index: 9999;
    transform: translateX(100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    font-family: 'Mona Sans', sans-serif;
}

.mobile-overlay.active {
    transform: translateX(0);
}

@media (min-width: 769px) {
    .mobile-overlay {
        display: none;
    }
}

.mobile-overlay-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 18px 20px;
    border-bottom: 1px solid #eee;
    position: relative;
}

.mobile-overlay-logo {
    display: flex;
    justify-content: center;
}

.mobile-overlay-logo a {
    display: flex;
    text-decoration: none;
}

.mobile-overlay-logo img {
    height: 50px;
    width: auto;
}

/* Close button - red X */
.mobile-close-btn {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    width: 44px;
    height: 44px;
    background: none;
    color: #d21e2b;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 38px;
    font-weight: 300;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.mobile-close-btn::before {
    content: '\00D7';
    margin-top: -3px;
}

.mobile-close-btn:hover,
.mobile-close-btn:focus-visible {
    color: #1a1a1a;
}

.mobile-overlay-content {
    padding: 10px 20px 35px;
}

.mobile-overlay-nav {
    display: flex;
    flex-direction: column;
}

/* Top-level items (links and submenu buttons share one look) */
.mobile-overlay-item {
    display: block;
    width: 100%;
    padding: 18px 0;
    background: none;
    border: none;
    border-bottom: 1px solid #eee;
    color: #1a1a1a;
    text-decoration: none;
    text-align: left;
    font-family: inherit;
    font-weight: 700;
    font-size: 1.15rem;
    line-height: 1.3;
    cursor: pointer;
    transition: color 0.3s ease;
}

.mobile-overlay-item.active {
    color: #d21e2b;
}

/* Hover colour only on devices with a mouse, so taps on phones don't leave items red */
@media (hover: hover) {
    .mobile-overlay-item:hover {
        color: #d21e2b;
    }
}

/* Red +/- on items with a submenu */
.mobile-overlay-item.has-submenu {
    position: relative;
    padding-right: 40px;
}

.mobile-overlay-item.has-submenu::after {
    content: '+';
    position: absolute;
    right: 2px;
    top: 50%;
    transform: translateY(-50%);
    color: #d21e2b;
    font-size: 28px;
    font-weight: 400;
    line-height: 1;
}

.mobile-overlay-item.has-submenu.active::after {
    content: '\2212';
}

/* Submenus - black panel */
.mobile-overlay-submenu {
    max-height: 0;
    overflow: hidden;
    background-color: #1a1a1a;
    border-radius: 12px;
    padding: 0 20px;
}

.mobile-overlay-submenu.active {
    max-height: none;
    padding: 8px 20px;
    margin: 10px 0 12px;
}

.mobile-overlay-submenu-item {
    display: block;
    padding: 13px 0;
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
    font-size: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: color 0.3s ease;
}

.mobile-overlay-submenu-item:hover {
    color: #ff4757;
}

.mobile-overlay-submenu-item:last-child {
    border-bottom: none;
}

/* Contact Us - full-width red button */
.mobile-overlay-cta {
    display: block;
    margin-top: 25px;
    padding: 16px 20px;
    background-color: #d21e2b;
    color: #ffffff;
    text-align: center;
    text-decoration: none;
    font-weight: 700;
    font-size: 1.05rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(210, 30, 43, 0.3);
    transition: background-color 0.3s ease;
}

.mobile-overlay-cta:hover {
    background-color: #b01a24;
    color: #ffffff;
}

/* Phone and email */
.mobile-overlay-contact {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
}

.mobile-overlay-contact-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 10px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.92rem;
    white-space: nowrap;
    transition: all 0.3s ease;
}

.mobile-overlay-contact-phone {
    background-color: #1a1a1a;
    color: #ffffff;
}

.mobile-overlay-contact-email {
    background-color: #f3f3f3;
    color: #1a1a1a;
}

.mobile-overlay-contact-btn i {
    color: #d21e2b;
}

/* Search */
.mobile-overlay-search {
    margin-top: 25px;
    display: flex;
    gap: 10px;
}

.mobile-overlay-search input {
    flex: 1;
    min-width: 0;
    padding: 14px 15px;
    border: 2px solid #eee;
    border-radius: 8px;
    font-family: 'Mona Sans', sans-serif;
    font-size: 16px;
}

.mobile-overlay-search input:focus {
    outline: none;
    border-color: #d21e2b;
}

.mobile-overlay-search button {
    background-color: #d21e2b;
    color: white;
    border: none;
    padding: 14px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 16px;
}

/* Review pill - smaller in the menu */
.mobile-overlay-reviews {
    margin-top: 25px;
    display: flex;
    justify-content: center;
}

.mobile-overlay .isomass-review-pill {
    gap: 8px;
    padding: 6px 14px 6px 6px;
    border: 1px solid #eee;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.08);
}

.mobile-overlay .isomass-review-pill-icon {
    width: 24px;
    height: 24px;
}

.mobile-overlay .isomass-review-pill-rating {
    font-size: 0.9rem;
}

.mobile-overlay .isomass-review-pill-stars {
    font-size: 0.78rem;
}

.mobile-overlay .isomass-review-pill-count {
    font-size: 0.78rem;
}

@media (max-width: 768px) {
    .desktop-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
    }
    
    /* Hide navbar when overlay is active */
    body.mobile-overlay-active .navbar {
        opacity: 0;
        pointer-events: none;
    }
    
    body.mobile-overlay-active .top-bar {
        opacity: 0;
        pointer-events: none;
    }
}

@media (max-width: 360px) {
    .mobile-overlay-contact {
        grid-template-columns: 1fr;
    }
}

/* ---------- logos ---------- */
/* Footer Logo Sections */
.isomass-footer-logos-white,
.isomass-footer-logos-grey {
    background-color: #ffffff;
    border-top: 1px solid #e9ecef;
    border-bottom: 1px solid #e9ecef;
}

.isomass-footer-logos-grey {
    background-color: #f3f3f3;
}

/* Desktop */
.isomass-footer-logos-white {
    padding: 45px 20px;
}

.isomass-footer-logos-white .logos-container {
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

.isomass-footer-logos-white img {
    max-width: 90%;
    height: auto;
}

/* Tablet */
@media (max-width: 768px) {
    .isomass-footer-logos-white {
        padding: 35px 20px;
    }
}

/* Mobile */
@media (max-width: 480px) {
    .isomass-footer-logos-white {
        padding: 30px 15px;
    }
}

/* ========================================
   REVIEW STARS - part-filled Font Awesome star
   Fill comes from the rating in includes/reviews-data.php (--fill set inline)
======================================== */
.isomass-star-partial::before {
    background: linear-gradient(90deg, #ffa500 var(--fill, 0%), #ddd var(--fill, 0%));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ========================================
   REVIEW PILL - site-wide (includes/review-pill.php)
======================================== */
.isomass-review-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 18px 8px 8px;
    background-color: #ffffff;
    border-radius: 50px;
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
    text-decoration: none;
    font-family: 'Mona Sans', sans-serif;
    line-height: 1;
    transition: all 0.3s ease;
}

.isomass-review-pill:hover,
.isomass-review-pill:focus {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
    text-decoration: none;
}

.isomass-review-pill-icon {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: contain;
    flex-shrink: 0;
}

.isomass-review-pill-rating {
    font-size: 1rem;
    font-weight: 700;
    color: #222;
}

.isomass-review-pill-stars {
    display: inline-flex;
    gap: 2px;
    font-size: 0.9rem;
    color: #ffa500;
}

.isomass-review-pill-count {
    font-size: 0.85rem;
    font-weight: 500;
    color: #666;
}

@media (max-width: 480px) {
    .isomass-review-pill {
        gap: 8px;
        padding: 6px 14px 6px 6px;
    }
    
    .isomass-review-pill-icon {
        width: 24px;
        height: 24px;
    }
    
    .isomass-review-pill-stars {
        font-size: 0.8rem;
    }
    
    .isomass-review-pill-count {
        font-size: 0.8rem;
    }
}
