/* ===========================
   MODERN WEBSITE UPGRADE
   Holding Hands Group 01 (Pty) Ltd
   =========================== */

/* CSS Variables */
:root {
    --primary: #f26b1d;
    --primary-light: #ff7e2e;
    --primary-dark: #d4571a;
    --secondary: #1a1a1a;
    --accent: #ff6b35;
    --success: #28a745;
    --warning: #ffc107;
    --info: #17a2b8;

    --white: #ffffff;
    --light: #f8f9fa;
    --bg: #f9f9f9;
    --gray-100: #f1f3f4;
    --gray-200: #e9ecef;
    --gray-300: #dee2e6;
    --gray-400: #ced4da;
    --gray-500: #6c757d;
    --gray-600: #495057;
    --gray-700: #343a40;
    --gray-800: #212529;
    --gray-900: #1a1a1a;

    --max-width: 1200px;
    --border-radius: 12px;
    --border-radius-sm: 6px;
    --border-radius-lg: 20px;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 8px 25px rgba(0, 0, 0, 0.15);
    --shadow-xl: 0 20px 40px rgba(0, 0, 0, 0.1);

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-fast: all 0.15s ease;
    --transition-slow: all 0.5s ease;

    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* Reset & Base Styles */
*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--secondary);
    background: var(--bg);
    overflow-x: hidden;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

input,
button,
textarea,
select {
    font: inherit;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 0.5em;
    color: var(--secondary);
}

h1 {
    font-size: clamp(2rem, 5vw, 3.5rem);
}

h2 {
    font-size: clamp(1.75rem, 4vw, 2.5rem);
}

h3 {
    font-size: clamp(1.5rem, 3vw, 2rem);
}

h4 {
    font-size: clamp(1.25rem, 2.5vw, 1.5rem);
}

h5 {
    font-size: clamp(1.1rem, 2vw, 1.25rem);
}

h6 {
    font-size: 1rem;
}

p {
    margin-bottom: 1rem;
    color: var(--gray-600);
}

.lead {
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--gray-600);
    line-height: 1.6;
}

/* Layout */
.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 1rem;
}

@media (min-width: 640px) {
    .container {
        padding: 0 2rem;
    }
}

/* Header */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    z-index: 1000;
    transition: var(--transition);
}

.site-header.scrolled {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: var(--shadow);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 0;
}

.brand {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: inherit;
}

.logo {
    width: 60px;
    height: 60px;
    border-radius: var(--border-radius-sm);
    transition: var(--transition);
}

.brand:hover .logo {
    transform: scale(1.05);
}

.company-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--secondary);
    line-height: 1.2;
}

.tagline {
    font-size: 0.85rem;
    color: var(--primary);
    font-weight: 500;
}

/* Navigation */
.nav {
    display: flex;
    align-items: center;
    gap: 2rem;
}

.nav a {
    color: var(--secondary);
    text-decoration: none;
    font-weight: 500;
    position: relative;
    transition: var(--transition);
}

.nav a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: var(--transition);
}

.nav a:hover {
    color: var(--primary);
}

.nav a:hover::after {
    width: 100%;
}

/* Mobile Menu */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    gap: 4px;
    transition: var(--transition);
}

.hamburger-line {
    width: 28px;
    height: 3px;
    background: var(--secondary);
    border-radius: 2px;
    transition: var(--transition);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(8px, -8px);
}

.mobile-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    box-shadow: var(--shadow-lg);
    padding: 1rem 0;
}

.mobile-nav.active {
    display: block;
    animation: slideDown 0.3s ease;
}

.mobile-nav a {
    display: block;
    padding: 1rem 2rem;
    color: var(--secondary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    border-bottom: 1px solid var(--gray-100);
}

.mobile-nav a:hover {
    background: var(--gray-50);
    color: var(--primary);
    padding-left: 2.5rem;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero {
    background: linear-gradient(180deg, #fff 0%, #fbfbfb 60%);
    padding: 3rem 0
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 480px;
    gap: 2rem;
    align-items: center
}

.hero-copy h2 {
    font-size: 2.25rem;
    margin: 0 0 0.5rem;
    color: var(--charcoal)
}

.lead {
    color: #333;
    max-width: 44ch
}

.btn {
    display: inline-block;
    padding: 0.75rem 1rem;
    border-radius: 6px;
    text-decoration: none
}

.btn.primary {
    background: var(--primary);
    color: #fff;
    font-weight: 600
}

/* industrial accent */
.hero-visual {
    border-left: 4px solid rgba(242, 107, 29, 0.06);
    padding-left: 1rem
}

.hero-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 6px 20px rgba(26, 26, 26, 0.08);
    object-fit: cover
}

.about h3,
.services h3,
.why h3,
.contact h3 {
    margin-top: 0
}

.about p {
    background: #fff;
    padding: 1rem;
    border-radius: var(--radius);
    box-shadow: 0 6px 18px rgba(26, 26, 26, 0.04)
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 1rem
}

.service-card {
    background: #fff;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 4px 16px rgba(26, 26, 26, 0.04);
    text-align: center
}

.service-card .icon {
    font-size: 1.8rem;
    margin-bottom: 0.5rem
}

.service-card h4 {
    margin: 0 0 .5rem
}

/* Service Inquiry Button */
.service-inquiry-btn {
    background: #25d366;
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 15px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    width: 100%;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(37, 211, 102, 0.3);
}

.service-inquiry-btn:hover {
    background: #20ba5a;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.4);
    color: white;
    text-decoration: none;
}

.service-inquiry-btn i {
    font-size: 16px;
}

.why .reasons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    list-style: none;
    padding: 0
}

.why .reasons li {
    background: #fff;
    padding: 0.75rem;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 0.75rem
}

.tick {
    color: var(--primary);
    font-weight: 700
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 220px;
    gap: 1rem;
    align-items: center
}

.contact-details a {
    color: var(--charcoal);
    text-decoration: none
}

.contact-logo img {
    width: 160px
}

/* visual polish for contact block to match requested layout */
.contact {
    padding-top: 1rem;
    padding-bottom: 1rem
}

.contact .contact-details {
    background: #fff;
    padding: 1rem;
    border-radius: 8px;
    box-shadow: 0 6px 18px rgba(26, 26, 26, 0.04)
}

.contact .contact-logo {
    display: flex;
    align-items: center;
    justify-content: center
}

.site-footer {
    background: #fff;
    border-top: 1px solid #eee;
    padding: 1rem 0;
    text-align: center;
    color: #666
}

/* Footer Built-by Credit */
.built-by {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: var(--gray-500);
}

.built-by a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
}

.built-by a:hover {
    color: var(--primary-dark);
    text-decoration: underline;
}

/* Responsive */
@media (max-width:900px) {
    .hero-grid {
        grid-template-columns: 1fr
    }

    .services-grid {
        grid-template-columns: repeat(2, 1fr)
    }

    .contact-grid {
        grid-template-columns: 1fr
    }

    .nav {
        display: none
    }

    .mobile-menu-toggle {
        display: flex
    }

    .site-header {
        position: relative
    }
}

@media (max-width:520px) {
    .service-card {
        padding: 0.75rem
    }

    .company-name {
        font-size: 0.9rem
    }

    .logo {
        width: 56px;
        height: 56px
    }

    .hero-copy h2 {
        font-size: 1.6rem
    }
}

/* WhatsApp Float Button */
.whatsapp-float {
    position: fixed;
    bottom: 120px;
    right: 20px;
    background: #25d366;
    color: white;
    border-radius: 50px;
    text-decoration: none;
    box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    z-index: 1000;
    display: flex;
    align-items: center;
    padding: 12px 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    font-size: 14px;
    transform: translateY(0) scale(1);
    opacity: 1;
    animation: whatsappPulse 2s infinite, whatsappFloat 3s ease-in-out infinite;
}

.whatsapp-float.show {
    animation: whatsappBounceIn 0.6s ease-out forwards, whatsappPulse 2s infinite 0.6s, whatsappFloat 3s ease-in-out infinite 0.6s;
}

.whatsapp-float:hover {
    background: #20ba5a;
    transform: translateY(-8px) scale(1.05);
    box-shadow: 0 8px 30px rgba(37, 211, 102, 0.6);
    text-decoration: none;
    color: white;
    animation-play-state: paused;
}

.whatsapp-float i {
    font-size: 24px;
    margin-right: 8px;
    line-height: 1;
}

.whatsapp-text {
    white-space: nowrap;
    opacity: 0;
    width: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.whatsapp-float:hover .whatsapp-text {
    opacity: 1;
    width: auto;
    margin-left: 8px;
}

/* WhatsApp notification tooltip */
.whatsapp-float::before {
    content: "Need help? Chat with us!";
    position: absolute;
    bottom: 100%;
    right: 0;
    background: var(--gray-800);
    color: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease;
    pointer-events: none;
    margin-bottom: 8px;
}

.whatsapp-float::after {
    content: "";
    position: absolute;
    bottom: calc(100% - 8px);
    right: 20px;
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid var(--gray-800);
    opacity: 0;
    transition: all 0.3s ease;
    pointer-events: none;
}

.whatsapp-float.show-tooltip::before,
.whatsapp-float.show-tooltip::after {
    opacity: 1;
    transform: translateY(0);
}

@keyframes whatsappPulse {
    0% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }

    50% {
        box-shadow: 0 4px 25px rgba(37, 211, 102, 0.6);
    }

    100% {
        box-shadow: 0 4px 20px rgba(37, 211, 102, 0.4);
    }
}

@keyframes whatsappFloat {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-5px);
    }
}

@keyframes whatsappBounceIn {
    0% {
        transform: translateY(100px) scale(0.5);
        opacity: 0;
    }

    50% {
        transform: translateY(-10px) scale(1.1);
        opacity: 0.8;
    }

    100% {
        transform: translateY(0px) scale(1);
        opacity: 1;
    }
}

/* WhatsApp Button Responsive */
@media (max-width: 768px) {
    .whatsapp-float {
        bottom: 80px;
        right: 15px;
        padding: 15px;
        border-radius: 50%;
        width: 60px;
        height: 60px;
        justify-content: center;
        animation: whatsappPulse 2s infinite, whatsappFloat 4s ease-in-out infinite;
    }

    .whatsapp-float.show {
        animation: whatsappBounceIn 0.6s ease-out forwards, whatsappPulse 2s infinite 0.6s, whatsappFloat 4s ease-in-out infinite 0.6s;
    }

    .whatsapp-float:hover {
        transform: translateY(-4px) scale(1.1);
        animation-play-state: paused;
    }

    .whatsapp-float i {
        margin-right: 0;
        font-size: 28px;
    }

    .whatsapp-text {
        display: none;
    }

    .whatsapp-float:hover .whatsapp-text {
        display: none;
    }

    /* Mobile tooltip adjustments */
    .whatsapp-float::before {
        content: "Chat with us!";
        right: -80px;
        bottom: 50%;
        transform: translateY(50%);
        margin-bottom: 0;
        font-size: 11px;
        padding: 6px 10px;
    }

    .whatsapp-float::after {
        right: -12px;
        bottom: 50%;
        transform: translateY(50%);
        border-top: 6px solid transparent;
        border-bottom: 6px solid transparent;
        border-right: 6px solid var(--gray-800);
        border-left: none;
    }

    .whatsapp-float.show-tooltip::before {
        transform: translateY(50%);
    }

    .whatsapp-float.show-tooltip::after {
        transform: translateY(50%);
    }
}