/* Sitemap Generator Styles */

/* Statistics Cards */
.stat-card {
    text-align: center;
    padding: 1rem;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--bs-primary);
    display: block;
    margin-bottom: 0.25rem;
}

[data-bs-theme="dark"] .stat-value {
    color: #4dabf7;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--bs-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* URL List Table */
.table-responsive {
    border-radius: 0.375rem;
}

.table thead.sticky-top {
    position: sticky;
    top: 0;
    z-index: 10;
}

[data-bs-theme="dark"] .table thead.sticky-top {
    background-color: rgba(30, 34, 42, 0.98) !important;
}

.table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.02);
}

[data-bs-theme="dark"] .table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

/* URL Input Row */
.url-row {
    background-color: var(--bs-light);
    transition: all 0.2s ease;
}

[data-bs-theme="dark"] .url-row {
    background-color: rgba(30, 34, 42, 0.5);
}

/* Output Sitemap */
#outputSitemap {
    font-family: 'Courier New', Courier, monospace;
    font-size: 0.85rem;
    line-height: 1.5;
    background-color: var(--bs-light);
    color: var(--bs-body-color);
    resize: vertical;
}

[data-bs-theme="dark"] #outputSitemap {
    background-color: rgba(30, 34, 42, 0.8);
    color: #e1e5e9;
    border-color: rgba(255, 255, 255, 0.1);
}

/* Installation Section */
.installation-section {
    background-color: rgba(25, 135, 84, 0.05);
    border: 1px solid rgba(25, 135, 84, 0.2);
    border-radius: 0.375rem;
    padding: 1.5rem;
}

[data-bs-theme="dark"] .installation-section {
    background-color: rgba(25, 135, 84, 0.1);
    border-color: rgba(25, 135, 84, 0.2);
}

.installation-section ol {
    padding-left: 1.5rem;
}

.installation-section li {
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.installation-section ul {
    list-style-type: none;
    padding-left: 1rem;
}

.installation-section ul li:before {
    content: "→ ";
    color: var(--bs-success);
    font-weight: bold;
    margin-right: 0.5rem;
}

/* Best Practices List */
.best-practices-list {
    list-style: none;
    padding-left: 0;
}

.best-practices-list li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.75rem;
    line-height: 1.6;
}

.best-practices-list li:before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--bs-success);
    font-weight: bold;
}

/* Validation Result */
#validationResult .alert {
    border-radius: 0.375rem;
    margin-bottom: 0;
}

/* Filter SVG for buttons */
.filter-svg {
    filter: brightness(0) invert(1);
}

[data-bs-theme="dark"] .filter-svg {
    filter: none;
}

/* Collapse transition */
.collapse {
    transition: height 0.3s ease;
}

/* Scrollbar Styling */
.table-responsive::-webkit-scrollbar,
#outputSitemap::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.table-responsive::-webkit-scrollbar-track,
#outputSitemap::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.05);
    border-radius: 4px;
}

.table-responsive::-webkit-scrollbar-thumb,
#outputSitemap::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 4px;
}

.table-responsive::-webkit-scrollbar-thumb:hover,
#outputSitemap::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 0, 0, 0.3);
}

[data-bs-theme="dark"] .table-responsive::-webkit-scrollbar-track,
[data-bs-theme="dark"] #outputSitemap::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.05);
}

[data-bs-theme="dark"] .table-responsive::-webkit-scrollbar-thumb,
[data-bs-theme="dark"] #outputSitemap::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
}

[data-bs-theme="dark"] .table-responsive::-webkit-scrollbar-thumb:hover,
[data-bs-theme="dark"] #outputSitemap::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* Button Improvements */
.toolBtn {
    transition: all 0.2s ease;
    font-weight: 500;
}

.toolBtn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.toolBtn:active {
    transform: translateY(0);
}

/* Small text in table */
.table-sm td, .table-sm th {
    padding: 0.5rem 0.25rem;
    vertical-align: middle;
}

.table-sm input, .table-sm select {
    font-size: 0.875rem;
}

/* Responsive Table Actions */
@media (max-width: 767px) {
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .table-sm td, .table-sm th {
        padding: 0.4rem 0.2rem;
    }
    
    .stat-value {
        font-size: 1.5rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .installation-section {
        padding: 1rem;
    }
}

@media (max-width: 576px) {
    .table-sm {
        font-size: 0.8rem;
    }
    
    .table-sm td, .table-sm th {
        padding: 0.3rem 0.15rem;
    }
    
    .stat-value {
        font-size: 1.25rem;
    }
    
    .card-header h5 {
        font-size: 1rem;
    }
    
    .toolBtn {
        font-size: 0.875rem;
        padding: 0.5rem 0.75rem;
    }
}

/* Animation */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

#outputContainer {
    animation: fadeIn 0.3s ease;
}

/* Focus States */
.form-control:focus,
.form-select:focus {
    border-color: var(--bs-primary);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.15);
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    border-color: #4dabf7;
    box-shadow: 0 0 0 0.2rem rgba(77, 171, 247, 0.25);
}

/* Print Styles */
@media print {
    .toolBtn,
    .card:not(#outputContainer .card),
    .form-group:not(#outputContainer) {
        display: none !important;
    }
    
    #outputContainer {
        display: block !important;
    }
    
    #outputSitemap {
        border: 1px solid #000;
        background: white;
        color: black;
    }
}