/* ============================================
   Hammond Brickwork - Custom Styles
   Built on Bootstrap 5
   Colour Palette: Premium Earth & Craft
   ============================================ */

/* --- CSS Custom Properties --- */
:root {
    --hb-charcoal: #1C1C1E;
    --hb-slate: #2D3436;
    --hb-terracotta: #C0592B;
    --hb-terracotta-dark: #A04420;
    --hb-gold: #D4A24E;
    --hb-gold-dark: #B8892F;
    --hb-cream: #F5F1EB;
    --hb-warm-grey: #A09A90;
    --hb-white: #FFFFFF;
    --hb-light-grey: #E8E4DE;
    --hb-body-text: #3A3A3C;
    --hb-hero-overlay: rgba(28, 28, 30, 0.65);
    --hb-font-heading: Georgia, 'Times New Roman', Times, serif;
    --hb-font-body: 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --hb-transition: 0.3s ease;
}

/* --- Base & Typography --- */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 76px;
}

body {
    font-family: var(--hb-font-body);
    color: var(--hb-body-text);
    background-color: var(--hb-white);
    line-height: 1.7;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--hb-font-heading);
    color: var(--hb-charcoal);
    font-weight: 700;
}

h2 {
    font-size: 2.2rem;
    margin-bottom: 0.5rem;
}

p {
    margin-bottom: 1rem;
}

a {
    color: var(--hb-terracotta);
    text-decoration: none;
    transition: color var(--hb-transition);
}

a:hover {
    color: var(--hb-terracotta-dark);
}

/* --- Section Styling --- */
.section-padding {
    padding: 5rem 0;
}

.section-bg-cream {
    background-color: var(--hb-cream);
}

.section-bg-dark {
    background-color: var(--hb-charcoal);
    color: var(--hb-cream);
}

.section-bg-dark h2,
.section-bg-dark h3,
.section-bg-dark h4 {
    color: var(--hb-white);
}

.section-title {
    text-align: center;
    margin-bottom: 1rem;
}

.section-subtitle {
    text-align: center;
    color: var(--hb-warm-grey);
    font-size: 1.1rem;
    max-width: 650px;
    margin: 0 auto 3rem auto;
}

.section-divider {
    width: 60px;
    height: 3px;
    background: linear-gradient(90deg, var(--hb-terracotta), var(--hb-gold));
    border: none;
    margin: 1rem auto 1.5rem auto;
}

/* --- Navbar --- */
.navbar {
    background-color: rgba(28, 28, 30, 0.95) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 0.6rem 0;
    transition: all var(--hb-transition);
    border-bottom: 2px solid transparent;
}

.navbar.scrolled {
    padding: 0.4rem 0;
    border-bottom-color: var(--hb-terracotta);
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.15);
}

.navbar-brand img {
    height: 50px;
    transition: height var(--hb-transition);
}

.navbar.scrolled .navbar-brand img {
    height: 40px;
}

.navbar-dark .navbar-nav .nav-link {
    color: rgba(255, 255, 255, 0.85);
    font-size: 0.9rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    padding: 0.5rem 1rem;
    transition: color var(--hb-transition);
    position: relative;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
    color: var(--hb-gold);
}

.navbar-dark .navbar-nav .nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background-color: var(--hb-gold);
    transition: all var(--hb-transition);
    transform: translateX(-50%);
}

.navbar-dark .navbar-nav .nav-link:hover::after,
.navbar-dark .navbar-nav .nav-link.active::after {
    width: 60%;
}

.navbar-phone {
    color: var(--hb-gold) !important;
    font-weight: 600;
    font-size: 0.95rem !important;
    letter-spacing: 0.5px;
}

.navbar-phone:hover {
    color: var(--hb-white) !important;
}

.navbar-phone i {
    margin-right: 0.3rem;
}

.navbar-toggler {
    border-color: rgba(255, 255, 255, 0.3);
    padding: 0.4rem 0.6rem;
}

.navbar-toggler-icon {
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 30 30'%3e%3cpath stroke='rgba%28212, 162, 78, 1%29' stroke-linecap='round' stroke-miterlimit='10' stroke-width='2' d='M4 7h22M4 15h22M4 23h22'/%3e%3c/svg%3e");
}

/* --- Hero Section --- */
.hero-section {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        135deg,
        rgba(28, 28, 30, 0.75) 0%,
        rgba(28, 28, 30, 0.55) 50%,
        rgba(28, 28, 30, 0.70) 100%
    );
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    padding: 2rem 1rem;
}

.hero-content .hero-headline {
    font-size: 3.2rem;
    color: var(--hb-white);
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 1rem;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}

.hero-content .hero-tagline,
.hero-content h1.hero-tagline {
    font-size: 1.3rem;
    color: var(--hb-cream);
    font-weight: 300;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
    opacity: 0.9;
}

.hero-content .hero-gold-line {
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, var(--hb-terracotta), var(--hb-gold));
    margin: 1.5rem auto;
    border: none;
}

.hero-content .hero-sub {
    font-size: 1.05rem;
    color: rgba(245, 241, 235, 0.8);
    max-width: 550px;
    margin: 0 auto 2rem auto;
    line-height: 1.8;
}

/* --- Buttons --- */
.btn-hb-primary {
    background: linear-gradient(135deg, var(--hb-terracotta), var(--hb-terracotta-dark));
    color: var(--hb-white);
    border: none;
    padding: 0.8rem 2.2rem;
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border-radius: 3px;
    transition: all var(--hb-transition);
    box-shadow: 0 4px 15px rgba(192, 89, 43, 0.3);
}

.btn-hb-primary:hover {
    background: linear-gradient(135deg, var(--hb-terracotta-dark), #8B3720);
    color: var(--hb-white);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(192, 89, 43, 0.4);
}

.btn-hb-outline {
    background: transparent;
    color: var(--hb-white);
    border: 2px solid var(--hb-gold);
    padding: 0.75rem 2rem;
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    border-radius: 3px;
    transition: all var(--hb-transition);
}

.btn-hb-outline:hover {
    background-color: var(--hb-gold);
    color: var(--hb-charcoal);
    transform: translateY(-2px);
}

/* --- About Section --- */
.about-stat {
    text-align: center;
    padding: 1.5rem 1rem;
}

.about-stat .stat-number {
    font-family: var(--hb-font-heading);
    font-size: 3rem;
    font-weight: 700;
    color: var(--hb-terracotta);
    line-height: 1;
    margin-bottom: 0.3rem;
}

.about-stat .stat-label {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--hb-warm-grey);
    font-weight: 600;
}

.about-image-wrapper {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
}

.about-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.about-image-wrapper:hover img {
    transform: scale(1.03);
}

.about-image-wrapper .image-accent {
    position: absolute;
    bottom: -5px;
    left: -5px;
    width: 100px;
    height: 100px;
    border-left: 4px solid var(--hb-gold);
    border-bottom: 4px solid var(--hb-gold);
}

/* --- Services Section --- */
.service-card {
    background-color: var(--hb-white);
    border: none;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
    transition: all var(--hb-transition);
    height: 100%;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
}

.service-card .card-img-top {
    height: 220px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.service-card:hover .card-img-top {
    transform: scale(1.05);
}

.service-card .card-img-wrapper {
    overflow: hidden;
    position: relative;
}

.service-card .card-img-wrapper::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--hb-terracotta), var(--hb-gold));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform var(--hb-transition);
}

.service-card:hover .card-img-wrapper::after {
    transform: scaleX(1);
}

.service-card .card-body {
    padding: 1.5rem;
}

.service-card .card-title {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 0.6rem;
    color: var(--hb-charcoal);
}

.service-card .card-text {
    font-size: 0.92rem;
    color: var(--hb-warm-grey);
    line-height: 1.6;
}

/* --- Portfolio / Gallery --- */
.portfolio-item {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    cursor: pointer;
}

.portfolio-item img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.portfolio-item:hover img {
    transform: scale(1.08);
}

/* --- Featured Project --- */
#featured-project .portfolio-item img {
    height: auto;
    width: 100%;
    border-radius: 4px;
}

.portfolio-item .portfolio-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(28, 28, 30, 0.8) 0%, transparent 60%);
    opacity: 0;
    transition: opacity var(--hb-transition);
    display: flex;
    align-items: flex-end;
    padding: 1.5rem;
}

.portfolio-item:hover .portfolio-overlay {
    opacity: 1;
}

.portfolio-overlay h5 {
    color: var(--hb-white);
    font-size: 1rem;
    margin: 0;
}

.portfolio-overlay span {
    color: var(--hb-gold);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* --- Why Choose Us / Trust --- */
.trust-item {
    text-align: center;
    padding: 2rem 1.5rem;
    transition: transform var(--hb-transition);
}

.trust-item:hover {
    transform: translateY(-3px);
}

.trust-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--hb-terracotta), var(--hb-terracotta-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.2rem auto;
    box-shadow: 0 4px 15px rgba(192, 89, 43, 0.25);
}

.trust-icon i {
    font-size: 1.6rem;
    color: var(--hb-white);
}

.trust-item h5 {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.trust-item p {
    font-size: 0.9rem;
    color: var(--hb-warm-grey);
    margin-bottom: 0;
}

/* --- Testimonials --- */
.testimonial-card {
    background-color: var(--hb-white);
    border-radius: 4px;
    padding: 2rem;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.06);
    height: 100%;
    position: relative;
    border-top: 3px solid var(--hb-gold);
}

.testimonial-card .quote-icon {
    font-size: 2.5rem;
    color: var(--hb-cream);
    line-height: 1;
    font-family: Georgia, serif;
    margin-bottom: 0.5rem;
}

.testimonial-card .testimonial-text {
    font-style: italic;
    font-size: 0.95rem;
    color: var(--hb-body-text);
    line-height: 1.7;
    margin-bottom: 1rem;
}

.testimonial-card .testimonial-author {
    font-weight: 700;
    font-size: 0.9rem;
    color: var(--hb-charcoal);
    margin-bottom: 0.1rem;
}

.testimonial-card .testimonial-location {
    font-size: 0.8rem;
    color: var(--hb-warm-grey);
}

.testimonial-stars {
    color: var(--hb-gold);
    margin-bottom: 0.5rem;
}

/* --- Service Areas --- */
.area-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.area-list li {
    padding: 0.4rem 0;
    font-size: 0.95rem;
    color: var(--hb-body-text);
    position: relative;
    padding-left: 1.5rem;
}

.area-list li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 8px;
    height: 8px;
    background-color: var(--hb-terracotta);
    border-radius: 1px;
}

/* --- Contact Section --- */
.contact-form .form-control {
    border: 1px solid var(--hb-light-grey);
    border-radius: 3px;
    padding: 0.8rem 1rem;
    font-size: 0.95rem;
    background-color: var(--hb-white);
    transition: border-color var(--hb-transition), box-shadow var(--hb-transition);
}

.contact-form .form-control:focus {
    border-color: var(--hb-terracotta);
    box-shadow: 0 0 0 3px rgba(192, 89, 43, 0.15);
}

.contact-form .form-label {
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--hb-charcoal);
    margin-bottom: 0.4rem;
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
}

.contact-info-item .contact-icon {
    width: 45px;
    height: 45px;
    min-width: 45px;
    background-color: var(--hb-terracotta);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1rem;
}

.contact-info-item .contact-icon i {
    color: var(--hb-white);
    font-size: 1rem;
}

.contact-info-item h6 {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--hb-warm-grey);
    margin-bottom: 0.2rem;
    font-family: var(--hb-font-body);
    font-weight: 600;
}

.contact-info-item p {
    margin-bottom: 0;
    font-size: 1rem;
    color: var(--hb-charcoal);
    font-weight: 500;
}

.contact-info-item a {
    color: var(--hb-charcoal);
    font-weight: 500;
}

.contact-info-item a:hover {
    color: var(--hb-terracotta);
}

/* --- Footer --- */
.site-footer {
    background-color: var(--hb-charcoal);
    color: rgba(245, 241, 235, 0.7);
    padding: 3rem 0 1.5rem 0;
}

.site-footer h6 {
    color: var(--hb-gold);
    font-family: var(--hb-font-body);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-size: 0.8rem;
    margin-bottom: 1rem;
}

.site-footer a {
    color: rgba(245, 241, 235, 0.7);
    font-size: 0.9rem;
    transition: color var(--hb-transition);
}

.site-footer a:hover {
    color: var(--hb-gold);
}

.site-footer .footer-links {
    list-style: none;
    padding: 0;
}

.site-footer .footer-links li {
    margin-bottom: 0.4rem;
}

.footer-bottom {
    border-top: 1px solid rgba(245, 241, 235, 0.1);
    padding-top: 1.5rem;
    margin-top: 2rem;
    font-size: 0.8rem;
    color: rgba(245, 241, 235, 0.4);
}

.footer-social a,
.footer-social span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid rgba(245, 241, 235, 0.2);
    color: rgba(245, 241, 235, 0.7);
    margin-right: 0.5rem;
    transition: all var(--hb-transition);
    font-size: 0.95rem;
}

.footer-social a:hover,
.footer-social span:hover {
    background-color: var(--hb-terracotta);
    border-color: var(--hb-terracotta);
    color: var(--hb-white);
}

/* --- Scroll Animations --- */
.fade-up {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-up.visible {
    opacity: 1;
    transform: translateY(0);
}

.fade-in {
    opacity: 0;
    transition: opacity 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
}

/* Staggered animations for cards */
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }

/* --- Back to Top Button --- */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 45px;
    height: 45px;
    background-color: var(--hb-terracotta);
    color: var(--hb-white);
    border: none;
    border-radius: 3px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: all var(--hb-transition);
    z-index: 999;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--hb-terracotta-dark);
    transform: translateY(-3px);
}

/* --- Responsive --- */
@media (max-width: 991.98px) {
    .hero-content .hero-headline {
        font-size: 2.4rem;
    }

    .hero-content .hero-tagline {
        font-size: 1.1rem;
    }

    h2 {
        font-size: 1.8rem;
    }

    .section-padding {
        padding: 3.5rem 0;
    }

    .navbar-collapse {
        background-color: var(--hb-charcoal);
        padding: 1rem;
        margin-top: 0.5rem;
        border-radius: 4px;
    }

    .hero-section {
        background-attachment: scroll;
    }
}

@media (max-width: 767.98px) {
    .hero-content .hero-headline {
        font-size: 1.9rem;
        letter-spacing: 1px;
    }

    .hero-content .hero-tagline {
        font-size: 1rem;
    }

    .hero-content .hero-sub {
        font-size: 0.95rem;
    }

    h2 {
        font-size: 1.6rem;
    }

    .section-padding {
        padding: 3rem 0;
    }

    .about-stat .stat-number {
        font-size: 2.4rem;
    }

    .portfolio-item img {
        height: 220px;
    }

    .service-card .card-img-top {
        height: 180px;
    }
}

@media (max-width: 575.98px) {
    .hero-content .hero-headline {
        font-size: 1.6rem;
    }

    .btn-hb-primary,
    .btn-hb-outline {
        padding: 0.7rem 1.5rem;
        font-size: 0.85rem;
    }
}

/* --- Sub-page Styles --- */
.subpage-header {
    background-color: var(--hb-charcoal);
    padding: 8rem 0 3rem 0;
    text-align: center;
}

.subpage-header h1 {
    color: var(--hb-white);
    font-size: 2.4rem;
    margin-bottom: 0.5rem;
}

.subpage-header p {
    color: var(--hb-warm-grey);
    font-size: 1rem;
}

.subpage-content {
    padding: 3rem 0 5rem 0;
}

.subpage-content h2 {
    font-size: 1.5rem;
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.subpage-content p,
.subpage-content li {
    font-size: 0.95rem;
    line-height: 1.8;
}

/* --- Gallery Page --- */
.gallery-grid .gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 4px;
    margin-bottom: 1.5rem;
    cursor: pointer;
}

.gallery-grid .gallery-item img {
    width: 100%;
    height: 300px;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.gallery-grid .gallery-item:hover img {
    transform: scale(1.05);
}

/* Lightbox overlay */
.lightbox-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.92);
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.lightbox-overlay.active {
    display: flex;
}

.lightbox-overlay img {
    max-width: 90%;
    max-height: 90vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
}

.lightbox-close {
    position: absolute;
    top: 1.5rem;
    right: 2rem;
    color: var(--hb-white);
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity var(--hb-transition);
    background: none;
    border: none;
}

.lightbox-close:hover {
    opacity: 1;
}

/* --- Print Styles --- */
@media print {
    .navbar,
    .back-to-top,
    .hero-overlay {
        display: none !important;
    }

    .hero-section {
        min-height: auto;
        padding: 2rem 0;
    }

    .section-padding {
        padding: 2rem 0;
    }
}
