/* 
 * Spiff Cleaning - Custom Styles
 * Tailwind CSS is loaded via CDN in functions.php
 * This file contains custom styles that complement Tailwind
 */

/* ===== CSS Variables (Design Tokens) ===== */
:root {
    /* Colors */
    --color-black-primary: #0A0A0A;
    --color-black-soft: #1A1A1A;
    --color-coral: #F28B82;
    --color-coral-light: #FAD4D1;
    --color-coral-dark: #E07B73;
    --color-off-white: #FAFAFA;
    --color-white: #FFFFFF;
    --color-gray-100: #F3F4F6;
    --color-gray-200: #E5E7EB;
    --color-gray-400: #9CA3AF;
    --color-gray-500: #6B7280;
    --color-gray-600: #4B5563;

    /* Typography */
    --font-display: 'Plus Jakarta Sans', sans-serif;
    --font-body: 'DM Sans', sans-serif;

    /* Spacing */
    --spacing-base: 1rem;

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-base: 300ms ease;
    --transition-slow: 500ms ease;

    /* Border Radius */
    --radius-sm: 0.5rem;
    --radius-md: 0.75rem;
    --radius-lg: 1rem;
    --radius-xl: 1.5rem;
    --radius-2xl: 2rem;
    --radius-full: 9999px;
}

/* ===== Global Styles ===== */
html {
    scroll-behavior: smooth;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Focus States for Accessibility */
*:focus-visible {
    outline: 2px solid var(--color-coral);
    outline-offset: 2px;
}

/* ===== Animations ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Animation Classes */
.animate-fade-in {
    animation: fadeIn 0.6s ease forwards;
}

.animate-slide-up {
    animation: slideUp 0.6s ease forwards;
}

.animate-slide-up-delay {
    animation: slideUp 0.6s ease 0.15s forwards;
    opacity: 0;
}

.animate-slide-up-delay-2 {
    animation: slideUp 0.6s ease 0.3s forwards;
    opacity: 0;
}

.animate-slide-down {
    animation: slideDown 0.3s ease forwards;
}

/* ===== Custom Components ===== */

/* Hide scrollbar but allow scrolling */
.scrollbar-hide {
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
    display: none;
}

/* Button hover effects */
.btn-hover-lift {
    transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.btn-hover-lift:hover {
    transform: translateY(-2px);
}

/* Card hover effects */
.card-hover {
    transition: transform var(--transition-base), box-shadow var(--transition-base), border-color var(--transition-base);
}

.card-hover:hover {
    transform: translateY(-4px);
}

/* Link underline animation */
.link-underline {
    position: relative;
}

.link-underline::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--color-coral);
    transition: width var(--transition-base);
}

.link-underline:hover::after {
    width: 100%;
}

/* ===== Form Styles ===== */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
}

/* Custom checkbox styling */
input[type="checkbox"] {
    accent-color: var(--color-coral);
}

/* File input styling */
input[type="file"]::file-selector-button {
    cursor: pointer;
}

/* ===== FAQ Accordion ===== */
.faq-toggle[aria-expanded="true"] .faq-icon {
    transform: rotate(180deg);
}

.faq-content {
    display: none;
}

.faq-content:not(.hidden) {
    display: block;
}

/* ===== Mobile Menu Animation ===== */
#mobile-menu {
    transition: max-height var(--transition-base), opacity var(--transition-base);
}

#mobile-menu.hidden {
    max-height: 0;
    overflow: hidden;
    display: none;
}

/* ===== Loading States ===== */
.loading {
    position: relative;
    pointer-events: none;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid transparent;
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* ===== Image Placeholders ===== */
.img-placeholder {
    background: linear-gradient(135deg, var(--color-gray-100) 0%, var(--color-gray-200) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ===== Print Styles ===== */
@media print {
    header,
    footer,
    .fixed {
        display: none !important;
    }

    main {
        padding-top: 0 !important;
    }

    a[href]::after {
        content: " (" attr(href) ")";
    }
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    html {
        scroll-behavior: auto;
    }
}

/* ===== High Contrast Mode ===== */
@media (prefers-contrast: high) {
    :root {
        --color-coral: #E05A4F;
        --color-gray-600: #333333;
    }
}

