/* ==========================================
   TrustedHomeProtection - Pest Control LP
   style.css — Custom Styles & Responsiveness
   ========================================== */

/* --- Reset & Base --- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* --- Scrollbar Hide Utility --- */
.hide-scrollbar::-webkit-scrollbar {
    display: none;
}

.hide-scrollbar {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

/* --- Animations --- */
@keyframes slideUp {
    from {
        transform: translateY(100%);
    }
    to {
        transform: translateY(0);
    }
}

.animate-slideUp {
    animation: slideUp 0.3s ease-out forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeInUp {
    animation: fadeInUp 0.6s ease-out forwards;
}

/* --- FAQ Accordion --- */
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out, padding 0.3s ease;
}

.faq-answer.expanded {
    max-height: 500px;
    padding-bottom: 1.25rem;
}

.faq-icon {
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.faq-icon.expanded {
    transform: rotate(180deg);
    color: #1E429B;
}

/* --- Pest Grid Card Image --- */
.pest-card img {
    transition: transform 0.3s ease;
}

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

/* --- Footer Links --- */
.footer-link {
    transition: color 0.2s ease;
}

.footer-link:hover {
    text-decoration: underline;
}

/* --- Footer Bottom Flush --- */
#standalone-footer {
    margin-top: auto;
}

/* ==========================================
   RESPONSIVE OVERRIDES
   ========================================== */

/* --- Extra Small Devices (< 375px) --- */
@media (max-width: 374px) {
    .hero-title {
        font-size: 30px !important;
    }

    .hero-subtitle {
        font-size: 15px !important;
    }

    .hero-cta-phone {
        font-size: 22px !important;
    }

    .pest-grid {
        gap: 0.75rem !important;
    }

    .pest-card img {
        height: 8rem !important;
    }

    .pain-card {
        padding: 1.5rem !important;
    }

    .section-title {
        font-size: 26px !important;
    }

    .final-cta-title {
        font-size: 28px !important;
    }

    .faq-question {
        font-size: 14px !important;
        padding: 1rem !important;
    }
}

/* --- Small Devices (375px - 639px) --- */
@media (min-width: 375px) and (max-width: 639px) {
    .hero-title {
        font-size: 34px !important;
    }

    .hero-subtitle {
        font-size: 16px !important;
    }

    .pest-card img {
        height: 9rem !important;
    }

    .section-title {
        font-size: 28px !important;
    }
}

/* --- Medium Devices / Tablets (640px - 767px) --- */
@media (min-width: 640px) and (max-width: 767px) {
    .pest-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }

    .pest-card img {
        height: 10rem !important;
    }

    .pain-cards {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* --- Tablets / Small Laptops (768px - 1023px) --- */
@media (min-width: 768px) and (max-width: 1023px) {
    .pest-grid {
        grid-template-columns: repeat(4, 1fr) !important;
        gap: 1rem !important;
    }

    .pest-card img {
        height: 10rem !important;
    }
}

/* --- Desktop (1024px+) --- */
@media (min-width: 1024px) {
    .pest-card img {
        height: 11rem !important;
    }
}

/* --- Mobile Toast Position Fix --- */
@media (max-width: 767px) {
    #live-toast {
        left: 1rem;
        right: 1rem;
        max-width: none;
        bottom: 5.5rem;
    }
}

/* --- Mobile Footer Spacing --- */
@media (max-width: 767px) {
    .footer-logo {
        flex-direction: column !important;
        gap: 0.5rem !important;
        text-align: center;
    }

    .footer-links {
        flex-direction: column !important;
        gap: 0.5rem !important;
    }

    .footer-links .footer-separator {
        display: none;
    }
}

/* --- Print Styles --- */
@media print {
    #mobile-sticky,
    #live-toast,
    #urgency-banner {
        display: none !important;
    }

    body {
        padding-bottom: 0 !important;
    }
}
