/* ==========================================================================
   MASTER STYLESHEET: CLEANPRO UK (FINAL MASTER)
   Palette: Artisan Earth | Fonts: Aeonik & Satoshi
   ========================================================================== */

/* --- 1. CORE VARIABLES --- */
:root {
    --primary: #006D77;        /* Deep Teal */
    --secondary: #E29578;      /* Soft Terracotta */
    --accent: #F4A261;         /* Goldenrod */
    --bg-linen: #EDF6F9;       /* Off-White/Linen */
    --text-dark: #003033;      /* Contrast Teal */
    --text-muted: #537a7d;
    --white: #ffffff;
    
    --font-heading: 'Aeonik', sans-serif;
    --font-body: 'Satoshi', sans-serif;
    
    --shadow-soft: 0 10px 30px rgba(0, 109, 119, 0.05);
    --shadow-premium: 0 20px 40px rgba(0, 109, 119, 0.08);
    --transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    --radius: 16px;
}

/* --- 2. RESET & BASE --- */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    background-color: var(--bg-linen);
    color: var(--text-dark);
    font-family: var(--font-body);
    line-height: 1.6;
    overflow-x: hidden;
}

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

img { max-width: 100%; height: auto; display: block; }

h1, h2, h3 { 
    font-family: var(--font-heading); 
    font-weight: 700; 
    line-height: 1.1; 
    color: var(--primary);
}

.highlight { color: var(--secondary); }

.badge {
    background: rgba(0, 109, 119, 0.1);
    color: var(--primary);
    padding: 6px 15px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 700;
    display: inline-block;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- 3. BUTTONS --- */
.btn {
    display: inline-block;
    padding: 16px 32px;
    border-radius: 50px;
    font-weight: 700;
    text-decoration: none;
    transition: var(--transition);
    font-family: var(--font-heading);
    cursor: pointer;
    border: none;
    text-align: center;
}
.btn-primary { background: var(--accent); color: var(--white); box-shadow: 0 10px 20px rgba(244, 162, 97, 0.2); }
.btn-primary:hover { transform: translateY(-5px); box-shadow: 0 15px 30px rgba(244, 162, 97, 0.4); }
.btn-secondary { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn-cta { background: var(--primary); color: var(--white) !important; padding: 10px 24px; }
.btn-white { background: var(--white); color: var(--primary); }

/* --- 4. NAVIGATION & HEADER --- */
#main-header {
    background: rgba(237, 246, 249, 0.9);
    backdrop-filter: blur(10px);
    padding: 20px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(0, 109, 119, 0.05);
}

#main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.logo img { max-height: 55px; width: auto; object-fit: contain; }
.logo-text { font-size: 1.4rem; font-family: var(--font-heading); color: var(--primary); line-height: 1; letter-spacing: 0.5px; }
.logo-text strong { font-weight: 800; }
.logo-text span { color: var(--secondary); font-weight: 600; }

.nav-links { list-style: none; display: flex; align-items: center; gap: 30px; }
.nav-links a { text-decoration: none; color: var(--text-dark); font-weight: 600; transition: var(--transition); }
.nav-links a:hover, .nav-links a.active { color: var(--secondary); }

.hamburger { display: none; cursor: pointer; z-index: 2000; }
.hamburger .bar { display: block; width: 25px; height: 3px; margin: 5px auto; transition: all 0.3s ease-in-out; background-color: var(--primary); border-radius: 3px; }

/* --- 5. GSAP PRELOADER --- */
.artisan-preloader { position: fixed; inset: 0; background: var(--bg-linen); z-index: 9999; display: flex; align-items: center; justify-content: center; }
.loader-logo img { max-height: 200px; width: auto; object-fit: contain; clip-path: inset(1px); }

/* --- 6. PAGE LAYOUTS & SECTIONS --- */
.section-header { text-align: center; margin-bottom: 50px; }
.section-header h2 { font-size: 3.5rem; margin-bottom: 10px; } 
.section-header .subtitle { font-size: 1.25rem; color: var(--text-muted); }

/* Homepage */
.hero-premium { padding: 100px 0; min-height: 80vh; display: flex; align-items: center; }
.hero-wrapper { display: grid; grid-template-columns: 1.2fr 1fr; gap: 60px; align-items: center; }
.hero-text h1 { font-size: 4.5rem; margin: 20px 0; }
.hero-text p { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 40px; }
.hero-btns { display: flex; gap: 15px; }
.hero-visual img { max-width: 85%; margin: 0 auto; border-radius: var(--radius); box-shadow: var(--shadow-premium); }

.trust-bar { padding: 60px 0; text-align: center; border-bottom: 1px solid rgba(0,0,0,0.05); }
.logo-grid { display: flex; justify-content: center; gap: 50px; opacity: 0.6; filter: grayscale(1); margin-top: 30px; }
.logo-grid img { max-height: 40px; }

/* Features */
.features-section { padding: 100px 0; }
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.feature-card { background: var(--white); padding: 40px; border-radius: var(--radius); box-shadow: var(--shadow-soft); transition: var(--transition); border: 1px solid rgba(0, 109, 119, 0.05); }
.feature-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-premium); }
.feature-icon { display: flex; align-items: center; justify-content: center; width: 65px; height: 65px; background: rgba(0, 109, 119, 0.05); color: var(--secondary); border-radius: 16px; margin-bottom: 25px; transition: var(--transition); }
.feature-card:hover .feature-icon { background: var(--primary); color: var(--white); transform: translateY(-5px) scale(1.05); box-shadow: 0 10px 20px rgba(0, 109, 119, 0.2); }

/* Portfolio / Services Teaser */
.work-teaser, .services-group { padding: 30px 0; }
.teaser-grid, .services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.work-teaser-card, .project-card { background: var(--white); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-soft); cursor: pointer; transition: var(--transition); }
.work-teaser-card:hover, .project-card:hover { transform: translateY(-10px); box-shadow: var(--shadow-premium); }
.img-container, .teaser-img { position: relative; height: 260px; overflow: hidden; }
.img-container img, .teaser-img img { width: 100%; height: 100%; object-fit: cover; }
.view-overlay { position: absolute; inset: 0; background: rgba(0, 109, 119, 0.7); display: flex; align-items: center; justify-content: center; opacity: 0; transition: 0.3s; }
.view-overlay span { color: white; font-weight: 700; border: 2px solid white; padding: 8px 20px; border-radius: 50px; }
.work-teaser-card:hover .view-overlay, .project-card:hover .view-overlay { opacity: 1; }
.card-body, .project-card h3 { padding: 25px; text-align: center; font-size: 1.1rem; }
.category-label { color: var(--secondary); font-weight: 800; font-size: 0.75rem; letter-spacing: 1.5px; display: block; margin-bottom: 8px; }

/* Services Intro */
.services-intro { padding: 100px 0 40px; text-align: center; }
.group-title { margin-bottom: 40px; border-left: 5px solid var(--secondary); padding-left: 20px; }

.final-cta { padding: 80px 0 120px; }
.cta-box { background: var(--primary); padding: 80px 40px; border-radius: 24px; text-align: center; box-shadow: var(--shadow-premium); }
.cta-box h2 { font-size: 3.5rem; color: var(--white); margin-bottom: 15px; }

/* --- REVIEWS SECTION --- */
.reviews-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.review-card {
    background: var(--white);
    padding: 40px;
    border-radius: var(--radius);
    box-shadow: var(--shadow-soft);
    border: 1px solid rgba(0, 109, 119, 0.05);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.review-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-premium);
}

.review-stars {
    color: var(--accent); /* Goldenrod stars */
    font-size: 1.2rem;
    letter-spacing: 2px;
    margin-bottom: 20px;
}

.review-text {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-dark);
    font-style: italic;
    margin-bottom: 25px;
}

.review-author {
    border-top: 1px solid rgba(0, 109, 119, 0.1);
    padding-top: 15px;
}

.review-author strong {
    display: block;
    color: var(--primary);
    font-family: var(--font-heading);
    font-size: 1.1rem;
}

.review-author span {
    display: block;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* --- FLEX HEADER (Recent Transformations) --- */
.flex-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 40px;
    text-align: left;
}

.flex-header .header-text h2 {
    margin-bottom: 5px;
}

/* --- 7. PAGINATION LOGIC --- */
.agency-pagination { display: flex; justify-content: center; align-items: center; gap: 10px; margin-top: 40px; }
.agency-pagination a { text-decoration: none; font-family: var(--font-heading); font-size: 1rem; font-weight: 600; transition: var(--transition); }
.agency-pagination .page-num { display: flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 8px; color: var(--text-dark); border: 1px solid rgba(0, 109, 119, 0.2); }
.agency-pagination .page-num:hover { background: rgba(0, 109, 119, 0.05); border-color: var(--primary); }
.agency-pagination .page-num.active { background: var(--primary); color: var(--white); border-color: var(--primary); }
.agency-pagination .page-btn { padding: 10px 20px; color: var(--primary); border-radius: 8px; }
.agency-pagination .page-btn:hover { background: rgba(0, 109, 119, 0.05); }

/* --- 8. PROJECT LIGHTBOX MODAL (Before/After Edition) --- */
.modal-backdrop { display: none; position: fixed; top: 0; left: 0; width: 100vw; height: 100vh; background: rgba(15, 23, 42, 0.85); backdrop-filter: blur(6px); z-index: 9999; align-items: center; justify-content: center; padding: 20px; }
.modal-box { background: var(--white); border-radius: var(--radius); width: 100%; max-width: 1000px; position: relative; padding: 40px; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5); animation: modalFadeIn 0.4s cubic-bezier(0.16, 1, 0.3, 1) forwards; }

.modal-close { position: absolute; top: 15px; right: 15px; background: var(--primary); color: var(--white); border: none; width: 36px; height: 36px; border-radius: 50%; font-size: 1.4rem; display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 10; transition: var(--transition); }
.modal-close:hover { background: var(--secondary); transform: scale(1.1) rotate(90deg); }
/* --- 8.5 SINGLE IMAGE ZOOM MODAL --- */
.zoom-modal-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.9); /* Very dark, opaque background */
    z-index: 10000; /* Sits ABOVE the main project modal */
    align-items: center;
    justify-content: center;
    padding: 40px; /* Creates the border so it doesn't fill the screen */
    backdrop-filter: blur(10px);
    cursor: zoom-out; /* Turns the mouse into a minus magnifying glass */
}

.zoom-modal-content {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    object-fit: contain; /* Ensures the image proportions stay perfect */
    animation: zoomIn 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Adds a little hover effect to the images in the comparison grid so people know they can click */
.comp-item img {
    cursor: zoom-in;
    transition: var(--transition);
}
.comp-item img:hover {
    transform: scale(1.03); /* Slight zoom on hover */
}

@keyframes zoomIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* The Dual-Image Grid */
.comparison-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.comp-item { position: relative; overflow: hidden; border-radius: 12px; }
.comp-item img { width: 100%; height: 320px; object-fit: cover; }
.comp-label { position: absolute; top: 15px; left: 15px; background: var(--primary); color: var(--white); font-size: 0.8rem; font-weight: 800; padding: 6px 15px; border-radius: 4px; letter-spacing: 1.5px; box-shadow: 0 4px 10px rgba(0,0,0,0.3); }
.comp-label.after-label { background: var(--secondary); } /* Differentiates the AFTER tag */

@keyframes modalFadeIn { from { opacity: 0; transform: translateY(30px) scale(0.95); } to { opacity: 1; transform: translateY(0) scale(1); } }

/* --- 9. CONTACT PAGE --- */
.contact-page-wrapper { padding: 140px 25px 80px; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 80px; align-items: center; }
.contact-text-slide h1 { font-size: 4rem; margin: 20px 0; }
.contact-text-slide .subtitle { font-size: 1.2rem; color: var(--text-muted); margin-bottom: 40px; }

.contact-details { margin-top: 40px; }
.contact-item { display: flex; align-items: center; gap: 20px; margin-bottom: 25px; }

@keyframes pulse-contact { 0% { box-shadow: 0 0 0 0 rgba(226, 149, 120, 0.4); } 70% { box-shadow: 0 0 0 15px rgba(226, 149, 120, 0); } 100% { box-shadow: 0 0 0 0 rgba(226, 149, 120, 0); } }
.contact-icon { display: flex; align-items: center; justify-content: center; width: 50px; height: 50px; background: rgba(0, 109, 119, 0.05); color: var(--secondary); border-radius: 50%; transition: var(--transition); animation: pulse-contact 2.5s infinite cubic-bezier(0.66, 0, 0, 1); }
.contact-item:hover .contact-icon { background: var(--primary); color: var(--white); transform: scale(1.1); animation: none; }

.item-label { font-size: 0.85rem; font-weight: 800; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; margin-bottom: 2px; }
.item-text { font-size: 1.15rem; font-weight: 700; color: var(--primary); }
a.contact-item.contact-link { text-decoration: none; color: inherit; }
a.contact-item.contact-link:hover .item-text { color: var(--secondary); transition: var(--transition); }

.contact-card { background: var(--white); padding: 50px; border-radius: 24px; box-shadow: var(--shadow-premium); }
.form-group { margin-bottom: 25px; }
.form-label { display: block; font-weight: 700; margin-bottom: 10px; color: var(--primary); }
.form-control { width: 100%; padding: 16px; border: 2px solid rgba(0, 109, 119, 0.1); border-radius: 12px; font-family: var(--font-body); font-size: 1rem; background: var(--bg-linen); color: var(--text-dark); transition: var(--transition); }
.form-control:focus { outline: none; border-color: var(--secondary); background: var(--white); box-shadow: 0 0 0 4px rgba(226, 149, 120, 0.15); }
.btn-block { width: 100%; text-align: center; }
.error-msg { color: #d9534f; background: #fdf2f2; padding: 15px; border-radius: 8px; margin-bottom: 20px; font-weight: 600; }

.map-wrapper { margin-top: 50px; width: 100%; height: 350px; border-radius: 24px; overflow: hidden; box-shadow: var(--shadow-premium); border: 6px solid var(--white); transition: var(--transition); }
.map-wrapper iframe { filter: grayscale(0.2) contrast(1.1); }

/* --- 10. FOOTER --- */
.main-footer { padding: 80px 0 30px; background:var(--text-dark); color: var(--white); text-align: center; }
.footer-brand { font-size: 2rem; margin-bottom: 15px; font-family: var(--font-heading); letter-spacing: 1px; }
.footer-brand span { color: var(--secondary); }
.footer-desc { color: var(--bg-linen); opacity: 0.9; margin: 0 auto 30px; font-size: 1.05rem; max-width: 500px; }
.footer-links { margin: 0 0 40px 0; display: flex; justify-content: center; gap: 30px; }
.footer-links a { color: var(--white); text-decoration: none; font-size: 1rem; font-weight: 600; transition: var(--transition); }
.footer-links a:hover { color: var(--secondary); }
.footer-links .footer-cta { color: var(--accent); }
.footer-copyright { border-top: 1px solid rgba(255, 255, 255, 0.1); padding-top: 25px; font-size: 0.85rem; color: rgba(255, 255, 255, 0.5); }

/* ==========================================================================
   11. UNIFIED MOBILE RESPONSIVE QUERIES
   ========================================================================== */

/* --- TABLETS & SMALL LAPTOPS (Max: 992px) --- */
@media (max-width: 992px) {
    .logo img { max-height: 45px; } 
    .logo-text { font-size: 1.2rem; }
    
    .hero-wrapper, .contact-grid { grid-template-columns: 1fr; text-align: center; }
    .hero-btns { justify-content: center; }
    .contact-card { padding: 30px; }
    .logo-grid { flex-wrap: wrap; }
    
    .feature-grid, .teaser-grid, .services-grid { grid-template-columns: 1fr; }
    
    /* Comparison Modal Scale Down */
    .comparison-grid { grid-template-columns: 1fr; }
    .comp-item img { height: 300px; } /* Slightly shorter for stacked view */

    .hero-text h1 { font-size: 3.2rem; }
    .section-header h2 { font-size: 2.8rem; }
    .contact-text-slide h1 { font-size: 3rem; }
    .cta-box h2 { font-size: 3rem; }

    /* Hamburger Menu Logic */
    .hamburger { display: block; }
    .nav-links { position: fixed; left: 100%; top: 0; gap: 0; flex-direction: column; background: rgba(237, 246, 249, 0.98); width: 100%; height: 100vh; text-align: center; transition: 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55); justify-content: center; align-items: center; z-index: 1500; }
    .nav-links li { margin: 20px 0; }
    .nav-links a { font-size: 1.5rem; }
    .nav-links.active { left: 0; }
    
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}

/* --- PHONES (Max: 768px) --- */
@media (max-width: 768px) {
    .logo img { max-height: 35px; } 
    .logo-text { font-size: 1rem; }
    .loader-logo img { max-height: 120px; }
    
    .hero-text h1 { font-size: 2.2rem; }
    .section-header h2 { font-size: 2rem; }
    .contact-text-slide h1 { font-size: 2.2rem; }
    .cta-box h2 { font-size: 2rem; }
    .group-title h2 { font-size: 1.8rem; }
    
    .hero-premium, .features-section, .work-teaser, .final-cta, .services-group { padding: 30px 0; }
    .contact-page-wrapper { padding: 80px 25px 60px; }
    .cta-box { padding: 50px 25px; }
    
    .modal-box { padding: 15px; }
    .comp-item img { height: 250px; } /* Phone height for before/after */
    /* Shift the main modal to the top of the screen on mobile */
    .modal-backdrop {
        align-items: flex-start; /* Pushes the modal to the top */
        padding-top: 60px; /* Gives it a clean margin below the phone's status bar */
        padding-bottom: 40px; /* Prevents the bottom from hitting the edge if they scroll */
    }

    /* Ensure the modal box has enough scrolling room when pushed up */
    .modal-box {
        max-height: 85vh; /* Keeps it from bleeding off the bottom of the screen */
    }
    
    .footer-links { flex-direction: row; gap: 15px; }
    .hero-btns { flex-direction: column; gap: 15px; }
    .item-label { font-size: 0.75rem; text-align: left; }
    
    .map-wrapper { margin-top: 50px; height: 250px; border-radius: 16px; border-width: 4px; }
    
    .agency-pagination { gap: 5px; }
    .agency-pagination .page-num { width: 35px; height: 35px; font-size: 0.9rem; }
    .agency-pagination .page-btn { padding: 8px 12px; font-size: 0.9rem; }
    /* Transform Reviews Grid into a Swipe Carousel on Mobile */
/* Transform Reviews Grid into a Swipe Carousel on Mobile */
    .reviews-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 5px; /* Tightened the gap slightly to maintain the 'peek' effect */
        padding-bottom: 20px; 
        -webkit-overflow-scrolling: touch; 
    }

    /* Hide the ugly default scrollbar but keep functionality */
    .reviews-grid::-webkit-scrollbar {
        display: none;
    }
    .reviews-grid {
        -ms-overflow-style: none;  
        scrollbar-width: none;  
    }

    /* Force the cards to take up more of the screen */
    .review-card {
        flex: 0 0 72vw; /* Increased from 85vw, and 'flex: 0 0' prevents squishing */
        scroll-snap-align: center;
        padding: 30px 20px; 
    }
    /* Stack the Flex Header on phones */
    .flex-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px; /* Gives the button breathing room below the text */
    }

    /* Prevent the button from squishing and make it a nice tap target */
    .flex-header .btn {
        flex-shrink: 0;
        align-self: stretch; /* Makes the button full-width on mobile */
        text-align: center;
    }
}