* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    min-height: 100%;
    overflow-x: hidden;
    max-width: 100%;
}

body {
    font-family: 'Funnel Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background-color: #1a1a1a;
    background-image: url('../Images/war-6520667_1920.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    padding: 0;
    margin: 0;
    position: relative;
    overflow-x: hidden;
    max-width: 100%;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.95) 0%, rgba(45, 45, 45, 0.95) 100%);
    z-index: -1;
}

/* Fix background glitch on mobile */
@media (max-width: 768px) {
    html {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    }

    body {
        background-attachment: scroll;
        background-image: none;
    }

    body::before {
        position: absolute;
        background: linear-gradient(135deg, rgba(26, 26, 26, 0.95) 0%, rgba(45, 45, 45, 0.95) 100%);
    }
}

/* Ensure desktop has subtle background */
@media (min-width: 769px) {
    body {
        background-image: url('../Images/war-6520667_1920.png');
        background-attachment: fixed;
    }

    body::before {
        position: fixed;
        background: linear-gradient(135deg, rgba(26, 26, 26, 0.95) 0%, rgba(45, 45, 45, 0.95) 100%);
    }
}

.container {
    width: 100%;
    max-width: 1600px;
    margin: 0 auto;
    padding: 20px;
    overflow-x: hidden;
}

/* Override container max-width when it contains stats-container */
.container:has(.stats-container) {
    max-width: 2500px !important;
}

/* Navbar */
.navbar {
    background-color: #1a1a1a;
    border-bottom: 2px solid #dc3545;
    padding: 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

.nav-container {
    max-width: 1600px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    position: relative;
}

.nav-brand a {
    color: #ffffff;
    text-decoration: none;
    font-size: 24px;
    font-weight: normal;
    transition: color 0.3s;
    font-family: 'Pirata One', cursive;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-brand a:hover {
    color: #dc3545;
}

.nav-brand a:hover .nav-logo {
    opacity: 0.9;
}

.nav-logo {
    height: 20px;
    width: auto;
    display: inline-block;
    transition: opacity 0.3s;
}

.nav-brand-text {
    display: inline-block;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

@media (max-width: 768px) {
    .nav-links {
        display: flex;
    }
}

/* Hamburger menu button */
.nav-toggle {
    display: none;
    flex-direction: column;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    gap: 5px;
    z-index: 1001;
}

.nav-toggle span {
    width: 25px;
    height: 3px;
    background-color: #ffffff;
    border-radius: 3px;
    transition: all 0.3s ease;
    display: block;
}

.nav-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.nav-toggle.active span:nth-child(2) {
    opacity: 0;
}

.nav-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Unified navbar link and button styles */
.nav-link {
    color: #cccccc;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    font-family: inherit;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 6px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    background: transparent;
}

.nav-link:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.05);
}

/* Button-style nav links (primary actions) - unified styling */
.nav-link.btn-nav,
button.nav-link.btn-nav,
.nav-links button.nav-link.btn-nav,
.nav-links a.nav-link.btn-nav,
button.btn-nav,
.nav-links button.btn-nav {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%) !important;
    color: #ffffff !important;
    border: none !important;
    cursor: pointer;
    font-family: inherit;
    text-decoration: none !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 16px;
    border-radius: 6px;
    font-weight: 500;
    font-size: 14px;
    white-space: nowrap;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    margin: 0;
}

.nav-link.btn-nav:hover,
button.nav-link.btn-nav:hover,
.nav-links button.nav-link.btn-nav:hover,
.nav-links a.nav-link.btn-nav:hover,
button.btn-nav:hover,
.nav-links button.btn-nav:hover {
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%) !important;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(220, 53, 69, 0.4);
}

/* Regular buttons in navbar (reset to allow btn-nav to override) */
.nav-links button:not(.btn-nav) {
    background: transparent;
    border: none;
    padding: 0;
    margin: 0;
    font: inherit;
    cursor: pointer;
}

.nav-user {
    color: #cccccc;
    font-size: 13px;
    padding: 8px 12px;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
}

.nav-user strong {
    color: #dc3545;
    font-weight: 600;
    margin-left: 4px;
}

/* Index Page / Repository */
.repository-container {
    min-height: calc(100vh - 80px);
    padding: 40px 20px;
    max-width: 1600px;
    margin: 0 auto;
}

.repository-header {
    text-align: center;
    margin-bottom: 40px;
}

.repository-header h1 {
    color: #fff;
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.repository-subtitle {
    color: #aaa;
    font-size: 1.1rem;
}

/* Mobile responsive repository container */
@media (max-width: 768px) {
    .repository-container {
        padding: 20px 10px;
    }

    .repository-header h1 {
        font-size: 2rem;
    }

    .repository-subtitle {
        font-size: 1rem;
    }
}

/* Sticky Filter Button */
.sticky-filter-button-container {
    position: sticky;
    top: 80px;
    /* Default navbar height, will be updated by JS */
    z-index: 999;
    background-color: transparent;
    padding: 0;
    margin: 5px 0 20px 0;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

/* Unified base styles for all sticky header buttons */
.sticky-filter-button,
.sticky-sort-button,
.sticky-clear-filters-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid transparent;
}

/* Icon sizing for all buttons */
.sticky-filter-button i,
.sticky-sort-button i,
.sticky-clear-filters-button i {
    font-size: 16px;
}

/* Primary button style (Filter button) */
.sticky-filter-button {
    background-color: #dc3545;
    color: #fff;
    border-color: #dc3545;
}

.sticky-filter-button:hover {
    background-color: #c82333;
    border-color: #bd2130;
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

.sticky-filter-button.active {
    background-color: #dc3545;
    border-color: #dc3545;
    color: #fff;
}

.sticky-filter-button.active:hover {
    background-color: #c82333;
    border-color: #bd2130;
}

/* Secondary button style (Sort and Clear buttons) */
.sticky-sort-button,
.sticky-clear-filters-button {
    background-color: #2d2d2d;
    color: #ccc;
    border-color: #444;
}

.sticky-sort-button:hover,
.sticky-clear-filters-button:hover {
    background-color: #dc3545;
    color: #fff;
    border-color: #dc3545;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

/* Filter badge styling */
.filter-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
}

/* Sort Modal Styles */
.sort-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.sort-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background-color: #2d2d2d;
    color: #ccc;
    border: 1px solid #444;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    text-align: left;
    width: 100%;
    font-family: inherit;
}

.sort-option:hover {
    background-color: #3d3d3d;
    color: #fff;
    border-color: #555;
}

.sort-option.active {
    background-color: #dc3545;
    color: #fff;
    border-color: #dc3545;
}

.sort-option.active:hover {
    background-color: #c82333;
    border-color: #bd2130;
}

.sort-option i.fa-check {
    width: 16px;
    text-align: center;
    font-size: 14px;
}

.sort-option span {
    flex: 1;
}

/* Footer */
footer {
    margin-top: 60px;
    padding: 20px 0;
    text-align: center;
    border-top: 1px solid #444;
    color: #666;
    font-size: 11px;
}

footer a {
    color: #666;
    text-decoration: none;
    transition: color 0.3s;
}

footer a:hover {
    color: #dc3545;
}

footer a[href*="buymeacoffee"] {
    color: #dc3545;
}

footer a[href*="buymeacoffee"]:hover {
    color: #c82333;
}

footer a[href*="buymeacoffee"] i {
    margin-right: 5px;
}

.buy-me-a-coffee-link-inline {
    color: #dc3545;
    text-decoration: none;
    margin-left: 15px;
    font-size: 0.9em;
    transition: color 0.3s;
}

.buy-me-a-coffee-link-inline:hover {
    color: #c82333;
}

.buy-me-a-coffee-link-inline i {
    margin-right: 5px;
}

.website-description {
    background-color: rgba(45, 45, 45, 0.8);
    border: 1px solid #444;
    border-radius: 12px;
    padding: 25px 30px;
    margin-bottom: 30px;
    text-align: center;
}

.website-description p {
    color: #cccccc;
    font-size: 1rem;
    line-height: 1.6;
    margin: 0;
    max-width: 900px;
    margin: 0 auto;
}

.content-section {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    max-width: 900px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.8;
    color: #ccc;
}

.content-section h2 {
    color: #fff;
    font-size: 1.5rem;
    margin-top: 30px;
    margin-bottom: 15px;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.content-section h2:first-child {
    margin-top: 0;
}

.content-section p {
    margin-bottom: 15px;
    color: #ccc;
}

.content-section ul {
    margin-left: 20px;
    margin-bottom: 15px;
    color: #ccc;
}

.content-section li {
    margin-bottom: 8px;
    list-style-type: disc;
}

.suggest-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.suggest-form .form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.suggest-form label {
    color: #ccc;
    font-size: 14px;
    font-weight: 500;
}

.suggest-form input,
.suggest-form textarea {
    padding: 12px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    font-family: 'Funnel Sans', sans-serif;
}

.suggest-form input:focus,
.suggest-form textarea:focus {
    outline: none;
    border-color: #dc3545;
}

.suggest-form textarea {
    resize: vertical;
    min-height: 100px;
}

.suggest-form .form-label {
    color: #ccc;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.suggest-form .form-input,
.suggest-form .form-textarea {
    padding: 12px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    font-family: 'Funnel Sans', sans-serif;
    width: 100%;
}

.suggest-form .form-input:focus,
.suggest-form .form-textarea:focus {
    outline: none;
    border-color: #dc3545;
}

.suggest-form .form-error {
    color: #dc3545;
    font-size: 12px;
    margin-top: 5px;
}

.suggest-form .form-error span {
    display: block;
}

/* Tag Input System */
.tag-input-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px;
    background-color: #1a1a1a;
    border: 2px solid #444;
    border-radius: 6px;
    min-height: 44px;
    cursor: text;
    transition: border-color 0.3s;
}

.tag-input-container:focus-within {
    border-color: #dc3545;
}

.tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    background-color: #dc3545;
    color: #fff;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 500;
    animation: tagSlideIn 0.2s ease;
}

@keyframes tagSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

.tag-chip-remove {
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.2);
    transition: background-color 0.2s;
}

.tag-chip-remove:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.tag-chip-remove i {
    font-size: 10px;
}

.tag-input-field {
    flex: 1;
    min-width: 120px;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 14px;
    outline: none;
    font-family: 'Funnel Sans', sans-serif;
}

.tag-input-field::placeholder {
    color: #888;
}

.tag-input-hint {
    color: #999;
    font-size: 0.85rem;
    margin-top: 6px;
}

/* Filters Section */

.filters-toggle-btn {
    width: auto;
    padding: 8px 16px;
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.filters-toggle-btn:hover {
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

.filters-toggle-btn i {
    font-size: 18px;
}

.filters-chevron {
    transition: transform 0.3s ease;
}

.filters-toggle-btn.active .filters-chevron {
    transform: rotate(180deg);
}


.clear-filters-btn {
    background-color: #2d2d2d;
    color: #ccc;
    border: 1px solid #444;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
    font-family: inherit;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.clear-filters-btn:hover {
    background-color: #dc3545;
    color: #fff;
    border-color: #dc3545;
}

.clear-filters-btn i {
    font-size: 18px;
}

.filters-section.hidden {
    opacity: 0;
    visibility: hidden;
    max-height: 0;
    padding: 0 25px;
    margin-bottom: 0;
    transform: translateY(-20px);
}

.filters-section:not(.hidden) {
    opacity: 1;
    visibility: visible;
    max-height: 5000px;
    padding: 25px;
    margin-bottom: 30px;
    transform: translateY(0);
}

.filters-section {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    position: sticky;
    z-index: 999;
    opacity: 1;
    visibility: visible;
    max-height: 5000px;
    overflow: hidden;
    transform: translateY(0);
    transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        visibility 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        padding 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        margin-bottom 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        margin-top 0.3s ease;
}

.filters-section.sticky-active {
    margin-top: 30px;
}

.filters-section.hidden {
    opacity: 0;
    visibility: hidden;
    max-height: 0;
    padding: 0 25px;
    margin-bottom: 0;
    transform: translateY(-20px);
}

.filters-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.search-group {
    display: flex;
    position: relative;
}

/* Add margin-bottom to search group in filter modal */
#filterModal .search-group {
    margin-bottom: 20px;
}

.search-input {
    flex: 1;
    padding: 12px 50px 12px 20px;
    background-color: #1a1a1a;
    border: 2px solid #444;
    border-radius: 8px;
    color: #fff;
    font-size: 16px;
    transition: border-color 0.3s;
}

.search-input:focus {
    outline: none;
    border-color: #dc3545;
}

.search-input::placeholder {
    color: #888;
}

.btn-search {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    padding: 8px 12px;
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-search:hover {
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
    transform: translateY(-50%) translateY(-1px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    align-items: flex-end;
    max-width: 100%;
}

.filter-row>.filter-group {
    max-width: 100%;
}

/* Limit to max 3 columns */
@media (min-width: 900px) {
    .filter-row {
        grid-template-columns: repeat(3, 1fr);
    }
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    min-width: 0;
}

.filter-group.filter-actions {
    flex: 0 0 auto;
}

.filter-group label {
    color: #ccc;
    font-size: 14px;
    font-weight: 500;
}

.filter-select {
    padding: 10px 15px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    transition: border-color 0.3s;
}

.filter-select:focus {
    outline: none;
    border-color: #dc3545;
}

.filter-select option {
    background-color: #1a1a1a;
    color: #fff;
}

.filter-actions {
    flex-direction: row;
    gap: 10px;
}

.filter-actions .btn {
    padding: 10px;
    font-size: 14px;
    min-width: 44px;
    width: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.results-count-text {
    transition: opacity 0.3s ease, visibility 0.3s ease, max-height 0.3s ease;
}

.results-count-text.hide-on-scroll {
    opacity: 0 !important;
    visibility: hidden !important;
    max-height: 0 !important;
    overflow: hidden !important;
    pointer-events: none !important;
    margin: 0 !important;
    padding: 0 !important;
}


.filter-indicator {
    color: #dc3545;
    font-style: italic;
}

/* STL Grid */
.stl-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 40px;
}

/* Mobile responsive grid - single column to prevent overflow */
@media (max-width: 768px) {
    .stl-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
}

.stl-ad-container {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    padding: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    width: 100%;
    max-width: 100%;
    grid-column: auto;
}

.stl-ad-container ins {
    display: block;
    width: 100%;
    height: 100%;
    max-width: 100%;
}

.stl-ad-card .stl-card-image .adblock-message {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px 20px;
    text-align: center;
    color: #aaa;
    min-height: 300px;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #1a1a1a;
}

.stl-ad-card.adblock-detected .adblock-message {
    display: flex;
}

.stl-ad-card.adblock-detected ins {
    display: none;
}

.adblock-message i {
    font-size: 3rem;
    color: #dc3545;
    margin-bottom: 15px;
    opacity: 0.7;
}

.adblock-message h3 {
    color: #fff;
    font-size: 1.3rem;
    margin: 0 0 10px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.adblock-message p {
    color: #aaa;
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
    max-width: 500px;
}

.stl-card {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    max-width: 90vw;
}

/* Allow popovers to overflow card boundaries - ensure parent containers don't clip */
.stl-card-content {
    overflow: visible !important;
}

.stl-card {
    overflow: visible;
}

.stl-card-image {
    overflow: hidden;
}

/* Animation removed - no pop-in effect */

.stl-card:hover {
    transform: scale(1) translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.5);
    border-color: #dc3545;
}

.stl-card-image {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background-color: #1a1a1a;
    position: relative;
}

.stl-card-rating-overlay {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
    border-radius: 8px;
    padding: 6px 10px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.stl-card-stars-overlay {
    display: flex;
    align-items: center;
    gap: 3px;
}

.stl-card-stars-overlay .fa-star {
    color: #555;
    font-size: 0.9rem;
}

.stl-card-stars-overlay .fa-star.active {
    color: #dc3545;
}

.stl-card-show-details {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(to top, rgba(220, 53, 69, 0.95), rgba(220, 53, 69, 0.85));
    color: #fff;
    padding: 15px 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 1rem;
    font-weight: 600;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
    z-index: 10;
}

.stl-card-show-details i {
    font-size: 1.1rem;
}

.stl-card:hover .stl-card-show-details {
    opacity: 1;
    transform: translateY(0);
}

.stl-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.stl-card:hover .stl-card-image img {
    transform: scale(1.05);
}

.stl-card-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #555;
    font-size: 4rem;
}

.stl-card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
    cursor: pointer;
    pointer-events: auto;
    overflow: visible;
    position: relative;
    z-index: 20;
}

.stl-card-title {
    color: #fff;
    font-size: 1.3rem;
    margin-bottom: 10px;
    font-weight: normal;
    font-family: 'Pirata One', cursive;
    cursor: pointer;
    pointer-events: auto;
}

.stl-card-meta {
    margin-bottom: 12px;
    font-size: 0.9rem;
    color: #dc3545;
    line-height: 1.5;
    display: block;
}

.stl-card-meta .stl-meta-icon {
    font-size: 0.8rem;
    margin-right: 5px;
    display: inline;
    vertical-align: baseline;
}

.stl-card-score {
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 12px;
}

.stl-card-score-overall {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.score-label {
    color: #aaa;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.score-display {
    display: flex;
    align-items: center;
    gap: 8px;
}

.score-number {
    color: #dc3545;
    font-size: 1.2rem;
    font-weight: bold;
}

.score-stars-mini {
    display: flex;
    gap: 2px;
}

.score-stars-mini .fa-star {
    color: #555;
    font-size: 0.85rem;
}

.score-stars-mini .fa-star.active {
    color: #dc3545;
}

.stl-card-score-details {
    display: flex;
    gap: 12px;
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 6px;
}

.stl-card-review-count {
    font-size: 0.75rem;
    color: #666;
    text-align: center;
}

.stl-meta-item {
    color: #dc3545;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    white-space: nowrap;
    width: auto;
    flex-shrink: 0;
    flex-wrap: nowrap;
}

.stl-meta-item i {
    font-size: 0.8rem;
    display: inline-block;
    flex-shrink: 0;
    vertical-align: middle;
}

.filter-link {
    color: #dc3545;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
    opacity: 0.8;
    display: inline;
    white-space: normal;
}

.filter-link:hover {
    color: #dc3545;
    opacity: 1;
    text-decoration: underline;
}

.stl-card-description-wrapper {
    position: relative;
    margin-bottom: 15px;
    flex: 1;
    cursor: pointer;
    pointer-events: auto;
}

.stl-card-description-preview {
    color: #aaa;
    font-size: 0.95rem;
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    pointer-events: auto;
}

.popover-content::before {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid #dc3545;
}

.popover-content::after {
    content: '';
    position: absolute;
    bottom: -7px;
    left: 20px;
    width: 0;
    height: 0;
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-top: 8px solid #1a1a1a;
}

.stl-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px 20px 20px;
    border-top: 1px solid #444;
    flex-wrap: wrap;
    gap: 10px;
}

.stl-card-creator {
    color: #888;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.stl-card-creator .filter-link {
    color: #dc3545;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.2s ease;
    opacity: 0.8;
}

.stl-card-creator .filter-link:hover {
    color: #dc3545;
    opacity: 1;
    text-decoration: underline;
}

.stl-card-links {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.stl-warband-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
    justify-content: flex-end;
}

.stl-in-warband-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background-color: rgba(220, 53, 69, 0.2);
    border: 1px solid #dc3545;
    border-radius: 12px;
    padding: 4px 8px;
    color: #dc3545;
    font-size: 12px;
    font-weight: 500;
    cursor: help;
}

.stl-in-warband-badge i {
    font-size: 12px;
}

.warband-count {
    font-weight: 600;
}

.stl-add-to-warband-btn,
.stl-remove-from-warband-btn {
    background: transparent;
    border: 1px solid #444;
    border-radius: 6px;
    color: #aaa;
    padding: 6px 10px;
    cursor: pointer;
    transition: all 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    min-width: 32px;
    height: 32px;
}

.stl-add-to-warband-btn:hover {
    background-color: rgba(220, 53, 69, 0.1);
    border-color: #dc3545;
    color: #dc3545;
    transform: translateY(-1px);
}

.stl-remove-from-warband-btn:hover {
    background-color: rgba(220, 53, 69, 0.1);
    border-color: #dc3545;
    color: #dc3545;
    transform: translateY(-1px);
}

.stl-link-btn {
    padding: 4px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 6px;
    color: #dc3545;
    text-decoration: none;
    transition: all 0.3s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    min-width: 28px;
    min-height: 28px;
}

.link-logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    display: block;
}

.stl-link-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Platform-specific links use standard styling */
.stl-link-cults3d,
.stl-link-myminifactory,
.stl-link-patreon {
    background-color: #1a1a1a;
    border-color: #444;
    padding: 4px;
}

.stl-link-cults3d:hover,
.stl-link-myminifactory:hover,
.stl-link-patreon:hover {
    background-color: #dc3545;
    border-color: #dc3545;
    transform: translateY(-2px);
}

/* Generic Link */
.stl-link-generic {
    background-color: #1a1a1a;
    border-color: #444;
    color: #dc3545;
}

.stl-link-generic:hover {
    background-color: #dc3545;
    color: #fff;
    border-color: #dc3545;
}

/* Loading Indicator */
.loading-indicator {
    text-align: center;
    padding: 40px 20px;
    color: #aaa;
}

.loading-indicator i {
    font-size: 2rem;
    margin-bottom: 10px;
    color: #dc3545;
}

.loading-indicator p {
    color: #888;
    font-size: 0.9rem;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #888;
}

.empty-state i {
    font-size: 4rem;
    color: #555;
    margin-bottom: 20px;
}

.empty-state h2 {
    color: #fff;
    margin-bottom: 10px;
}

.empty-state p {
    margin-bottom: 25px;
    font-size: 1.1rem;
}

/* Style icons in buttons within empty state */
.empty-state .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.empty-state .btn i {
    font-size: 18px;
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    vertical-align: 0;
    margin: 0;
    padding: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .repository-header h1 {
        font-size: 2rem;
    }

    .filters-toggle-container {
        display: block;
    }

    .filters-section {
        position: relative;
        top: 0;
    }

    .filters-form {
        gap: 15px;
    }

    .filter-row {
        flex-direction: column;
        gap: 15px;
    }

    .filter-group {
        width: 100%;
        flex: 1 1 100%;
        min-width: 100%;
    }

    .filter-group label {
        display: block;
        margin-bottom: 8px;
        font-size: 14px;
        font-weight: 500;
        color: #ccc;
    }

    .filter-select {
        width: 100%;
        padding: 12px 15px;
        font-size: 16px;
    }

    .filter-group.filter-actions {
        width: 100%;
        flex-direction: row;
        gap: 10px;
        margin-top: 5px;
    }

    .filter-actions .btn {
        flex: 1;
        min-width: 0;
    }

    .search-group {
        width: 100%;
    }

    .search-input {
        width: 100%;
        font-size: 16px;
        padding: 12px 50px 12px 15px;
    }

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

    .search-group {
        position: relative;
    }

    .btn-search {
        position: absolute;
        right: 5px;
        top: 50%;
        transform: translateY(-50%);
        width: auto;
    }
}

/* Flash Messages */
.flash-messages {
    margin-bottom: 20px;
}

.flash {
    padding: 12px 20px;
    border-radius: 6px;
    margin-bottom: 10px;
    font-weight: 500;
}

.flash-success {
    background-color: rgba(220, 53, 69, 0.2);
    color: #ff6b6b;
    border: 1px solid #dc3545;
}

.flash-error {
    background-color: rgba(220, 53, 69, 0.3);
    color: #ff4444;
    border: 1px solid #dc3545;
}

.flash-info {
    background-color: rgba(220, 53, 69, 0.15);
    color: #ff6b6b;
    border: 1px solid #dc3545;
}

/* Login Page */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: calc(100vh - 80px);
    margin: -20px;
    padding: 20px;
    background: transparent;
}

.login-box {
    background: #2d2d2d;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    width: 100%;
    max-width: 400px;
    border: 1px solid #444;
}

.login-box h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #ffffff;
    font-size: 28px;
}

.form-group {
    margin-bottom: 20px;
}

.password-req {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #aaa;
    transition: color 0.3s;
}

.password-req i {
    transition: color 0.3s;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #cccccc;
    font-weight: 500;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #444;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
    background-color: #1a1a1a;
    color: #ffffff;
}

.form-group input:focus {
    outline: none;
    border-color: #dc3545;
    background-color: #252525;
}

.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #444;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
    background-color: #1a1a1a;
    color: #ffffff;
    font-family: inherit;
    resize: vertical;
    min-height: 200px;
}

.form-group textarea:focus {
    outline: none;
    border-color: #dc3545;
    background-color: #252525;
}

.form-select {
    width: 100%;
    padding: 12px;
    border: 2px solid #444;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s;
    background-color: #1a1a1a;
    color: #ffffff;
    cursor: pointer;
}

.form-select:focus {
    outline: none;
    border-color: #dc3545;
    background-color: #252525;
}

.form-select option {
    background-color: #2d2d2d;
    color: #ffffff;
}

.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 200px;
    overflow-y: auto;
    padding: 10px;
    background-color: #1a1a1a;
    border: 2px solid #444;
    border-radius: 6px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #cccccc;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.checkbox-label:hover {
    background-color: #252525;
}

/* Disable hover effect for Trench Crusade checkbox labels */
.form-group:has(input[name="is_trench_crusade"]) .checkbox-label:hover,
.form-group:has(input[id="suggest-is-trench-crusade"]) .checkbox-label:hover {
    background-color: transparent;
}

.checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #dc3545;
}

.checkbox-label span {
    user-select: none;
}

/* Searchable model list for suggest STL page */
.model-search-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.model-search-input {
    width: 100%;
    padding: 10px 12px;
    background-color: #1a1a1a;
    border: 2px solid #444;
    border-radius: 6px;
    color: #fff;
    font-size: 14px;
    transition: border-color 0.3s;
}

.model-search-input:focus {
    outline: none;
    border-color: #dc3545;
}

.model-checkbox-group {
    max-height: 200px;
    overflow-y: auto;
    padding: 10px;
    background-color: #1a1a1a;
    border: 2px solid #444;
    border-radius: 6px;
}

@media (max-width: 768px) {
    .model-checkbox-group {
        max-height: 150px;
    }
}

.model-checkbox-group::-webkit-scrollbar {
    width: 8px;
}

.model-checkbox-group::-webkit-scrollbar-track {
    background: #1a1a1a;
    border-radius: 4px;
}

.model-checkbox-group::-webkit-scrollbar-thumb {
    background: #444;
    border-radius: 4px;
}

.model-checkbox-group::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.model-checkbox-label {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #cccccc;
    cursor: pointer;
    padding: 8px;
    border-radius: 4px;
    transition: background-color 0.2s;
}

.model-checkbox-label:hover {
    background-color: #252525;
}

.model-checkbox-label input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #dc3545;
}

.model-checkbox-label span {
    user-select: none;
}

.no-results-message {
    padding: 20px;
    text-align: center;
    color: #999;
    font-style: italic;
}

.btn {
    padding: 12px;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-width: 44px;
    height: 44px;
    gap: 8px;
}

.btn i {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.btn-primary {
    background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
    color: white;
}

/* Full width for primary buttons in modals */
.modal-footer .btn-primary {
    width: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(220, 53, 69, 0.5);
    background: linear-gradient(135deg, #c82333 0%, #bd2130 100%);
}

.btn-secondary {
    background-color: #444;
    color: white;
    border: 1px solid #555;
}

.btn-secondary:hover {
    background-color: #555;
    border-color: #666;
}

.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #218838 100%);
    color: white;
    border: none;
}

.btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(40, 167, 69, 0.5);
    background: linear-gradient(135deg, #218838 0%, #1e7e34 100%);
}

.btn-info {
    background: linear-gradient(135deg, #17a2b8 0%, #138496 100%);
    color: white;
    border: none;
}

.btn-info:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(23, 162, 184, 0.5);
    background: linear-gradient(135deg, #138496 0%, #117a8b 100%);
}

/* Override width for icon-only buttons in admin header */
.admin-header-actions .btn {
    width: auto;
    min-width: 44px;
}

/* Style icons in admin header buttons */
.admin-header-actions .btn i {
    font-size: 18px;
    color: white;
    vertical-align: middle;
    line-height: 1;
}

/* Style file input labels as buttons */
.admin-header-actions label.btn {
    cursor: pointer;
    margin: 0;
}

.admin-header-actions input[type="file"] {
    display: none;
}

/* Admin Dashboard */
.admin-container {
    background: #2d2d2d;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    border: 1px solid #444;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #444;
}

.admin-header h1 {
    color: #ffffff;
    font-size: 32px;
    margin: 0;
}

.admin-header-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.admin-info {
    display: flex;
    align-items: center;
    gap: 20px;
}

.admin-info p {
    color: #cccccc;
    margin: 0;
}

.admin-info strong {
    color: #dc3545;
}

.admin-content {
    padding: 20px 0;
    color: #cccccc;
    font-size: 16px;
}

/* Admin Dashboard Links */
.admin-links {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.admin-link-card {
    background: #1a1a1a;
    padding: 30px;
    border-radius: 8px;
    border: 2px solid #444;
    text-decoration: none;
    color: #cccccc;
    transition: all 0.3s;
    display: block;
    position: relative;
}

.admin-link-card-full {
    grid-column: 1 / -1;
}

.admin-link-card:hover {
    border-color: #dc3545;
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(220, 53, 69, 0.3);
}

.admin-link-card h2 {
    color: #dc3545;
    margin-bottom: 10px;
    font-size: 24px;
    padding-right: 80px;
}

.admin-link-card-full h2 {
    padding-right: 100px;
}

.admin-link-card p {
    color: #aaaaaa;
    margin: 0 0 15px 0;
    font-size: 14px;
}

.admin-count {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #dc3545;
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    padding: 6px 12px;
    border-radius: 6px;
    min-width: 40px;
    text-align: center;
}

.admin-link-card-full .admin-count {
    font-size: 32px;
    padding: 10px 20px;
    min-width: 60px;
    top: 30px;
    right: 30px;
}

/* Statistics Page Styles */
/* Wider container for statistics page */
.repository-container.stats-container {
    max-width: 2500px;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Statistics grid - responsive columns with minimum 500px per column */
.statistics-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
}

/* Use auto-fit with minmax to ensure minimum 500px per column */
/* 2 columns: 2 × 500px + 1 × 30px gap = 1030px minimum */
@media (min-width: 1030px) {
    .statistics-grid {
        grid-template-columns: repeat(auto-fit, minmax(min(500px, 100%), 1fr));
    }
}

/* Limit to 2 columns until 1560px (2 × 500px + 1 × 30px + 500px) */
@media (min-width: 1560px) {
    .statistics-grid {
        grid-template-columns: repeat(3, minmax(min(500px, calc((100% - 60px) / 3)), 1fr));
    }
}

/* 4 columns: 4 × 500px + 3 × 30px = 2090px */
@media (min-width: 2090px) {
    .statistics-grid {
        grid-template-columns: repeat(4, minmax(min(500px, calc((100% - 90px) / 4)), 1fr));
    }
}

/* 5 columns: 5 × 500px + 4 × 30px = 2620px */
@media (min-width: 2620px) {
    .statistics-grid {
        grid-template-columns: repeat(5, minmax(min(500px, calc((100% - 120px) / 5)), 1fr));
    }
}

/* Override content-section max-width inside stats container */
.stats-container .content-section {
    max-width: none;
    margin-left: 0;
    margin-right: 0;
    width: 100%;
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Responsive legend grid for statistics - single column layout */
.stats-legend-grid {
    display: grid;
    gap: 15px;
    margin-top: 30px;
    /* Single column layout - items stacked vertically */
    grid-template-columns: 1fr;
}

/* Leaderboard grid for statistics - add spacing between items */
.top-proxied-models-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Statistics grid responsive adjustments for very small screens */
@media (max-width: 600px) {
    .statistics-grid {
        grid-template-columns: 1fr;
    }
}

.stats-section {
    margin-bottom: 40px;
    padding: 20px;
    background: #1a1a1a;
    border-radius: 8px;
    border: 1px solid #333;
}

.stats-section-title {
    color: #ffffff;
    font-size: 24px;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #dc3545;
    display: flex;
    align-items: center;
    gap: 10px;
}

.stats-section-title i {
    color: #dc3545;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: #2d2d2d;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
    border: 1px solid #444;
    transition: transform 0.3s, box-shadow 0.3s;
    position: relative;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(220, 53, 69, 0.3);
}

.stat-card-warning {
    border-color: #ffc107;
}

.stat-card-warning:hover {
    box-shadow: 0 5px 15px rgba(255, 193, 7, 0.3);
}

.stat-icon {
    font-size: 32px;
    color: #dc3545;
    margin-bottom: 10px;
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    color: #ffffff;
    margin: 10px 0;
}

.stat-label {
    font-size: 14px;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stats-chart-container {
    margin: 30px 0;
    padding: 20px;
    background: #252525;
    border-radius: 8px;
    height: 400px;
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

.stats-chart-container canvas {
    max-width: 100% !important;
    height: 100% !important;
}

.stats-table-container {
    margin: 30px 0;
}

.stats-table-container h3 {
    color: #ffffff;
    font-size: 18px;
    margin-bottom: 15px;
}

.stat-table {
    width: 100%;
    border-collapse: collapse;
    background: #1a1a1a;
    border-radius: 8px;
    overflow: hidden;
}

.stat-table thead {
    background: #2d2d2d;
}

.stat-table th {
    padding: 15px;
    text-align: left;
    color: #ffffff;
    font-weight: 600;
    border-bottom: 2px solid #444;
}

.stat-table td {
    padding: 12px 15px;
    color: #ddd;
    border-bottom: 1px solid #333;
}

.stat-table tbody tr:hover {
    background: #252525;
}

.stat-table a {
    color: #dc3545;
    text-decoration: none;
    transition: color 0.3s;
}

.stat-table a:hover {
    color: #ff6b7a;
    text-decoration: underline;
}

/* Responsive Statistics */
@media (max-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
        gap: 15px;
    }

    .stat-value {
        font-size: 28px;
    }

    .stats-chart-container {
        height: 300px;
    }

    .stats-chart-container canvas {
        max-width: 100% !important;
        height: 100% !important;
    }

    .stats-section {
        padding: 15px;
    }
}

/* Data Tables */
.table-controls {
    margin-bottom: 20px;
}

.table-search {
    width: 100%;
    max-width: 400px;
    padding: 10px 15px;
    border: 2px solid #444;
    border-radius: 6px;
    font-size: 16px;
    background-color: #1a1a1a;
    color: #ffffff;
    transition: border-color 0.3s;
}

.table-search:focus {
    outline: none;
    border-color: #dc3545;
    background-color: #252525;
}

.table-search::placeholder {
    color: #888;
}

.data-table {
    overflow-x: auto;
    margin-top: 20px;
}

.data-table table {
    width: 100%;
    border-collapse: collapse;
    background: #1a1a1a;
    border-radius: 8px;
    overflow: hidden;
}

.data-table thead {
    background: #2d2d2d;
}

.data-table th {
    padding: 15px;
    text-align: left;
    color: #ffffff;
    font-weight: 600;
    border-bottom: 2px solid #444;
    user-select: none;
}

.data-table th.sortable {
    position: relative;
    padding-right: 30px;
}

.data-table th.sortable:hover {
    background-color: #333;
}

.data-table th.sort-asc,
.data-table th.sort-desc {
    background-color: #333;
}

.sort-indicator {
    position: absolute;
    right: 10px;
    color: #888;
    font-size: 12px;
}

.data-table th.sort-asc .sort-indicator,
.data-table th.sort-desc .sort-indicator {
    color: #dc3545;
}

.data-table td {
    padding: 12px 15px;
    color: #cccccc;
    border-bottom: 1px solid #333;
}

.description-cell {
    max-width: 300px;
    position: relative;
}

.description-text {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
}

.data-table tbody tr:hover {
    background: #252525;
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.empty-message {
    text-align: center;
    color: #666;
    padding: 30px !important;
    font-style: italic;
}

.table-link {
    color: #dc3545;
    text-decoration: none;
    word-break: break-all;
}

.table-link:hover {
    text-decoration: underline;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    margin-top: 30px;
    padding: 20px 0;
}

.page-link {
    padding: 8px 16px;
    background-color: #2d2d2d;
    color: #ffffff;
    text-decoration: none;
    border-radius: 6px;
    border: 1px solid #444;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s;
    font-size: 14px;
}

.page-link:hover:not(.disabled) {
    background-color: #dc3545;
    border-color: #dc3545;
    transform: translateY(-1px);
}

.page-link.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background-color: #1a1a1a;
}

.page-info {
    color: #cccccc;
    font-size: 14px;
    padding: 0 10px;
}

.table-actions {
    white-space: nowrap;
}

.btn-action {
    padding: 8px 12px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s;
    margin-right: 5px;
    text-decoration: none;
    display: inline-block;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.btn-edit {
    background-color: #444;
    color: #ffffff;
    border: 1px solid #555;
}

.btn-edit:hover {
    background-color: #555;
    border-color: #666;
}

.btn-action.btn-success {
    background-color: #28a745;
    color: #ffffff;
    border: 1px solid #28a745;
}

.btn-action.btn-success:hover {
    background-color: #218838;
    border-color: #1e7e34;
}

.btn-delete {
    background-color: #dc3545;
    color: #ffffff;
}

.btn-delete:hover {
    background-color: #c82333;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(220, 53, 69, 0.4);
}

.btn-danger {
    background-color: #dc3545;
    color: white;
}

.btn-danger:hover {
    background-color: #c82333;
}

.delete-warning {
    color: #dc3545;
    font-weight: 500;
    margin-top: 10px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.8);
}

.modal.show {
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background-color: #2d2d2d;
    margin: auto;
    padding: 0;
    border: 2px solid #444;
    border-radius: 12px;
    position: relative;
    width: 90%;
    max-width: 1200px;
    height: 90vh;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
    animation: modalSlideIn 0.3s;
}

/* Revert filter modal to original styling */
#filterModal .modal-content {
    height: auto;
    max-height: 95vh;
}

/* Revert filter modal to original styling */
#filterModal .modal-content {
    height: auto;
    max-height: 95vh;
}

@keyframes modalSlideIn {
    from {
        transform: translateY(-50px);
        opacity: 0;
    }

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

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    border-bottom: 2px solid #444;
    flex: 0 0 auto;
    flex-shrink: 0;
}

.modal-header h2 {
    color: #ffffff;
    margin: 0;
    font-size: 24px;
    display: inline-flex;
    align-items: center;
}

.modal-close {
    color: #aaaaaa;
    font-size: 20px;
    cursor: pointer;
    line-height: 1;
    transition: color 0.3s;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 4px;
}

.modal-close:hover {
    background-color: #444;
}

.modal-close:hover {
    color: #dc3545;
}

.modal-body {
    padding: 30px;
    color: #cccccc;
    overflow-y: auto;
    flex: 1 1 0;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
}

/* General modal form styles for desktop */
.modal form {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
    height: 100%;
}

.modal form .modal-body {
    flex: 1 1 0;
    min-height: 0;
    overflow-y: auto;
    overflow-x: hidden;
}

.modal form .modal-footer {
    flex: 0 0 auto;
    flex-shrink: 0;
    margin-top: auto;
}

/* Revert filter modal form to original styling */
#filterModal form {
    height: auto;
    flex: none;
}

#filterModal .modal-body {
    flex: none;
    overflow-y: visible;
}

#filterModal .modal-footer {
    margin-top: 0;
}

.modal-body p {
    color: #cccccc;
    margin-bottom: 10px;
}

.modal-body.two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.modal-body.two-column .form-group.full-width {
    grid-column: 1 / -1;
}

@media (max-width: 768px) {
    .modal-body.two-column {
        grid-template-columns: 1fr;
    }
}

/* Suggest Modal & Admin STL Modal - Responsive Layout */
#suggestModal .modal-content,
#stlModal .modal-content {
    max-width: 900px;
    width: 95%;
    height: 90vh;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

/* Apply suggest modal styles to admin suggestions modal */
#stlModal .modal-body.suggest-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1 1 0;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
}

.suggest-modal-body {
    padding: 20px;
    overflow-y: auto;
    flex: 1 1 0;
    min-height: 0;
    -webkit-overflow-scrolling: touch;
}

.suggest-form-section {
    margin-bottom: 25px;
    padding-bottom: 20px;
    border-bottom: 1px solid #444;
}

.suggest-form-section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.suggest-two-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    align-items: start;
}

.suggest-form-col-section {
    display: flex;
    flex-direction: column;
}

.suggest-section-title {
    color: #ffffff;
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid #dc3545;
    display: inline-block;
}

.suggest-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.suggest-form-col {
    margin-bottom: 0;
}

.suggest-modal-body .form-group {
    margin-bottom: 15px;
}

.suggest-modal-body .form-group:last-child {
    margin-bottom: 0;
}

.suggest-modal-body .form-label {
    font-size: 14px;
    margin-bottom: 6px;
    display: block;
}

.suggest-modal-body .form-input,
.suggest-modal-body .form-textarea,
.suggest-modal-body .form-select {
    font-size: 14px;
    padding: 8px 12px;
    width: 100%;
}

.suggest-modal-body .form-textarea {
    resize: vertical;
    min-height: 60px;
}

.suggest-modal-body .checkbox-label {
    font-size: 14px;
}

.suggest-modal-body .btn-sm {
    padding: 6px 12px;
    font-size: 13px;
}

#suggestModal .modal-header,
#stlModal .modal-header {
    padding: 15px 20px;
    flex: 0 0 auto;
    flex-shrink: 0;
}

#suggestModal .modal-header h2,
#stlModal .modal-header h2 {
    font-size: 20px;
}

#suggestModal form,
#stlModal form {
    display: flex;
    flex-direction: column;
    flex: 1 1 0;
    min-height: 0;
    overflow: hidden;
    height: 100%;
}

#suggestModal .modal-footer,
#stlModal .modal-footer {
    padding: 15px 20px;
    flex: 0 0 auto;
    flex-shrink: 0;
    border-top: 1px solid #444;
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: auto;
}

#suggestModal .modal-footer .btn,
#stlModal .modal-footer .btn {
    padding: 8px 16px;
    font-size: 14px;
}

.suggest-image-preview {
    margin-top: 15px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    max-height: 200px;
    overflow-y: auto;
}

.selected-models-display {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 10px;
    background-color: #1a1a1a;
    border: 2px solid #dc3545;
    border-radius: 6px;
    min-height: 40px;
}

.selected-model-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background-color: #dc3545;
    color: #ffffff;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 500;
}

.selected-model-badge i {
    font-size: 11px;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.selected-model-badge i:hover {
    opacity: 1;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .modal {
        overflow: hidden !important;
    }

    .modal.show {
        align-items: flex-start;
        padding: 0;
        overflow: hidden !important;
    }

    .modal-content {
        width: 100%;
        height: 100svh;
        /* Small viewport height - accounts for mobile browser UI */
        max-height: 100svh;
        border-radius: 0;
        margin: 0;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
    }

    /* Fallback for browsers that don't support svh */
    @supports not (height: 100svh) {
        .modal-content {
            height: 100vh;
            max-height: 100vh;
        }
    }

    /* Ensure suggest modal is full width and height on mobile */
    #suggestModal .modal-content,
    #stlModal .modal-content {
        width: 100% !important;
        max-width: 100% !important;
        height: 100svh !important;
        /* Small viewport height - accounts for mobile browser UI */
        max-height: 100svh !important;
    }

    /* Fallback for browsers that don't support svh */
    @supports not (height: 100svh) {

        #suggestModal .modal-content,
        #stlModal .modal-content {
            height: 100vh !important;
            max-height: 100vh !important;
        }
    }

    .modal form {
        display: flex;
        flex-direction: column;
        height: 100%;
        min-height: 0;
        overflow: hidden;
    }

    .modal-body {
        padding: 15px;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        flex: 1 1 0;
        min-height: 0;
        max-height: 100%;
        -webkit-overflow-scrolling: touch;
        position: relative;
    }

    /* Ensure filter modal form and body work together for scrolling */
    #filterModal form.filters-form {
        display: flex;
        flex-direction: column;
        flex: 1 1 0;
        min-height: 0;
        overflow: hidden;
    }

    #filterModal .modal-body {
        overflow-y: auto !important;
        overflow-x: hidden !important;
        flex: 1 1 0;
        min-height: 0;
        -webkit-overflow-scrolling: touch;
    }

    /* For modals without forms, ensure body still scrolls */
    .modal-content>.modal-body {
        flex: 1 1 0;
        min-height: 0;
    }

    .modal-header {
        flex-shrink: 0;
        flex: 0 0 auto;
        padding: 12px 15px;
    }

    .modal-header h2 {
        font-size: 18px;
    }

    .modal-footer {
        flex: 0 0 auto;
        flex-shrink: 0;
        padding: 12px 15px;
        flex-direction: column;
        position: sticky;
        bottom: 0;
        z-index: 10;
        background-color: #2d2d2d;
        border-top: 1px solid #444;
        margin-top: auto;
    }

    /* Ensure footer stays visible in forms - must be after body in flex order */
    .modal form .modal-footer {
        flex: 0 0 auto;
        flex-shrink: 0;
        position: sticky;
        bottom: 0;
        margin-top: auto;
    }

    /* Ensure modal-body scrolls instead of pushing footer off screen */
    .modal form .modal-body {
        flex: 1 1 0;
        min-height: 0;
        max-height: calc(100vh - 150px);
        overflow-y: auto !important;
        overflow-x: hidden !important;
    }

    /* Specific styles for suggest modal body */
    #suggestModal .suggest-modal-body,
    #stlModal .suggest-modal-body {
        padding: 15px;
        overflow-y: auto !important;
        overflow-x: hidden !important;
        flex: 1 1 0;
        min-height: 0;
        -webkit-overflow-scrolling: touch;
        position: relative;
    }

    .suggest-form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .suggest-two-column {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .suggest-form-section {
        margin-bottom: 20px;
        padding-bottom: 15px;
    }

    .suggest-section-title {
        font-size: 15px;
    }

    #suggestModal .modal-footer .btn,
    #stlModal .modal-footer .btn {
        width: 100%;
    }

    .suggest-image-preview {
        grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
        gap: 8px;
    }

    .model-checkbox-group {
        max-height: 150px;
    }
}

/* Tablet Responsive */
@media (min-width: 769px) and (max-width: 1024px) {

    #suggestModal .modal-content,
    #stlModal .modal-content {
        max-width: 700px;
    }
}

/* Link input groups */
.link-input-group {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    align-items: center;
}

.link-input {
    flex: 1;
    padding: 10px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 4px;
    color: #fff;
    font-size: 14px;
}

.link-input:focus {
    outline: none;
    border-color: #dc3545;
}

.btn-remove-link {
    background-color: #dc3545;
    color: #fff;
    border: none;
    padding: 10px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    min-width: auto;
}

.btn-remove-link:hover {
    background-color: #c82333;
}

.btn-sm {
    padding: 8px 12px;
    font-size: 13px;
}

/* Image preview */
#image-preview-container img,
#existing-images-container img {
    border-radius: 4px;
}

#image-preview-container .btn,
#existing-images-container .btn {
    padding: 5px 8px;
    font-size: 12px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    flex: 0 0 auto;
    flex-shrink: 0;
    padding: 20px 30px;
    border-top: 1px solid #444;
    margin-top: auto;
    gap: 10px;
    padding: 20px 30px;
    border-top: 2px solid #444;
}

/* Badge styles */
.badge {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.badge-success {
    background-color: #28a745;
    color: white;
}

.badge-trench-crusade {
    background-color: #dc3545;
    /* Red color matching the theme */
    color: white;
}

.badge-trench-crusade i {
    color: white;
}

.badge-verified {
    background-color: #9c27b0;
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    font-size: 0.85rem;
    padding: 4px 6px;
    border-radius: 4px;
    font-weight: 500;
    min-width: 24px;
    height: 24px;
}

.badge-verified i {
    font-size: 0.9rem;
}

.badge-secondary {
    background-color: #6c757d;
    color: white;
}

/* Badge Popover */
.badge-popover-wrapper {
    position: relative;
    display: inline-block;
    z-index: 10001;
}

/* Prevent link navigation when clicking admin tag toggles */
.admin-tag-container {
    position: relative;
    z-index: 10002;
    pointer-events: auto;
}

.admin-tag-container * {
    pointer-events: auto;
}

.admin-tag-toggle {
    pointer-events: auto;
    position: relative;
    z-index: 10003;
}

.admin-tag-toggle * {
    pointer-events: auto;
}

.badge-popover {
    position: absolute;
    bottom: 100%;
    left: 50%;
    margin-bottom: 8px;
    padding: 6px 12px;
    background-color: #1a1a1a;
    color: #fff;
    border: 1px solid #dc3545;
    border-radius: 4px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
    z-index: 10000;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    transform: translateX(-50%) translateY(-5px);
}

.badge-popover::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-top: 6px solid #dc3545;
}

.badge-popover::before {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 7px solid transparent;
    border-right: 7px solid transparent;
    border-top: 7px solid #1a1a1a;
    margin-top: -1px;
}

/* Green popover for free badges */
.badge-popover-wrapper:has(.badge-success) .badge-popover {
    border-color: #28a745;
}

.badge-popover-wrapper:has(.badge-success) .badge-popover::after {
    border-top-color: #28a745;
}

/* Purple popover for verified creator badges */
.badge-popover-wrapper:has(.badge-verified) .badge-popover {
    border-color: #9c27b0;
}

.badge-popover-wrapper:has(.badge-verified) .badge-popover::after {
    border-top-color: #9c27b0;
}

/* Red popover for Trench Crusade badges */
.badge-popover-wrapper:has(.badge-trench-crusade) .badge-popover {
    border-color: #dc3545;
}

.badge-popover-wrapper:has(.badge-trench-crusade) .badge-popover::after {
    border-top-color: #dc3545;
}

.badge-popover-wrapper:hover .badge-popover {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

/* Ensure popover is visible outside card boundaries */
.stl-card-content,
.stl-detail-title-section {
    overflow: visible;
}

/* Adjust popover position for badges on the right edge */
.badge-popover-wrapper.popover-right .badge-popover {
    left: auto;
    right: 0;
    transform: translateX(0) translateY(-5px);
}

.badge-popover-wrapper.popover-right:hover .badge-popover {
    transform: translateX(0) translateY(0);
}

.badge-popover-wrapper.popover-right .badge-popover::after,
.badge-popover-wrapper.popover-right .badge-popover::before {
    left: auto;
    right: 12px;
    transform: translateX(0);
}

@media (max-width: 768px) {
    .container {
        padding: 10px;
    }

    .repository-container {
        overflow: visible;
    }

    .admin-container {
        padding: 20px 15px;
        margin: 0;
        border-radius: 8px;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .admin-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .admin-header h1 {
        font-size: 24px;
    }

    .admin-content {
        padding: 15px 0;
        overflow-x: hidden;
        width: 100%;
        max-width: 100%;
    }

    .warband-grid {
        grid-template-columns: 1fr !important;
        gap: 15px !important;
        margin-top: 15px !important;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .warband-card {
        width: 100%;
        max-width: 100%;
        padding: 15px !important;
        box-sizing: border-box;
        overflow: hidden;
    }

    .warband-card>div {
        flex-wrap: wrap;
        gap: 8px !important;
    }

    .warband-card h3 {
        word-wrap: break-word;
        overflow-wrap: break-word;
    }

    .nav-container {
        flex-wrap: wrap;
        padding: 12px 15px;
    }

    .nav-brand {
        flex: 1;
    }

    .nav-brand a {
        font-size: 20px;
    }

    .nav-logo {
        height: 16px;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-links {
        width: 100%;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        margin-top: 0;
        padding-top: 0;
        border-top: 1px solid transparent;
        opacity: 0;
        visibility: hidden;
        transform: translateY(-20px);
        max-height: 0;
        overflow: hidden;
        transition: opacity 0.4s cubic-bezier(0.4, 0, 0.2, 1),
            transform 0.4s cubic-bezier(0.4, 0, 0.2, 1),
            max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1),
            margin-top 0.4s cubic-bezier(0.4, 0, 0.2, 1),
            padding-top 0.4s cubic-bezier(0.4, 0, 0.2, 1),
            border-top-color 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .nav-links.active {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
        max-height: 1000px;
        margin-top: 15px;
        padding-top: 15px;
        border-top-color: #444;
    }

    .nav-link {
        width: 100%;
        padding: 12px 16px;
        text-align: center;
        border-radius: 6px;
        margin-bottom: 5px;
        font-size: 16px;
        min-height: 44px;
        display: flex;
        align-items: center;
        justify-content: center;
        opacity: 0;
        transform: translateX(-30px);
        transition: opacity 0.3s ease, transform 0.3s ease;
        transition-delay: 0s;
        background: transparent !important;
        box-shadow: none !important;
    }

    .nav-links.active .nav-link {
        opacity: 1;
        transform: translateX(0);
    }

    .nav-links.active .nav-link:nth-child(1) {
        transition-delay: 0.1s;
    }

    .nav-links.active .nav-link:nth-child(2) {
        transition-delay: 0.15s;
    }

    .nav-links.active .nav-link:nth-child(3) {
        transition-delay: 0.2s;
    }

    .nav-links.active .nav-link:nth-child(4) {
        transition-delay: 0.25s;
    }

    .nav-links.active .nav-link:nth-child(5) {
        transition-delay: 0.3s;
    }

    .nav-link.btn-nav,
    button.nav-link.btn-nav,
    .nav-links button.nav-link.btn-nav,
    .nav-links a.nav-link.btn-nav,
    button.btn-nav,
    .nav-links button.btn-nav {
        width: 100%;
        justify-content: center;
        margin-bottom: 5px;
        background: transparent !important;
        box-shadow: none !important;
    }

    .nav-link.btn-nav:hover,
    button.nav-link.btn-nav:hover,
    .nav-links button.nav-link.btn-nav:hover,
    .nav-links a.nav-link.btn-nav:hover,
    button.btn-nav:hover,
    .nav-links button.btn-nav:hover {
        background: transparent !important;
        box-shadow: none !important;
        transform: none !important;
    }

    .nav-link:hover {
        background-color: transparent !important;
    }

    .nav-user {
        width: 100%;
        padding: 12px 16px;
        text-align: center;
        order: -1;
        margin-bottom: 10px;
        opacity: 0;
        transform: translateX(-30px);
        transition: opacity 0.3s ease, transform 0.3s ease;
    }

    .nav-links.active .nav-user {
        opacity: 1;
        transform: translateX(0);
        transition-delay: 0.05s;
    }

    .admin-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .admin-info {
        width: 100%;
        justify-content: space-between;
    }
}

/* STL Card Link */
.stl-card-link {
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
    flex: 1;
    width: 100%;
    cursor: pointer;
    pointer-events: auto;
}

.stl-card-link:hover {
    text-decoration: none;
    color: inherit;
}

/* Make the card itself clickable */
.stl-card {
    cursor: pointer;
    position: relative;
}

/* STL Detail Page */
.stl-detail-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
}

.stl-detail-header {
    margin-bottom: 30px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #dc3545;
    text-decoration: none;
    font-size: 1rem;
    transition: color 0.3s;
}

.back-link:hover {
    color: #c82333;
    text-decoration: none;
}

.stl-detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.stl-detail-images {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 90vw;
}

.stl-main-image {
    width: 100%;
    aspect-ratio: 1;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 12px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    max-width: 90vw;
}

.stl-main-image img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.stl-image-placeholder {
    flex-direction: column;
    color: #555;
    font-size: 4rem;
}

.stl-image-placeholder p {
    margin-top: 15px;
    color: #888;
    font-size: 1rem;
}

.stl-image-thumbnails {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    max-width: 90vw;
}

.thumbnail {
    width: 80px;
    height: 80px;
    border: 2px solid #444;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    background-color: #1a1a1a;
}

.thumbnail:hover {
    border-color: #dc3545;
    transform: scale(1.05);
}

.thumbnail.active {
    border-color: #dc3545;
    box-shadow: 0 0 10px rgba(220, 53, 69, 0.5);
}

.thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.stl-stats {
    display: flex;
    gap: 20px;
    margin-top: 15px;
    padding: 15px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    flex-wrap: wrap;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    min-width: 60px;
}

.stat-item i {
    font-size: 1.2rem;
    color: #dc3545;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 1.1rem;
    font-weight: bold;
    color: #ffffff;
}

.stl-warband-section {
    margin-top: 20px;
    padding: 15px;
    background-color: rgba(255, 255, 255, 0.05);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.stl-warband-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.stl-warband-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background-color: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.warband-name {
    color: #fff;
    font-size: 14px;
    display: flex;
    align-items: center;
}

.stl-warband-section .btn-sm {
    padding: 4px 8px;
    font-size: 12px;
}

.stat-label {
    font-size: 0.85rem;
    color: #999;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stl-detail-info {
    display: flex;
    flex-direction: column;
    gap: 25px;
    max-width: 90vw;
}

.stl-detail-title-section {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.stl-detail-title-section h1 {
    color: #fff;
    font-size: 2.5rem;
    margin: 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.stl-detail-scores-top {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 25px;
}

.score-summary {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.score-summary-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.score-label-small {
    color: #aaa;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.score-display-inline {
    display: flex;
    align-items: center;
    gap: 15px;
}

.score-number-large {
    color: #dc3545;
    font-size: 2rem;
    font-weight: bold;
    min-width: 60px;
}

.score-stars-inline {
    display: flex;
    gap: 4px;
}

.score-stars-inline .fa-star {
    color: #555;
    font-size: 1.3rem;
}

.score-stars-inline .fa-star.active {
    color: #dc3545;
}

.score-breakdown {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-top: 15px;
    border-top: 1px solid #444;
}

.breakdown-item {
    color: #ccc;
    font-size: 0.95rem;
}

.breakdown-item strong {
    color: #dc3545;
    font-size: 1.1rem;
}

.stl-detail-meta {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 20px;
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #ccc;
    font-size: 1rem;
}

.meta-item i {
    color: #dc3545;
    width: 20px;
}

.meta-item strong {
    color: #fff;
    margin-right: 5px;
}

.stl-detail-creator {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    padding: 15px 20px;
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    color: #ccc;
    font-size: 1rem;
}

.stl-detail-creator i {
    color: #dc3545;
}

.stl-detail-creator strong {
    color: #fff;
    margin-right: 5px;
}

.stl-detail-description {
    padding: 20px;
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
}

.stl-detail-description h3 {
    color: #fff;
    font-size: 1.3rem;
    margin: 0 0 15px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.stl-detail-description p,
.stl-detail-description div {
    color: #ccc;
    line-height: 1.8;
    margin: 0;
    font-size: 1rem;
}

/* Mistake Notification Overlay */
.mistake-notification {
    position: fixed;
    bottom: 20px;
    left: 20px;
    background-color: #dc3545;
    color: #fff;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.mistake-notification:hover {
    background-color: #c82333;
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.mistake-notification i {
    font-size: 1.1rem;
}

.stl-detail-links {
    padding: 20px;
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
}

.stl-detail-links h3 {
    color: #fff;
    font-size: 1.3rem;
    margin: 0 0 20px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.stl-links-grid {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.stl-links-grid .stl-link-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 8px;
    text-decoration: none;
    color: #fff;
    transition: all 0.3s;
    font-size: 1rem;
    width: auto;
    height: auto;
    min-width: auto;
    min-height: auto;
    justify-content: flex-start;
}

.stl-links-grid .stl-link-btn:hover {
    border-color: #dc3545;
    background-color: #2d2d2d;
    transform: translateX(5px);
    text-decoration: none;
    color: #fff;
}

.stl-links-grid .stl-link-btn .link-logo {
    width: 24px;
    height: 24px;
    object-fit: contain;
    flex-shrink: 0;
}

.stl-links-grid .stl-link-btn span {
    color: #fff;
}

.stl-links-grid .stl-link-btn i {
    color: #dc3545;
    font-size: 1.2rem;
}

.stl-detail-actions {
    padding-top: 10px;
}

.stl-detail-related {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid #444;
}

.stl-detail-related h2 {
    color: #fff;
    font-size: 2rem;
    margin: 0 0 30px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

/* Reviews Section */
.stl-reviews-section {
    margin-top: 60px;
    padding-top: 40px;
    border-top: 2px solid #444;
}

.stl-reviews-section>h2 {
    color: #fff;
    font-size: 2rem;
    margin: 0 0 30px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.stl-average-scores {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
}

.stl-average-scores h3 {
    color: #fff;
    font-size: 1.3rem;
    margin: 0 0 20px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.scores-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 15px;
}

.score-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.score-label {
    color: #aaa;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.score-value {
    display: flex;
    align-items: center;
    gap: 15px;
}

.score-number {
    color: #dc3545;
    font-size: 1.8rem;
    font-weight: bold;
    min-width: 50px;
}

.score-stars {
    display: flex;
    gap: 3px;
}

.score-stars .fa-star {
    color: #555;
    font-size: 1.2rem;
}

.score-stars .fa-star.active {
    color: #dc3545;
}

.review-count {
    color: #888;
    font-size: 0.9rem;
    margin: 15px 0 0 0;
    text-align: center;
}

.stl-review-form-section {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
}

.stl-review-form-section h3 {
    color: #fff;
    font-size: 1.3rem;
    margin: 0 0 20px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.review-scores {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-bottom: 20px;
}

.score-input-group {
    display: flex;
    align-items: center;
    gap: 20px;
}

.score-input-group label {
    color: #ccc;
    font-size: 1rem;
    min-width: 100px;
}

.star-rating {
    display: flex;
    flex-direction: row-reverse;
    gap: 5px;
}

.star-rating input[type="radio"] {
    display: none;
}

.star-rating .star-label {
    cursor: pointer;
    color: #555;
    font-size: 1.5rem;
    transition: color 0.2s;
}

.star-rating .star-label:hover,
.star-rating .star-label:hover~.star-label {
    color: #dc3545;
}

.star-rating input[type="radio"]:checked~.star-label,
.star-rating input[type="radio"]:checked~.star-label~.star-label {
    color: #dc3545;
}

.review-form .form-group {
    margin-bottom: 20px;
}

.review-form .form-group label {
    display: block;
    color: #ccc;
    margin-bottom: 8px;
    font-size: 1rem;
}

.review-form textarea {
    width: 100%;
    padding: 12px;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-radius: 8px;
    color: #fff;
    font-family: inherit;
    font-size: 1rem;
    resize: vertical;
    min-height: 100px;
}

.review-form textarea:focus {
    outline: none;
    border-color: #dc3545;
}

.stl-review-login-prompt {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    margin-bottom: 30px;
}

.stl-review-login-prompt p {
    color: #aaa;
    margin: 0;
}

.stl-review-login-prompt a {
    color: #dc3545;
    text-decoration: none;
}

.stl-review-login-prompt a:hover {
    text-decoration: underline;
}

.stl-reviews-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stl-reviews-list h3 {
    color: #fff;
    font-size: 1.5rem;
    margin: 0 0 20px 0;
    font-family: 'Pirata One', cursive;
    font-weight: normal;
}

.review-item {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 20px;
}

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

.review-author {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #ccc;
}

.review-author i {
    color: #dc3545;
    font-size: 1.2rem;
}

.review-date {
    color: #888;
    font-size: 0.9rem;
}

.review-scores-display {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 15px;
}

.review-score-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.review-score-item span {
    color: #aaa;
    font-size: 0.9rem;
    min-width: 100px;
}

.mini-stars {
    display: flex;
    gap: 3px;
}

.mini-stars .fa-star {
    color: #555;
    font-size: 0.9rem;
}

.mini-stars .fa-star.active {
    color: #dc3545;
}

.review-text {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #444;
}

.review-text p {
    color: #ccc;
    line-height: 1.6;
    margin: 0;
}

.stl-no-reviews {
    background-color: #2d2d2d;
    border: 1px solid #444;
    border-radius: 12px;
    padding: 40px;
    text-align: center;
}

.stl-no-reviews p {
    color: #888;
    margin: 0;
    font-size: 1.1rem;
}

/* Back to Top Button */
.back-to-top-btn {
    position: fixed !important;
    bottom: 17px !important;
    right: 100px !important;
    width: 65px;
    height: 65px;
    background: linear-gradient(135deg, #ff5f5f 0%, #ff5f5f 100%);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s ease;
    z-index: 10000 !important;
    pointer-events: none;
}

.back-to-top-btn.show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

.back-to-top-btn:hover {
    background: linear-gradient(135deg, #ff5f5f 0%, #ff5f5f 100%);
    transform: scale(1.1);
}

.back-to-top-btn:active {
    transform: translateY(-1px);
}

@media (max-width: 768px) {
    .back-to-top-btn {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
        font-size: 18px;
    }
}

/* Responsive Design for Detail Page */
@media (max-width: 968px) {
    .stl-detail-container {
        padding: 15px 10px;
        overflow-x: hidden;
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    .stl-detail-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .stl-detail-title-section h1 {
        font-size: 2rem;
    }

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

    .score-input-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .review-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .stl-reviews-section {
        padding: 20px 0;
    }

    .stl-review-form-section {
        padding: 20px 15px;
        margin-bottom: 20px;
    }

    .review-scores {
        gap: 15px;
        margin-bottom: 15px;
    }

    .score-input-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        width: 100%;
    }

    .score-input-group label {
        min-width: auto;
        width: 100%;
        font-size: 14px;
    }

    .star-rating {
        width: 100%;
        justify-content: flex-start;
    }

    .star-rating .star-label {
        font-size: 1.2rem;
    }

    .review-form textarea {
        width: 100%;
        font-size: 16px;
        padding: 10px;
    }

    .review-item {
        padding: 15px;
    }

    .review-score-item {
        flex-wrap: wrap;
    }

    .review-score-item span {
        min-width: auto;
        width: 100%;
        margin-bottom: 5px;
    }
}

/* Creator Autocomplete Styles */
.creator-autocomplete-wrapper {
    position: relative;
    width: 100%;
}

.creator-autocomplete-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: #1a1a1a;
    border: 1px solid #444;
    border-top: none;
    border-radius: 0 0 6px 6px;
    max-height: 300px;
    overflow-y: auto;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5);
    margin-top: -1px;
}

.creator-autocomplete-item {
    padding: 10px 12px;
    color: #fff;
    cursor: pointer;
    font-size: 14px;
    font-family: 'Funnel Sans', sans-serif;
    transition: background-color 0.2s ease;
    border-bottom: 1px solid #2a2a2a;
}

.creator-autocomplete-item:last-child {
    border-bottom: none;
}

.creator-autocomplete-item:hover,
.creator-autocomplete-item.active {
    background-color: #2a2a2a;
    color: #fff;
}

.creator-autocomplete-dropdown::-webkit-scrollbar {
    width: 8px;
}

.creator-autocomplete-dropdown::-webkit-scrollbar-track {
    background: #1a1a1a;
}

.creator-autocomplete-dropdown::-webkit-scrollbar-thumb {
    background: #444;
    border-radius: 4px;
}

.creator-autocomplete-dropdown::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Creator Verification Modal Styles */
.creator-link-group {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    align-items: flex-end;
}

.creator-link-group .form-group {
    margin-bottom: 0;
}

.info-box {
    background: #1a3a52;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border: 1px solid #2d5a7a;
    color: #e0e0e0;
}

.info-box h4 {
    margin-top: 0;
    color: #4fc3f7;
}

.info-box ul {
    margin: 0;
    padding-left: 20px;
    color: #e0e0e0;
}

.info-box p {
    margin-bottom: 10px;
    color: #e0e0e0;
}

.info-box p:last-child {
    margin-bottom: 0;
}

.info-box strong {
    color: #fff;
}

/* MyMiniFactory Auto-Fill Button Styles */
.mmf-autofill-btn {
    background: transparent;
    border: none;
    padding: 0;
    margin-left: 10px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    transition: opacity 0.2s ease, transform 0.2s ease;
    opacity: 0.8;
    position: relative;
}

.mmf-autofill-btn.mmf-button-animate {
    animation: mmfButtonAppear 0.8s cubic-bezier(0.34, 1.56, 0.64, 1) forwards, mmfButtonPulse 1.5s ease-in-out 0.8s infinite;
}

.mmf-autofill-btn:hover {
    opacity: 1;
    transform: scale(1.15);
}

.mmf-autofill-btn:active {
    opacity: 0.7;
    transform: scale(0.95);
}

.mmf-autofill-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: scale(1);
}

.mmf-autofill-btn img {
    display: block;
    width: 18px;
    height: 18px;
    object-fit: contain;
    transition: transform 0.2s ease;
    filter: drop-shadow(0 0 0 rgba(220, 53, 69, 0));
}

.mmf-autofill-btn.mmf-button-animate img {
    animation: mmfButtonImageGlow 1.5s ease-in-out 0.8s infinite;
}

@keyframes mmfButtonAppear {
    0% {
        opacity: 0;
        transform: scale(0) rotate(-360deg);
    }

    60% {
        transform: scale(1.3) rotate(10deg);
    }

    80% {
        transform: scale(0.9) rotate(-5deg);
    }

    100% {
        opacity: 0.8;
        transform: scale(1) rotate(0deg);
    }
}

@keyframes mmfButtonPulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7);
    }

    50% {
        transform: scale(1.2);
        box-shadow: 0 0 0 8px rgba(220, 53, 69, 0);
    }
}

@keyframes mmfButtonImageGlow {

    0%,
    100% {
        filter: drop-shadow(0 0 0 rgba(220, 53, 69, 0));
    }

    50% {
        filter: drop-shadow(0 0 10px rgba(220, 53, 69, 0.8)) drop-shadow(0 0 20px rgba(220, 53, 69, 0.4));
    }
}

.modal-header h2 {
    display: inline-flex;
    align-items: center;
}

.repository-header h1 {
    display: inline-flex;
    align-items: center;
}

/* MyMiniFactory Loading Overlay Styles */
.mmf-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.92);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    border-radius: 8px;
    animation: mmfFadeIn 0.5s ease-out forwards, mmfPulse 2s ease-in-out infinite;
    animation-delay: 0s, 0.5s;
    box-shadow: 0 0 0 4px rgba(220, 53, 69, 0.3), inset 0 0 100px rgba(220, 53, 69, 0.1);
    opacity: 0;
}

@keyframes mmfFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes mmfPulse {

    0%,
    100% {
        box-shadow: 0 0 0 4px rgba(220, 53, 69, 0.3), inset 0 0 100px rgba(220, 53, 69, 0.1);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(220, 53, 69, 0.5), inset 0 0 100px rgba(220, 53, 69, 0.2);
    }
}

.mmf-loading-content {
    text-align: center;
    color: #fff;
    padding: 40px 50px;
    background: linear-gradient(135deg, rgba(26, 26, 26, 0.98) 0%, rgba(30, 30, 30, 0.98) 100%);
    border-radius: 12px;
    border: 2px solid #dc3545;
    min-width: 320px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.6), 0 0 20px rgba(220, 53, 69, 0.3);
    animation: mmfContentSlideIn 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
    position: relative;
    overflow: hidden;
    opacity: 0;
    transform: translateY(-30px) scale(0.8);
}

.mmf-loading-content::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(220, 53, 69, 0.1), transparent);
    animation: mmfShine 3s infinite;
}

@keyframes mmfContentSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px) scale(0.8);
    }

    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

@keyframes mmfShine {
    0% {
        transform: translateX(-100%) translateY(-100%) rotate(45deg);
    }

    100% {
        transform: translateX(100%) translateY(100%) rotate(45deg);
    }
}

.mmf-loading-spinner {
    font-size: 56px;
    color: #dc3545;
    margin-bottom: 25px;
    animation: mmfSpin 1.2s linear infinite, mmfPulseGlow 2s ease-in-out infinite;
    text-shadow: 0 0 20px rgba(220, 53, 69, 0.6), 0 0 40px rgba(220, 53, 69, 0.4);
    position: relative;
    z-index: 1;
    display: inline-block;
}

@keyframes mmfSpin {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@keyframes mmfPulseGlow {

    0%,
    100% {
        filter: brightness(1) drop-shadow(0 0 10px rgba(220, 53, 69, 0.6));
    }

    50% {
        filter: brightness(1.4) drop-shadow(0 0 20px rgba(220, 53, 69, 0.9));
    }
}

.mmf-loading-text {
    font-size: 18px;
    margin-bottom: 25px;
    color: #ffffff;
    font-weight: 600;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
    position: relative;
    z-index: 1;
    animation: mmfTextFade 2s ease-in-out infinite;
}

@keyframes mmfTextFade {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.7;
    }
}

.mmf-loading-progress {
    width: 100%;
    height: 10px;
    background: #1a1a1a;
    border-radius: 5px;
    overflow: hidden;
    margin-top: 15px;
    border: 1px solid #333;
    position: relative;
    z-index: 1;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.3);
}

.mmf-loading-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #dc3545 0%, #ff4757 50%, #dc3545 100%);
    background-size: 200% 100%;
    border-radius: 5px;
    width: 0%;
    transition: width 0.3s ease;
    animation: mmfShimmer 1.5s infinite;
    box-shadow: 0 0 10px rgba(220, 53, 69, 0.6);
}

@keyframes mmfShimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.mmf-loading-overlay.fade-out {
    animation: fadeOut 0.3s ease-out forwards;
}

@keyframes fadeOut {
    from {
        opacity: 1;
    }

    to {
        opacity: 0;
    }
}

/* Badge styles for verified creator */
.badge-warning {
    background-color: #ffc107;
    color: #000;
}

.badge-danger {
    background-color: #dc3545;
    color: white;
}

/* Suggest Type Modal Button Styles */
.suggest-type-btn {
    padding: 40px 50px;
    font-size: 1.4rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    width: 100%;
}

/* Responsive styles for suggest type buttons */
@media (max-width: 768px) {
    .suggest-type-btn {
        padding: 25px 20px;
        font-size: 1.1rem;
        gap: 8px;
    }

    .suggest-type-btn i {
        font-size: 1.3rem !important;
    }

    .suggest-type-btn>div:last-child {
        font-size: 0.85rem !important;
    }

    #suggestTypeModal .modal-body {
        padding: 30px 20px !important;
        min-height: 250px !important;
    }
}

@media (max-width: 480px) {
    .suggest-type-btn {
        padding: 20px 15px;
        font-size: 1rem;
    }

    .suggest-type-btn i {
        font-size: 1.2rem !important;
    }


    .suggest-type-btn>div:last-child {
        font-size: 0.8rem !important;
    }

    #suggestTypeModal .modal-body {
        padding: 20px 15px !important;
        min-height: 200px !important;
    }
}

/* Google AdSense Styles */
.adsbygoogle {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 20px 0 !important;
}

/* Ensure AdSense iframes are full width */
.adsbygoogle iframe,
ins.adsbygoogle iframe {
    width: 100% !important;
    max-width: 100% !important;
}