/* Custom styles for Ośrodek MIRiOLA */

/* Global prefers-reduced-motion override */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        transition-duration: 0.01ms !important;
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
    }
}

/* Global focus visible indicator for WCAG 2.4.7 compliance */
:focus-visible {
    outline: 2px solid #001e40 !important;
    outline-offset: 2px !important;
}

/* Ensure smooth scrolling & prevent horizontal swaying on mobile devices */
html {
    scroll-behavior: smooth;
    overflow-x: hidden !important;
    max-width: 100%;
    width: 100%;
}

body {
    overflow-x: hidden !important;
    max-width: 100%;
    width: 100%;
    position: relative;
}

/* Ambient shadow with Deep Sea Blue tint (6% opacity) as per DESIGN.md */
.ambient-shadow {
    box-shadow: 0 10px 20px -5px rgba(0, 30, 64, 0.06), 0 4px 6px -2px rgba(0, 30, 64, 0.02);
}

/* Premium Card Transitions */
.room-card {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.5s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.5s ease;
}

/* Zoom effect on hover for Room Card Images */
.room-image {
    transition: transform 400ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* Navigation Links underline effect */
.nav-underline {
    position: relative;
}
.nav-underline::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 2px;
    bottom: -4px;
    left: 0;
    background-color: #001e40;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 180ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* Accordion transition for FAQ */
.faq-content {
    transition: grid-template-rows 250ms cubic-bezier(0.16, 1, 0.3, 1);
}

/* Spring-like Micro-interactions for buttons */
.btn-animate {
    transition: transform 200ms cubic-bezier(0.34, 1.56, 0.64, 1), background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.btn-animate:active {
    transform: scale(0.97);
    transition-duration: 80ms;
}

/* Gated hover effects for precise pointer devices only */
@media (hover: hover) and (pointer: fine) {
    .room-card:hover {
        transform: translateY(-8px);
        border-color: #001e40;
        box-shadow: 0 24px 38px -10px rgba(0, 30, 64, 0.12), 0 8px 16px -6px rgba(0, 30, 64, 0.04);
    }

    .room-card:hover .room-image {
        transform: scale(1.04);
    }

    .nav-underline:hover::after {
        transform: scaleX(1);
    }

    .btn-animate:hover {
        transform: scale(1.03);
    }
}

/* Map frame rendering */
.map-placeholder iframe {
    transition: filter 0.6s ease, opacity 0.6s ease;
}

/* Used on 4 horizontal scroll strips but never defined anywhere, so scrollbars
   stayed visible. See REVIEW.md M-33. */
.scrollbar-none {
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.scrollbar-none::-webkit-scrollbar {
    display: none;
}

/* Custom subtle slim scrollbar for modals */
.modal-scrollbar {
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 30, 64, 0.2) transparent;
}
.modal-scrollbar::-webkit-scrollbar {
    width: 6px;
}
.modal-scrollbar::-webkit-scrollbar-track {
    background: transparent;
}
.modal-scrollbar::-webkit-scrollbar-thumb {
    background: rgba(0, 30, 64, 0.2);
    border-radius: 9999px;
}
.modal-scrollbar::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 30, 64, 0.4);
}

/* Social Media Badges */
.social-badge-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.375rem;
    padding: 0.4rem 0.8rem;
    border-radius: 0.75rem;
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1rem;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    flex-shrink: 0;
    text-decoration: none;
}
.social-badge-btn:hover {
    transform: translateY(-2px);
}
@media (max-width: 640px) {
    .social-badge-btn {
        width: 2.125rem;
        height: 2.125rem;
        padding: 0;
    }
    .social-badge-btn .social-text {
        display: none !important;
    }
}

/* Frameless Header Phone Link */
.header-phone-link {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 700;
    color: #001e40;
    margin-right: 0.5rem;
    text-decoration: none;
    transition: color 0.2s ease;
    white-space: nowrap;
}
.header-phone-link .material-symbols-outlined {
    color: #f75555;
    font-size: 1.125rem;
}
.header-phone-link:hover {
    color: #f75555;
}
@media (max-width: 640px) {
    .header-phone-link {
        display: none !important;
    }
}

