/* FlipBookPro Custom Styles */

/* Custom animations and effects */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes flipPage {
    0% {
        transform: rotateY(0deg);
    }
    50% {
        transform: rotateY(-90deg);
    }
    100% {
        transform: rotateY(-180deg);
    }
}

.animate-fade-in-up {
    animation: fadeInUp 0.8s ease-out;
}

.animate-flip-page {
    animation: flipPage 0.6s ease-in-out;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Glassmorphism effect for modals */
.glass-effect {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* Page flip effect enhancements */
.flipbook-3d {
    transform-style: preserve-3d;
}

.page-shadow {
    box-shadow: 
        0 0 20px rgba(0, 0, 0, 0.1),
        0 0 40px rgba(0, 0, 0, 0.05),
        inset 0 0 1px rgba(0, 0, 0, 0.1);
}

/* Loading spinner animation */
@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.spinner {
    animation: spin 1s linear infinite;
}

/* Hover effects for interactive elements */
.interactive-element {
    transition: all 0.3s ease;
    cursor: pointer;
}

.interactive-element:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Custom gradient backgrounds */
.gradient-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-secondary {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.gradient-success {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

/* Typography enhancements */
.text-shadow {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Custom button styles */
.btn-gradient {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
    color: white;
    transition: all 0.3s ease;
}

.btn-gradient:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

/* Responsive design helpers */
@media (max-width: 768px) {
    .flipbook-container {
        padding: 1rem;
    }
    
    .page {
        width: 300px;
        height: 450px;
    }
    
    .hero-gradient h1 {
        font-size: 2.5rem;
    }
    
    .hero-gradient p {
        font-size: 1.125rem;
    }
}

@media (max-width: 480px) {
    .page {
        width: 280px;
        height: 420px;
    }
    
    .hero-gradient h1 {
        font-size: 2rem;
    }
    
    .controls {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .control-btn {
        width: 100%;
    }
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    .page {
        box-shadow: none;
        border: 1px solid #ddd;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .card-hover {
        border: 2px solid #000;
    }
    
    .btn-gradient {
        background: #000;
        border: 2px solid #000;
    }
    
    .btn-gradient:hover {
        background: #333;
    }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
    .animate-fade-in-up,
    .animate-flip-page,
    .card-hover,
    .interactive-element,
    .page {
        animation: none !important;
        transition: none !important;
    }
}

/* Dark mode support (for future enhancement) */
@media (prefers-color-scheme: dark) {
    /* Dark mode styles would go here */
}

/* Focus styles for accessibility */
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #4f46e5;
    outline-offset: 2px;
}

/* Skip link for accessibility */
.skip-link {
    position: absolute;
    top: -40px;
    left: 6px;
    background: #000;
    color: #fff;
    padding: 8px;
    text-decoration: none;
    border-radius: 4px;
    z-index: 1000;
}

.skip-link:focus {
    top: 6px;
}

/* Custom selection colors */
::selection {
    background-color: #667eea;
    color: white;
}

::-moz-selection {
    background-color: #667eea;
    color: white;
}