:root {
    /* Colors */
    --color-bg: #0a0a0a;
    --color-surface: rgba(20, 20, 20, 0.6);
    --color-surface-hover: rgba(26, 26, 26, 0.8);
    --color-border: #2a2a2a;
    --color-border-light: #333333;

    /* Gold accent */
    --color-gold: #d4af37;
    --color-gold-light: #e8c966;
    --color-gold-dark: #b8963d;

    /* Text */
    --color-text: #e8e8e8;
    --color-text-secondary: #a0a0a0;
    --color-text-tertiary: #707070;

    /* Semantic */
    --color-success: #4a9960;
    --color-danger: #c94d3d;

    /* Spacing - More compact */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 0.75rem;
    --spacing-lg: 1rem;
    --spacing-xl: 1.5rem;

    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 6px;
    --radius-lg: 8px;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.5);
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: linear-gradient(135deg, #0a0e15 0%, #0a0a0a 50%, #0d0d0d 100%);
    color: var(--color-text);
    line-height: 1.5;
    overflow-x: hidden;
    position: relative;
}

/* Strong blue gradient background */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background:
        radial-gradient(ellipse 70% 50% at 10% 10%, rgba(60, 120, 180, 0.35) 0%, transparent 60%),
        radial-gradient(ellipse 50% 40% at 90% 90%, rgba(220, 220, 220, 0.15) 0%, transparent 55%),
        radial-gradient(ellipse 60% 55% at 30% 50%, rgba(80, 140, 200, 0.25) 0%, transparent 65%);
    animation: atmosphericDrift 25s ease-in-out infinite alternate;
}

@keyframes atmosphericDrift {
    0% {
        opacity: 1;
        filter: blur(60px);
    }

    100% {
        opacity: 0.85;
        filter: blur(80px);
    }
}

/* Film grain texture */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' /%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)' opacity='0.04'/%3E%3C/svg%3E");
    pointer-events: none;
    opacity: 0.6;
}

.app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    position: relative;
    z-index: 1;
}

/* ========== HEADER ========== */
.header {
    background: rgba(20, 20, 20, 0.95);
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    max-width: 1600px;
    margin: 0 auto;
    padding: var(--spacing-lg) var(--spacing-xl);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-lg);
}

.brand {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
}

.brand-logo {
    height: 42px;
    width: auto;
    object-fit: contain;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.5));
}

.brand-divider {
    width: 1px;
    height: 32px;
    background: linear-gradient(to bottom, transparent, var(--color-gold-dark), transparent);
    opacity: 0.5;
}

.brand h1 {
    font-family: 'Cinzel', serif;
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--color-gold);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.search-icon {
    position: absolute;
    left: 12px;
    width: 18px;
    height: 18px;
    color: var(--color-text-tertiary);
    pointer-events: none;
}

.search-input {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    color: var(--color-text);
    padding: 0.5rem 0.75rem 0.5rem 2.5rem;
    font-size: 0.875rem;
    font-family: inherit;
    width: 280px;
    transition: all 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: var(--color-gold-dark);
    background: var(--color-surface);
}

.search-input::placeholder {
    color: var(--color-text-tertiary);
}

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    font-family: inherit;
    border: 1px solid transparent;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn svg {
    width: 16px;
    height: 16px;
}

.btn-primary {
    background: var(--color-gold);
    color: #0a0a0a;
    border-color: var(--color-gold);
}

.btn-primary:hover {
    background: var(--color-gold-light);
    border-color: var(--color-gold-light);
    transform: translateY(-1px);
}

.btn-secondary {
    background: transparent;
    color: var(--color-text-secondary);
    border-color: var(--color-border);
}

.btn-secondary:hover {
    background: var(--color-surface);
    color: var(--color-text);
    border-color: var(--color-border-light);
}

.sort-dropdown {
    position: relative;
}

.sort-dropdown .btn {
    min-width: 140px;
    justify-content: space-between;
}

.sort-dropdown .btn .sort-icon {
    display: none;
}

.sort-dropdown .dropdown-content {
    position: absolute;
    top: calc(100% + 4px);
    right: 0;
    background: linear-gradient(135deg, #0a0e15 0%, #0d0d0d 50%, #0a0a0a 100%);
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-md);
    min-width: 200px;
    box-shadow: var(--shadow-lg);
    z-index: 200;
    display: none;
}

.sort-dropdown.active .dropdown-content {
    display: block;
    animation: dropdownSlide 0.15s ease-out;
}

@keyframes dropdownSlide {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }

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

.dropdown-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all 0.15s;
    border: none;
    background: transparent;
    width: 100%;
    text-align: left;
}

.dropdown-item:first-child {
    border-radius: var(--radius-md) var(--radius-md) 0 0;
}

.dropdown-item:last-child {
    border-radius: 0 0 var(--radius-md) var(--radius-md);
}

.dropdown-item:hover {
    background: var(--color-bg);
    color: var(--color-text);
}

.dropdown-item.active {
    color: var(--color-gold);
}

.dropdown-item svg {
    width: 16px;
    height: 16px;
}

/* ========== MAIN CONTENT ========== */
.main {
    flex: 1;
    padding: var(--spacing-xl);
    padding-bottom: 80px;
    /* Space for footer */
}

.container {
    max-width: 1600px;
    margin: 0 auto;
}

.resources-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--spacing-md);
}

/* ========== RESOURCE CARDS ========== */
.resource-item {
    background: var(--color-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    padding: var(--spacing-lg) 1.25rem;
    display: grid;
    grid-template-columns: 1fr auto;
    align-items: center;
    gap: var(--spacing-lg);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
    position: relative;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

/* Drag and drop styles - SortableJS integration */
.resources-grid .resource-item {
    cursor: grab;
}

.resource-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: var(--color-gold-dark);
    opacity: 0;
    transition: opacity 0.2s;
}

.resource-item:hover {
    background: var(--color-surface-hover);
    border-color: var(--color-border-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.resource-item:hover::before {
    opacity: 1;
}

/* Custom drag and drop styles */

/* Placeholder - invisible element that holds the space in grid */
.drag-placeholder {
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden;
}

/* Ghost element - the tilted card that follows the cursor */
.drag-ghost {
    opacity: 1;
    background: var(--color-surface-hover);
    border-color: var(--color-gold-dark);
    transform: scale(1.05) rotate(3deg);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4),
        0 0 0 1px var(--color-gold-dark);
    cursor: grabbing;
    pointer-events: none;
    transition: none;
    user-select: none;
    -webkit-user-select: none;
}

/* Enhance the left accent bar on ghost */
.drag-ghost::before {
    opacity: 1;
}

/* Hide action buttons on ghost */
.drag-ghost .resource-actions {
    display: none;
}

/* Show weight on ghost */
.drag-ghost .resource-weight-display {
    opacity: 1;
}

/* Enhance text on ghost */
.drag-ghost .resource-name {
    color: var(--color-gold);
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

.resource-info {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
}

.resource-name {
    font-size: 1.0625rem;
    font-weight: 600;
    color: var(--color-gold-light);
    letter-spacing: 0.3px;
}

.resource-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    color: var(--color-text-secondary);
}

.location-icon {
    width: 14px;
    height: 14px;
    color: var(--color-text-tertiary);
    flex-shrink: 0;
}

.resource-weight-display {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: var(--color-text-secondary);
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    min-width: 100px;
    justify-content: flex-end;
}

.weight-icon {
    width: 14px;
    height: 14px;
    color: var(--color-text-tertiary);
    flex-shrink: 0;
}

.resource-actions {
    display: flex;
    gap: var(--spacing-xs);
    opacity: 0;
    transition: opacity 0.35s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    position: absolute;
    right: 1.25rem;
    transform: translateX(-5px);
}

.resource-item:hover .resource-weight-display {
    opacity: 0;
    pointer-events: none;
}

.resource-item:hover .resource-actions {
    opacity: 1;
    transform: translateX(0);
}

.action-btn {
    background: transparent;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    color: var(--color-text-tertiary);
    width: 32px;
    height: 32px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateZ(0);
}

.action-btn svg {
    width: 16px;
    height: 16px;
}

.action-btn:hover {
    background: var(--color-bg);
    border-color: var(--color-border-light);
    color: var(--color-text);
}

.action-btn.delete:hover {
    border-color: var(--color-danger);
    color: var(--color-danger);
}

/* ========== MODAL ========== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-lg);
}

.modal.active {
    display: flex;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
}

.modal-content {
    position: relative;
    background: linear-gradient(135deg, #0a0e15 0%, #0d0d0d 50%, #0a0a0a 100%);
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-lg);
    width: 100%;
    max-width: 520px;
    box-shadow: var(--shadow-lg);
    animation: modalSlide 0.2s ease-out;
}

@keyframes modalSlide {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }

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

.modal-header {
    padding: var(--spacing-lg);
    border-bottom: 1px solid var(--color-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--color-text);
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--color-text-tertiary);
    width: 32px;
    height: 32px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s;
}

.modal-close svg {
    width: 20px;
    height: 20px;
}

.modal-close:hover {
    background: var(--color-bg);
    color: var(--color-text);
}

.modal-body {
    padding: var(--spacing-lg);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--color-text-secondary);
}

.form-input {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    color: var(--color-text);
    padding: 0.625rem 0.75rem;
    font-size: 0.9375rem;
    font-family: inherit;
    transition: all 0.2s;
}

.form-input:focus {
    outline: none;
    border-color: var(--color-gold-dark);
    background: var(--color-surface);
}

.form-input::placeholder {
    color: var(--color-text-tertiary);
}

.town-select-container {
    position: relative;
}

.town-tags {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-sm);
    min-height: 0;
}

.town-tags:not(:empty) {
    margin-bottom: var(--spacing-sm);
}

.town-tag-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.town-tag {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    background: var(--color-gold-dark);
    color: var(--color-bg);
    padding: 0.3rem 0.6rem;
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
    font-weight: 500;
}

.weight-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.weight-input-icon {
    position: absolute;
    left: 10px;
    width: 14px;
    height: 14px;
    color: var(--color-text-tertiary);
    pointer-events: none;
}

.town-weight-input {
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    color: var(--color-text);
    padding: 0.3rem 0.5rem 0.3rem 2rem;
    font-size: 0.8125rem;
    font-family: inherit;
    width: 100px;
    transition: all 0.2s;
}

.town-weight-input:focus {
    outline: none;
    border-color: var(--color-gold-dark);
    background: var(--color-surface);
}

/* Remove spinner arrows from number inputs */
.town-weight-input::-webkit-outer-spin-button,
.town-weight-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.town-weight-input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

.town-tag-remove {
    background: transparent;
    border: none;
    color: var(--color-bg);
    cursor: pointer;
    padding: 0;
    width: 14px;
    height: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.7;
    transition: opacity 0.15s;
}

.town-tag-remove:hover {
    opacity: 1;
}

.town-tag-remove svg {
    width: 12px;
    height: 12px;
}

.town-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: linear-gradient(135deg, #0a0e15 0%, #0d0d0d 50%, #0a0a0a 100%);
    border: 1px solid var(--color-border-light);
    border-radius: var(--radius-md);
    max-height: 200px;
    overflow-y: auto;
    z-index: 300;
    display: none;
    box-shadow: var(--shadow-lg);
    margin-top: 4px;
}

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

.town-dropdown::-webkit-scrollbar-track {
    background: transparent;
}

.town-dropdown::-webkit-scrollbar-thumb {
    background: var(--color-border);
    border-radius: 4px;
}

.town-dropdown::-webkit-scrollbar-thumb:hover {
    background: var(--color-border-light);
}

.town-dropdown.active {
    display: block;
    animation: dropdownSlide 0.15s ease-out;
}

.town-dropdown-item {
    padding: var(--spacing-md) var(--spacing-lg);
    cursor: pointer;
    transition: background 0.15s;
    font-size: 0.875rem;
    color: var(--color-text-secondary);
}

.town-dropdown-item:hover {
    background: var(--color-bg);
    color: var(--color-text);
}

.town-dropdown-item.selected {
    background: var(--color-gold-dark);
    color: var(--color-bg);
}

.town-dropdown-divider {
    height: 1px;
    background: var(--color-border);
    margin: var(--spacing-xs) 0;
}

.town-input {
    margin-top: 0 !important;
}

.modal-footer {
    padding: var(--spacing-lg);
    border-top: 1px solid var(--color-border);
    display: flex;
    justify-content: flex-end;
    gap: var(--spacing-md);
}

/* ========== EMPTY STATE ========== */
.empty-state {
    grid-column: 1 / -1;
    text-align: center;
    padding: var(--spacing-xl) var(--spacing-lg);
    color: var(--color-text-tertiary);
    font-size: 0.9375rem;
}

/* ========== FOOTER ========== */
.footer {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(20, 20, 20, 0.98);
    border-top: 1px solid var(--color-border);
    z-index: 90;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.footer.collapsed {
    transform: translateY(100%);
}

.footer-toggle {
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(20, 20, 20, 0.98);
    border: 1px solid var(--color-border-light);
    border-bottom: 1px solid var(--color-border);
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    padding: 0.25rem 2rem;
    cursor: pointer;
    color: var(--color-gold-dark);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 -2px 8px rgba(212, 175, 55, 0.15);
    animation: footerTabPulse 3s ease-in-out infinite;
}

@keyframes footerTabPulse {

    0%,
    100% {
        box-shadow: 0 -2px 8px rgba(212, 175, 55, 0.15);
    }

    50% {
        box-shadow: 0 -2px 12px rgba(212, 175, 55, 0.25);
    }
}

.footer-toggle:hover {
    background: var(--color-surface-hover);
    color: var(--color-gold-light);
    border-color: var(--color-gold-dark);
    box-shadow: 0 -2px 16px rgba(212, 175, 55, 0.35);
    animation: none;
    transform: translateX(-50%) translateY(-2px);
}

.footer-toggle svg {
    width: 18px;
    height: 18px;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    filter: drop-shadow(0 0 2px rgba(212, 175, 55, 0.3));
}

.footer.collapsed .footer-toggle {
    border-bottom: none;
}

.footer.collapsed .footer-toggle svg {
    transform: rotate(180deg);
}

.footer-content {
    max-width: 1600px;
    margin: 0 auto;
    text-align: center;
    padding: var(--spacing-lg) var(--spacing-xl);
}

.footer-content p {
    margin: 0;
    color: var(--color-text-secondary);
    font-size: 0.875rem;
}

.footer-link {
    display: inline-flex;
    align-items: center;
    color: var(--color-text-secondary);
    text-decoration: none;
    transition: color 0.2s;
}

.footer-link:hover {
    color: var(--color-gold-light);
}

/* ========== RESPONSIVE ========== */
@media (max-width: 1200px) {
    .header-content {
        flex-direction: column;
        align-items: stretch;
        gap: var(--spacing-sm);
        padding: var(--spacing-md);
    }

    .brand {
        justify-content: center;
    }

    .brand-logo {
        height: 32px;
    }

    .brand h1 {
        font-size: 1rem;
    }

    .header-actions {
        display: grid;
        grid-template-columns: auto auto 1fr auto;
        gap: var(--spacing-sm);
        align-items: stretch;
    }

    .search-box {
        /* First row, spans columns 1-3 */
        grid-column: 1 / 4;
    }

    .search-input {
        width: 100%;
        padding: 0.5rem 0.75rem 0.5rem 2.25rem;
        font-size: 0.8125rem;
    }

    .search-icon {
        left: 12px;
        width: 16px;
        height: 16px;
    }

    .sort-dropdown {
        /* First row, column 4, icon-only button */
        grid-column: 4 / 5;
    }

    .sort-dropdown .btn {
        padding: 0.5rem 0.75rem;
        font-size: 0.8125rem;
        min-width: auto;
    }

    .sort-dropdown .btn #sortLabel {
        display: none;
    }

    .sort-dropdown .btn .chevron-icon {
        display: none;
    }

    .sort-dropdown .btn .sort-icon {
        display: block;
        width: 16px;
        height: 16px;
    }

    .dropdown-item svg {
        width: 14px;
        height: 14px;
    }

    #exportBtn,
    #importBtn {
        /* Second row, columns 1 and 2, icon only buttons */
        padding: 0.5rem 0.75rem;
        min-width: auto;
    }

    #exportBtn span,
    #importBtn span {
        display: none;
    }

    #exportBtn svg,
    #importBtn svg {
        width: 16px;
        height: 16px;
    }

    #addBtn {
        /* Second row, spans columns 3-4 */
        grid-column: 3 / 5;
    }

    .btn {
        justify-content: center;
        padding: 0.375rem 0.75rem;
        font-size: 0.8125rem;
        gap: 0.375rem;
    }

    .btn svg {
        width: 14px;
        height: 14px;
    }

    .main {
        padding: var(--spacing-md);
    }

    .resources-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .resource-actions {
        opacity: 1;
        position: static;
    }

    .resource-item {
        grid-template-columns: 1fr auto auto;
        gap: var(--spacing-md);
        cursor: default;
    }

    .resources-grid .resource-item {
        cursor: default;
    }

    .resource-weight-display {
        display: flex;
        min-width: 70px;
    }

    .resource-item:hover .resource-weight-display {
        opacity: 1;
        pointer-events: auto;
    }

    .modal {
        padding: var(--spacing-md);
    }
}

@media (max-width: 600px) {
    .resources-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 1201px) and (max-width: 1400px) {
    .resources-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (min-width: 1401px) {
    .resources-grid {
        grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    }
}