/* Quiz Iframe Styles - Only iframe and fullscreen button */

.chestionar-container {
    position: relative;
    width: 100%;
    height: auto;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    margin: 0 auto;
    max-width: 1200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    overscroll-behavior: none;
}

.chestionar-container iframe {
    width: 100%;
    height: 100%;
    min-height: 100vh;
    min-height: -webkit-fill-available;
    border: 0;
    margin: 0;
    padding: 0;
    overflow: auto;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: none;
}

/* Mobile iframe styles */
@media (max-width: 768px) {
    .chestionar-container {
        position: relative;
        width: 100%;
        height: auto;
        max-width: none;
        margin: 0;
        padding: 0;
        padding-bottom: env(safe-area-inset-bottom);
        overscroll-behavior: none;
    }

    .chestionar-container iframe {
        height: 100%;
        min-height: 100vh;
        min-height: -webkit-fill-available;
        padding-bottom: env(safe-area-inset-bottom);
    }
}

/* iOS specific fixes */
@supports (-webkit-touch-callout: none) {
    .chestionar-container {
        position: relative;
        height: auto;
        min-height: -webkit-fill-available;
        padding-bottom: env(safe-area-inset-bottom);
        overscroll-behavior: auto;
    }

    .chestionar-container iframe {
        height: 100%;
        min-height: -webkit-fill-available;
        padding-bottom: env(safe-area-inset-bottom);
    }

    /* Prevenim scroll-ul pe body când suntem în fullscreen */
    body.is-fullscreen {
        position: fixed;
        width: 100%;
        height: 100%;
        overflow: hidden;
    }
}

/* Fullscreen mode */
.chestionar-container.fullscreen {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100% !important;
    min-height: 100vh !important;
    min-height: -webkit-fill-available !important;
    max-width: 100vw !important;
    margin: 0 !important;
    padding: 0 !important;
    z-index: 999999 !important;
    background: #ffffff !important;
    padding-top: env(safe-area-inset-top) !important;
    padding-bottom: env(safe-area-inset-bottom) !important;
    overscroll-behavior: none !important; /* Dezactivăm overscroll în fullscreen */
    touch-action: none !important; /* Dezactivăm scroll-ul natural în fullscreen */
}

.chestionar-container.fullscreen iframe {
    height: 100% !important;
    min-height: 100vh !important;
    min-height: -webkit-fill-available !important;
    padding-top: env(safe-area-inset-top) !important;
    padding-bottom: env(safe-area-inset-bottom) !important;
}

/* Fullscreen button */
.fullscreen-btn {
    position: absolute;
    top: max(8px, env(safe-area-inset-top));
    right: max(8px, env(safe-area-inset-right));
    background: rgba(0, 0, 0, 0.4);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 8px 12px;
    cursor: pointer;
    z-index: 1000;
    font-size: 13px;
    font-weight: 500;
    transition: all 0.2s ease;
    opacity: 0;
    visibility: hidden;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    min-height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-tap-highlight-color: transparent;
}

.fullscreen-btn.loaded {
    opacity: 0.7;
    visibility: visible;
}

.fullscreen-btn:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.6);
}

/* Mobile fullscreen button */
@media (max-width: 768px) {
    .fullscreen-btn {
        top: max(6px, env(safe-area-inset-top));
        right: max(6px, env(safe-area-inset-right));
        padding: 10px 14px;
        font-size: 12px;
        min-height: 40px;
    }
} 