:root {
    --forest-green: #2d5a43;    
    --leaf-green: #4a7c59;      
    --gradient-start: #78a36d;  
    --gradient-end: #2d5a43;    
    --rich-cream: #efebe2;      
    --text-color: #333333;
    --white: #ffffff;
    --border-grey: #e0e0e0;
    --transition: all 0.3s ease;
    --slide-pos: 4; 
    --item-width: 700px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body { font-family: 'Montserrat', sans-serif; color: var(--text-color); background-color: var(--rich-cream); line-height: 1.6; overflow-x: hidden; position: relative; width: 100%; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; position: relative; z-index: 2; }
.relative-pos { position: relative; }

.textured-master-bg, .richer-bg { background-color: var(--rich-cream); background-image: url("https://www.transparenttextures.com/patterns/linen-paper.png"); }
.simpler-white-bg { background-color: var(--white); }

.bg-design { position: absolute; width: 200px; height: 200px; background-size: contain; background-repeat: no-repeat; opacity: 0.03; z-index: 1; pointer-events: none; }
.icon-logo { background-image: url('images/logo/logo.png'); width: 450px; height: 450px; opacity: 0.05; }
.watermark-logo-pos { top: 250px; left: 50%; transform: translateX(-50%); }

h1, h2, h3 { font-family: 'Fredoka', sans-serif; font-weight: 700; color: var(--forest-green); letter-spacing: 1px; }
.section-title { text-align: center; font-size: 2.8rem; margin-bottom: 30px; text-transform: uppercase; }

.btn-primary { background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%); color: var(--white) !important; padding: 16px 32px; border-radius: 50px; text-decoration: none; font-weight: 700; font-family: 'Fredoka', sans-serif; font-size: 1rem; transition: var(--transition); border: 2px solid transparent; display: inline-block; cursor: pointer; box-shadow: 0 4px 15px rgba(45, 90, 67, 0.2); text-transform: uppercase; }
.btn-primary:hover { background: transparent; border-color: var(--forest-green); color: var(--forest-green) !important; transform: translateY(-3px); box-shadow: 0 10px 25px rgba(45, 90, 67, 0.3); }
.large-btn { padding: 20px 40px; font-size: 1.1rem; }
.full-btn { width: 100%; text-align: center; }

/* HEADER & MENU */
header { padding: 5px 0; background: rgba(255, 255, 255, 0.98); backdrop-filter: blur(5px); border-bottom: 5px solid var(--forest-green); position: sticky; top: 0; z-index: 1000; box-shadow: 0 5px 15px rgba(0,0,0,0.05); transition: var(--transition); }
.masterpiece-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; }

a.logo-group { display: flex; gap: 15px; align-items: center; text-decoration: none; color: inherit; cursor: pointer; transition: var(--transition); }
a.logo-group:hover { opacity: 0.8; }

.header-logo-container { width: 100px; height: 100px; flex-shrink: 0; display: flex; justify-content: center; align-items: center; transition: var(--transition); }
.header-logo-image { width: 100%; height: 100%; object-fit: contain; }

.logo-text h1 { font-size: 1.6rem; line-height: 1; margin-top: 5px; transition: var(--transition); color: var(--forest-green); } 
.logo-text p { font-size: 0.70rem; text-transform: uppercase; color: var(--leaf-green); font-weight: 700; margin-top: 5px; letter-spacing: 1px; max-height: 30px; opacity: 1; overflow: hidden; transition: var(--transition); }

.nav-container { display: flex; align-items: center; margin-left: auto; }
.nav-links { list-style: none; display: flex; gap: 20px; align-items: center; }
.nav-links a { text-decoration: none; color: var(--text-color); font-weight: 700; font-size: 0.9rem; text-transform: uppercase; transition: 0.3s; }
.nav-links a:hover { color: var(--forest-green); }

.mobile-menu-btn { display: none; flex-direction: column; gap: 6px; cursor: pointer; padding: 10px; margin-left: auto; z-index: 1001; }
.mobile-menu-btn .bar { width: 30px; height: 4px; background-color: var(--forest-green); border-radius: 4px; transition: var(--transition); }

header.scrolled { padding: 2px 0; }
header.scrolled .header-logo-container { width: 60px; height: 60px; }
header.scrolled .logo-text h1 { font-size: 1.3rem; }
header.scrolled .header-tagline { max-height: 0; opacity: 0; margin-top: 0; }

/* HERO & SERVICES */
.hero { padding: 130px 0; text-align: center; border-bottom: 1px solid var(--border-grey); }
.hero h1 { font-size: 4.5rem; line-height: 1.1; margin-bottom: 25px; }
.highlight { color: var(--forest-green); }
.green-glow { text-shadow: 0 0 15px rgba(45, 90, 67, 0.2); }
.hero p { font-size: 1.25rem; margin-bottom: 40px; font-weight: 600; max-width: 800px; margin-left: auto; margin-right: auto; }

.services-section { padding: 100px 0; border-bottom: 1px solid var(--border-grey); }
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 40px; }
.bordered-card { background: var(--rich-cream); padding: 50px 35px; border-radius: 15px; border-bottom: 6px solid transparent; transition: var(--transition); border: 1px solid var(--border-grey); }
.bordered-card h3 { font-size: 1.4rem; margin-bottom: 15px; text-transform: uppercase;}
.card-icon { color: var(--forest-green); font-size: 2rem; font-weight: bold; margin-bottom: 15px; }
.bordered-card:hover { border-bottom-color: var(--forest-green); transform: translateY(-8px); box-shadow: 12px 12px 0px var(--forest-green); }

/* SPONGE GALLERY SHOWCASE */
.showcase-section { padding: 100px 0; border-bottom: 1px solid var(--border-grey); overflow: hidden; }
.gallery-wrapper { position: relative; width: 100%; max-width: 1000px; margin: 0 auto; overflow: visible; padding: 40px 0; }
.gallery-track { display: flex; gap: 20px; align-items: center; width: max-content; margin-left: 50%; transform: translateX(calc((var(--item-width) / -2) - (var(--slide-pos) * (var(--item-width) + 20px)))); }
.gallery-item { width: var(--item-width) !important; height: 400px !important; flex: 0 0 var(--item-width) !important; background-color: var(--border-grey); border-radius: 20px; object-fit: cover; opacity: 0.4; transform: scale(0.85); transition: opacity 0.2s ease-out, transform 0.2s ease-out; box-shadow: 0 0 0 1px rgba(0,0,0,0.1), 0 20px 40px rgba(0,0,0,0.3); }
.gallery-item.active { opacity: 1; transform: scale(1.05); box-shadow: 0 0 0 4px var(--forest-green), 0 30px 60px rgba(45, 90, 67, 0.5); z-index: 10; }

.gallery-controls { text-align: center; margin-top: 50px; padding: 0 20px; }
.gallery-slider { -webkit-appearance: none; width: 100%; max-width: 400px; height: 12px; background: rgba(0,0,0,0.1); border-radius: 10px; outline: none; z-index: 20; position: relative; touch-action: pan-y; } 
.gallery-slider::-webkit-slider-thumb { -webkit-appearance: none; appearance: none; width: 75px; height: 75px; background-color: transparent; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'><polygon points='32,4 60,18 32,32 4,18' fill='%234a7c59'/><polygon points='4,18 32,32 32,38 4,24' fill='%233c6b49'/><polygon points='32,32 60,18 60,24 32,38' fill='%232d5a43'/><polygon points='4,24 32,38 32,60 4,46' fill='%23f4d03f'/><polygon points='32,38 60,24 60,46 32,60' fill='%23d4ac0d'/><circle cx='14' cy='38' r='3' fill='%23c29b0c'/><circle cx='24' cy='48' r='2' fill='%23c29b0c'/><circle cx='12' cy='46' r='2.5' fill='%23c29b0c'/><circle cx='42' cy='38' r='2.5' fill='%23b08b0a'/><circle cx='52' cy='34' r='2' fill='%23b08b0a'/><circle cx='48' cy='48' r='3' fill='%23b08b0a'/></svg>"); background-size: contain; background-position: center; background-repeat: no-repeat; cursor: grab; border: none; border-radius: 0; filter: drop-shadow(0px 8px 10px rgba(45,90,67,0.4)); transition: transform 0.1s ease; }
.gallery-slider::-webkit-slider-thumb:active { cursor: grabbing; transform: scale(1.15); filter: drop-shadow(0px 12px 12px rgba(45,90,67,0.6)); }

.gallery-slider::-moz-range-thumb { width: 75px; height: 75px; background-color: transparent; background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 64'><polygon points='32,4 60,18 32,32 4,18' fill='%234a7c59'/><polygon points='4,18 32,32 32,38 4,24' fill='%233c6b49'/><polygon points='32,32 60,18 60,24 32,38' fill='%232d5a43'/><polygon points='4,24 32,38 32,60 4,46' fill='%23f4d03f'/><polygon points='32,38 60,24 60,46 32,60' fill='%23d4ac0d'/><circle cx='14' cy='38' r='3' fill='%23c29b0c'/><circle cx='24' cy='48' r='2' fill='%23c29b0c'/><circle cx='12' cy='46' r='2.5' fill='%23c29b0c'/><circle cx='42' cy='38' r='2.5' fill='%23b08b0a'/><circle cx='52' cy='34' r='2' fill='%23b08b0a'/><circle cx='48' cy='48' r='3' fill='%23b08b0a'/></svg>"); background-size: contain; background-position: center; background-repeat: no-repeat; cursor: grab; border: none; border-radius: 0; filter: drop-shadow(0px 8px 10px rgba(45,90,67,0.4)); }
.gallery-slider::-moz-range-thumb:active { cursor: grabbing; transform: scale(1.15); filter: drop-shadow(0px 12px 12px rgba(45,90,67,0.6)); }

/* SHOWCASE CURTAIN STYLES */
.showcase-page-section { padding: 80px 0 120px; }

.ba-wrapper {
    position: relative; 
    width: fit-content; 
    max-width: 100%;
    margin: 0 auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0,0,0,0.2);
    border: 4px solid var(--forest-green);
    background-color: #ddd; 
}

.clip-layer { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; }
#ba-before-layer { z-index: 3; clip-path: polygon(0% 0%, 50% 0%, 50% 100%, 0% 100%); }
#ba-middle-layer { z-index: 2; }
.ba-wrapper img { display: block; pointer-events: none; }
#ba-before, #ba-middle { position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover; }
#ba-after { position: relative; max-height: 70vh; width: auto; max-width: 100%; z-index: 1; }

.ba-slider { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 6; opacity: 0; cursor: col-resize; margin: 0; touch-action: pan-y; }

.ba-handle { position: absolute; top: 0; left: 50%; width: 4px; height: 100%; background: var(--white); z-index: 5; transform: translateX(-50%); pointer-events: none; }
.ba-handle-button { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; background: var(--forest-green); color: var(--white); border: 2px solid var(--white); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: bold; box-shadow: 0 4px 10px rgba(0,0,0,0.3); transition: width 0.3s, height 0.3s, border-radius 0.3s; }

.ba-wrapper.mode-3pic .ba-handle { background: transparent !important; }
.ba-wrapper.mode-3pic .ba-handle-button { top: auto; bottom: 20px; width: 70px; height: 30px; border-radius: 15px; }
.ba-wrapper.mode-3pic .ba-label { display: none !important; }

.ba-label { position: absolute; top: 20px; padding: 8px 16px; background: rgba(0,0,0,0.6); color: var(--white); font-weight: bold; border-radius: 30px; pointer-events: none; text-transform: uppercase; font-size: 0.9rem; }
.label-before { left: 20px; }
.label-middle { left: 50%; transform: translateX(-50%); } 
.label-after { right: 20px; z-index: 1; }

/* PROJECT SELECTOR BUTTONS */
.project-selector { display: flex; justify-content: center; gap: 15px; margin-top: 40px; margin-bottom: 20px; flex-wrap: wrap; }
.proj-btn { background: transparent; color: var(--forest-green) !important; border-color: var(--forest-green); }
.proj-btn.active { background: linear-gradient(135deg, var(--gradient-start) 0%, var(--gradient-end) 100%); color: var(--white) !important; border-color: transparent; }
.thumbnail-bar { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }
.thumb-item { width: 100px; height: 70px; object-fit: cover; border-radius: 8px; cursor: pointer; box-shadow: 0 0 0 3px transparent; opacity: 0.6; transition: var(--transition); }
.thumb-item:hover { opacity: 0.9; }
.thumb-item.active { opacity: 1; box-shadow: 0 0 0 3px var(--forest-green), 0 4px 10px rgba(45, 90, 67, 0.3); }

/* ESTIMATE SECTION & FORM */
.estimate-section { padding: 100px 0; border-bottom: 1px solid var(--border-grey); }
.rich-form { max-width: 800px; margin: 0 auto; background: var(--white); padding: 50px; border-radius: 15px; box-shadow: 0 15px 35px rgba(0,0,0,0.1); border-top: 5px solid var(--forest-green); }
.rich-form h2 { text-align: center; font-size: 2.2rem; margin-bottom: 10px; }
.form-sub-tag { text-align: center; margin-bottom: 30px; font-weight: 600; color: #666; }

.input-group { margin-bottom: 20px; }
.input-row { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.input-group label { display: block; margin-bottom: 8px; font-weight: 700; color: var(--forest-green); font-size: 0.9rem; text-transform: uppercase; }
.input-group input[type="text"], .input-group input[type="tel"], .input-group input[type="number"] { width: 100%; padding: 15px; border: 2px solid var(--border-grey); border-radius: 8px; font-family: 'Montserrat', sans-serif; font-size: 1rem; transition: var(--transition); background: #f9f9f9; }
.input-group input:focus { border-color: var(--leaf-green); outline: none; background: var(--white); box-shadow: 0 0 0 3px rgba(74, 124, 89, 0.2); }

.custom-check-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 15px; margin-top: 10px; }
.custom-check { display: flex; align-items: center; gap: 10px; background: #f9f9f9; padding: 12px 15px; border-radius: 8px; border: 2px solid var(--border-grey); transition: var(--transition); cursor: pointer; }
.custom-check:hover { border-color: var(--leaf-green); }
.custom-check input[type="checkbox"] { width: 18px; height: 18px; accent-color: var(--forest-green); cursor: pointer; }
.custom-check label { margin-bottom: 0; cursor: pointer; text-transform: none; color: var(--text-color); font-weight: 600; }

/* FOOTER */
.footer { background: var(--forest-green); color: var(--white); padding: 60px 0 30px; }
.footer-grid { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 30px; }
.footer-text-logo { font-family: 'Fredoka', sans-serif; font-size: 1.8rem; font-weight: 700; margin-bottom: 15px; color: var(--white); }
.footer p { color: rgba(255, 255, 255, 0.8); margin-bottom: 8px; font-size: 0.95rem; }
.social-tag { display: inline-block; background: rgba(255, 255, 255, 0.1); color: var(--white); padding: 10px 20px; border-radius: 50px; text-decoration: none; font-weight: 600; transition: var(--transition); border: 1px solid rgba(255,255,255,0.2); }
.social-tag:hover { background: var(--white); color: var(--forest-green); }
.copyright { text-align: center; margin-top: 50px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,0.1); color: rgba(255,255,255,0.6); font-size: 0.85rem; }

/* RESPONSIVE DESIGN FOR MOBILE */
@media (max-width: 768px) {
    :root {
        --item-width: 85vw;
    }

    .masterpiece-header { position: relative; }
    .mobile-menu-btn { display: flex; z-index: 1001; }
    
    .mobile-menu-btn.active .bar:nth-child(1) { transform: translateY(10px) rotate(45deg); }
    .mobile-menu-btn.active .bar:nth-child(2) { opacity: 0; }
    .mobile-menu-btn.active .bar:nth-child(3) { transform: translateY(-10px) rotate(-45deg); }

    .nav-container { position: absolute; top: 100%; left: 0; width: 100%; background: var(--white); box-shadow: 0 10px 15px rgba(0,0,0,0.1); clip-path: polygon(0 0, 100% 0, 100% 0, 0 0); transition: clip-path 0.3s ease; }
    .nav-container.active { clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%); }
    
    .nav-links { display: flex; flex-direction: column; padding: 30px 0; margin: 0; gap: 25px; text-align: center; align-items: center; justify-content: center; width: 100%; }
    .nav-links li { width: 100%; display: flex; justify-content: center; }
    .nav-links a { font-size: 1.1rem; display: block; width: fit-content; }
    .nav-links .btn-primary { width: auto; min-width: 220px; display: inline-block; }
    
    .hero h1 { font-size: 3rem; }
    .input-row { grid-template-columns: 1fr; }
    .footer-grid { flex-direction: column; text-align: center; }
    .footer-right-group { text-align: center !important; }
    .gallery-item { height: 55vw !important; }
    
    #ba-after { height: auto; max-height: unset; }
}