/**
 * IntelliRealty Favorites CSS
 * IBEXMONT Design System
 */

:root {
    --ir-primary-blue: #0666E6;
    --ir-primary-blue-hover: #0558C7;
    --ir-danger: #DC3545;
    --ir-success: #28A745;
    --ir-gray-900: #212529;
    --ir-transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ====================================
   FAVORITE BUTTON
   ==================================== */
/* Hide favorite button for non-logged-in users */
body:not(.logged-in) .ir-property-favorite-btn {
    display: none !important;
}

.ir-property-favorite-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.95);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--ir-transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    z-index: 10;
    padding: 0;
    outline: none;
}

.ir-property-favorite-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
    background: white;
}

.ir-property-favorite-btn:focus {
    outline: 2px solid var(--ir-primary-blue);
    outline-offset: 2px;
}

.ir-property-favorite-btn.is-favorited {
    background: var(--ir-primary-blue);
}

.ir-property-favorite-btn.is-favorited:hover {
    background: var(--ir-primary-blue-hover);
}

.ir-property-favorite-btn .heart-icon {
    width: 22px;
    height: 22px;
    transition: transform var(--ir-transition);
    stroke: var(--ir-gray-900);
}

.ir-property-favorite-btn.is-favorited .heart-icon {
    transform: scale(1.2);
    stroke: white;
    fill: white;
}

.ir-property-favorite-btn .sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Animation on favorite */
@keyframes heartBeat {
    0%, 100% {
        transform: scale(1);
    }
    25% {
        transform: scale(1.3);
    }
    50% {
        transform: scale(1.1);
    }
}

.ir-property-favorite-btn.is-favorited .heart-icon {
    animation: heartBeat 0.5s ease;
}

/* ====================================
   TOAST NOTIFICATIONS - Using global ir-components.css
   ==================================== */
/* Base .ir-toast system defined in ir-components.css */

/* ====================================
   MERGE MODAL - Using global ir-components.css
   ==================================== */
/* Base .ir-modal, .ir-modal-overlay, .ir-modal-content defined in ir-components.css */

/* ====================================
   BUTTONS - Using global ir-components.css
   ==================================== */
/* Module-specific button overrides only if needed */

/* ====================================
   MOBILE RESPONSIVE
   ==================================== */
@media (max-width: 768px) {
    /* Toast and Modal responsive styles handled by ir-components.css */

    .ir-btn {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .ir-property-favorite-btn {
        width: 40px;
        height: 40px;
    }

    .ir-property-favorite-btn .heart-icon {
        width: 20px;
        height: 20px;
    }
}

/* Touch optimizations */
@media (hover: none) and (pointer: coarse) {
    .ir-property-favorite-btn {
        width: 48px;
        height: 48px;
    }
}
