/* ==============================================================================
   LĪMBŌ LIVING — APPLE iOS HIG 2026 NATIVE APP STYLING & INTERACTION SYSTEM
   Guidelines: Apple Human Interface Guidelines 2026 / Spring Physics & Micro-haptics
   ============================================================================== */

/* 1. Safe Area Insets Support (iOS Notch & Dynamic Island) */
:root {
    --ios-safe-top: env(safe-area-inset-top, 0px);
    --ios-safe-bottom: env(safe-area-inset-bottom, 0px);
    --ios-tab-bar-height: 64px;
}

/* 2. Apple Physics: Touch Damping & Spring Rebound */
.apple-touch-active,
button:active:not(:disabled),
a:active:not(:disabled),
.property-card:active,
.experience-card:active,
[data-apple-tap="true"]:active {
    transform: scale(0.965) !important;
    opacity: 0.90 !important;
    transition: transform 0.12s cubic-bezier(0.32, 0.72, 0, 1), opacity 0.12s ease !important;
}

/* Retorno elástico al soltar */
button,
a,
.property-card,
.experience-card,
.apple-tab-item,
[data-apple-tap="true"] {
    transition: transform 0.32s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
    -webkit-tap-highlight-color: transparent !important;
}

/* 3. Modo Standalone / App Descargada Específico */
.apple-app-mode {
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
    overscroll-behavior-y: contain;
}

.apple-app-mode input,
.apple-app-mode textarea,
.apple-app-mode select {
    -webkit-user-select: auto;
    user-select: auto;
}

/* Espaciado inferior para que el contenido no quede tapado por la barra de pestañas en móvil */
@media (max-width: 767px) {
    #app-content {
        padding-bottom: calc(var(--ios-tab-bar-height) + var(--ios-safe-bottom) + 16px) !important;
    }
    
    #global-footer {
        padding-bottom: calc(var(--ios-tab-bar-height) + var(--ios-safe-bottom) + 32px) !important;
    }
}

/* 4. Translucency Frosted Glassmorphism (Apple Material Blur) */
#apple-bottom-tab-bar {
    -webkit-backdrop-filter: blur(28px) saturate(180%);
    backdrop-filter: blur(28px) saturate(180%);
}

.apple-tab-item {
    outline: none !important;
    border: none !important;
}

.apple-tab-item:active .apple-tab-icon-wrapper {
    transform: scale(0.88);
    transition: transform 0.12s cubic-bezier(0.32, 0.72, 0, 1);
}

/* 5. Fluid Mobile Touch Target Standards (Apple 44pt Touch Targets) */
@media (max-width: 640px) {
    button, 
    .btn-action, 
    input[type="submit"], 
    select {
        min-height: 44px;
    }
}
