/* Byte Portfolio Frontend Styles */

.byte-portfolio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin: 30px 0;
}

.byte-portfolio-item {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.byte-portfolio-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.15);
}


.byte-portfolio-content {
    padding: 20px;
}

.byte-portfolio-title {
    font-size: 1.5em;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #333;
}

.byte-portfolio-title a {
    color: inherit;
    text-decoration: none;
}

.byte-portfolio-title a:hover {
    color: #0073aa;
}

.byte-portfolio-excerpt {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
}

.byte-portfolio-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 15px;
}

.byte-portfolio-meta-item {
    background: #f5f5f5;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 0.9em;
    color: #555;
}

.byte-portfolio-meta-item strong {
    color: #333;
}

.byte-portfolio-categories {
    margin-bottom: 15px;
}

.byte-portfolio-category {
    display: inline-block;
    background: #000080;
    color: #fff;
    padding: 10px;
    border-radius: 12px;
    font-size: 0.8em;
    margin-right: 5px;
    margin-bottom: 5px;
    text-decoration: none;
}

.byte-portfolio-category:hover {
    background: #000080;
    color: #fff;
}

.byte-portfolio-tags {
    margin-bottom: 15px;
}

.byte-portfolio-tag {
    display: inline-block;
    background: #e9ecef;
    color: #495057;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 0.75em;
    margin-right: 5px;
    margin-bottom: 5px;
    text-decoration: none;
}

.byte-portfolio-tag:hover {
    background: #dee2e6;
    color: #495057;
}

.byte-portfolio-services {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 5px;
    margin-top: 15px;
}

.byte-portfolio-services h4 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 1em;
}

.byte-portfolio-services p {
    margin: 0;
    color: #666;
    line-height: 1.5;
}

/* Portfolio Single Page Styles */
.portfolio-single {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.portfolio-single-header {
    text-align: center;
    margin-bottom: 30px;
}

.portfolio-single-title {
    font-size: 2.5em;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: #333;
}

.portfolio-single-meta {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 30px;
}

.portfolio-single-meta-item {
    text-align: center;
}

.portfolio-single-meta-label {
    font-size: 0.9em;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 5px;
}

.portfolio-single-meta-value {
    font-size: 1.1em;
    font-weight: 600;
    color: #333;
}

.portfolio-single-image {
    width: 100%;
    max-width: 600px;
    height: auto;
    border-radius: 8px;
    margin: 0 auto 30px;
    display: block;
}

.portfolio-single-content {
    line-height: 1.8;
    color: #444;
    margin-bottom: 30px;
}

.portfolio-single-categories,
.portfolio-single-tags {
    margin-bottom: 20px;
}

.portfolio-single-categories h3,
.portfolio-single-tags h3 {
    font-size: 1.2em;
    margin: 0 0 10px 0;
    color: #333;
}

.portfolio-single-services {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 8px;
    margin-top: 30px;
}

.portfolio-single-services h3 {
    margin: 0 0 15px 0;
    color: #333;
    font-size: 1.3em;
}

.portfolio-single-services p {
    margin: 0;
    line-height: 1.6;
    color: #555;
}

/* Portfolio Archive Styles */
.portfolio-archive-header {
    text-align: center;
    margin-bottom: 40px;
}

.portfolio-archive-title {
    font-size: 2.5em;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: #333;
}

.portfolio-archive-description {
    font-size: 1.1em;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

.portfolio-filters {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 40px;
}

.portfolio-filter-button {
    background: #fff;
    border: 2px solid #0073aa;
    color: #0073aa;
    padding: 10px 20px;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
}

.portfolio-filter-button:hover,
.portfolio-filter-button.active {
    background: #0073aa;
    color: #fff;
}

/* Category Archive Styles */
.portfolio-category-header {
    text-align: center;
    margin-bottom: 40px;
}

.portfolio-category-image {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 20px;
    display: block;
}

.portfolio-category-title {
    font-size: 2.5em;
    font-weight: 700;
    margin: 0 0 15px 0;
    color: #333;
}

.portfolio-category-description {
    font-size: 1.1em;
    color: #666;
    max-width: 600px;
    margin: 0 auto;
}

/* Responsive Design */
@media (max-width: 768px) {
    .portfolio-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .portfolio-single-title,
    .portfolio-archive-title,
    .portfolio-category-title {
        font-size: 2em;
    }
    
    .portfolio-single-meta {
        flex-direction: column;
        gap: 15px;
    }
    
    .portfolio-filters {
        flex-direction: column;
        align-items: center;
    }
    
    .portfolio-filter-button {
        width: 200px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .portfolio-content {
        padding: 15px;
    }
    
    .portfolio-title {
        font-size: 1.3em;
    }
    
    .portfolio-single {
        padding: 15px;
    }
    
    .portfolio-single-title,
    .portfolio-archive-title,
    .portfolio-category-title {
        font-size: 1.8em;
    }
}

/* Loading States */
.portfolio-loading {
    text-align: center;
    padding: 40px;
    color: #666;
}

.portfolio-loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

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

/* No Results */
.portfolio-no-results {
    text-align: center;
    padding: 60px 20px;
    color: #666;
}

.portfolio-no-results h3 {
    font-size: 1.5em;
    margin: 0 0 15px 0;
    color: #333;
}

.portfolio-no-results p {
    font-size: 1.1em;
    margin: 0;
}

/* Byte Portfolio Shortcode Styles */
.byte-portfolio-shortcode {
    margin: 30px 0;
}

/* Filter Bar Styles */
.byte-portfolio-filter-bar {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 30px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.byte-portfolio-filter-container {
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: center;
    flex-wrap: nowrap;
}

.byte-portfolio-filter-container select {
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    background: #fff;
    font-size: 14px;
    min-width: 150px;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.byte-portfolio-filter-container select:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 2px rgba(0, 115, 170, 0.2);
}

.byte-portfolio-filter-reset {
    background: rgb(0, 0, 128);
    color: #fff;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 38px;
    line-height: 1;
}

.byte-portfolio-filter-reset:hover {
    background: rgb(0, 0, 128);
}

.byte-portfolio-filter-reset:disabled {
    background: #adb5bd;
    color: #6c757d;
    cursor: not-allowed;
    opacity: 0.6;
}

/* Loading state */
#byte-portfolio-ajax-content.loading {
    opacity: 0.6;
    pointer-events: none;
    position: relative;
}

#byte-portfolio-ajax-content.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007cba;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1000;
}

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

/* Error messages */
.byte-portfolio-error {
    text-align: center;
    padding: 40px 20px;
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    margin: 20px 0;
}

.byte-portfolio-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    margin: 20px 0;
}

/* Grid Container */
.byte-portfolio-grid-container {
    position: relative;
}

/* Enhanced Grid Styles */
.byte-portfolio-grid {
    display: grid;
    gap: 30px;
    margin: 30px 0;
}

/* Responsive Grid Layouts */
.byte-portfolio-grid .byte-portfolio-item.mobile {
    grid-column: span 1;
}

.byte-portfolio-grid .byte-portfolio-item.tablet {
    grid-column: span 1;
}

.byte-portfolio-grid .byte-portfolio-item.desktop {
    grid-column: span 1;
}

/* Mobile: 1 per row */
@media (max-width: 767px) {
    .byte-portfolio-grid {
        grid-template-columns: 1fr;
    }
    
    .byte-portfolio-filter-container {
        flex-direction: column;
        align-items: stretch;
    }
    
    .byte-portfolio-filter-container select {
        min-width: auto;
    }
    
    .byte-portfolio-filter-container.mobile {
        flex-direction: column;
    }
}

/* Tablet: 2 per row */
@media (min-width: 768px) and (max-width: 1023px) {
    .byte-portfolio-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Desktop: 4 per row */
@media (min-width: 1024px) {
    .byte-portfolio-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Enhanced Portfolio Item Styles */
.byte-portfolio-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.byte-portfolio-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
    border-color: #0073aa;
}

.byte-portfolio-item.hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.12);
}

/* Image Container */
.byte-portfolio-image-container {
    width: 100%;
    height: auto;
    padding: 20px 0;
    overflow: hidden;
    position: relative;
    background: #f8f9fa;
}

.byte-portfolio-image {
    width: 70%;
    height: 100%;
    object-fit: contain;
    margin: 0 auto;
    display: block;
    transition: transform 0.3s ease;
}

.byte-portfolio-item:hover .byte-portfolio-image {
    transform: scale(1.05);
}

/* Content Styles */
.byte-portfolio-content {
    padding: 20px;
    text-align: center;
}

.byte-portfolio-title {
    font-size: 1.3em;
    font-weight: 600;
    margin: 0 0 10px 0;
    color: #333;
    line-height: 1.3;
}



.byte-portfolio-university {
    font-size: 0.95em;
    color: #0073aa;
    font-weight: 500;
    margin-bottom: 8px;
}

.byte-portfolio-department {
    font-size: 0.9em;
    color: #666;
    margin-bottom: 10px;
}

.byte-portfolio-categories {
    margin-bottom: 10px;
}

.byte-portfolio-category {
    display: inline-block;
    background: #000080;
    color: #fff;
    padding: 3px 8px;
    border-radius: 12px;
    font-size: 0.75em;
    margin: 2px;
    text-decoration: none;
    transition: background-color 0.3s ease;
}

.byte-portfolio-category:hover {
    background: #000080;
    color: #fff;
}

.byte-portfolio-services {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    margin-top: 15px;
    text-align: left;
}



.byte-portfolio-services p {
    margin: 0;
    color: #666;
    line-height: 1.5;
    font-size: 0.85em;
    text-align: center;
}

/* Pagination Styles */
.byte-portfolio-pagination {
    margin-top: 40px;
    text-align: center;
}

.byte-portfolio-pagination ul {
    display: inline-flex;
    list-style: none;
    margin: 0;
    padding: 0;
    align-items: center;
    gap: 5px;
}

.byte-portfolio-pagination li {
    margin: 0;
    display: flex;
    align-items: center;
}

.byte-portfolio-pagination .page-numbers {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 10px 15px;
    margin: 0;
    border: 1px solid #ddd;
    border-radius: 6px;
    text-decoration: none;
    color: #333;
    background: #fff;
    transition: all 0.3s ease;
    min-height: 44px;
    min-width: 44px;
    box-sizing: border-box;
}

.byte-portfolio-pagination .page-numbers.current {
    background: #0073aa;
    color: #fff;
    border-color: #0073aa;
    font-weight: bold;
}

.byte-portfolio-pagination .page-numbers.dots {
    background: #f8f9fa;
    color: #6c757d;
    border-color: #dee2e6;
}

.byte-portfolio-pagination .prev,
.byte-portfolio-pagination .next {
    font-weight: 600;
    min-width: auto;
}

/* Loading States */
.byte-portfolio-loading {
    text-align: center;
    padding: 40px;
    color: #666;
    font-style: italic;
}

.byte-portfolio-loading::after {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #0073aa;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-left: 10px;
}

/* Error States */
.byte-portfolio-error {
    text-align: center;
    padding: 40px;
    color: #dc3545;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
}

/* Filter Bar Mobile */
@media (max-width: 767px) {
    .byte-portfolio-filter-container {
        flex-direction: column;
        gap: 10px;
        flex-wrap: wrap;
    }
    
    .byte-portfolio-filter-container.mobile {
        flex-direction: column;
        gap: 10px;
    }
}

/* Accessibility */
.byte-portfolio-item:focus {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

.byte-portfolio-filter-container select:focus {
    outline: 2px solid #0073aa;
    outline-offset: 2px;
}

/* High Contrast Mode */
@media (prefers-contrast: high) {
    .byte-portfolio-item {
        border-width: 2px;
    }
    
    .byte-portfolio-filter-container select {
        border-width: 2px;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    .byte-portfolio-item,
    .byte-portfolio-image,
    .byte-portfolio-filter-container select,
    .byte-portfolio-pagination .page-numbers {
        transition: none;
    }
    
    .byte-portfolio-item:hover {
        transform: none;
    }
} 