/*
Theme Name: Astra Child
Theme URI: https://fueldaddy.com.au
Description: Child theme for Astra with iPhone home screen fixes and optimizations
Author: Fuel Daddy
Template: astra
Version: 1.0.0
*/

/* iPhone Home Screen Layout Fix */
@media only screen and (max-width: 768px) {
    /* Fix viewport for iPhone home screen mode */
    html {
        height: 100%;
        height: -webkit-fill-available;
    }

    body {
        min-height: 100vh;
        min-height: -webkit-fill-available;
    }

    /* Fix for iPhone notch and safe areas */
    body {
        padding-top: env(safe-area-inset-top);
        padding-bottom: env(safe-area-inset-bottom);
        padding-left: env(safe-area-inset-left);
        padding-right: env(safe-area-inset-right);
    }

    /* Ensure header stays at top in standalone mode */
    .site-header {
        position: sticky;
        top: 0;
        z-index: 999;
    }

    /* Fix content area to use full available height */
    .site-content {
        min-height: calc(100vh - 60px); /* Adjust 60px to your header height */
    }
}

/* Standalone mode detection (when added to home screen) */
@media all and (display-mode: standalone) {
    /* Remove any top padding that causes layout issues */
    body {
        padding-top: 0;
    }

    /* Ensure proper spacing for notched devices */
    .site-header {
        padding-top: env(safe-area-inset-top);
    }
}
