﻿/* ---------- Base / resets (seen repeated in your HTML) ---------- */
* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
}

body {
    margin: 0;
    font-family: "Inter", sans-serif;
}

/* Use Merriweather when you want serif headings */
.font-serif {
    font-family: "Merriweather", serif;
}

/* Ensure consistent font family across all elements */
/*h1, h2, h3, h4, h5, h6, p, span, div, a, button, input, select, textarea, label, li, td, th {
    font-family: inherit;
}*/

/* ---------- FAQ <details> animations (from FAQs.html) ---------- */
details > summary {
    list-style: none;
}

    details > summary::-webkit-details-marker {
        display: none;
    }

details[open] summary ~ * {
    animation: slideDown 0.3s ease-in-out;
}

details[open] .fa-chevron-down {
    transform: rotate(180deg);
}

@keyframes slideDown {
    0% {
        opacity: 0;
        transform: translateY(-10px);
    }

    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Respect reduced-motion preferences (WCAG-friendly) */
@media (prefers-reduced-motion: reduce) {
    details[open] summary ~ * {
        animation: none !important;
    }

    * {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
    }
}

/* ---------- Product card hover (from ProductSearch.html) ---------- */
.product-card:hover {
    transform: translateY(-4px);
}

a {
    text-decoration: none;
}

    a.underline, a[class*="underline"] {
        text-decoration: underline;
    }

/* Visible keyboard focus (WCAG-friendly) */
:focus-visible {
    outline: 2px solid rgba(34, 197, 94, 0.7);
    outline-offset: 2px;
}

::-webkit-scrollbar {
    display: none;
}

.input-validation-error {
    border-color: #dc3545 !important;
    background: #f5e9ea !important;
}

.email-link {
    @apply text-blue-600 hover:text-blue-700 underline;
}

/* ---------- Tooltips for links ---------- */
[data-tooltip] {
    position: relative;
}

    [data-tooltip]::before {
        content: attr(data-tooltip);
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        padding: 0.5rem 0.75rem;
        background-color: #1f2937;
        color: white;
        font-size: 0.75rem;
        font-weight: 500;
        border-radius: 0.375rem;
        white-space: nowrap;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.2s ease-in-out, visibility 0.2s ease-in-out;
        z-index: 9999;
        pointer-events: none;
    }

    [data-tooltip]::after {
        content: '';
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        border: 6px solid transparent;
        border-top-color: #1f2937;
        margin-bottom: -12px;
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.2s ease-in-out, visibility 0.2s ease-in-out;
        z-index: 9999;
        pointer-events: none;
    }

    [data-tooltip]:hover::before,
    [data-tooltip]:hover::after,
    [data-tooltip]:focus::before,
    [data-tooltip]:focus::after {
        opacity: 1;
        visibility: visible;
    }

.back-to-top {
    cursor: pointer;
    position: fixed;
    bottom: 60px;
    right: 20px;
    display: none;
    margin-right: 10px;
    z-index: 5;
    border: solid 2px;
    padding: 5px 10px;
    color: #fff;
    border-radius: 50px;
    background: var(--Red-Red-200) !important;
    border-color: var(--Red-Red-200) !important;
}

    .back-to-top:hover {
        border-color: var(--main-bg-color-shaded) !important;
        color: #fff;
        background: var(--main-bg-color-shaded) !important;
    }