/* Shared KiwisCAD footer — matches home.html */
:root {
    --footer-transition: 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

footer {
    padding: 0;
    background: var(--secondary, #1a4d2e);
    color: rgba(255, 255, 255, 0.65);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2.2fr 1fr 1fr 1fr 1fr;
    gap: 56px;
    padding: 64px 5% 56px;
}

.footer-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    margin-bottom: 24px;
    margin-left: 48px;
    line-height: 0;
    overflow: visible;
}

.footer-logo .logo-box {
    width: auto;
    height: 50px;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    overflow: visible;
}

.footer-logo .logo-box img {
    display: block;
    height: 50px;
    width: auto;
    max-width: none;
    object-fit: contain;
    object-position: left center;
}

.footer-desc {
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    line-height: 1.75;
    max-width: 290px;
    margin-bottom: 22px;
}

.footer-socials {
    display: flex;
    gap: 10px;
    margin-bottom: 22px;
}

.footer-contact-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 8px;
}

.footer-contact-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
    transition: var(--footer-transition);
}

.footer-contact-links a i {
    width: 14px;
    height: 14px;
    color: var(--primary, #27c96d);
    flex-shrink: 0;
}

.footer-contact-links a:hover {
    color: var(--primary, #27c96d);
}

.footer-socials a {
    width: 38px;
    height: 38px;
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(255, 255, 255, 0.6);
    transition: var(--footer-transition);
}

.footer-socials a:hover {
    color: white;
    transform: translateY(-3px);
}

.footer-socials a[aria-label*="Twitter"]:hover,
.footer-socials a[aria-label*="X"]:hover {
    background: #14171a;
}

.footer-socials a[aria-label*="GitHub"]:hover {
    background: #24292e;
}

.footer-socials a[aria-label*="LinkedIn"]:hover {
    background: #0a66c2;
}

.footer-socials a[aria-label*="YouTube"]:hover {
    background: #ff0000;
}

.footer-socials a[aria-label*="Discord"]:hover {
    background: #5865f2;
}

.footer-col h4 {
    font-family: var(--font-heading, 'Outfit', sans-serif);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 20px;
    color: white;
    display: flex;
    align-items: center;
    gap: 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.col-icon {
    width: 16px !important;
    height: 16px !important;
    color: var(--primary, #27c96d);
}

.footer-links {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 0;
}

.footer-links a {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.5);
    font-size: 14px;
    font-weight: 500;
    transition: var(--footer-transition);
    display: flex;
    align-items: center;
    gap: 8px;
}

.footer-links a i {
    width: 14px;
    height: 14px;
    color: rgba(255, 255, 255, 0.25);
    flex-shrink: 0;
    transition: color var(--footer-transition);
}

.footer-links a:hover {
    color: var(--primary, #27c96d);
    padding-left: 4px;
}

.footer-links a:hover i {
    color: var(--primary, #27c96d);
}

.footer-bottom {
    padding: 24px 5% 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.copy {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.35);
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: default;
    transition: color var(--footer-transition);
}

.copy:hover {
    color: #ffffff;
}

.footer-bottom-links {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.footer-bottom-links .dot {
    color: rgba(255, 255, 255, 0.35);
    font-size: 12px;
}

.footer-bottom-links a {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.35);
    text-decoration: none;
    transition: color var(--footer-transition);
    display: flex;
    align-items: center;
    gap: 5px;
}

.footer-bottom-links a i {
    width: 12px;
    height: 12px;
}

.footer-bottom-links a:hover {
    color: var(--primary, #27c96d);
}

@media (max-width: 1100px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 1024px) {
    .footer-grid {
        grid-template-columns: 2fr 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-logo {
        margin-left: 0;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

/* Kiwistron brand — below footer grid */
.kiwistron-strip {
    width: 100%;
    background: transparent;
    padding: 20px 5% 28px;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.kiwistron-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 32px;
}

.kiwistron-logo-wrap {
    display: flex;
    align-items: center;
    gap: 12px;
}

.kiwistron-logo-img {
    height: 48px;
    width: auto;
    object-fit: contain;
    border-radius: 10px;
    background: #000000;
    padding: 3px;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.kiwistron-info-box {
    display: flex;
    flex-direction: column;
}

.kiwistron-label {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 700;
    margin-bottom: 2px;
    line-height: 1;
}

.kiwistron-name {
    font-family: 'Outfit', sans-serif;
    font-weight: 700;
    font-size: 17px;
    color: #ffffff;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: color 0.2s ease;
    line-height: 1.2;
}

.kiwistron-name:hover {
    color: var(--primary, #27c96d);
}

.kiwistron-name .external-icon {
    width: 14px;
    height: 14px;
    opacity: 0.6;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.kiwistron-name:hover .external-icon {
    opacity: 1;
    transform: translate(1px, -1px);
}

.kiwistron-inner .divider-v {
    width: 1px;
    height: 42px;
    background: rgba(255, 255, 255, 0.15);
}

.kiwistron-tagline {
    display: flex;
    flex-direction: column;
}

.kiwistron-tagline .tagline-primary {
    font-family: 'Outfit', sans-serif;
    font-size: 15px;
    color: #ffffff;
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 2px;
}

.kiwistron-tagline .tagline-secondary {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 500;
    line-height: 1.2;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .kiwistron-inner {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
    
    .kiwistron-logo-wrap {
        flex-direction: column;
        gap: 8px;
    }
    
    .kiwistron-info-box {
        align-items: center;
    }
    
    .kiwistron-inner .divider-v {
        width: 60px;
        height: 1px;
        background: rgba(255, 255, 255, 0.15);
    }
    
    .kiwistron-tagline {
        align-items: center;
    }
}

/* --- Floating WhatsApp Button --- */
.whatsapp-float {
    position: fixed;
    bottom: 24px;
    left: 24px;
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, #25D366, #128C7E);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(37, 211, 102, 0.3);
    z-index: 99999; /* Ensure it is above headers, dialogs, etc. */
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.whatsapp-float:hover {
    transform: scale(1.08) translateY(-4px);
    box-shadow: 0 12px 28px rgba(37, 211, 102, 0.45);
    color: #ffffff; /* Keep white on hover */
}

.whatsapp-icon {
    width: 28px;
    height: 28px;
    fill: currentColor;
    transition: transform 0.3s ease;
    display: block;
}

.whatsapp-float:hover .whatsapp-icon {
    transform: rotate(8deg);
}

/* Slide-out Tooltip to the Right */
.whatsapp-tooltip {
    position: absolute;
    left: 68px;
    background: #18181c;
    color: #ffffff;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 13.5px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateX(-15px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.08);
    font-family: 'Outfit', 'DM Sans', sans-serif;
    pointer-events: none; /* Make tooltip non-interactive so it doesn't block hover */
}

.whatsapp-float:hover .whatsapp-tooltip {
    opacity: 1;
    visibility: visible;
    transform: translateX(0);
}

/* Soft ripple/pulse wave around the button */
.whatsapp-float::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: inherit;
    opacity: 0.35;
    z-index: -1;
    animation: whatsapp-pulse 2.2s cubic-bezier(0.1, 0.8, 0.3, 1) infinite;
}

@keyframes whatsapp-pulse {
    0% {
        transform: scale(1);
        opacity: 0.4;
    }
    100% {
        transform: scale(1.45);
        opacity: 0;
    }
}

/* Mobile responsive tuning */
@media (max-width: 768px) {
  /* Pages without scroll-to-top: tuck WhatsApp bottom-right away from content */
  body:not(:has(#scrollTop)) .whatsapp-float {
    bottom: 20px;
    right: 20px;
    left: auto;
    width: 44px;
    height: 44px;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
  }
  body:not(:has(#scrollTop)) .whatsapp-tooltip {
    right: 54px;
    left: auto;
    font-size: 12px;
    padding: 6px 12px;
  }
  /* Home (has scroll-to-top): keep WhatsApp bottom-left */
  body:has(#scrollTop) .whatsapp-float {
    bottom: 20px;
    left: 20px;
    right: auto;
    width: 44px;
    height: 44px;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.3);
  }
  body:has(#scrollTop) .whatsapp-tooltip {
    left: 54px;
    right: auto;
    font-size: 12px;
    padding: 6px 12px;
  }
  .whatsapp-icon {
    width: 22px;
    height: 22px;
  }
}
