/* Pet Home AR Styles */

/* Landing Page Container Styles */
.landing8-container {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    z-index: 815;
    box-sizing: border-box;
}

.landing8-container * {
    box-sizing: inherit;
}

.landing8-background {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    z-index: -2;
}

.landing8-background-image {
    position: absolute;
    z-index: -1;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

.landing8-centered-container {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    overflow: auto;
    display: grid;
    justify-content: center;
    align-items: center;
}

.landing8-media-view {
    padding: 16px;
}

.landing8-view-loading {
    opacity: 0;
    transform: scale(0.97);
}

.landing8-view-transition {
    transition: .3s opacity, .3s transform;
}

.landing8-logo {
    display: block;
    max-width: 100%;
    height: auto;
    max-height: 168px;
    margin-bottom: 24px;
}

.landing8-attribution-logo {
    margin-top: auto;
    width: 220px;
    max-width: 100%;
}

.landing8-media-embed,
.landing8-media-image,
.landing8-media-video {
    width: 100%;
    min-width: 0;
    border-radius: 10px;
    overflow: hidden;
    margin: 0 auto;
    display: block;
}

.landing8-media-embed,
.landing8-media-image,
.landing8-media-video-container {
    grid-area: media;
}

.landing8-prompt-text {
    text-align: center;
    font-size: 24px;
    min-width: 0;
    z-index: 1;
}

.landing8-prompt-link {
    display: block;
    position: relative;
    width: 100%;
    line-height: 0;
}

.landing8-qr {
    background: #fff;
    border-radius: 16px;
    width: 220px;
    height: 220px;
    grid-area: qr;
    margin-bottom: 12px;
}

.landing8-prompt-link:link,
.landing8-prompt-link:visited,
.landing8-prompt-link:hover,
.landing8-prompt-link:active {
    color: inherit;
    text-decoration: none;
}

.landing8-prompt-link:hover .landing8-prompt-link-overflow-container {
    display: block;
}

.landing8-prompt-link:active .landing8-prompt-link-overflow-text {
    background-color: #000;
    color: #fff;
}

.landing8-prompt-link-placeholder {
    display: inline-block;
    overflow: hidden;
    width: 100%;
    white-space: nowrap;
    text-overflow: ellipsis;
    line-height: normal;
}

.landing8-prompt-link-overflow-container {
    display: none;
    position: absolute;
    top: -2px;
    left: -8px;
    width: 150%;
    max-width: calc(100% + 16px);
}

.landing8-prompt-link-overflow-text {
    display: inline-block;
    color: #000;
    background-color: #fff;
    padding: 2px 8px;
    border-radius: 8px;
    max-width: 100%;
    overflow: hidden;
    white-space: normal;
    word-break: break-all;
    line-height: normal;
}

.landing8-prompt-link-icon {
    display: inline-block;
    position: relative;
    top: 3px;
    margin-left: 4px;
}

.landing8-shadow {
    filter: drop-shadow(0px 0px 5px rgba(0, 0, 0, 0.8));
}

.landing8-media-image,
.landing8-media-video {
    max-width: calc((var(--landing8-media-width) / var(--landing8-media-height)) * var(--landing8-media-max-height));
    --landing8-media-max-height: 600px;
}

.landing8-media-view {
    display: grid;
    grid-template-columns: 1fr;
    grid-template-rows: auto auto auto;
    grid-gap: 24px;
    grid-template-areas: "media" "logo" "qr";
}

.landing8-prompt-section {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    grid-area: qr;
}

.landing8-logo-section {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    grid-area: logo;
    max-width: 300px;
    margin: 0 auto;
}

/* Pet Home Specific Styles */
.pethome-title {
    color: #ffffff;
    font-size: 28px;
    font-weight: bold;
    text-align: center;
    margin-bottom: 20px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.pethome-instructions {
    color: #ffffff;
    font-size: 18px;
    text-align: center;
    margin-bottom: 30px;
    padding: 0 20px;
    line-height: 1.5;
}

.pethome-ar-button {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 15px 30px;
    font-size: 18px;
    background: linear-gradient(45deg, #ff6b6b, #4ecdc4);
    color: white;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.3);
    transition: all 0.3s ease;
    font-weight: bold;
}

.pethome-ar-button:hover {
    background: linear-gradient(45deg, #ff5252, #26a69a);
    transform: translateX(-50%) translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 107, 0.4);
}

.pethome-ar-button:active {
    transform: translateX(-50%) translateY(0);
}

/* Responsive Design */
@media screen and (min-width: 768px) {
    .landing8-media-view .landing8-prompt-link-overflow-container,
    .landing8-model-viewer-info .landing8-prompt-link-overflow-container {
        max-width: 150%;
    }
    
    .landing8-media-view .landing8-prompt-text,
    .landing8-model-viewer-info .landing8-prompt-text {
        text-align: left;
    }
    
    .landing8-media-view .landing8-qr,
    .landing8-model-viewer-info .landing8-qr {
        margin-right: 24px;
        margin-bottom: 0;
    }
    
    .landing8-media-view .landing8-prompt-section,
    .landing8-model-viewer-info .landing8-prompt-section {
        flex-direction: row;
        align-items: flex-end;
    }
    
    .landing8-logo-section {
        align-items: flex-end;
        margin-right: 0;
    }
    
    .landing8-portrait-layout {
        grid-template-columns: 500px minmax(0, 500px);
        grid-template-rows: 1fr auto;
        grid-template-areas: "logo media" "qr media";
    }
    
    .landing8-portrait-layout .landing8-media-image,
    .landing8-portrait-layout .landing8-media-video {
        --landing8-media-max-height: 80vh;
    }
    
    .landing8-portrait-layout .landing8-logo-section {
        align-items: flex-start;
        margin-left: 0;
        justify-content: space-between;
    }
    
    .landing8-landscape-layout {
        min-width: 736px;
        width: 65vw;
        max-width: 1000px;
        grid-template-columns: minmax(500px, 1fr) minmax(0, 300px);
        grid-template-rows: auto auto;
        grid-template-areas: "media media" "qr logo";
    }
    
    .landing8-landscape-layout .landing8-media-image,
    .landing8-landscape-layout .landing8-media-video-element {
        max-height: 650px;
    }
    
    .landing8-landscape-layout .landing8-logo-section {
        align-items: flex-end;
        justify-content: space-between;
    }
}

/* Pet Home AR Specific Responsive Styles */
@media screen and (max-width: 767px) {
    .pethome-title {
        font-size: 24px;
        margin-bottom: 15px;
    }
    
    .pethome-instructions {
        font-size: 16px;
        margin-bottom: 20px;
        padding: 0 15px;
    }
    
    .pethome-ar-button {
        padding: 12px 24px;
        font-size: 16px;
        bottom: 15px;
    }
}

/* Dark theme support */
@media (prefers-color-scheme: dark) {
    .landing8-qr {
        background: #f0f0f0;
    }
    
    .landing8-prompt-link-overflow-text {
        background-color: #333;
        color: #fff;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .pethome-title {
        text-shadow: none;
        border: 2px solid #fff;
        padding: 10px;
        border-radius: 5px;
    }
    
    .pethome-ar-button {
        border: 2px solid #fff;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .landing8-view-transition {
        transition: none;
    }
    
    .pethome-ar-button {
        transition: none;
    }
    
    .pethome-ar-button:hover {
        transform: translateX(-50%);
    }
}
