
/* Update History Styles */
.history-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.update-entry {
    background: #fff;
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: box-shadow 0.2s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.update-entry:hover {
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
}

.update-header {
    background: #f8f9fa;
    padding: 15px 20px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid transparent;
    transition: background-color 0.2s;
    user-select: none;
}

.update-header:hover {
    background: #f1f3f5;
}

.update-header h3 {
    margin: 0;
    font-size: 1rem;
    color: #333;
    font-weight: 600;
}

.toggle-icon {
    width: 24px;
    height: 24px;
    position: relative;
    opacity: 0.6;
}

.toggle-icon::before,
.toggle-icon::after {
    content: '';
    position: absolute;
    background-color: #333;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    transition: transform 0.3s ease;
}

.toggle-icon::before {
    width: 12px;
    height: 2px;
}

.toggle-icon::after {
    width: 2px;
    height: 12px;
}

/* Expanded State */
.update-entry.expanded .update-header {
    border-bottom-color: #eee;
    background: #fff;
}

.update-entry.expanded .update-header h3 {
    color: var(--primary-color, #28a745); /* Fallback to green if var not defined */
}

.update-entry.expanded .toggle-icon::after {
    transform: translate(-50%, -50%) rotate(90deg);
}

.update-content {
    display: grid;
    grid-template-rows: 0fr;
    transition: grid-template-rows 0.3s ease-out;
    background: #fff;
    /* Ensure content is clipped when collapsed to 0 height, 
       hiding any padding from the child element */
    overflow: hidden;
}

.update-entry.expanded .update-content {
    grid-template-rows: 1fr;
    transition: grid-template-rows 0.3s ease-out;
}

.update-content ul {
    overflow: hidden;
    /* min-height: 0 is crucial for the grid-template-rows animation 
       to allow the item to shrink below its content size */
    min-height: 0; 
    list-style-type: none;
    margin: 0;
}

.update-content li {
    position: relative;
    padding-left: 20px;
    padding-bottom: 10px;
    color: #555;
    line-height: 1.5;
    margin: 10px;
}

.update-content li:last-child {
    margin-bottom: 0;
}

.update-content li::before {
    content: "•";
    color: #28a745;
    position: absolute;
    left: 0;
    font-weight: bold;
}

/* Button Secondary */
.btn-secondary {
    background: #f8f9fa;
    border: 1px solid #ddd;
    padding: 10px 20px;
    border-radius: 4px;
    color: #555;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.btn-secondary:hover {
    background: #e9ecef;
    color: #333;
    border-color: #ccc;
}

.update-entry:nth-child(n + 4) {
    display: none;
}