/* Desktop: Add subtle background so centered container stands out */
@media (min-width: 501px) {
    body {
        background-color: #f5f5f5;
    }
}

/* Desktop: Center the mobile experience with a max-width for better viewing */
.mobile-experience-container {
    padding: 0;
    margin: 0 auto;
    max-width: 500px;
    overflow-x: hidden;
    /* Ensure container fills parent height for proper ActionSheet positioning in preview mode */
    min-height: 100vh;
    background-color: white;
    box-shadow: 0 0 30px rgba(0, 0, 0, 0.15);
}

/* Mobile: Full width on actual mobile devices */
@media (max-width: 500px) {
    .mobile-experience-container {
        max-width: 100%;
        box-shadow: none;
    }
}

/* Remove any default padding from MudContainer when used with mobile experience */
.mobile-experience-container ::deep(.mud-container) {
    padding-left: 0 !important;
    padding-right: 0 !important;
}

/* Ensure images render edge-to-edge without gaps */
.mobile-experience-container img,
.mobile-experience-container ::deep(.branded-image),
.mobile-experience-container ::deep(.mud-image) {
    display: block;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0;
    padding: 0;
}

/* Remove centering wrapper for images in mobile experience - make them full width */
.mobile-experience-container ::deep(div[style*="display: flex"][style*="justify-content: center"]) {
    width: 100% !important;
    display: block !important;
    margin: 0;
    padding: 0;
}

/* Ensure image containers don't add padding */
.mobile-experience-container ::deep(div > img),
.mobile-experience-container ::deep(div > .branded-image) {
    width: 100% !important;
    max-width: 100% !important;
}

.mobile-experience-container .detail-component {
    margin-bottom: 1rem;
}

.mobile-experience-container .paragraph-component {
    padding: 1rem;
    font-size: 1rem;
    line-height: 1.6;
}

.mobile-experience-container .warranty-registration-component {
    margin: 1rem 0;
}

/* Hide desktop-only elements just in case they are rendered and not hidden by @if */
.mobile-experience-container .assistant-mode-badge,
.mobile-experience-container .troubleshooting-fab {
    display: none !important;
}

/* Fix MudBlazor button icon alignment */
.mud-button-label {
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* iOS Safari: disable MudBlazor ripple effect which expands beyond button bounds
   on touch due to overflow:hidden not clipping transformed children properly. */
.mud-ripple-effect {
    display: none !important;
}

/* Suppress native iOS touch highlight on all interactive elements */
button,
.mud-button-root,
.mud-fab,
.mud-chip,
[type='button'],
[type='submit'] {
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

