/* Custom Layout Styles for Bitte Setzen */

/* Smooth transitions for layout changes */
.layout-transition {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Custom grid animations */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(100%);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideOut {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(100%);
    }
}

/* Button animations */
@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

.slide-in {
    animation: slideIn 0.3s ease-in-out;
}

.slide-out {
    animation: slideOut 0.3s ease-in-out;
}

.fade-in {
    animation: fadeIn 0.3s ease-in-out;
}

.fade-out {
    animation: fadeOut 0.3s ease-in-out;
}

/* PDF panel close button effects */
button[data-action="click->layout#close"] {
    transition: all 0.2s ease-in-out;
}

button[data-action="click->layout#close"]:hover {
    transform: scale(1.1);
}

/* PDF panel restore button styles */
[data-layout-target="showPanelButton"] {
    transition: all 0.3s ease-in-out;
    opacity: 0.8;
}

[data-layout-target="showPanelButton"]:hover {
    opacity: 1;
    transform: translate(-2px, -50%);
}

/* Layout states - panel hidden */
.layout-panel-hidden [data-layout-target="leftSidebar"] {
    padding: 0.5rem;
}

.layout-panel-hidden [data-layout-target="mainContent"] {
    grid-column: span 4 / span 4;
}

.layout-panel-hidden [data-layout-target="rightPanel"] {
    display: none;
}

/* Book card hover effects */
.book-card {
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.book-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

/* Section item hover effects */
.section-item {
    transition: all 0.2s ease-in-out;
}

.section-item:hover {
    transform: translateX(4px);
}

/* Mobile responsive adjustments */
@media (max-width: 768px) {
    .mobile-hidden {
        display: none !important;
    }

    .mobile-full-width {
        width: 100% !important;
        margin: 0 !important;
    }

    /* Force single column on mobile */
    .responsive-grid {
        grid-template-columns: 1fr !important;
        gap: 1rem !important;
    }
}

/* Custom scrollbar for content areas */
.custom-scrollbar::-webkit-scrollbar {
    width: 6px;
}

.custom-scrollbar::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 3px;
}

.custom-scrollbar::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

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

/* Loading animations */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.loading-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }

    .print-break-before {
        page-break-before: always;
    }

    .print-break-after {
        page-break-after: always;
    }
}

/* Focus styles for accessibility */
.focus-ring:focus {
    outline: 2px solid transparent;
    outline-offset: 2px;
    box-shadow: 0 0 0 2px #3b82f6, 0 0 0 4px rgba(59, 130, 246, 0.1);
}

/* Dark mode support (future enhancement) */
@media (prefers-color-scheme: dark) {
    .dark-mode-support {
        color-scheme: dark;
    }
}