/* Preview Page Styles */
body {
    margin: 0;
    padding: 0;
    background: #000;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    overflow: hidden;
}

.page-container {
    position: relative;
    width: 100vw;
    height: 100vh;
    max-width: 177.78vh; /* 16:9 aspect ratio = 16/9 * 100vh */
    max-height: 56.25vw;  /* 16:9 aspect ratio = 9/16 * 100vw */
    overflow: hidden;
    margin: auto;
    background-image: url('../BG Plain.jpg');
    background-size: 100% 100%;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    flex-direction: column;
}

/* Header */
.page-header {
    position: relative;
    z-index: 100;
    padding: 20px 40px;
    background: rgba(255, 255, 255, 0.9);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.logo-link {
    display: inline-block;
    transition: transform 0.3s ease;
}

.logo-link:hover {
    transform: scale(1.05);
}

.page-logo {
    height: 60px;
    width: auto;
}

/* Preview Wrapper */
.preview-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px; /* Reduced padding */
    min-height: 0;
    width: 100%;
}

/* Preview Container */
.preview-container {
    position: relative;
    max-width: 1200px;
    width: 90%;
    /* Use flex to fill available space */
    flex: 1;
    max-height: 600px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.2);
    overflow: hidden;
}

.preview-image {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Placeholder for Screenshot */
.placeholder-screen {
    text-align: center;
    padding: 60px;
    background: linear-gradient(135deg, #FFF5E4 0%, #FFE4E1 100%);
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.placeholder-screen h2 {
    color: #E63946;
    font-size: 32px;
    margin-bottom: 20px;
    font-weight: 700;
}

.placeholder-screen p {
    color: #666;
    font-size: 18px;
    margin-bottom: 30px;
}

.placeholder-icon {
    font-size: 120px;
    opacity: 0.3;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.1));
}

/* Screenshot Image (when provided) */
.preview-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Open Website Button */
.open-website-btn-container {
    display: flex;
    justify-content: center;
}

.open-website-btn {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 18px 40px;
    background: linear-gradient(to right, #FF6831, #F79A21);
    border: 3px solid #fff;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 5px 20px rgba(255, 104, 49, 0.4);
}

.open-website-btn:hover {
    transform: scale(1.05) translateY(-2px);
    box-shadow: 0 8px 30px rgba(255, 104, 49, 0.6);
}

.open-website-btn:active {
    transform: scale(0.98);
}

.open-website-btn .btn-icon {
    font-size: 28px;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.open-website-btn .btn-text {
    color: white;
    font-size: 18px;
    font-weight: 700;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    letter-spacing: 1px;
}

.open-website-btn svg {
    stroke: white;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

/* Footer */
.page-footer {
    position: relative;
    z-index: 100;
    width: 100%;
    min-height: 100px;
    background: #fae6cb;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px 0;
}

.footer-bg {
    display: none;
}

.footer-buttons {
    position: relative;
    bottom: auto;
    left: auto;
    transform: none;
    z-index: 10;
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 10px;
    flex-wrap: nowrap;
    width: 95%;
    max-width: 1400px;
    padding-right: 120px;
}

.footer-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: linear-gradient(to right, #FF6831, #F79A21);
    border: 2px solid #fff;
    border-radius: 50px;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 3px 12px rgba(255, 104, 49, 0.3);
    flex: 1;
    min-width: 0;
    height: auto;
}

.footer-btn-long {
    flex: 2;
}

.footer-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 20px rgba(255, 104, 49, 0.5);
}

.footer-btn:active {
    transform: scale(0.98);
}

.btn-icon {
    font-size: 20px;
    flex-shrink: 0;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.btn-text {
    color: white;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.1;
    text-align: left;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.3);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    word-break: break-word;
}

.mascot-right {
    position: absolute;
    right: 10px;
    bottom: 10px;
    height: 110%;
    width: auto;
    object-fit: contain;
    z-index: 5;
    pointer-events: none;
    filter: drop-shadow(-2px 2px 5px rgba(0,0,0,0.1));
}

/* Responsive */
@media (max-width: 1440px) {
    .preview-container {
        height: 500px;
    }

    .page-logo {
        height: 50px;
    }
}

@media (min-width: 1025px) and (max-width: 1366px) {
    .preview-container {
        width: 85%;
        height: 480px;
    }

    .footer-btn {
        padding: 10px 18px;
    }

    .btn-text {
        font-size: 10px;
    }

    .open-website-btn {
        padding: 15px 35px;
    }

    .open-website-btn .btn-text {
        font-size: 16px;
    }
}

@media (max-width: 1024px) {
    body, .page-container {
        height: auto !important;
        min-height: 100vh;
        overflow-y: auto !important;
        max-width: none !important;
        max-height: none !important;
        display: block !important;
    }

    .preview-wrapper {
        min-height: auto;
        padding: 20px;
    }

    .preview-container {
        height: 40vh;
        max-height: 400px;
    }
    
    .page-footer {
         /* Ensure footer isn't hidden */
         flex-wrap: wrap;
    }

    /* Small Header on Mobile */
    .page-header {
        padding: 10px 20px;
    }
    .page-logo {
        height: 40px;
    }
}
