.thumb-wrapper {
    position: relative;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    border-radius: 18px;
}

.media-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.media-card:hover .thumb-wrapper img {
    transform: scale(1.1);
}

.article-delete-btn {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: rgba(239,68,68,0.2);
    border: 1px solid #ef4444;
    color: #ef4444;
    padding: 0.8rem;
    border-radius: 12px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s var(--ease-out);
}

.article-delete-btn:hover {
    background: #ef4444;
    color: white;
}

.bento-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.bento-card {
    border-radius: 16px;
    padding: 2rem;
    transition: 0.4s var(--ease-out);
    text-align: center;
}

.bento-card:hover {
    transform: translateY(-8px);
    border-color: rgba(255,255,255,0.3);
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
}

.bento-card img {
    width: 100%;
    height: 320px;
    object-fit: contain;
    filter: drop-shadow(0 10px 20px rgba(0,0,0,0.6));
    transition: 0.4s;
}

.bento-card:hover img { transform: scale(1.05); }

.card-info h4 {
    margin-top: 1.5rem;
    font-size: 1.6rem;
    font-weight: 600;
}

.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
    gap: 2rem;
}

.media-card {
    border-radius: 12px;
    overflow: hidden;
    transition: 0.3s;
}

.media-card:hover {
    border-color: var(--accent);
    transform: translateY(-4px);
}

.thumb-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.media-card:hover .thumb-wrapper img { transform: scale(1.08); }

.media-info {
    padding: 1.5rem;
}

.media-info h4 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
    line-height: 1.4;
    font-weight: 500;
}

.media-meta {
    font-size: 0.8rem;
    color: var(--secondary);
    display: flex;
    justify-content: space-between;
    font-family: var(--font-mono);
}

.terminal-window {
    background: #0a0a0a;
    border: 1px solid var(--border);
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.6);
    font-family: var(--font-mono);
    overflow: hidden;
}

.terminal-header {
    background: rgba(255,255,255,0.03);
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    border-bottom: 1px solid var(--border);
}

.win-buttons { display: flex; gap: 8px; }
.win-buttons span {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}
.win-buttons span:nth-child(1) { background: #ff5f56; }
.win-buttons span:nth-child(2) { background: #ffbd2e; }
.win-buttons span:nth-child(3) { background: #27c93f; }

.win-title {
    color: var(--secondary);
    font-size: 0.8rem;
    letter-spacing: 1px;
    margin-left: 1.5rem;
}

.terminal-body {
    padding: 2rem;
    min-height: 500px;
    color: #a8a8a8;
    font-size: 0.95rem;
}

.dashboard-interface {
    display: grid;
    grid-template-columns: 380px 1fr;
    border-radius: 16px;
    height: 620px;
    overflow: hidden;
}

.agent-list-panel {
    border-right: 1px solid var(--border);
    overflow-y: auto;
    background: rgba(0,0,0,0.3);
}

.agent-item {
    padding: 1.2rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: 0.2s;
}

.agent-item:hover,
.agent-item.active {
    background: rgba(59, 130, 246, 0.1);
    border-left: 3px solid var(--accent);
}

.agent-item img {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1px solid var(--border);
    object-fit: cover;
}

.agent-preview-panel {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    background: rgba(0,0,0,0.2);
}

.placeholder-state {
    text-align: center;
    color: var(--secondary);
    opacity: 0.5;
}

.stable-banner {
    border-radius: 16px;
    padding: 3rem;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
}

.tool-card {
    height: 320px;
    border-radius: 16px;
    display: flex;
    flex-direction: column;
}

.tool-head {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--secondary);
}

.tool-body {
    flex: 1;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tool-body img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.text-body {
    padding: 1.5rem;
    align-items: flex-start;
    justify-content: flex-start;
    text-align: left;
    font-size: 0.9rem;
    color: var(--secondary);
}

.refresh-mini {
    background: none;
    border: none;
    color: var(--secondary);
    cursor: pointer;
    opacity: 0.6;
    transition: 0.2s;
}

.refresh-mini:hover {
    opacity: 1;
    color: var(--primary);
    transform: rotate(90deg);

}
