/**
 * Sample Papers & User Stories Page Styles
 * Provides styling for video players and copy-protected PDF viewers
 */

/* Page Header */
.sample-papers-page .entry-header {
    text-align: center;
    margin-bottom: 3rem;
    padding: 2rem 0;
    border-bottom: 2px solid #e0e0e0;
}

.sample-papers-page .entry-title {
    font-size: 2.5rem;
    color: #333;
    margin: 0;
}

/* Section Styling */
.user-stories-section,
.sample-papers-section {
    margin-bottom: 4rem;
    padding: 2rem;
    background: #f9f9f9;
    border-radius: 8px;
}

.section-title {
    font-size: 2rem;
    color: #444;
    margin-bottom: 1.5rem;
    padding-bottom: 0.5rem;
    border-bottom: 3px solid #0073aa;
}

/* Videos Container */
.videos-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.video-wrapper {
    background: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
}

.video-wrapper h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

.video-container {
    position: relative;
    width: 100%;
    overflow: hidden;
    border-radius: 4px;
}

.video-wrapper video {
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 4px;
    background: #000;
    display: block;
}

/* Video Protection Overlay - Invisible but blocks right-click */
.video-protection-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* Disable video download and controls manipulation */
.video-wrapper video::-webkit-media-controls-enclosure {
    overflow: hidden;
}

.video-wrapper video::-webkit-media-controls-panel {
    width: calc(100% + 30px);
}

/* Hide download button in Chrome */
video::-internal-media-controls-download-button {
    display: none !important;
}

video::-webkit-media-controls-download-button {
    display: none !important;
}

/* Privacy Notice for Videos */
.privacy-notice {
    background: #e3f2fd;
    border-left: 4px solid #2196f3;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    border-radius: 4px;
    font-size: 1rem;
    color: #0d47a1;
    line-height: 1.6;
    font-style: italic;
}

/* Sample Papers Description */
.samples-description {
    font-size: 1.1rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    text-align: left;
}

.samples-description a {
    color: #0073aa;
    text-decoration: none;
    font-weight: 600;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
}

.samples-description a:hover {
    border-bottom-color: #0073aa;
}

/* Papers Notice */
.papers-notice {
    background: #fff3cd;
    border-left: 4px solid #ff5722;
    padding: 1rem 1.5rem;
    margin-bottom: 2rem;
    border-radius: 4px;
    font-size: 1rem;
    color: #856404;
    font-weight: 600;
}

/* Papers Container */
.papers-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.paper-viewer-wrapper {
    background: #fff;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
}

.paper-viewer-wrapper h3 {
    font-size: 1.3rem;
    margin-bottom: 1rem;
    color: #333;
}

/* PDF Viewer Container - Small Window with STRICT Copy Protection */
.pdf-viewer-container {
    position: relative;
    width: 100%;
    height: 500px;
    border: 2px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
    background: #525659;
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    -webkit-touch-callout: none !important;
}

.pdf-viewer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
    z-index: 1;
}

/* Overlay blocks text selection but allows scrollbar clicks */
.pdf-protection-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: calc(100% - 20px);
    height: 100%;
    background: transparent;
    z-index: 1000;
    cursor: default;
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    pointer-events: auto;
}

/* PDF Watermark - Always visible */
.pdf-watermark {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(255, 255, 255, 0.8);
    padding: 5px 12px;
    border-radius: 3px;
    font-size: 11px;
    color: #333;
    font-weight: 600;
    z-index: 1000;
    pointer-events: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    user-select: none;
}

/* Disable ALL text selection on PDF containers and children */
.pdf-viewer-container,
.pdf-viewer-container * {
    user-select: none !important;
    -webkit-user-select: none !important;
    -moz-user-select: none !important;
    -ms-user-select: none !important;
    -webkit-touch-callout: none !important;
}

/* Prevent drag and drop */
.pdf-viewer-container {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-drag: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .sample-papers-page .entry-title {
        font-size: 2rem;
    }
    
    .section-title {
        font-size: 1.5rem;
    }
    
    .videos-container,
    .papers-container {
        grid-template-columns: 1fr;
    }
    
    .pdf-viewer-container {
        height: 400px;
    }
}

@media (max-width: 480px) {
    .sample-papers-page .entry-title {
        font-size: 1.5rem;
    }
    
    .pdf-viewer-container {
        height: 350px;
    }
    
    .user-stories-section,
    .sample-papers-section {
        padding: 1rem;
    }
}

/* Print Protection */
@media print {
    .pdf-viewer-container,
    .video-wrapper video {
        display: none !important;
    }
    
    .pdf-viewer-container::after,
    .video-wrapper::after {
        content: "Content protected - printing not available";
        display: block;
        padding: 2rem;
        text-align: center;
        color: #999;
        font-style: italic;
    }
}
