/* Selected Item Highlight */
.char-item {
    cursor: pointer;
    transition: background-color 0.2s;
    padding: 8px;
    /* Slightly more padding */
}

.char-item:hover {
    background-color: #222;
}

.char-item.selected {
    background-color: #eee;
    color: #000;
}

.char-item.selected button {
    border-color: #000;
    /* Adjust button border when inverted */
    color: #000;
    background: #ccc;
}

.char-item small {
    color: #CCC;
}

.char-item.selected small {
    color: #777;
    /* Darker grey when selected */
}

/* Character Detail Card */
.detail-card {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    font-size: 0.9em;
}

.detail-header {
    grid-column: 1 / -1;
    border-bottom: 1px solid #444;
    padding-bottom: 5px;
    margin-bottom: 5px;
}

.detail-stat {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px dashed #333;
}

.detail-stat label {
    color: #ccc;
}

/* Inn Specific Styles */
.inn-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 15px;
    margin-bottom: 20px;
}

.inn-card {
    padding: 10px;
    border: 1px solid #CCC;
    background: #0a0a0a;
    position: relative;
    transition: all 0.2s ease-out;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.5);
    border-radius: 2px;
    display: flex;
    gap: 12px;
}

.inn-card.needs-recovery {
    border-color: #533;
    background: #1a0a0a;
}

.inn-card.poisoned {
    border-color: #a0f;
    background: #201030;
    box-shadow: 0 0 10px rgba(160, 0, 255, 0.2);
}

.inn-card:hover {
    border-color: #0af;
    background: #001;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.8), 0 0 10px rgba(0, 170, 255, 0.2);
}

.inn-card.healing {
    filter: brightness(1.5);
    box-shadow: 0 0 20px rgba(0, 255, 0, 0.3);
}

.inn-card.just-healed {
    animation: heal-pulse 1s ease-out;
}

@keyframes heal-pulse {
    0% {
        filter: brightness(2);
        transform: scale(1.02);
    }

    100% {
        filter: brightness(1);
        transform: scale(1);
    }
}

.inn-poison-badge {
    position: absolute;
    top: -5px;
    right: 10px;
    background: #a0f;
    color: #fff;
    font-size: 9px;
    padding: 2px 6px;
    border-radius: 3px;
    font-weight: bold;
    box-shadow: 0 0 8px #a0f;
    z-index: 10;
    animation: pulse-poison 2s infinite;
}

@keyframes pulse-poison {
    0% {
        opacity: 0.8;
    }

    50% {
        opacity: 1;
        transform: scale(1.05);
    }

    100% {
        opacity: 0.8;
    }
}