/* ===========================================
   BIM CHECKER - INDEX PAGE STYLES
   Styles specific to the main index page
   =========================================== */

/* Index page specific body styling */
body {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Index page specific container width */
.page-container {
    max-width: 1200px !important;
}

/* Index page content padding - spacing from edges */
.content {
    padding: 60px 40px;
}

/* Index page header styling - more prominent */
.header {
    padding: 60px 30px !important;
}

.header h1 {
    font-size: 3em !important;
    margin-bottom: 15px !important;
}

.header p {
    font-size: 1.3em !important;
}

/* Tools Grid Section */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.tool-card {
    background: white;
    border: 3px solid #e9ecef;
    border-radius: 12px;
    padding: 30px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: block;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 24px rgba(102, 126, 234, 0.2);
    border-color: #667eea;
}

.tool-icon {
    font-size: 4em;
    margin-bottom: 20px;
}

.tool-title {
    font-size: 1.5em;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 15px;
}

.tool-description {
    color: #6c757d;
    line-height: 1.6;
    font-size: 1em;
    margin-bottom: 20px;
}

.tool-features {
    text-align: left;
    margin-top: 20px;
    padding-top: 20px;
    border-top: 2px solid #e9ecef;
}

.tool-features ul {
    list-style: none;
    padding: 0;
}

.tool-features li {
    padding: 5px 0;
    color: #495057;
    font-size: 0.9em;
}

.tool-features li:before {
    content: " ";
    color: #28a745;
    font-weight: bold;
    margin-right: 8px;
}

/* About Section */
.about-section {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 40px;
    margin-top: 40px;
    border: 2px solid #e9ecef;
}

.about-section h2 {
    color: #2d3748;
    font-size: 2em;
    margin-bottom: 20px;
    text-align: center;
}

.about-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 30px;
}

.about-item {
    text-align: center;
}

.about-icon {
    font-size: 2.5em;
    margin-bottom: 15px;
}

.about-title {
    font-size: 1.2em;
    font-weight: 600;
    color: #667eea;
    margin-bottom: 10px;
}

.about-text {
    color: #6c757d;
    line-height: 1.6;
}

/* Storage Section */
.storage-section {
    margin-bottom: 50px;
}

.section-title {
    font-size: 2em;
    color: #2d3748;
    margin-bottom: 10px;
    text-align: center;
}

.section-subtitle {
    text-align: center;
    color: #6c757d;
    margin-bottom: 30px;
    font-size: 1.1em;
}

.storage-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.storage-panel {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    min-height: 400px;
    display: flex;
    flex-direction: column;
}

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 2px solid #dee2e6;
}

.panel-header h3 {
    font-size: 1.3em;
    color: #2d3748;
    margin: 0;
}

.panel-actions {
    display: flex;
    gap: 8px;
}

.btn-icon {
    background: white;
    border: 2px solid #dee2e6;
    border-radius: 6px;
    padding: 6px 12px;
    cursor: pointer;
    font-size: 1.1em;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: #667eea;
    border-color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(102, 126, 234, 0.3);
}

.drop-zone {
    background: white;
    border: 3px dashed #cbd5e0;
    border-radius: 8px;
    padding: 40px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    margin-bottom: 15px;
}

.drop-zone:hover {
    border-color: #667eea;
    background: #f7fafc;
}

.drop-zone.drag-over {
    border-color: #667eea;
    background: #eef2ff;
    transform: scale(1.02);
}

.drop-icon {
    font-size: 3em;
    margin-bottom: 10px;
    opacity: 0.6;
}

.drop-zone p {
    margin: 5px 0;
    color: #4a5568;
}

.drop-hint {
    font-size: 0.9em;
    color: #a0aec0;
}

.file-tree {
    flex: 1;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    overflow-y: auto;
    min-height: 200px;
    max-height: 400px;
}

.file-tree:empty::before {
    content: "}�dn� soubory";
    color: #a0aec0;
    font-style: italic;
    display: block;
    text-align: center;
    padding: 20px;
}

.tree-folder {
    margin-bottom: 8px;
}

.tree-folder-header {
    display: flex;
    align-items: center;
    padding: 8px;
    cursor: pointer;
    border-radius: 6px;
    transition: background 0.2s;
    user-select: none;
}

.tree-folder-header:hover {
    background: #f7fafc;
}

.tree-folder-header.selected {
    background: #eef2ff;
    border: 2px solid #667eea;
}

.tree-folder-header.drag-over {
    background: #c3dafe;
    border: 2px dashed #667eea;
    box-shadow: 0 0 8px rgba(102, 126, 234, 0.3);
}

.folder-arrow {
    margin-right: 6px;
    font-size: 0.8em;
    color: #667eea;
    font-weight: bold;
    display: inline-block;
    width: 12px;
    text-align: center;
    cursor: pointer;
    user-select: none;
}

.folder-icon {
    margin-right: 8px;
    font-size: 1.2em;
}

.folder-name {
    flex: 1;
    font-weight: 600;
    color: #2d3748;
}

.folder-actions {
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.2s;
}

.tree-folder-header:hover .folder-actions {
    opacity: 1;
}

.action-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1em;
    padding: 2px 6px;
    border-radius: 4px;
    transition: background 0.2s;
}

.action-btn:hover {
    background: #e2e8f0;
}

.tree-folder-children {
    margin-left: 20px;
    display: none;
}

.tree-folder-children.expanded {
    display: block;
}

.tree-file {
    display: flex;
    align-items: center;
    padding: 6px 8px;
    margin: 4px 0;
    cursor: move;
    border-radius: 6px;
    transition: background 0.2s, opacity 0.2s;
}

.tree-file:hover {
    background: #f7fafc;
}

.tree-file.selected {
    background: #eef2ff;
    border: 2px solid #667eea;
}

.file-icon {
    margin-right: 8px;
    font-size: 1.1em;
}

.file-name {
    flex: 1;
    color: #4a5568;
    font-size: 0.95em;
}

.file-size {
    font-size: 0.85em;
    color: #a0aec0;
    margin-right: 8px;
}

.file-actions {
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.2s;
}

.tree-file:hover .file-actions {
    opacity: 1;
}

.storage-stats {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 2px solid #e9ecef;
    display: flex;
    justify-content: space-around;
    font-size: 0.9em;
    color: #6c757d;
}

.storage-stats strong {
    color: #667eea;
}

/* Context Menu */
.context-menu {
    position: fixed;
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    padding: 8px 0;
    z-index: 1000;
    min-width: 180px;
    display: none;
}

.context-menu.show {
    display: block;
}

.context-menu-item {
    padding: 10px 20px;
    cursor: pointer;
    transition: background 0.2s;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #4a5568;
}

.context-menu-item:hover {
    background: #f7fafc;
}

.context-menu-item.danger:hover {
    background: #fff5f5;
    color: #e53e3e;
}

/* Loading Overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-overlay.show {
    display: flex;
}

.loading-content {
    background: white;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
    max-width: 500px;
    width: 90%;
}

.loading-spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    width: 60px;
    height: 60px;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-text {
    font-size: 1.2em;
    color: #2d3748;
    margin-bottom: 10px;
    font-weight: 600;
}

.loading-subtext {
    color: #6c757d;
    font-size: 0.95em;
    margin-bottom: 20px;
}

.progress-bar-container {
    background: #e9ecef;
    border-radius: 10px;
    height: 20px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-bar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    height: 100%;
    width: 0%;
    transition: width 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.85em;
    font-weight: 600;
}

.file-info {
    font-size: 0.9em;
    color: #6c757d;
}

/* Footer Section */
.footer {
    text-align: center;
    padding: 30px;
    color: #6c757d;
    border-top: 2px solid #e9ecef;
    margin-top: 40px;
}

.footer p {
    margin-bottom: 10px;
}

.tech-stack {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.tech-badge {
    background: #667eea;
    color: white;
    padding: 6px 12px;
    border-radius: 15px;
    font-size: 0.85em;
    font-weight: 600;
}

/* Responsive */
@media (max-width: 768px) {
    .storage-grid {
        grid-template-columns: 1fr;
    }

    .tools-grid {
        grid-template-columns: 1fr;
    }

    .about-content {
        grid-template-columns: 1fr;
    }
}
