/* --- Plugins Page Modern Design --- */

:root {
    --mylands-color: #00c896;
    --mycommands-color: #5865f2;
    --myeconomy-color: #f1c40f;
    --mylands-glow: rgba(0, 200, 150, 0.4);
    --mycommands-glow: rgba(88, 101, 242, 0.4);
    --myeconomy-glow: rgba(241, 196, 15, 0.4);
}

.plugins-page-modern {
    padding: 6rem 0;
    min-height: 80vh;
    background: radial-gradient(circle at 50% 10%, rgba(88, 101, 242, 0.05), transparent 40%);
}

/* --- Header --- */
.plugins-header-modern {
    text-align: center;
    margin-bottom: 4rem;
    position: relative;
}

.plugins-badge-modern {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 1.5rem;
    backdrop-filter: blur(5px);
}

.plugins-title-modern {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, #fff 0%, #aaa 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -1px;
}

.plugins-subtitle-modern {
    color: var(--text-muted);
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.6;
}

/* --- Grid --- */
.plugins-grid-modern {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 2rem;
    padding: 1rem;
}

/* --- Card --- */
.plugin-card {
    position: relative;
    background: rgba(22, 27, 34, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    padding: 2rem;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    backdrop-filter: blur(10px);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.plugin-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(800px circle at var(--mouse-x) var(--mouse-y), rgba(255, 255, 255, 0.06), transparent 40%);
    opacity: 0;
    transition: opacity 0.5s;
    pointer-events: none;
    z-index: 1;
}

.plugin-card:hover::before {
    opacity: 1;
}

.plugin-card:hover {
    transform: translateY(-10px);
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
}

/* Dynamic Glows based on plugin type */
.plugin-card[data-slug="mylands"]:hover {
    border-color: var(--mylands-color);
    box-shadow: 0 10px 40px -10px var(--mylands-glow);
}

.plugin-card[data-slug="mycommands"]:hover {
    border-color: var(--mycommands-color);
    box-shadow: 0 10px 40px -10px var(--mycommands-glow);
}

.plugin-card[data-slug="myeconomy"]:hover {
    border-color: var(--myeconomy-color);
    box-shadow: 0 10px 40px -10px var(--myeconomy-glow);
}

/* Card Header */
.plugin-card-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 2;
}

.plugin-icon {
    width: 60px;
    height: 60px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.4s ease;
}

.plugin-card:hover .plugin-icon {
    background: var(--accent);
    color: #fff;
    transform: rotate(10deg) scale(1.1);
    box-shadow: 0 0 20px rgba(0, 200, 150, 0.4);
}

.plugin-card[data-slug="mycommands"]:hover .plugin-icon {
    background: var(--mycommands-color);
    box-shadow: 0 0 20px rgba(88, 101, 242, 0.4);
}

.plugin-card[data-slug="myeconomy"]:hover .plugin-icon {
    background: var(--myeconomy-color);
    box-shadow: 0 0 20px rgba(241, 196, 15, 0.4);
}

.plugin-version-badge {
    padding: 4px 10px;
    background: rgba(0, 200, 150, 0.15);
    color: var(--accent);
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    border: 1px solid rgba(0, 200, 150, 0.3);
}

/* Card Body */
.plugin-body {
    flex-grow: 1;
    position: relative;
    z-index: 2;
}

.plugin-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-align: center;
}

.badge-new {
    font-size: 0.6rem;
    padding: 2px 6px;
    background: linear-gradient(135deg, #ff4081, #ff80ab);
    color: white;
    border-radius: 4px;
    font-weight: 800;
    text-transform: uppercase;
    vertical-align: middle;
}

.plugin-desc {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-align: center;
}

/* Meta Data */
.plugin-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    justify-content: center;
}

.meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.03);
    padding: 6px 12px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.meta-item i {
    color: var(--accent);
}

/* Actions */
.plugin-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-top: auto;
    position: relative;
    z-index: 2;
}

.btn-card {
    padding: 10px;
    border-radius: 12px;
    font-size: 0.9rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s ease;
    text-decoration: none !important;
    cursor: pointer;
}

.btn-card-primary {
    background: var(--accent);
    color: #fff;
    border: none;
    box-shadow: 0 4px 15px rgba(0, 200, 150, 0.2);
    grid-column: span 2;
}

.btn-card-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 200, 150, 0.4);
}

.btn-card-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-light);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.btn-card-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.download-bar {
    margin-top: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    height: 6px;
    overflow: hidden;
    position: relative;
}

.download-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 10px;
}

@media (max-width: 768px) {
    .plugins-grid-modern {
        grid-template-columns: 1fr;
    }
}

/* --- Updates for Version & Download Text --- */
.plugin-header-badges {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
}

.badge-new-version {
    background: linear-gradient(135deg, #00c896, #00e676) !important;
    color: #fff !important;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    box-shadow: 0 2px 10px rgba(0, 200, 150, 0.3) !important;
    border: none !important;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    text-shadow: none !important;
}

.download-section {
    margin-top: 1rem;
}

/* Reset margin since it's inside section, with high specificity to override */
.download-section .download-bar {
    margin-top: 0;
}

.download-text {
    display: block;
    text-align: right;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 6px;
    font-family: 'JetBrains Mono', monospace;
}